bitboss-ui 3.0.0-beta.75 → 3.0.0-beta.76

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.
Files changed (169) hide show
  1. package/README.md +5 -5
  2. package/bin/cli.mjs +16 -10
  3. package/dist/ai/BbAlert.md +1 -1
  4. package/dist/ai/BbBreadcrumbs.md +1 -1
  5. package/dist/ai/BbButton.md +2 -2
  6. package/dist/ai/BbColorInput.md +1 -1
  7. package/dist/ai/BbColorPalette.md +1 -1
  8. package/dist/ai/BbConfirm.md +1 -1
  9. package/dist/ai/BbDatePicker.md +1 -1
  10. package/dist/ai/BbDatePickerInput.md +1 -1
  11. package/dist/ai/BbDialog.md +3 -2
  12. package/dist/ai/BbDropdown.md +23 -21
  13. package/dist/ai/BbDropdownButton.md +13 -11
  14. package/dist/ai/BbGallery.md +3 -2
  15. package/dist/ai/BbIcon.md +10 -10
  16. package/dist/ai/BbOffCanvas.md +3 -2
  17. package/dist/ai/BbPopover.md +1 -1
  18. package/dist/ai/BbSelect.md +153 -43
  19. package/dist/ai/BbSelectPopover.md +115 -9
  20. package/dist/ai/BbTable.md +1 -1
  21. package/dist/ai/BbTimePicker.md +1 -1
  22. package/dist/ai/BbTimePickerInput.md +1 -1
  23. package/dist/ai/GroupedListBox.md +2 -2
  24. package/dist/ai/ListBox.md +3 -2
  25. package/dist/ai/changelog.json +153 -7
  26. package/dist/ai/components.json +12 -12
  27. package/dist/ai/guides/agent-contract.md +1 -1
  28. package/dist/ai/guides/calendars-and-digits.md +1 -1
  29. package/dist/ai/guides/eslint-rules.md +1 -1
  30. package/dist/ai/guides/icons-policy.md +32 -11
  31. package/dist/ai/guides/installation-and-plugin-setup.md +24 -23
  32. package/dist/ai/guides/migration/adoption-checklist.md +1 -1
  33. package/dist/ai/guides/migration/components/bb-icon.md +4 -4
  34. package/dist/ai/guides/migration/v2-to-v3.md +48 -19
  35. package/dist/ai/guides/migration/v3-beta-css-classes.md +18 -3
  36. package/dist/ai/guides/passthrough.md +58 -58
  37. package/dist/ai/helpers/inertia/manifest.json +1 -1
  38. package/dist/ai/manifest/components/BbDialog.tree.json +1 -1
  39. package/dist/ai/manifest/components/BbDropdown.json +19 -17
  40. package/dist/ai/manifest/components/BbDropdown.tree.json +9 -9
  41. package/dist/ai/manifest/components/BbDropdownButton.json +12 -10
  42. package/dist/ai/manifest/components/BbDropdownButton.tree.json +2 -0
  43. package/dist/ai/manifest/components/BbGallery.tree.json +1 -1
  44. package/dist/ai/manifest/components/BbOffCanvas.tree.json +1 -1
  45. package/dist/ai/manifest/components/BbSelect.json +44 -40
  46. package/dist/ai/manifest/components/BbSelect.tree.json +2 -1
  47. package/dist/ai/manifest/components/BbSelectPopover.json +10 -6
  48. package/dist/ai/manifest/components/BbSelectPopover.tree.json +4 -1
  49. package/dist/ai/manifest/components/BbTable.tree.json +5 -1
  50. package/dist/ai/manifest/components/GroupedListBox.json +1 -1
  51. package/dist/ai/manifest/components/GroupedListBox.tree.json +1 -0
  52. package/dist/ai/manifest/components/ListBox.json +1 -1
  53. package/dist/ai/manifest/components/ListBox.tree.json +1 -1
  54. package/dist/ai/manifest/index.json +2 -2
  55. package/dist/ai/recipes/inertia/inline-edit-workspace.md +1 -1
  56. package/dist/ai/recipes/inertia/onboarding.md +1 -1
  57. package/dist/ai/recipes/nuxt/inline-edit-workspace.md +1 -1
  58. package/dist/ai/recipes/nuxt/onboarding.md +1 -1
  59. package/dist/ai/recipes/vue/inline-edit-workspace.md +1 -1
  60. package/dist/ai/recipes/vue/onboarding.md +2 -2
  61. package/dist/ai/source/BbAccordion.md +4 -5
  62. package/dist/ai/source/BbAvatar.md +9 -2
  63. package/dist/ai/source/BbBadge.md +6 -2
  64. package/dist/ai/source/BbBreadcrumbs.md +5 -2
  65. package/dist/ai/source/BbCalendar.md +8 -6
  66. package/dist/ai/source/BbCarousel.md +10 -6
  67. package/dist/ai/source/BbColorPalette.md +5 -2
  68. package/dist/ai/source/BbDatePickerInput.md +7 -2
  69. package/dist/ai/source/BbDropdown.md +91 -66
  70. package/dist/ai/source/BbDropdownButton.md +36 -19
  71. package/dist/ai/source/BbDropdownGroup.md +91 -66
  72. package/dist/ai/source/BbGallery.md +6 -5
  73. package/dist/ai/source/BbPagination.md +12 -28
  74. package/dist/ai/source/BbRating.md +4 -4
  75. package/dist/ai/source/BbSelect.md +130 -106
  76. package/dist/ai/source/BbSelectPopover.md +128 -21
  77. package/dist/ai/source/BbTable.md +42 -9
  78. package/dist/ai/source/BbTimePickerInput.md +6 -2
  79. package/dist/ai/source/ClearableButton.md +4 -2
  80. package/dist/ai/source/ErrorIcon.md +4 -3
  81. package/dist/ai/source/FlatListBox.md +7 -2
  82. package/dist/ai/source/GroupedListBox.md +22 -3
  83. package/dist/ai/source/ListBox.md +7 -1
  84. package/dist/ai/source/WarningIcon.md +4 -3
  85. package/dist/assets/svgs/close.svg_raw.js +1 -1
  86. package/dist/components/BbAccordion/BbAccordion.vue.d.ts +1 -1
  87. package/dist/components/BbAccordion/BbAccordion.vue_vue_type_script_setup_true_lang.js +35 -34
  88. package/dist/components/BbAvatar/BbAvatar.vue_vue_type_script_setup_true_lang.js +48 -47
  89. package/dist/components/BbBadge/BbBadge.vue_vue_type_script_setup_true_lang.js +60 -59
  90. package/dist/components/BbBreadcrumbs/BbBreadcrumbs.vue_vue_type_script_setup_true_lang.js +128 -127
  91. package/dist/components/BbCalendar/BbCalendar.vue.d.ts +1 -1
  92. package/dist/components/BbCalendar/BbCalendar.vue_vue_type_script_setup_true_lang.js +240 -239
  93. package/dist/components/BbCarousel/BbCarousel.vue_vue_type_script_setup_true_lang.js +500 -499
  94. package/dist/components/BbCheckboxGroup/BbCheckboxGroup.vue.d.ts +4 -4
  95. package/dist/components/BbColorPalette/BbColorPalette.vue_vue_type_script_setup_true_lang.js +175 -174
  96. package/dist/components/BbDatePicker/BbDatePicker.vue.d.ts +1 -1
  97. package/dist/components/BbDatePickerInput/BbDatePickerInput.vue.d.ts +2 -2
  98. package/dist/components/BbDatePickerInput/BbDatePickerInput.vue_vue_type_script_setup_true_lang.js +263 -262
  99. package/dist/components/BbDropdown/AdaptiveDropdown.vue_vue_type_script_setup_true_lang.js +81 -80
  100. package/dist/components/BbDropdown/BbDropdown.vue_vue_type_script_setup_true_lang.js +4 -0
  101. package/dist/components/BbDropdown/BbDropdownList.vue_vue_type_script_setup_true_lang.js +318 -312
  102. package/dist/components/BbDropdown/DropdownRow.vue_vue_type_script_setup_true_lang.js +47 -46
  103. package/dist/components/BbDropdown/ptKeys.generated.d.ts +36 -20
  104. package/dist/components/BbDropdown/types.d.ts +51 -53
  105. package/dist/components/BbDropdown/types.js +2 -0
  106. package/dist/components/BbDropdownButton/BbDropdownButton.vue.d.ts +1 -1
  107. package/dist/components/BbDropdownButton/BbDropdownButton.vue_vue_type_script_setup_true_lang.js +74 -59
  108. package/dist/components/BbDropdownButton/ptKeys.generated.d.ts +111 -63
  109. package/dist/components/BbDropdownButton/types.d.ts +12 -10
  110. package/dist/components/BbDropdownButton/types.js +2 -0
  111. package/dist/components/BbDropzone/BbDropzone.vue.d.ts +1 -1
  112. package/dist/components/BbGallery/BbGallery.vue_vue_type_script_setup_true_lang.js +204 -203
  113. package/dist/components/BbIcon/iconCache.js +1 -1
  114. package/dist/components/BbNumberInput/BbNumberInput.vue.d.ts +1 -1
  115. package/dist/components/BbPagination/BbPagination.vue.d.ts +2 -2
  116. package/dist/components/BbPagination/BbPagination.vue_vue_type_script_setup_true_lang.js +138 -136
  117. package/dist/components/BbProgress/BbProgress.vue.d.ts +1 -1
  118. package/dist/components/BbRadioGroup/BbRadioGroup.vue.d.ts +4 -4
  119. package/dist/components/BbRating/BbRating.vue.d.ts +1 -1
  120. package/dist/components/BbRating/BbRating.vue_vue_type_script_setup_true_lang.js +100 -99
  121. package/dist/components/BbSelect/BbSelect.vue.d.ts +30 -20
  122. package/dist/components/BbSelect/BbSelect.vue_vue_type_script_setup_true_lang.js +201 -184
  123. package/dist/components/BbSelect/ptKeys.generated.d.ts +128 -96
  124. package/dist/components/BbSelect/types.d.ts +101 -105
  125. package/dist/components/BbSelect/types.js +1 -27
  126. package/dist/components/BbSelectPopover/BbSelectPopover.vue.d.ts +6 -3
  127. package/dist/components/BbSelectPopover/BbSelectPopover.vue_vue_type_script_setup_true_lang.js +617 -585
  128. package/dist/components/BbSelectPopover/ptKeys.generated.d.ts +22 -10
  129. package/dist/components/BbSelectPopover/types.d.ts +22 -13
  130. package/dist/components/BbSelectPopover/types.js +3 -1
  131. package/dist/components/BbSwitchGroup/BbSwitchGroup.vue.d.ts +1 -1
  132. package/dist/components/BbTable/BbTable.vue.d.ts +1 -1
  133. package/dist/components/BbTable/BbTable.vue_vue_type_script_setup_true_lang.js +1092 -1090
  134. package/dist/components/BbTable/BbTableDataRow.js +97 -90
  135. package/dist/components/BbTabs/BbTabs.vue.d.ts +3 -3
  136. package/dist/components/BbTimePicker/BbTimePicker.vue.d.ts +2 -2
  137. package/dist/components/BbTimePickerInput/BbTimePickerInput.vue.d.ts +2 -2
  138. package/dist/components/BbTimePickerInput/BbTimePickerInput.vue_vue_type_script_setup_true_lang.js +225 -224
  139. package/dist/components/BbToast/BbToastMessage.vue_vue_type_script_setup_true_lang.js +76 -75
  140. package/dist/components/ClearableButton/ClearableButton.vue_vue_type_script_setup_true_lang.js +9 -8
  141. package/dist/components/CloseIcon/CloseButton.vue.js +1 -1
  142. package/dist/components/CloseIcon/CloseButton.vue_vue_type_script_setup_true_lang.js +9 -7
  143. package/dist/components/ErrorIcon/ErrorIcon.vue_vue_type_script_setup_true_lang.js +8 -6
  144. package/dist/components/FlatListBox/FlatListBox.vue_vue_type_script_setup_true_lang.js +69 -68
  145. package/dist/components/GroupedListBox/GroupedListBox.vue_vue_type_script_setup_true_lang.js +166 -165
  146. package/dist/components/WarningIcon/WarningIcon.vue_vue_type_script_setup_true_lang.js +8 -6
  147. package/dist/composables/useInternalIcon.js +25 -0
  148. package/dist/icon-scan.d.ts +1 -1
  149. package/dist/llms-full.txt +477 -187
  150. package/dist/llms-medium.txt +25 -24
  151. package/dist/llms.txt +1 -1
  152. package/dist/nuxt.js +1 -1
  153. package/dist/styles.css +2 -2
  154. package/dist/types/Config.d.ts +8 -1
  155. package/dist/types/ConfigDefaults.d.ts +10 -2
  156. package/dist/types/internalIcons.d.ts +89 -0
  157. package/dist/types/internalIcons.js +158 -0
  158. package/dist/types/ptComponentMap.d.ts +4 -4
  159. package/dist/utils/configDefaults.js +75 -64
  160. package/dist/utils/iconsOption.js +48 -0
  161. package/dist/utils/versionCheck.js +1 -1
  162. package/dist/vite-plugin.d.ts +10 -16
  163. package/dist/vite.js +319 -306
  164. package/llms.txt +1 -1
  165. package/package.json +1 -1
  166. package/scripts/lib/adoption-checklist.json +1 -1
  167. package/scripts/lib/update-install.mjs +48 -0
  168. package/scripts/lib/validate-bb-markup.mjs +73 -12
  169. package/dist/assets/svgs/caret_down.svg_raw.js +0 -3
package/README.md CHANGED
@@ -34,7 +34,7 @@ Full detail: `dist/ai/guides/installation-and-plugin-setup.md`.
34
34
 
35
35
  ### TypeScript: icons
36
36
 
37
- - **`IconType`** — the type of every icon prop: a plain `prefix:name` string (`lucide:save`, or `local:<name>` for an SVG in `iconDir`). There is no registry to extend; the build plugin ships what your code names (see Icons below).
37
+ - **`IconType`** — the type of every icon prop: a plain `prefix:name` string (`lucide:save`, or `local:<name>` for an SVG in `icons.dir`). There is no registry to extend; the build plugin ships what your code names (see Icons below).
38
38
 
39
39
  ### Composables
40
40
 
@@ -239,7 +239,7 @@ export default defineConfig({
239
239
  plugins: [
240
240
  vue(),
241
241
  bitbossUi({
242
- iconDir: './src/assets/icons',
242
+ icons: { dir: './src/assets/icons' },
243
243
  // Tailwind v4: keep this, or your utilities on Bb* components lose to
244
244
  // the library's CSS. Tailwind v3 or plain CSS: drop it.
245
245
  cssLayers: TAILWIND_V4_LAYERS,
@@ -248,12 +248,12 @@ export default defineConfig({
248
248
  });
249
249
  ```
250
250
 
251
- **Icons, in one paragraph.** `local:` ships every SVG in `iconDir`. Provider
251
+ **Icons, in one paragraph.** `local:` ships every SVG in `icons.dir`. Provider
252
252
  icons (`lucide:*`, `tabler:*`, any installed `@iconify-json/*` set) ship only
253
253
  what the plugin finds as a `prefix:name` literal anywhere in the project — it
254
254
  reads every file under the Vite root as bytes, PHP included, skipping only
255
255
  gitignored, hidden, binary, `node_modules`/`vendor`/`storage`/`outDir` and
256
- `iconsScanner.exclude` paths — plus whatever you list in `iconWhitelist`
256
+ `iconsScanner.exclude` paths — plus whatever you list in `icons.whitelist`
257
257
  (exact names or globs, for names composed at runtime or stored in a database).
258
258
  This holds in dev exactly as in prod: dev registers the same set and re-scans a
259
259
  file on every save. A name that does not resolve renders a built-in placeholder
@@ -269,7 +269,7 @@ import { TAILWIND_V4_LAYERS } from 'bitboss-ui/vite';
269
269
  export default defineNuxtConfig({
270
270
  modules: ['bitboss-ui/nuxt'],
271
271
  bitboss: {
272
- iconDir: './assets/icons',
272
+ icons: { dir: './assets/icons' },
273
273
  cssLayers: TAILWIND_V4_LAYERS, // Tailwind v4 only
274
274
  },
275
275
  });
package/bin/cli.mjs CHANGED
@@ -135,6 +135,7 @@ import { fileURLToPath, pathToFileURL } from 'node:url';
135
135
  import { parseArgs } from 'node:util';
136
136
  import { createRequire } from 'node:module';
137
137
  import { detectPackageManager, mcpLaunch } from '../scripts/lib/mcp-config.mjs';
138
+ import { updateInstallCommand } from '../scripts/lib/update-install.mjs';
138
139
  import { mcpSdkFailureMessage } from '../scripts/lib/mcp-sdk.mjs';
139
140
  import { loadI18n, refreshAgentSetup } from '../scripts/lib/agent-refresh.mjs';
140
141
  import { restartNoteForVersionChange } from '../scripts/lib/setup.mjs';
@@ -168,13 +169,6 @@ function packageVersion() {
168
169
  }
169
170
  }
170
171
 
171
- /** `pnpm add` / `yarn add` / `bun add` / `npm install`, dev or not. */
172
- function addCommand(pm, specs, { dev }) {
173
- const verb = pm === 'npm' ? 'install' : 'add';
174
- const flag = dev ? (pm === 'npm' ? '--save-dev' : '-D') : [];
175
- return [pm, verb, ...[flag].flat(), ...specs];
176
- }
177
-
178
172
  function runPm(argv, cwd) {
179
173
  console.log(`[bitboss-ui] ${argv.join(' ')}`);
180
174
  const result = spawnSync(argv[0], argv.slice(1), {
@@ -259,9 +253,21 @@ async function updateCommand({ install, since, all = false }) {
259
253
  const before = installedBitboss(root);
260
254
  const channel = channelOf(before.version ?? packageVersion());
261
255
  const pm = detectPackageManager(root);
262
- if (
263
- !runPm(addCommand(pm, [`bitboss-ui@${channel}`], { dev: before.dev }), root)
264
- ) {
256
+ // In the app's own pin style: exact stays exact, a local tarball or link
257
+ // is not replaced by a registry version (update-install.mjs).
258
+ const installArgv = updateInstallCommand(pm, {
259
+ declared: before.declared,
260
+ dev: before.dev,
261
+ channel,
262
+ });
263
+ if (!installArgv) {
264
+ console.log(
265
+ `[bitboss-ui] update: bitboss-ui comes from "${before.declared}", a local spec: not reinstalled. Install the version you want, then this refreshes the agent setup.`
266
+ );
267
+ await updateCommand({ install: false, since: undefined, all });
268
+ return;
269
+ }
270
+ if (!runPm(installArgv, root)) {
265
271
  console.error(
266
272
  '[bitboss-ui] update: the install failed, nothing else changed.'
267
273
  );
@@ -148,7 +148,7 @@ styles** — you provide the CSS, setting the same tokens the built-ins use:
148
148
  ```ts
149
149
  // vite.config.ts
150
150
  bitbossUi({
151
- iconDir: './src/icons',
151
+ icons: { dir: './src/icons' },
152
152
  components: { BbAlert: { variants: ['success'] } },
153
153
  });
154
154
  ```
@@ -762,7 +762,7 @@ Set these on the element, or on a class you put on it, to retune this component
762
762
  - `BbBadge` _(public — [contract](./BbBadge.md))_ — its own pt parts (`BbBadge`): `spinner` → `BbSpinner`, `icon` → `span.bb-badge__append-icon`, `icon` → `BbIcon`, `clear` → `button.bb-badge__clear`; documented CSS variables: `--bg`, `--fg`, `--bw`, `--ring-color`, `--ring-size`, `--min-size-md`, `--min-size`, `--elev`, `--r`, `--fs`, `--icon-size`, `--gap`, `--px`, `--clear-size`, `--bg-disabled`, `--fg-disabled`, `--border-disabled`, `--pad-left`; also mounts `BbIcon`, `BbSpinner`, `BadgeBodyContent`
763
763
  - `AdaptiveDropdown` _(internal — not importable, reach it through `BbDropdown`)_ — hands `BbOffCanvas` the pt map `{ header: 'header', footer: 'footer', panel: 'root', sheet: 'root' }` (ours → theirs); also mounts `BbSmoothHeight`, `BbDropdownList`, `DropdownFailures`
764
764
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
765
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
765
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
766
766
  - `BbButton` _(public — [contract](./BbButton.md))_ — its own pt parts (`BbButton`): `root` → `BbBaseButton`, `spinner` → `BbSpinner`, `icon` → `span.bb-button__prepend-icon`, `icon` → `BbIcon`, `text` → `span.bb-button__text`, `icon` → `span.bb-button__append-icon`; documented CSS variables: `--h-xs`, `--h`, `--icon-size`, `--px`, `--ipx`, `--fs`, `--r`, `--gap`, `--bg`, `--bg-hover`, `--bg-pressed`, `--fg`, `--border-color`, `--ring-color`, `--ring-size`, `--bw`, `--fg-hover`, `--border-hover`, `--fg-pressed`, `--border-pressed`, `--bg-disabled`, `--fg-disabled`, `--border-disabled`, `--opacity-disabled`, `--elev-tier`, `--elev`; also mounts `BbBaseButton`, `BbSpinner`, `BbIcon`
767
767
  - Also mounts `BbIcon`
768
768
 
@@ -399,9 +399,9 @@ SSR-safe): `:icon-only="{ default: true, md: false }"` is the icon below
399
399
  as `size`'s do. Icon names come
400
400
  from an installed provider set (e.g. `lucide:*`) or from your own SVGs as
401
401
  `local:<file-name>` (see the icons policy) — a brand mark or a custom glyph is
402
- a `local:` file in your `iconDir`, not a hand-made icon component wrapped in a
402
+ a `local:` file in your `icons.dir`, not a hand-made icon component wrapped in a
403
403
  `BbBaseButton`. The name below stands for your own file: it resolves only if
404
- `brand-mark.svg` sits in your `iconDir` (BbIcon's guide renders a live
404
+ `brand-mark.svg` sits in your `icons.dir` (BbIcon's guide renders a live
405
405
  `local:` demo).
406
406
 
407
407
  ```vue
@@ -827,7 +827,7 @@ Set these on the element, or on a class you put on it, to retune this component
827
827
  - `CommonFieldInput` _(internal — not importable, reach it through `BbColorInput`)_ — `BbColorInput`'s pt parts land here: `box` → `span.bb-field-input__box`, `prefix` → `span.bb-field-input__prefix`, `icon` → `BbIcon`, `clear` → `ClearableButton`, `spinner` → `BbSpinner`, `suffix` → `span.bb-field-input__suffix`; documented CSS variables: `--bg`, `--bg-hover`, `--bg-focus`, `--bg-disabled`, `--fg-disabled`, `--border-color`, `--border-focus`, `--ring-size`, `--ring-color`, `--elev`, `--frost`, `--ph`, `--inside-label-clearance`; also mounts `BbIcon`, `BbSpinner`, `ErrorIcon`, `WarningIcon`, `ClearableButton`
828
828
  - `BbColorPalette` _(public — [contract](./BbColorPalette.md))_ — its own pt parts (`BbColorPalette`): `swatch` → `button.bb-color-palette__swatch`, `panel` → `div`, `panel` → `CommonPopover`; hands `BbOffCanvas` the pt map `{ panel: 'root', sheet: 'root' }` (ours → theirs); documented CSS variables: `--edge`; also mounts `BbIcon`, `CommonPopover`
829
829
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
830
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
830
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
831
831
 
832
832
  ## See Also
833
833
 
@@ -834,7 +834,7 @@ Set these on the element, or on a class you put on it, to retune this component
834
834
 
835
835
  - `BbColorPalette` _(this component)_ — its own template binds: `swatch` → `button.bb-color-palette__swatch`, `panel` → `div`, `panel` → `CommonPopover`; hands `BbOffCanvas` the pt map `{ panel: 'root', sheet: 'root' }` (ours → theirs)
836
836
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
837
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
837
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
838
838
  - Also mounts `BbIcon`, `CommonPopover`
839
839
 
840
840
  ## See Also
@@ -794,7 +794,7 @@ States are listed in precedence order: when two are on at once and their entries
794
794
 
795
795
  - `BbConfirm` _(this component)_ — its own template binds: `action` → `BbDialog`, `text` → `div.bb-confirm__text`; hands `BbDialog` the pt map `passthrough.forward(DIALOG_PARTS, BB_DIALOG_PT.states)` (ours → theirs)
796
796
  - `BbDialog` _(public — [contract](./BbDialog.md))_ — its own pt parts (`BbDialog`): `header` → `div.bb-dialog__header`, `title` → `span.bb-dialog__title`, `description` → `p.bb-dialog__description`, `close` → `CloseButton`, `content` → `div.bb-dialog__content`, `footer` → `div.bb-dialog__footer`; hands `BbOffCanvas` the pt map `{ root: 'root', header: 'header', title: 'title', description: 'description', content: 'content', footer: 'footer', close: 'close', sheet: 'root', }` (ours → theirs); documented CSS variables: `--px`, `--close-size`
797
- - `CloseButton` _(internal — not importable, reach it through `BbDialog`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
797
+ - `CloseButton` _(internal — not importable, reach it through `BbDialog`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
798
798
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`; also mounts `CloseButton`
799
799
 
800
800
  ## See Also
@@ -604,7 +604,7 @@ Set these on the element, or on a class you put on it, to retune this component
604
604
  - `BbBaseButton` _(public — [contract](./BbBaseButton.md))_ — its own pt parts (`BbBaseButton`): `root` → `RouterComponent`, `root` → `a`, `root` → `component`; also mounts `RouterComponent`
605
605
  - `CommonTimeSelector` _(internal — not importable, reach it through `BbCalendar`)_ — its own pt parts (`BbCalendar`): `header` → `div.bb-time-selector__header`, `cellColumnHeader` → `div.bb-time-selector__cell-column-header`, `item` → `BbBaseButton`; documented CSS variables: `--time-mark`; also mounts `BbBaseButton`
606
606
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
607
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
607
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
608
608
  - Also mounts `CommonPopover`
609
609
 
610
610
  ## See Also
@@ -1157,7 +1157,7 @@ Set these on the element, or on a class you put on it, to retune this component
1157
1157
  - `BbBaseButton` _(public — [contract](./BbBaseButton.md))_ — its own pt parts (`BbBaseButton`): `root` → `RouterComponent`, `root` → `a`, `root` → `component`; also mounts `RouterComponent`
1158
1158
  - `CommonTimeSelector` _(internal — not importable, reach it through `BbCalendar`)_ — its own pt parts (`BbCalendar`): `header` → `div.bb-time-selector__header`, `cellColumnHeader` → `div.bb-time-selector__cell-column-header`, `item` → `BbBaseButton`; documented CSS variables: `--time-mark`; also mounts `BbBaseButton`
1159
1159
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
1160
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
1160
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
1161
1161
  - `CommonField` _(internal — not importable, reach it through `BbDatePickerInput`)_ — `BbDatePickerInput`'s pt parts land here: `root` → `div.bb-field`, `label` → `component`, `description` → `span.bb-field__description`, `hint` → `span.bb-field__hint`, `counter` → `span.bb-field__counter`, `message` → `div.bb-field__message`; also mounts `BbAsterisk`
1162
1162
  - `CommonFieldInput` _(internal — not importable, reach it through `BbDatePickerInput`)_ — `BbDatePickerInput`'s pt parts land here: `box` → `span.bb-field-input__box`, `prefix` → `span.bb-field-input__prefix`, `icon` → `BbIcon`, `clear` → `ClearableButton`, `spinner` → `BbSpinner`, `suffix` → `span.bb-field-input__suffix`; documented CSS variables: `--bg`, `--bg-hover`, `--bg-focus`, `--bg-disabled`, `--fg-disabled`, `--border-color`, `--border-focus`, `--ring-size`, `--ring-color`, `--elev`, `--frost`, `--ph`, `--inside-label-clearance`; also mounts `BbIcon`, `BbSpinner`, `ErrorIcon`, `WarningIcon`, `ClearableButton`
1163
1163
  - Also mounts `BbIcon`
@@ -30,7 +30,8 @@
30
30
  | --- | --- | --- | --- |
31
31
  | `--size` | `pt:close` | `CloseButton` | the button box — the hit target, not the glyph |
32
32
  | `--p` | `pt:close` | `CloseButton` | padding inside that box; what is left of --size is the glyph |
33
- | `--icon-size` | `pt:close` | `CloseButton` | Glyph: whatever the padding leaves, but never under 10px — a tight --size with the default padding would otherwise collapse it. Declared here, not on the svg: the glyph is a BbIcon, whose own `--size` local would shadow the button's there. |
33
+ | `--icon-size` | `pt:close` | `CloseButton` | Glyph: the ✕ is drawn on a 24 grid with a stock icon's proportions (its ink spans 12 of the 24 units, as Lucide's, Tabler's and Phosphor's do), so any set's ✕ can stand in. Its box is what the padding leaves × 22/12: the ink then spans what the old edge-to-edge glyph painted, the same optical size in the same button box (the extra box overflows the padding, unpainted). Never under 10px — a tight --size with the default padding would otherwise collapse it. Declared here, not on the svg: the glyph is a BbIcon, whose own `--size` local would shadow the button's there. |
34
+ | `--icon-inset` | `pt:close` | `CloseButton` | Centres that larger box on the padding box (negative: it overflows it evenly). Resolved here for the same `--size` reason. |
34
35
 
35
36
  ## Usage & Guidelines
36
37
 
@@ -1952,7 +1953,7 @@ Set these on the element, or on a class you put on it, to retune this component
1952
1953
  - Listed nodes are the ones `BbDialog`'s API reaches or that declare a documented CSS variable; the rest fold into "also mounts". The complete tree, undocumented locals included, is `manifest/components/BbDialog.tree.json` (a public component in it is a name: its own tree file has the rest).
1953
1954
 
1954
1955
  - `BbDialog` _(this component)_ — its own template binds: `header` → `div.bb-dialog__header`, `title` → `span.bb-dialog__title`, `description` → `p.bb-dialog__description`, `close` → `CloseButton`, `content` → `div.bb-dialog__content`, `footer` → `div.bb-dialog__footer`; hands `BbOffCanvas` the pt map `{ root: 'root', header: 'header', title: 'title', description: 'description', content: 'content', footer: 'footer', close: 'close', sheet: 'root', }` (ours → theirs)
1955
- - `CloseButton` _(internal — not importable, reach it through `BbDialog`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
1956
+ - `CloseButton` _(internal — not importable, reach it through `BbDialog`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
1956
1957
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`; also mounts `CloseButton`
1957
1958
 
1958
1959
  ## See Also
@@ -1253,7 +1253,7 @@ What each knob does:
1253
1253
  plain menu group (`'interaction'`, the default, fetches when the group is
1254
1254
  first reached; `true` fetches on mount).
1255
1255
  - **`minQueryLength`** (as on `BbSelect`): below that many characters
1256
- (trimmed) the query counts as empty, so no `'search'` call and no filtering
1256
+ (after trimming; an emoji is one) the query counts as empty, so no `'search'` call and no filtering
1257
1257
  run, and the field says how many characters to type (on a search-first
1258
1258
  group, its hint row too: "Type at least 2 characters"). Slots still get the
1259
1259
  typed `query`. No guard in the getter:
@@ -2048,8 +2048,8 @@ sheet alike; its magnifier is chrome),
2048
2048
  resolved per entry — and `itemText` / `itemIcon` / `itemDescription`, that
2049
2049
  entry's label, its prepend / append icons and its muted second line (the item's
2050
2050
  `label` / `prepend:icon` · `append:icon` / `description`), resolved with the entry's
2051
- states (a per-entry `#<value>` slot replaces the label and description), and `check`, the tick at the end of a selectable group's checked entry (a row slot never replaces it; `pt:check="hidden"` drops it and leaves a mark your slot draws alone), and `submenu`, every submenu's flyout box at any depth (desktop: a phone sheet drills into submenus in place, so style what you see there with `panel`). States: `open`, and `selected` / `disabled` per entry.
2052
- Groups, headings and dividers are not parts.
2051
+ states (a per-entry `#<value>` slot replaces the label and description), `groupLabel` (every group's label row: its `label` and icons, the row an `onClick` group activates; `#<id>:label` replaces its content) and `groupHeader` (every `groupBy` heading, sticky; `#group` / `#<id>:group` replace its content), and `check`, the tick at the end of a selectable group's checked entry (a row slot never replaces it; `pt:check="hidden"` drops it and leaves a mark your slot draws alone), and `submenu`, every submenu's flyout box at any depth (desktop: a phone sheet drills into submenus in place, so style what you see there with `panel`). States: `open`, and `selected` / `disabled` per entry.
2052
+ A group's items box and the dividers are not parts.
2053
2053
 
2054
2054
  The invoice View menu, restyled through those parts: a muted wash on
2055
2055
  `pt:header` and on `pt:item:selected` (per entry), muted
@@ -2502,15 +2502,15 @@ it, and at the top level closes the sheet.
2502
2502
 
2503
2503
  | Prop | Type | Default | Required | Description |
2504
2504
  | --- | --- | --- | --- | --- |
2505
- | `pt:<part>`, `pt:<part>:<state>`, `pt` | `PtValue` | | | Passthrough — a class list, or `{ class, style, attrs }`, bound to one named part of the component; the state form applies only while that state is on. Parts: `box`, `check`, `footer`, `header`, `input`, `item`, `itemDescription`, `itemIcon`, `itemText`, `list`, `panel`, `root`, `sheet`, `submenu`. States: `open`, `activeLink`, `default`, `destructive`, `disabled`, `exactActiveLink`, `selected`. What each one is: _Passthrough parts and states_ below. `pt` is the object form with the same keys minus the prefix (`{ icon: '…', 'icon:loading': '…' }`). See `guides/passthrough.md`. In `<script>` a `pt` value is typed `BbDropdownProps['pt']` (`PtValue` is not exported): § Typing `pt` in `<script>`. |
2505
+ | `pt:<part>`, `pt:<part>:<state>`, `pt` | `PtValue` | | | Passthrough — a class list, or `{ class, style, attrs }`, bound to one named part of the component; the state form applies only while that state is on. Parts: `box`, `check`, `footer`, `groupHeader`, `groupLabel`, `header`, `input`, `item`, `itemDescription`, `itemIcon`, `itemText`, `list`, `panel`, `root`, `sheet`, `submenu`. States: `open`, `activeLink`, `default`, `destructive`, `disabled`, `exactActiveLink`, `selected`. What each one is: _Passthrough parts and states_ below. `pt` is the object form with the same keys minus the prefix (`{ icon: '…', 'icon:loading': '…' }`). See `guides/passthrough.md`. In `<script>` a `pt` value is typed `BbDropdownProps['pt']` (`PtValue` is not exported): § Typing `pt` in `<script>`. |
2506
2506
  | `activator` | `ElementOrComponentRef \| undefined` | | | An external activator (element or component ref): the slot isn't rendered; the listeners and ARIA (`aria-haspopup` / `aria-expanded` / `aria-controls`) go on it, so don't add your own. |
2507
- | `adaptive` | `boolean \| undefined` | ``all.adaptive` (`true`)` | | On mobile (below `config.mobileMaxWidth`), renders the menu as a bottom sheet that drills into submenus one level at a time instead of hover flyouts; slots and selection are unchanged. Unset: the global `all.adaptive`. |
2507
+ | `adaptive` | `boolean \| undefined` | ``all.adaptive` (`true`)` | | On mobile (below `config.mobileMaxWidth`), the menu is a bottom sheet drilling into submenus a level at a time, not hover flyouts; slots and selection unchanged. Unset: the global `all.adaptive`. |
2508
2508
  | `anchor` | `ElementOrComponentRef \| VirtualAnchor \| undefined` | `the activator element` | | What the panel positions against instead of the activator (e.g. a wrapper around it): an element, a component ref or a virtual box. It also sets a percentage `width`. Ignored with `placement="cursor"`. |
2509
- | `boundary` | `string \| ElementOrComponentRef \| undefined` | | | Keeps the panel inside this element beside its trigger (sideways under a menu); away from it only the viewport flips it. An element, component ref or CSS selector (a `useTemplateRef`, not `$refs.x`). Default in a `BbTable`: the table's left and right edges. |
2510
- | `closeOnSelect` | `boolean \| undefined` | `unset (close after a single-choice change)` | | Whether a selection closes the menu. Unset: a change in a single-choice group closes it (an untick too, at any depth); a `multiple` group stays open. `true`: every selection change closes it. `false`: none does. |
2511
- | `compact` | `boolean \| undefined` | `undefined` | | Compact density, the `BbSelect` ladder: flyout rows 28px → 24px, sheet rows 44px → 36px (a sheet row stays a touch target). The label size does not change. |
2509
+ | `boundary` | `string \| ElementOrComponentRef \| undefined` | | | Keeps the panel inside this element beside its trigger (sideways under a menu); away from it only the viewport flips it. An element, component ref or CSS selector (a `useTemplateRef`, not `$refs.x`). In a `BbTable`: its left and right edges. |
2510
+ | `closeOnSelect` | `boolean \| undefined` | `unset (close after a single-choice change)` | | Whether a selection closes the menu. Unset: a single-choice group's change closes it (an untick too, any depth), a `multiple` group stays open. `true`: every change closes it; `false`: none. |
2511
+ | `compact` | `boolean \| undefined` | `undefined` | | Compact density, the `BbSelect` ladder: flyout rows 28 → 24px, sheet rows 44 → 36px (still a touch target). The label size stays. |
2512
2512
  | `disabled` | `boolean \| undefined` | `false` | | Disables the component |
2513
- | `eager` | `boolean \| undefined` | `false` | | Renders the menu panel at mount instead of on the first open (the phone sheet's too), and keeps its rows after a close. Without it the rows mount on each open and go once the menu has closed. |
2513
+ | `eager` | `boolean \| undefined` | `false` | | Renders the panel (the phone sheet's too) at mount, not on the first open, and keeps its rows after a close; otherwise rows mount on each open and go after the close. |
2514
2514
  | `emptyText` | `string \| undefined` | | | A pipeline group's no-items row; its own `emptyText` wins. Default: `common.emptyText`. |
2515
2515
  | `enforceCoherence` | `boolean \| undefined` | `false` | | Default for pipeline groups: drop selections that are no longer present in a group's current items (e.g. after a `dependencies` re-fetch) from the selection and `v-model`. A group's own `enforceCoherence` overrides this. |
2516
2516
  | `failedText` | `string \| undefined` | | | A pipeline group's failed-load row (its getter threw); its own `failedText` wins. Default: `common.failedText`. |
@@ -2524,8 +2524,8 @@ it, and at the top level closes the sheet.
2524
2524
  | `padding` | `number \| undefined` | `10` | | Minimum empty space to keep from the edge of the page |
2525
2525
  | `placement` | `'start'` \| `'end'` \| `'top'` \| `'bottom'` \| `'left'` \| `'right'` \| `'top-start'` \| `'top-end'` \| `'right-start'` \| `'right-end'` \| `'bottom-start'` \| `'bottom-end'` \| `'left-start'` \| `'left-end'` \| `'start-start'` \| `'start-end'` \| `'end-start'` \| `'end-end'` \| `'cursor'` | `"bottom"` | | Position relative to the activator; `'cursor'` anchors at the mouse/touch point. No arrow (tooltips only). |
2526
2526
  | `queryDebounceTime` | `number \| undefined` | `300` | | Debounce (ms) applied to the async re-fetch a `searchable` group fires as the user types. Applies to every searchable group in the menu. |
2527
- | `transitionDuration` | `number \| undefined` | `150` | | The open / close transition in milliseconds. Menus take the fast one (150), not the popovers' medium 250: a menu is picked from and gone, so it answers faster than a panel you read or edit in. |
2528
- | `trigger` | `DropdownTrigger \| DropdownTrigger[] \| undefined` | `"click"` | | Interaction(s) that open the dropdown. Accepts a single trigger or an array to combine them. - `'click'` — left-click / tap (default) - `'contextMenu'` — right-click on desktop, long-press on mobile |
2527
+ | `transitionDuration` | `number \| undefined` | `150` | | The open / close transition (ms). Menus take the fast 150, not the popovers' 250: a menu is picked from and gone, quicker than a panel you read or edit. |
2528
+ | `trigger` | `DropdownTrigger \| DropdownTrigger[] \| undefined` | `"click"` | | What opens the menu, one or an array: `'click'` (left-click / tap) or `'contextMenu'` (right-click; long-press on mobile). |
2529
2529
  | `width` | `string \| number \| undefined` | `"auto"` | | Width of the dropdown in pixels, percentage, or 'auto' to fit content. |
2530
2530
 
2531
2531
  ## Passthrough parts and states
@@ -2534,18 +2534,20 @@ it, and at the top level closes the sheet.
2534
2534
 
2535
2535
  | Part | What it is |
2536
2536
  | --- | --- |
2537
- | `root` | The floating element — an invisible positioning wrapper; a `class` on the component lands here. No node on the phone sheet: style what you see with `panel`. |
2537
+ | `root` | The floating element, an invisible positioning wrapper; a `class` on the component lands here. No node on the phone sheet (style `panel` there). |
2538
2538
  | `panel` | The menu surface you see — the bordered flyout box on desktop, the sheet itself on a phone. |
2539
- | `sheet` | The bottom sheet the menu becomes on a phone (the `BbOffCanvas` root) — never the desktop surface. Applied after `panel`, so it wins a conflict there. |
2539
+ | `sheet` | The phone's bottom sheet (the `BbOffCanvas` root), never the desktop surface; applied after `panel`, so it wins a conflict. |
2540
2540
  | `header` | The menu's header band. |
2541
2541
  | `footer` | The menu's footer band. |
2542
2542
  | `box` | Every searchable group's search box (field and magnifier), as `box` on a field; desktop and phone. |
2543
- | `input` | A searchable group's search field — a broadcast: it lands on every searchable group's field, desktop and phone alike. Its magnifier glyph is chrome. |
2544
- | `list` | The top-level items container between the bands — the node that lays the entries out (a flex column with a 1px gap; on a phone, the sheet's items container). A submenu's list is not reached. Groups, headings and dividers are not parts. |
2543
+ | `input` | Every searchable group's search field, desktop and phone alike. Its magnifier glyph is chrome. |
2544
+ | `list` | The top-level entries' container between the bands (a flex column, 1px gap; on a phone, the sheet's). A submenu's list is not reached. |
2545
+ | `groupLabel` | Every group's label row (its `label` and icons; the row an `onClick` group activates). `#<id>:label` replaces its content. |
2546
+ | `groupHeader` | Every `groupBy` heading (sticky). `#group` / `#<id>:group` replace its content. |
2545
2547
  | `item` | One menu entry, submenus included — a broadcast resolved per entry. Also takes a per-item function, called with the entry. |
2546
2548
  | `itemText` | An entry's label (its `label`) — resolved with that entry's states. A per-entry `#<value>` slot replaces it. Also takes a per-item function. |
2547
2549
  | `itemIcon` | An entry's prepend / append icons — resolved with that entry's states. Also takes a per-item function. |
2548
- | `itemDescription` | An entry's muted second line (its `description`) — resolved with that entry's states. A per-entry `#<value>` slot replaces it. Also takes a per-item function. |
2550
+ | `itemDescription` | An entry's muted second line (its `description`), with the entry's states. A per-entry `#<value>` slot replaces it. Also takes a per-item function. |
2549
2551
  | `check` | A checked entry's tick, outside the row slots: `pt:check="hidden"` spares your own glyph. Also takes a per-item function. |
2550
2552
  | `submenu` | Every submenu's flyout box (desktop only). Also takes a per-item function, called with the entry that opens it. |
2551
2553
 
@@ -2553,7 +2555,7 @@ States are listed in precedence order: when two are on at once and their entries
2553
2555
 
2554
2556
  | State | When it is on |
2555
2557
  | --- | --- |
2556
- | `activeLink` | Per node, on the entry parts: an entry whose link (`to` / `href`) points at the current page or one of its ancestors — exactly when its `activeClass` is on. The weakest state. |
2558
+ | `activeLink` | Per node, on the entry parts: an entry whose link (`to` / `href`) is the current page or an ancestor (its `activeClass` is on). The weakest state. |
2557
2559
  | `exactActiveLink` | Per node, on the entry parts: an entry whose link points at the current page itself — its `exactActiveClass` is on. |
2558
2560
  | `selected` | Per node, on the entry parts: a selectable group's checked entry. |
2559
2561
  | `disabled` | Per node, on the entry parts: an entry that is disabled. |
@@ -2565,7 +2567,7 @@ States are listed in precedence order: when two are on at once and their entries
2565
2567
 
2566
2568
  - `hidden` — `(): void` — Emitted once the menu has finished closing.
2567
2569
  - `hide` — `(): void` — Emitted as soon as the menu starts to close.
2568
- - `item:selected` — `(value: any): void` — The user selected a row in a selectable group, at the click — also when a controlled companion's app then refuses the value. The payload is the row's value (its `item-value` for pipeline groups, else its `value`).
2570
+ - `item:selected` — `(value: any): void` — The user selected a row in a selectable group, at the click, even when a controlled companion's app then refuses it. Payload: the row's value (`item-value` for pipeline groups, else `value`).
2569
2571
  - `item:unselected` — `(value: any): void` — The user unselected a row (a multiple toggle, a `clearable` re-click, a chip ×, or the old value a single pick replaces). Payload is the item's resolved value, matching `item:selected`.
2570
2572
  - `show` — `(): void` — Emitted as soon as the menu (the popover, or the sheet on a phone) starts to open.
2571
2573
  - `shown` — `(): void` — Emitted once the menu is open and its open transition has finished.
@@ -2575,11 +2577,11 @@ States are listed in precedence order: when two are on at once and their entries
2575
2577
 
2576
2578
  - `activator` — scope: `BbDropdownActivatorSlotProps` `{ disabled?: boolean; empty: boolean; loading: boolean; open: boolean; placement: Placement \| "cursor"; props: BbDropdownActivatorProps }` — The element that triggers the dropdown to open. Spread `props` onto your trigger element.
2577
2579
  - `default` — scope: `any` — Hosts `<BbDropdownGroup>` companions. They register their group with the dropdown and render nothing themselves.
2578
- - `empty` — scope: `BbDropdownPlaceholderSlotProps` `{ groupId?: string; query: string; text: string }` — Replaces the default "no data" placeholder row shown in a pipeline group that resolved to no items. Rendered once per empty group. A failed load is not empty: it keeps its own row (the error icon and `failedText`).
2580
+ - `empty` — scope: `BbDropdownPlaceholderSlotProps` `{ groupId?: string; query: string; text: string }` — Replaces the placeholder row of a pipeline group that resolved to no items, once per empty group. A failed load is not empty: it keeps its own row (error icon, `failedText`).
2579
2581
  - `footer` — scope: `BbDropdownEdgeSlotProps` `{ disabled?: boolean; open: boolean; placement: Placement \| "cursor" }` — Pinned below the rows, outside their scroll, with a divider — for action buttons.
2580
2582
  - `group` — scope: `BbDropdownGroupSlotProps` `{ text: string; item: unknown; index: number; length: number; disabled: boolean }` — Every group's `groupBy` headings (`BbSelect`'s `#group` scope); `#<groupId>:group` beats it.
2581
2583
  - `header` — scope: `BbDropdownEdgeSlotProps` `{ disabled?: boolean; open: boolean; placement: Placement \| "cursor" }` — Pinned above the rows, outside their scroll, with a divider — for a title or a filter field.
2582
- - `item:append` — scope: `BbDropdownItemSlotProps` `{ description?: string; disabled?: boolean; group: BbDropdownSlotGroup; groupTitle: boolean; level: number; index: number; item: InternalItem; loading: boolean; open: boolean; placement: Placement \| "cursor"; selected: boolean; label: string; activeLink?: boolean; exactActiveLink?: boolean }` — The trailing region of every row (and group title line), replacing its `append:icon` wherever it renders. A named slot wins; the submenu chevron and the check on a selected row take its place.
2584
+ - `item:append` — scope: `BbDropdownItemSlotProps` `{ description?: string; disabled?: boolean; group: BbDropdownSlotGroup; groupTitle: boolean; level: number; index: number; item: InternalItem; loading: boolean; open: boolean; placement: Placement \| "cursor"; selected: boolean; label: string; activeLink?: boolean; exactActiveLink?: boolean }` — The trailing region of every row (and group label), replacing its `append:icon` wherever it renders. A named slot wins; a submenu chevron or a selected row's check takes its place.
2583
2585
  - `item:prepend` — scope: `BbDropdownItemSlotProps` `{ description?: string; disabled?: boolean; group: BbDropdownSlotGroup; groupTitle: boolean; level: number; index: number; item: InternalItem; loading: boolean; open: boolean; placement: Placement \| "cursor"; selected: boolean; label: string; activeLink?: boolean; exactActiveLink?: boolean }` — The leading region of every row (and group title line), replacing its `prepend:icon` wherever it renders. A named slot wins.
2584
2586
  - `loading` — scope: `BbDropdownPlaceholderSlotProps` `{ groupId?: string; query: string; text: string }` — Replaces the default loading placeholder row shown in a pipeline group while its async items load. Rendered once per loading group.
2585
2587
  - `#<value>` (named from data) — scope: `BbDropdownItemSlotProps` — One row's content (label and description), by its value; in a fetched group, by its resolved `itemValue`. Reserved names (their slot is one of this component's own, so an item value or column key spelled like them is an error): `activator`, `default`, `empty`, `footer`, `group`, `header`, `item`, `loading`.
@@ -2616,7 +2618,7 @@ Set these on the element, or on a class you put on it, to retune this component
2616
2618
  - `BbBadge` _(public — [contract](./BbBadge.md))_ — its own pt parts (`BbBadge`): `spinner` → `BbSpinner`, `icon` → `span.bb-badge__append-icon`, `icon` → `BbIcon`, `clear` → `button.bb-badge__clear`; documented CSS variables: `--bg`, `--fg`, `--bw`, `--ring-color`, `--ring-size`, `--min-size-md`, `--min-size`, `--elev`, `--r`, `--fs`, `--icon-size`, `--gap`, `--px`, `--clear-size`, `--bg-disabled`, `--fg-disabled`, `--border-disabled`, `--pad-left`; also mounts `BbIcon`, `BbSpinner`, `BadgeBodyContent`
2617
2619
  - `AdaptiveDropdown` _(internal — not importable, reach it through `BbDropdown`)_ — hands `BbOffCanvas` the pt map `{ header: 'header', footer: 'footer', panel: 'root', sheet: 'root' }` (ours → theirs); also mounts `BbSmoothHeight`, `BbDropdownList`, `DropdownFailures`
2618
2620
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
2619
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
2621
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
2620
2622
  - `BbButton` _(public — [contract](./BbButton.md))_ — its own pt parts (`BbButton`): `root` → `BbBaseButton`, `spinner` → `BbSpinner`, `icon` → `span.bb-button__prepend-icon`, `icon` → `BbIcon`, `text` → `span.bb-button__text`, `icon` → `span.bb-button__append-icon`; documented CSS variables: `--h-xs`, `--h`, `--icon-size`, `--px`, `--ipx`, `--fs`, `--r`, `--gap`, `--bg`, `--bg-hover`, `--bg-pressed`, `--fg`, `--border-color`, `--ring-color`, `--ring-size`, `--bw`, `--fg-hover`, `--border-hover`, `--fg-pressed`, `--border-pressed`, `--bg-disabled`, `--fg-disabled`, `--border-disabled`, `--opacity-disabled`, `--elev-tier`, `--elev`; also mounts `BbSpinner`, `BbIcon`
2621
2623
  - `BbBaseButton` _(public — [contract](./BbBaseButton.md))_ — its own pt parts (`BbBaseButton`): `root` → `RouterComponent`, `root` → `a`, `root` → `component`; also mounts `RouterComponent`
2622
2624
  - Also mounts `CommonPopover`, `DropdownFailures`, `DropdownPipelineResolver`
@@ -653,23 +653,23 @@ to `false`).
653
653
 
654
654
  | Prop | Type | Default | Required | Description |
655
655
  | --- | --- | --- | --- | --- |
656
- | `pt:<part>`, `pt:<part>:<state>`, `pt` | `PtValue` | | | Passthrough — a class list, or `{ class, style, attrs }`, bound to one named part of the component; the state form applies only while that state is on. Parts: `box`, `check`, `footer`, `header`, `icon`, `input`, `item`, `itemDescription`, `itemIcon`, `itemText`, `list`, `main`, `panel`, `root`, `sheet`, `spinner`, `submenu`, `text`, `toggle`. States: `activeLink`, `disabled`, `exactActiveLink`, `loading`, `open`, `default`, `destructive`, `selected`, `ghost`, `link`, `outline`, `primary`, `secondary`. What each one is: _Passthrough parts and states_ below. `pt` is the object form with the same keys minus the prefix (`{ icon: '…', 'icon:loading': '…' }`). See `guides/passthrough.md`. In `<script>` a `pt` value is typed `BbDropdownButtonProps['pt']` (`PtValue` is not exported): § Typing `pt` in `<script>`. |
656
+ | `pt:<part>`, `pt:<part>:<state>`, `pt` | `PtValue` | | | Passthrough — a class list, or `{ class, style, attrs }`, bound to one named part of the component; the state form applies only while that state is on. Parts: `box`, `check`, `footer`, `groupHeader`, `groupLabel`, `header`, `icon`, `input`, `item`, `itemDescription`, `itemIcon`, `itemText`, `list`, `main`, `panel`, `root`, `sheet`, `spinner`, `submenu`, `text`, `toggle`. States: `activeLink`, `disabled`, `exactActiveLink`, `loading`, `open`, `default`, `destructive`, `selected`, `ghost`, `link`, `outline`, `primary`, `secondary`. What each one is: _Passthrough parts and states_ below. `pt` is the object form with the same keys minus the prefix (`{ icon: '…', 'icon:loading': '…' }`). See `guides/passthrough.md`. In `<script>` a `pt` value is typed `BbDropdownButtonProps['pt']` (`PtValue` is not exported): § Typing `pt` in `<script>`. |
657
657
  | `activeClass` | `string \| undefined` | | | Class to apply when the link is active. |
658
- | `adaptive` | `boolean \| undefined` | ``all.adaptive` (`true`)` | | On mobile (below `config.mobileMaxWidth`), renders the menu as a bottom sheet that drills into submenus one level at a time instead of hover flyouts; slots and selection are unchanged. Unset: the global `all.adaptive`. |
658
+ | `adaptive` | `boolean \| undefined` | ``all.adaptive` (`true`)` | | On mobile (below `config.mobileMaxWidth`), the menu is a bottom sheet drilling into submenus a level at a time, not hover flyouts; slots and selection unchanged. Unset: the global `all.adaptive`. |
659
659
  | `append:icon` | `string \| undefined` | | | Icon to be added on the right of the text. |
660
660
  | `ariaCurrentValue` | `"time" \| "true" \| "false" \| "page" \| "step" \| "location" \| "date" \| undefined` | `'page'` | | Value passed to the attribute `aria-current` when the link is exact active. |
661
661
  | `async` | `boolean \| undefined` | `false` | | Inertia: runs the visit without blocking — the page stays interactive and several async visits can be in flight at once. |
662
662
  | `block` | `boolean \| undefined` | `undefined` | | Displays the component as full width. |
663
663
  | `cacheFor` | `string \| number \| (string \| number)[] \| undefined` | | | Inertia: how long a prefetched response stays fresh before it is re-fetched. A single duration, or `[staleAfter, expiresAfter]`. Typed platform-agnostically (matching BbButton) so the library's types never require `@inertiajs/vue3` to be installed. |
664
664
  | `cacheTags` | `string \| string[] \| undefined` | | | Inertia: tags to file this visit's prefetch cache under, so a later request can invalidate the whole tagged group. |
665
- | `closeOnSelect` | `boolean \| undefined` | `unset (close after a single-choice change)` | | Whether a selection closes the menu. Unset: a change in a single-choice group closes it (an untick too, at any depth); a `multiple` group stays open. `true`: every selection change closes it. `false`: none does. |
666
- | `compact` | `boolean \| undefined` | `false` | | Compact density, the `BbSelect` ladder: flyout rows 28px → 24px, sheet rows 44px → 36px (a sheet row stays a touch target). The label size does not change. |
665
+ | `closeOnSelect` | `boolean \| undefined` | `unset (close after a single-choice change)` | | Whether a selection closes the menu. Unset: a single-choice group's change closes it (an untick too, any depth), a `multiple` group stays open. `true`: every change closes it; `false`: none. |
666
+ | `compact` | `boolean \| undefined` | `false` | | Compact density, the `BbSelect` ladder: flyout rows 28 → 24px, sheet rows 44 → 36px (still a touch target). The label size stays. |
667
667
  | `component` | `string \| undefined` | | | Inertia: the page component this visit resolves to. Rarely set by hand — the server normally decides it. |
668
668
  | `data` | `object \| undefined` | | | Request payload forwarded to Inertia when navigating via `href` in an Inertia-enabled app. Ignored when not using Inertia. |
669
669
  | `disableAutoLoading` | `boolean \| undefined` | `false` | | Disables the automatic loading state that tracks async actions (enabled by default). Only affects the main action button: the split toggle half still mirrors the dropdown's internal async-action loading state. |
670
670
  | `disabled` | `boolean \| undefined` | `false` | | Disables both halves: the main button and the menu toggle. |
671
671
  | `download` | `string \| boolean \| undefined` | | | Marks an `href` link as a download: renders a plain `<a download>` doing a native navigation (never an Inertia/router visit), so file downloads work. Pass a string for the suggested filename. A native-anchor signal alongside `target` and `external`. |
672
- | `eager` | `boolean \| undefined` | `false` | | Renders the menu panel at mount instead of on the first open (the phone sheet's too), and keeps its rows after a close. Without it the rows mount on each open and go once the menu has closed. |
672
+ | `eager` | `boolean \| undefined` | `false` | | Renders the panel (the phone sheet's too) at mount, not on the first open, and keeps its rows after a close; otherwise rows mount on each open and go after the close. |
673
673
  | `exactActiveClass` | `string \| undefined` | | | Class to apply when the link is exact active. |
674
674
  | `except` | `string[] \| undefined` | | | Inertia: the inverse of `only` — properties to EXCLUDE from a partial reload. Pass one or the other, not both. |
675
675
  | `external` | `boolean \| undefined` | `false` | | Forces an `href` link to render as a plain `<a>` (native navigation), bypassing Inertia/router interception — same intent as Nuxt's `external`. A native-anchor signal alongside `target` and `download`. |
@@ -713,7 +713,7 @@ to `false`).
713
713
  | `text` | `string \| undefined` | | | Text content of the component. |
714
714
  | `to` | `string \| et \| X \| undefined` | | | Route Location the link should navigate to when clicked on. |
715
715
  | `toggle:icon` | `string \| undefined` | | | Replaces the chevron shown inside the dropdown toggle button. A constrained alternative to a slot: only the toggle's icon changes, so the button keeps its semantics. Named after the part it sits in (the `toggle`), the way `prepend:icon` / `append:icon` name theirs. |
716
- | `transitionDuration` | `number \| undefined` | `150` | | The open / close transition in milliseconds. Menus take the fast one (150), not the popovers' medium 250: a menu is picked from and gone, so it answers faster than a panel you read or edit in. |
716
+ | `transitionDuration` | `number \| undefined` | `150` | | The open / close transition (ms). Menus take the fast 150, not the popovers' 250: a menu is picked from and gone, quicker than a panel you read or edit. |
717
717
  | `type` | `"button" \| "reset" \| "submit" \| undefined` | | | Gets the classification and default behavior of the button. |
718
718
  | `variant` | `'outline'` \| `'primary'` \| `'destructive'` \| `'secondary'` \| `'none'` \| `'ghost'` \| `'link'` | ``components.BbButton.variant`, else `'primary'`` | | Visual variant shared by both buttons of the split control. `'none'` takes no look (you own hover, focus and disabled); register a real one with the plugin's `components.BbButton.variants` and style `.bb-button--<name>`. Unset: `BbButton`'s `components` entry (the app's or a config scope's). |
719
719
  | `viewTransition` | `boolean \| undefined` | `false` | | Inertia: run the page swap inside a View Transition, where the browser supports one. |
@@ -738,10 +738,12 @@ to `false`).
738
738
  | `box` | A searchable group's search box in the menu (field and magnifier) — handed to the `BbDropdown` as its own `pt:box`. |
739
739
  | `input` | A searchable group's search field in the menu — a broadcast, every searchable group's field — handed to the `BbDropdown` as its own `pt:input`. |
740
740
  | `list` | The menu's top-level items container — handed to the `BbDropdown` as its own `pt:list`. |
741
+ | `groupLabel` | Every menu group's label row (the menu's own). |
742
+ | `groupHeader` | Every `groupBy` heading in the menu (the menu's own). |
741
743
  | `item` | One menu entry, submenus included — a broadcast resolved per entry. Also takes a per-item function, called with the entry. |
742
744
  | `itemText` | An entry's label (its `label`) — resolved with that entry's states. A per-entry `#<value>` slot replaces it. Also takes a per-item function. |
743
745
  | `itemIcon` | An entry's prepend / append icons — resolved with that entry's states. Also takes a per-item function. |
744
- | `itemDescription` | An entry's muted second line (its `description`) — resolved with that entry's states. A per-entry `#<value>` slot replaces it. Also takes a per-item function. |
746
+ | `itemDescription` | An entry's muted second line (its `description`), with the entry's states. A per-entry `#<value>` slot replaces it. Also takes a per-item function. |
745
747
  | `check` | A checked entry's tick, outside the row slots: `pt:check="hidden"` spares your own glyph. Also takes a per-item function. |
746
748
  | `submenu` | Every submenu's flyout box (desktop only). Also takes a per-item function, called with the entry that opens it. |
747
749
 
@@ -749,10 +751,10 @@ States are listed in precedence order: when two are on at once and their entries
749
751
 
750
752
  | State | When it is on |
751
753
  | --- | --- |
752
- | `activeLink` | Component-wide while the main button is a link to the current page or one of its ancestors (its `activeClass` is on); also per node, on the entry parts: a menu entry whose link is. The weakest state. |
753
- | `exactActiveLink` | Component-wide while the main button is a link to the current page itself (its `exactActiveClass` is on); also per node, on the entry parts. |
754
+ | `activeLink` | Component-wide while the main button links to the current page or an ancestor (its `activeClass` is on); per node, on the entry parts: an entry whose link does. The weakest state. |
755
+ | `exactActiveLink` | Component-wide while the main button links to the current page itself (its `exactActiveClass` is on); per node, on the entry parts. |
754
756
  | `selected` | Per node, on the entry parts only (`item`, `itemText`, `itemIcon`, `itemDescription`, `check`): a selectable group's checked entry. `pt:root:selected` is a type error, not a silent no-op. |
755
- | `disabled` | Component-wide while the control is `disabled`; also per node, on the entry parts: a menu entry that is disabled. |
757
+ | `disabled` | Component-wide while the control is `disabled`; per node, on the entry parts: a disabled entry. |
756
758
  | `open` | Component-wide: the menu is open. |
757
759
  | `loading` | Component-wide: `loading` is on — the main button shows its spinner. |
758
760
  | `default` | Per entry, on the entry parts: an entry with `variant: 'default'` or none. Merged after the part's base entry and before its states, so the real states still win. |
@@ -813,7 +815,7 @@ States are listed in precedence order: when two are on at once and their entries
813
815
  - `BbBadge` _(public — [contract](./BbBadge.md))_ — its own pt parts (`BbBadge`): `spinner` → `BbSpinner`, `icon` → `span.bb-badge__append-icon`, `icon` → `BbIcon`, `clear` → `button.bb-badge__clear`; documented CSS variables: `--bg`, `--fg`, `--bw`, `--ring-color`, `--ring-size`, `--min-size-md`, `--min-size`, `--elev`, `--r`, `--fs`, `--icon-size`, `--gap`, `--px`, `--clear-size`, `--bg-disabled`, `--fg-disabled`, `--border-disabled`, `--pad-left`; also mounts `BbIcon`, `BbSpinner`, `BadgeBodyContent`
814
816
  - `AdaptiveDropdown` _(internal — not importable, reach it through `BbDropdown`)_ — hands `BbOffCanvas` the pt map `{ header: 'header', footer: 'footer', panel: 'root', sheet: 'root' }` (ours → theirs); also mounts `BbSmoothHeight`, `BbButton`, `BbDropdownList`, `DropdownFailures`
815
817
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
816
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
818
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
817
819
 
818
820
  ## See Also
819
821
 
@@ -22,7 +22,8 @@
22
22
  | --- | --- | --- | --- |
23
23
  | `--size` | `pt:close` | `CloseButton` | the button box — the hit target, not the glyph |
24
24
  | `--p` | `pt:close` | `CloseButton` | padding inside that box; what is left of --size is the glyph |
25
- | `--icon-size` | `pt:close` | `CloseButton` | Glyph: whatever the padding leaves, but never under 10px — a tight --size with the default padding would otherwise collapse it. Declared here, not on the svg: the glyph is a BbIcon, whose own `--size` local would shadow the button's there. |
25
+ | `--icon-size` | `pt:close` | `CloseButton` | Glyph: the ✕ is drawn on a 24 grid with a stock icon's proportions (its ink spans 12 of the 24 units, as Lucide's, Tabler's and Phosphor's do), so any set's ✕ can stand in. Its box is what the padding leaves × 22/12: the ink then spans what the old edge-to-edge glyph painted, the same optical size in the same button box (the extra box overflows the padding, unpainted). Never under 10px — a tight --size with the default padding would otherwise collapse it. Declared here, not on the svg: the glyph is a BbIcon, whose own `--size` local would shadow the button's there. |
26
+ | `--icon-inset` | `pt:close` | `CloseButton` | Centres that larger box on the padding box (negative: it overflows it evenly). Resolved here for the same `--size` reason. |
26
27
 
27
28
  ## Usage & Guidelines
28
29
 
@@ -2026,7 +2027,7 @@ Set these on the element, or on a class you put on it, to retune this component
2026
2027
  - Listed nodes are the ones `BbGallery`'s API reaches or that declare a documented CSS variable; the rest fold into "also mounts". The complete tree, undocumented locals included, is `manifest/components/BbGallery.tree.json` (a public component in it is a name: its own tree file has the rest).
2027
2028
 
2028
2029
  - `BbGallery` _(this component)_ — its own template binds: `header` → `div.bb-gallery__header`, `title` → `p.bb-gallery__title`, `close` → `CloseButton`, `slide` → `figure.bb-gallery__slide`, `image` → `img.bb-gallery__image`, `prev` → `button.bb-gallery__nav`, `next` → `button.bb-gallery__nav`, `footer` → `div.bb-gallery__footer`, `caption` → `p.bb-gallery__caption`, `more` → `button.bb-gallery__more`, `counter` → `p.bb-gallery__counter`
2029
- - `CloseButton` _(internal — not importable, reach it through `BbGallery`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
2030
+ - `CloseButton` _(internal — not importable, reach it through `BbGallery`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
2030
2031
  - Also mounts `BbIcon`
2031
2032
 
2032
2033
  ## See Also
package/dist/ai/BbIcon.md CHANGED
@@ -128,7 +128,7 @@ The `icon` prop takes a name in one of three forms:
128
128
  ships no icon package of its own — install the ones you want. Prefer `lucide:`
129
129
  for UI glyphs when no direction is given, so one visual language stays
130
130
  consistent.
131
- - **`local:name`** — an SVG in the configured `iconDir` (brand marks, custom
131
+ - **`local:name`** — an SVG in the configured `icons.dir` (brand marks, custom
132
132
  illustrations). Each `.svg` file becomes `local:<basename>`.
133
133
  - **bare `name`** — an unprefixed name **normalizes to `local:`**; it never
134
134
  searches provider sets. Prefer writing the prefix anyway: the Iconify editor
@@ -138,7 +138,7 @@ The `icon` prop takes a name in one of three forms:
138
138
  the same shape as `mdi:home` / `lucide:check`, so the source of every icon is
139
139
  legible without inferring it from a missing prefix.
140
140
 
141
- **Split `iconDir` by kind.** Keep single-colour UI glyphs, which paint in
141
+ **Split `icons.dir` by kind.** Keep single-colour UI glyphs, which paint in
142
142
  `currentColor` and follow the text around them, in `icons/ui/`, and
143
143
  fixed-colour logos, which carry their own fills, in `icons/brand/`. The folder
144
144
  is scanned recursively, so both are found, but a name is the file's
@@ -179,13 +179,13 @@ guess a name. See the Icons Policy for the discovery workflow and the heroicons
179
179
  </div>
180
180
  ```
181
181
 
182
- `local:*` is for brand art in `iconDir`. The deploy card below cycles stages
182
+ `local:*` is for brand art in `icons.dir`. The deploy card below cycles stages
183
183
  with full `local:` literals from that folder — the canonical brand-mark demo.
184
184
 
185
185
  **Every `local:` name in this guide is one of _this repository's_ fixture SVGs**
186
186
  (`clock`, `loader`, `check_circle`, `alert_circle`, …). They are illustrative,
187
187
  not a shipped set: copy the pattern, not the names. In your project a
188
- `local:` name resolves only if `<name>.svg` exists in your own `iconDir`; a
188
+ `local:` name resolves only if `<name>.svg` exists in your own `icons.dir`; a
189
189
  missing one renders the placeholder and logs which file is absent.
190
190
 
191
191
  **Brand marks via local: — deploy stages**
@@ -221,11 +221,11 @@ type Stage = {
221
221
  tone: string;
222
222
  };
223
223
 
224
- // Brand marks via `local:*` (files in iconDir). Each stage owns a full static
224
+ // Brand marks via `local:*` (files in icons.dir). Each stage owns a full static
225
225
  // literal so the production scanner bundles it — never `local:${name}`. The
226
226
  // glyph is decorative beside the stage label, so no `label` prop.
227
227
  const stages: Stage[] = [
228
- // `local:*` names resolve against YOUR `iconDir` — these four are this
228
+ // `local:*` names resolve against YOUR `icons.dir` — these four are this
229
229
  // repository's fixture SVGs. Copied into another project, each one throws
230
230
  // at mount until a `<name>.svg` of your own exists there (or swap them for
231
231
  // `lucide:*` names, which need no files).
@@ -264,13 +264,13 @@ Provider icons ship only when the plugin can see them. It reads the **whole
264
264
  project** as bytes — every file under the Vite root, PHP and JSON and SQL
265
265
  included, minus gitignored, hidden, binary, `node_modules`/`vendor` and
266
266
  excluded paths — for `provider:name` literals, and bundles exactly those (plus
267
- `iconWhitelist`). `local:` ships everything. **Dev registers the same set**, so
267
+ `icons.whitelist`). `local:` ships everything. **Dev registers the same set**, so
268
268
  a name assembled at runtime (`` `lucide:${kind}` ``) renders the placeholder
269
269
  on first render in dev, not after deploy. Map dynamic state to full literals —
270
270
  a lookup object of complete names, exactly as the deploy-stages companion does
271
271
  (`stages[i].icon` holds `'local:clock'`, not a concatenation) — or, when the
272
272
  name really is composed at runtime or comes from a database, list it in the
273
- plugin's `iconWhitelist` (`'lucide:circle-check'`, or a glob such as
273
+ plugin's `icons.whitelist` (`'lucide:circle-check'`, or a glob such as
274
274
  `'lucide:calendar-*'`). An icon used only in a `.stories.ts` / `.test.ts` file
275
275
  is scanned like any other file.
276
276
 
@@ -283,7 +283,7 @@ const STATUS_ICON = {
283
283
  failed: 'lucide:circle-x',
284
284
  } as const;
285
285
  // Wrong: `lucide:${status}` — never scanned; placeholder in dev AND prod
286
- // (unless every value is in the plugin's `iconWhitelist`).
286
+ // (unless every value is in the plugin's `icons.whitelist`).
287
287
  defineProps<{ status: 'paid' | 'pending' | 'failed' }>();
288
288
  </script>
289
289
 
@@ -378,7 +378,7 @@ deploy-stages companions both color the row wrapper; the icon tracks it.
378
378
  (a setup fault — a merely missing NAME never throws, it renders the
379
379
  placeholder).
380
380
  Provider sets (`@iconify-json/*`) are auto-discovered from `node_modules`;
381
- `local:*` comes from `iconDir` (default `./assets/icons` on Nuxt).
381
+ `local:*` comes from `icons.dir` (default `./assets/icons` on Nuxt).
382
382
  - **SSR / Nuxt** — icons resolve during `onServerPrefetch`, so server-rendered
383
383
  markup contains the glyph on first paint (no hydration flash). `BbIcon` carries
384
384
  no navigation surface — it is a pure visual primitive.
@@ -22,7 +22,8 @@
22
22
  | --- | --- | --- | --- |
23
23
  | `--size` | `pt:close` | `CloseButton` | the button box — the hit target, not the glyph |
24
24
  | `--p` | `pt:close` | `CloseButton` | padding inside that box; what is left of --size is the glyph |
25
- | `--icon-size` | `pt:close` | `CloseButton` | Glyph: whatever the padding leaves, but never under 10px — a tight --size with the default padding would otherwise collapse it. Declared here, not on the svg: the glyph is a BbIcon, whose own `--size` local would shadow the button's there. |
25
+ | `--icon-size` | `pt:close` | `CloseButton` | Glyph: the ✕ is drawn on a 24 grid with a stock icon's proportions (its ink spans 12 of the 24 units, as Lucide's, Tabler's and Phosphor's do), so any set's ✕ can stand in. Its box is what the padding leaves × 22/12: the ink then spans what the old edge-to-edge glyph painted, the same optical size in the same button box (the extra box overflows the padding, unpainted). Never under 10px — a tight --size with the default padding would otherwise collapse it. Declared here, not on the svg: the glyph is a BbIcon, whose own `--size` local would shadow the button's there. |
26
+ | `--icon-inset` | `pt:close` | `CloseButton` | Centres that larger box on the padding box (negative: it overflows it evenly). Resolved here for the same `--size` reason. |
26
27
 
27
28
  ## Usage & Guidelines
28
29
 
@@ -1547,7 +1548,7 @@ Set these on the element, or on a class you put on it, to retune this component
1547
1548
  - Listed nodes are the ones `BbOffCanvas`'s API reaches or that declare a documented CSS variable; the rest fold into "also mounts". The complete tree, undocumented locals included, is `manifest/components/BbOffCanvas.tree.json` (a public component in it is a name: its own tree file has the rest).
1548
1549
 
1549
1550
  - `BbOffCanvas` _(this component)_ — its own template binds: `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`
1550
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
1551
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
1551
1552
 
1552
1553
  ## See Also
1553
1554
 
@@ -965,7 +965,7 @@ States are listed in precedence order: when two are on at once and their entries
965
965
 
966
966
  - `BbPopover` _(this component)_ — its own template binds: `panel` → `CommonPopover`, `root` → `CommonPopover`, `header` → `div.bb-popover__header`, `content` → `div.bb-popover__content`, `footer` → `div.bb-popover__footer`; hands `BbOffCanvas` the pt map `{ header: 'header', content: 'content', footer: 'footer', panel: 'root', sheet: 'root', }` (ours → theirs)
967
967
  - `BbOffCanvas` _(public — [contract](./BbOffCanvas.md))_ — its own pt parts (`BbOffCanvas`): `header` → `div.bb-offcanvas__header`, `title` → `span.bb-offcanvas__title`, `description` → `p.bb-offcanvas__description`, `close` → `CloseButton`, `content` → `div.bb-offcanvas__content`, `footer` → `div.bb-offcanvas__footer`; documented CSS variables: `--stack-x`, `--snap-y`, `--stack-fill`, `--stack-transition-duration`, `--px`, `--handle-w`, `--handle-h`, `--handle-bg`, `--safe-top`, `--close-size`
968
- - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`; also mounts `BbIcon`
968
+ - `CloseButton` _(internal — not importable, reach it through `BbOffCanvas`)_ — documented CSS variables: `--size`, `--p`, `--icon-size`, `--icon-inset`; also mounts `BbIcon`
969
969
  - Also mounts `CommonPopover`
970
970
 
971
971
  ## See Also