@nvidia-elements/core 0.1.1 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +30 -0
- package/dist/_virtual/{_@oxc-project_runtime@0.128.0 → _@oxc-project_runtime@0.130.0}/helpers/decorate.js +1 -1
- package/dist/accordion/accordion2.js +5 -5
- package/dist/accordion/accordion2.js.map +1 -1
- package/dist/accordion/define.js.map +1 -1
- package/dist/alert/alert-group2.js +2 -2
- package/dist/alert/alert-group2.js.map +1 -1
- package/dist/alert/alert2.js +2 -2
- package/dist/alert/alert2.js.map +1 -1
- package/dist/alert/define.js.map +1 -1
- package/dist/avatar/avatar-group2.js +1 -1
- package/dist/avatar/avatar-group2.js.map +1 -1
- package/dist/avatar/avatar2.js +2 -2
- package/dist/avatar/avatar2.js.map +1 -1
- package/dist/avatar/define.js.map +1 -1
- package/dist/badge/badge2.js +2 -2
- package/dist/badge/badge2.js.map +1 -1
- package/dist/badge/define.js.map +1 -1
- package/dist/breadcrumb/breadcrumb2.js +2 -2
- package/dist/breadcrumb/breadcrumb2.js.map +1 -1
- package/dist/breadcrumb/define.js.map +1 -1
- package/dist/bundles/index.d.ts +6 -1
- package/dist/bundles/index.js +4 -4
- package/dist/button/button.js +1 -1
- package/dist/button/button.js.map +1 -1
- package/dist/button/button2.js +2 -2
- package/dist/button/button2.js.map +1 -1
- package/dist/button/define.js.map +1 -1
- package/dist/button-group/button-group2.js +2 -2
- package/dist/button-group/button-group2.js.map +1 -1
- package/dist/button-group/define.js.map +1 -1
- package/dist/card/card2.js +5 -5
- package/dist/card/card2.js.map +1 -1
- package/dist/card/define.js.map +1 -1
- package/dist/chat-message/chat-message2.js +2 -2
- package/dist/chat-message/chat-message2.js.map +1 -1
- package/dist/chat-message/define.js.map +1 -1
- package/dist/checkbox/checkbox-group2.js +2 -2
- package/dist/checkbox/checkbox-group2.js.map +1 -1
- package/dist/checkbox/checkbox2.js +2 -2
- package/dist/checkbox/checkbox2.js.map +1 -1
- package/dist/checkbox/define.js.map +1 -1
- package/dist/color/color2.js +2 -2
- package/dist/color/color2.js.map +1 -1
- package/dist/color/define.js.map +1 -1
- package/dist/combobox/combobox2.js +2 -2
- package/dist/combobox/combobox2.js.map +1 -1
- package/dist/combobox/define.js.map +1 -1
- package/dist/copy-button/copy-button2.js +2 -2
- package/dist/copy-button/copy-button2.js.map +1 -1
- package/dist/copy-button/define.js.map +1 -1
- package/dist/custom-elements-jsx.d.ts +24 -33
- package/dist/custom-elements-vue.d.ts +24 -33
- package/dist/custom-elements.json +255 -118
- package/dist/data.html.json +16 -48
- package/dist/data.snippets.json +18 -18
- package/dist/date/date2.js +2 -2
- package/dist/date/date2.js.map +1 -1
- package/dist/date/define.js.map +1 -1
- package/dist/datetime/datetime2.js +2 -2
- package/dist/datetime/datetime2.js.map +1 -1
- package/dist/datetime/define.js.map +1 -1
- package/dist/dialog/define.js.map +1 -1
- package/dist/dialog/dialog-footer2.js +2 -2
- package/dist/dialog/dialog-footer2.js.map +1 -1
- package/dist/dialog/dialog-header2.js +2 -2
- package/dist/dialog/dialog-header2.js.map +1 -1
- package/dist/dialog/dialog2.js +2 -2
- package/dist/dialog/dialog2.js.map +1 -1
- package/dist/divider/define.js.map +1 -1
- package/dist/divider/divider2.js +2 -2
- package/dist/divider/divider2.js.map +1 -1
- package/dist/dot/define.js.map +1 -1
- package/dist/dot/dot2.js +2 -2
- package/dist/dot/dot2.js.map +1 -1
- package/dist/drawer/define.js.map +1 -1
- package/dist/drawer/drawer-content2.js +2 -2
- package/dist/drawer/drawer-content2.js.map +1 -1
- package/dist/drawer/drawer-footer2.js +2 -2
- package/dist/drawer/drawer-footer2.js.map +1 -1
- package/dist/drawer/drawer-header2.js +2 -2
- package/dist/drawer/drawer-header2.js.map +1 -1
- package/dist/drawer/drawer2.js +2 -2
- package/dist/drawer/drawer2.js.map +1 -1
- package/dist/dropdown/define.js.map +1 -1
- package/dist/dropdown/dropdown-footer2.js +2 -2
- package/dist/dropdown/dropdown-footer2.js.map +1 -1
- package/dist/dropdown/dropdown-header2.js +2 -2
- package/dist/dropdown/dropdown-header2.js.map +1 -1
- package/dist/dropdown/dropdown2.js +2 -2
- package/dist/dropdown/dropdown2.js.map +1 -1
- package/dist/dropdown-group/define.js.map +1 -1
- package/dist/dropdown-group/dropdown-group.js +2 -2
- package/dist/dropdown-group/dropdown-group.js.map +1 -1
- package/dist/dropzone/define.js.map +1 -1
- package/dist/dropzone/dropzone.util.js.map +1 -1
- package/dist/dropzone/dropzone2.js +2 -2
- package/dist/dropzone/dropzone2.js.map +1 -1
- package/dist/file/define.js.map +1 -1
- package/dist/file/file2.js +1 -1
- package/dist/file/file2.js.map +1 -1
- package/dist/format-datetime/define.js.map +1 -1
- package/dist/format-datetime/format-datetime2.js +2 -2
- package/dist/format-datetime/format-datetime2.js.map +1 -1
- package/dist/format-number/define.js.map +1 -1
- package/dist/format-number/format-number2.js +2 -2
- package/dist/format-number/format-number2.js.map +1 -1
- package/dist/format-relative-time/define.js.map +1 -1
- package/dist/format-relative-time/format-relative-time2.js +2 -2
- package/dist/format-relative-time/format-relative-time2.js.map +1 -1
- package/dist/forms/control/control2.js +2 -2
- package/dist/forms/control/control2.js.map +1 -1
- package/dist/forms/control-group/control-group2.js +2 -2
- package/dist/forms/control-group/control-group2.js.map +1 -1
- package/dist/forms/control-message/control-message2.js +2 -2
- package/dist/forms/control-message/control-message2.js.map +1 -1
- package/dist/forms/define.js.map +1 -1
- package/dist/forms/utils/layout.js.map +1 -1
- package/dist/forms/utils/states.js.map +1 -1
- package/dist/grid/cell/cell2.js +1 -1
- package/dist/grid/cell/cell2.js.map +1 -1
- package/dist/grid/column/column2.js +2 -2
- package/dist/grid/column/column2.js.map +1 -1
- package/dist/grid/define.js.map +1 -1
- package/dist/grid/footer/footer2.js +2 -2
- package/dist/grid/footer/footer2.js.map +1 -1
- package/dist/grid/grid2.js +2 -2
- package/dist/grid/grid2.js.map +1 -1
- package/dist/grid/header/header2.js +2 -2
- package/dist/grid/header/header2.js.map +1 -1
- package/dist/grid/placeholder/placeholder2.js +1 -1
- package/dist/grid/placeholder/placeholder2.js.map +1 -1
- package/dist/grid/row/row2.js +2 -2
- package/dist/grid/row/row2.js.map +1 -1
- package/dist/icon/define.js.map +1 -1
- package/dist/icon/icon2.js +3 -3
- package/dist/icon/icon2.js.map +1 -1
- package/dist/icon/icons.js.map +1 -1
- package/dist/icon/server.js.map +1 -1
- package/dist/icon-button/define.js.map +1 -1
- package/dist/icon-button/icon-button2.js +2 -2
- package/dist/icon-button/icon-button2.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/input/define.js.map +1 -1
- package/dist/input/input-group2.js +1 -1
- package/dist/input/input-group2.js.map +1 -1
- package/dist/input/input2.js +2 -2
- package/dist/input/input2.js.map +1 -1
- package/dist/internal/base/button.d.ts +6 -1
- package/dist/internal/base/button.js +10 -3
- package/dist/internal/base/button.js.map +1 -1
- package/dist/internal/controllers/audit.controller.js.map +1 -1
- package/dist/internal/controllers/i18n.controller.js.map +1 -1
- package/dist/internal/controllers/keynav-grid.controller.js.map +1 -1
- package/dist/internal/controllers/keynav-list.controller.js.map +1 -1
- package/dist/internal/controllers/state-active.controller.js.map +1 -1
- package/dist/internal/controllers/state-current.controller.d.ts +1 -1
- package/dist/internal/controllers/state-current.controller.js +1 -1
- package/dist/internal/controllers/state-current.controller.js.map +1 -1
- package/dist/internal/controllers/state-disabled.controller.d.ts +1 -1
- package/dist/internal/controllers/state-disabled.controller.js +1 -1
- package/dist/internal/controllers/state-disabled.controller.js.map +1 -1
- package/dist/internal/controllers/state-expanded.controller.d.ts +1 -1
- package/dist/internal/controllers/state-expanded.controller.js +1 -1
- package/dist/internal/controllers/state-expanded.controller.js.map +1 -1
- package/dist/internal/controllers/state-highlighted.controller.js.map +1 -1
- package/dist/internal/controllers/state-pressed.controller.d.ts +1 -1
- package/dist/internal/controllers/state-pressed.controller.js +1 -1
- package/dist/internal/controllers/state-pressed.controller.js.map +1 -1
- package/dist/internal/controllers/state-scroll.controller.js.map +1 -1
- package/dist/internal/controllers/state-selected.controller.d.ts +1 -1
- package/dist/internal/controllers/state-selected.controller.js +1 -1
- package/dist/internal/controllers/state-selected.controller.js.map +1 -1
- package/dist/internal/controllers/type-anchor.controller.d.ts +1 -1
- package/dist/internal/controllers/type-anchor.controller.js +1 -1
- package/dist/internal/controllers/type-anchor.controller.js.map +1 -1
- package/dist/internal/controllers/type-button.controller.d.ts +1 -1
- package/dist/internal/controllers/type-button.controller.js +1 -1
- package/dist/internal/controllers/type-button.controller.js.map +1 -1
- package/dist/internal/controllers/type-closable.controller.js.map +1 -1
- package/dist/internal/controllers/type-command.controller.d.ts +1 -1
- package/dist/internal/controllers/type-command.controller.js +1 -1
- package/dist/internal/controllers/type-command.controller.js.map +1 -1
- package/dist/internal/controllers/type-expandable.controller.js.map +1 -1
- package/dist/internal/controllers/type-interest.controller.d.ts +1 -1
- package/dist/internal/controllers/type-interest.controller.js.map +1 -1
- package/dist/internal/controllers/type-native-popover-trigger.controller.js.map +1 -1
- package/dist/internal/controllers/type-native-popover.controller.js.map +1 -1
- package/dist/internal/controllers/type-native-popover.utils.js.map +1 -1
- package/dist/internal/controllers/type-selectable.controller.js.map +1 -1
- package/dist/internal/controllers/type-ssr.controller.js.map +1 -1
- package/dist/internal/controllers/type-submit.controller.d.ts +1 -1
- package/dist/internal/controllers/type-submit.controller.js +1 -1
- package/dist/internal/controllers/type-submit.controller.js.map +1 -1
- package/dist/internal/controllers/type-touch.controller.js.map +1 -1
- package/dist/internal/decorators/host-attr.js.map +1 -1
- package/dist/internal/decorators/scoped-registry.js.map +1 -1
- package/dist/internal/services/global.service.js +1 -1
- package/dist/internal/services/global.service.js.map +1 -1
- package/dist/internal/services/global.utils.js +6 -8
- package/dist/internal/services/global.utils.js.map +1 -1
- package/dist/internal/services/i18n.service.js.map +1 -1
- package/dist/internal/services/log.service.js.map +1 -1
- package/dist/internal/services/transition.service.js.map +1 -1
- package/dist/internal/styles/index.js.map +1 -1
- package/dist/internal/styles/popover2.js.map +1 -1
- package/dist/internal/types/index.d.ts +4 -0
- package/dist/internal/types/index.js.map +1 -1
- package/dist/internal/utils/a11y.js.map +1 -1
- package/dist/internal/utils/audit-logs.d.ts +0 -1
- package/dist/internal/utils/audit-logs.js +1 -4
- package/dist/internal/utils/audit-logs.js.map +1 -1
- package/dist/internal/utils/audit.js.map +1 -1
- package/dist/internal/utils/dom.js.map +1 -1
- package/dist/internal/utils/events.js.map +1 -1
- package/dist/internal/utils/focus.js.map +1 -1
- package/dist/internal/utils/keynav.js.map +1 -1
- package/dist/internal/utils/objects.js.map +1 -1
- package/dist/internal/utils/strings.js.map +1 -1
- package/dist/internal/utils/supports.js.map +1 -1
- package/dist/logo/define.js.map +1 -1
- package/dist/logo/logo2.js +2 -2
- package/dist/logo/logo2.js.map +1 -1
- package/dist/menu/define.js.map +1 -1
- package/dist/menu/menu-item2.js +2 -2
- package/dist/menu/menu-item2.js.map +1 -1
- package/dist/menu/menu2.js +2 -2
- package/dist/menu/menu2.js.map +1 -1
- package/dist/month/define.js.map +1 -1
- package/dist/month/month2.js +2 -2
- package/dist/month/month2.js.map +1 -1
- package/dist/notification/define.js.map +1 -1
- package/dist/notification/notification-group2.js +2 -2
- package/dist/notification/notification-group2.js.map +1 -1
- package/dist/notification/notification2.js +2 -2
- package/dist/notification/notification2.js.map +1 -1
- package/dist/page/define.js.map +1 -1
- package/dist/page/page-panel/page-panel-content2.js +1 -1
- package/dist/page/page-panel/page-panel-content2.js.map +1 -1
- package/dist/page/page-panel/page-panel-footer2.js +2 -2
- package/dist/page/page-panel/page-panel-footer2.js.map +1 -1
- package/dist/page/page-panel/page-panel-header2.js +2 -2
- package/dist/page/page-panel/page-panel-header2.js.map +1 -1
- package/dist/page/page-panel/page-panel2.js +2 -2
- package/dist/page/page-panel/page-panel2.js.map +1 -1
- package/dist/page/page2.js +2 -2
- package/dist/page/page2.js.map +1 -1
- package/dist/page-header/define.js.map +1 -1
- package/dist/page-header/page-header2.js +1 -1
- package/dist/page-header/page-header2.js.map +1 -1
- package/dist/page-loader/define.js.map +1 -1
- package/dist/page-loader/page-loader2.js +2 -2
- package/dist/page-loader/page-loader2.js.map +1 -1
- package/dist/pagination/define.js.map +1 -1
- package/dist/pagination/pagination2.js +2 -2
- package/dist/pagination/pagination2.js.map +1 -1
- package/dist/panel/define.js.map +1 -1
- package/dist/panel/panel2.js +5 -5
- package/dist/panel/panel2.js.map +1 -1
- package/dist/password/define.js.map +1 -1
- package/dist/password/password2.js +2 -2
- package/dist/password/password2.js.map +1 -1
- package/dist/polyfills/custom-state-set.js.map +1 -1
- package/dist/polyfills/index.js.map +1 -1
- package/dist/preferences-input/define.js.map +1 -1
- package/dist/preferences-input/preferences-input2.js +2 -2
- package/dist/preferences-input/preferences-input2.js.map +1 -1
- package/dist/progress-bar/define.js.map +1 -1
- package/dist/progress-bar/progress-bar2.js +2 -2
- package/dist/progress-bar/progress-bar2.js.map +1 -1
- package/dist/progress-ring/define.js.map +1 -1
- package/dist/progress-ring/progress-ring2.js +2 -2
- package/dist/progress-ring/progress-ring2.js.map +1 -1
- package/dist/progressive-filter-chip/define.js.map +1 -1
- package/dist/progressive-filter-chip/progressive-filter-chip2.js +2 -2
- package/dist/progressive-filter-chip/progressive-filter-chip2.js.map +1 -1
- package/dist/pulse/define.js.map +1 -1
- package/dist/pulse/pulse2.js +2 -2
- package/dist/pulse/pulse2.js.map +1 -1
- package/dist/radio/define.js.map +1 -1
- package/dist/radio/radio-group2.js +2 -2
- package/dist/radio/radio-group2.js.map +1 -1
- package/dist/radio/radio2.js +2 -2
- package/dist/radio/radio2.js.map +1 -1
- package/dist/range/define.js.map +1 -1
- package/dist/range/range2.js +2 -2
- package/dist/range/range2.js.map +1 -1
- package/dist/resize-handle/define.js.map +1 -1
- package/dist/resize-handle/resize-handle2.js +2 -2
- package/dist/resize-handle/resize-handle2.js.map +1 -1
- package/dist/search/define.js.map +1 -1
- package/dist/search/search2.js +2 -2
- package/dist/search/search2.js.map +1 -1
- package/dist/select/define.js.map +1 -1
- package/dist/select/select2.js +2 -2
- package/dist/select/select2.js.map +1 -1
- package/dist/skeleton/define.js.map +1 -1
- package/dist/skeleton/skeleton2.js +2 -2
- package/dist/skeleton/skeleton2.js.map +1 -1
- package/dist/sort-button/define.js.map +1 -1
- package/dist/sort-button/sort-button2.js +2 -2
- package/dist/sort-button/sort-button2.js.map +1 -1
- package/dist/sparkline/define.js.map +1 -1
- package/dist/sparkline/sparkline.utils.js.map +1 -1
- package/dist/sparkline/sparkline2.js +2 -2
- package/dist/sparkline/sparkline2.js.map +1 -1
- package/dist/star-rating/define.js.map +1 -1
- package/dist/star-rating/star-rating2.js +2 -2
- package/dist/star-rating/star-rating2.js.map +1 -1
- package/dist/steps/define.js.map +1 -1
- package/dist/steps/steps2.js +3 -3
- package/dist/steps/steps2.js.map +1 -1
- package/dist/switch/define.js.map +1 -1
- package/dist/switch/switch-group2.js +2 -2
- package/dist/switch/switch-group2.js.map +1 -1
- package/dist/switch/switch2.js +2 -2
- package/dist/switch/switch2.js.map +1 -1
- package/dist/tabs/define.js.map +1 -1
- package/dist/tabs/tabs-group2.js +2 -2
- package/dist/tabs/tabs-group2.js.map +1 -1
- package/dist/tabs/tabs2.js +3 -3
- package/dist/tabs/tabs2.js.map +1 -1
- package/dist/tag/define.js.map +1 -1
- package/dist/tag/tag2.js +2 -2
- package/dist/tag/tag2.js.map +1 -1
- package/dist/textarea/define.js.map +1 -1
- package/dist/textarea/textarea2.js +1 -1
- package/dist/textarea/textarea2.js.map +1 -1
- package/dist/time/define.js.map +1 -1
- package/dist/time/time2.js +2 -2
- package/dist/time/time2.js.map +1 -1
- package/dist/toast/define.js.map +1 -1
- package/dist/toast/toast2.js +2 -2
- package/dist/toast/toast2.js.map +1 -1
- package/dist/toggletip/define.js.map +1 -1
- package/dist/toggletip/toggletip-footer2.js +2 -2
- package/dist/toggletip/toggletip-footer2.js.map +1 -1
- package/dist/toggletip/toggletip-header2.js +2 -2
- package/dist/toggletip/toggletip-header2.js.map +1 -1
- package/dist/toggletip/toggletip2.js +2 -2
- package/dist/toggletip/toggletip2.js.map +1 -1
- package/dist/toolbar/define.js.map +1 -1
- package/dist/toolbar/toolbar2.js +2 -2
- package/dist/toolbar/toolbar2.js.map +1 -1
- package/dist/tooltip/define.js.map +1 -1
- package/dist/tooltip/tooltip2.js +2 -2
- package/dist/tooltip/tooltip2.js.map +1 -1
- package/dist/tree/define.js.map +1 -1
- package/dist/tree/tree-node2.js +2 -2
- package/dist/tree/tree-node2.js.map +1 -1
- package/dist/tree/tree2.js +2 -2
- package/dist/tree/tree2.js.map +1 -1
- package/dist/tree/utils.js.map +1 -1
- package/dist/week/define.js.map +1 -1
- package/dist/week/week2.js +2 -2
- package/dist/week/week2.js.map +1 -1
- package/package.json +7 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox2.js","names":["#datalist","#_datalist","#select","#_select","#options","#items","#dropdown","#input","#tags","#hasAvailableOptions","#hasFooterContent","#showCreateItem","#findOptionMatch","#selectValue","#largeOptionsList","#isPristine","#onDropdownOpen","#closeListBox","#getOptionCheckbox","#characterAtIndexMatches","#onCreateItemClick","#onSlottedChildMutation","#setupSingleSelect","#setupMultipleSelect","#setupAutoCompleteKeyEvents","#setupMenuItemUpdateEvents","#setupOpenKeyEvents","#setupOverflowListener","#setupSlotStates","#setupLightDismiss","#observers","#setupInitialValue","#syncSelectValueStates","#syncOptionSelectedStates","#updateInputValue","#trackedOptions","#syncPending","#cleanupStaleTrackedOptions","#setInputValue","#setSelectValue","#dispatchCreate","#filterOptions","#openListBox","#validateSingleSelectValue","#updateMultipleOverflow","#setSlotStates"],"sources":["../../src/combobox/combobox.ts"],"sourcesContent":["// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport type { PropertyValues } from 'lit';\nimport { html, isServer, nothing } from 'lit';\nimport { property } from 'lit/decorators/property.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\nimport type { ContainerElement } from '@nvidia-elements/core/internal';\nimport {\n createLightDismiss,\n focusElementTimeout,\n getDisplayValue,\n getElementUpdate,\n getPropertyChanges,\n scopedRegistry,\n useStyles\n} from '@nvidia-elements/core/internal';\nimport { Control } from '@nvidia-elements/core/forms';\nimport { inputStyles } from '@nvidia-elements/core/input';\nimport { Menu, MenuItem } from '@nvidia-elements/core/menu';\nimport { Dropdown } from '@nvidia-elements/core/dropdown';\nimport { Tag } from '@nvidia-elements/core/tag';\nimport { Icon } from '@nvidia-elements/core/icon';\nimport { Checkbox } from '@nvidia-elements/core/checkbox';\nimport styles from './combobox.css?inline';\n\n/**\n * @element nve-combobox\n * @description An editable combobox with autocomplete behavior and selection support.\n * @since 0.17.0\n * @entrypoint \\@nvidia-elements/core/combobox\n * @slot - default slot for an input and a datalist/select element\n * @slot prefix-icon - slot for icon before the input\n * @slot footer - slot for dropdown footer content\n * @cssprop --scroll-height\n * @cssprop --padding\n * @cssprop --font-size\n * @cssprop --height\n * @cssprop --background\n * @cssprop --color\n * @cssprop --border-radius\n * @cssprop --border\n * @cssprop --cursor\n * @cssprop --font-weight\n * @cssprop --width\n * @cssprop --border-color\n * @cssprop --max-height\n * @cssprop --text-transform\n * @csspart tag - The tag element for selected items\n * @csspart dropdown - The dropdown popup element\n * @csspart menu - The menu element\n * @csspart menu-item - The menu item elements\n * @csspart checkbox - The checkbox element\n * @csspart icon - The icon element\n * @event scroll - Fires when the user scrolls the dropdown option list. Throttled to one dispatch per animation frame. `detail: { scrollTop, scrollHeight, clientHeight }`.\n * @event create - Fires when the user confirms a value that doesn't match any existing option and the `behavior-create` attribute exists. `detail: { value }`.\n * @csspart create-option - The menu item element for creating new options\n * @aria https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-autocomplete-list/\n */\n@scopedRegistry()\nexport class Combobox extends Control implements ContainerElement {\n /**\n * Reduces the visual container for a minimal borderless appearance while preserving whitespace bounds.\n * Use when embedding within another container such as a toolbar.\n */\n @property({ type: String, reflect: true }) container: 'flat';\n\n /** Disable rendering of inline tags for many-item select */\n @property({ type: Boolean, reflect: true }) notags: boolean;\n\n /** Enable creation of new options when the input value doesn't match any existing option. Dispatches a `create` event with `{ value }` detail. */\n @property({ type: Boolean, reflect: true, attribute: 'behavior-create' }) behaviorCreate: boolean;\n\n static styles = useStyles([...Control.styles, inputStyles, styles]);\n\n static readonly metadata = {\n tag: 'nve-combobox',\n version: '0.0.0'\n };\n\n static elementDefinitions = {\n [Checkbox.metadata.tag]: Checkbox,\n [Icon.metadata.tag]: Icon,\n [Dropdown.metadata.tag]: Dropdown,\n [Menu.metadata.tag]: Menu,\n [MenuItem.metadata.tag]: MenuItem,\n [Tag.metadata.tag]: Tag\n };\n\n /**\n * If a <select> exists, on focus all options show by default.\n * If a <datalist> exists, on focus only options that match the current input value show.\n */\n\n #_datalist: HTMLSelectElement | null;\n get #datalist(): HTMLSelectElement | null {\n if (!this.#_datalist) {\n this.#_datalist = this.shadowRoot\n ? ((this.shadowRoot\n .querySelector('slot')\n ?.assignedElements({ flatten: true })\n ?.find(i => i.tagName === 'DATALIST' || i.tagName === 'SELECT') ??\n this.querySelector('datalist, select')) as HTMLSelectElement)\n : null;\n }\n return this.#_datalist;\n }\n\n #_select: HTMLSelectElement | null;\n get #select(): HTMLSelectElement | null {\n if (!this.#_select) {\n this.#_select = this.shadowRoot\n ? ((this.shadowRoot\n .querySelector('slot')\n ?.assignedElements({ flatten: true })\n ?.find(i => i.tagName === 'SELECT') ?? this.querySelector('select')) as HTMLSelectElement)\n : null;\n }\n return this.#_select;\n }\n\n get #options(): HTMLOptionElement[] {\n return Array.from(this.#datalist?.options ? this.#datalist.options : []);\n }\n\n get #items() {\n return Array.from(this.shadowRoot!.querySelectorAll<MenuItem>(MenuItem.metadata.tag));\n }\n\n get #dropdown() {\n return this.shadowRoot!.querySelector<Dropdown>(Dropdown.metadata.tag);\n }\n\n get #input() {\n return this.shadowRoot!.querySelector('[input]');\n }\n\n get #tags() {\n return this.shadowRoot!.querySelector('.tags');\n }\n\n get #hasAvailableOptions() {\n return this.#options.find(o => !o.disabled && !o.hidden);\n }\n\n get #hasFooterContent() {\n return !!this.querySelector('[slot=\"footer\"]');\n }\n\n get #showCreateItem(): boolean {\n if (!this.behaviorCreate || this.input?.disabled) return false;\n const value = this.input?.value.trim();\n if (!value) return false;\n return !this.#findOptionMatch(value);\n }\n\n #findOptionMatch(value: string): HTMLOptionElement | undefined {\n const lower = value.toLowerCase();\n return this.#options.find(o => {\n const display = o.textContent!.trim() || o.value;\n return display.toLowerCase() === lower || o.value.toLowerCase() === lower;\n });\n }\n\n #observers: (MutationObserver | ResizeObserver)[] = [];\n #syncPending = false;\n\n protected _associateDatalist = false;\n\n protected get prefixContent() {\n return this.#select?.multiple && !this.notags\n ? html`\n <div class=\"tags-label\" aria-hidden=\"true\">${this.#select.selectedOptions.length} ${this.i18n.selected}</div>\n <div class=\"tags\">\n ${Array.from<HTMLOptionElement>(this.#select.selectedOptions).map(\n o => html`\n <nve-tag part=\"tag\" readonly color=\"gray-slate\" closable .value=${o.value} @click=${() => this.#selectValue(o)}>${getDisplayValue(o)}</nve-tag>`\n )}\n </div>`\n : html`<slot name=\"prefix-icon\"></slot>`;\n }\n\n get #largeOptionsList() {\n return (this.#datalist?.options?.length ?? 0) > 50;\n }\n\n get #isPristine() {\n return !this._internals.states.has('dirty');\n }\n\n protected get suffixContent() {\n if (isServer) return nothing;\n const options = this.#options;\n const largeOptionsList = this.#largeOptionsList;\n const isPristine = this.#isPristine;\n const visibleOptions = options.filter(o => !o.hidden).filter(o => !(o.value === '' && o.disabled));\n const hasNoResults = visibleOptions.filter(o => !o.disabled).length === 0;\n const showCreateItem = this.#showCreateItem;\n return html`\n <nve-dropdown part=\"dropdown\" .popoverType=${'manual'} .modal=${false} @open=${this.#onDropdownOpen} @close=${this.#closeListBox} hidden .anchor=${this.#input as HTMLElement} .trigger=${this.#input as HTMLElement} position=\"bottom\">\n <nve-menu part=\"menu\" role=\"listbox\" style=\"--width: 100%; --min-width: fit-content\" aria-label=${ifDefined(this.i18n.select)}>\n ${visibleOptions.map(\n o => html`\n <nve-menu-item part=\"menu-item\" .option=${getDisplayValue(o)} role=\"option\" @click=${() => this.#selectValue(o)} ?selected=${o.selected} aria-selected=${o.selected ? 'true' : 'false'} ?disabled=${o.disabled} aria-label=${getDisplayValue(o)}>\n ${this.#getOptionCheckbox(o)}\n ${largeOptionsList || isPristine ? getDisplayValue(o) : html`<span role=\"presentation\">${(o.label ? o.label : o.value)?.split('')?.map((c, ci) => html`<span ?matches=${this.#characterAtIndexMatches(c, ci)}>${c}</span>`)}</span>`}\n </nve-menu-item>`\n )}\n ${hasNoResults && !showCreateItem ? html`<nve-menu-item part=\"menu-item\" .value=${''} disabled>${this.i18n.noResults}</nve-menu-item>` : nothing}\n ${\n showCreateItem\n ? html`<nve-menu-item part=\"create-option\" role=\"button\" aria-label=${`${this.i18n.create} \"${this.input?.value.trim()}\"`} @click=${this.#onCreateItemClick}>\n <nve-icon part=\"icon\" name=\"add\" size=\"sm\"></nve-icon> \"${this.input?.value.trim()}\"\n </nve-menu-item>`\n : nothing\n }\n </nve-menu>\n <slot name=\"footer\"></slot>\n </nve-dropdown>`;\n }\n\n #getOptionCheckbox(o: HTMLOptionElement) {\n const select = this.#select;\n if (select?.multiple && this.#largeOptionsList) {\n return html`<input aria-hidden=\"true\" type=\"checkbox\" .checked=${o.selected} .disabled=${o.disabled} .name=${o.selected ? 'check' : undefined} />`;\n } else if (select?.multiple) {\n /* eslint-disable @nvidia-elements/lint/no-missing-control-label */\n return html`<nve-checkbox part=\"checkbox\"><input aria-hidden=\"true\" type=\"checkbox\" .checked=${o.selected} .disabled=${o.disabled} .name=${o.selected ? 'check' : undefined} /></nve-checkbox>`;\n } else if (select) {\n return html`<nve-icon part=\"icon\" name=\"check\" size=\"sm\"></nve-icon>`;\n } else {\n return nothing;\n }\n }\n\n async firstUpdated(props: PropertyValues<this>) {\n super.firstUpdated(props);\n this.shadowRoot!.addEventListener('slotchange', () => {\n this.#_datalist = null;\n this.#_select = null;\n this.#onSlottedChildMutation();\n });\n await this.updateComplete;\n this.#setupSingleSelect();\n this.#setupMultipleSelect();\n this.#setupAutoCompleteKeyEvents();\n this.#setupMenuItemUpdateEvents();\n this.#setupOpenKeyEvents();\n this.#setupOverflowListener();\n this.#setupSlotStates();\n await this.#setupLightDismiss();\n this.input.setAttribute('list', '');\n this.input.autocomplete = 'off';\n }\n\n connectedCallback() {\n super.connectedCallback();\n const observer = new MutationObserver(mutations => {\n if (mutations.some(m => m.type === 'childList' && m.target === this)) {\n this.#_datalist = null;\n this.#_select = null;\n }\n this.#onSlottedChildMutation();\n });\n observer.observe(this, {\n childList: true,\n subtree: true,\n attributes: true,\n attributeFilter: ['selected', 'disabled', 'value'],\n characterData: true\n });\n this.#observers.push(observer);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.#observers.forEach(observer => observer.disconnect());\n }\n\n reset() {\n this.#dropdown!.hidePopover();\n if (this.#select) {\n this.#select.selectedIndex = -1;\n }\n super.reset();\n }\n\n /** Select all options provided */\n selectAll() {\n this.#options.forEach(o => (o.selected = true));\n this.requestUpdate();\n this.#select!.dispatchEvent(new Event('input', { bubbles: true }));\n this.#select!.dispatchEvent(new Event('change', { bubbles: true }));\n }\n\n #setupSingleSelect() {\n if (this.#select && !this.#select.multiple) {\n this.#setupInitialValue();\n this.#syncSelectValueStates();\n this.#syncOptionSelectedStates();\n }\n }\n\n #setupMultipleSelect() {\n if (this.#select?.multiple) {\n this.#setupInitialValue();\n this.#syncSelectValueStates();\n this.#syncOptionSelectedStates();\n this._internals.states.add('multiple');\n }\n }\n\n #setupInitialValue() {\n const selected = Array.from(this.#select!.selectedOptions).find((o: HTMLOptionElement) =>\n o.hasAttribute('selected')\n );\n if (selected && !this.#select!.multiple && !this.input.defaultValue) {\n this.input.value = getDisplayValue(selected);\n }\n }\n\n #updateInputValue() {\n if (!this.#select!.multiple && !this.input.defaultValue) {\n this.input.value = getDisplayValue(\n Array.from(this.#select!.selectedOptions).find(o => o.value === this.#select!.value)!\n );\n }\n }\n\n #syncSelectValueStates() {\n this.#observers.push(\n getElementUpdate(this.#select!, 'value', () => {\n this.#updateInputValue();\n this.requestUpdate();\n })\n );\n }\n\n #trackedOptions = new Set<HTMLOptionElement>();\n #syncOptionSelectedStates() {\n this.#options.forEach(o => {\n if (!this.#trackedOptions.has(o)) {\n this.#trackedOptions.add(o);\n getPropertyChanges(o, 'selected', () => this.requestUpdate());\n }\n });\n }\n\n #onSlottedChildMutation() {\n if (!this.#syncPending) {\n this.#syncPending = true;\n queueMicrotask(() => {\n this.#syncPending = false;\n this.#cleanupStaleTrackedOptions();\n this.#syncOptionSelectedStates();\n this.requestUpdate();\n });\n }\n }\n\n #cleanupStaleTrackedOptions() {\n const currentOptions = new Set(this.#options);\n for (const tracked of this.#trackedOptions) {\n if (!currentOptions.has(tracked)) {\n this.#trackedOptions.delete(tracked);\n }\n }\n }\n\n #onDropdownOpen(e: Event) {\n (e.target as HTMLElement).hidden = false;\n }\n\n #setupAutoCompleteKeyEvents() {\n this.addEventListener('keydown', (e: KeyboardEvent) => {\n const value = this.input.value.trim();\n\n if (e.code === 'Tab') {\n if (this.#hasAvailableOptions && this.#dropdown!.matches(':popover-open') && value !== '') {\n e.preventDefault();\n // the menu item option property caches/stores the option value instead of value to prevent unnecessary lit lifecycle updates for each menu item\n this.#setInputValue((this.#items[0] as MenuItem & { option: string }).option);\n this.#setSelectValue(\n this.#options.find(\n o => (o.label ? o.label : o.value) === (this.#items[0] as MenuItem & { option: string }).option\n )!\n );\n }\n this.#dropdown!.hidePopover();\n }\n\n if (e.code === 'Enter' && this.behaviorCreate && !this.input.disabled && value) {\n const match = this.#findOptionMatch(value);\n if (match) {\n this.#selectValue(match);\n } else {\n e.preventDefault();\n e.stopImmediatePropagation();\n this.#dispatchCreate();\n }\n }\n });\n }\n\n #setupMenuItemUpdateEvents() {\n this.input.addEventListener('input', () => this.#filterOptions());\n this.shadowRoot!.addEventListener('slotchange', () => this.#filterOptions());\n }\n\n async #setupLightDismiss() {\n const dropdown = this.#dropdown!;\n await dropdown.updateComplete;\n const options = {\n element: dropdown.shadowRoot!.querySelector<HTMLElement>('[internal-host]')!,\n focusElement: this.input\n };\n createLightDismiss(options, () => {\n if (this.#dropdown!.matches(':popover-open')) {\n this.#dropdown!.hidePopover();\n }\n });\n }\n\n #setupOpenKeyEvents() {\n this.input.addEventListener('pointerdown', () => {\n this.#openListBox();\n });\n\n this.addEventListener('keydown', (e: KeyboardEvent) => {\n if (e.code !== 'Tab' && e.code !== 'Escape') {\n this.#openListBox();\n }\n\n if (e?.code === 'ArrowDown' && (this.getRootNode() as ShadowRoot).activeElement === this.input) {\n this.#dropdown!.tabIndex = 0;\n this.#items[0]?.focus();\n e.preventDefault();\n }\n });\n }\n\n #selectValue(option: { selected?: boolean; label?: string; value?: string }) {\n if (!this.#select?.multiple) {\n this.#setInputValue(getDisplayValue(option));\n this.#dropdown!.hidePopover();\n focusElementTimeout(this.input);\n }\n\n if (this.#select) {\n option.selected = !option.selected;\n this.#setSelectValue(option);\n }\n\n this.requestUpdate();\n }\n\n #onCreateItemClick() {\n this.#dispatchCreate();\n }\n\n #dispatchCreate() {\n const value = this.input.value.trim();\n if (value) {\n this.dispatchEvent(new CustomEvent('create', { detail: { value }, bubbles: true, composed: true }));\n this.input.value = '';\n this.#dropdown!.hidePopover();\n focusElementTimeout(this.input);\n this.requestUpdate();\n }\n }\n\n #characterAtIndexMatches(character: string, index: number) {\n if (this.#hasAvailableOptions) {\n return this.input.value.toLowerCase()[index]?.toLowerCase() === character.toLowerCase();\n }\n return false;\n }\n\n #filterOptions() {\n this.#options.forEach(option => {\n const hasLabel = option.textContent!.trim().length;\n if (hasLabel) {\n const matchesLabel = option.textContent!.toLocaleLowerCase().includes(this.input?.value.toLowerCase());\n option.hidden = !matchesLabel;\n } else {\n const matchesValue = option.value.toLocaleLowerCase().includes(this.input?.value.toLowerCase());\n option.hidden = !matchesValue;\n }\n });\n this.requestUpdate();\n }\n\n #openListBox() {\n if (!this.input.disabled && !this.#dropdown!.matches(':popover-open')) {\n if (this.#select) {\n this.#options.forEach(option => (option.hidden = false));\n this.requestUpdate();\n } else {\n this.#filterOptions();\n }\n this.#dropdown!.style.setProperty('--min-width', `${this.#input!.getBoundingClientRect().width}px`);\n // explicitly provide source as the performance optimizations in the suffixContent getter prevent the dropdown from setting its anchor/trigger reliably\n this.#dropdown!.showPopover({ source: this.#input as HTMLElement });\n this.#dropdown!.tabIndex = -1;\n }\n }\n\n #closeListBox() {\n this.#dropdown!.hidePopover();\n this._internals.states.delete('dirty');\n this.#validateSingleSelectValue();\n }\n\n #validateSingleSelectValue() {\n const invalidInputValue =\n this.#select &&\n !this.#select.multiple &&\n !this.#options.filter(o => !(o.value === '' && o.disabled)).find(o => getDisplayValue(o) === this.input.value);\n if (invalidInputValue) {\n this.#options.forEach(o => (o.selected = false));\n this.#setInputValue('');\n this.#setSelectValue({ value: '', selected: false });\n }\n }\n\n #setInputValue(value: string) {\n this.input.value = value;\n this.input.dispatchEvent(new Event('input', { bubbles: true }));\n this.input.dispatchEvent(new Event('change', { bubbles: true }));\n }\n\n #setSelectValue(option: { value?: string; selected?: boolean }) {\n const found = [...this.#options, { value: '', selected: null as boolean | null }].find(\n o => o.value === option.value\n );\n if (found) found.selected = option.selected ?? null;\n\n if (this.#select && !this.#select.multiple) {\n this.#select.value = option.value!;\n }\n\n this.#select?.dispatchEvent(new Event('input', { bubbles: true }));\n this.#select?.dispatchEvent(new Event('change', { bubbles: true }));\n }\n\n #setupOverflowListener() {\n if (this.#select?.multiple && !this.notags) {\n if (this.#select.selectedOptions.length > 1) {\n // only calculate initial overflow if many tags exist\n this.#updateMultipleOverflow(this.#tags!.getBoundingClientRect().width);\n }\n const observer = new ResizeObserver(entries => this.#updateMultipleOverflow(entries[0]!.contentRect.width));\n this.#observers.push(observer);\n observer.observe(this.#tags!);\n }\n }\n\n #updateMultipleOverflow(tagWidth: number) {\n const INPUT_MIN_WIDTH = 100;\n if (this.#select?.multiple && tagWidth > this.#input!.getBoundingClientRect().width - INPUT_MIN_WIDTH) {\n this._internals.states.add('multiple-overflow');\n } else {\n this._internals.states.delete('multiple-overflow');\n }\n }\n\n #setupSlotStates() {\n this.#setSlotStates();\n this.shadowRoot!.addEventListener('slotchange', () => this.#setSlotStates());\n }\n\n #setSlotStates() {\n if (this.#hasFooterContent) {\n this._internals.states.add('footer-content');\n } else {\n this._internals.states.delete('footer-content');\n }\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AA4DO,IAAA,IAAA,cAAuB,EAAoC;;yBAwGZ,EAAE,YACvC,8BAEgB,8BA2Kb,IAAI,KAAwB;;;gBAzQ9B,EAAU;GAAC,GAAG,EAAQ;GAAQ;GAAa;GAAO,CAAC;;;kBAExC;GACzB,KAAK;GACL,SAAS;GACV;;;4BAE2B;IACzB,EAAS,SAAS,MAAM;IACxB,EAAK,SAAS,MAAM;IACpB,EAAS,SAAS,MAAM;IACxB,EAAK,SAAS,MAAM;IACpB,EAAS,SAAS,MAAM;IACxB,EAAI,SAAS,MAAM;GACrB;;CAOD;CACA,IAAIA,KAAsC;EAUxC,OATA,AACE,KAAKC,OAAa,KAAK,aACjB,KAAK,WACJ,cAAc,OAAO,EACpB,iBAAiB,EAAE,SAAS,IAAM,CAAC,EACnC,MAAK,MAAK,EAAE,YAAY,cAAc,EAAE,YAAY,SAAS,IAC/D,KAAK,cAAc,mBAAmB,GACxC,MAEC,KAAKA;;CAGd;CACA,IAAIC,KAAoC;EAStC,OARA,AACE,KAAKC,OAAW,KAAK,aACf,KAAK,WACJ,cAAc,OAAO,EACpB,iBAAiB,EAAE,SAAS,IAAM,CAAC,EACnC,MAAK,MAAK,EAAE,YAAY,SAAS,IAAI,KAAK,cAAc,SAAS,GACrE,MAEC,KAAKA;;CAGd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M;CAAS,SAAS;CAAM,CAAC,CAAA,EAAA,EAAA,WAAA,UAAA,KAAA,EAAA,KAG1C,EAAS;CAAE,MAAM;CAAS,SAAS;CAAM,WAAW;CAAmB,CAAC,CAAA,EAAA,EAAA,WAAA,kBAAA,KAAA,EAAA,SAZ1E,GAAgB,CAAA,EAAA,EAAA"}
|
|
1
|
+
{"version":3,"file":"combobox2.js","names":["#datalist","#_datalist","#select","#_select","#options","#items","#dropdown","#input","#tags","#hasAvailableOptions","#hasFooterContent","#showCreateItem","#findOptionMatch","#selectValue","#largeOptionsList","#isPristine","#onDropdownOpen","#closeListBox","#getOptionCheckbox","#characterAtIndexMatches","#onCreateItemClick","#onSlottedChildMutation","#setupSingleSelect","#setupMultipleSelect","#setupAutoCompleteKeyEvents","#setupMenuItemUpdateEvents","#setupOpenKeyEvents","#setupOverflowListener","#setupSlotStates","#setupLightDismiss","#observers","#setupInitialValue","#syncSelectValueStates","#syncOptionSelectedStates","#updateInputValue","#trackedOptions","#syncPending","#cleanupStaleTrackedOptions","#setInputValue","#setSelectValue","#dispatchCreate","#filterOptions","#openListBox","#validateSingleSelectValue","#updateMultipleOverflow","#setSlotStates"],"sources":["../../src/combobox/combobox.ts"],"sourcesContent":["// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport type { PropertyValues } from 'lit';\nimport { html, isServer, nothing } from 'lit';\nimport { property } from 'lit/decorators/property.js';\nimport { ifDefined } from 'lit/directives/if-defined.js';\nimport type { ContainerElement } from '@nvidia-elements/core/internal';\nimport {\n createLightDismiss,\n focusElementTimeout,\n getDisplayValue,\n getElementUpdate,\n getPropertyChanges,\n scopedRegistry,\n useStyles\n} from '@nvidia-elements/core/internal';\nimport { Control } from '@nvidia-elements/core/forms';\nimport { inputStyles } from '@nvidia-elements/core/input';\nimport { Menu, MenuItem } from '@nvidia-elements/core/menu';\nimport { Dropdown } from '@nvidia-elements/core/dropdown';\nimport { Tag } from '@nvidia-elements/core/tag';\nimport { Icon } from '@nvidia-elements/core/icon';\nimport { Checkbox } from '@nvidia-elements/core/checkbox';\nimport styles from './combobox.css?inline';\n\n/**\n * @element nve-combobox\n * @description An editable combobox with autocomplete behavior and selection support.\n * @since 0.17.0\n * @entrypoint \\@nvidia-elements/core/combobox\n * @slot - default slot for an input and a datalist/select element\n * @slot prefix-icon - slot for icon before the input\n * @slot footer - slot for dropdown footer content\n * @cssprop --scroll-height\n * @cssprop --padding\n * @cssprop --font-size\n * @cssprop --height\n * @cssprop --background\n * @cssprop --color\n * @cssprop --border-radius\n * @cssprop --border\n * @cssprop --cursor\n * @cssprop --font-weight\n * @cssprop --width\n * @cssprop --border-color\n * @cssprop --max-height\n * @cssprop --text-transform\n * @csspart tag - The tag element for selected items\n * @csspart dropdown - The dropdown popup element\n * @csspart menu - The menu element\n * @csspart menu-item - The menu item elements\n * @csspart checkbox - The checkbox element\n * @csspart icon - The icon element\n * @event scroll - Fires when the user scrolls the dropdown option list. Throttled to one dispatch per animation frame. `detail: { scrollTop, scrollHeight, clientHeight }`.\n * @event create - Fires when the user confirms a value that doesn't match any existing option and the `behavior-create` attribute exists. `detail: { value }`.\n * @csspart create-option - The menu item element for creating new options\n * @aria https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-autocomplete-list/\n */\n@scopedRegistry()\nexport class Combobox extends Control implements ContainerElement {\n /**\n * Reduces the visual container for a minimal borderless appearance while preserving whitespace bounds.\n * Use when embedding within another container such as a toolbar.\n */\n @property({ type: String, reflect: true }) container: 'flat';\n\n /** Disable rendering of inline tags for many-item select */\n @property({ type: Boolean, reflect: true }) notags: boolean;\n\n /** Enable creation of new options when the input value doesn't match any existing option. Dispatches a `create` event with `{ value }` detail. */\n @property({ type: Boolean, reflect: true, attribute: 'behavior-create' }) behaviorCreate: boolean;\n\n static styles = useStyles([...Control.styles, inputStyles, styles]);\n\n static readonly metadata = {\n tag: 'nve-combobox',\n version: '0.0.0'\n };\n\n static elementDefinitions = {\n [Checkbox.metadata.tag]: Checkbox,\n [Icon.metadata.tag]: Icon,\n [Dropdown.metadata.tag]: Dropdown,\n [Menu.metadata.tag]: Menu,\n [MenuItem.metadata.tag]: MenuItem,\n [Tag.metadata.tag]: Tag\n };\n\n /**\n * If a <select> exists, on focus all options show by default.\n * If a <datalist> exists, on focus only options that match the current input value show.\n */\n\n #_datalist: HTMLSelectElement | null;\n get #datalist(): HTMLSelectElement | null {\n if (!this.#_datalist) {\n this.#_datalist = this.shadowRoot\n ? ((this.shadowRoot\n .querySelector('slot')\n ?.assignedElements({ flatten: true })\n ?.find(i => i.tagName === 'DATALIST' || i.tagName === 'SELECT') ??\n this.querySelector('datalist, select')) as HTMLSelectElement)\n : null;\n }\n return this.#_datalist;\n }\n\n #_select: HTMLSelectElement | null;\n get #select(): HTMLSelectElement | null {\n if (!this.#_select) {\n this.#_select = this.shadowRoot\n ? ((this.shadowRoot\n .querySelector('slot')\n ?.assignedElements({ flatten: true })\n ?.find(i => i.tagName === 'SELECT') ?? this.querySelector('select')) as HTMLSelectElement)\n : null;\n }\n return this.#_select;\n }\n\n get #options(): HTMLOptionElement[] {\n return Array.from(this.#datalist?.options ? this.#datalist.options : []);\n }\n\n get #items() {\n return Array.from(this.shadowRoot!.querySelectorAll<MenuItem>(MenuItem.metadata.tag));\n }\n\n get #dropdown() {\n return this.shadowRoot!.querySelector<Dropdown>(Dropdown.metadata.tag);\n }\n\n get #input() {\n return this.shadowRoot!.querySelector('[input]');\n }\n\n get #tags() {\n return this.shadowRoot!.querySelector('.tags');\n }\n\n get #hasAvailableOptions() {\n return this.#options.find(o => !o.disabled && !o.hidden);\n }\n\n get #hasFooterContent() {\n return !!this.querySelector('[slot=\"footer\"]');\n }\n\n get #showCreateItem(): boolean {\n if (!this.behaviorCreate || this.input?.disabled) return false;\n const value = this.input?.value.trim();\n if (!value) return false;\n return !this.#findOptionMatch(value);\n }\n\n #findOptionMatch(value: string): HTMLOptionElement | undefined {\n const lower = value.toLowerCase();\n return this.#options.find(o => {\n const display = o.textContent!.trim() || o.value;\n return display.toLowerCase() === lower || o.value.toLowerCase() === lower;\n });\n }\n\n #observers: (MutationObserver | ResizeObserver)[] = [];\n #syncPending = false;\n\n protected _associateDatalist = false;\n\n protected get prefixContent() {\n return this.#select?.multiple && !this.notags\n ? html`\n <div class=\"tags-label\" aria-hidden=\"true\">${this.#select.selectedOptions.length} ${this.i18n.selected}</div>\n <div class=\"tags\">\n ${Array.from<HTMLOptionElement>(this.#select.selectedOptions).map(\n o => html`\n <nve-tag part=\"tag\" readonly color=\"gray-slate\" closable .value=${o.value} @click=${() => this.#selectValue(o)}>${getDisplayValue(o)}</nve-tag>`\n )}\n </div>`\n : html`<slot name=\"prefix-icon\"></slot>`;\n }\n\n get #largeOptionsList() {\n return (this.#datalist?.options?.length ?? 0) > 50;\n }\n\n get #isPristine() {\n return !this._internals.states.has('dirty');\n }\n\n protected get suffixContent() {\n if (isServer) return nothing;\n const options = this.#options;\n const largeOptionsList = this.#largeOptionsList;\n const isPristine = this.#isPristine;\n const visibleOptions = options.filter(o => !o.hidden).filter(o => !(o.value === '' && o.disabled));\n const hasNoResults = visibleOptions.filter(o => !o.disabled).length === 0;\n const showCreateItem = this.#showCreateItem;\n return html`\n <nve-dropdown part=\"dropdown\" .popoverType=${'manual'} .modal=${false} @open=${this.#onDropdownOpen} @close=${this.#closeListBox} hidden .anchor=${this.#input as HTMLElement} .trigger=${this.#input as HTMLElement} position=\"bottom\">\n <nve-menu part=\"menu\" role=\"listbox\" style=\"--width: 100%; --min-width: fit-content\" aria-label=${ifDefined(this.i18n.select)}>\n ${visibleOptions.map(\n o => html`\n <nve-menu-item part=\"menu-item\" .option=${getDisplayValue(o)} role=\"option\" @click=${() => this.#selectValue(o)} ?selected=${o.selected} aria-selected=${o.selected ? 'true' : 'false'} ?disabled=${o.disabled} aria-label=${getDisplayValue(o)}>\n ${this.#getOptionCheckbox(o)}\n ${largeOptionsList || isPristine ? getDisplayValue(o) : html`<span role=\"presentation\">${(o.label ? o.label : o.value)?.split('')?.map((c, ci) => html`<span ?matches=${this.#characterAtIndexMatches(c, ci)}>${c}</span>`)}</span>`}\n </nve-menu-item>`\n )}\n ${hasNoResults && !showCreateItem ? html`<nve-menu-item part=\"menu-item\" .value=${''} disabled>${this.i18n.noResults}</nve-menu-item>` : nothing}\n ${\n showCreateItem\n ? html`<nve-menu-item part=\"create-option\" role=\"button\" aria-label=${`${this.i18n.create} \"${this.input?.value.trim()}\"`} @click=${this.#onCreateItemClick}>\n <nve-icon part=\"icon\" name=\"add\" size=\"sm\"></nve-icon> \"${this.input?.value.trim()}\"\n </nve-menu-item>`\n : nothing\n }\n </nve-menu>\n <slot name=\"footer\"></slot>\n </nve-dropdown>`;\n }\n\n #getOptionCheckbox(o: HTMLOptionElement) {\n const select = this.#select;\n if (select?.multiple && this.#largeOptionsList) {\n return html`<input aria-hidden=\"true\" type=\"checkbox\" .checked=${o.selected} .disabled=${o.disabled} .name=${o.selected ? 'check' : undefined} />`;\n } else if (select?.multiple) {\n /* eslint-disable @nvidia-elements/lint/no-missing-control-label */\n return html`<nve-checkbox part=\"checkbox\"><input aria-hidden=\"true\" type=\"checkbox\" .checked=${o.selected} .disabled=${o.disabled} .name=${o.selected ? 'check' : undefined} /></nve-checkbox>`;\n } else if (select) {\n return html`<nve-icon part=\"icon\" name=\"check\" size=\"sm\"></nve-icon>`;\n } else {\n return nothing;\n }\n }\n\n async firstUpdated(props: PropertyValues<this>) {\n super.firstUpdated(props);\n this.shadowRoot!.addEventListener('slotchange', () => {\n this.#_datalist = null;\n this.#_select = null;\n this.#onSlottedChildMutation();\n });\n await this.updateComplete;\n this.#setupSingleSelect();\n this.#setupMultipleSelect();\n this.#setupAutoCompleteKeyEvents();\n this.#setupMenuItemUpdateEvents();\n this.#setupOpenKeyEvents();\n this.#setupOverflowListener();\n this.#setupSlotStates();\n await this.#setupLightDismiss();\n this.input.setAttribute('list', '');\n this.input.autocomplete = 'off';\n }\n\n connectedCallback() {\n super.connectedCallback();\n const observer = new MutationObserver(mutations => {\n if (mutations.some(m => m.type === 'childList' && m.target === this)) {\n this.#_datalist = null;\n this.#_select = null;\n }\n this.#onSlottedChildMutation();\n });\n observer.observe(this, {\n childList: true,\n subtree: true,\n attributes: true,\n attributeFilter: ['selected', 'disabled', 'value'],\n characterData: true\n });\n this.#observers.push(observer);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.#observers.forEach(observer => observer.disconnect());\n }\n\n reset() {\n this.#dropdown!.hidePopover();\n if (this.#select) {\n this.#select.selectedIndex = -1;\n }\n super.reset();\n }\n\n /** Select all options provided */\n selectAll() {\n this.#options.forEach(o => (o.selected = true));\n this.requestUpdate();\n this.#select!.dispatchEvent(new Event('input', { bubbles: true }));\n this.#select!.dispatchEvent(new Event('change', { bubbles: true }));\n }\n\n #setupSingleSelect() {\n if (this.#select && !this.#select.multiple) {\n this.#setupInitialValue();\n this.#syncSelectValueStates();\n this.#syncOptionSelectedStates();\n }\n }\n\n #setupMultipleSelect() {\n if (this.#select?.multiple) {\n this.#setupInitialValue();\n this.#syncSelectValueStates();\n this.#syncOptionSelectedStates();\n this._internals.states.add('multiple');\n }\n }\n\n #setupInitialValue() {\n const selected = Array.from(this.#select!.selectedOptions).find((o: HTMLOptionElement) =>\n o.hasAttribute('selected')\n );\n if (selected && !this.#select!.multiple && !this.input.defaultValue) {\n this.input.value = getDisplayValue(selected);\n }\n }\n\n #updateInputValue() {\n if (!this.#select!.multiple && !this.input.defaultValue) {\n this.input.value = getDisplayValue(\n Array.from(this.#select!.selectedOptions).find(o => o.value === this.#select!.value)!\n );\n }\n }\n\n #syncSelectValueStates() {\n this.#observers.push(\n getElementUpdate(this.#select!, 'value', () => {\n this.#updateInputValue();\n this.requestUpdate();\n })\n );\n }\n\n #trackedOptions = new Set<HTMLOptionElement>();\n #syncOptionSelectedStates() {\n this.#options.forEach(o => {\n if (!this.#trackedOptions.has(o)) {\n this.#trackedOptions.add(o);\n getPropertyChanges(o, 'selected', () => this.requestUpdate());\n }\n });\n }\n\n #onSlottedChildMutation() {\n if (!this.#syncPending) {\n this.#syncPending = true;\n queueMicrotask(() => {\n this.#syncPending = false;\n this.#cleanupStaleTrackedOptions();\n this.#syncOptionSelectedStates();\n this.requestUpdate();\n });\n }\n }\n\n #cleanupStaleTrackedOptions() {\n const currentOptions = new Set(this.#options);\n for (const tracked of this.#trackedOptions) {\n if (!currentOptions.has(tracked)) {\n this.#trackedOptions.delete(tracked);\n }\n }\n }\n\n #onDropdownOpen(e: Event) {\n (e.target as HTMLElement).hidden = false;\n }\n\n #setupAutoCompleteKeyEvents() {\n this.addEventListener('keydown', (e: KeyboardEvent) => {\n const value = this.input.value.trim();\n\n if (e.code === 'Tab') {\n if (this.#hasAvailableOptions && this.#dropdown!.matches(':popover-open') && value !== '') {\n e.preventDefault();\n // the menu item option property caches/stores the option value instead of value to prevent unnecessary lit lifecycle updates for each menu item\n this.#setInputValue((this.#items[0] as MenuItem & { option: string }).option);\n this.#setSelectValue(\n this.#options.find(\n o => (o.label ? o.label : o.value) === (this.#items[0] as MenuItem & { option: string }).option\n )!\n );\n }\n this.#dropdown!.hidePopover();\n }\n\n if (e.code === 'Enter' && this.behaviorCreate && !this.input.disabled && value) {\n const match = this.#findOptionMatch(value);\n if (match) {\n this.#selectValue(match);\n } else {\n e.preventDefault();\n e.stopImmediatePropagation();\n this.#dispatchCreate();\n }\n }\n });\n }\n\n #setupMenuItemUpdateEvents() {\n this.input.addEventListener('input', () => this.#filterOptions());\n this.shadowRoot!.addEventListener('slotchange', () => this.#filterOptions());\n }\n\n async #setupLightDismiss() {\n const dropdown = this.#dropdown!;\n await dropdown.updateComplete;\n const options = {\n element: dropdown.shadowRoot!.querySelector<HTMLElement>('[internal-host]')!,\n focusElement: this.input\n };\n createLightDismiss(options, () => {\n if (this.#dropdown!.matches(':popover-open')) {\n this.#dropdown!.hidePopover();\n }\n });\n }\n\n #setupOpenKeyEvents() {\n this.input.addEventListener('pointerdown', () => {\n this.#openListBox();\n });\n\n this.addEventListener('keydown', (e: KeyboardEvent) => {\n if (e.code !== 'Tab' && e.code !== 'Escape') {\n this.#openListBox();\n }\n\n if (e?.code === 'ArrowDown' && (this.getRootNode() as ShadowRoot).activeElement === this.input) {\n this.#dropdown!.tabIndex = 0;\n this.#items[0]?.focus();\n e.preventDefault();\n }\n });\n }\n\n #selectValue(option: { selected?: boolean; label?: string; value?: string }) {\n if (!this.#select?.multiple) {\n this.#setInputValue(getDisplayValue(option));\n this.#dropdown!.hidePopover();\n focusElementTimeout(this.input);\n }\n\n if (this.#select) {\n option.selected = !option.selected;\n this.#setSelectValue(option);\n }\n\n this.requestUpdate();\n }\n\n #onCreateItemClick() {\n this.#dispatchCreate();\n }\n\n #dispatchCreate() {\n const value = this.input.value.trim();\n if (value) {\n this.dispatchEvent(new CustomEvent('create', { detail: { value }, bubbles: true, composed: true }));\n this.input.value = '';\n this.#dropdown!.hidePopover();\n focusElementTimeout(this.input);\n this.requestUpdate();\n }\n }\n\n #characterAtIndexMatches(character: string, index: number) {\n if (this.#hasAvailableOptions) {\n return this.input.value.toLowerCase()[index]?.toLowerCase() === character.toLowerCase();\n }\n return false;\n }\n\n #filterOptions() {\n this.#options.forEach(option => {\n const hasLabel = option.textContent!.trim().length;\n if (hasLabel) {\n const matchesLabel = option.textContent!.toLocaleLowerCase().includes(this.input?.value.toLowerCase());\n option.hidden = !matchesLabel;\n } else {\n const matchesValue = option.value.toLocaleLowerCase().includes(this.input?.value.toLowerCase());\n option.hidden = !matchesValue;\n }\n });\n this.requestUpdate();\n }\n\n #openListBox() {\n if (!this.input.disabled && !this.#dropdown!.matches(':popover-open')) {\n if (this.#select) {\n this.#options.forEach(option => (option.hidden = false));\n this.requestUpdate();\n } else {\n this.#filterOptions();\n }\n this.#dropdown!.style.setProperty('--min-width', `${this.#input!.getBoundingClientRect().width}px`);\n // explicitly provide source as the performance optimizations in the suffixContent getter prevent the dropdown from setting its anchor/trigger reliably\n this.#dropdown!.showPopover({ source: this.#input as HTMLElement });\n this.#dropdown!.tabIndex = -1;\n }\n }\n\n #closeListBox() {\n this.#dropdown!.hidePopover();\n this._internals.states.delete('dirty');\n this.#validateSingleSelectValue();\n }\n\n #validateSingleSelectValue() {\n const invalidInputValue =\n this.#select &&\n !this.#select.multiple &&\n !this.#options.filter(o => !(o.value === '' && o.disabled)).find(o => getDisplayValue(o) === this.input.value);\n if (invalidInputValue) {\n this.#options.forEach(o => (o.selected = false));\n this.#setInputValue('');\n this.#setSelectValue({ value: '', selected: false });\n }\n }\n\n #setInputValue(value: string) {\n this.input.value = value;\n this.input.dispatchEvent(new Event('input', { bubbles: true }));\n this.input.dispatchEvent(new Event('change', { bubbles: true }));\n }\n\n #setSelectValue(option: { value?: string; selected?: boolean }) {\n const found = [...this.#options, { value: '', selected: null as boolean | null }].find(\n o => o.value === option.value\n );\n if (found) found.selected = option.selected ?? null;\n\n if (this.#select && !this.#select.multiple) {\n this.#select.value = option.value!;\n }\n\n this.#select?.dispatchEvent(new Event('input', { bubbles: true }));\n this.#select?.dispatchEvent(new Event('change', { bubbles: true }));\n }\n\n #setupOverflowListener() {\n if (this.#select?.multiple && !this.notags) {\n if (this.#select.selectedOptions.length > 1) {\n // only calculate initial overflow if many tags exist\n this.#updateMultipleOverflow(this.#tags!.getBoundingClientRect().width);\n }\n const observer = new ResizeObserver(entries => this.#updateMultipleOverflow(entries[0]!.contentRect.width));\n this.#observers.push(observer);\n observer.observe(this.#tags!);\n }\n }\n\n #updateMultipleOverflow(tagWidth: number) {\n const INPUT_MIN_WIDTH = 100;\n if (this.#select?.multiple && tagWidth > this.#input!.getBoundingClientRect().width - INPUT_MIN_WIDTH) {\n this._internals.states.add('multiple-overflow');\n } else {\n this._internals.states.delete('multiple-overflow');\n }\n }\n\n #setupSlotStates() {\n this.#setSlotStates();\n this.shadowRoot!.addEventListener('slotchange', () => this.#setSlotStates());\n }\n\n #setSlotStates() {\n if (this.#hasFooterContent) {\n this._internals.states.add('footer-content');\n } else {\n this._internals.states.delete('footer-content');\n }\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AA4DO,IAAA,IAAA,cAAuB,EAAoC;;yBAwGZ,CAAC,aACtC,8BAEgB,8BA2Kb,IAAI,IAAuB;;;gBAzQ7B,EAAU;GAAC,GAAG,EAAQ;GAAQ;GAAa;EAAM,CAAC;;;kBAEvC;GACzB,KAAK;GACL,SAAS;EACX;;;4BAE4B;IACzB,EAAS,SAAS,MAAM;IACxB,EAAK,SAAS,MAAM;IACpB,EAAS,SAAS,MAAM;IACxB,EAAK,SAAS,MAAM;IACpB,EAAS,SAAS,MAAM;IACxB,EAAI,SAAS,MAAM;EACtB;;CAOA;CACA,IAAIA,KAAsC;EAUxC,OATA,AACE,KAAKC,OAAa,KAAK,aACjB,KAAK,WACJ,cAAc,MAAM,GACnB,iBAAiB,EAAE,SAAS,GAAK,CAAC,GAClC,MAAK,MAAK,EAAE,YAAY,cAAc,EAAE,YAAY,QAAQ,KAC9D,KAAK,cAAc,kBAAkB,IACvC,MAEC,KAAKA;CACd;CAEA;CACA,IAAIC,KAAoC;EAStC,OARA,AACE,KAAKC,OAAW,KAAK,aACf,KAAK,WACJ,cAAc,MAAM,GACnB,iBAAiB,EAAE,SAAS,GAAK,CAAC,GAClC,MAAK,MAAK,EAAE,YAAY,QAAQ,KAAK,KAAK,cAAc,QAAQ,IACpE,MAEC,KAAKA;CACd;CAEA,IAAIC,KAAgC;EAClC,OAAO,MAAM,KAAK,KAAKJ,IAAW,UAAU,KAAKA,GAAU,UAAU,CAAC,CAAC;CACzE;CAEA,IAAIK,KAAS;EACX,OAAO,MAAM,KAAK,KAAK,WAAY,iBAA2B,EAAS,SAAS,GAAG,CAAC;CACtF;CAEA,IAAIC,KAAY;EACd,OAAO,KAAK,WAAY,cAAwB,EAAS,SAAS,GAAG;CACvE;CAEA,IAAIC,KAAS;EACX,OAAO,KAAK,WAAY,cAAc,SAAS;CACjD;CAE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AS,SAAS;CAAM,WAAW;AAAkB,CAAC,CAAA,GAAA,EAAA,WAAA,kBAAA,KAAA,CAAA,UAZzE,EAAe,CAAA,GAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"define.js","names":[],"sources":["../../src/combobox/define.ts"],"sourcesContent":["// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { define } from '@nvidia-elements/core/internal';\nimport { Combobox } from '@nvidia-elements/core/combobox';\nimport { Control, ControlGroup, ControlMessage } from '@nvidia-elements/core/forms';\n\ndefine(Combobox);\ndefine(Control);\ndefine(ControlGroup);\ndefine(ControlMessage);\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nve-combobox': Combobox;\n }\n}\n"],"mappings":";;;;;AAOA,EAAO,
|
|
1
|
+
{"version":3,"file":"define.js","names":[],"sources":["../../src/combobox/define.ts"],"sourcesContent":["// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { define } from '@nvidia-elements/core/internal';\nimport { Combobox } from '@nvidia-elements/core/combobox';\nimport { Control, ControlGroup, ControlMessage } from '@nvidia-elements/core/forms';\n\ndefine(Combobox);\ndefine(Control);\ndefine(ControlGroup);\ndefine(ControlMessage);\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nve-combobox': Combobox;\n }\n}\n"],"mappings":";;;;;AAOA,EAAO,CAAQ,GACf,EAAO,CAAO,GACd,EAAO,CAAY,GACnB,EAAO,CAAc"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __decorate as e } from "../_virtual/_@oxc-project_runtime@0.
|
|
1
|
+
import { __decorate as e } from "../_virtual/_@oxc-project_runtime@0.130.0/helpers/decorate.js";
|
|
2
2
|
import { I18nController as t } from "../internal/controllers/i18n.controller.js";
|
|
3
3
|
import { scopedRegistry as n } from "../internal/decorators/scoped-registry.js";
|
|
4
4
|
import { useStyles as r } from "../internal/styles/index.js";
|
|
@@ -32,7 +32,7 @@ var p = class extends a {
|
|
|
32
32
|
static {
|
|
33
33
|
this.metadata = {
|
|
34
34
|
tag: "nve-copy-button",
|
|
35
|
-
version: "0.1.
|
|
35
|
+
version: "0.1.3"
|
|
36
36
|
};
|
|
37
37
|
}
|
|
38
38
|
static {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"copy-button2.js","names":["#i18nController","#close","#copy","#openTooltip","#closeTooltip"],"sources":["../../src/copy-button/copy-button.ts"],"sourcesContent":["// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { html, nothing } from 'lit';\nimport { property } from 'lit/decorators/property.js';\nimport { state } from 'lit/decorators/state.js';\nimport { useStyles, I18nController, scopedRegistry } from '@nvidia-elements/core/internal';\nimport { Button } from '@nvidia-elements/core/button';\nimport { Icon } from '@nvidia-elements/core/icon';\nimport { Toast } from '@nvidia-elements/core/toast';\nimport { Tooltip } from '@nvidia-elements/core/tooltip';\nimport styles from './copy-button.css?inline';\n\n/**\n * @element nve-copy-button\n * @description A copy button is a button that easily enables the copy to clipboard pattern.\n * @since 1.1.4\n * @entrypoint \\@nvidia-elements/core/copy-button\n * @slot - default\n * @slot icon - slot for custom icon\n * @cssprop --color\n * @cssprop --background\n * @cssprop --border-radius\n * @cssprop --padding\n * @cssprop --height\n * @cssprop --min-width\n * @cssprop --font-size\n * @cssprop --line-height\n * @csspart icon - The icon element\n * @csspart toast - The toast notification element\n * @csspart tooltip - The tooltip element\n * @aria https://www.w3.org/WAI/ARIA/apg/patterns/button/\n *\n */\n@scopedRegistry()\nexport class CopyButton extends Button {\n @state() private copied = false;\n\n @state() private showToast = false;\n\n @state() private showTooltip = false;\n\n #i18nController: I18nController<this> = new I18nController<this>(this);\n\n /**\n * Enables internal string values to update for internationalization.\n */\n @property({ type: Object }) i18n = this.#i18nController.i18n;\n\n /**\n * Determines if the copy button should auto write to clipboard by the trigger.\n */\n @property({ type: Boolean, reflect: true, attribute: 'behavior-copy' }) behaviorCopy: boolean;\n\n /**\n * Defines the value that copies to the user clipboard. Use `aria-label` to set the tooltip hint.\n */\n @property({ type: String }) value: string;\n\n static styles = useStyles([...Button.styles, styles]);\n\n static readonly metadata = {\n tag: 'nve-copy-button',\n version: '0.0.0'\n };\n\n static elementDefinitions = {\n [Icon.metadata.tag]: Icon,\n [Toast.metadata.tag]: Toast,\n [Tooltip.metadata.tag]: Tooltip\n };\n\n /* eslint-disable @nvidia-elements/lint/no-deprecated-popover-attributes */\n render() {\n return html`\n <div id=\"btn\" internal-host interaction-state focus-within>\n <slot></slot>\n ${\n this.copied\n ? html`<nve-icon part=\"icon\" name=\"check\" status=\"success\" .size=${this.size} aria-hidden=\"true\"></nve-icon>`\n : html`<slot name=\"icon\"><nve-icon part=\"icon\" name=\"copy\" .size=${this.size} aria-hidden=\"true\"></nve-icon></slot>`\n }\n </div>\n ${this.showToast ? html`<nve-toast part=\"toast\" @close=${this.#close} status=\"success\" anchor=\"btn\" trigger=\"btn\" position=\"top\" close-timeout=\"1500\">${this.i18n.copied}</nve-toast>` : nothing}\n ${this.showTooltip && !this.showToast ? html`<nve-tooltip part=\"tooltip\" exportparts=\"arrow:tooltip-arrow\" anchor=\"btn\" trigger=\"btn\">${this.ariaLabel ?? this.i18n.copy}</nve-tooltip>` : nothing}\n `;\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.addEventListener('click', this.#copy);\n this.addEventListener('mouseenter', this.#openTooltip);\n this.addEventListener('mouseleave', this.#closeTooltip);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.removeEventListener('click', this.#copy);\n this.removeEventListener('mouseenter', this.#openTooltip);\n this.removeEventListener('mouseleave', this.#closeTooltip);\n }\n\n #copy = () => {\n if (this.behaviorCopy) {\n navigator.clipboard\n .writeText(this.value)\n .then(() => {\n this.showToast = true;\n this.copied = true;\n })\n .catch(err => {\n this.showToast = false;\n console.error(err);\n });\n }\n };\n\n #close() {\n this.showToast = false;\n this.copied = false;\n this.showTooltip = false;\n }\n\n #openTooltip = () => {\n this.showTooltip = true;\n };\n\n #closeTooltip = () => {\n this.showTooltip = false;\n };\n}\n"],"mappings":";;;;;;;;;;;;;AAmCO,IAAA,IAAA,cAAyB,EAAO;;6BACX,qBAEG,uBAEE,cAES,IAAI,EAAqB,
|
|
1
|
+
{"version":3,"file":"copy-button2.js","names":["#i18nController","#close","#copy","#openTooltip","#closeTooltip"],"sources":["../../src/copy-button/copy-button.ts"],"sourcesContent":["// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { html, nothing } from 'lit';\nimport { property } from 'lit/decorators/property.js';\nimport { state } from 'lit/decorators/state.js';\nimport { useStyles, I18nController, scopedRegistry } from '@nvidia-elements/core/internal';\nimport { Button } from '@nvidia-elements/core/button';\nimport { Icon } from '@nvidia-elements/core/icon';\nimport { Toast } from '@nvidia-elements/core/toast';\nimport { Tooltip } from '@nvidia-elements/core/tooltip';\nimport styles from './copy-button.css?inline';\n\n/**\n * @element nve-copy-button\n * @description A copy button is a button that easily enables the copy to clipboard pattern.\n * @since 1.1.4\n * @entrypoint \\@nvidia-elements/core/copy-button\n * @slot - default\n * @slot icon - slot for custom icon\n * @cssprop --color\n * @cssprop --background\n * @cssprop --border-radius\n * @cssprop --padding\n * @cssprop --height\n * @cssprop --min-width\n * @cssprop --font-size\n * @cssprop --line-height\n * @csspart icon - The icon element\n * @csspart toast - The toast notification element\n * @csspart tooltip - The tooltip element\n * @aria https://www.w3.org/WAI/ARIA/apg/patterns/button/\n *\n */\n@scopedRegistry()\nexport class CopyButton extends Button {\n @state() private copied = false;\n\n @state() private showToast = false;\n\n @state() private showTooltip = false;\n\n #i18nController: I18nController<this> = new I18nController<this>(this);\n\n /**\n * Enables internal string values to update for internationalization.\n */\n @property({ type: Object }) i18n = this.#i18nController.i18n;\n\n /**\n * Determines if the copy button should auto write to clipboard by the trigger.\n */\n @property({ type: Boolean, reflect: true, attribute: 'behavior-copy' }) behaviorCopy: boolean;\n\n /**\n * Defines the value that copies to the user clipboard. Use `aria-label` to set the tooltip hint.\n */\n @property({ type: String }) value: string;\n\n static styles = useStyles([...Button.styles, styles]);\n\n static readonly metadata = {\n tag: 'nve-copy-button',\n version: '0.0.0'\n };\n\n static elementDefinitions = {\n [Icon.metadata.tag]: Icon,\n [Toast.metadata.tag]: Toast,\n [Tooltip.metadata.tag]: Tooltip\n };\n\n /* eslint-disable @nvidia-elements/lint/no-deprecated-popover-attributes */\n render() {\n return html`\n <div id=\"btn\" internal-host interaction-state focus-within>\n <slot></slot>\n ${\n this.copied\n ? html`<nve-icon part=\"icon\" name=\"check\" status=\"success\" .size=${this.size} aria-hidden=\"true\"></nve-icon>`\n : html`<slot name=\"icon\"><nve-icon part=\"icon\" name=\"copy\" .size=${this.size} aria-hidden=\"true\"></nve-icon></slot>`\n }\n </div>\n ${this.showToast ? html`<nve-toast part=\"toast\" @close=${this.#close} status=\"success\" anchor=\"btn\" trigger=\"btn\" position=\"top\" close-timeout=\"1500\">${this.i18n.copied}</nve-toast>` : nothing}\n ${this.showTooltip && !this.showToast ? html`<nve-tooltip part=\"tooltip\" exportparts=\"arrow:tooltip-arrow\" anchor=\"btn\" trigger=\"btn\">${this.ariaLabel ?? this.i18n.copy}</nve-tooltip>` : nothing}\n `;\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.addEventListener('click', this.#copy);\n this.addEventListener('mouseenter', this.#openTooltip);\n this.addEventListener('mouseleave', this.#closeTooltip);\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.removeEventListener('click', this.#copy);\n this.removeEventListener('mouseenter', this.#openTooltip);\n this.removeEventListener('mouseleave', this.#closeTooltip);\n }\n\n #copy = () => {\n if (this.behaviorCopy) {\n navigator.clipboard\n .writeText(this.value)\n .then(() => {\n this.showToast = true;\n this.copied = true;\n })\n .catch(err => {\n this.showToast = false;\n console.error(err);\n });\n }\n };\n\n #close() {\n this.showToast = false;\n this.copied = false;\n this.showTooltip = false;\n }\n\n #openTooltip = () => {\n this.showTooltip = true;\n };\n\n #closeTooltip = () => {\n this.showTooltip = false;\n };\n}\n"],"mappings":";;;;;;;;;;;;;AAmCO,IAAA,IAAA,cAAyB,EAAO;;6BACX,qBAEG,uBAEE,cAES,IAAI,EAAqB,IAAI,eAKlC,KAAKA,GAAgB,sBAuD1C;GACZ,AAAI,KAAK,gBACP,UAAU,UACP,UAAU,KAAK,KAAK,EACpB,WAAW;IAEV,AADA,KAAK,YAAY,IACjB,KAAK,SAAS;GAChB,CAAC,EACA,OAAM,MAAO;IAEZ,AADA,KAAK,YAAY,IACjB,QAAQ,MAAM,CAAG;GACnB,CAAC;EAEP,mBAQqB;GACnB,KAAK,cAAc;EACrB,mBAEsB;GACpB,KAAK,cAAc;EACrB;;CAvFA;;gBAiBgB,EAAU,CAAC,GAAG,EAAO,QAAQ,CAAM,CAAC;;;kBAEzB;GACzB,KAAK;GACL,SAAS;EACX;;;4BAE4B;IACzB,EAAK,SAAS,MAAM;IACpB,EAAM,SAAS,MAAM;IACrB,EAAQ,SAAS,MAAM;EAC1B;;CAGA,SAAS;EACP,OAAO,CAAI,2EAIL,KAAK,SACD,CAAI,8DAA6D,KAAK,KAAK,oCAC3E,CAAI,8DAA6D,KAAK,KAAK,yCAChF,QAEF,KAAK,YAAY,CAAI,mCAAkC,KAAKC,GAAO,oFAAmF,KAAK,KAAK,OAAO,gBAAgB,EAAQ,GAC/L,KAAK,eAAe,CAAC,KAAK,YAAY,CAAI,4FAA4F,KAAK,aAAa,KAAK,KAAK,KAAK,kBAAkB;CAE9L;CAEA,oBAAoB;EAIlB,AAHA,MAAM,kBAAkB,GACxB,KAAK,iBAAiB,SAAS,KAAKC,EAAK,GACzC,KAAK,iBAAiB,cAAc,KAAKC,EAAY,GACrD,KAAK,iBAAiB,cAAc,KAAKC,EAAa;CACxD;CAEA,uBAAuB;EAIrB,AAHA,MAAM,qBAAqB,GAC3B,KAAK,oBAAoB,SAAS,KAAKF,EAAK,GAC5C,KAAK,oBAAoB,cAAc,KAAKC,EAAY,GACxD,KAAK,oBAAoB,cAAc,KAAKC,EAAa;CAC3D;CAEA;CAeA,KAAS;EAGP,AAFA,KAAK,YAAY,IACjB,KAAK,SAAS,IACd,KAAK,cAAc;CACrB;CAEA;CAIA;AAGF;GA9FG,EAAM,CAAA,GAAA,EAAA,WAAA,UAAA,KAAA,CAAA,MAEN,EAAM,CAAA,GAAA,EAAA,WAAA,aAAA,KAAA,CAAA,MAEN,EAAM,CAAA,GAAA,EAAA,WAAA,eAAA,KAAA,CAAA,MAON,EAAS,EAAE,MAAM,OAAO,CAAC,CAAA,GAAA,EAAA,WAAA,QAAA,KAAA,CAAA,MAKzB,EAAS;CAAE,MAAM;CAAS,SAAS;CAAM,WAAW;AAAgB,CAAC,CAAA,GAAA,EAAA,WAAA,gBAAA,KAAA,CAAA,MAKrE,EAAS,EAAE,MAAM,OAAO,CAAC,CAAA,GAAA,EAAA,WAAA,SAAA,KAAA,CAAA,UAvB3B,EAAe,CAAA,GAAA,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"define.js","names":[],"sources":["../../src/copy-button/define.ts"],"sourcesContent":["// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { define } from '@nvidia-elements/core/internal';\nimport { CopyButton } from '@nvidia-elements/core/copy-button';\n\ndefine(CopyButton);\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nve-copy-button': CopyButton;\n }\n}\n"],"mappings":";;;AAMA,EAAO,
|
|
1
|
+
{"version":3,"file":"define.js","names":[],"sources":["../../src/copy-button/define.ts"],"sourcesContent":["// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.\n// SPDX-License-Identifier: Apache-2.0\n\nimport { define } from '@nvidia-elements/core/internal';\nimport { CopyButton } from '@nvidia-elements/core/copy-button';\n\ndefine(CopyButton);\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nve-copy-button': CopyButton;\n }\n}\n"],"mappings":";;;AAMA,EAAO,CAAU"}
|
|
@@ -440,10 +440,7 @@ export type ButtonProps = {
|
|
|
440
440
|
|
|
441
441
|
- `false` The associated content collapses and hides from the user. */
|
|
442
442
|
expanded?: boolean;
|
|
443
|
-
/**
|
|
444
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
445
|
-
|
|
446
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
443
|
+
/** */
|
|
447
444
|
readonly?: boolean;
|
|
448
445
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
449
446
|
Returns a reference to the form element if available.
|
|
@@ -495,6 +492,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
495
492
|
/** The idref of the element that receives the interest.
|
|
496
493
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
497
494
|
interestfor?: string | null;
|
|
495
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
496
|
+
readonly?: boolean;
|
|
498
497
|
};
|
|
499
498
|
|
|
500
499
|
export type CardProps = {
|
|
@@ -740,10 +739,7 @@ export type CopyButtonProps = {
|
|
|
740
739
|
|
|
741
740
|
- `false` The associated content collapses and hides from the user. */
|
|
742
741
|
expanded?: boolean;
|
|
743
|
-
/**
|
|
744
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
745
|
-
|
|
746
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
742
|
+
/** */
|
|
747
743
|
readonly?: boolean;
|
|
748
744
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
749
745
|
Returns a reference to the form element if available.
|
|
@@ -793,6 +789,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
793
789
|
/** The idref of the element that receives the interest.
|
|
794
790
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
795
791
|
interestfor?: string | null;
|
|
792
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
793
|
+
readonly?: boolean;
|
|
796
794
|
};
|
|
797
795
|
|
|
798
796
|
export type DateProps = {
|
|
@@ -1778,10 +1776,7 @@ Only supported by expand-panel/collapse-panel (horizontal axis) and arrow/caret/
|
|
|
1778
1776
|
|
|
1779
1777
|
- `false` The associated content collapses and hides from the user. */
|
|
1780
1778
|
expanded?: boolean;
|
|
1781
|
-
/**
|
|
1782
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
1783
|
-
|
|
1784
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
1779
|
+
/** */
|
|
1785
1780
|
readonly?: boolean;
|
|
1786
1781
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
1787
1782
|
Returns a reference to the form element if available.
|
|
@@ -1833,6 +1828,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
1833
1828
|
/** The idref of the element that receives the interest.
|
|
1834
1829
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
1835
1830
|
interestfor?: string | null;
|
|
1831
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
1832
|
+
readonly?: boolean;
|
|
1836
1833
|
};
|
|
1837
1834
|
|
|
1838
1835
|
export type IconProps = {
|
|
@@ -2251,10 +2248,7 @@ export type MenuItemProps = {
|
|
|
2251
2248
|
|
|
2252
2249
|
- `false` The associated content collapses and hides from the user. */
|
|
2253
2250
|
expanded?: boolean;
|
|
2254
|
-
/**
|
|
2255
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
2256
|
-
|
|
2257
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
2251
|
+
/** */
|
|
2258
2252
|
readonly?: boolean;
|
|
2259
2253
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
2260
2254
|
Returns a reference to the form element if available.
|
|
@@ -2306,6 +2300,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
2306
2300
|
/** The idref of the element that receives the interest.
|
|
2307
2301
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
2308
2302
|
interestfor?: string | null;
|
|
2303
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
2304
|
+
readonly?: boolean;
|
|
2309
2305
|
};
|
|
2310
2306
|
|
|
2311
2307
|
export type MenuProps = {
|
|
@@ -2969,10 +2965,7 @@ export type SortButtonProps = {
|
|
|
2969
2965
|
|
|
2970
2966
|
- `false` The associated content collapses and hides from the user. */
|
|
2971
2967
|
expanded?: boolean;
|
|
2972
|
-
/**
|
|
2973
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
2974
|
-
|
|
2975
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
2968
|
+
/** */
|
|
2976
2969
|
readonly?: boolean;
|
|
2977
2970
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
2978
2971
|
Returns a reference to the form element if available.
|
|
@@ -3024,7 +3017,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
3024
3017
|
/** The idref of the element that receives the interest.
|
|
3025
3018
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
3026
3019
|
interestfor?: string | null;
|
|
3027
|
-
|
|
3020
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
3021
|
+
readonly?: boolean;
|
|
3028
3022
|
/** Dispatched on sort button click, returns the current sort value and the next sort value. */
|
|
3029
3023
|
onsort?: (e: CustomEvent<never>) => void;
|
|
3030
3024
|
};
|
|
@@ -3195,10 +3189,7 @@ Demonstrates different container styles to accommodate visual weight and context
|
|
|
3195
3189
|
|
|
3196
3190
|
- `false` The associated content collapses and hides from the user. */
|
|
3197
3191
|
expanded?: boolean;
|
|
3198
|
-
/**
|
|
3199
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
3200
|
-
|
|
3201
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
3192
|
+
/** */
|
|
3202
3193
|
readonly?: boolean;
|
|
3203
3194
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
3204
3195
|
Returns a reference to the form element if available.
|
|
@@ -3245,6 +3236,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
3245
3236
|
/** The idref of the element that receives the interest.
|
|
3246
3237
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
3247
3238
|
interestfor?: string | null;
|
|
3239
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
3240
|
+
readonly?: boolean;
|
|
3248
3241
|
};
|
|
3249
3242
|
|
|
3250
3243
|
export type StepsProps = {
|
|
@@ -3349,10 +3342,7 @@ export type TabsItemProps = {
|
|
|
3349
3342
|
|
|
3350
3343
|
- `false` The associated content collapses and hides from the user. */
|
|
3351
3344
|
expanded?: boolean;
|
|
3352
|
-
/**
|
|
3353
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
3354
|
-
|
|
3355
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
3345
|
+
/** */
|
|
3356
3346
|
readonly?: boolean;
|
|
3357
3347
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
3358
3348
|
Returns a reference to the form element if available.
|
|
@@ -3399,6 +3389,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
3399
3389
|
/** The idref of the element that receives the interest.
|
|
3400
3390
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
3401
3391
|
interestfor?: string | null;
|
|
3392
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
3393
|
+
readonly?: boolean;
|
|
3402
3394
|
};
|
|
3403
3395
|
|
|
3404
3396
|
export type TabsProps = {
|
|
@@ -3463,10 +3455,7 @@ export type TagProps = {
|
|
|
3463
3455
|
|
|
3464
3456
|
- `false` The associated content collapses and hides from the user. */
|
|
3465
3457
|
expanded?: boolean;
|
|
3466
|
-
/**
|
|
3467
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
3468
|
-
|
|
3469
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
3458
|
+
/** */
|
|
3470
3459
|
readonly?: boolean;
|
|
3471
3460
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
3472
3461
|
Returns a reference to the form element if available.
|
|
@@ -3518,6 +3507,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
3518
3507
|
/** The idref of the element that receives the interest.
|
|
3519
3508
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
3520
3509
|
interestfor?: string | null;
|
|
3510
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
3511
|
+
readonly?: boolean;
|
|
3521
3512
|
};
|
|
3522
3513
|
|
|
3523
3514
|
export type TextareaProps = {
|
|
@@ -367,10 +367,7 @@ type ButtonProps = {
|
|
|
367
367
|
|
|
368
368
|
- `false` The associated content collapses and hides from the user. */
|
|
369
369
|
expanded?: boolean;
|
|
370
|
-
/**
|
|
371
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
372
|
-
|
|
373
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
370
|
+
/** */
|
|
374
371
|
readonly?: boolean;
|
|
375
372
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
376
373
|
Returns a reference to the form element if available.
|
|
@@ -422,6 +419,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
422
419
|
/** The idref of the element that receives the interest.
|
|
423
420
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
424
421
|
interestfor?: string | null;
|
|
422
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
423
|
+
readonly?: boolean;
|
|
425
424
|
};
|
|
426
425
|
|
|
427
426
|
type CardProps = {
|
|
@@ -667,10 +666,7 @@ type CopyButtonProps = {
|
|
|
667
666
|
|
|
668
667
|
- `false` The associated content collapses and hides from the user. */
|
|
669
668
|
expanded?: boolean;
|
|
670
|
-
/**
|
|
671
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
672
|
-
|
|
673
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
669
|
+
/** */
|
|
674
670
|
readonly?: boolean;
|
|
675
671
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
676
672
|
Returns a reference to the form element if available.
|
|
@@ -720,6 +716,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
720
716
|
/** The idref of the element that receives the interest.
|
|
721
717
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
722
718
|
interestfor?: string | null;
|
|
719
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
720
|
+
readonly?: boolean;
|
|
723
721
|
};
|
|
724
722
|
|
|
725
723
|
type DateProps = {
|
|
@@ -1705,10 +1703,7 @@ Only supported by expand-panel/collapse-panel (horizontal axis) and arrow/caret/
|
|
|
1705
1703
|
|
|
1706
1704
|
- `false` The associated content collapses and hides from the user. */
|
|
1707
1705
|
expanded?: boolean;
|
|
1708
|
-
/**
|
|
1709
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
1710
|
-
|
|
1711
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
1706
|
+
/** */
|
|
1712
1707
|
readonly?: boolean;
|
|
1713
1708
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
1714
1709
|
Returns a reference to the form element if available.
|
|
@@ -1760,6 +1755,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
1760
1755
|
/** The idref of the element that receives the interest.
|
|
1761
1756
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
1762
1757
|
interestfor?: string | null;
|
|
1758
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
1759
|
+
readonly?: boolean;
|
|
1763
1760
|
};
|
|
1764
1761
|
|
|
1765
1762
|
type IconProps = {
|
|
@@ -2178,10 +2175,7 @@ type MenuItemProps = {
|
|
|
2178
2175
|
|
|
2179
2176
|
- `false` The associated content collapses and hides from the user. */
|
|
2180
2177
|
expanded?: boolean;
|
|
2181
|
-
/**
|
|
2182
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
2183
|
-
|
|
2184
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
2178
|
+
/** */
|
|
2185
2179
|
readonly?: boolean;
|
|
2186
2180
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
2187
2181
|
Returns a reference to the form element if available.
|
|
@@ -2233,6 +2227,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
2233
2227
|
/** The idref of the element that receives the interest.
|
|
2234
2228
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
2235
2229
|
interestfor?: string | null;
|
|
2230
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
2231
|
+
readonly?: boolean;
|
|
2236
2232
|
};
|
|
2237
2233
|
|
|
2238
2234
|
type MenuProps = {
|
|
@@ -2896,10 +2892,7 @@ type SortButtonProps = {
|
|
|
2896
2892
|
|
|
2897
2893
|
- `false` The associated content collapses and hides from the user. */
|
|
2898
2894
|
expanded?: boolean;
|
|
2899
|
-
/**
|
|
2900
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
2901
|
-
|
|
2902
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
2895
|
+
/** */
|
|
2903
2896
|
readonly?: boolean;
|
|
2904
2897
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
2905
2898
|
Returns a reference to the form element if available.
|
|
@@ -2951,7 +2944,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
2951
2944
|
/** The idref of the element that receives the interest.
|
|
2952
2945
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
2953
2946
|
interestfor?: string | null;
|
|
2954
|
-
|
|
2947
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
2948
|
+
readonly?: boolean;
|
|
2955
2949
|
/** Dispatched on sort button click, returns the current sort value and the next sort value. */
|
|
2956
2950
|
onsort?: (e: CustomEvent<never>) => void;
|
|
2957
2951
|
};
|
|
@@ -3122,10 +3116,7 @@ Demonstrates different container styles to accommodate visual weight and context
|
|
|
3122
3116
|
|
|
3123
3117
|
- `false` The associated content collapses and hides from the user. */
|
|
3124
3118
|
expanded?: boolean;
|
|
3125
|
-
/**
|
|
3126
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
3127
|
-
|
|
3128
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
3119
|
+
/** */
|
|
3129
3120
|
readonly?: boolean;
|
|
3130
3121
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
3131
3122
|
Returns a reference to the form element if available.
|
|
@@ -3172,6 +3163,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
3172
3163
|
/** The idref of the element that receives the interest.
|
|
3173
3164
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
3174
3165
|
interestfor?: string | null;
|
|
3166
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
3167
|
+
readonly?: boolean;
|
|
3175
3168
|
};
|
|
3176
3169
|
|
|
3177
3170
|
type StepsProps = {
|
|
@@ -3276,10 +3269,7 @@ type TabsItemProps = {
|
|
|
3276
3269
|
|
|
3277
3270
|
- `false` The associated content collapses and hides from the user. */
|
|
3278
3271
|
expanded?: boolean;
|
|
3279
|
-
/**
|
|
3280
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
3281
|
-
|
|
3282
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
3272
|
+
/** */
|
|
3283
3273
|
readonly?: boolean;
|
|
3284
3274
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
3285
3275
|
Returns a reference to the form element if available.
|
|
@@ -3326,6 +3316,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
3326
3316
|
/** The idref of the element that receives the interest.
|
|
3327
3317
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
3328
3318
|
interestfor?: string | null;
|
|
3319
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
3320
|
+
readonly?: boolean;
|
|
3329
3321
|
};
|
|
3330
3322
|
|
|
3331
3323
|
type TabsProps = {
|
|
@@ -3390,10 +3382,7 @@ type TagProps = {
|
|
|
3390
3382
|
|
|
3391
3383
|
- `false` The associated content collapses and hides from the user. */
|
|
3392
3384
|
expanded?: boolean;
|
|
3393
|
-
/**
|
|
3394
|
-
- `true` The element has a readonly state: the user cannot change its value, but can still focus and copy it.
|
|
3395
|
-
|
|
3396
|
-
- `false` The element allows editing and the user can change its value through interaction. */
|
|
3385
|
+
/** */
|
|
3397
3386
|
readonly?: boolean;
|
|
3398
3387
|
/** Like input form, sets a button to submit a form outside its parent form.
|
|
3399
3388
|
Returns a reference to the form element if available.
|
|
@@ -3445,6 +3434,8 @@ https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForEl
|
|
|
3445
3434
|
/** The idref of the element that receives the interest.
|
|
3446
3435
|
https://developer.mozilla.org/en-US/docs/Web/API/HTMLAnchorElement/interestForElement */
|
|
3447
3436
|
interestfor?: string | null;
|
|
3437
|
+
/** @deprecated Use `readOnly`. The `readonly` attribute remains supported. */
|
|
3438
|
+
readonly?: boolean;
|
|
3448
3439
|
};
|
|
3449
3440
|
|
|
3450
3441
|
type TextareaProps = {
|