You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
svelte-kit-vice/src/uix/eidos/index.css

99 lines
4.7 KiB

eidos: V1 minimum viable — tokens + archetype rules + event reactions First eidos code. Closes the cross-layer cycle that's been documented but unproven: an actual CSS layer that consumes the morfo + sema contracts and applies styles transversally without enumerating components. src/uix/eidos/ - tokens.css — motion durations (quick/fast/base) + easings (standard / emphasized / decelerate) + opacity scale (hover/disabled/faded) + intent tints (neutral/affirm/fulfill/risk/threat) + focus ring tokens. ~30 lines. No theming dimension yet — when it arrives, these are the base theme. - archetypes.css — transversal selectors keyed by `data-archetype`. Covers trigger, overlay, content, indicator, thumb, track, close, action, item, option. Plus a universal `:focus-visible` ring rule that applies to every archetype-classified element. Single attribute selector specificity — components can override freely. - events.css — reactions to perceptual signals during their ~13ms life. `[data-event^="dismiss"]` fades out, `[data-event^="announce"]` pulses with intent-tinted box-shadow, `[data-last-action]` tints exit animation by causa. - index.css — entrypoint that imports the above in cascade order. Consumer: `import '$uix/eidos/index.css'`. src/routes/test/eidos/+page.svelte (demo) - Sets up Soma + App context inline (independent of /test/soma layout). - Imports `$uix/eidos/index.css` and demonstrates the cross-layer story: - Toggle + Switch buttons share trigger styles via `[data-archetype="trigger"]` without per-component CSS. - Collapsible expands/collapses with state-driven attrs. - Toast intent buttons fire `data-event="announce" data-intent="risk|threat|affirm"`, which eidos's events.css briefly tints via box-shadow during the signal window. - Component-specific layout (positioning, switch thumb transform) lives in the page's `<style>` block — eidos provides only the cross-component baseline, NOT per-component recipes. What this proves - The runtime emits `data-archetype` correctly in browser (not just in unit tests). - A single CSS rule can target ALL triggers across all components without enumeration. Add a new component with `archetype: 'trigger'` and it inherits the styling automatically. - Sema's `data-event*` signals live in the DOM long enough for CSS to react (the ~13ms window measured by `scripts/probe-toast-dismiss.ts` is observable as a brief box-shadow flash on toasts). - The cross-layer cycle Morfo declara → Soma transcribe → Sema emite → Dom aplica → Eidos lee runs end-to-end. What V1 deliberately excludes - Theming dimension (no `[data-theme]` overrides yet). - Per-component recipes (each component will get its own CSS later). - Keyframes / @starting-style / animation primitives. - Sound / vibra (those are separate engines that subscribe to sema). Verification - /test/eidos returns 200; manual browser check shows triggers share hover dim + focus ring across components, toasts flash intent tint on appear. - 68/68 smoke routes (smoke only scans /test/soma — eidos route is outside that scope, manually verified). - svelte-check unchanged at 155 (pure CSS additions).
6 months ago
/**
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* Eidos — visual layer entrypoint.
*
* Eidos is CSS that reads `data-*` attrs emitted by the morfo-runtime
* (via soma) and the visual channel (via sema) and applies styling.
* It does not act, it does not own state, it does not decide events.
*
* Layout (translated from the legacy `air/` layer with the architectural
* adjustments below — air targeted terra and was class-gated; eidos
* targets soma+morfo and applies universally to the data-attrs the
* morfo declares):
*
* generated/ foundation CSS generated from EidosConfig
* themes/ font assets used by the base generated theme
* components/ recipes per component (selectors and state rules)
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* archetypes transversal selectors keyed by `data-archetype`
* events reactions to `data-event-*` signals (sema visual channel)
*
eidos: pilot wrapper pattern + doctrinal API conventions Toggle as the eidos pilot: subdirectory layout (recipe + Svelte wrapper + types + index + README) replacing the flat CSS-only form. Pattern is documented in eidos/components/README.md and the toggle README. Shared types live in eidos/lib/types.ts. First export is `Size` (8 values xxs..xxl + full); components narrow with `Extract<Size, ...>` per the per-component-subset doctrine. No `Eidos` prefix on types — module path already conveys the layer. API doctrine: - soma stays compound (Toggle.Provider) for symmetry with multi-part - eidos exports both default + Provider so single-part components accept both `<Toggle>` (ergonomic) and `<Toggle.Provider>` (compound-style consumers) SoundChannel eager-init fixes the autoplay race: AudioContext is created + resumed synchronously on the first user gesture (capture-phase listener registered in the constructor), avoiding the previous race where the first emit() scheduled the resume in a microtask outside the gesture window. Demo page (web/routes/toggle/+page.svelte) restructured so the live preview renders ALWAYS above the tablist — Sema-tab Play buttons can fire on the real toggle. Motion preview amplifies scale ×8 visually only; doctrinal values stay in the <dl>. Conventions 7-13 added to src/docs/sema-implementation-guide.md covering: directory structure, wrapper composition, no Eidos prefix, soma compound vs eidos flat, iconOnly sr-only body, sound eager-init, docs-preview amplification. CLAUDE.md gets a session hand-off block listing where things stand and next concrete steps (migrate switch/collapsible/dialog/drawer/popover/ toast/avatar; wire topbar sound mute to masterGain; rename theme tokens to drop the success/warning/danger fallback aliases). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* --- The `--*` token prefix ---
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
*
* In an app with a single owned design system there's no strict need for a
eidos: pilot wrapper pattern + doctrinal API conventions Toggle as the eidos pilot: subdirectory layout (recipe + Svelte wrapper + types + index + README) replacing the flat CSS-only form. Pattern is documented in eidos/components/README.md and the toggle README. Shared types live in eidos/lib/types.ts. First export is `Size` (8 values xxs..xxl + full); components narrow with `Extract<Size, ...>` per the per-component-subset doctrine. No `Eidos` prefix on types — module path already conveys the layer. API doctrine: - soma stays compound (Toggle.Provider) for symmetry with multi-part - eidos exports both default + Provider so single-part components accept both `<Toggle>` (ergonomic) and `<Toggle.Provider>` (compound-style consumers) SoundChannel eager-init fixes the autoplay race: AudioContext is created + resumed synchronously on the first user gesture (capture-phase listener registered in the constructor), avoiding the previous race where the first emit() scheduled the resume in a microtask outside the gesture window. Demo page (web/routes/toggle/+page.svelte) restructured so the live preview renders ALWAYS above the tablist — Sema-tab Play buttons can fire on the real toggle. Motion preview amplifies scale ×8 visually only; doctrinal values stay in the <dl>. Conventions 7-13 added to src/docs/sema-implementation-guide.md covering: directory structure, wrapper composition, no Eidos prefix, soma compound vs eidos flat, iconOnly sr-only body, sound eager-init, docs-preview amplification. CLAUDE.md gets a session hand-off block listing where things stand and next concrete steps (migrate switch/collapsible/dialog/drawer/popover/ toast/avatar; wire topbar sound mute to masterGain; rename theme tokens to drop the success/warning/danger fallback aliases). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* prefix on custom properties: nothing else collides. We keep `--*`
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* deliberately, for two reasons:
*
* 1. **Authorship clarity at debug time.** Inspecting an element in
eidos: pilot wrapper pattern + doctrinal API conventions Toggle as the eidos pilot: subdirectory layout (recipe + Svelte wrapper + types + index + README) replacing the flat CSS-only form. Pattern is documented in eidos/components/README.md and the toggle README. Shared types live in eidos/lib/types.ts. First export is `Size` (8 values xxs..xxl + full); components narrow with `Extract<Size, ...>` per the per-component-subset doctrine. No `Eidos` prefix on types — module path already conveys the layer. API doctrine: - soma stays compound (Toggle.Provider) for symmetry with multi-part - eidos exports both default + Provider so single-part components accept both `<Toggle>` (ergonomic) and `<Toggle.Provider>` (compound-style consumers) SoundChannel eager-init fixes the autoplay race: AudioContext is created + resumed synchronously on the first user gesture (capture-phase listener registered in the constructor), avoiding the previous race where the first emit() scheduled the resume in a microtask outside the gesture window. Demo page (web/routes/toggle/+page.svelte) restructured so the live preview renders ALWAYS above the tablist — Sema-tab Play buttons can fire on the real toggle. Motion preview amplifies scale ×8 visually only; doctrinal values stay in the <dl>. Conventions 7-13 added to src/docs/sema-implementation-guide.md covering: directory structure, wrapper composition, no Eidos prefix, soma compound vs eidos flat, iconOnly sr-only body, sound eager-init, docs-preview amplification. CLAUDE.md gets a session hand-off block listing where things stand and next concrete steps (migrate switch/collapsible/dialog/drawer/popover/ toast/avatar; wire topbar sound mute to masterGain; rename theme tokens to drop the success/warning/danger fallback aliases). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* DevTools and seeing `--toggle-bg` immediately answers "this
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* came from the visual layer of UIX". A bare `--toggle-bg` could
* come from anywhere — a third-party widget, a route-scoped style,
* an experiment.
*
eidos: pilot wrapper pattern + doctrinal API conventions Toggle as the eidos pilot: subdirectory layout (recipe + Svelte wrapper + types + index + README) replacing the flat CSS-only form. Pattern is documented in eidos/components/README.md and the toggle README. Shared types live in eidos/lib/types.ts. First export is `Size` (8 values xxs..xxl + full); components narrow with `Extract<Size, ...>` per the per-component-subset doctrine. No `Eidos` prefix on types — module path already conveys the layer. API doctrine: - soma stays compound (Toggle.Provider) for symmetry with multi-part - eidos exports both default + Provider so single-part components accept both `<Toggle>` (ergonomic) and `<Toggle.Provider>` (compound-style consumers) SoundChannel eager-init fixes the autoplay race: AudioContext is created + resumed synchronously on the first user gesture (capture-phase listener registered in the constructor), avoiding the previous race where the first emit() scheduled the resume in a microtask outside the gesture window. Demo page (web/routes/toggle/+page.svelte) restructured so the live preview renders ALWAYS above the tablist — Sema-tab Play buttons can fire on the real toggle. Motion preview amplifies scale ×8 visually only; doctrinal values stay in the <dl>. Conventions 7-13 added to src/docs/sema-implementation-guide.md covering: directory structure, wrapper composition, no Eidos prefix, soma compound vs eidos flat, iconOnly sr-only body, sound eager-init, docs-preview amplification. CLAUDE.md gets a session hand-off block listing where things stand and next concrete steps (migrate switch/collapsible/dialog/drawer/popover/ toast/avatar; wire topbar sound mute to masterGain; rename theme tokens to drop the success/warning/danger fallback aliases). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* 2. **Override discipline.** A consumer overriding `--color-
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* primary-element` knows they are overriding the visual layer
* contract, not just naming-colliding with some local variable.
* The prefix makes the public API surface explicit.
*
* Tokens are owned by EidosConfig and emitted by the generated foundation.
* Recipes inside eidos consume them via `var(--*)`. Higher layers (sema,
* soma, morfo) do NOT consume these tokens — those layers carry their own
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
* concerns (perceptual durations, behavior, contract DNA) that are
* independent of visual rendering.
eidos: V1 minimum viable — tokens + archetype rules + event reactions First eidos code. Closes the cross-layer cycle that's been documented but unproven: an actual CSS layer that consumes the morfo + sema contracts and applies styles transversally without enumerating components. src/uix/eidos/ - tokens.css — motion durations (quick/fast/base) + easings (standard / emphasized / decelerate) + opacity scale (hover/disabled/faded) + intent tints (neutral/affirm/fulfill/risk/threat) + focus ring tokens. ~30 lines. No theming dimension yet — when it arrives, these are the base theme. - archetypes.css — transversal selectors keyed by `data-archetype`. Covers trigger, overlay, content, indicator, thumb, track, close, action, item, option. Plus a universal `:focus-visible` ring rule that applies to every archetype-classified element. Single attribute selector specificity — components can override freely. - events.css — reactions to perceptual signals during their ~13ms life. `[data-event^="dismiss"]` fades out, `[data-event^="announce"]` pulses with intent-tinted box-shadow, `[data-last-action]` tints exit animation by causa. - index.css — entrypoint that imports the above in cascade order. Consumer: `import '$uix/eidos/index.css'`. src/routes/test/eidos/+page.svelte (demo) - Sets up Soma + App context inline (independent of /test/soma layout). - Imports `$uix/eidos/index.css` and demonstrates the cross-layer story: - Toggle + Switch buttons share trigger styles via `[data-archetype="trigger"]` without per-component CSS. - Collapsible expands/collapses with state-driven attrs. - Toast intent buttons fire `data-event="announce" data-intent="risk|threat|affirm"`, which eidos's events.css briefly tints via box-shadow during the signal window. - Component-specific layout (positioning, switch thumb transform) lives in the page's `<style>` block — eidos provides only the cross-component baseline, NOT per-component recipes. What this proves - The runtime emits `data-archetype` correctly in browser (not just in unit tests). - A single CSS rule can target ALL triggers across all components without enumeration. Add a new component with `archetype: 'trigger'` and it inherits the styling automatically. - Sema's `data-event*` signals live in the DOM long enough for CSS to react (the ~13ms window measured by `scripts/probe-toast-dismiss.ts` is observable as a brief box-shadow flash on toasts). - The cross-layer cycle Morfo declara → Soma transcribe → Sema emite → Dom aplica → Eidos lee runs end-to-end. What V1 deliberately excludes - Theming dimension (no `[data-theme]` overrides yet). - Per-component recipes (each component will get its own CSS later). - Keyframes / @starting-style / animation primitives. - Sound / vibra (those are separate engines that subscribe to sema). Verification - /test/eidos returns 200; manual browser check shows triggers share hover dim + focus ring across components, toasts flash intent tint on appear. - 68/68 smoke routes (smoke only scans /test/soma — eidos route is outside that scope, manually verified). - svelte-check unchanged at 155 (pure CSS additions).
6 months ago
*/
/* ── Foundation: generated static fallback ─────────────────────────────────
*
* ActiveEidos is the canonical source for generated foundation CSS. This
* entrypoint imports the generated artifact for SSR/static docs where
* `ActiveEidos.create({ applyDom: false })` does not inject runtime styles.
* Historical `contracts/` and `themes/base/` CSS were retired once
* ActiveEidos became the source for generated foundation/theme CSS.
*/
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
/* ── Theme assets: font faces used by the base static theme tokens ───────── */
@import './themes/fonts.css';
/* ── Generated foundation: ActiveEidos base config static export ────────── */
@import './generated/base.css';
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
/* ── Eidos-specific layers (no equivalent in air) ───────────────────────── */
eidos: V1 minimum viable — tokens + archetype rules + event reactions First eidos code. Closes the cross-layer cycle that's been documented but unproven: an actual CSS layer that consumes the morfo + sema contracts and applies styles transversally without enumerating components. src/uix/eidos/ - tokens.css — motion durations (quick/fast/base) + easings (standard / emphasized / decelerate) + opacity scale (hover/disabled/faded) + intent tints (neutral/affirm/fulfill/risk/threat) + focus ring tokens. ~30 lines. No theming dimension yet — when it arrives, these are the base theme. - archetypes.css — transversal selectors keyed by `data-archetype`. Covers trigger, overlay, content, indicator, thumb, track, close, action, item, option. Plus a universal `:focus-visible` ring rule that applies to every archetype-classified element. Single attribute selector specificity — components can override freely. - events.css — reactions to perceptual signals during their ~13ms life. `[data-event^="dismiss"]` fades out, `[data-event^="announce"]` pulses with intent-tinted box-shadow, `[data-last-action]` tints exit animation by causa. - index.css — entrypoint that imports the above in cascade order. Consumer: `import '$uix/eidos/index.css'`. src/routes/test/eidos/+page.svelte (demo) - Sets up Soma + App context inline (independent of /test/soma layout). - Imports `$uix/eidos/index.css` and demonstrates the cross-layer story: - Toggle + Switch buttons share trigger styles via `[data-archetype="trigger"]` without per-component CSS. - Collapsible expands/collapses with state-driven attrs. - Toast intent buttons fire `data-event="announce" data-intent="risk|threat|affirm"`, which eidos's events.css briefly tints via box-shadow during the signal window. - Component-specific layout (positioning, switch thumb transform) lives in the page's `<style>` block — eidos provides only the cross-component baseline, NOT per-component recipes. What this proves - The runtime emits `data-archetype` correctly in browser (not just in unit tests). - A single CSS rule can target ALL triggers across all components without enumeration. Add a new component with `archetype: 'trigger'` and it inherits the styling automatically. - Sema's `data-event*` signals live in the DOM long enough for CSS to react (the ~13ms window measured by `scripts/probe-toast-dismiss.ts` is observable as a brief box-shadow flash on toasts). - The cross-layer cycle Morfo declara → Soma transcribe → Sema emite → Dom aplica → Eidos lee runs end-to-end. What V1 deliberately excludes - Theming dimension (no `[data-theme]` overrides yet). - Per-component recipes (each component will get its own CSS later). - Keyframes / @starting-style / animation primitives. - Sound / vibra (those are separate engines that subscribe to sema). Verification - /test/eidos returns 200; manual browser check shows triggers share hover dim + focus ring across components, toasts flash intent tint on appear. - 68/68 smoke routes (smoke only scans /test/soma — eidos route is outside that scope, manually verified). - svelte-check unchanged at 155 (pure CSS additions).
6 months ago
@import './archetypes.css';
@import './events.css';
eidos: phase 1 — translate air's foundation (contracts, tokens, themes/base) Translates the foundation of air's visual system into eidos: - eidos/contracts/ public token interfaces (4 root + 64 components) - eidos/tokens/ per-component token values (62 components + motion) - eidos/themes/base/ light + dark + _static + motion (4 files) Mechanical translation: `--air-*` → `--eidos-*` everywhere, relative imports preserved. The CSS is currently NOT wired into the legacy air/ folder, which stays for reference until phase 4 cleanup. The `--eidos-*` prefix is documented in eidos/index.css with the two reasons it earns its keep: 1. Authorship clarity at debug time (DevTools can identify the layer) 2. Override discipline (consumers know they're targeting public API) Phase 1 only adds the foundation without touching component recipes. The hand-rolled recipes (toast, dialog, toggle, switch, collapsible) and the legacy hand-rolled tokens.css continue to load alongside the new tree. Phase 2 will replace recipes with air-translated equivalents and reconcile the duplicate motion/tint tokens. Architectural note: air targeted terra and gated its CSS with `.air-{component}` class on a wrapper. Eidos targets soma+morfo and applies universally to the data-attrs the morfo declares — no class gates, no Svelte wrappers. The morfo layer is the one that decides which `data-*` attrs exist, which is the substantive shift between the two systems. Verification: smoke 68/68, morfo-check 66/66, focus rings + dialog entrance/exit still working per Playwright check (curve unchanged). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
/* ── Component recipes ──────────────────────────────────────────────────── */
@import './components/icon/icon.css';
@import './components/avatar/avatar.css';
@import './components/breadcrumb/breadcrumb.css';
@import './components/toast/toast.css';
sema/morfo/eidos: typed selector builder + dialog wrapper + emerge color sema architecture - sema-map: 5-channel registry (motion / sound / color / presence / haptic) via SemaChannelSignatures declaration merging; engine stamps data-event-* tokens; flat CSS-style cascade replaces the eventLabel-overrides middle layer. - sema-map: emerge family gains base.color so intent deltas can shift hue / saturation / intensity. Without a base, the resolver was skipping the channel and Dialog open with intent='threat' rendered as neutral blue in the Sema tab visualisation. - types: SEMA_FAMILY_POLICY const drives compile-time + runtime intent requirements per family. Object shape so future per-family policy fields fit alongside. Emerge events MAY now declare intent (canon update — a Dialog confirming threat carries it in its very appearance). - chans: rename vibra→haptic, add HapticChannel V1 (Vibration API); SoundChannel eager-init on first user gesture (autoplay race fix). morfo selector discipline - morfo/selectors.ts (new): semaSelector(morfo, partKebab, matchers?) — type-checked against morfo.parts and morfo.events. Sema cascade rules MUST use it; hand-written strings are an architecture violation that breaks silently when morfo renames a part. - dialog morfo: open carries intent via fromProp; close-cancel / close-dismiss / close-dismiss-outside drop intent (cancellation has no evaluative load); close-save stays hardcoded fulfill (commit fulfils the user's decision regardless of dialog context). eidos dialog migration (4th pilot) - eidos/components/dialog/: full subdirectory wrapper — flat <Dialog> + compound Provider/Trigger/Overlay/Content/Title/Description/Close/Header/ Footer; size + position responsive props; sheet auto-form on narrow viewports; closePosition for the auto-X. - sema/components/dialog.ts: cascade rules use semaSelector(dialogMorfo, 'content', matchers?). Intent block adds character (haptic kind / pattern) but never overrides pitch / gain / contour — those are intent.deltas signature ownership and overriding flattens per-intent perceptual difference. demo controls + dialog page - src/lib/_demo (DemoSwitch / DemoEnum / DemoText / DemoRange) — unified controls reused across all component demos. - web/routes/dialog: live preview always rendered above tabs; per-event Sema tab with independent intent probe; signature visualisation + Play buttons with fallback target chain. documentation - CLAUDE.md: intent.deltas signature ownership rule; eidos drift defense doctrine (types over lint); 2026-05-09 hand-off entry. - morfo/README: Typed selector builder section. - eidos/README: linter section reframed as opt-in safety net for plain CSS recipes; the architectural mechanism is compile-time typing. - sema/README: open channel registry + flat cascade docs + override semantics + intent policy const + selector builder discipline. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
@import './components/dialog/dialog.css';
@import './components/drawer/drawer.css';
@import './components/field/field.css';
@import './components/form/form.css';
@import './components/popover/popover.css';
@import './components/tooltip/tooltip.css';
@import './components/progress/progress.css';
@import './components/meter/meter.css';
@import './components/number-field/number-field.css';
@import './components/pagination/pagination.css';
eidos: pilot wrapper pattern + doctrinal API conventions Toggle as the eidos pilot: subdirectory layout (recipe + Svelte wrapper + types + index + README) replacing the flat CSS-only form. Pattern is documented in eidos/components/README.md and the toggle README. Shared types live in eidos/lib/types.ts. First export is `Size` (8 values xxs..xxl + full); components narrow with `Extract<Size, ...>` per the per-component-subset doctrine. No `Eidos` prefix on types — module path already conveys the layer. API doctrine: - soma stays compound (Toggle.Provider) for symmetry with multi-part - eidos exports both default + Provider so single-part components accept both `<Toggle>` (ergonomic) and `<Toggle.Provider>` (compound-style consumers) SoundChannel eager-init fixes the autoplay race: AudioContext is created + resumed synchronously on the first user gesture (capture-phase listener registered in the constructor), avoiding the previous race where the first emit() scheduled the resume in a microtask outside the gesture window. Demo page (web/routes/toggle/+page.svelte) restructured so the live preview renders ALWAYS above the tablist — Sema-tab Play buttons can fire on the real toggle. Motion preview amplifies scale ×8 visually only; doctrinal values stay in the <dl>. Conventions 7-13 added to src/docs/sema-implementation-guide.md covering: directory structure, wrapper composition, no Eidos prefix, soma compound vs eidos flat, iconOnly sr-only body, sound eager-init, docs-preview amplification. CLAUDE.md gets a session hand-off block listing where things stand and next concrete steps (migrate switch/collapsible/dialog/drawer/popover/ toast/avatar; wire topbar sound mute to masterGain; rename theme tokens to drop the success/warning/danger fallback aliases). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
@import './components/toggle/toggle.css';
docs + switch: align active docs to canon, migrate switch to eidos wrapper Phase 4 (docs alignment with the canonical guide): - active_architecture.md — Dialog example refactored to the new event shape (target inside semantic, explicit verb + sequence). Verbs table grouped by family with the post-canon vocabulary (select/ toggle moved to commit, edit removed from handle, new verbs added). Section 10 (Estado actual) updated to 2026-05-08 with current progress: doctrina cerrada, eidos en producción, SoundChannel eager-init, switch migrated, etc. "Para profundizar" §14 points at the canonical guide. - morfo/README.md — Step 5.5 added covering the doctrinal event shape with all fields (semantic.family, .verb, .target, .sequence, .intent) and the two naming shapes ({verb}-{variant} and {family}-{verb}). - sema/README.md — verbs section restructured to Record-by-family matching the runtime; documents the verbs that moved between families per the canon. Naming shapes section updated with both forms and validateEventName signature. - CLAUDE.md — "Session hand-off" rewritten with the post-canon state. Pointer at GUIA_IMPLEMENTACION_SEMAUIX.md as the canonical source. Pending list refreshed: switch is the immediate next component, persistence/a11ySemantic/polymorphism deferred until real consumers appear. Switch migration to the eidos wrapper pattern: - morfo/components/switch.ts — adds events: [{ commit-toggle }] with the doctrinal shape (verb=toggle, sequence=post, intent fromProp binding to the 4 supported intents). New data-* (data-color with the 6-token Toggle/Switch subset, data-readonly, data-invalid, data-required) and corresponding aria-*. scope expanded to ['soma', 'sema']. - soma/components/switch/types.ts — adds intent, color, readonly, invalid, aria-labelledby props with full JSDoc. Subset constrained per guide §3.1 (Toggle/Switch row). - soma/components/switch/switch-provider.svelte.ts — runtime-direct, Field integration via FieldProvider.get(), isDisabled/isReadonly/ isRequired/isInvalid OR-merge derivations, intent ↔ color resolution (intent wins when evaluative), runtime.trigger( 'commit-toggle') in onclick. - soma/components/switch/components/switch.svelte — wires the new props through bindProps. - eidos/components/switch/{switch.css, switch.svelte, types.ts, index.ts, README.md} — full subdirectory pattern, mirroring toggle. Recipe drops legacy success/warning/danger/info selectors; declares the 6 doctrinal data-color values directly. Wrapper auto-renders Switch.Thumb inside the track and exposes an optional `thumb` snippet for in-thumb glyphs. - eidos/components/switch.css (legacy flat) deleted; eidos/index.css updated to import the subdirectory recipe. - web/routes/switch/+page.svelte — interactive testbed with all soma props as live controls + tabs (Live, Soma, Morfo, Sema, Eidos, Notes). Mirrors toggle's structure. npm run check holds at the 39-error baseline. Tests 217/217 green. Pending: - Migrate collapsible / dialog / drawer / popover / toast / avatar to the eidos wrapper pattern. - Persistence + holds-by-intent — defer until first signal.warn / signal.alert consumer. - a11ySemantic + polymorphic events — defer until concrete need. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
@import './components/switch/switch.css';
collapsible: migrate to eidos wrapper pattern (third pilot) Third component migrated to the eidos wrapper subdirectory pattern, following the new "check air baseline first" discipline. Air baseline recovered from commit 0a391408^: - air/components/collapsible: 3 wrappers (Provider/Trigger/Content) with `class` passthrough, `bind:open`, `onOpenChange`, manual `air.interaction.play('expansion', enter|exit)` perceptual emit. - No size, intent, color, or chevron slot. Migration decisions (presented BEFORE coding per scope-approval rule): - Two doctrinal events (`expand` + `collapse`, both emerge family, sequence='pre', no intent — emerge is transitional). Replaces air's manual `air.interaction.play` with `runtime.trigger('expand'| 'collapse')` which atravieses visual + sound + vibra channels. - No intent/color/size — air didn't have them and disclosure is non-evaluative per guide §3.1. - Multi-part API: Provider + Trigger + Content (no flat default per doctrine §10). Files: - src/uix/morfo/components/collapsible.ts: scope expanded to ['soma', 'sema'], events array added with two emerge events. - src/uix/soma/components/collapsible/collapsible-provider.svelte.ts: runtime.events handlers `expand`/`collapse` mutate state; toggle() fires runtime.trigger(next ? 'expand' : 'collapse'). - src/uix/eidos/components/collapsible/{collapsible.css, collapsible-provider.svelte, collapsible-trigger.svelte, collapsible-content.svelte, types.ts, index.ts, README.md}. - src/uix/eidos/components/collapsible.css (legacy flat) deleted. - src/uix/eidos/index.css: import path updated to subdirectory. - web/routes/collapsible/+page.svelte: full interactive testbed with tabs (Live, Soma, Morfo, Sema, Eidos, Notes) mirroring switch's structure. Sema tab shows per-channel signature cards for both expand and collapse events. Disciplina formalizada en CLAUDE.md hand-off + memory entry: "Check air baseline first" before any future eidos migration. Switch shipped without this check and lost ResponsiveProp<Size> (regression). Don't repeat with collapsible/dialog/drawer/popover/toast/avatar. npm run check holds at the 39-error baseline. Tests 218/218 green. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
@import './components/collapsible/collapsible.css';
@import './components/accordion/accordion.css';
@import './components/tabs/tabs.css';
@import './components/checkbox/checkbox.css';
@import './components/radio-group/radio-group.css';
@import './components/rating-group/rating-group.css';
@import './components/search-field/search-field.css';
@import './components/select/select.css';
@import './components/combobox/combobox.css';
@import './components/calendar/calendar.css';
@import './components/date-field/date-field.css';
uix: date-picker + date-range-picker components + component audit infra Two new Eidos components shipped end-to-end (wrapper + recipe + demo + Soma provider hardening) plus a checklist-driven audit pipeline that scores all 67 morfo components against doctrinal completion criteria. New components: - date-picker: full popover-anchored picker over date-field + calendar, with calendar/content/trigger parts and demo route. - date-range-picker: standalone wrapper with own calendar/grid/segment surface, demo route, and recipe CSS. - Both wrappers follow Option C disciplined (root + parts attached via explicit assignment, no Object.assign). Supporting Soma changes: - range-calendar provider tightened (211 LOC of behavior, 167 LOC of tests), README brought up to component doctrine. - date-field, date-picker, date-range-field, date-range-picker Soma providers + READMEs updated for new wrappers. - popover provider/close gain props needed by the picker wrappers. Morfo updates: - date-picker / date-range-picker / range-calendar morfos refined for the new APIs (parts, events, ARIA). Audit infrastructure (new): - src/uix/COMPONENT_COMPLETION_CHECKLIST.md — 81 doctrinal rules across morfo / eidos wrapper / recipe CSS / demo / README / cross-layer scripts. Each rule keyed to active_architecture.md, GUIA_IMPLEMENTACION and DEMO_AUTHORING_GUIDE. - scripts/component-audit.ts + `npm run component:audit` — regex parser over all 67 components, emits tmp/component-audit.md with summary scoreboard + per-component findings. Validates against canonical SEMA_FAMILIES / SEMA_VERBS / ARCHETYPE_VOCABULARY / INTENTS. - Initial baseline: 1 PASS, 64 NEEDS-WORK, 2 BROKEN (tooltip, date-range-picker). Top systemic gaps: translations.label (49), README Gaps/Comparativa/Baseline sections (87 combined), keyboard /event ratio under-declaration (15), apg URL absent (19). Misc: - src/uix/kimi-audit-eidos.md — supplementary audit notes. - .gitignore: ignore .codex-* agent scratch artifacts at repo root. - continue.md + READMEs updated through the migration. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
5 months ago
@import './components/date-picker/date-picker.css';
@import './components/date-range-picker/date-range-picker.css';
@import './components/slider/slider.css';
@import './components/toolbar/toolbar.css';
@import './components/tag-group/tag-group.css';
@import './components/tags-input/tags-input.css';
@import './components/file-upload/file-upload.css';
@import './components/editable/editable.css';
@import './components/stepper/stepper.css';

Powered by TurnKey Linux.