@telepath-computer/television 0.1.216 → 1.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/THIRD-PARTY-NOTICES.txt +336 -0
- package/dist/canonical/v1/frozen.json +6 -0
- package/dist/canonical/v1/styles.css +7 -2
- package/dist/canonical/v2/components.js +1 -0
- package/dist/canonical/v2/fonts/Hind-Variable.933e9900.woff2 +0 -0
- package/dist/canonical/v2/styles.css +1241 -0
- package/dist/cli.cjs +1763 -761
- package/dist/onboarding/README.md +16 -14
- package/dist/onboarding/business-ops/about.html +4 -3
- package/dist/onboarding/business-ops/retention-vs-releases.html +25 -32
- package/dist/onboarding/business-ops/revenue-vs-goals.html +26 -31
- package/dist/onboarding/productivity/about.html +4 -3
- package/dist/onboarding/productivity/company-todos/THIRD-PARTY-NOTICES.txt +29 -0
- package/dist/onboarding/productivity/company-todos/index.html +20 -20
- package/dist/onboarding/productivity/company-todos/task.css +4 -5
- package/dist/onboarding/productivity/company-todos/task.js +1 -1
- package/dist/onboarding/productivity/meeting-prep.html +12 -12
- package/dist/onboarding/productivity/priorities-today.html +10 -10
- package/dist/onboarding/productivity/todays-calendar/calendar.css +1 -1
- package/dist/onboarding/productivity/todays-calendar/index.html +12 -14
- package/dist/onboarding/research/about.html +4 -3
- package/dist/onboarding/research/open-model-research.html +35 -35
- package/dist/onboarding/research/todays-news.html +72 -72
- package/dist/onboarding/tv-guide/welcome.html +178 -0
- package/dist/skills/television/SKILL.md +124 -67
- package/dist/skills/television/theming.md +1086 -0
- package/dist/skills/tv-calendar/SKILL.md +3 -1
- package/dist/skills/tv-calendar/calendar.css +1 -1
- package/dist/skills/tv-table/SKILL.md +5 -2
- package/dist/skills/tv-tasks/SKILL.md +19 -15
- package/dist/skills/tv-tasks/task.css +4 -26
- package/dist/skills/tv-tasks/task.js +1 -1
- package/dist/themes/README.md +5 -0
- package/dist/themes/aquarium/README.md +48 -0
- package/dist/themes/aquarium/iframe-background.js +137 -0
- package/dist/themes/aquarium/manifest.json +7 -0
- package/dist/themes/aquarium/theme.css +46 -0
- package/dist/themes/blueprint/README.md +31 -0
- package/dist/themes/blueprint/manifest.json +6 -0
- package/dist/themes/blueprint/theme.css +115 -0
- package/dist/themes/clouds/README.md +15 -0
- package/dist/themes/clouds/THIRD-PARTY-NOTICES.txt +81 -0
- package/dist/themes/clouds/manifest.json +6 -0
- package/dist/themes/clouds/theme.css +62 -0
- package/dist/themes/clouds/wallpaper-dark.webp +0 -0
- package/dist/themes/clouds/wallpaper.webp +0 -0
- package/dist/themes/crt-phosphor/README.md +31 -0
- package/dist/themes/crt-phosphor/manifest.json +6 -0
- package/dist/themes/crt-phosphor/theme.css +105 -0
- package/dist/themes/nord/README.md +9 -0
- package/dist/themes/nord/THIRD-PARTY-NOTICES.txt +29 -0
- package/dist/themes/nord/manifest.json +5 -0
- package/dist/themes/nord/theme.css +28 -0
- package/dist/themes/swiss/README.md +5 -0
- package/dist/themes/swiss/manifest.json +5 -0
- package/dist/themes/swiss/theme.css +34 -0
- package/dist/themes/tokyo-night/README.md +17 -0
- package/dist/themes/tokyo-night/THIRD-PARTY-NOTICES.txt +235 -0
- package/dist/themes/tokyo-night/manifest.json +5 -0
- package/dist/themes/tokyo-night/theme.css +31 -0
- package/dist/themes/tokyo-night/wallpaper.webp +0 -0
- package/dist/views/artifact-missing/index.html +40 -68
- package/dist/views/markdown/THIRD-PARTY-NOTICES.txt +26 -0
- package/dist/views/markdown/index.html +49 -23
- package/dist/web/THIRD-PARTY-NOTICES.txt +26 -0
- package/dist/web/assets/artifact-bridge-BEUWXKq7.js +1 -0
- package/dist/web/assets/{artifactMissing-BiK_l3Ts.js → artifactMissing-CUs1ZwDx.js} +1 -1
- package/dist/web/assets/main-Bi6QZnn7.css +1 -0
- package/dist/web/assets/main-Dw6rK_zF.js +706 -0
- package/dist/web/assets/{urlUnsupported-RGIrhMDe.js → urlUnsupported-powR79PT.js} +1 -1
- package/dist/web/index.html +40 -5
- package/dist/web/views/artifact-missing/index.html +40 -68
- package/dist/web/views/url-unsupported/index.html +40 -68
- package/package.json +1 -1
- package/dist/onboarding/tv-guide/welcome/assets/television.svg +0 -71
- package/dist/onboarding/tv-guide/welcome/index.html +0 -203
- package/dist/skills/tv-theme/SKILL.md +0 -449
- package/dist/web/assets/artifact-bridge-3Trk-B2L.js +0 -1
- package/dist/web/assets/clouds-CAYIArXj.jpg +0 -0
- package/dist/web/assets/main-Blg8fuaV.css +0 -1
- package/dist/web/assets/main-V14r9Psb.js +0 -596
|
@@ -10,6 +10,8 @@ Television is a persistent artifact channel for agents.
|
|
|
10
10
|
|
|
11
11
|
Load this skill when you need to create, update, inspect, focus, delete, or otherwise manage Television channels and artifacts.
|
|
12
12
|
|
|
13
|
+
Read the [theming guidance](./theming.md) when creating, revising, or bringing an installed theme up to date.
|
|
14
|
+
|
|
13
15
|
Re-read this skill only if it is not already in your context or you know it changed.
|
|
14
16
|
|
|
15
17
|
## When to use Television
|
|
@@ -133,7 +135,7 @@ tv help <command>
|
|
|
133
135
|
|
|
134
136
|
Commands group into four intents:
|
|
135
137
|
|
|
136
|
-
- **Channel and display commands** — create, inspect, remove, or switch channels, or change the active display theme (`create-channel`, `list-channels`, `get-channel`, `remove-channel`, `focus-channel`, `focus-status`, `set-theme`).
|
|
138
|
+
- **Channel and display commands** — create, inspect, rename, remove, or switch channels, or change the active display theme (`create-channel`, `list-channels`, `get-channel`, `update-channel`, `remove-channel`, `focus-channel`, `focus-status`, `set-theme`).
|
|
137
139
|
- **Artifact creation commands** — register path or URL artifacts (`create-path-artifact`, `create-url-artifact`).
|
|
138
140
|
- **Artifact management commands** — inspect, retitle, repoint, focus, list, or delete existing artifacts (`delete-artifact`, `get-artifact`, `list-artifacts`, `update-artifact`, `focus-artifact`).
|
|
139
141
|
- **Server and environment commands** — operate on the Television server itself (`serve`, `status`, `stop`, `storage-path`, `telemetry`, `skills install`).
|
|
@@ -148,7 +150,15 @@ Starting, installing, upgrading, or reconfiguring the server — `tv serve` flag
|
|
|
148
150
|
|
|
149
151
|
## Read vs mutate
|
|
150
152
|
|
|
151
|
-
Read commands print JSON. Workflow commands
|
|
153
|
+
Read commands print JSON. Workflow commands and most mutation commands print plain text. On success, `tv set-theme` prints one of these forms:
|
|
154
|
+
|
|
155
|
+
```text
|
|
156
|
+
Active theme changed from '<previous>' to '<new>'.
|
|
157
|
+
Active theme unchanged: '<selection>'.
|
|
158
|
+
Active theme: '<new>'.
|
|
159
|
+
```
|
|
160
|
+
|
|
161
|
+
The first two forms are available when the opening selection read succeeds. The third confirms activation when that read is unavailable. Theme labels preserve exact installed theme IDs and use `None` for no theme. `tv serve` startup output is human-readable connection text.
|
|
152
162
|
|
|
153
163
|
Use read commands when you need authoritative state for planning or verification. Use mutation commands when you are intentionally changing Television state.
|
|
154
164
|
|
|
@@ -379,12 +389,16 @@ A directory artifact needs root `index.html` or `index.htm`. Keep sibling assets
|
|
|
379
389
|
<script type="module" src="./main.js"></script>
|
|
380
390
|
```
|
|
381
391
|
|
|
382
|
-
Use
|
|
392
|
+
Use Television's canonical artifact stylesheet and record the app version whose canonical surface you authored against:
|
|
383
393
|
|
|
384
394
|
```html
|
|
385
|
-
<link rel="stylesheet" href="/canonical/
|
|
395
|
+
<link rel="stylesheet" href="/canonical/v2/styles.css?authoredForAppVersion=<version>" />
|
|
386
396
|
```
|
|
387
397
|
|
|
398
|
+
Replace `<version>` with the target Television app version. For a running server, read the exact release `version` from `tv status`; when working in a Television checkout, read the exact version from the checkout root `package.json`. Copy that exact release version unchanged into `authoredForAppVersion`. A missing version or the `0.0.0` development sentinel does not identify a release, so omit the metadata.
|
|
399
|
+
|
|
400
|
+
`authoredForAppVersion` is advisory authoring context for a future agent. The server ignores it when serving the stylesheet, so it neither asserts compatibility nor controls whether the artifact loads. Set it when creating an artifact or deliberately re-authoring one against that app surface. Preserve an existing `authoredForAppVersion` value during unrelated maintenance. If you cannot establish the target app version, omit the query parameter; the canonical URL remains valid without it.
|
|
401
|
+
|
|
388
402
|
### Suggested HTML file set
|
|
389
403
|
|
|
390
404
|
For durable HTML artifacts, write nearby documentation so a future agent can maintain the work:
|
|
@@ -483,21 +497,25 @@ If the browser placeholder for an ordinary non-Television URL is not sufficient,
|
|
|
483
497
|
# HTML artifact style
|
|
484
498
|
|
|
485
499
|
Write a complete HTML document for the Television viewer. Load both canonical
|
|
486
|
-
|
|
500
|
+
v2 resources in the document head:
|
|
487
501
|
|
|
488
502
|
```html
|
|
489
|
-
<link rel="stylesheet" href="/canonical/
|
|
490
|
-
<script type="module" src="/canonical/
|
|
503
|
+
<link rel="stylesheet" href="/canonical/v2/styles.css?authoredForAppVersion=<version>">
|
|
504
|
+
<script type="module" src="/canonical/v2/components.js"></script>
|
|
491
505
|
```
|
|
492
506
|
|
|
507
|
+
Replace `<version>` with the Television app version whose canonical surface you
|
|
508
|
+
are authoring against. The Artifact workflow section explains how to find that
|
|
509
|
+
version and when to set, preserve, or omit this advisory query parameter.
|
|
510
|
+
|
|
493
511
|
The stylesheet provides Television's reset, Hind font, public design tokens,
|
|
494
|
-
semantic document defaults, and
|
|
495
|
-
the
|
|
512
|
+
semantic document defaults, and public element styles. The script registers
|
|
513
|
+
the public custom elements. Add local CSS for the artifact's own layout,
|
|
496
514
|
density, hierarchy, and specialized presentation.
|
|
497
515
|
|
|
498
|
-
Lean on semantic HTML first.
|
|
499
|
-
|
|
500
|
-
|
|
516
|
+
Lean on semantic HTML first. Put `text-display="prose"` on a body or section
|
|
517
|
+
to apply readable styling to its headings, paragraphs, lists, links, code
|
|
518
|
+
blocks, blockquotes, rules, images and tables. Rely on those defaults instead of recreating baseline
|
|
501
519
|
typography in each artifact.
|
|
502
520
|
|
|
503
521
|
## Page header
|
|
@@ -515,8 +533,7 @@ Use a `<header>` containing an `<h1>` and, when useful, one `<p>` subtitle:
|
|
|
515
533
|
</header>
|
|
516
534
|
```
|
|
517
535
|
|
|
518
|
-
|
|
519
|
-
heading.
|
|
536
|
+
Use the prose region for document reading rhythm; author any special header treatment locally.
|
|
520
537
|
|
|
521
538
|
For prose-like documents, 32px padding on the top and sides with 64px at the
|
|
522
539
|
bottom is a useful starting point. Adapt it to the document's content and
|
|
@@ -544,66 +561,104 @@ fallback when the artifact should remain readable without the canonical sheet:
|
|
|
544
561
|
Fallbacks are paired: a guarded ground goes with a guarded text color, using
|
|
545
562
|
values that read together.
|
|
546
563
|
|
|
547
|
-
This
|
|
564
|
+
This public inventory is closed. Do not invent token names; when no public
|
|
548
565
|
token expresses a value, use an intentional literal, and when one does, use the
|
|
549
566
|
documented token with a literal fallback where appropriate.
|
|
550
567
|
|
|
551
|
-
###
|
|
552
|
-
|
|
553
|
-
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
-
|
|
558
|
-
`--alpha-400`, `--alpha-500`, `--alpha-600`, `--alpha-700`,
|
|
559
|
-
`--alpha-800`, `--alpha-900`, `--alpha-950`.
|
|
560
|
-
- Blue: `--blue-50`, `--blue-100`, `--blue-200`, `--blue-300`,
|
|
561
|
-
`--blue-400`, `--blue-500`, `--blue-600`, `--blue-700`, `--blue-800`,
|
|
562
|
-
`--blue-900`.
|
|
563
|
-
- Red: `--red-50`, `--red-100`, `--red-200`, `--red-300`, `--red-400`,
|
|
564
|
-
`--red-500`, `--red-600`, `--red-700`, `--red-800`, `--red-900`.
|
|
565
|
-
- Yellow: `--yellow-50`, `--yellow-100`, `--yellow-200`, `--yellow-300`,
|
|
566
|
-
`--yellow-400`, `--yellow-500`, `--yellow-600`, `--yellow-700`,
|
|
567
|
-
`--yellow-800`, `--yellow-900`, `--yellow-950`.
|
|
568
|
-
- Green: `--green-50`, `--green-100`, `--green-200`, `--green-300`,
|
|
569
|
-
`--green-400`, `--green-500`, `--green-600`, `--green-700`,
|
|
570
|
-
`--green-800`, `--green-900`.
|
|
571
|
-
- Orange: `--orange-50`, `--orange-100`, `--orange-200`, `--orange-300`,
|
|
572
|
-
`--orange-400`, `--orange-500`, `--orange-600`, `--orange-700`,
|
|
573
|
-
`--orange-800`, `--orange-900`.
|
|
574
|
-
- Purple: `--purple-50`, `--purple-100`, `--purple-200`, `--purple-300`,
|
|
575
|
-
`--purple-400`, `--purple-500`, `--purple-600`, `--purple-700`,
|
|
576
|
-
`--purple-800`, `--purple-900`.
|
|
577
|
-
- Current-color tints: `--tint-50`, `--tint-100`, `--tint-200`,
|
|
578
|
-
`--tint-300`, `--tint-400`, `--tint-500`, `--tint-600`, `--tint-700`,
|
|
579
|
-
`--tint-800`, `--tint-900`, `--tint-950`.
|
|
580
|
-
|
|
581
|
-
Prefer the semantic roles when they express the intended meaning:
|
|
582
|
-
`--color-text`, `--color-text-muted`, `--color-primary`,
|
|
583
|
-
`--color-on-primary`, `--color-selected`, `--color-link`, `--color-danger`,
|
|
584
|
-
`--color-success`, `--color-warning`, `--color-background`, `--color-surface`,
|
|
585
|
-
`--color-surface-muted`, `--color-border`, and `--color-border-muted`.
|
|
568
|
+
### Fonts
|
|
569
|
+
|
|
570
|
+
`--font-sans`, `--font-mono`, `--font-weight-normal`, `--font-weight-medium`, `--font-weight-semibold`.
|
|
571
|
+
|
|
572
|
+
### Colors
|
|
573
|
+
|
|
574
|
+
`--checkbox-color`, `--panel-background`, `--panel-text-color`, `--panel-border-color`, `--panel-border`, `--panel-edge-highlight`, `--panel-edge-shadow`, `--option-background-highlighted`, `--option-background-active`, `--control-background`, `--control-text-color`, `--control-border-color`, `--control-border-width`, `--control-border`, `--input-placeholder-text-color`, `--neutral`, `--red`, `--orange`, `--yellow`, `--green`, `--cyan`, `--blue`, `--purple`, `--pink`, `--accent`, `--neutral-50`, `--neutral-100`, `--neutral-200`, `--neutral-300`, `--neutral-400`, `--neutral-500`, `--neutral-600`, `--neutral-700`, `--neutral-800`, `--neutral-900`, `--neutral-950`, `--red-50`, `--red-100`, `--red-200`, `--red-300`, `--red-400`, `--red-500`, `--red-600`, `--red-700`, `--red-800`, `--red-900`, `--red-950`, `--orange-50`, `--orange-100`, `--orange-200`, `--orange-300`, `--orange-400`, `--orange-500`, `--orange-600`, `--orange-700`, `--orange-800`, `--orange-900`, `--orange-950`, `--yellow-50`, `--yellow-100`, `--yellow-200`, `--yellow-300`, `--yellow-400`, `--yellow-500`, `--yellow-600`, `--yellow-700`, `--yellow-800`, `--yellow-900`, `--yellow-950`, `--green-50`, `--green-100`, `--green-200`, `--green-300`, `--green-400`, `--green-500`, `--green-600`, `--green-700`, `--green-800`, `--green-900`, `--green-950`, `--cyan-50`, `--cyan-100`, `--cyan-200`, `--cyan-300`, `--cyan-400`, `--cyan-500`, `--cyan-600`, `--cyan-700`, `--cyan-800`, `--cyan-900`, `--cyan-950`, `--blue-50`, `--blue-100`, `--blue-200`, `--blue-300`, `--blue-400`, `--blue-500`, `--blue-600`, `--blue-700`, `--blue-800`, `--blue-900`, `--blue-950`, `--purple-50`, `--purple-100`, `--purple-200`, `--purple-300`, `--purple-400`, `--purple-500`, `--purple-600`, `--purple-700`, `--purple-800`, `--purple-900`, `--purple-950`, `--pink-50`, `--pink-100`, `--pink-200`, `--pink-300`, `--pink-400`, `--pink-500`, `--pink-600`, `--pink-700`, `--pink-800`, `--pink-900`, `--pink-950`, `--accent-50`, `--accent-100`, `--accent-200`, `--accent-300`, `--accent-400`, `--accent-500`, `--accent-600`, `--accent-700`, `--accent-800`, `--accent-900`, `--accent-950`, `--neutral-alpha-5`, `--neutral-alpha-10`, `--neutral-alpha-15`, `--neutral-alpha-25`, `--neutral-alpha-50`, `--neutral-alpha-75`, `--red-alpha-5`, `--red-alpha-10`, `--red-alpha-15`, `--red-alpha-25`, `--red-alpha-50`, `--red-alpha-75`, `--orange-alpha-5`, `--orange-alpha-10`, `--orange-alpha-15`, `--orange-alpha-25`, `--orange-alpha-50`, `--orange-alpha-75`, `--yellow-alpha-5`, `--yellow-alpha-10`, `--yellow-alpha-15`, `--yellow-alpha-25`, `--yellow-alpha-50`, `--yellow-alpha-75`, `--green-alpha-5`, `--green-alpha-10`, `--green-alpha-15`, `--green-alpha-25`, `--green-alpha-50`, `--green-alpha-75`, `--cyan-alpha-5`, `--cyan-alpha-10`, `--cyan-alpha-15`, `--cyan-alpha-25`, `--cyan-alpha-50`, `--cyan-alpha-75`, `--blue-alpha-5`, `--blue-alpha-10`, `--blue-alpha-15`, `--blue-alpha-25`, `--blue-alpha-50`, `--blue-alpha-75`, `--purple-alpha-5`, `--purple-alpha-10`, `--purple-alpha-15`, `--purple-alpha-25`, `--purple-alpha-50`, `--purple-alpha-75`, `--pink-alpha-5`, `--pink-alpha-10`, `--pink-alpha-15`, `--pink-alpha-25`, `--pink-alpha-50`, `--pink-alpha-75`, `--accent-alpha-5`, `--accent-alpha-10`, `--accent-alpha-15`, `--accent-alpha-25`, `--accent-alpha-50`, `--accent-alpha-75`, `--alpha-3`, `--alpha-5`, `--alpha-10`, `--alpha-15`, `--alpha-20`, `--alpha-25`, `--alpha-40`, `--alpha-50`, `--alpha-75`, `--hover-mix`, `--alpha-active`, `--tint-hover`, `--tint-active`, `--icon-check`, `--color-surface`, `--color-surface-muted`, `--color-text`, `--color-text-muted`, `--color-text-reversed`, `--color-border`, `--color-danger`, `--tint-danger`, `--tint-danger-hover`, `--tint-danger-active`, `--color-alert`, `--tint-alert`, `--tint-alert-hover`, `--tint-alert-active`, `--color-success`, `--tint-success`, `--tint-surface`, `--tint-surface-muted`, `--color-primary`, `--tint-primary`, `--tint-primary-hover`, `--tint-primary-active`, `--color-primary-text`, `--outline-focus`, `--control-background-hover`, `--control-background-active`, `--color-primary-hover`, `--color-primary-active`, `--color-danger-hover`, `--color-danger-active`, `--color-alert-hover`, `--color-alert-active`, `--color-link`, `--color-overlay`, `--state-flip`, `--contrast-flip`.
|
|
586
575
|
|
|
587
576
|
### Type
|
|
588
577
|
|
|
589
|
-
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
- Families: `--font-sans`, `--font-mono`.
|
|
593
|
-
- Weights: `--font-weight-normal`, `--font-weight-medium`,
|
|
594
|
-
`--font-weight-body`, `--font-weight-semibold`.
|
|
578
|
+
`--control-font-size`, `--text-base`, `--text-sm`, `--text-md`, `--text-lg`, `--text-xl`, `--text-2xl`, `--text-3xl`, `--text-4xl`, `--line-control`, `--line-control-sm`.
|
|
579
|
+
|
|
580
|
+
### Spacing and radii
|
|
595
581
|
|
|
596
|
-
|
|
582
|
+
`--control-radius`, `--control-padding`, `--space-2`, `--space-3`, `--space-4`, `--space-6`, `--space-8`, `--space-10`, `--space-12`, `--space-16`, `--space-20`, `--space-24`, `--space-32`, `--space-48`, `--space-64`, `--radius-pill`, `--panel-radius`, `--popover-distance`.
|
|
597
583
|
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
584
|
+
### Shadows
|
|
585
|
+
|
|
586
|
+
`--shadow-sm`, `--shadow-md`, `--shadow-lg`, `--shadow-xl`, `--popover-shadow`, `--dialog-shadow`.
|
|
587
|
+
|
|
588
|
+
### Layers
|
|
589
|
+
|
|
590
|
+
`--layer-ground`, `--layer-panel`, `--layer-overlay`.
|
|
604
591
|
|
|
605
592
|
## Canonical components
|
|
606
593
|
|
|
594
|
+
### Native inputs and errors
|
|
595
|
+
|
|
596
|
+
Native text-entry inputs and textareas receive shared styling automatically.
|
|
597
|
+
Supported input types are absent or empty type, `text`, `email`, `url`, `tel`,
|
|
598
|
+
`password` and `number`; search fields and other controls are outside this
|
|
599
|
+
treatment. Give each field an accessible label; a placeholder is only a hint.
|
|
600
|
+
Use `disabled` to disable a field and `readonly` to retain selectable contents
|
|
601
|
+
without editing. Preserve the keyboard focus ring and state styling.
|
|
602
|
+
|
|
603
|
+
When presenting a validation error, set `aria-invalid="true"` and associate
|
|
604
|
+
the message using `aria-describedby`. The foundation supplies the invalid
|
|
605
|
+
border. Use a paragraph with `class="tv-error"` for shared message styling:
|
|
606
|
+
|
|
607
|
+
```html
|
|
608
|
+
<label for="name">Name</label>
|
|
609
|
+
<input id="name" aria-invalid="true" aria-describedby="name-error">
|
|
610
|
+
<p id="name-error" class="tv-error">Enter a name.</p>
|
|
611
|
+
```
|
|
612
|
+
|
|
613
|
+
Explain what needs correcting in text, not color alone. Preserve existing hint
|
|
614
|
+
IDs when adding the error ID to `aria-describedby`. When the error clears,
|
|
615
|
+
remove `aria-invalid` (or set it to `false`), remove only the error ID from
|
|
616
|
+
`aria-describedby`, and remove the message or hide it with native `hidden`.
|
|
617
|
+
Do not mark untouched required fields invalid merely because they are empty.
|
|
618
|
+
|
|
619
|
+
`tv-error` adds no validation, visibility, focus or announcement behavior and
|
|
620
|
+
can also style messages outside inputs. Decide whether an asynchronous error
|
|
621
|
+
needs a live announcement; the class does not imply `role="alert"`.
|
|
622
|
+
|
|
623
|
+
### Popovers, menus and selects
|
|
624
|
+
|
|
625
|
+
Pair a panel with the ID of a trigger button in the same document:
|
|
626
|
+
|
|
627
|
+
```html
|
|
628
|
+
<button id="details">Details</button>
|
|
629
|
+
<tv-popover trigger="details" open>Panel contents</tv-popover>
|
|
630
|
+
<button id="manual-details">Manual details</button>
|
|
631
|
+
<tv-popover trigger="manual-details" manual>Explicitly dismissed contents</tv-popover>
|
|
632
|
+
|
|
633
|
+
<button id="actions">Actions</button>
|
|
634
|
+
<tv-menu trigger="actions" open>
|
|
635
|
+
<tv-menu-item>Rename</tv-menu-item>
|
|
636
|
+
<hr>
|
|
637
|
+
<tv-menu-item intent="danger">Delete</tv-menu-item>
|
|
638
|
+
</tv-menu>
|
|
639
|
+
<button id="manual-actions">Manual actions</button>
|
|
640
|
+
<tv-menu trigger="manual-actions" manual>…</tv-menu>
|
|
641
|
+
|
|
642
|
+
<button id="choice" aria-label="Appearance"></button>
|
|
643
|
+
<tv-select trigger="choice" open>
|
|
644
|
+
<tv-option value="light" selected>Light</tv-option>
|
|
645
|
+
<tv-option value="dark">Dark</tv-option>
|
|
646
|
+
</tv-select>
|
|
647
|
+
```
|
|
648
|
+
|
|
649
|
+
The `open` attribute controls visibility; omit it for the usual closed initial state.
|
|
650
|
+
Popover and menu triggers toggle their panels. Manual popovers and menus require
|
|
651
|
+
explicit closing. Ordinary panels dismiss on outside press or Escape; menus
|
|
652
|
+
also close on item activation and support keyboard navigation and typeahead.
|
|
653
|
+
Author action handlers on the menu items.
|
|
654
|
+
|
|
655
|
+
Menus and popovers prefer below the trigger with left edges aligned, flip toward
|
|
656
|
+
more room when needed, and constrain scrolling within their own document. Selects
|
|
657
|
+
open over the selected row and keep an owning Settings-style popover open. A select
|
|
658
|
+
copies its selected option label to the trigger. Its `value` property reads or sets
|
|
659
|
+
a matching option value; a committed user choice emits `change`. No direction
|
|
660
|
+
attributes or internal classes are part of the authoring API.
|
|
661
|
+
|
|
607
662
|
### Static checkbox lists
|
|
608
663
|
|
|
609
664
|
Use `checkbox-list` and `checkbox-item` for a checklist whose state is authored
|
|
@@ -619,11 +674,11 @@ into the document:
|
|
|
619
674
|
`checked` marks a completed `checkbox-item`. Checked rows render muted and
|
|
620
675
|
struck through, and the marker shows a not-allowed cursor to communicate its
|
|
621
676
|
static nature. The list is presentational and does not toggle when pressed.
|
|
622
|
-
`--checkbox-color`
|
|
677
|
+
The shared `--checkbox-color` token controls checked marker fill and border:
|
|
623
678
|
|
|
624
679
|
```css
|
|
625
|
-
|
|
626
|
-
--checkbox-color: var(--
|
|
680
|
+
:root {
|
|
681
|
+
--checkbox-color: var(--color-success);
|
|
627
682
|
}
|
|
628
683
|
```
|
|
629
684
|
|
|
@@ -654,7 +709,7 @@ The public icon names are:
|
|
|
654
709
|
- `phone`, `web`, `tag`, `bookmark`, `table`, `code`, `group`, `up`, `down`
|
|
655
710
|
- `money`, `bank`, `card`, `wallet`, `gauge`, `activity`, `trend-up`
|
|
656
711
|
- `trend-down`, `database`, `server`, `deploy`, `list`, `terminal`, `branch`
|
|
657
|
-
- `shield`
|
|
712
|
+
- `shield`, `select`
|
|
658
713
|
|
|
659
714
|
Choose a name from this catalog. When the catalog has no suitable glyph, use a
|
|
660
715
|
text label or an emoji.
|
|
@@ -666,3 +721,5 @@ artifact frame. Build responsive layouts from the document's available width
|
|
|
666
721
|
and height. Vertical document scrolling is appropriate for overflow; reserve
|
|
667
722
|
horizontal scrolling for content that needs width, such as a data table or
|
|
668
723
|
timeline.
|
|
724
|
+
|
|
725
|
+
For a native dialog, put its contents in one direct `.dialog-content` child: `<dialog><div class="dialog-content">…</div></dialog>`. Author content layout on that child. It scrolls within the viewport and any authored dialog height or maximum height while the dialog paints its rim and broad shadow. Unwrapped dialogs retain native overflow.
|