@1337exp/taoui 5.30.2 → 5.32.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@1337exp/taoui",
3
- "version": "5.30.2",
3
+ "version": "5.32.0",
4
4
  "description": "Design-token driven Vue 3 / Nuxt component library: palettes with tested contrast, accessible menus and toolbars, navigation that adapts without JS, small charts, built-in locales.",
5
5
  "keywords": [
6
6
  "vue",
@@ -31,6 +31,9 @@ createApp(App).use(TaoUI, { locale: localeRu }).mount('#app') // locale option
31
31
 
32
32
  1. **Colours come from roles**, never hex: `var(--tao-color-text-muted)`, `--tao-color-accent`, `--tao-color-surface`,
33
33
  `--tao-color-border`, `--tao-color-danger`… A hex in app CSS breaks the light mode and every palette.
34
+ **Pick the text step by its job** (patterns.md, "The text ladder"): `text-strong` for headings and the value that is the
35
+ point, `text` for body copy and every control at rest, `text-muted` for hints and captions; hover goes one step up.
36
+ Never paint body copy `strong` to make it important.
34
37
  2. **Status is `tone`**, the same everywhere: `success | danger | warning | info | neutral` (the accent when omitted) on
35
38
  TaoButton, TaoAlert, TaoTag, the stripe of TaoCard / TaoBlock (`stripeTone`), TaoTimeline markers; `toast().danger()`. Say the status in words
36
39
  too: colour alone is not a message.
@@ -85,7 +88,7 @@ choose a text colour, WCAG 2 to promise a number.
85
88
 
86
89
  - Every field takes `size`, `disabled`, `error` (a red frame). The message, the label and the hint go through
87
90
  **`TaoFormField`** (`label`, `hint`, `error`), which also wires `id`, `aria-describedby` and `aria-invalid`.
88
- - `TaoInput`, `TaoTextarea`, `TaoInputNumber`, `TaoQuantity`, `TaoSelect`, `TaoCombobox`, `TaoDate` (`editable` to type `5`, `5.3`, `05.03.26`) / `TaoDateRange`
91
+ - `TaoInput`, `TaoTextarea`, `TaoInputNumber`, `TaoQuantity`, `TaoSelect`, `TaoCombobox`, `TaoPresetInput` (a field with presets and two arrows, e.g. font size or zoom: `options` with `default: true` for «Auto», `loop`, `custom`), `TaoDate` (`editable` to type `5`, `5.3`, `05.03.26`) / `TaoDateRange`
89
92
  (`YYYY-MM-DD` strings), `TaoCalendar` (the inline month calendar, `mode="single" | "range"`), `TaoCheckbox`,
90
93
  `TaoChecklist` (one model for a group), `TaoRadioGroup` + `TaoRadio`, `TaoSwitch`, `TaoSegmented`, `TaoSlider` /
91
94
  `TaoRangeSlider`, `TaoPinCode` (`status="success | error"` after `complete`), `TaoColorInput` / `TaoColorPicker`,
@@ -104,7 +107,8 @@ choose a text colour, WCAG 2 to promise a number.
104
107
  `{ type: 'checkbox' | 'radio', checked }`, `{ type: 'label' | 'separator' }`. `@select="id => …"`. `closeOnScroll`.
105
108
  With TaoUX, `createCommands().toMenu(layout)` builds this tree and binds the same shortcuts.
106
109
  - `TaoToolbar` (one tab stop, arrows walk it) with `TaoToolbarGroup` and `TaoToolbarSeparator`; toggles are
107
- `TaoButton v-model:pressed`, a one-of-many choice inside it is `TaoSegmented`.
110
+ `TaoButton v-model:pressed`, a one-of-many choice inside it is `TaoSegmented`. A bar that must stay one row (an editor, a phone)
111
+ is `<TaoToolbar overflow>`: the groups that do not fit go under a «⋮» button, a `TaoToolbarGroup pinned` never does.
108
112
  - `toast().success().message('Saved')`, `toast().danger().title('Network').timeout(5000).message('…')`,
109
113
  `.action('Undo', fn)`. `await confirm().title('Delete?').message('…').danger()` resolves to a boolean.
110
114
  Their hosts `TaoToastViewport` / `TaoConfirmHost` mount themselves on the first call; place them yourself only to control
@@ -118,7 +122,7 @@ choose a text colour, WCAG 2 to promise a number.
118
122
  `TaoTree` (expand, select, tri-state `checkable`, lazy `load`), `TaoStages`, `TaoTimeline` (`active` makes it a progress),
119
123
  `TaoTag`, `TaoAvatar`, `TaoImage`, `TaoCarousel`, `TaoCard` (`#media`, `#title`, `#sub`, `#footer`, `#corner`, `closable`,
120
124
  `stripe` + `stripeTone`), `TaoBlock`, `TaoTabs`, `TaoBreadcrumb`, `TaoLink`, `TaoStretchedLink` (a whole card or row as one link, the buttons inside still work: `tao-stretched` on the container, `tao-stretched-raise` on a control that must click by itself; never `filter` / `transform` on the link), `TaoSpoiler` / `TaoSpoilerGroup`, `TaoCounter`,
121
- `TaoCopy`, `TaoTour` (a guided tour: `:step` / `:index` / `:count`, events `next` / `prev` / `skip`; it only draws, the state is yours or TaoUX `useTour`; a step is `{ id, target?, title?, text?, placement? }`), `TaoThemeToggle` (the light / dark switch as an icon button: flips `data-tao-mode` of `<html>`, or `v-model` with `:apply="false"`; `#icon="{ mode, next }"` for your own glyph), `TaoMarquee` (one line that runs round only when it does not fit), `TaoScrubber` (play / pause + time),
125
+ `TaoCopy`, `TaoTour` (a guided tour: `:step` / `:index` / `:count`, events `next` / `prev` / `skip`; it only draws, the state is yours or TaoUX `useTour`; a step is `{ id, target?, title?, text?, placement? }`), `TaoThemeToggle` (the light / dark switch as an icon button: flips `data-tao-mode` of `<html>`, or `v-model` with `:apply="false"`; `system` adds a third state, «follow the OS» (click: system → light → dark; `v-model` then holds `'system'` too, resolve it with `resolveTaoMode()`); `#icon="{ mode, choice, next }"` for your own glyph), `TaoMarquee` (one line that runs round only when it does not fit), `TaoScrubber` (play / pause + time),
122
126
  `TaoScrollTop`, `TaoAnimatedBorder`, `TaoIcon`.
123
127
 
124
128
  Small charts only: `TaoSparkline` (a trend), `TaoMeter` (a value in a range, `low` / `high` / `optimum`), `TaoDonut`
@@ -128,7 +132,7 @@ library and feed it `taoChartTheme()` / `watchTaoChartTheme(apply)`; do not buil
128
132
 
129
133
  ## Icons
130
134
 
131
- `<TaoIcon name="tao-check" />`: 42 built-in SVG icons under the `tao-` prefix (incl. `tao-settings`, `tao-edit`, `tao-trash`, `tao-bell`, `tao-tag`, `tao-repeat`, `tao-undo`, `tao-redo`, `tao-sun`, `tao-moon`) (`taoIconNames`). Your own:
135
+ `<TaoIcon name="tao-check" />`: 43 built-in SVG icons under the `tao-` prefix (incl. `tao-settings`, `tao-edit`, `tao-trash`, `tao-bell`, `tao-tag`, `tao-repeat`, `tao-undo`, `tao-redo`, `tao-sun`, `tao-moon`, `tao-monitor`) (`taoIconNames`). Your own:
132
136
  `registerTaoIcons({ rocket: { body: '<path d="…"/>' } })` on a 24 grid with `currentColor`; add `grid: true` for icons made
133
137
  only of straight lines through the middle (a plus), so they stay crisp when small. Any other name renders the class
134
138
  `icon-<name>` for an icon font you bring.