@openreachtech/furo-vue 1.5.0 → 1.7.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.
Files changed (89) hide show
  1. package/README.ja.md +2 -0
  2. package/README.md +2 -0
  3. package/docs/design-tokens.md +419 -0
  4. package/docs/furo-accordion.md +109 -0
  5. package/docs/furo-alert-dialog.md +107 -0
  6. package/docs/furo-attachment.md +133 -0
  7. package/docs/furo-autocomplete-field.md +719 -0
  8. package/docs/furo-avatar-group.md +87 -0
  9. package/docs/furo-avatar.md +101 -0
  10. package/docs/furo-badge.md +126 -0
  11. package/docs/furo-breadcrumb.md +89 -0
  12. package/docs/furo-button.md +263 -0
  13. package/docs/furo-checkbox.md +384 -0
  14. package/docs/furo-collapsible.md +104 -0
  15. package/docs/furo-control-block.md +102 -0
  16. package/docs/furo-date-picker.md +270 -0
  17. package/docs/furo-date-time-picker.md +110 -0
  18. package/docs/furo-dialog.md +88 -0
  19. package/docs/furo-drawer.md +122 -0
  20. package/docs/furo-dropdown-menu.md +298 -0
  21. package/docs/furo-editable-field.md +391 -0
  22. package/docs/furo-editor.md +304 -0
  23. package/docs/furo-email-field.md +93 -0
  24. package/docs/furo-empty-state.md +97 -0
  25. package/docs/furo-error-state.md +97 -0
  26. package/docs/furo-file-field.md +163 -0
  27. package/docs/furo-icon.md +288 -0
  28. package/docs/furo-number-field.md +397 -0
  29. package/docs/furo-pagination.md +101 -0
  30. package/docs/furo-password-field.md +75 -0
  31. package/docs/furo-popover.md +114 -0
  32. package/docs/furo-radio.md +125 -0
  33. package/docs/furo-scroll-area.md +112 -0
  34. package/docs/furo-search-field.md +94 -0
  35. package/docs/furo-section-header.md +135 -0
  36. package/docs/furo-select.md +443 -0
  37. package/docs/furo-separator.md +87 -0
  38. package/docs/furo-sidebar.md +178 -0
  39. package/docs/furo-skeleton.md +92 -0
  40. package/docs/furo-splitter.md +103 -0
  41. package/docs/furo-stepper.md +127 -0
  42. package/docs/furo-switch.md +107 -0
  43. package/docs/furo-table.md +233 -0
  44. package/docs/furo-tabs.md +173 -0
  45. package/docs/furo-text-field.md +249 -0
  46. package/docs/furo-textarea.md +214 -0
  47. package/docs/furo-time-field.md +276 -0
  48. package/docs/furo-toast.md +217 -0
  49. package/docs/furo-toggle-group.md +123 -0
  50. package/docs/furo-toggle.md +104 -0
  51. package/docs/furo-tool-bar.md +88 -0
  52. package/docs/furo-tooltip.md +107 -0
  53. package/lib/assets/css/furo/0030.variables-semantic-color.css +15 -1
  54. package/lib/components/atoms/FuroButton/FuroButtonContext.js +8 -8
  55. package/lib/components/atoms/FuroCheckbox/FuroCheckboxContext.js +1 -1
  56. package/lib/components/atoms/FuroIcon/FuroIcon.vue +1 -1
  57. package/lib/components/atoms/FuroSwitch/FuroSwitchContext.js +1 -1
  58. package/lib/components/atoms/FuroToggle/FuroToggleContext.js +1 -1
  59. package/lib/components/molecules/FuroAccordion/FuroAccordionContext.js +1 -1
  60. package/lib/components/molecules/FuroAttachment/FuroAttachment.vue +1 -1
  61. package/lib/components/molecules/FuroBreadcrumb/FuroBreadcrumb.vue +1 -1
  62. package/lib/components/molecules/FuroCollapsible/FuroCollapsibleContext.js +1 -1
  63. package/lib/components/molecules/FuroControlBlock/FuroControlBlock.vue +2 -2
  64. package/lib/components/molecules/FuroDropdownMenu/FuroDropdownMenu.vue +1 -1
  65. package/lib/components/molecules/FuroDropdownMenu/FuroDropdownMenuContext.js +1 -2
  66. package/lib/components/molecules/FuroErrorState/FuroErrorState.vue +1 -1
  67. package/lib/components/molecules/FuroPopover/FuroPopoverContext.js +1 -1
  68. package/lib/components/molecules/FuroSearchField/FuroSearchField.vue +1 -1
  69. package/lib/components/molecules/FuroSelect/FuroSelect.vue +8 -6
  70. package/lib/components/molecules/FuroSelect/FuroSelectContext.js +35 -0
  71. package/lib/components/molecules/FuroSelect/FuroSelectOptionText.vue +40 -0
  72. package/lib/components/molecules/FuroSelect/FuroSelectOptionTextContext.js +275 -0
  73. package/lib/components/molecules/FuroSplitter/FuroSplitterContext.js +1 -1
  74. package/lib/components/molecules/FuroToggleGroup/FuroToggleGroupContext.js +1 -1
  75. package/lib/components/molecules/FuroTooltip/FuroTooltipContext.js +1 -1
  76. package/lib/components/organisms/FuroSidebar/FuroSidebar.vue +3 -3
  77. package/lib/components/organisms/FuroTable/FuroTable.vue +1 -1
  78. package/lib/components/organisms/FuroTable/FuroTableContext.js +3 -3
  79. package/lib/components/organisms/FuroToast/FuroToastContext.js +6 -2
  80. package/lib/components/organisms/FuroToast/ToastQueue.js +4 -4
  81. package/nuxt/index.js +9 -9
  82. package/package.json +23 -22
  83. package/public/furo-vue/components.json +1 -1
  84. package/types/generated/components/atoms/FuroButton/FuroButtonContext.d.ts +4 -4
  85. package/types/generated/components/molecules/FuroSelect/FuroSelect.vue.d.ts +23 -0
  86. package/types/generated/components/molecules/FuroSelect/FuroSelectContext.d.ts +14 -0
  87. package/types/generated/components/molecules/FuroSelect/FuroSelectOptionText.vue.d.ts +50 -0
  88. package/types/generated/components/molecules/FuroSelect/FuroSelectOptionTextContext.d.ts +141 -0
  89. package/types/generated/components/organisms/FuroTable/FuroTableContext.d.ts +2 -2
@@ -272,7 +272,7 @@ export default class FuroSplitterContext extends BaseFuroContext {
272
272
  }) {
273
273
  const entries = Object.entries(panel)
274
274
  .filter(([key]) => SPLITTER_PANEL_KEYS.has(key))
275
- .filter(([, value]) => value !== undefined)
275
+ .filter(([, value]) => typeof value !== 'undefined')
276
276
 
277
277
  return Object.fromEntries(entries)
278
278
  }
@@ -250,7 +250,7 @@ export default class FuroToggleGroupContext extends BaseFuroContext {
250
250
 
251
251
  const { value: attrsValue } = this.attrs ?? {}
252
252
 
253
- if (attrsValue !== undefined) {
253
+ if (typeof attrsValue !== 'undefined') {
254
254
  return /** @type {FuroToggleGroupValue} */ (attrsValue)
255
255
  }
256
256
 
@@ -144,7 +144,7 @@ export default class FuroTooltipContext extends BaseFuroContext {
144
144
  * @returns {boolean} true when `parcel.open` is supplied.
145
145
  */
146
146
  isOpenControlled () {
147
- return this.parcel?.open !== undefined
147
+ return typeof this.parcel?.open !== 'undefined'
148
148
  && this.parcel?.open !== null
149
149
  }
150
150
 
@@ -271,7 +271,7 @@ export default defineComponent({
271
271
  padding-block: 0.5rem;
272
272
  padding-inline: 0.5rem;
273
273
 
274
- color: var(--color-foreground-tertiary);
274
+ color: var(--color-foreground-secondary);
275
275
  font: var(--font-label-tiny);
276
276
  }
277
277
 
@@ -381,7 +381,7 @@ export default defineComponent({
381
381
  width: 0.875rem;
382
382
  height: 0.875rem;
383
383
 
384
- color: var(--color-foreground-tertiary);
384
+ color: var(--color-foreground-glyph);
385
385
  }
386
386
 
387
387
  /* nested sub-rows */
@@ -438,7 +438,7 @@ export default defineComponent({
438
438
 
439
439
  background-color: transparent;
440
440
 
441
- color: var(--color-foreground-tertiary);
441
+ color: var(--color-foreground-secondary);
442
442
  font: var(--font-label-small);
443
443
  text-align: start;
444
444
 
@@ -673,7 +673,7 @@ export default defineComponent({
673
673
  }
674
674
 
675
675
  .unit-table .state-row.error > td {
676
- color: var(--color-destructive);
676
+ color: var(--color-destructive-text);
677
677
  }
678
678
 
679
679
  .unit-table .spinner-icon {
@@ -129,11 +129,11 @@ export default class FuroTableContext extends BaseFuroContext {
129
129
  * Wrapped as a static hook so scroll throttling can be driven deterministically
130
130
  * in tests (spy on this method) instead of depending on the browser global.
131
131
  *
132
- * @param {FrameRequestCallback} callback - Callback to run on the next frame.
132
+ * @param {FrameRequestCallback} frameCallback - Callback to run on the next frame.
133
133
  * @returns {number} The frame request id.
134
134
  */
135
- static requestFrame (callback) {
136
- return globalThis.requestAnimationFrame(callback)
135
+ static requestFrame (frameCallback) {
136
+ return globalThis.requestAnimationFrame(frameCallback)
137
137
  }
138
138
 
139
139
  /**
@@ -61,13 +61,17 @@ const LOADING_DURATION = 1000000000
61
61
  * only accent — the toast body stays neutral.
62
62
  */
63
63
  const TYPE_ICON_NAME_HASH = {
64
- info: 'ph:info',
65
64
  success: 'ph:check-circle',
66
65
  warning: 'ph:warning',
67
66
  error: 'ph:x-circle',
68
67
  loading: 'ph:circle-notch',
69
68
  }
70
69
 
70
+ /**
71
+ * Icon name of the default `info` type, which the hash above leaves out.
72
+ */
73
+ const DEFAULT_TYPE_ICON_NAME = 'ph:info'
74
+
71
75
  /**
72
76
  * Context class for FuroToast organism.
73
77
  *
@@ -591,7 +595,7 @@ export default class FuroToastContext extends BaseFuroContext {
591
595
  type,
592
596
  }) {
593
597
  return TYPE_ICON_NAME_HASH[type]
594
- ?? TYPE_ICON_NAME_HASH[DEFAULT_TYPE]
598
+ ?? DEFAULT_TYPE_ICON_NAME
595
599
  }
596
600
 
597
601
  /**
@@ -266,10 +266,10 @@ export default class ToastQueue {
266
266
  * @param {ToastConfig} [params] - Configuration to merge.
267
267
  */
268
268
  configure (params = {}) {
269
- Object.assign(
270
- this.stateReactive.config,
271
- params
272
- )
269
+ this.stateReactive.config = {
270
+ ...this.stateReactive.config,
271
+ ...params,
272
+ }
273
273
  }
274
274
 
275
275
  /**
package/nuxt/index.js CHANGED
@@ -43,14 +43,14 @@ export default defineNuxtModule({
43
43
  nuxt,
44
44
  })
45
45
 
46
- Object.assign(nuxt.options.appConfig, {
47
- furoVue: {
48
- iconComponentName: extractIconComponentName({
49
- options,
50
- nuxt,
51
- }),
52
- },
53
- })
46
+ const { appConfig } = nuxt.options
47
+
48
+ appConfig.furoVue = {
49
+ iconComponentName: extractIconComponentName({
50
+ options,
51
+ nuxt,
52
+ }),
53
+ }
54
54
 
55
55
  const resolver = createResolver(import.meta.url)
56
56
 
@@ -84,7 +84,7 @@ async function ensureIconModule ({
84
84
  throw new Error(`[@openreachtech/furo-vue] the Nuxt module needs \`${ICON_MODULE_NAME}\` to draw the names the icon registry lacks. Install it with \`npm install ${ICON_MODULE_NAME}\`, or drop this module and install a renderer yourself with \`furoIconRegistry.useIconRenderer()\`.`)
85
85
  }
86
86
 
87
- await installModule(ICON_MODULE_NAME, undefined, nuxt)
87
+ await installModule(ICON_MODULE_NAME, {}, nuxt)
88
88
  }
89
89
 
90
90
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openreachtech/furo-vue",
3
- "version": "1.5.0",
3
+ "version": "1.7.0",
4
4
  "description": "furo for Vue",
5
5
  "main": "index.js",
6
6
  "types": "./types/index.d.ts",
@@ -39,6 +39,8 @@
39
39
  "nuxt/",
40
40
  "types/",
41
41
  "public/furo-vue/",
42
+ "docs/design-tokens.md",
43
+ "docs/furo-*.md",
42
44
  "!**/.directorykeeper",
43
45
  "!types/jest.d.ts"
44
46
  ],
@@ -77,22 +79,22 @@
77
79
  },
78
80
  "license": "Apache-2.0",
79
81
  "dependencies": {
80
- "@iconify/vue": "^5.0.3",
82
+ "@iconify/vue": "^5.0.4",
81
83
  "@openreachtech/furo": "^1.11.0",
82
- "@tiptap/core": "^3.31.4",
83
- "@tiptap/extension-highlight": "^3.31.4",
84
- "@tiptap/extension-image": "^3.31.4",
85
- "@tiptap/extension-mention": "^3.31.4",
86
- "@tiptap/extension-text-align": "^3.31.4",
87
- "@tiptap/extension-text-style": "^3.31.4",
88
- "@tiptap/extension-typography": "^3.31.4",
89
- "@tiptap/extensions": "^3.31.4",
90
- "@tiptap/pm": "^3.31.4",
91
- "@tiptap/starter-kit": "^3.31.4",
92
- "@tiptap/vue-3": "^3.31.4",
93
- "marked": "^18.1.0",
84
+ "@tiptap/core": "^3.32.0",
85
+ "@tiptap/extension-highlight": "^3.32.0",
86
+ "@tiptap/extension-image": "^3.32.0",
87
+ "@tiptap/extension-mention": "^3.32.0",
88
+ "@tiptap/extension-text-align": "^3.32.0",
89
+ "@tiptap/extension-text-style": "^3.32.0",
90
+ "@tiptap/extension-typography": "^3.32.0",
91
+ "@tiptap/extensions": "^3.32.0",
92
+ "@tiptap/pm": "^3.32.0",
93
+ "@tiptap/starter-kit": "^3.32.0",
94
+ "@tiptap/vue-3": "^3.32.0",
95
+ "marked": "^18.1.2",
94
96
  "reka-ui": "^2.11.0",
95
- "vue": "^3.5.43"
97
+ "vue": "^3.5.44"
96
98
  },
97
99
  "peerDependencies": {
98
100
  "@nuxt/icon": "^1.0.0",
@@ -112,23 +114,22 @@
112
114
  "@babel/preset-env": "^7.29.7",
113
115
  "@iconify-json/ph": "^1.2.2",
114
116
  "@nuxt/icon": "^1.15.0",
115
- "@openreachtech/eslint-config": "^3.0.2",
117
+ "@openreachtech/eslint-config": "^4.5.0",
116
118
  "@openreachtech/jest-constructor-spy": "^1.1.2",
117
119
  "@openreachtech/jest-deep-containing": "^1.0.2",
118
120
  "@types/jest": "^30.0.0",
119
121
  "@vue/test-utils": "^2.5.1",
120
- "@vue/vue3-jest": "^29.2.6",
121
- "babel-jest": "^29.7.0",
122
- "core-js": "^3.50.0",
122
+ "babel-jest": "^30.5.2",
123
+ "core-js": "^3.51.0",
123
124
  "eslint": "^9.39.5",
124
125
  "eslint-plugin-eslint-comments": "^3.2.0",
125
126
  "eslint-plugin-vue": "^9.33.0",
126
127
  "globals": "^17.13.0",
127
- "jest": "^29.7.0",
128
- "jest-environment-jsdom": "^29.7.0",
128
+ "jest": "^30.5.2",
129
+ "jest-environment-jsdom": "^30.5.2",
129
130
  "nuxt": "^3.21.11",
130
131
  "typescript": "^5.9.3",
131
- "vue-tsc": "^3.3.12",
132
+ "vue-tsc": "^3.3.13",
132
133
  "whatwg-fetch": "^3.6.20"
133
134
  },
134
135
  "overrides": {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "library": "@openreachtech/furo-vue",
3
- "version": "1.5.0",
3
+ "version": "1.7.0",
4
4
  "generatedFrom": "app/docs/component-registry.js",
5
5
  "layers": [
6
6
  "foundation",
@@ -104,13 +104,13 @@ export default class FuroButtonContext extends BaseFuroContext<null, Props, "CLI
104
104
  * Extract ARIA attributes for the button root.
105
105
  *
106
106
  * @returns {{
107
- * 'aria-disabled': 'true' | undefined
108
- * 'aria-busy': 'true' | undefined
107
+ * 'aria-disabled'?: 'true'
108
+ * 'aria-busy'?: 'true'
109
109
  * }}
110
110
  */
111
111
  extractAriaAttributes(): {
112
- "aria-disabled": "true" | undefined;
113
- "aria-busy": "true" | undefined;
112
+ "aria-disabled"?: "true";
113
+ "aria-busy"?: "true";
114
114
  };
115
115
  /**
116
116
  * Handle native click on the button root.
@@ -461,6 +461,27 @@ declare const __VLS_export: import("vue").DefineComponent<{
461
461
  }> & Readonly<{}>, {
462
462
  size: string | number;
463
463
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
464
+ FuroSelectOptionText: import("vue").DefineComponent<{}, {
465
+ context: import("./FuroSelectOptionTextContext.js").default;
466
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {
467
+ SelectOptionText: {
468
+ new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
469
+ P: {};
470
+ B: {};
471
+ D: {};
472
+ C: {};
473
+ M: {};
474
+ Defaults: {};
475
+ }, Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, {}>;
476
+ __isFragment?: never;
477
+ __isTeleport?: never;
478
+ __isSuspense?: never;
479
+ } & import("vue").ComponentOptionsBase<Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
480
+ $slots: {
481
+ default?: (props: {}) => any;
482
+ };
483
+ });
484
+ }, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
464
485
  SelectRoot: <T extends import("reka-ui").AcceptableValue = import("reka-ui").AcceptableValue>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: {
465
486
  attrs: any;
466
487
  slots: {
@@ -780,6 +801,7 @@ declare const __VLS_export: import("vue").DefineComponent<{
780
801
  }, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
781
802
  declare namespace __VLS_componentsOption {
782
803
  export { FuroIcon };
804
+ export { FuroSelectOptionText };
783
805
  export let SelectRoot: <T extends import("reka-ui").AcceptableValue = import("reka-ui").AcceptableValue>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: {
784
806
  attrs: any;
785
807
  slots: {
@@ -1169,3 +1191,4 @@ declare var __VLS_197: {};
1169
1191
  import FuroSelectContext from './FuroSelectContext.js';
1170
1192
  import type { FuroSelectSlots } from './FuroSelectContext.js';
1171
1193
  import FuroIcon from '../../atoms/FuroIcon/FuroIcon.vue';
1194
+ import FuroSelectOptionText from './FuroSelectOptionText.vue';
@@ -165,6 +165,20 @@ export default class FuroSelectContext extends BaseFuroContext<null, Props, "CHA
165
165
  resolveOptionValue({ option, }: {
166
166
  option: FuroSelectOption;
167
167
  }): FuroSelectValue;
168
+ /**
169
+ * Build an option's render key from its value and label, so a change to either
170
+ * remounts the item, because the item records both only when it mounts.
171
+ *
172
+ * @param {{
173
+ * option: FuroSelectOption
174
+ * index: number
175
+ * }} params - Parameters of this method.
176
+ * @returns {string} Render key.
177
+ */
178
+ generateOptionKey({ option, index, }: {
179
+ option: FuroSelectOption;
180
+ index: number;
181
+ }): string;
168
182
  /**
169
183
  * Setup component context.
170
184
  *
@@ -0,0 +1,50 @@
1
+ declare const _default: typeof __VLS_export;
2
+ export default _default;
3
+ export type __VLS_LocalComponents = typeof __VLS_componentsOption;
4
+ export type __VLS_GlobalComponents = import("vue").GlobalComponents;
5
+ export type __VLS_LocalDirectives = {};
6
+ export type __VLS_Slots = {} & {
7
+ default?: (props: typeof __VLS_7) => any;
8
+ };
9
+ declare const __VLS_export: import("vue").DefineComponent<{}, {
10
+ context: FuroSelectOptionTextContext;
11
+ }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {
12
+ SelectOptionText: {
13
+ new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
14
+ P: {};
15
+ B: {};
16
+ D: {};
17
+ C: {};
18
+ M: {};
19
+ Defaults: {};
20
+ }, Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, {}>;
21
+ __isFragment?: never;
22
+ __isTeleport?: never;
23
+ __isSuspense?: never;
24
+ } & import("vue").ComponentOptionsBase<Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
25
+ $slots: {
26
+ default?: (props: {}) => any;
27
+ };
28
+ });
29
+ }, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
30
+ declare namespace __VLS_componentsOption {
31
+ let SelectOptionText: {
32
+ new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, {
33
+ P: {};
34
+ B: {};
35
+ D: {};
36
+ C: {};
37
+ M: {};
38
+ Defaults: {};
39
+ }, Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, {}>;
40
+ __isFragment?: never;
41
+ __isTeleport?: never;
42
+ __isSuspense?: never;
43
+ } & import("vue").ComponentOptionsBase<Readonly<import("reka-ui").SelectItemTextProps> & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
44
+ $slots: {
45
+ default?: (props: {}) => any;
46
+ };
47
+ });
48
+ }
49
+ declare var __VLS_7: {};
50
+ import FuroSelectOptionTextContext from './FuroSelectOptionTextContext.js';
@@ -0,0 +1,141 @@
1
+ /**
2
+ * Context class for the text of one FuroSelect option.
3
+ *
4
+ * @extends {BaseFuroContext<null, {}, never>}
5
+ */
6
+ export default class FuroSelectOptionTextContext extends BaseFuroContext<null, {}, never> {
7
+ /**
8
+ * Factory method.
9
+ *
10
+ * @template {X extends typeof FuroSelectOptionTextContext ? X : never} T, X
11
+ * @override
12
+ * @param {FuroSelectOptionTextContextFactoryParams} params - Parameters of this factory method.
13
+ * @returns {InstanceType<T>} An instance of this class.
14
+ * @this {T}
15
+ */
16
+ static override create<T extends X extends typeof FuroSelectOptionTextContext ? X : never, X>(this: T, { props, componentContext, refHash, selectRootContext, selectItemContext, }: FuroSelectOptionTextContextFactoryParams): InstanceType<T>;
17
+ /**
18
+ * Build ref hash.
19
+ *
20
+ * @override
21
+ * @returns {FuroSelectOptionTextContextParams['refHash']}
22
+ */
23
+ static override buildRefHash(): FuroSelectOptionTextContextParams["refHash"];
24
+ /**
25
+ * Inject the select root context, which holds the text the trigger shows.
26
+ *
27
+ * @returns {FuroSelectRootContext}
28
+ */
29
+ static injectSelectRootContext(): FuroSelectRootContext;
30
+ /**
31
+ * Inject the context of the option that holds this text.
32
+ *
33
+ * @returns {FuroSelectItemContext}
34
+ */
35
+ static injectSelectItemContext(): FuroSelectItemContext;
36
+ /**
37
+ * Constructor.
38
+ *
39
+ * @param {FuroSelectOptionTextContextParams} params - Parameters of this constructor.
40
+ */
41
+ constructor({ props, componentContext, refHash, selectRootContext, selectItemContext, }: FuroSelectOptionTextContextParams);
42
+ refHash: {
43
+ textComponentRef: import("vue").ShallowRef<{
44
+ $el: HTMLElement;
45
+ } | null>;
46
+ observerRef: import("vue").ShallowRef<MutationObserver | null>;
47
+ recordedTextRef: import("vue").Ref<string | null>;
48
+ };
49
+ selectRootContext: FuroSelectRootContext;
50
+ selectItemContext: FuroSelectItemContext;
51
+ /**
52
+ * get: Ctor
53
+ *
54
+ * @override
55
+ * @returns {typeof FuroSelectOptionTextContext}
56
+ */
57
+ override get Ctor(): typeof FuroSelectOptionTextContext;
58
+ /**
59
+ * get: textComponentRef
60
+ *
61
+ * @returns {import('vue').ShallowRef<{ $el: HTMLElement } | null>}
62
+ */
63
+ get textComponentRef(): import("vue").ShallowRef<{
64
+ $el: HTMLElement;
65
+ } | null>;
66
+ /**
67
+ * get: observerRef
68
+ *
69
+ * @returns {import('vue').ShallowRef<MutationObserver | null>}
70
+ */
71
+ get observerRef(): import("vue").ShallowRef<MutationObserver | null>;
72
+ /**
73
+ * get: recordedTextRef
74
+ *
75
+ * @returns {import('vue').Ref<string | null>}
76
+ */
77
+ get recordedTextRef(): import("vue").Ref<string | null>;
78
+ /**
79
+ * Setup component context.
80
+ *
81
+ * @template {X extends FuroSelectOptionTextContext ? X : never} T, X
82
+ * @override
83
+ * @returns {T} - For method chaining.
84
+ * @this {T}
85
+ */
86
+ override setupComponent<T extends X extends FuroSelectOptionTextContext ? X : never, X>(this: T): T;
87
+ /**
88
+ * Extract the rendered text element.
89
+ *
90
+ * @returns {HTMLElement | null}
91
+ */
92
+ extractTextElement(): HTMLElement | null;
93
+ /**
94
+ * Extract the rendered text.
95
+ *
96
+ * @returns {string | null}
97
+ */
98
+ extractText(): string | null;
99
+ /**
100
+ * Watch the rendered text for changes.
101
+ */
102
+ observeTextElement(): void;
103
+ /**
104
+ * Replace the recorded option text when the rendered text differs from it.
105
+ */
106
+ syncText(): void;
107
+ /**
108
+ * Stop watching the rendered text.
109
+ */
110
+ disconnectObserver(): void;
111
+ }
112
+ export type FuroSelectRootContext = {
113
+ onOptionAdd: (option: {
114
+ value: unknown;
115
+ disabled: boolean;
116
+ textContent: string;
117
+ }) => void;
118
+ };
119
+ export type FuroSelectItemContext = {
120
+ value: unknown;
121
+ disabled: import("vue").Ref<boolean>;
122
+ };
123
+ export type FuroSelectOptionTextContextParams = import("../../../contexts/BaseFuroContext.js").BaseFuroContextParams & {
124
+ props: {};
125
+ componentContext: import("vue").SetupContext;
126
+ refHash: {
127
+ textComponentRef: import("vue").ShallowRef<{
128
+ $el: HTMLElement;
129
+ } | null>;
130
+ observerRef: import("vue").ShallowRef<MutationObserver | null>;
131
+ recordedTextRef: import("vue").Ref<string | null>;
132
+ };
133
+ selectRootContext: FuroSelectRootContext;
134
+ selectItemContext: FuroSelectItemContext;
135
+ };
136
+ export type FuroSelectOptionTextContextFactoryParams = Omit<FuroSelectOptionTextContextParams, "refHash" | "selectRootContext" | "selectItemContext"> & {
137
+ refHash?: FuroSelectOptionTextContextParams["refHash"];
138
+ selectRootContext?: FuroSelectRootContext;
139
+ selectItemContext?: FuroSelectItemContext;
140
+ };
141
+ import BaseFuroContext from '../../../contexts/BaseFuroContext.js';
@@ -31,10 +31,10 @@ export default class FuroTableContext extends BaseFuroContext<null, Props, "SORT
31
31
  * Wrapped as a static hook so scroll throttling can be driven deterministically
32
32
  * in tests (spy on this method) instead of depending on the browser global.
33
33
  *
34
- * @param {FrameRequestCallback} callback - Callback to run on the next frame.
34
+ * @param {FrameRequestCallback} frameCallback - Callback to run on the next frame.
35
35
  * @returns {number} The frame request id.
36
36
  */
37
- static requestFrame(callback: FrameRequestCallback): number;
37
+ static requestFrame(frameCallback: FrameRequestCallback): number;
38
38
  /**
39
39
  * Cancel a scheduled animation frame.
40
40
  *