@visitwonders/assembly 0.10.1 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/declarations/form/combobox-field.d.ts +71 -0
- package/declarations/form/combobox-field.d.ts.map +1 -0
- package/declarations/form/combobox-shared.d.ts +36 -0
- package/declarations/form/combobox-shared.d.ts.map +1 -0
- package/declarations/form/combobox.d.ts +239 -0
- package/declarations/form/combobox.d.ts.map +1 -0
- package/declarations/form/index.d.ts +4 -0
- package/declarations/form/index.d.ts.map +1 -1
- package/declarations/form/multi-combobox-field.d.ts +72 -0
- package/declarations/form/multi-combobox-field.d.ts.map +1 -0
- package/declarations/form/multi-combobox.d.ts +202 -0
- package/declarations/form/multi-combobox.d.ts.map +1 -0
- package/declarations/layout/h-stack.d.ts.map +1 -1
- package/declarations/layout/stack.d.ts.map +1 -1
- package/declarations/layout/v-stack.d.ts.map +1 -1
- package/declarations/overlay/popover.d.ts +20 -1
- package/declarations/overlay/popover.d.ts.map +1 -1
- package/dist/_app_/form/combobox-field.js +1 -0
- package/dist/_app_/form/combobox-shared.js +1 -0
- package/dist/_app_/form/combobox.js +1 -0
- package/dist/_app_/form/multi-combobox-field.js +1 -0
- package/dist/_app_/form/multi-combobox.js +1 -0
- package/dist/data/{sortable-list-css-211fcfeedc08052ccbac7f51549ce0b1.css → sortable-list-css-03e5d237ea377f7d6056e76cc85b2aaa.css} +8 -4
- package/dist/data/sortable-list.js +1 -1
- package/dist/form/combobox-field.js +37 -0
- package/dist/form/combobox-field.js.map +1 -0
- package/dist/form/combobox-shared.js +76 -0
- package/dist/form/combobox-shared.js.map +1 -0
- package/dist/form/combobox.css +345 -0
- package/dist/form/combobox.js +612 -0
- package/dist/form/combobox.js.map +1 -0
- package/dist/form/{display-field-css-890d9be4b5da61613fd017071f330735.css → display-field-css-502236a2343d47e31e52bdb93a769ca1.css} +2 -2
- package/dist/form/display-field.js +1 -1
- package/dist/form/index.js +4 -0
- package/dist/form/index.js.map +1 -1
- package/dist/form/multi-combobox-field.js +36 -0
- package/dist/form/multi-combobox-field.js.map +1 -0
- package/dist/form/multi-combobox.css +422 -0
- package/dist/form/multi-combobox.js +626 -0
- package/dist/form/multi-combobox.js.map +1 -0
- package/dist/layout/h-stack.js.map +1 -1
- package/dist/layout/v-stack.js.map +1 -1
- package/dist/overlay/popover.js +19 -1
- package/package.json +6 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"multi-combobox.d.ts","sourceRoot":"","sources":["../../src/form/multi-combobox.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAU3C,OAAO,EAIL,KAAK,aAAa,EAClB,KAAK,cAAc,EACnB,KAAK,mBAAmB,EACzB,MAAM,sBAAsB,CAAC;AAE9B,YAAY,EAAE,aAAa,EAAE,cAAc,EAAE,mBAAmB,EAAE,CAAC;AASnE,MAAM,WAAW,sBAAsB;IACrC,OAAO,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE;QACJ,6DAA6D;QAC7D,KAAK,EAAE,aAAa,CAAC;QAErB,4CAA4C;QAC5C,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;QAElB,wCAAwC;QACxC,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,EAAE,OAAO,EAAE,cAAc,EAAE,KAAK,IAAI,CAAC;QAEjE;;;WAGG;QACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,aAAa,CAAC,CAAC;QAErD,mEAAmE;QACnE,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAE1B,+BAA+B;QAC/B,SAAS,CAAC,EAAE,OAAO,CAAC;QAEpB;;;;;;WAMG;QACH,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAC;QAEzC,6DAA6D;QAC7D,WAAW,CAAC,EAAE,MAAM,CAAC;QAErB,sCAAsC;QACtC,WAAW,CAAC,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ts","sourceRoot":"","sources":["../../src/layout/h-stack.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,gCAAgC,CAAC;AAG1D,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE;QACJ,GAAG,CAAC,
|
|
1
|
+
{"version":3,"file":"h-stack.d.ts","sourceRoot":"","sources":["../../src/layout/h-stack.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,gCAAgC,CAAC;AAG1D,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE;QACJ,GAAG,CAAC,EACA,MAAM,GACN,KAAK,GACL,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,CAAC;QACV,KAAK,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,SAAS,GAAG,UAAU,CAAC;QAC5D,OAAO,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,SAAS,CAAC;QACjD,IAAI,CAAC,EAAE,OAAO,CAAC;QACf,MAAM,CAAC,EAAE,OAAO,CAAC;KAClB,CAAC;IACF,MAAM,EAAE;QACN,OAAO,EAAE,EAAE,CAAC;KACb,CAAC;CACH;AAED,QAAA,MAAM,MAAM,EAAE,GAAG,CAAC,eAAe,CAW/B,CAAC;AAEH,eAAe,MAAM,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stack.d.ts","sourceRoot":"","sources":["../../src/layout/stack.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAE3C,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE;QACJ,SAAS,EAAE,KAAK,GAAG,QAAQ,CAAC;QAC5B,GAAG,CAAC,
|
|
1
|
+
{"version":3,"file":"stack.d.ts","sourceRoot":"","sources":["../../src/layout/stack.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAE3C,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE;QACJ,SAAS,EAAE,KAAK,GAAG,QAAQ,CAAC;QAC5B,GAAG,CAAC,EACA,MAAM,GACN,KAAK,GACL,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,CAAC;QACV,KAAK,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,SAAS,GAAG,UAAU,CAAC;QAC5D,OAAO,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,SAAS,CAAC;QACjD,IAAI,CAAC,EAAE,OAAO,CAAC;QACf,MAAM,CAAC,EAAE,OAAO,CAAC;KAClB,CAAC;IACF,MAAM,EAAE;QACN,OAAO,EAAE,EAAE,CAAC;KACb,CAAC;CACH;AAED,MAAM,CAAC,OAAO,OAAO,KAAM,SAAQ,SAAS,CAAC,cAAc,CAAC;IAC1D,IAAI,GAAG,sFAEN;IAED,IAAI,KAAK,wDAIR;IAED,IAAI,OAAO,2CAEV;IAED,IAAI,IAAI,YAEP;IAED,IAAI,MAAM,YAET;CAyBF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"v-stack.d.ts","sourceRoot":"","sources":["../../src/layout/v-stack.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,gCAAgC,CAAC;AAG1D,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE;QACJ,GAAG,CAAC,
|
|
1
|
+
{"version":3,"file":"v-stack.d.ts","sourceRoot":"","sources":["../../src/layout/v-stack.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,gCAAgC,CAAC;AAG1D,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,cAAc,CAAC;IACxB,IAAI,EAAE;QACJ,GAAG,CAAC,EACA,MAAM,GACN,KAAK,GACL,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,CAAC;QACV,KAAK,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,SAAS,CAAC;QAC/C,OAAO,CAAC,EAAE,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,SAAS,CAAC;QACjD,MAAM,CAAC,EAAE,OAAO,CAAC;KAClB,CAAC;IACF,MAAM,EAAE;QACN,OAAO,EAAE,EAAE,CAAC;KACb,CAAC;CACH;AAED,QAAA,MAAM,MAAM,EAAE,GAAG,CAAC,eAAe,CAW/B,CAAC;AAEH,eAAe,MAAM,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import Component from '@glimmer/component';
|
|
2
|
-
import type { WithBoundArgs } from '@glint/template';
|
|
2
|
+
import type { ModifierLike, WithBoundArgs } from '@glint/template';
|
|
3
3
|
import { type Placement, type OffsetOptions, type FlipOptions, type ShiftOptions, type Middleware } from '@floating-ui/dom';
|
|
4
4
|
export type PopoverSide = 'top' | 'right' | 'bottom' | 'left';
|
|
5
5
|
export type PopoverAlign = 'start' | 'center' | 'end';
|
|
@@ -43,6 +43,16 @@ export interface PopoverSignature {
|
|
|
43
43
|
Trigger: WithBoundArgs<typeof PopoverTrigger, 'ctx'>;
|
|
44
44
|
Content: WithBoundArgs<typeof PopoverContent, 'ctx'>;
|
|
45
45
|
Close: WithBoundArgs<typeof PopoverClose, 'ctx'>;
|
|
46
|
+
/**
|
|
47
|
+
* Modifier for registering a custom (non-Trigger) element as the
|
|
48
|
+
* popover's anchor. Use this when `<popover.Trigger>` (which
|
|
49
|
+
* renders a `<button>`) is the wrong element type — e.g.,
|
|
50
|
+
* anchoring to an `<input>` inside a combobox where nesting
|
|
51
|
+
* `<input>` inside `<button>` is invalid HTML.
|
|
52
|
+
*/
|
|
53
|
+
registerTrigger: ModifierLike<{
|
|
54
|
+
Element: HTMLElement;
|
|
55
|
+
}>;
|
|
46
56
|
isOpen: boolean;
|
|
47
57
|
open: () => void;
|
|
48
58
|
close: () => void;
|
|
@@ -176,6 +186,15 @@ export default class Popover extends Component<PopoverSignature> {
|
|
|
176
186
|
Element: HTMLElement;
|
|
177
187
|
}>;
|
|
178
188
|
registerTrigger: (element: HTMLElement) => void;
|
|
189
|
+
/**
|
|
190
|
+
* Yielded modifier for registering an arbitrary element as the popover
|
|
191
|
+
* trigger. Useful for consumers who can't (or shouldn't) use the
|
|
192
|
+
* `<popover.Trigger>` button — e.g., a combobox where the trigger IS
|
|
193
|
+
* an `<input>`.
|
|
194
|
+
*/
|
|
195
|
+
registerTriggerModifier: ModifierLike<{
|
|
196
|
+
Element: HTMLElement;
|
|
197
|
+
}>;
|
|
179
198
|
get isOpenInternal(): boolean;
|
|
180
199
|
set isOpenInternal(value: boolean);
|
|
181
200
|
get isControlled(): boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"popover.d.ts","sourceRoot":"","sources":["../../src/overlay/popover.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAK3C,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"popover.d.ts","sourceRoot":"","sources":["../../src/overlay/popover.ts"],"names":[],"mappings":"AAAA,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAK3C,OAAO,KAAK,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AACnE,OAAO,EAEL,KAAK,SAAS,EACd,KAAK,aAAa,EAClB,KAAK,WAAW,EAChB,KAAK,YAAY,EACjB,KAAK,UAAU,EAChB,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AAC,KAAK,EAAE,OAAO,EAEhC;IAED,IAAI,YAAY,IAAI,OAAO,CAE1B;IAED,IAAI,MAAM,IAAI,OAAO,CAEpB;IAED,IAAI,WAAW,IAAI,kBAAkB,CAEpC;IAED,IAAI,qBAAqB,IAAI,OAAO,CAEnC;IAED,IAAI,eAAe,IAAI,OAAO,CAE7B;IAED,IAAI,SAAS,IAAI,MAAM,CAEtB;IAED,IAAI,UAAU,IAAI,MAAM,CAEvB;IAED,OAAO,UAAW,OAAO,KAAG,IAAI,CAK9B;IAEF,WAAW,QAAO,IAAI,CASpB;IAEF,YAAY,QAAO,IAAI,CASrB;IAEF,aAAa,QAAO,IAAI,CAMtB;IAEF,OAAO,CAAC,aAAa;IAWrB,kBAAkB,UAAW,UAAU,KAAG,IAAI,CAW5C;IAEF,aAAa,UAAW,aAAa,KAAG,IAAI,CAS1C;IAEF,sBAAsB,YAAa,WAAW,GAAG,IAAI,KAAG,IAAI,CAE1D;IAEF,IAAI,OAAO,IAAI,cAAc,CAa5B;CAwBF;AAED,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,YAAY,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from "@visitwonders/assembly/form/combobox-field";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from "@visitwonders/assembly/form/combobox-shared";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from "@visitwonders/assembly/form/combobox";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from "@visitwonders/assembly/form/multi-combobox-field";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default } from "@visitwonders/assembly/form/multi-combobox";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* <inline>/src/data/sortable-list-css-
|
|
1
|
+
/* <inline>/src/data/sortable-list-css-03e5d237ea377f7d6056e76cc85b2aaa.css */
|
|
2
2
|
|
|
3
3
|
.sortable-list_ebb0a8898 {
|
|
4
4
|
display: flex;
|
|
@@ -15,7 +15,8 @@
|
|
|
15
15
|
display: flex;
|
|
16
16
|
align-items: center;
|
|
17
17
|
gap: var(--spacing-3);
|
|
18
|
-
padding: var(--spacing-3) var(--spacing-4) var(--spacing-3)
|
|
18
|
+
padding: var(--spacing-3) var(--spacing-4) var(--spacing-3)
|
|
19
|
+
var(--spacing-10);
|
|
19
20
|
background: var(--color-bg-surface);
|
|
20
21
|
border: var(--border-width-1) solid var(--color-border-subtle);
|
|
21
22
|
border-radius: var(--radius-md);
|
|
@@ -38,7 +39,9 @@
|
|
|
38
39
|
border-bottom-right-radius: 0;
|
|
39
40
|
}
|
|
40
41
|
|
|
41
|
-
.sortable-list_ebb0a8898[data-direction="horizontal"]
|
|
42
|
+
.sortable-list_ebb0a8898[data-direction="horizontal"]
|
|
43
|
+
.sortable-item_ebb0a8898
|
|
44
|
+
+ .sortable-item_ebb0a8898 {
|
|
42
45
|
margin-top: 0;
|
|
43
46
|
margin-left: calc(-1 * var(--border-width-1));
|
|
44
47
|
border-top-left-radius: 0;
|
|
@@ -47,7 +50,8 @@
|
|
|
47
50
|
border-bottom-right-radius: var(--radius-md);
|
|
48
51
|
}
|
|
49
52
|
|
|
50
|
-
.sortable-list_ebb0a8898[data-direction="horizontal"]
|
|
53
|
+
.sortable-list_ebb0a8898[data-direction="horizontal"]
|
|
54
|
+
.sortable-item_ebb0a8898:has(+ .sortable-item_ebb0a8898) {
|
|
51
55
|
border-top-right-radius: 0;
|
|
52
56
|
border-bottom-right-radius: 0;
|
|
53
57
|
border-top-left-radius: var(--radius-md);
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import Component from '@glimmer/component';
|
|
2
|
+
import Control from './control.js';
|
|
3
|
+
import ComboBox from './combobox.js';
|
|
4
|
+
import { precompileTemplate } from '@ember/template-compilation';
|
|
5
|
+
import { setComponentTemplate } from '@ember/component';
|
|
6
|
+
|
|
7
|
+
class ComboBoxField extends Component {
|
|
8
|
+
get isInvalid() {
|
|
9
|
+
return !!this.args.error;
|
|
10
|
+
}
|
|
11
|
+
get isLabelHidden() {
|
|
12
|
+
return this.args.labelVisibility === 'hidden';
|
|
13
|
+
}
|
|
14
|
+
/** Build aria-describedby from the control's help text and error IDs. */
|
|
15
|
+
getAriaDescribedBy = controlId => {
|
|
16
|
+
const parts = [];
|
|
17
|
+
if (this.args.helpText) {
|
|
18
|
+
parts.push(`${controlId}-help-text`);
|
|
19
|
+
}
|
|
20
|
+
if (this.args.error) {
|
|
21
|
+
parts.push(`${controlId}-error-message`);
|
|
22
|
+
}
|
|
23
|
+
return parts.length > 0 ? parts.join(' ') : undefined;
|
|
24
|
+
};
|
|
25
|
+
static {
|
|
26
|
+
setComponentTemplate(precompileTemplate("<Control @isInvalid={{this.isInvalid}} @isDisabled={{@isDisabled}} @isRequired={{@isRequired}} @labelInfo={{@labelInfo}} ...attributes as |ctrl|>\n {{#if (has-block \"info\")}}\n <ctrl.Label @isVisuallyHidden={{this.isLabelHidden}}>\n <:default>{{@label}}</:default>\n <:info>{{yield to=\"info\"}}</:info>\n </ctrl.Label>\n {{else}}\n <ctrl.Label @isVisuallyHidden={{this.isLabelHidden}}>\n {{@label}}\n </ctrl.Label>\n {{/if}}\n\n <ComboBox @id={{ctrl.id}} @name={{@name}} @items={{@items}} @value={{@value}} @placeholder={{@placeholder}} @noResultsText={{@noResultsText}} @onSearch={{@onSearch}} @searchDebounceMs={{@searchDebounceMs}} @isLoading={{@isLoading}} @onSearchError={{@onSearchError}} @loadingText={{@loadingText}} @isCreatable={{@isCreatable}} @onCreate={{@onCreate}} @createLabel={{@createLabel}} @isDisabled={{@isDisabled}} @isInvalid={{this.isInvalid}} @isRequired={{@isRequired}} @isClearable={{@isClearable}} @aria-describedby={{this.getAriaDescribedBy ctrl.id}} @onChange={{@onChange}} @onBlur={{@onBlur}} @onFocus={{@onFocus}} @onOpen={{@onOpen}} @onClose={{@onClose}} data-test-combobox-field />\n\n {{#if @helpText}}\n <ctrl.HelpText>{{@helpText}}</ctrl.HelpText>\n {{/if}}\n\n {{#if @error}}\n <ctrl.ErrorMessage>{{@error}}</ctrl.ErrorMessage>\n {{/if}}\n</Control>", {
|
|
27
|
+
strictMode: true,
|
|
28
|
+
scope: () => ({
|
|
29
|
+
Control,
|
|
30
|
+
ComboBox
|
|
31
|
+
})
|
|
32
|
+
}), this);
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export { ComboBoxField as default };
|
|
37
|
+
//# sourceMappingURL=combobox-field.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"combobox-field.js","sources":["../../src/form/combobox-field.gts"],"sourcesContent":["import Component from '@glimmer/component';\n\nimport Control from './control.gts';\nimport ComboBox from './combobox.gts';\nimport type { ComboBoxItems, ComboBoxOption } from './combobox-shared.ts';\n\nexport type LabelVisibility = 'visible' | 'hidden';\n\nexport interface ComboBoxFieldSignature {\n Element: HTMLDivElement;\n Args: {\n /** Label text (required). */\n label: string;\n\n /** Available options. Flat or pre-grouped. */\n items: ComboBoxItems;\n\n /** Current selected value (controlled). */\n value?: string | null;\n\n /** Fires when the selection changes. */\n onChange?: (value: string | null, option: ComboBoxOption | null) => void;\n\n /** Async search (passed through to ComboBox). */\n onSearch?: (query: string) => Promise<ComboBoxItems>;\n\n /** Debounce for `onSearch` in ms. */\n searchDebounceMs?: number;\n\n /** Force the loading state. */\n isLoading?: boolean;\n\n /** Called when an `onSearch` promise rejects. */\n onSearchError?: (error: unknown) => void;\n\n /** Loading row text. */\n loadingText?: string;\n\n /** Input placeholder. */\n placeholder?: string;\n\n /** Empty state text. */\n noResultsText?: string;\n\n /** Allow creating new options from a non-matching query. */\n isCreatable?: boolean;\n\n /** Fires when the user activates the create row. */\n onCreate?: (query: string) => void;\n\n /** Build the create-row label. */\n createLabel?: (query: string) => string;\n\n /** Help text displayed below the control. */\n helpText?: string;\n\n /** Error message (also sets invalid state). */\n error?: string;\n\n /** Field is required. */\n isRequired?: boolean;\n\n /** Field is disabled. */\n isDisabled?: boolean;\n\n /** Show the clear button when a value is set. */\n isClearable?: boolean;\n\n /** Info tooltip text shown next to the label. */\n labelInfo?: string;\n\n /** Label visibility. */\n labelVisibility?: LabelVisibility;\n\n /** Input name for forms. */\n name?: string;\n\n /** Blur event handler. */\n onBlur?: (event: FocusEvent) => void;\n\n /** Focus event handler. */\n onFocus?: (event: FocusEvent) => void;\n\n /** Fires when the dropdown opens. */\n onOpen?: () => void;\n\n /** Fires when the dropdown closes. */\n onClose?: () => void;\n };\n Blocks: {\n /** Rich tooltip content shown next to the label. */\n info: [];\n };\n}\n\nexport default class ComboBoxField extends Component<ComboBoxFieldSignature> {\n get isInvalid(): boolean {\n return !!this.args.error;\n }\n\n get isLabelHidden(): boolean {\n return this.args.labelVisibility === 'hidden';\n }\n\n /** Build aria-describedby from the control's help text and error IDs. */\n getAriaDescribedBy = (controlId: string): string | undefined => {\n const parts: string[] = [];\n if (this.args.helpText) {\n parts.push(`${controlId}-help-text`);\n }\n if (this.args.error) {\n parts.push(`${controlId}-error-message`);\n }\n return parts.length > 0 ? parts.join(' ') : undefined;\n };\n\n <template>\n <Control\n @isInvalid={{this.isInvalid}}\n @isDisabled={{@isDisabled}}\n @isRequired={{@isRequired}}\n @labelInfo={{@labelInfo}}\n ...attributes\n as |ctrl|\n >\n {{#if (has-block \"info\")}}\n <ctrl.Label @isVisuallyHidden={{this.isLabelHidden}}>\n <:default>{{@label}}</:default>\n <:info>{{yield to=\"info\"}}</:info>\n </ctrl.Label>\n {{else}}\n <ctrl.Label @isVisuallyHidden={{this.isLabelHidden}}>\n {{@label}}\n </ctrl.Label>\n {{/if}}\n\n <ComboBox\n @id={{ctrl.id}}\n @name={{@name}}\n @items={{@items}}\n @value={{@value}}\n @placeholder={{@placeholder}}\n @noResultsText={{@noResultsText}}\n @onSearch={{@onSearch}}\n @searchDebounceMs={{@searchDebounceMs}}\n @isLoading={{@isLoading}}\n @onSearchError={{@onSearchError}}\n @loadingText={{@loadingText}}\n @isCreatable={{@isCreatable}}\n @onCreate={{@onCreate}}\n @createLabel={{@createLabel}}\n @isDisabled={{@isDisabled}}\n @isInvalid={{this.isInvalid}}\n @isRequired={{@isRequired}}\n @isClearable={{@isClearable}}\n @aria-describedby={{this.getAriaDescribedBy ctrl.id}}\n @onChange={{@onChange}}\n @onBlur={{@onBlur}}\n @onFocus={{@onFocus}}\n @onOpen={{@onOpen}}\n @onClose={{@onClose}}\n data-test-combobox-field\n />\n\n {{#if @helpText}}\n <ctrl.HelpText>{{@helpText}}</ctrl.HelpText>\n {{/if}}\n\n {{#if @error}}\n <ctrl.ErrorMessage>{{@error}}</ctrl.ErrorMessage>\n {{/if}}\n </Control>\n </template>\n}\n"],"names":["ComboBoxField","Component","isInvalid","args","error","isLabelHidden","labelVisibility","getAriaDescribedBy","controlId","parts","helpText","push","length","join","undefined","setComponentTemplate","precompileTemplate","strictMode","scope","Control","ComboBox"],"mappings":";;;;;;AA+Fe,MAAMA,sBAAsBC,SAAA,CAAU;EACnD,IAAIC,SAAAA,GAAqB;AACvB,IAAA,OAAO,CAAC,CAAC,IAAI,CAACC,IAAI,CAACC,KAAK;AAC1B,EAAA;EAEA,IAAIC,aAAAA,GAAyB;AAC3B,IAAA,OAAO,IAAI,CAACF,IAAI,CAACG,eAAe,KAAK,QAAA;AACvC,EAAA;AAEA;EACAC,qBAAsBC,SAAiB,IAAqB;IAC1D,MAAMC,KAAa,GAAK,EAAE;AAC1B,IAAA,IAAI,IAAI,CAACN,IAAI,CAACO,QAAQ,EAAE;AACtBD,MAAAA,KAAA,CAAME,IAAI,CAAC,CAAA,EAAGH,SAAA,YAAqB,CAAA;AACrC,IAAA;AACA,IAAA,IAAI,IAAI,CAACL,IAAI,CAACC,KAAK,EAAE;AACnBK,MAAAA,KAAA,CAAME,IAAI,CAAC,CAAA,EAAGH,SAAA,gBAAyB,CAAA;AACzC,IAAA;AACA,IAAA,OAAOC,MAAMG,MAAM,GAAG,IAAIH,KAAA,CAAMI,IAAI,CAAC,GAAA,CAAA,GAAOC,SAAA;EAC9C,CAAA;AAEA,EAAA;IAAAC,oBAAA,CAAAC,kBAAA,CAAA,ozCAAA,EAwDA;MAAAC,UAAA,EAAA,IAAA;AAAAC,MAAAA,KAAA,EAAAA,OAAA;QAAAC,OAAA;AAAAC,QAAAA;AAAA,OAAA;KAAU,CAAA,EAAV,IAAW,CAAA;AAAD;AACZ;;;;"}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
// Shared types + helpers used by both ComboBox and MultiComboBox.
|
|
2
|
+
// Pulled out so neither component owns the canonical versions and so
|
|
3
|
+
// consumers can import the types from a neutral module if they want.
|
|
4
|
+
//
|
|
5
|
+
// This module intentionally exports a default (empty object) because
|
|
6
|
+
// the addon's rollup app-reexports pattern (`form/!(index).js`) expects
|
|
7
|
+
// a default export on every file under `src/form/`. There's no runtime
|
|
8
|
+
// behaviour attached; consumers should use the named exports.
|
|
9
|
+
var comboboxShared = {};
|
|
10
|
+
|
|
11
|
+
// ============================================================================
|
|
12
|
+
// Match highlighting
|
|
13
|
+
// ============================================================================
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Splits `label` into alternating match / non-match segments based on a
|
|
17
|
+
* case-insensitive substring search for `query`. Used in templates to
|
|
18
|
+
* render matched substrings in <mark>-style spans.
|
|
19
|
+
*/
|
|
20
|
+
function splitOnMatch(label, query) {
|
|
21
|
+
const trimmed = query.trim();
|
|
22
|
+
if (!trimmed) return [{
|
|
23
|
+
text: label,
|
|
24
|
+
isMatch: false
|
|
25
|
+
}];
|
|
26
|
+
const lowerLabel = label.toLowerCase();
|
|
27
|
+
const lowerQuery = trimmed.toLowerCase();
|
|
28
|
+
const segments = [];
|
|
29
|
+
let cursor = 0;
|
|
30
|
+
while (cursor < label.length) {
|
|
31
|
+
const idx = lowerLabel.indexOf(lowerQuery, cursor);
|
|
32
|
+
if (idx === -1) {
|
|
33
|
+
segments.push({
|
|
34
|
+
text: label.slice(cursor),
|
|
35
|
+
isMatch: false
|
|
36
|
+
});
|
|
37
|
+
break;
|
|
38
|
+
}
|
|
39
|
+
if (idx > cursor) {
|
|
40
|
+
segments.push({
|
|
41
|
+
text: label.slice(cursor, idx),
|
|
42
|
+
isMatch: false
|
|
43
|
+
});
|
|
44
|
+
}
|
|
45
|
+
segments.push({
|
|
46
|
+
text: label.slice(idx, idx + lowerQuery.length),
|
|
47
|
+
isMatch: true
|
|
48
|
+
});
|
|
49
|
+
cursor = idx + lowerQuery.length;
|
|
50
|
+
}
|
|
51
|
+
return segments;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
// ============================================================================
|
|
55
|
+
// Item normalization
|
|
56
|
+
// ============================================================================
|
|
57
|
+
|
|
58
|
+
/** Discriminator for flat option vs grouped option shape. */
|
|
59
|
+
function isOptionGroup(item) {
|
|
60
|
+
return item.options !== undefined;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/** Flatten `ComboBoxItems` to a single array of options regardless of whether
|
|
64
|
+
* the source was grouped. Used for lookups across the whole option universe
|
|
65
|
+
* (e.g., resolving a selected value to its label, duplicate-by-label checks
|
|
66
|
+
* for the create row). */
|
|
67
|
+
function flattenOptions(items) {
|
|
68
|
+
if (items.length === 0) return [];
|
|
69
|
+
if (isOptionGroup(items[0])) {
|
|
70
|
+
return items.flatMap(g => g.options);
|
|
71
|
+
}
|
|
72
|
+
return items;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export { comboboxShared as default, flattenOptions, isOptionGroup, splitOnMatch };
|
|
76
|
+
//# sourceMappingURL=combobox-shared.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"combobox-shared.js","sources":["../../src/form/combobox-shared.ts"],"sourcesContent":["// Shared types + helpers used by both ComboBox and MultiComboBox.\n// Pulled out so neither component owns the canonical versions and so\n// consumers can import the types from a neutral module if they want.\n//\n// This module intentionally exports a default (empty object) because\n// the addon's rollup app-reexports pattern (`form/!(index).js`) expects\n// a default export on every file under `src/form/`. There's no runtime\n// behaviour attached; consumers should use the named exports.\nexport default {};\n\nexport interface ComboBoxOption {\n /** Stable identity — what value / onChange refer to. */\n value: string;\n /** What the user sees in the trigger + option list. */\n label: string;\n /** Optional secondary line shown under the label in the option list. */\n description?: string;\n /** Disabled options render but are not selectable. */\n isDisabled?: boolean;\n}\n\nexport interface ComboBoxOptionGroup {\n /** Heading text shown above the group (non-selectable). */\n label: string;\n options: ComboBoxOption[];\n}\n\nexport type ComboBoxItems = ComboBoxOption[] | ComboBoxOptionGroup[];\n\n// ============================================================================\n// Match highlighting\n// ============================================================================\n\nexport interface MatchSegment {\n text: string;\n isMatch: boolean;\n}\n\n/**\n * Splits `label` into alternating match / non-match segments based on a\n * case-insensitive substring search for `query`. Used in templates to\n * render matched substrings in <mark>-style spans.\n */\nexport function splitOnMatch(label: string, query: string): MatchSegment[] {\n const trimmed = query.trim();\n if (!trimmed) return [{ text: label, isMatch: false }];\n\n const lowerLabel = label.toLowerCase();\n const lowerQuery = trimmed.toLowerCase();\n const segments: MatchSegment[] = [];\n let cursor = 0;\n\n while (cursor < label.length) {\n const idx = lowerLabel.indexOf(lowerQuery, cursor);\n if (idx === -1) {\n segments.push({ text: label.slice(cursor), isMatch: false });\n break;\n }\n if (idx > cursor) {\n segments.push({ text: label.slice(cursor, idx), isMatch: false });\n }\n segments.push({\n text: label.slice(idx, idx + lowerQuery.length),\n isMatch: true,\n });\n cursor = idx + lowerQuery.length;\n }\n\n return segments;\n}\n\n// ============================================================================\n// Item normalization\n// ============================================================================\n\n/** Discriminator for flat option vs grouped option shape. */\nexport function isOptionGroup(\n item: ComboBoxOption | ComboBoxOptionGroup,\n): item is ComboBoxOptionGroup {\n return (item as ComboBoxOptionGroup).options !== undefined;\n}\n\n/** Flatten `ComboBoxItems` to a single array of options regardless of whether\n * the source was grouped. Used for lookups across the whole option universe\n * (e.g., resolving a selected value to its label, duplicate-by-label checks\n * for the create row). */\nexport function flattenOptions(items: ComboBoxItems): ComboBoxOption[] {\n if (items.length === 0) return [];\n if (isOptionGroup(items[0]!)) {\n return (items as ComboBoxOptionGroup[]).flatMap((g) => g.options);\n }\n return items as ComboBoxOption[];\n}\n"],"names":["splitOnMatch","label","query","trimmed","trim","text","isMatch","lowerLabel","toLowerCase","lowerQuery","segments","cursor","length","idx","indexOf","push","slice","isOptionGroup","item","options","undefined","flattenOptions","items","flatMap","g"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qBAAe,EAAE;;AAqBjB;AACA;AACA;;AAOA;AACA;AACA;AACA;AACA;AACO,SAASA,YAAYA,CAACC,KAAa,EAAEC,KAAa,EAAkB;AACzE,EAAA,MAAMC,OAAO,GAAGD,KAAK,CAACE,IAAI,EAAE;AAC5B,EAAA,IAAI,CAACD,OAAO,EAAE,OAAO,CAAC;AAAEE,IAAAA,IAAI,EAAEJ,KAAK;AAAEK,IAAAA,OAAO,EAAE;AAAM,GAAC,CAAC;AAEtD,EAAA,MAAMC,UAAU,GAAGN,KAAK,CAACO,WAAW,EAAE;AACtC,EAAA,MAAMC,UAAU,GAAGN,OAAO,CAACK,WAAW,EAAE;EACxC,MAAME,QAAwB,GAAG,EAAE;EACnC,IAAIC,MAAM,GAAG,CAAC;AAEd,EAAA,OAAOA,MAAM,GAAGV,KAAK,CAACW,MAAM,EAAE;IAC5B,MAAMC,GAAG,GAAGN,UAAU,CAACO,OAAO,CAACL,UAAU,EAAEE,MAAM,CAAC;AAClD,IAAA,IAAIE,GAAG,KAAK,EAAE,EAAE;MACdH,QAAQ,CAACK,IAAI,CAAC;AAAEV,QAAAA,IAAI,EAAEJ,KAAK,CAACe,KAAK,CAACL,MAAM,CAAC;AAAEL,QAAAA,OAAO,EAAE;AAAM,OAAC,CAAC;AAC5D,MAAA;AACF,IAAA;IACA,IAAIO,GAAG,GAAGF,MAAM,EAAE;MAChBD,QAAQ,CAACK,IAAI,CAAC;QAAEV,IAAI,EAAEJ,KAAK,CAACe,KAAK,CAACL,MAAM,EAAEE,GAAG,CAAC;AAAEP,QAAAA,OAAO,EAAE;AAAM,OAAC,CAAC;AACnE,IAAA;IACAI,QAAQ,CAACK,IAAI,CAAC;AACZV,MAAAA,IAAI,EAAEJ,KAAK,CAACe,KAAK,CAACH,GAAG,EAAEA,GAAG,GAAGJ,UAAU,CAACG,MAAM,CAAC;AAC/CN,MAAAA,OAAO,EAAE;AACX,KAAC,CAAC;AACFK,IAAAA,MAAM,GAAGE,GAAG,GAAGJ,UAAU,CAACG,MAAM;AAClC,EAAA;AAEA,EAAA,OAAOF,QAAQ;AACjB;;AAEA;AACA;AACA;;AAEA;AACO,SAASO,aAAaA,CAC3BC,IAA0C,EACb;AAC7B,EAAA,OAAQA,IAAI,CAAyBC,OAAO,KAAKC,SAAS;AAC5D;;AAEA;AACA;AACA;AACA;AACO,SAASC,cAAcA,CAACC,KAAoB,EAAoB;AACrE,EAAA,IAAIA,KAAK,CAACV,MAAM,KAAK,CAAC,EAAE,OAAO,EAAE;AACjC,EAAA,IAAIK,aAAa,CAACK,KAAK,CAAC,CAAC,CAAE,CAAC,EAAE;IAC5B,OAAQA,KAAK,CAA2BC,OAAO,CAAEC,CAAC,IAAKA,CAAC,CAACL,OAAO,CAAC;AACnE,EAAA;AACA,EAAA,OAAOG,KAAK;AACd;;;;"}
|
|
@@ -0,0 +1,345 @@
|
|
|
1
|
+
/* src/form/combobox.css */
|
|
2
|
+
/* ===================================
|
|
3
|
+
* ComboBox Component
|
|
4
|
+
* Searchable single-select with typeahead
|
|
5
|
+
* =================================== */
|
|
6
|
+
|
|
7
|
+
.combobox_e2657ea63 {
|
|
8
|
+
display: inline-flex;
|
|
9
|
+
width: 100%;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
/* Visually-hidden aria-live region used by .combobox for screen-reader
|
|
13
|
+
* result-count announcements. Standard sr-only pattern. */
|
|
14
|
+
.combobox-sr-only_e2657ea63 {
|
|
15
|
+
position: absolute;
|
|
16
|
+
width: 1px;
|
|
17
|
+
height: 1px;
|
|
18
|
+
padding: 0;
|
|
19
|
+
margin: -1px;
|
|
20
|
+
overflow: hidden;
|
|
21
|
+
clip: rect(0, 0, 0, 0);
|
|
22
|
+
white-space: nowrap;
|
|
23
|
+
border: 0;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/* ===================================
|
|
27
|
+
* Trigger wrapper — looks like a TextField, contains the input
|
|
28
|
+
* and the chevron + clear affordances.
|
|
29
|
+
* =================================== */
|
|
30
|
+
|
|
31
|
+
.combobox_e2657ea63 .combobox-trigger_e2657ea63 {
|
|
32
|
+
position: relative;
|
|
33
|
+
display: flex;
|
|
34
|
+
align-items: center;
|
|
35
|
+
width: 100%;
|
|
36
|
+
height: var(--input-height-md);
|
|
37
|
+
border: var(--border-width-1) solid var(--color-border-control);
|
|
38
|
+
border-radius: var(--radius-md);
|
|
39
|
+
background-color: var(--color-bg);
|
|
40
|
+
transition:
|
|
41
|
+
border-color var(--transition-fast),
|
|
42
|
+
box-shadow var(--transition-fast);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.combobox_e2657ea63 .combobox-trigger_e2657ea63:hover:not([data-disabled="true"]) {
|
|
46
|
+
border-color: var(--color-border-control-hover);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.combobox_e2657ea63 .combobox-trigger_e2657ea63:focus-within {
|
|
50
|
+
border-color: var(--color-border-focus);
|
|
51
|
+
box-shadow: var(--focus-ring);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
/* ===================================
|
|
55
|
+
* Input — the trigger AND the search field, per the WAI-ARIA
|
|
56
|
+
* "Editable Combobox With List Autocomplete" pattern.
|
|
57
|
+
* =================================== */
|
|
58
|
+
|
|
59
|
+
.combobox-input_e2657ea63 {
|
|
60
|
+
flex: 1;
|
|
61
|
+
min-width: 0;
|
|
62
|
+
height: 100%;
|
|
63
|
+
padding: 0 var(--input-padding-horizontal-md);
|
|
64
|
+
border: none;
|
|
65
|
+
background: transparent;
|
|
66
|
+
font-family: inherit;
|
|
67
|
+
font-size: var(--font-size-md);
|
|
68
|
+
line-height: var(--line-height-tight);
|
|
69
|
+
color: var(--color-text);
|
|
70
|
+
text-overflow: ellipsis;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/* Suppress the input's own focus ring — the wrapper (:focus-within)
|
|
74
|
+
owns the focused look. Chrome re-applies `outline: auto` on
|
|
75
|
+
:focus-visible even when the base rule declares `outline: none`,
|
|
76
|
+
which produced a stray inner blue rectangle inside the wrapper's
|
|
77
|
+
border. Nuke it at both states to be safe. */
|
|
78
|
+
.combobox-input_e2657ea63,
|
|
79
|
+
.combobox-input_e2657ea63:focus,
|
|
80
|
+
.combobox-input_e2657ea63:focus-visible {
|
|
81
|
+
outline: none;
|
|
82
|
+
box-shadow: none;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.combobox-input_e2657ea63::placeholder {
|
|
86
|
+
color: var(--color-text-tertiary);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.combobox-input_e2657ea63:disabled {
|
|
90
|
+
cursor: not-allowed;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
/* When trailing affordances are present, leave room for them so the
|
|
94
|
+
* typed text doesn't slide under the icons. */
|
|
95
|
+
.combobox-input_e2657ea63 {
|
|
96
|
+
padding-right: var(--spacing-1);
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
/* ===================================
|
|
100
|
+
* Clear Button
|
|
101
|
+
* =================================== */
|
|
102
|
+
|
|
103
|
+
.combobox-clear_e2657ea63,
|
|
104
|
+
.combobox-chevron_e2657ea63 {
|
|
105
|
+
flex-shrink: 0;
|
|
106
|
+
display: inline-flex;
|
|
107
|
+
align-items: center;
|
|
108
|
+
justify-content: center;
|
|
109
|
+
width: 24px;
|
|
110
|
+
height: 24px;
|
|
111
|
+
padding: 0;
|
|
112
|
+
margin: 0 2px;
|
|
113
|
+
border: none;
|
|
114
|
+
background: transparent;
|
|
115
|
+
color: var(--color-text-tertiary);
|
|
116
|
+
cursor: pointer;
|
|
117
|
+
border-radius: var(--radius-sm);
|
|
118
|
+
transition: color var(--transition-fast);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.combobox-clear_e2657ea63:hover,
|
|
122
|
+
.combobox-chevron_e2657ea63:hover:not(:disabled) {
|
|
123
|
+
color: var(--color-text);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.combobox-chevron_e2657ea63 {
|
|
127
|
+
margin-right: var(--spacing-1);
|
|
128
|
+
transition:
|
|
129
|
+
transform var(--transition-fast),
|
|
130
|
+
color var(--transition-fast);
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.combobox_e2657ea63[data-open="true"] .combobox-chevron_e2657ea63 {
|
|
134
|
+
transform: rotate(180deg);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.combobox-chevron_e2657ea63:disabled {
|
|
138
|
+
color: var(--color-text-disabled);
|
|
139
|
+
cursor: not-allowed;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
/* ===================================
|
|
143
|
+
* Invalid State
|
|
144
|
+
* =================================== */
|
|
145
|
+
|
|
146
|
+
.combobox_e2657ea63[data-invalid="true"] .combobox-trigger_e2657ea63 {
|
|
147
|
+
border-color: var(--color-border-critical);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.combobox_e2657ea63[data-invalid="true"] .combobox-trigger_e2657ea63:focus-within {
|
|
151
|
+
border-color: var(--color-border-critical);
|
|
152
|
+
box-shadow: var(--focus-ring-critical);
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
/* ===================================
|
|
156
|
+
* Disabled State
|
|
157
|
+
* =================================== */
|
|
158
|
+
|
|
159
|
+
.combobox_e2657ea63[data-disabled="true"] .combobox-trigger_e2657ea63 {
|
|
160
|
+
background-color: var(--color-bg-disabled);
|
|
161
|
+
border-color: var(--color-border-control-disabled);
|
|
162
|
+
cursor: not-allowed;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.combobox_e2657ea63[data-disabled="true"] .combobox-input_e2657ea63 {
|
|
166
|
+
color: var(--color-text-disabled);
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
/* ===================================
|
|
170
|
+
* Popover Content
|
|
171
|
+
* =================================== */
|
|
172
|
+
|
|
173
|
+
.combobox-popover-content_e2657ea63 {
|
|
174
|
+
min-width: 240px;
|
|
175
|
+
max-height: min(320px, 40vh);
|
|
176
|
+
display: flex;
|
|
177
|
+
flex-direction: column;
|
|
178
|
+
padding: 0;
|
|
179
|
+
overflow: hidden;
|
|
180
|
+
/* Anchor the open-scale animation to the top-left edge so it appears
|
|
181
|
+
* to emerge from the trigger (which is left-aligned) rather than
|
|
182
|
+
* inflate from its own centre. */
|
|
183
|
+
transform-origin: top left;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.combobox-listbox_e2657ea63 {
|
|
187
|
+
flex: 1;
|
|
188
|
+
min-height: 0;
|
|
189
|
+
overflow-y: auto;
|
|
190
|
+
padding: var(--spacing-2) var(--spacing-1);
|
|
191
|
+
/* Keep the active row comfortably away from the scroll edges when
|
|
192
|
+
* keyboard nav brings it into view (scrollIntoView({ block: 'nearest' })). */
|
|
193
|
+
scroll-padding-block: var(--spacing-2);
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
/* ===================================
|
|
197
|
+
* Empty / Loading State
|
|
198
|
+
* =================================== */
|
|
199
|
+
|
|
200
|
+
.combobox-empty_e2657ea63,
|
|
201
|
+
.combobox-loading_e2657ea63 {
|
|
202
|
+
padding: var(--spacing-3);
|
|
203
|
+
text-align: center;
|
|
204
|
+
color: var(--color-text-tertiary);
|
|
205
|
+
font-size: var(--font-size-13);
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
/* ===================================
|
|
209
|
+
* Groups
|
|
210
|
+
* =================================== */
|
|
211
|
+
|
|
212
|
+
.combobox-group_e2657ea63:not(:first-child) {
|
|
213
|
+
border-top: 1px solid var(--color-border-subtle);
|
|
214
|
+
margin-top: var(--spacing-1);
|
|
215
|
+
padding-top: var(--spacing-1);
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
.combobox-group-heading_e2657ea63 {
|
|
219
|
+
padding: var(--spacing-2) var(--spacing-3) var(--spacing-1);
|
|
220
|
+
font-size: var(--font-size-11);
|
|
221
|
+
font-weight: var(--font-weight-medium);
|
|
222
|
+
color: var(--color-text-tertiary);
|
|
223
|
+
text-transform: uppercase;
|
|
224
|
+
letter-spacing: 0.05em;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
/* ===================================
|
|
228
|
+
* Create row
|
|
229
|
+
* =================================== */
|
|
230
|
+
|
|
231
|
+
.combobox-create_e2657ea63 {
|
|
232
|
+
border-top: 1px solid var(--color-border-subtle);
|
|
233
|
+
margin-top: var(--spacing-1);
|
|
234
|
+
padding-top: var(--spacing-2);
|
|
235
|
+
color: var(--color-text-accent);
|
|
236
|
+
font-weight: var(--font-weight-medium);
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
.combobox-create-icon_e2657ea63 {
|
|
240
|
+
flex-shrink: 0;
|
|
241
|
+
display: inline-flex;
|
|
242
|
+
align-items: center;
|
|
243
|
+
justify-content: center;
|
|
244
|
+
width: 16px;
|
|
245
|
+
height: 16px;
|
|
246
|
+
font-size: var(--font-size-md);
|
|
247
|
+
line-height: 1;
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
/* ===================================
|
|
251
|
+
* Options
|
|
252
|
+
* =================================== */
|
|
253
|
+
|
|
254
|
+
.combobox-option_e2657ea63 {
|
|
255
|
+
display: flex;
|
|
256
|
+
align-items: flex-start;
|
|
257
|
+
justify-content: space-between;
|
|
258
|
+
gap: var(--spacing-2);
|
|
259
|
+
padding: var(--spacing-2) var(--spacing-3);
|
|
260
|
+
border-radius: var(--radius-sm);
|
|
261
|
+
font-size: var(--font-size-13);
|
|
262
|
+
line-height: var(--line-height-tight);
|
|
263
|
+
color: var(--color-text);
|
|
264
|
+
cursor: pointer;
|
|
265
|
+
user-select: none;
|
|
266
|
+
transition: background-color var(--transition-fast);
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
.combobox-option_e2657ea63:hover:not([data-disabled="true"]) {
|
|
270
|
+
background-color: var(--color-bg-neutral-subtle);
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
.combobox-option_e2657ea63[data-active="true"]:not([data-disabled="true"]) {
|
|
274
|
+
background-color: var(--color-bg-neutral-subtle);
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
.combobox-option_e2657ea63[data-selected="true"] {
|
|
278
|
+
color: var(--color-text-accent);
|
|
279
|
+
font-weight: var(--font-weight-medium);
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
.combobox-option_e2657ea63[data-disabled="true"] {
|
|
283
|
+
color: var(--color-text-disabled);
|
|
284
|
+
cursor: not-allowed;
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
.combobox-option-content_e2657ea63 {
|
|
288
|
+
flex: 1;
|
|
289
|
+
min-width: 0;
|
|
290
|
+
display: flex;
|
|
291
|
+
flex-direction: column;
|
|
292
|
+
gap: 2px;
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
.combobox-option-label_e2657ea63 {
|
|
296
|
+
display: block;
|
|
297
|
+
overflow: hidden;
|
|
298
|
+
text-overflow: ellipsis;
|
|
299
|
+
white-space: nowrap;
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
.combobox-option-description_e2657ea63 {
|
|
303
|
+
display: block;
|
|
304
|
+
font-size: var(--font-size-11);
|
|
305
|
+
font-weight: var(--font-weight-regular);
|
|
306
|
+
color: var(--color-text-tertiary);
|
|
307
|
+
overflow: hidden;
|
|
308
|
+
text-overflow: ellipsis;
|
|
309
|
+
white-space: nowrap;
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
/* ===================================
|
|
313
|
+
* Match highlight
|
|
314
|
+
* =================================== */
|
|
315
|
+
|
|
316
|
+
.combobox-mark_e2657ea63 {
|
|
317
|
+
background: transparent;
|
|
318
|
+
color: inherit;
|
|
319
|
+
font-weight: var(--font-weight-bold);
|
|
320
|
+
padding: 0;
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
/* ===================================
|
|
324
|
+
* Checkmark indicator
|
|
325
|
+
* =================================== */
|
|
326
|
+
|
|
327
|
+
.combobox-option-check_e2657ea63 {
|
|
328
|
+
flex-shrink: 0;
|
|
329
|
+
width: 16px;
|
|
330
|
+
height: 16px;
|
|
331
|
+
position: relative;
|
|
332
|
+
margin-top: 2px;
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
.combobox-option-check_e2657ea63::before {
|
|
336
|
+
content: "";
|
|
337
|
+
position: absolute;
|
|
338
|
+
left: 5px;
|
|
339
|
+
top: 2px;
|
|
340
|
+
width: 5px;
|
|
341
|
+
height: 10px;
|
|
342
|
+
border: solid currentColor;
|
|
343
|
+
border-width: 0 2px 2px 0;
|
|
344
|
+
transform: rotate(45deg);
|
|
345
|
+
}
|