@qualcomm-ui/core 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.txt +31 -0
- package/dist/accordion/accordion.api.d.ts +4 -0
- package/dist/accordion/accordion.api.d.ts.map +1 -0
- package/dist/accordion/accordion.machine.d.ts +4 -0
- package/dist/accordion/accordion.machine.d.ts.map +1 -0
- package/dist/accordion/accordion.props.d.ts +3 -0
- package/dist/accordion/accordion.props.d.ts.map +1 -0
- package/dist/accordion/accordion.types.d.ts +155 -0
- package/dist/accordion/accordion.types.d.ts.map +1 -0
- package/dist/accordion/index.cjs +2 -0
- package/dist/accordion/index.cjs.map +7 -0
- package/dist/accordion/index.d.ts +5 -0
- package/dist/accordion/index.d.ts.map +1 -0
- package/dist/accordion/index.js +2 -0
- package/dist/accordion/index.js.map +7 -0
- package/dist/accordion/internal/accordion.dom.d.ts +10 -0
- package/dist/accordion/internal/accordion.dom.d.ts.map +1 -0
- package/dist/accordion/internal/index.d.ts +2 -0
- package/dist/accordion/internal/index.d.ts.map +1 -0
- package/dist/action-group/action-group.d.ts +6 -0
- package/dist/action-group/action-group.d.ts.map +1 -0
- package/dist/action-group/index.cjs +2 -0
- package/dist/action-group/index.cjs.map +7 -0
- package/dist/action-group/index.d.ts +2 -0
- package/dist/action-group/index.d.ts.map +1 -0
- package/dist/action-group/index.js +2 -0
- package/dist/action-group/index.js.map +7 -0
- package/dist/avatar/avatar.api.d.ts +4 -0
- package/dist/avatar/avatar.api.d.ts.map +1 -0
- package/dist/avatar/avatar.machine.d.ts +4 -0
- package/dist/avatar/avatar.machine.d.ts.map +1 -0
- package/dist/avatar/avatar.props.d.ts +3 -0
- package/dist/avatar/avatar.props.d.ts.map +1 -0
- package/dist/avatar/avatar.types.d.ts +55 -0
- package/dist/avatar/avatar.types.d.ts.map +1 -0
- package/dist/avatar/index.cjs +2 -0
- package/dist/avatar/index.cjs.map +7 -0
- package/dist/avatar/index.d.ts +5 -0
- package/dist/avatar/index.d.ts.map +1 -0
- package/dist/avatar/index.js +2 -0
- package/dist/avatar/index.js.map +7 -0
- package/dist/avatar/internal/avatar.dom.d.ts +12 -0
- package/dist/avatar/internal/avatar.dom.d.ts.map +1 -0
- package/dist/avatar/internal/index.d.ts +2 -0
- package/dist/avatar/internal/index.d.ts.map +1 -0
- package/dist/checkbox/checkbox.api.d.ts +4 -0
- package/dist/checkbox/checkbox.api.d.ts.map +1 -0
- package/dist/checkbox/checkbox.machine.d.ts +4 -0
- package/dist/checkbox/checkbox.machine.d.ts.map +1 -0
- package/dist/checkbox/checkbox.props.d.ts +3 -0
- package/dist/checkbox/checkbox.props.d.ts.map +1 -0
- package/dist/checkbox/checkbox.types.d.ts +165 -0
- package/dist/checkbox/checkbox.types.d.ts.map +1 -0
- package/dist/checkbox/index.cjs +2 -0
- package/dist/checkbox/index.cjs.map +7 -0
- package/dist/checkbox/index.d.ts +5 -0
- package/dist/checkbox/index.d.ts.map +1 -0
- package/dist/checkbox/index.js +2 -0
- package/dist/checkbox/index.js.map +7 -0
- package/dist/checkbox/internal/checkbox.dom.d.ts +7 -0
- package/dist/checkbox/internal/checkbox.dom.d.ts.map +1 -0
- package/dist/checkbox/internal/index.d.ts +2 -0
- package/dist/checkbox/internal/index.d.ts.map +1 -0
- package/dist/collapsible/collapsible.api.d.ts +4 -0
- package/dist/collapsible/collapsible.api.d.ts.map +1 -0
- package/dist/collapsible/collapsible.machine.d.ts +4 -0
- package/dist/collapsible/collapsible.machine.d.ts.map +1 -0
- package/dist/collapsible/collapsible.props.d.ts +4 -0
- package/dist/collapsible/collapsible.props.d.ts.map +1 -0
- package/dist/collapsible/collapsible.types.d.ts +129 -0
- package/dist/collapsible/collapsible.types.d.ts.map +1 -0
- package/dist/collapsible/index.cjs +2 -0
- package/dist/collapsible/index.cjs.map +7 -0
- package/dist/collapsible/index.d.ts +5 -0
- package/dist/collapsible/index.d.ts.map +1 -0
- package/dist/collapsible/index.js +2 -0
- package/dist/collapsible/index.js.map +7 -0
- package/dist/collapsible/internal/collapsible.dom.d.ts +5 -0
- package/dist/collapsible/internal/collapsible.dom.d.ts.map +1 -0
- package/dist/collapsible/internal/index.d.ts +2 -0
- package/dist/collapsible/internal/index.d.ts.map +1 -0
- package/dist/combobox/combobox.api.d.ts +4 -0
- package/dist/combobox/combobox.api.d.ts.map +1 -0
- package/dist/combobox/combobox.collection.d.ts +4 -0
- package/dist/combobox/combobox.collection.d.ts.map +1 -0
- package/dist/combobox/combobox.machine.d.ts +4 -0
- package/dist/combobox/combobox.machine.d.ts.map +1 -0
- package/dist/combobox/combobox.props.d.ts +4 -0
- package/dist/combobox/combobox.props.d.ts.map +1 -0
- package/dist/combobox/combobox.types.d.ts +631 -0
- package/dist/combobox/combobox.types.d.ts.map +1 -0
- package/dist/combobox/index.cjs +2 -0
- package/dist/combobox/index.cjs.map +7 -0
- package/dist/combobox/index.d.ts +6 -0
- package/dist/combobox/index.d.ts.map +1 -0
- package/dist/combobox/index.js +2 -0
- package/dist/combobox/index.js.map +7 -0
- package/dist/combobox/internal/combobox.dom.d.ts +13 -0
- package/dist/combobox/internal/combobox.dom.d.ts.map +1 -0
- package/dist/combobox/internal/index.d.ts +2 -0
- package/dist/combobox/internal/index.d.ts.map +1 -0
- package/dist/dialog/dialog.api.d.ts +4 -0
- package/dist/dialog/dialog.api.d.ts.map +1 -0
- package/dist/dialog/dialog.machine.d.ts +4 -0
- package/dist/dialog/dialog.machine.d.ts.map +1 -0
- package/dist/dialog/dialog.props.d.ts +4 -0
- package/dist/dialog/dialog.props.d.ts.map +1 -0
- package/dist/dialog/dialog.types.d.ts +184 -0
- package/dist/dialog/dialog.types.d.ts.map +1 -0
- package/dist/dialog/index.cjs +2 -0
- package/dist/dialog/index.cjs.map +7 -0
- package/dist/dialog/index.d.ts +5 -0
- package/dist/dialog/index.d.ts.map +1 -0
- package/dist/dialog/index.js +2 -0
- package/dist/dialog/index.js.map +7 -0
- package/dist/dialog/internal/dialog.dom.d.ts +5 -0
- package/dist/dialog/internal/dialog.dom.d.ts.map +1 -0
- package/dist/dialog/internal/index.d.ts +2 -0
- package/dist/dialog/internal/index.d.ts.map +1 -0
- package/dist/dnd/dnd.types.d.ts +13 -0
- package/dist/dnd/dnd.types.d.ts.map +1 -0
- package/dist/dnd/index.cjs +2 -0
- package/dist/dnd/index.cjs.map +7 -0
- package/dist/dnd/index.d.ts +2 -0
- package/dist/dnd/index.d.ts.map +1 -0
- package/dist/dnd/index.js +1 -0
- package/dist/dnd/index.js.map +7 -0
- package/dist/field/field.types.d.ts +87 -0
- package/dist/field/field.types.d.ts.map +1 -0
- package/dist/field/index.cjs +2 -0
- package/dist/field/index.cjs.map +7 -0
- package/dist/field/index.d.ts +2 -0
- package/dist/field/index.d.ts.map +1 -0
- package/dist/field/index.js +1 -0
- package/dist/field/index.js.map +7 -0
- package/dist/fieldset/fieldset.types.d.ts +49 -0
- package/dist/fieldset/fieldset.types.d.ts.map +1 -0
- package/dist/fieldset/index.cjs +2 -0
- package/dist/fieldset/index.cjs.map +7 -0
- package/dist/fieldset/index.d.ts +2 -0
- package/dist/fieldset/index.d.ts.map +1 -0
- package/dist/fieldset/index.js +1 -0
- package/dist/fieldset/index.js.map +7 -0
- package/dist/inline-notification/index.cjs +2 -0
- package/dist/inline-notification/index.cjs.map +7 -0
- package/dist/inline-notification/index.d.ts +5 -0
- package/dist/inline-notification/index.d.ts.map +1 -0
- package/dist/inline-notification/index.js +2 -0
- package/dist/inline-notification/index.js.map +7 -0
- package/dist/inline-notification/inline-notification.api.d.ts +4 -0
- package/dist/inline-notification/inline-notification.api.d.ts.map +1 -0
- package/dist/inline-notification/inline-notification.machine.d.ts +4 -0
- package/dist/inline-notification/inline-notification.machine.d.ts.map +1 -0
- package/dist/inline-notification/inline-notification.props.d.ts +7 -0
- package/dist/inline-notification/inline-notification.props.d.ts.map +1 -0
- package/dist/inline-notification/inline-notification.types.d.ts +76 -0
- package/dist/inline-notification/inline-notification.types.d.ts.map +1 -0
- package/dist/inline-notification/internal/index.d.ts +2 -0
- package/dist/inline-notification/internal/index.d.ts.map +1 -0
- package/dist/inline-notification/internal/inline-notification.dom.d.ts +4 -0
- package/dist/inline-notification/internal/inline-notification.dom.d.ts.map +1 -0
- package/dist/input/index.cjs +2 -0
- package/dist/input/index.cjs.map +7 -0
- package/dist/input/index.d.ts +2 -0
- package/dist/input/index.d.ts.map +1 -0
- package/dist/input/index.js +1 -0
- package/dist/input/index.js.map +7 -0
- package/dist/input/input.types.d.ts +66 -0
- package/dist/input/input.types.d.ts.map +1 -0
- package/dist/menu/index.cjs +2 -0
- package/dist/menu/index.cjs.map +7 -0
- package/dist/menu/index.d.ts +5 -0
- package/dist/menu/index.d.ts.map +1 -0
- package/dist/menu/index.js +2 -0
- package/dist/menu/index.js.map +7 -0
- package/dist/menu/internal/index.d.ts +2 -0
- package/dist/menu/internal/index.d.ts.map +1 -0
- package/dist/menu/internal/menu.dom.d.ts +33 -0
- package/dist/menu/internal/menu.dom.d.ts.map +1 -0
- package/dist/menu/menu.api.d.ts +4 -0
- package/dist/menu/menu.api.d.ts.map +1 -0
- package/dist/menu/menu.machine.d.ts +4 -0
- package/dist/menu/menu.machine.d.ts.map +1 -0
- package/dist/menu/menu.props.d.ts +8 -0
- package/dist/menu/menu.props.d.ts.map +1 -0
- package/dist/menu/menu.types.d.ts +482 -0
- package/dist/menu/menu.types.d.ts.map +1 -0
- package/dist/number-input/index.cjs +2 -0
- package/dist/number-input/index.cjs.map +7 -0
- package/dist/number-input/index.d.ts +6 -0
- package/dist/number-input/index.d.ts.map +1 -0
- package/dist/number-input/index.js +2 -0
- package/dist/number-input/index.js.map +7 -0
- package/dist/number-input/internal/index.d.ts +2 -0
- package/dist/number-input/internal/index.d.ts.map +1 -0
- package/dist/number-input/internal/number-input.dom.d.ts +10 -0
- package/dist/number-input/internal/number-input.dom.d.ts.map +1 -0
- package/dist/number-input/number-input.api.d.ts +4 -0
- package/dist/number-input/number-input.api.d.ts.map +1 -0
- package/dist/number-input/number-input.machine.d.ts +4 -0
- package/dist/number-input/number-input.machine.d.ts.map +1 -0
- package/dist/number-input/number-input.props.d.ts +4 -0
- package/dist/number-input/number-input.props.d.ts.map +1 -0
- package/dist/number-input/number-input.types.d.ts +395 -0
- package/dist/number-input/number-input.types.d.ts.map +1 -0
- package/dist/number-input/number-input.utils.d.ts +11 -0
- package/dist/number-input/number-input.utils.d.ts.map +1 -0
- package/dist/overlay-panel/index.cjs.map +7 -0
- package/dist/overlay-panel/index.d.ts +2 -0
- package/dist/overlay-panel/index.d.ts.map +1 -0
- package/dist/overlay-panel/overlay-panel.types.d.ts +2 -0
- package/dist/overlay-panel/overlay-panel.types.d.ts.map +1 -0
- package/dist/pagination/index.cjs +2 -0
- package/dist/pagination/index.cjs.map +7 -0
- package/dist/pagination/index.d.ts +5 -0
- package/dist/pagination/index.d.ts.map +1 -0
- package/dist/pagination/index.js +2 -0
- package/dist/pagination/index.js.map +7 -0
- package/dist/pagination/pagination.api.d.ts +4 -0
- package/dist/pagination/pagination.api.d.ts.map +1 -0
- package/dist/pagination/pagination.machine.d.ts +4 -0
- package/dist/pagination/pagination.machine.d.ts.map +1 -0
- package/dist/pagination/pagination.props.d.ts +3 -0
- package/dist/pagination/pagination.props.d.ts.map +1 -0
- package/dist/pagination/pagination.types.d.ts +214 -0
- package/dist/pagination/pagination.types.d.ts.map +1 -0
- package/dist/password-input/index.cjs +2 -0
- package/dist/password-input/index.cjs.map +7 -0
- package/dist/password-input/index.d.ts +5 -0
- package/dist/password-input/index.d.ts.map +1 -0
- package/dist/password-input/index.js +2 -0
- package/dist/password-input/index.js.map +7 -0
- package/dist/password-input/internal/index.d.ts +2 -0
- package/dist/password-input/internal/index.d.ts.map +1 -0
- package/dist/password-input/internal/password.dom.d.ts +7 -0
- package/dist/password-input/internal/password.dom.d.ts.map +1 -0
- package/dist/password-input/password-input.api.d.ts +4 -0
- package/dist/password-input/password-input.api.d.ts.map +1 -0
- package/dist/password-input/password-input.machine.d.ts +4 -0
- package/dist/password-input/password-input.machine.d.ts.map +1 -0
- package/dist/password-input/password-input.props.d.ts +3 -0
- package/dist/password-input/password-input.props.d.ts.map +1 -0
- package/dist/password-input/password-input.types.d.ts +172 -0
- package/dist/password-input/password-input.types.d.ts.map +1 -0
- package/dist/popover/index.cjs +2 -0
- package/dist/popover/index.cjs.map +7 -0
- package/dist/popover/index.d.ts +5 -0
- package/dist/popover/index.d.ts.map +1 -0
- package/dist/popover/index.js +2 -0
- package/dist/popover/index.js.map +7 -0
- package/dist/popover/internal/index.d.ts +2 -0
- package/dist/popover/internal/index.d.ts.map +1 -0
- package/dist/popover/internal/popover.dom.d.ts +8 -0
- package/dist/popover/internal/popover.dom.d.ts.map +1 -0
- package/dist/popover/popover.api.d.ts +4 -0
- package/dist/popover/popover.api.d.ts.map +1 -0
- package/dist/popover/popover.machine.d.ts +4 -0
- package/dist/popover/popover.machine.d.ts.map +1 -0
- package/dist/popover/popover.props.d.ts +3 -0
- package/dist/popover/popover.props.d.ts.map +1 -0
- package/dist/popover/popover.types.d.ts +233 -0
- package/dist/popover/popover.types.d.ts.map +1 -0
- package/dist/presence/index.cjs +2 -0
- package/dist/presence/index.cjs.map +7 -0
- package/dist/presence/index.d.ts +5 -0
- package/dist/presence/index.d.ts.map +1 -0
- package/dist/presence/index.js +2 -0
- package/dist/presence/index.js.map +7 -0
- package/dist/presence/presence.api.d.ts +4 -0
- package/dist/presence/presence.api.d.ts.map +1 -0
- package/dist/presence/presence.machine.d.ts +4 -0
- package/dist/presence/presence.machine.d.ts.map +1 -0
- package/dist/presence/presence.props.d.ts +6 -0
- package/dist/presence/presence.props.d.ts.map +1 -0
- package/dist/presence/presence.types.d.ts +94 -0
- package/dist/presence/presence.types.d.ts.map +1 -0
- package/dist/progress/index.cjs +2 -0
- package/dist/progress/index.cjs.map +7 -0
- package/dist/progress/index.d.ts +5 -0
- package/dist/progress/index.d.ts.map +1 -0
- package/dist/progress/index.js +2 -0
- package/dist/progress/index.js.map +7 -0
- package/dist/progress/internal/index.d.ts +2 -0
- package/dist/progress/internal/index.d.ts.map +1 -0
- package/dist/progress/internal/progress.dom.d.ts +4 -0
- package/dist/progress/internal/progress.dom.d.ts.map +1 -0
- package/dist/progress/progress.api.d.ts +4 -0
- package/dist/progress/progress.api.d.ts.map +1 -0
- package/dist/progress/progress.machine.d.ts +4 -0
- package/dist/progress/progress.machine.d.ts.map +1 -0
- package/dist/progress/progress.props.d.ts +4 -0
- package/dist/progress/progress.props.d.ts.map +1 -0
- package/dist/progress/progress.types.d.ts +182 -0
- package/dist/progress/progress.types.d.ts.map +1 -0
- package/dist/radio/index.cjs +2 -0
- package/dist/radio/index.cjs.map +7 -0
- package/dist/radio/index.d.ts +5 -0
- package/dist/radio/index.d.ts.map +1 -0
- package/dist/radio/index.js +2 -0
- package/dist/radio/index.js.map +7 -0
- package/dist/radio/internal/index.d.ts +2 -0
- package/dist/radio/internal/index.d.ts.map +1 -0
- package/dist/radio/internal/radio.dom.d.ts +10 -0
- package/dist/radio/internal/radio.dom.d.ts.map +1 -0
- package/dist/radio/radio.api.d.ts +4 -0
- package/dist/radio/radio.api.d.ts.map +1 -0
- package/dist/radio/radio.machine.d.ts +4 -0
- package/dist/radio/radio.machine.d.ts.map +1 -0
- package/dist/radio/radio.props.d.ts +4 -0
- package/dist/radio/radio.props.d.ts.map +1 -0
- package/dist/radio/radio.types.d.ts +233 -0
- package/dist/radio/radio.types.d.ts.map +1 -0
- package/dist/segmented-control/index.cjs +2 -0
- package/dist/segmented-control/index.cjs.map +7 -0
- package/dist/segmented-control/index.d.ts +5 -0
- package/dist/segmented-control/index.d.ts.map +1 -0
- package/dist/segmented-control/index.js +2 -0
- package/dist/segmented-control/index.js.map +7 -0
- package/dist/segmented-control/internal/index.d.ts +2 -0
- package/dist/segmented-control/internal/index.d.ts.map +1 -0
- package/dist/segmented-control/internal/segmented-control.dom.d.ts +7 -0
- package/dist/segmented-control/internal/segmented-control.dom.d.ts.map +1 -0
- package/dist/segmented-control/segmented-control.api.d.ts +4 -0
- package/dist/segmented-control/segmented-control.api.d.ts.map +1 -0
- package/dist/segmented-control/segmented-control.machine.d.ts +4 -0
- package/dist/segmented-control/segmented-control.machine.d.ts.map +1 -0
- package/dist/segmented-control/segmented-control.props.d.ts +4 -0
- package/dist/segmented-control/segmented-control.props.d.ts.map +1 -0
- package/dist/segmented-control/segmented-control.types.d.ts +103 -0
- package/dist/segmented-control/segmented-control.types.d.ts.map +1 -0
- package/dist/select/index.cjs +2 -0
- package/dist/select/index.cjs.map +7 -0
- package/dist/select/index.d.ts +6 -0
- package/dist/select/index.d.ts.map +1 -0
- package/dist/select/index.js +2 -0
- package/dist/select/index.js.map +7 -0
- package/dist/select/internal/index.d.ts +2 -0
- package/dist/select/internal/index.d.ts.map +1 -0
- package/dist/select/internal/select.dom.d.ts +9 -0
- package/dist/select/internal/select.dom.d.ts.map +1 -0
- package/dist/select/select.api.d.ts +4 -0
- package/dist/select/select.api.d.ts.map +1 -0
- package/dist/select/select.collection.d.ts +4 -0
- package/dist/select/select.collection.d.ts.map +1 -0
- package/dist/select/select.machine.d.ts +4 -0
- package/dist/select/select.machine.d.ts.map +1 -0
- package/dist/select/select.props.d.ts +3 -0
- package/dist/select/select.props.d.ts.map +1 -0
- package/dist/select/select.types.d.ts +582 -0
- package/dist/select/select.types.d.ts.map +1 -0
- package/dist/side-nav/index.cjs +2 -0
- package/dist/side-nav/index.cjs.map +7 -0
- package/dist/side-nav/index.d.ts +5 -0
- package/dist/side-nav/index.d.ts.map +1 -0
- package/dist/side-nav/index.js +2 -0
- package/dist/side-nav/index.js.map +7 -0
- package/dist/side-nav/internal/index.d.ts +2 -0
- package/dist/side-nav/internal/index.d.ts.map +1 -0
- package/dist/side-nav/internal/side-nav.dom.d.ts +5 -0
- package/dist/side-nav/internal/side-nav.dom.d.ts.map +1 -0
- package/dist/side-nav/side-nav.api.d.ts +4 -0
- package/dist/side-nav/side-nav.api.d.ts.map +1 -0
- package/dist/side-nav/side-nav.machine.d.ts +4 -0
- package/dist/side-nav/side-nav.machine.d.ts.map +1 -0
- package/dist/side-nav/side-nav.props.d.ts +4 -0
- package/dist/side-nav/side-nav.props.d.ts.map +1 -0
- package/dist/side-nav/side-nav.types.d.ts +108 -0
- package/dist/side-nav/side-nav.types.d.ts.map +1 -0
- package/dist/slider/index.cjs +2 -0
- package/dist/slider/index.cjs.map +7 -0
- package/dist/slider/index.d.ts +5 -0
- package/dist/slider/index.d.ts.map +1 -0
- package/dist/slider/index.js +2 -0
- package/dist/slider/index.js.map +7 -0
- package/dist/slider/slider.api.d.ts +4 -0
- package/dist/slider/slider.api.d.ts.map +1 -0
- package/dist/slider/slider.dom.d.ts +18 -0
- package/dist/slider/slider.dom.d.ts.map +1 -0
- package/dist/slider/slider.machine.d.ts +4 -0
- package/dist/slider/slider.machine.d.ts.map +1 -0
- package/dist/slider/slider.props.d.ts +4 -0
- package/dist/slider/slider.props.d.ts.map +1 -0
- package/dist/slider/slider.style.d.ts +21 -0
- package/dist/slider/slider.style.d.ts.map +1 -0
- package/dist/slider/slider.types.d.ts +449 -0
- package/dist/slider/slider.types.d.ts.map +1 -0
- package/dist/slider/slider.utils.d.ts +17 -0
- package/dist/slider/slider.utils.d.ts.map +1 -0
- package/dist/switch/index.cjs +2 -0
- package/dist/switch/index.cjs.map +7 -0
- package/dist/switch/index.d.ts +5 -0
- package/dist/switch/index.d.ts.map +1 -0
- package/dist/switch/index.js +2 -0
- package/dist/switch/index.js.map +7 -0
- package/dist/switch/internal/index.d.ts +2 -0
- package/dist/switch/internal/index.d.ts.map +1 -0
- package/dist/switch/internal/switch.dom.d.ts +7 -0
- package/dist/switch/internal/switch.dom.d.ts.map +1 -0
- package/dist/switch/switch.api.d.ts +4 -0
- package/dist/switch/switch.api.d.ts.map +1 -0
- package/dist/switch/switch.machine.d.ts +4 -0
- package/dist/switch/switch.machine.d.ts.map +1 -0
- package/dist/switch/switch.props.d.ts +4 -0
- package/dist/switch/switch.props.d.ts.map +1 -0
- package/dist/switch/switch.types.d.ts +157 -0
- package/dist/switch/switch.types.d.ts.map +1 -0
- package/dist/table/aggregation-fns.d.ts +14 -0
- package/dist/table/aggregation-fns.d.ts.map +1 -0
- package/dist/table/column-helper.d.ts +9 -0
- package/dist/table/column-helper.d.ts.map +1 -0
- package/dist/table/core/cell.d.ts +46 -0
- package/dist/table/core/cell.d.ts.map +1 -0
- package/dist/table/core/column.d.ts +55 -0
- package/dist/table/core/column.d.ts.map +1 -0
- package/dist/table/core/headers.d.ts +196 -0
- package/dist/table/core/headers.d.ts.map +1 -0
- package/dist/table/core/row.d.ts +76 -0
- package/dist/table/core/row.d.ts.map +1 -0
- package/dist/table/core/table.d.ts +244 -0
- package/dist/table/core/table.d.ts.map +1 -0
- package/dist/table/dom.d.ts +3 -0
- package/dist/table/dom.d.ts.map +1 -0
- package/dist/table/features/column-sizing.d.ts +168 -0
- package/dist/table/features/column-sizing.d.ts.map +1 -0
- package/dist/table/features/expanding.d.ts +138 -0
- package/dist/table/features/expanding.d.ts.map +1 -0
- package/dist/table/features/filters.d.ts +309 -0
- package/dist/table/features/filters.d.ts.map +1 -0
- package/dist/table/features/grouping.d.ts +182 -0
- package/dist/table/features/grouping.d.ts.map +1 -0
- package/dist/table/features/ordering.d.ts +33 -0
- package/dist/table/features/ordering.d.ts.map +1 -0
- package/dist/table/features/pagination.d.ts +127 -0
- package/dist/table/features/pagination.d.ts.map +1 -0
- package/dist/table/features/pinning.d.ts +227 -0
- package/dist/table/features/pinning.d.ts.map +1 -0
- package/dist/table/features/row-selection.d.ts +148 -0
- package/dist/table/features/row-selection.d.ts.map +1 -0
- package/dist/table/features/sorting.d.ts +194 -0
- package/dist/table/features/sorting.d.ts.map +1 -0
- package/dist/table/features/visibility.d.ts +119 -0
- package/dist/table/features/visibility.d.ts.map +1 -0
- package/dist/table/filter-fns.d.ts +4 -0
- package/dist/table/filter-fns.d.ts.map +1 -0
- package/dist/table/index.cjs +5 -0
- package/dist/table/index.cjs.map +7 -0
- package/dist/table/index.d.ts +32 -0
- package/dist/table/index.d.ts.map +1 -0
- package/dist/table/index.js +5 -0
- package/dist/table/index.js.map +7 -0
- package/dist/table/sorting-fns.d.ts +5 -0
- package/dist/table/sorting-fns.d.ts.map +1 -0
- package/dist/table/types.d.ts +142 -0
- package/dist/table/types.d.ts.map +1 -0
- package/dist/table/utils/filter-rows-utils.d.ts +5 -0
- package/dist/table/utils/filter-rows-utils.d.ts.map +1 -0
- package/dist/table/utils/get-core-row-model.d.ts +3 -0
- package/dist/table/utils/get-core-row-model.d.ts.map +1 -0
- package/dist/table/utils/get-expanded-row-model.d.ts +8 -0
- package/dist/table/utils/get-expanded-row-model.d.ts.map +1 -0
- package/dist/table/utils/get-faceted-min-max-values.d.ts +3 -0
- package/dist/table/utils/get-faceted-min-max-values.d.ts.map +1 -0
- package/dist/table/utils/get-faceted-row-model.d.ts +3 -0
- package/dist/table/utils/get-faceted-row-model.d.ts.map +1 -0
- package/dist/table/utils/get-faceted-unique-values.d.ts +3 -0
- package/dist/table/utils/get-faceted-unique-values.d.ts.map +1 -0
- package/dist/table/utils/get-filtered-row-model.d.ts +3 -0
- package/dist/table/utils/get-filtered-row-model.d.ts.map +1 -0
- package/dist/table/utils/get-grouped-row-model.d.ts +3 -0
- package/dist/table/utils/get-grouped-row-model.d.ts.map +1 -0
- package/dist/table/utils/get-pagination-row-model.d.ts +3 -0
- package/dist/table/utils/get-pagination-row-model.d.ts.map +1 -0
- package/dist/table/utils/get-sorted-row-model.d.ts +3 -0
- package/dist/table/utils/get-sorted-row-model.d.ts.map +1 -0
- package/dist/table/utils.d.ts +39 -0
- package/dist/table/utils.d.ts.map +1 -0
- package/dist/tabs/index.cjs +2 -0
- package/dist/tabs/index.cjs.map +7 -0
- package/dist/tabs/index.d.ts +5 -0
- package/dist/tabs/index.d.ts.map +1 -0
- package/dist/tabs/index.js +2 -0
- package/dist/tabs/index.js.map +7 -0
- package/dist/tabs/internal/index.d.ts +2 -0
- package/dist/tabs/internal/index.d.ts.map +1 -0
- package/dist/tabs/internal/tabs.dom.d.ts +42 -0
- package/dist/tabs/internal/tabs.dom.d.ts.map +1 -0
- package/dist/tabs/tabs.api.d.ts +4 -0
- package/dist/tabs/tabs.api.d.ts.map +1 -0
- package/dist/tabs/tabs.machine.d.ts +4 -0
- package/dist/tabs/tabs.machine.d.ts.map +1 -0
- package/dist/tabs/tabs.props.d.ts +4 -0
- package/dist/tabs/tabs.props.d.ts.map +1 -0
- package/dist/tabs/tabs.types.d.ts +256 -0
- package/dist/tabs/tabs.types.d.ts.map +1 -0
- package/dist/text-area/index.cjs +2 -0
- package/dist/text-area/index.cjs.map +7 -0
- package/dist/text-area/index.d.ts +2 -0
- package/dist/text-area/index.d.ts.map +1 -0
- package/dist/text-area/index.js +1 -0
- package/dist/text-area/index.js.map +7 -0
- package/dist/text-input/index.cjs +2 -0
- package/dist/text-input/index.cjs.map +7 -0
- package/dist/text-input/index.d.ts +5 -0
- package/dist/text-input/index.d.ts.map +1 -0
- package/dist/text-input/index.js +2 -0
- package/dist/text-input/index.js.map +7 -0
- package/dist/text-input/internal/index.d.ts +2 -0
- package/dist/text-input/internal/index.d.ts.map +1 -0
- package/dist/text-input/internal/text-input.dom.d.ts +7 -0
- package/dist/text-input/internal/text-input.dom.d.ts.map +1 -0
- package/dist/text-input/text-input.api.d.ts +4 -0
- package/dist/text-input/text-input.api.d.ts.map +1 -0
- package/dist/text-input/text-input.machine.d.ts +4 -0
- package/dist/text-input/text-input.machine.d.ts.map +1 -0
- package/dist/text-input/text-input.props.d.ts +3 -0
- package/dist/text-input/text-input.props.d.ts.map +1 -0
- package/dist/text-input/text-input.types.d.ts +118 -0
- package/dist/text-input/text-input.types.d.ts.map +1 -0
- package/dist/toast/index.cjs +2 -0
- package/dist/toast/index.cjs.map +7 -0
- package/dist/toast/index.d.ts +8 -0
- package/dist/toast/index.d.ts.map +1 -0
- package/dist/toast/index.js +2 -0
- package/dist/toast/index.js.map +7 -0
- package/dist/toast/internal/index.d.ts +2 -0
- package/dist/toast/internal/index.d.ts.map +1 -0
- package/dist/toast/internal/toast.dom.d.ts +10 -0
- package/dist/toast/internal/toast.dom.d.ts.map +1 -0
- package/dist/toast/toast-group.api.d.ts +4 -0
- package/dist/toast/toast-group.api.d.ts.map +1 -0
- package/dist/toast/toast-group.machine.d.ts +4 -0
- package/dist/toast/toast-group.machine.d.ts.map +1 -0
- package/dist/toast/toast.api.d.ts +4 -0
- package/dist/toast/toast.api.d.ts.map +1 -0
- package/dist/toast/toast.machine.d.ts +4 -0
- package/dist/toast/toast.machine.d.ts.map +1 -0
- package/dist/toast/toast.store.d.ts +4 -0
- package/dist/toast/toast.store.d.ts.map +1 -0
- package/dist/toast/toast.types.d.ts +463 -0
- package/dist/toast/toast.types.d.ts.map +1 -0
- package/dist/toast/toast.utils.d.ts +9 -0
- package/dist/toast/toast.utils.d.ts.map +1 -0
- package/dist/tooltip/index.cjs +2 -0
- package/dist/tooltip/index.cjs.map +7 -0
- package/dist/tooltip/index.d.ts +5 -0
- package/dist/tooltip/index.d.ts.map +1 -0
- package/dist/tooltip/index.js +2 -0
- package/dist/tooltip/index.js.map +7 -0
- package/dist/tooltip/tooltip.api.d.ts +4 -0
- package/dist/tooltip/tooltip.api.d.ts.map +1 -0
- package/dist/tooltip/tooltip.machine.d.ts +4 -0
- package/dist/tooltip/tooltip.machine.d.ts.map +1 -0
- package/dist/tooltip/tooltip.props.d.ts +4 -0
- package/dist/tooltip/tooltip.props.d.ts.map +1 -0
- package/dist/tooltip/tooltip.store.d.ts +5 -0
- package/dist/tooltip/tooltip.store.d.ts.map +1 -0
- package/dist/tooltip/tooltip.types.d.ts +122 -0
- package/dist/tooltip/tooltip.types.d.ts.map +1 -0
- package/dist/tree/index.cjs +2 -0
- package/dist/tree/index.cjs.map +7 -0
- package/dist/tree/index.d.ts +6 -0
- package/dist/tree/index.d.ts.map +1 -0
- package/dist/tree/index.js +2 -0
- package/dist/tree/index.js.map +7 -0
- package/dist/tree/internal/index.d.ts +3 -0
- package/dist/tree/internal/index.d.ts.map +1 -0
- package/dist/tree/internal/tree.dom.d.ts +8 -0
- package/dist/tree/internal/tree.dom.d.ts.map +1 -0
- package/dist/tree/internal/tree.utils.d.ts +12 -0
- package/dist/tree/internal/tree.utils.d.ts.map +1 -0
- package/dist/tree/tree.api.d.ts +5 -0
- package/dist/tree/tree.api.d.ts.map +1 -0
- package/dist/tree/tree.collection.d.ts +4 -0
- package/dist/tree/tree.collection.d.ts.map +1 -0
- package/dist/tree/tree.machine.d.ts +4 -0
- package/dist/tree/tree.machine.d.ts.map +1 -0
- package/dist/tree/tree.props.d.ts +7 -0
- package/dist/tree/tree.props.d.ts.map +1 -0
- package/dist/tree/tree.types.d.ts +579 -0
- package/dist/tree/tree.types.d.ts.map +1 -0
- package/dist/tsbuildinfo +1 -0
- package/package.json +29 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dialog/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAA;AAC5B,cAAc,kBAAkB,CAAA;AAChC,cAAc,gBAAgB,CAAA;AAC9B,mBAAmB,gBAAgB,CAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{booleanAriaAttr as u}from"@qualcomm-ui/utils/attributes";var s={backdrop:e=>e.ids.get("backdrop"),closeTrigger:e=>e.ids.get("closeTrigger"),content:e=>e.ids.get("content"),description:e=>e.ids.get("description"),label:e=>e.ids.get("label"),positioner:e=>e.ids.get("positioner"),trigger:e=>e.ids.get("trigger")},a={backdrop:e=>e.getById(s.backdrop(e)),closeTrigger:e=>e.getById(s.closeTrigger(e)),content:e=>e.getById(s.content(e)),description:e=>e.getById(s.description(e)),label:e=>e.getById(s.label(e)),positioner:e=>e.getById(s.positioner(e)),trigger:e=>e.getById(s.trigger(e))};var l={"data-scope":"dialog"};function b(e,t){let{prop:o,scope:n,send:r,state:g}=e,p=o("aria-label"),c=g.matches("open");return{open:c,setOpen(i){g.matches("open")!==i&&r({type:i?"OPEN":"CLOSE"})},getBackdropBindings(i){return n.ids.register("backdrop",i),t.element({...l,"data-part":"backdrop","data-state":g.get(),dir:o("dir"),hidden:!c,id:i.id})},getBodyBindings(){return t.element({...l,"data-part":"body"})},getCloseTriggerBindings(i){return n.ids.register("closeTrigger",i),t.button({...l,"data-part":"close-trigger",dir:o("dir"),id:i.id,onClick(d){d.defaultPrevented||r({type:"CLOSE"})},type:"button"})},getContentBindings(i){n.ids.register("content",i);let d=s.label(n);return t.element({...l,"aria-describedby":s.description(n)||void 0,"aria-label":p||void 0,"aria-labelledby":p||!d?void 0:d,"aria-modal":o("modal"),"data-part":"content","data-state":g.get(),dir:o("dir"),hidden:!c,id:i.id,role:o("role"),tabIndex:-1})},getDescriptionBindings(i){return n.ids.register("description",i),t.element({...l,"data-part":"description",dir:o("dir"),id:i.id})},getFooterBindings(){return t.element({...l,"data-part":"footer",dir:o("dir")})},getHeadingBindings(i){return n.ids.register("label",i),t.element({...l,"data-part":"heading",dir:o("dir"),id:i.id})},getPositionerBindings(i){return n.ids.register("positioner",i),t.element({...l,"data-part":"positioner",dir:o("dir"),id:i.id,style:{pointerEvents:c?void 0:"none"}})},getTriggerBindings(i){return n.ids.register("trigger",i),t.button({...l,"aria-controls":s.content(n),"aria-expanded":u(c),"aria-haspopup":"dialog","data-part":"trigger","data-state":g.get(),dir:o("dir"),id:i.id,onClick(d){d.defaultPrevented||r({type:"TOGGLE"})},type:"button"})}}}import{ariaHidden as m}from"@qualcomm-ui/dom/aria-hidden";import{trackDismissableElement as D}from"@qualcomm-ui/dom/dismissable";import{trapFocus as O}from"@qualcomm-ui/dom/focus-trap";import{raf as f}from"@qualcomm-ui/dom/query";import{preventBodyScroll as E}from"@qualcomm-ui/dom/remove-scroll";import{isDefined as y}from"@qualcomm-ui/utils/guard";import{createMachine as B}from"@qualcomm-ui/utils/machine";var G=B({actions:{invokeOnClose:({prop:e})=>{e("onOpenChange")?.(!1)},invokeOnOpen:({prop:e})=>{e("onOpenChange")?.(!0)},syncZIndex:({scope:e})=>{f(()=>{let t=a.content(e);if(!t)return;let o=getComputedStyle(t);[a.positioner(e),a.backdrop(e)].forEach(r=>{r?.style.setProperty("--z-index",o.zIndex)})})},toggleVisibility:({prop:e,send:t})=>{t({type:e("open")?"CONTROLLED.OPEN":"CONTROLLED.CLOSE"})}},effects:{hideContentBelow({prop:e,scope:t}){return e("modal")?m(()=>[a.content(t)],{defer:!0}):void 0},preventScroll({prop:e,scope:t}){if(e("preventScroll"))return E(t.getDoc())},trackDismissableElement({prop:e,scope:t,send:o}){return D(()=>a.content(t),{defer:!0,exclude:()=>[a.trigger(t)],onDismiss(){o({src:"interact-outside",type:"CLOSE"})},onEscapeKeyDown(r){e("onEscapeKeyDown")?.(r),e("closeOnEscape")||r.preventDefault()},onFocusOutside:e("onFocusOutside"),onInteractOutside(r){e("onInteractOutside")?.(r),e("closeOnInteractOutside")||r.preventDefault()},onPointerDownOutside:e("onPointerDownOutside"),onRequestDismiss:e("onRequestDismiss"),persistentElements:e("persistentElements"),pointerBlocking:e("modal")})},trapFocus:({prop:e,scope:t})=>!e("trapFocus")||!e("modal")?void 0:O(()=>a.content(t),{initialFocus:e("initialFocusEl"),preventScroll:!0,returnFocusOnDeactivate:e("restoreFocus"),setReturnFocus:n=>e("finalFocusEl")?.()??n})},guards:{isOpenControlled:({prop:e})=>y(e("open"))},ids:({bindableId:e})=>({backdrop:e(),closeTrigger:e(),content:e(),description:e(),label:e(),positioner:e(),trigger:e()}),initialState({prop:e}){return e("open")||e("defaultOpen")?"open":"closed"},props:({props:e,scope:t})=>{let o=e.role==="alertdialog";return{closeOnEscape:!0,closeOnInteractOutside:!o,dir:"ltr",initialFocusEl:o?()=>a.closeTrigger(t):void 0,modal:!0,preventScroll:!0,restoreFocus:!0,role:"dialog",trapFocus:!0,...e}},states:{closed:{on:{"CONTROLLED.OPEN":{target:"open"},OPEN:[{actions:["invokeOnOpen"],guard:"isOpenControlled"},{actions:["invokeOnOpen"],target:"open"}],TOGGLE:[{actions:["invokeOnOpen"],guard:"isOpenControlled"},{actions:["invokeOnOpen"],target:"open"}]}},open:{effects:["trackDismissableElement","trapFocus","preventScroll","hideContentBelow"],entry:["syncZIndex"],on:{CLOSE:[{actions:["invokeOnClose"],guard:"isOpenControlled"},{actions:["invokeOnClose"],target:"closed"}],"CONTROLLED.CLOSE":{target:"closed"},TOGGLE:[{actions:["invokeOnClose"],guard:"isOpenControlled"},{actions:["invokeOnClose"],target:"closed"}]}}},watch({actions:e,prop:t,track:o}){o([()=>t("open")],()=>{e.toggleVisibility()})}});import{createProps as C,createSplitProps as P}from"@qualcomm-ui/utils/object";var k=C()("aria-label","closeOnEscape","closeOnInteractOutside","defaultOpen","dir","finalFocusEl","getRootNode","initialFocusEl","modal","onEscapeKeyDown","onFocusOutside","onInteractOutside","onOpenChange","onPointerDownOutside","onRequestDismiss","open","persistentElements","preventScroll","restoreFocus","role","trapFocus"),H=P(k);export{b as createDialogApi,G as dialogMachine,k as dialogProps,H as splitDialogProps};
|
|
2
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/dialog/dialog.api.ts", "../../src/dialog/internal/dialog.dom.ts", "../../src/dialog/dialog.machine.ts", "../../src/dialog/dialog.props.ts"],
|
|
4
|
+
"sourcesContent": ["// Modified from https://github.com/chakra-ui/zag\n// MIT License\n// Changes from Qualcomm Technologies, Inc. are provided under the following license:\n// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {booleanAriaAttr} from \"@qualcomm-ui/utils/attributes\"\nimport type {Machine, PropNormalizer} from \"@qualcomm-ui/utils/machine\"\n\nimport type {\n DialogApi,\n DialogBackdropBindings,\n DialogBodyBindings,\n DialogCloseTriggerBindings,\n DialogContentBindings,\n DialogDescriptionBindings,\n DialogFooterBindings,\n DialogHeadingBindings,\n DialogPositionerBindings,\n DialogSchema,\n DialogTriggerBindings,\n} from \"./dialog.types\"\nimport {domIds} from \"./internal\"\n\nconst commonBindings: {\"data-scope\": \"dialog\"} = {\n \"data-scope\": \"dialog\",\n}\n\nexport function createDialogApi(\n machine: Machine<DialogSchema>,\n normalize: PropNormalizer,\n): DialogApi {\n const {prop, scope, send, state} = machine\n\n const ariaLabel = prop(\"aria-label\")\n const open = state.matches(\"open\")\n\n return {\n open,\n setOpen(nextOpen) {\n const open = state.matches(\"open\")\n if (open === nextOpen) {\n return\n }\n send({type: nextOpen ? \"OPEN\" : \"CLOSE\"})\n },\n\n // group: bindings\n getBackdropBindings(props): DialogBackdropBindings {\n scope.ids.register(\"backdrop\", props)\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"backdrop\",\n \"data-state\": state.get(),\n dir: prop(\"dir\"),\n hidden: !open,\n id: props.id,\n })\n },\n getBodyBindings(): DialogBodyBindings {\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"body\",\n })\n },\n getCloseTriggerBindings(props): DialogCloseTriggerBindings {\n scope.ids.register(\"closeTrigger\", props)\n return normalize.button({\n ...commonBindings,\n \"data-part\": \"close-trigger\",\n dir: prop(\"dir\"),\n id: props.id,\n onClick(event) {\n if (event.defaultPrevented) {\n return\n }\n send({type: \"CLOSE\"})\n },\n type: \"button\",\n })\n },\n getContentBindings(props): DialogContentBindings {\n scope.ids.register(\"content\", props)\n const labelId = domIds.label(scope)\n return normalize.element({\n ...commonBindings,\n \"aria-describedby\": domIds.description(scope) || undefined,\n \"aria-label\": ariaLabel || undefined,\n \"aria-labelledby\": ariaLabel || !labelId ? undefined : labelId,\n \"aria-modal\": prop(\"modal\"),\n \"data-part\": \"content\",\n \"data-state\": state.get(),\n dir: prop(\"dir\"),\n hidden: !open,\n id: props.id,\n role: prop(\"role\"),\n tabIndex: -1,\n })\n },\n getDescriptionBindings(props): DialogDescriptionBindings {\n scope.ids.register(\"description\", props)\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"description\",\n dir: prop(\"dir\"),\n id: props.id,\n })\n },\n getFooterBindings(): DialogFooterBindings {\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"footer\",\n dir: prop(\"dir\"),\n })\n },\n getHeadingBindings(props): DialogHeadingBindings {\n scope.ids.register(\"label\", props)\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"heading\",\n dir: prop(\"dir\"),\n id: props.id,\n })\n },\n getPositionerBindings(props): DialogPositionerBindings {\n scope.ids.register(\"positioner\", props)\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"positioner\",\n dir: prop(\"dir\"),\n id: props.id,\n style: {\n pointerEvents: open ? undefined : \"none\",\n },\n })\n },\n getTriggerBindings(props): DialogTriggerBindings {\n scope.ids.register(\"trigger\", props)\n return normalize.button({\n ...commonBindings,\n \"aria-controls\": domIds.content(scope),\n \"aria-expanded\": booleanAriaAttr(open),\n \"aria-haspopup\": \"dialog\",\n \"data-part\": \"trigger\",\n \"data-state\": state.get(),\n dir: prop(\"dir\"),\n id: props.id,\n onClick(event) {\n if (event.defaultPrevented) {\n return\n }\n send({type: \"TOGGLE\"})\n },\n type: \"button\",\n })\n },\n }\n}\n", "// Modified from https://github.com/chakra-ui/zag\n// MIT License\n// Changes from Qualcomm Technologies, Inc. are provided under the following license:\n// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport type {ScopeDomElements, ScopeDomIds} from \"@qualcomm-ui/utils/machine\"\n\nimport type {DialogElementIds, DialogScope} from \"../dialog.types\"\n\nexport const domIds: ScopeDomIds<DialogElementIds, DialogScope> = {\n backdrop: (scope) => scope.ids.get(\"backdrop\"),\n closeTrigger: (scope) => scope.ids.get(\"closeTrigger\"),\n content: (scope) => scope.ids.get(\"content\"),\n description: (scope) => scope.ids.get(\"description\"),\n label: (scope) => scope.ids.get(\"label\"),\n positioner: (scope) => scope.ids.get(\"positioner\"),\n trigger: (scope) => scope.ids.get(\"trigger\"),\n}\n\nexport const domEls: ScopeDomElements<DialogElementIds, DialogScope> = {\n backdrop: (scope) => scope.getById(domIds.backdrop(scope)),\n closeTrigger: (scope) => scope.getById(domIds.closeTrigger(scope)),\n content: (scope) => scope.getById(domIds.content(scope)),\n description: (scope) => scope.getById(domIds.description(scope)),\n label: (scope) => scope.getById(domIds.label(scope)),\n positioner: (scope) => scope.getById(domIds.positioner(scope)),\n trigger: (scope) => scope.getById(domIds.trigger(scope)),\n}\n", "// Modified from https://github.com/chakra-ui/zag\n// MIT License\n// Changes from Qualcomm Technologies, Inc. are provided under the following license:\n// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {ariaHidden} from \"@qualcomm-ui/dom/aria-hidden\"\nimport {trackDismissableElement} from \"@qualcomm-ui/dom/dismissable\"\nimport {trapFocus} from \"@qualcomm-ui/dom/focus-trap\"\nimport {raf} from \"@qualcomm-ui/dom/query\"\nimport {preventBodyScroll} from \"@qualcomm-ui/dom/remove-scroll\"\nimport {isDefined} from \"@qualcomm-ui/utils/guard\"\nimport {createMachine, type MachineConfig} from \"@qualcomm-ui/utils/machine\"\n\nimport type {DialogApiProps, DialogSchema} from \"./dialog.types\"\nimport {domEls} from \"./internal\"\n\nexport const dialogMachine: MachineConfig<DialogSchema> =\n createMachine<DialogSchema>({\n actions: {\n invokeOnClose: ({prop}) => {\n prop(\"onOpenChange\")?.(false)\n },\n invokeOnOpen: ({prop}) => {\n prop(\"onOpenChange\")?.(true)\n },\n syncZIndex: ({scope}) => {\n raf(() => {\n const contentEl = domEls.content(scope)\n if (!contentEl) {\n return\n }\n\n const styles = getComputedStyle(contentEl)\n const elems = [domEls.positioner(scope), domEls.backdrop(scope)]\n elems.forEach((node) => {\n node?.style.setProperty(\"--z-index\", styles.zIndex)\n })\n })\n },\n toggleVisibility: ({prop, send}) => {\n send({type: prop(\"open\") ? \"CONTROLLED.OPEN\" : \"CONTROLLED.CLOSE\"})\n },\n },\n\n effects: {\n hideContentBelow({prop, scope}) {\n if (!prop(\"modal\")) {\n return\n }\n const getElements = () => [domEls.content(scope)]\n return ariaHidden(getElements, {defer: true})\n },\n\n preventScroll({prop, scope}) {\n if (!prop(\"preventScroll\")) {\n return\n }\n return preventBodyScroll(scope.getDoc())\n },\n\n trackDismissableElement({prop, scope, send}) {\n const getContentEl = () => domEls.content(scope)\n return trackDismissableElement(getContentEl, {\n defer: true,\n exclude: () => [domEls.trigger(scope)],\n onDismiss() {\n send({src: \"interact-outside\", type: \"CLOSE\"})\n },\n onEscapeKeyDown(event) {\n prop(\"onEscapeKeyDown\")?.(event)\n if (!prop(\"closeOnEscape\")) {\n event.preventDefault()\n }\n },\n onFocusOutside: prop(\"onFocusOutside\"),\n onInteractOutside(event) {\n prop(\"onInteractOutside\")?.(event)\n if (!prop(\"closeOnInteractOutside\")) {\n event.preventDefault()\n }\n },\n onPointerDownOutside: prop(\"onPointerDownOutside\"),\n onRequestDismiss: prop(\"onRequestDismiss\"),\n persistentElements: prop(\"persistentElements\"),\n pointerBlocking: prop(\"modal\"),\n })\n },\n\n trapFocus: ({prop, scope}) => {\n if (!prop(\"trapFocus\") || !prop(\"modal\")) {\n return\n }\n const contentEl = () => domEls.content(scope)\n return trapFocus(contentEl, {\n initialFocus: prop(\"initialFocusEl\"),\n preventScroll: true,\n returnFocusOnDeactivate: prop(\"restoreFocus\"),\n setReturnFocus: (el) => prop(\"finalFocusEl\")?.() ?? el,\n })\n },\n },\n\n guards: {\n isOpenControlled: ({prop}) => isDefined(prop(\"open\")),\n },\n\n ids: ({bindableId}) => ({\n backdrop: bindableId<string>(),\n closeTrigger: bindableId<string>(),\n content: bindableId<string>(),\n description: bindableId<string>(),\n label: bindableId<string>(),\n positioner: bindableId<string>(),\n trigger: bindableId<string>(),\n }),\n\n initialState({prop}) {\n const open = prop(\"open\") || prop(\"defaultOpen\")\n return open ? \"open\" : \"closed\"\n },\n\n props: ({props, scope}) => {\n const alertDialog = props.role === \"alertdialog\"\n const initialFocusEl: DialogApiProps[\"initialFocusEl\"] = alertDialog\n ? () => domEls.closeTrigger(scope)\n : undefined\n return {\n closeOnEscape: true,\n closeOnInteractOutside: !alertDialog,\n dir: \"ltr\",\n initialFocusEl: initialFocusEl!,\n modal: true,\n preventScroll: true,\n restoreFocus: true,\n role: \"dialog\",\n trapFocus: true,\n ...props,\n }\n },\n\n states: {\n closed: {\n on: {\n \"CONTROLLED.OPEN\": {\n target: \"open\",\n },\n OPEN: [\n {\n actions: [\"invokeOnOpen\"],\n guard: \"isOpenControlled\",\n },\n {\n actions: [\"invokeOnOpen\"],\n target: \"open\",\n },\n ],\n TOGGLE: [\n {\n actions: [\"invokeOnOpen\"],\n guard: \"isOpenControlled\",\n },\n {\n actions: [\"invokeOnOpen\"],\n target: \"open\",\n },\n ],\n },\n },\n open: {\n effects: [\n \"trackDismissableElement\",\n \"trapFocus\",\n \"preventScroll\",\n \"hideContentBelow\",\n ],\n entry: [\"syncZIndex\"],\n on: {\n CLOSE: [\n {\n actions: [\"invokeOnClose\"],\n guard: \"isOpenControlled\",\n },\n {\n actions: [\"invokeOnClose\"],\n target: \"closed\",\n },\n ],\n \"CONTROLLED.CLOSE\": {\n target: \"closed\",\n },\n TOGGLE: [\n {\n actions: [\"invokeOnClose\"],\n guard: \"isOpenControlled\",\n },\n {\n actions: [\"invokeOnClose\"],\n target: \"closed\",\n },\n ],\n },\n },\n },\n\n watch({actions, prop, track}) {\n track([() => prop(\"open\")], () => {\n actions.toggleVisibility()\n })\n },\n })\n", "// Modified from https://github.com/chakra-ui/zag\n// MIT License\n// Changes from Qualcomm Technologies, Inc. are provided under the following license:\n// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {createProps, createSplitProps} from \"@qualcomm-ui/utils/object\"\n\nimport type {DialogApiProps} from \"./dialog.types\"\n\nexport const dialogProps: (keyof DialogApiProps)[] =\n createProps<DialogApiProps>()(\n \"aria-label\",\n \"closeOnEscape\",\n \"closeOnInteractOutside\",\n \"defaultOpen\",\n \"dir\",\n \"finalFocusEl\",\n \"getRootNode\",\n \"initialFocusEl\",\n \"modal\",\n \"onEscapeKeyDown\",\n \"onFocusOutside\",\n \"onInteractOutside\",\n \"onOpenChange\",\n \"onPointerDownOutside\",\n \"onRequestDismiss\",\n \"open\",\n \"persistentElements\",\n \"preventScroll\",\n \"restoreFocus\",\n \"role\",\n \"trapFocus\",\n )\n\nexport const splitDialogProps: <Props extends DialogApiProps>(\n props: Props,\n) => [DialogApiProps, Omit<Props, keyof DialogApiProps>] =\n createSplitProps<DialogApiProps>(dialogProps)\n"],
|
|
5
|
+
"mappings": "AAMA,OAAQ,mBAAAA,MAAsB,gCCIvB,IAAMC,EAAqD,CAChE,SAAWC,GAAUA,EAAM,IAAI,IAAI,UAAU,EAC7C,aAAeA,GAAUA,EAAM,IAAI,IAAI,cAAc,EACrD,QAAUA,GAAUA,EAAM,IAAI,IAAI,SAAS,EAC3C,YAAcA,GAAUA,EAAM,IAAI,IAAI,aAAa,EACnD,MAAQA,GAAUA,EAAM,IAAI,IAAI,OAAO,EACvC,WAAaA,GAAUA,EAAM,IAAI,IAAI,YAAY,EACjD,QAAUA,GAAUA,EAAM,IAAI,IAAI,SAAS,CAC7C,EAEaC,EAA0D,CACrE,SAAWD,GAAUA,EAAM,QAAQD,EAAO,SAASC,CAAK,CAAC,EACzD,aAAeA,GAAUA,EAAM,QAAQD,EAAO,aAAaC,CAAK,CAAC,EACjE,QAAUA,GAAUA,EAAM,QAAQD,EAAO,QAAQC,CAAK,CAAC,EACvD,YAAcA,GAAUA,EAAM,QAAQD,EAAO,YAAYC,CAAK,CAAC,EAC/D,MAAQA,GAAUA,EAAM,QAAQD,EAAO,MAAMC,CAAK,CAAC,EACnD,WAAaA,GAAUA,EAAM,QAAQD,EAAO,WAAWC,CAAK,CAAC,EAC7D,Q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W",
|
|
6
|
+
"names": ["booleanAriaAttr", "domIds", "scope", "domEls", "commonBindings", "createDialogApi", "machine", "normalize", "prop", "scope", "send", "state", "ariaLabel", "open", "nextOpen", "props", "event", "labelId", "domIds", "booleanAriaAttr", "ariaHidden", "trackDismissableElement", "trapFocus", "raf", "preventBodyScroll", "isDefined", "createMachine", "dialogMachine", "createMachine", "prop", "scope", "raf", "contentEl", "domEls", "styles", "node", "send", "ariaHidden", "preventBodyScroll", "trackDismissableElement", "event", "trapFocus", "el", "isDefined", "bindableId", "props", "alertDialog", "actions", "track", "createProps", "createSplitProps", "dialogProps", "splitDialogProps"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { ScopeDomElements, ScopeDomIds } from "@qualcomm-ui/utils/machine";
|
|
2
|
+
import type { DialogElementIds, DialogScope } from "../dialog.types";
|
|
3
|
+
export declare const domIds: ScopeDomIds<DialogElementIds, DialogScope>;
|
|
4
|
+
export declare const domEls: ScopeDomElements<DialogElementIds, DialogScope>;
|
|
5
|
+
//# sourceMappingURL=dialog.dom.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dialog.dom.d.ts","sourceRoot":"","sources":["../../../src/dialog/internal/dialog.dom.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAC,gBAAgB,EAAE,WAAW,EAAC,MAAM,4BAA4B,CAAA;AAE7E,OAAO,KAAK,EAAC,gBAAgB,EAAE,WAAW,EAAC,MAAM,iBAAiB,CAAA;AAElE,eAAO,MAAM,MAAM,EAAE,WAAW,CAAC,gBAAgB,EAAE,WAAW,CAQ7D,CAAA;AAED,eAAO,MAAM,MAAM,EAAE,gBAAgB,CAAC,gBAAgB,EAAE,WAAW,CAQlE,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/dialog/internal/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAA"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export type DragState = {
|
|
2
|
+
type: "idle";
|
|
3
|
+
} | {
|
|
4
|
+
type: "is-dragging";
|
|
5
|
+
} | {
|
|
6
|
+
container: HTMLElement;
|
|
7
|
+
type: "preview";
|
|
8
|
+
} | {
|
|
9
|
+
closestEdge: any;
|
|
10
|
+
sourceIndex?: number;
|
|
11
|
+
type: "is-dragging-over";
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=dnd.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dnd.types.d.ts","sourceRoot":"","sources":["../../src/dnd/dnd.types.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,SAAS,GACjB;IACE,IAAI,EAAE,MAAM,CAAA;CACb,GACD;IACE,IAAI,EAAE,aAAa,CAAA;CACpB,GACD;IAAC,SAAS,EAAE,WAAW,CAAC;IAAC,IAAI,EAAE,SAAS,CAAA;CAAC,GACzC;IACE,WAAW,EAAE,GAAG,CAAA;IAChB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,IAAI,EAAE,kBAAkB,CAAA;CACzB,CAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var o=Object.defineProperty;var y=Object.getOwnPropertyDescriptor;var f=Object.getOwnPropertyNames;var m=Object.prototype.hasOwnProperty;var n=(p,e,r,d)=>{if(e&&typeof e=="object"||typeof e=="function")for(let t of f(e))!m.call(p,t)&&t!==r&&o(p,t,{get:()=>e[t],enumerable:!(d=y(e,t))||d.enumerable});return p};var s=p=>n(o({},"__esModule",{value:!0}),p);var x={};module.exports=s(x);
|
|
2
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/dnd/index.ts"],"names":[],"mappings":"AAAA,mBAAmB,aAAa,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import type { BooleanAriaAttr, BooleanDataAttr } from "@qualcomm-ui/utils/attributes";
|
|
2
|
+
import type { DirectionProperty } from "@qualcomm-ui/utils/direction";
|
|
3
|
+
import type { IdRegistrationProps } from "@qualcomm-ui/utils/machine";
|
|
4
|
+
/**
|
|
5
|
+
* The field is primarily used to wire up accessibility for its elements.
|
|
6
|
+
*/
|
|
7
|
+
export interface FieldApiProps extends DirectionProperty {
|
|
8
|
+
/**
|
|
9
|
+
* Whether the input is disabled. When true, prevents user interaction and
|
|
10
|
+
* applies visual styling to indicate the disabled state.
|
|
11
|
+
*/
|
|
12
|
+
disabled?: boolean | undefined;
|
|
13
|
+
/**
|
|
14
|
+
* Controls the visual error state of the input. When true, applies semantic error
|
|
15
|
+
* styling to indicate validation failure.
|
|
16
|
+
*/
|
|
17
|
+
invalid?: boolean | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* Whether the input is read-only. When true, prevents user interaction while
|
|
20
|
+
* keeping the input focusable and visible.
|
|
21
|
+
*/
|
|
22
|
+
readOnly?: boolean | undefined;
|
|
23
|
+
/**
|
|
24
|
+
* Whether the input is required. When true, the input must have a value for form
|
|
25
|
+
* validation to pass.
|
|
26
|
+
*/
|
|
27
|
+
required?: boolean | undefined;
|
|
28
|
+
}
|
|
29
|
+
interface CommonBindings extends Required<DirectionProperty> {
|
|
30
|
+
"data-scope": "field";
|
|
31
|
+
}
|
|
32
|
+
export interface FieldRootBindings extends CommonBindings {
|
|
33
|
+
"data-disabled": BooleanDataAttr;
|
|
34
|
+
"data-invalid": BooleanDataAttr;
|
|
35
|
+
"data-part": "root";
|
|
36
|
+
"data-readonly": BooleanDataAttr;
|
|
37
|
+
role: "group";
|
|
38
|
+
}
|
|
39
|
+
export interface FieldLabelBindings extends CommonBindings {
|
|
40
|
+
"data-disabled": BooleanDataAttr;
|
|
41
|
+
"data-invalid": BooleanDataAttr;
|
|
42
|
+
"data-part": "label";
|
|
43
|
+
"data-required": BooleanDataAttr;
|
|
44
|
+
htmlFor: string;
|
|
45
|
+
id: string;
|
|
46
|
+
}
|
|
47
|
+
export interface FieldHintBindings extends CommonBindings {
|
|
48
|
+
"data-disabled": BooleanDataAttr;
|
|
49
|
+
"data-part": "hint";
|
|
50
|
+
id: string;
|
|
51
|
+
}
|
|
52
|
+
export interface FieldControlBindings extends CommonBindings {
|
|
53
|
+
"aria-describedby": string | undefined;
|
|
54
|
+
"aria-invalid": BooleanAriaAttr;
|
|
55
|
+
"data-disabled": BooleanDataAttr;
|
|
56
|
+
"data-invalid": BooleanDataAttr;
|
|
57
|
+
"data-part": "control";
|
|
58
|
+
"data-required": BooleanDataAttr;
|
|
59
|
+
disabled: boolean;
|
|
60
|
+
id: string;
|
|
61
|
+
readOnly: boolean;
|
|
62
|
+
required: BooleanDataAttr;
|
|
63
|
+
}
|
|
64
|
+
export interface FieldErrorTextBindings extends CommonBindings {
|
|
65
|
+
"aria-live": "polite";
|
|
66
|
+
"data-disabled": BooleanDataAttr;
|
|
67
|
+
"data-part": "error-text";
|
|
68
|
+
id: string;
|
|
69
|
+
}
|
|
70
|
+
export interface FieldRequiredIndicatorBindings extends CommonBindings {
|
|
71
|
+
"aria-hidden": BooleanAriaAttr;
|
|
72
|
+
"data-part": "required-indicator";
|
|
73
|
+
}
|
|
74
|
+
export interface FieldApi {
|
|
75
|
+
getControlBindings(props: IdRegistrationProps): FieldControlBindings;
|
|
76
|
+
getErrorTextBindings(props: IdRegistrationProps): FieldErrorTextBindings;
|
|
77
|
+
getHintBindings(props: IdRegistrationProps): FieldHintBindings;
|
|
78
|
+
getLabelBindings(props: IdRegistrationProps): FieldLabelBindings;
|
|
79
|
+
getRequiredIndicatorBindings(): FieldRequiredIndicatorBindings;
|
|
80
|
+
getRootBindings(): FieldRootBindings;
|
|
81
|
+
disabled: boolean | undefined;
|
|
82
|
+
invalid: boolean | undefined;
|
|
83
|
+
readOnly: boolean | undefined;
|
|
84
|
+
required: boolean | undefined;
|
|
85
|
+
}
|
|
86
|
+
export {};
|
|
87
|
+
//# sourceMappingURL=field.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"field.types.d.ts","sourceRoot":"","sources":["../../src/field/field.types.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,eAAe,EACf,eAAe,EAChB,MAAM,+BAA+B,CAAA;AACtC,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,8BAA8B,CAAA;AACnE,OAAO,KAAK,EAAC,mBAAmB,EAAC,MAAM,4BAA4B,CAAA;AAEnE;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,iBAAiB;IACtD;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAE9B;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAE7B;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAE9B;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;CAC/B;AAED,UAAU,cAAe,SAAQ,QAAQ,CAAC,iBAAiB,CAAC;IAC1D,YAAY,EAAE,OAAO,CAAA;CACtB;AAED,MAAM,WAAW,iBAAkB,SAAQ,cAAc;IACvD,eAAe,EAAE,eAAe,CAAA;IAChC,cAAc,EAAE,eAAe,CAAA;IAC/B,WAAW,EAAE,MAAM,CAAA;IACnB,eAAe,EAAE,eAAe,CAAA;IAChC,IAAI,EAAE,OAAO,CAAA;CACd;AAED,MAAM,WAAW,kBAAmB,SAAQ,cAAc;IACxD,eAAe,EAAE,eAAe,CAAA;IAChC,cAAc,EAAE,eAAe,CAAA;IAC/B,WAAW,EAAE,OAAO,CAAA;IACpB,eAAe,EAAE,eAAe,CAAA;IAChC,OAAO,EAAE,MAAM,CAAA;IACf,EAAE,EAAE,MAAM,CAAA;CACX;AAED,MAAM,WAAW,iBAAkB,SAAQ,cAAc;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,GAAG,SAAS,CAAA;CAC9B"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var o=Object.defineProperty;var y=Object.getOwnPropertyDescriptor;var d=Object.getOwnPropertyNames;var i=Object.prototype.hasOwnProperty;var l=(p,e,r,f)=>{if(e&&typeof e=="object"||typeof e=="function")for(let t of d(e))!i.call(p,t)&&t!==r&&o(p,t,{get:()=>e[t],enumerable:!(f=y(e,t))||f.enumerable});return p};var m=p=>l(o({},"__esModule",{value:!0}),p);var s={};module.exports=m(s);
|
|
2
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/field/index.ts"],"names":[],"mappings":"AAAA,mBAAmB,eAAe,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import type { BooleanDataAttr } from "@qualcomm-ui/utils/attributes";
|
|
2
|
+
export interface FieldsetApiProps {
|
|
3
|
+
/**
|
|
4
|
+
* Indicates whether the fieldset is disabled.
|
|
5
|
+
*/
|
|
6
|
+
disabled?: boolean;
|
|
7
|
+
/**
|
|
8
|
+
* Indicates whether the fieldset is invalid.
|
|
9
|
+
*/
|
|
10
|
+
invalid?: boolean;
|
|
11
|
+
}
|
|
12
|
+
export interface FieldsetElementIds {
|
|
13
|
+
errorText: string | undefined;
|
|
14
|
+
hint: string | undefined;
|
|
15
|
+
}
|
|
16
|
+
interface CommonBindings {
|
|
17
|
+
"data-scope": "fieldset";
|
|
18
|
+
}
|
|
19
|
+
export interface FieldsetRootBindings extends CommonBindings {
|
|
20
|
+
"aria-describedby": string | undefined;
|
|
21
|
+
"data-disabled": BooleanDataAttr;
|
|
22
|
+
"data-invalid": BooleanDataAttr;
|
|
23
|
+
disabled: boolean | undefined;
|
|
24
|
+
}
|
|
25
|
+
export interface FieldsetLegendBindings extends CommonBindings {
|
|
26
|
+
"data-disabled": BooleanDataAttr;
|
|
27
|
+
"data-invalid": BooleanDataAttr;
|
|
28
|
+
"data-part": "legend";
|
|
29
|
+
}
|
|
30
|
+
export interface FieldsetHintBindings extends CommonBindings {
|
|
31
|
+
"data-disabled": BooleanDataAttr;
|
|
32
|
+
"data-part": "hint";
|
|
33
|
+
id: string;
|
|
34
|
+
}
|
|
35
|
+
export interface FieldsetErrorTextBindings extends CommonBindings {
|
|
36
|
+
"aria-live": "polite";
|
|
37
|
+
"data-disabled": BooleanDataAttr;
|
|
38
|
+
"data-part": "error-text";
|
|
39
|
+
}
|
|
40
|
+
export interface FieldsetApi {
|
|
41
|
+
disabled: boolean;
|
|
42
|
+
getErrorTextBindings(): FieldsetErrorTextBindings;
|
|
43
|
+
getHintBindings(): FieldsetHintBindings;
|
|
44
|
+
getLegendBindings(): FieldsetLegendBindings;
|
|
45
|
+
getRootBindings(): FieldsetRootBindings;
|
|
46
|
+
invalid: boolean;
|
|
47
|
+
}
|
|
48
|
+
export {};
|
|
49
|
+
//# sourceMappingURL=fieldset.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fieldset.types.d.ts","sourceRoot":"","sources":["../../src/fieldset/fieldset.types.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAC,eAAe,EAAC,MAAM,+BAA+B,CAAA;AAElE,MAAM,WAAW,gBAAgB;IAC/B;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAElB;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,MAAM,WAAW,kBAAkB;IACjC,SAAS,EAAE,MAAM,GAAG,SAAS,CAAA;IAC7B,IAAI,EAAE,MAAM,GAAG,SAAS,CAAA;CACzB;AAED,UAAU,cAAc;IACtB,YAAY,EAAE,UAAU,CAAA;CACzB;AAED,MAAM,WAAW,oBAAqB,SAAQ,cAAc;IAC1D,kBAAkB,EAAE,MAAM,GAAG,SAAS,CAAA;IACtC,eAAe,EAAE,eAAe,CAAA;IAChC,cAAc,EAAE,eAAe,CAAA;IAC/B,QAAQ,EAAE,OAAO,GAAG,SAAS,CAAA;CAC9B;AAED,MAAM,WAAW,sBAAuB,SAAQ,cAAc;IAC5D,eAAe,EAAE,eAAe,CAAA;IAChC,cAAc,EAAE,eAAe,CAAA;IAC/B,WAAW,EAAE,QAAQ,CAAA;CACtB;AAED,MAAM,WAAW,oBAAqB,SAAQ,cAAc;IAC1D,eAAe,EAAE,eAAe,CAAA;IAChC,WAAW,EAAE,MAAM,CAAA;IACnB,EAAE,EAAE,MAAM,CAAA;CACX;AAED,MAAM,WAAW,yBAA0B,SAAQ,cAAc;IAC/D,WAAW,EAAE,QAAQ,CAAA;IACrB,eAAe,EAAE,eAAe,CAAA;IAChC,WAAW,EAAE,YAAY,CAAA;CAC1B;AAED,MAAM,WAAW,WAAW;IAC1B,QAAQ,EAAE,OAAO,CAAA;IACjB,oBAAoB,IAAI,yBAAyB,CAAA;IACjD,eAAe,IAAI,oBAAoB,CAAA;IACvC,iBAAiB,IAAI,sBAAsB,CAAA;IAC3C,eAAe,IAAI,oBAAoB,CAAA;IACvC,OAAO,EAAE,OAAO,CAAA;CACjB"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var o=Object.defineProperty;var s=Object.getOwnPropertyDescriptor;var y=Object.getOwnPropertyNames;var d=Object.prototype.hasOwnProperty;var i=(t,e,r,f)=>{if(e&&typeof e=="object"||typeof e=="function")for(let p of y(e))!d.call(t,p)&&p!==r&&o(t,p,{get:()=>e[p],enumerable:!(f=s(e,p))||f.enumerable});return t};var l=t=>i(o({},"__esModule",{value:!0}),t);var m={};module.exports=l(m);
|
|
2
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/fieldset/index.ts"],"names":[],"mappings":"AAAA,mBAAmB,kBAAkB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var p=Object.defineProperty;var I=Object.getOwnPropertyDescriptor;var N=Object.getOwnPropertyNames;var h=Object.prototype.hasOwnProperty;var u=(i,n)=>{for(var e in n)p(i,e,{get:n[e],enumerable:!0})},B=(i,n,e,o)=>{if(n&&typeof n=="object"||typeof n=="function")for(let s of N(n))!h.call(i,s)&&s!==e&&p(i,s,{get:()=>n[s],enumerable:!(o=I(n,s))||o.enumerable});return i};var P=i=>B(p({},"__esModule",{value:!0}),i);var D={};u(D,{createInlineNotificationApi:()=>y,inlineNotificationMachine:()=>S,inlineNotificationProps:()=>g,splitInlineNotificationProps:()=>A});module.exports=P(D);var d={closeTrigger:i=>i.ids.get("closeTrigger"),description:i=>i.ids.get("description"),heading:i=>i.ids.get("heading"),root:i=>i.ids.get("root")};function y(i,n){let{prop:e,scope:o,send:s,state:f}=i,c=f.matches("visible"),r={"data-scope":"inline-notification",dir:e("dir")};return{visible:c,getActionBindings(){return n.element({...r,"data-part":"action"})},getCloseTriggerBindings(t){return o.ids.register("closeTrigger",t),n.button({...r,"aria-label":"Dismiss notification","data-part":"close-trigger",id:t.id,onClick:m=>{m.defaultPrevented||s({type:"DISMISS"})},type:"button"})},getDescriptionBindings(t){return o.ids.register("description",t),n.element({...r,"data-part":"description",id:t.id})},getIconBindings(){return n.element({...r,"data-part":"status-icon"})},getLabelBindings(t){return o.ids.register("heading",t),n.element({...r,"data-part":"heading",id:t.id})},getRootBindings(t){return o.ids.register("root",t),n.element({...r,"aria-describedby":d.description(o),"aria-labelledby":d.heading(o),"aria-live":e("role")==="status"?"polite":"assertive","data-part":"root","data-state":c?"visible":"dismissed",hidden:!c,role:e("role")})}}}var l=require("@qualcomm-ui/utils/machine"),S=(0,l.createMachine)({actions:{invokeOnDismiss({prop:i}){i("onDismiss")?.()}},ids:({bindableId:i})=>({closeTrigger:i(),description:i(),heading:i(),root:i()}),initialState:()=>"visible",props({props:i}){return{dir:"ltr",role:"status",...i}},states:{dismissed:{},visible:{on:{DISMISS:{actions:["invokeOnDismiss"],target:"dismissed"}}}}});var a=require("@qualcomm-ui/utils/object"),g=(0,a.createProps)()("dir","getRootNode","onDismiss","role"),A=(0,a.createSplitProps)(g);
|
|
2
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/inline-notification/index.ts", "../../src/inline-notification/internal/inline-notification.dom.ts", "../../src/inline-notification/inline-notification.api.ts", "../../src/inline-notification/inline-notification.machine.ts", "../../src/inline-notification/inline-notification.props.ts"],
|
|
4
|
+
"sourcesContent": ["export * from \"./inline-notification.api\"\nexport * from \"./inline-notification.machine\"\nexport * from \"./inline-notification.props\"\nexport type * from \"./inline-notification.types\"\n", "// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport type {ScopeDomIds} from \"@qualcomm-ui/utils/machine\"\n\nimport type {\n InlineNotificationElementIds,\n InlineNotificationScope,\n} from \"../inline-notification.types\"\n\nexport const domIds: ScopeDomIds<\n InlineNotificationElementIds,\n InlineNotificationScope\n> = {\n closeTrigger: (scope) => scope.ids.get(\"closeTrigger\"),\n description: (scope) => scope.ids.get(\"description\"),\n heading: (scope) => scope.ids.get(\"heading\"),\n root: (scope) => scope.ids.get(\"root\"),\n}\n", "// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport type {\n IdRegistrationProps,\n Machine,\n PropNormalizer,\n} from \"@qualcomm-ui/utils/machine\"\n\nimport type {\n InlineNotificationActionBindings,\n InlineNotificationApi,\n InlineNotificationCloseTriggerBindings,\n InlineNotificationCommonBindings,\n InlineNotificationDescriptionBindings,\n InlineNotificationIconBindings,\n InlineNotificationLabelBindings,\n InlineNotificationRootBindings,\n InlineNotificationSchema,\n} from \"./inline-notification.types\"\nimport {domIds} from \"./internal\"\n\nexport function createInlineNotificationApi(\n machine: Machine<InlineNotificationSchema>,\n normalize: PropNormalizer,\n): InlineNotificationApi {\n const {prop, scope, send, state} = machine\n\n const visible = state.matches(\"visible\")\n\n const commonBindings: InlineNotificationCommonBindings = {\n \"data-scope\": \"inline-notification\",\n dir: prop(\"dir\"),\n }\n\n return {\n visible,\n\n // group: bindings\n getActionBindings(): InlineNotificationActionBindings {\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"action\",\n })\n },\n getCloseTriggerBindings(\n props: IdRegistrationProps,\n ): InlineNotificationCloseTriggerBindings {\n scope.ids.register(\"closeTrigger\", props)\n return normalize.button({\n ...commonBindings,\n \"aria-label\": \"Dismiss notification\",\n \"data-part\": \"close-trigger\",\n id: props.id,\n onClick: (event) => {\n if (!event.defaultPrevented) {\n send({type: \"DISMISS\"})\n }\n },\n type: \"button\",\n })\n },\n getDescriptionBindings(\n props: IdRegistrationProps,\n ): InlineNotificationDescriptionBindings {\n scope.ids.register(\"description\", props)\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"description\",\n id: props.id,\n })\n },\n getIconBindings(): InlineNotificationIconBindings {\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"status-icon\",\n })\n },\n getLabelBindings(\n props: IdRegistrationProps,\n ): InlineNotificationLabelBindings {\n scope.ids.register(\"heading\", props)\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"heading\",\n id: props.id,\n })\n },\n getRootBindings(props): InlineNotificationRootBindings {\n scope.ids.register(\"root\", props)\n return normalize.element({\n ...commonBindings,\n \"aria-describedby\": domIds.description(scope),\n \"aria-labelledby\": domIds.heading(scope),\n \"aria-live\": prop(\"role\") === \"status\" ? \"polite\" : \"assertive\",\n \"data-part\": \"root\",\n \"data-state\": visible ? \"visible\" : \"dismissed\",\n hidden: !visible,\n role: prop(\"role\"),\n })\n },\n }\n}\n", "// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {createMachine, type MachineConfig} from \"@qualcomm-ui/utils/machine\"\n\nimport type {InlineNotificationSchema} from \"./inline-notification.types\"\n\nexport const inlineNotificationMachine: MachineConfig<InlineNotificationSchema> =\n createMachine<InlineNotificationSchema>({\n actions: {\n invokeOnDismiss({prop}) {\n prop(\"onDismiss\")?.()\n },\n },\n ids: ({bindableId}) => ({\n closeTrigger: bindableId(),\n description: bindableId(),\n heading: bindableId(),\n root: bindableId(),\n }),\n initialState: () => \"visible\",\n props({props}) {\n return {\n dir: \"ltr\",\n role: \"status\",\n ...props,\n }\n },\n states: {\n dismissed: {},\n visible: {\n on: {\n DISMISS: {\n actions: [\"invokeOnDismiss\"],\n target: \"dismissed\",\n },\n },\n },\n },\n })\n", "// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {createProps, createSplitProps} from \"@qualcomm-ui/utils/object\"\n\nimport type {InlineNotificationApiProps} from \"./inline-notification.types\"\n\nexport const inlineNotificationProps: (keyof InlineNotificationApiProps)[] =\n createProps<InlineNotificationApiProps>()(\n \"dir\",\n \"getRootNode\",\n \"onDismiss\",\n \"role\",\n )\n\nexport const splitInlineNotificationProps: <\n Props extends InlineNotificationApiProps,\n>(\n props: Props,\n) => [\n InlineNotificationApiProps,\n Omit<Props, keyof InlineNotificationApiProps>,\n] = createSplitProps<InlineNotificationApiProps>(inlineNotificationProps)\n"],
|
|
5
|
+
"mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,iCAAAE,EAAA,8BAAAC,EAAA,4BAAAC,EAAA,iCAAAC,IAAA,eAAAC,EAAAN,GCUO,IAAMO,EAGT,CACF,aAAeC,GAAUA,EAAM,IAAI,IAAI,cAAc,EACrD,YAAcA,GAAUA,EAAM,IAAI,IAAI,aAAa,EACnD,QAAUA,GAAUA,EAAM,IAAI,IAAI,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AACA,EACT,KAAMJ,EAAK,MAAM,CACnB,CAAC,CACH,CACF,CACF,CCnGA,IAAAS,EAAgD,sCAInCC,KACX,iBAAwC,CACtC,QAAS,CACP,gBAAgB,CAAC,KAAAC,CAAI,EAAG,CACtBA,EAAK,WAAW,IAAI,CACtB,CACF,EACA,IAAK,CAAC,CAAC,WAAAC,CAAU,KAAO,CACtB,aAAcA,EAAW,EACzB,YAAaA,EAAW,EACxB,QAASA,EAAW,EACpB,KAAMA,EAAW,CACnB,GACA,aAAc,IAAM,UACpB,MAAM,CAAC,MAAAC,CAAK,EAAG,CACb,MAAO,CACL,IAAK,MACL,KAAM,SACN,GAAGA,CACL,CACF,EACA,OAAQ,CACN,UAAW,CAAC,EACZ,QAAS,CACP,GAAI,CACF,QAAS,CACP,QAAS,CAAC,iBAAiB,EAC3B,OAAQ,WACV,CACF,CACF,CACF,CACF,CAAC,ECpCH,IAAAC,EAA4C,qCAI/BC,KACX,eAAwC,EACtC,MACA,cACA,YACA,MACF,EAEWC,KAOT,oBAA6CD,CAAuB",
|
|
6
|
+
"names": ["inline_notification_exports", "__export", "createInlineNotificationApi", "inlineNotificationMachine", "inlineNotificationProps", "splitInlineNotificationProps", "__toCommonJS", "domIds", "scope", "createInlineNotificationApi", "machine", "normalize", "prop", "scope", "send", "state", "visible", "commonBindings", "props", "event", "domIds", "import_machine", "inlineNotificationMachine", "prop", "bindableId", "props", "import_object", "inlineNotificationProps", "splitInlineNotificationProps"]
|
|
7
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/inline-notification/index.ts"],"names":[],"mappings":"AAAA,cAAc,2BAA2B,CAAA;AACzC,cAAc,+BAA+B,CAAA;AAC7C,cAAc,6BAA6B,CAAA;AAC3C,mBAAmB,6BAA6B,CAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var a={closeTrigger:i=>i.ids.get("closeTrigger"),description:i=>i.ids.get("description"),heading:i=>i.ids.get("heading"),root:i=>i.ids.get("root")};function h(i,t){let{prop:s,scope:o,send:c,state:p}=i,r=p.matches("visible"),e={"data-scope":"inline-notification",dir:s("dir")};return{visible:r,getActionBindings(){return t.element({...e,"data-part":"action"})},getCloseTriggerBindings(n){return o.ids.register("closeTrigger",n),t.button({...e,"aria-label":"Dismiss notification","data-part":"close-trigger",id:n.id,onClick:d=>{d.defaultPrevented||c({type:"DISMISS"})},type:"button"})},getDescriptionBindings(n){return o.ids.register("description",n),t.element({...e,"data-part":"description",id:n.id})},getIconBindings(){return t.element({...e,"data-part":"status-icon"})},getLabelBindings(n){return o.ids.register("heading",n),t.element({...e,"data-part":"heading",id:n.id})},getRootBindings(n){return o.ids.register("root",n),t.element({...e,"aria-describedby":a.description(o),"aria-labelledby":a.heading(o),"aria-live":s("role")==="status"?"polite":"assertive","data-part":"root","data-state":r?"visible":"dismissed",hidden:!r,role:s("role")})}}}import{createMachine as l}from"@qualcomm-ui/utils/machine";var P=l({actions:{invokeOnDismiss({prop:i}){i("onDismiss")?.()}},ids:({bindableId:i})=>({closeTrigger:i(),description:i(),heading:i(),root:i()}),initialState:()=>"visible",props({props:i}){return{dir:"ltr",role:"status",...i}},states:{dismissed:{},visible:{on:{DISMISS:{actions:["invokeOnDismiss"],target:"dismissed"}}}}});import{createProps as g,createSplitProps as f}from"@qualcomm-ui/utils/object";var m=g()("dir","getRootNode","onDismiss","role"),A=f(m);export{h as createInlineNotificationApi,P as inlineNotificationMachine,m as inlineNotificationProps,A as splitInlineNotificationProps};
|
|
2
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/inline-notification/internal/inline-notification.dom.ts", "../../src/inline-notification/inline-notification.api.ts", "../../src/inline-notification/inline-notification.machine.ts", "../../src/inline-notification/inline-notification.props.ts"],
|
|
4
|
+
"sourcesContent": ["// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport type {ScopeDomIds} from \"@qualcomm-ui/utils/machine\"\n\nimport type {\n InlineNotificationElementIds,\n InlineNotificationScope,\n} from \"../inline-notification.types\"\n\nexport const domIds: ScopeDomIds<\n InlineNotificationElementIds,\n InlineNotificationScope\n> = {\n closeTrigger: (scope) => scope.ids.get(\"closeTrigger\"),\n description: (scope) => scope.ids.get(\"description\"),\n heading: (scope) => scope.ids.get(\"heading\"),\n root: (scope) => scope.ids.get(\"root\"),\n}\n", "// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport type {\n IdRegistrationProps,\n Machine,\n PropNormalizer,\n} from \"@qualcomm-ui/utils/machine\"\n\nimport type {\n InlineNotificationActionBindings,\n InlineNotificationApi,\n InlineNotificationCloseTriggerBindings,\n InlineNotificationCommonBindings,\n InlineNotificationDescriptionBindings,\n InlineNotificationIconBindings,\n InlineNotificationLabelBindings,\n InlineNotificationRootBindings,\n InlineNotificationSchema,\n} from \"./inline-notification.types\"\nimport {domIds} from \"./internal\"\n\nexport function createInlineNotificationApi(\n machine: Machine<InlineNotificationSchema>,\n normalize: PropNormalizer,\n): InlineNotificationApi {\n const {prop, scope, send, state} = machine\n\n const visible = state.matches(\"visible\")\n\n const commonBindings: InlineNotificationCommonBindings = {\n \"data-scope\": \"inline-notification\",\n dir: prop(\"dir\"),\n }\n\n return {\n visible,\n\n // group: bindings\n getActionBindings(): InlineNotificationActionBindings {\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"action\",\n })\n },\n getCloseTriggerBindings(\n props: IdRegistrationProps,\n ): InlineNotificationCloseTriggerBindings {\n scope.ids.register(\"closeTrigger\", props)\n return normalize.button({\n ...commonBindings,\n \"aria-label\": \"Dismiss notification\",\n \"data-part\": \"close-trigger\",\n id: props.id,\n onClick: (event) => {\n if (!event.defaultPrevented) {\n send({type: \"DISMISS\"})\n }\n },\n type: \"button\",\n })\n },\n getDescriptionBindings(\n props: IdRegistrationProps,\n ): InlineNotificationDescriptionBindings {\n scope.ids.register(\"description\", props)\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"description\",\n id: props.id,\n })\n },\n getIconBindings(): InlineNotificationIconBindings {\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"status-icon\",\n })\n },\n getLabelBindings(\n props: IdRegistrationProps,\n ): InlineNotificationLabelBindings {\n scope.ids.register(\"heading\", props)\n return normalize.element({\n ...commonBindings,\n \"data-part\": \"heading\",\n id: props.id,\n })\n },\n getRootBindings(props): InlineNotificationRootBindings {\n scope.ids.register(\"root\", props)\n return normalize.element({\n ...commonBindings,\n \"aria-describedby\": domIds.description(scope),\n \"aria-labelledby\": domIds.heading(scope),\n \"aria-live\": prop(\"role\") === \"status\" ? \"polite\" : \"assertive\",\n \"data-part\": \"root\",\n \"data-state\": visible ? \"visible\" : \"dismissed\",\n hidden: !visible,\n role: prop(\"role\"),\n })\n },\n }\n}\n", "// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {createMachine, type MachineConfig} from \"@qualcomm-ui/utils/machine\"\n\nimport type {InlineNotificationSchema} from \"./inline-notification.types\"\n\nexport const inlineNotificationMachine: MachineConfig<InlineNotificationSchema> =\n createMachine<InlineNotificationSchema>({\n actions: {\n invokeOnDismiss({prop}) {\n prop(\"onDismiss\")?.()\n },\n },\n ids: ({bindableId}) => ({\n closeTrigger: bindableId(),\n description: bindableId(),\n heading: bindableId(),\n root: bindableId(),\n }),\n initialState: () => \"visible\",\n props({props}) {\n return {\n dir: \"ltr\",\n role: \"status\",\n ...props,\n }\n },\n states: {\n dismissed: {},\n visible: {\n on: {\n DISMISS: {\n actions: [\"invokeOnDismiss\"],\n target: \"dismissed\",\n },\n },\n },\n },\n })\n", "// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.\n// SPDX-License-Identifier: BSD-3-Clause-Clear\n\nimport {createProps, createSplitProps} from \"@qualcomm-ui/utils/object\"\n\nimport type {InlineNotificationApiProps} from \"./inline-notification.types\"\n\nexport const inlineNotificationProps: (keyof InlineNotificationApiProps)[] =\n createProps<InlineNotificationApiProps>()(\n \"dir\",\n \"getRootNode\",\n \"onDismiss\",\n \"role\",\n )\n\nexport const splitInlineNotificationProps: <\n Props extends InlineNotificationApiProps,\n>(\n props: Props,\n) => [\n InlineNotificationApiProps,\n Omit<Props, keyof InlineNotificationApiProps>,\n] = createSplitProps<InlineNotificationApiProps>(inlineNotificationProps)\n"],
|
|
5
|
+
"mappings": "AAUO,IAAMA,EAGT,CACF,aAAeC,GAAUA,EAAM,IAAI,IAAI,cAAc,EACrD,YAAcA,GAAUA,EAAM,IAAI,IAAI,aAAa,EACnD,QAAUA,GAAUA,EAAM,IAAI,IAAI,SAAS,EAC3C,KAAOA,GAAUA,EAAM,IAAI,IAAI,MAAM,CACvC,ECIO,SAASC,EACdC,EACAC,EACuB,CACvB,GAAM,CAAC,KAAAC,EAAM,MAAAC,EAAO,KAAAC,EAAM,MAAAC,CAAK,EAAIL,EAE7BM,EAAUD,EAAM,QAAQ,SAAS,EAEjCE,EAAmD,CACvD,aAAc,sBACd,IAAKL,EAAK,KAAK,CACjB,EAEA,MAAO,CACL,QAAAI,EAGA,mBAAsD,CACpD,OAAOL,EAAU,QAAQ,CACvB,GAAGM,EACH,YAAa,QACf,CAAC,CACH,EACA,wBACEC,EACwC,CACxC,OAAAL,EAAM,IAAI,SAAS,eAAgBK,CAAK,EACjCP,EAAU,OAAO,CACtB,GAAGM,EACH,aAAc,uBACd,YAAa,gBACb,GAAIC,EAAM,GACV,QAAUC,GAAU,CACbA,EAAM,kBACTL,EAAK,CAAC,KAAM,SAAS,CAAC,CAE1B,EACA,KAAM,QACR,CAAC,CACH,EACA,uBACEI,EACuC,CACvC,OAAAL,EAAM,IAAI,SAAS,cAAeK,CAAK,EAChCP,EAAU,QAAQ,CACvB,GAAGM,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6
|
+
"names": ["domIds", "scope", "createInlineNotificationApi", "machine", "normalize", "prop", "scope", "send", "state", "visible", "commonBindings", "props", "event", "domIds", "createMachine", "inlineNotificationMachine", "prop", "bindableId", "props", "createProps", "createSplitProps", "inlineNotificationProps", "splitInlineNotificationProps"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { Machine, PropNormalizer } from "@qualcomm-ui/utils/machine";
|
|
2
|
+
import type { InlineNotificationApi, InlineNotificationSchema } from "./inline-notification.types";
|
|
3
|
+
export declare function createInlineNotificationApi(machine: Machine<InlineNotificationSchema>, normalize: PropNormalizer): InlineNotificationApi;
|
|
4
|
+
//# sourceMappingURL=inline-notification.api.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inline-notification.api.d.ts","sourceRoot":"","sources":["../../src/inline-notification/inline-notification.api.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAEV,OAAO,EACP,cAAc,EACf,MAAM,4BAA4B,CAAA;AAEnC,OAAO,KAAK,EAEV,qBAAqB,EAOrB,wBAAwB,EACzB,MAAM,6BAA6B,CAAA;AAGpC,wBAAgB,2BAA2B,CACzC,OAAO,EAAE,OAAO,CAAC,wBAAwB,CAAC,EAC1C,SAAS,EAAE,cAAc,GACxB,qBAAqB,CA6EvB"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { type MachineConfig } from "@qualcomm-ui/utils/machine";
|
|
2
|
+
import type { InlineNotificationSchema } from "./inline-notification.types";
|
|
3
|
+
export declare const inlineNotificationMachine: MachineConfig<InlineNotificationSchema>;
|
|
4
|
+
//# sourceMappingURL=inline-notification.machine.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inline-notification.machine.d.ts","sourceRoot":"","sources":["../../src/inline-notification/inline-notification.machine.ts"],"names":[],"mappings":"AAGA,OAAO,EAAgB,KAAK,aAAa,EAAC,MAAM,4BAA4B,CAAA;AAE5E,OAAO,KAAK,EAAC,wBAAwB,EAAC,MAAM,6BAA6B,CAAA;AAEzE,eAAO,MAAM,yBAAyB,EAAE,aAAa,CAAC,wBAAwB,CAgC1E,CAAA"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { InlineNotificationApiProps } from "./inline-notification.types";
|
|
2
|
+
export declare const inlineNotificationProps: (keyof InlineNotificationApiProps)[];
|
|
3
|
+
export declare const splitInlineNotificationProps: <Props extends InlineNotificationApiProps>(props: Props) => [
|
|
4
|
+
InlineNotificationApiProps,
|
|
5
|
+
Omit<Props, keyof InlineNotificationApiProps>
|
|
6
|
+
];
|
|
7
|
+
//# sourceMappingURL=inline-notification.props.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inline-notification.props.d.ts","sourceRoot":"","sources":["../../src/inline-notification/inline-notification.props.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAC,0BAA0B,EAAC,MAAM,6BAA6B,CAAA;AAE3E,eAAO,MAAM,uBAAuB,EAAE,CAAC,MAAM,0BAA0B,CAAC,EAMrE,CAAA;AAEH,eAAO,MAAM,4BAA4B,EAAE,CACzC,KAAK,SAAS,0BAA0B,EAExC,KAAK,EAAE,KAAK,KACT;IACH,0BAA0B;IAC1B,IAAI,CAAC,KAAK,EAAE,MAAM,0BAA0B,CAAC;CAC0B,CAAA"}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import type { DirectionProperty } from "@qualcomm-ui/utils/direction";
|
|
2
|
+
import type { RequiredBy } from "@qualcomm-ui/utils/guard";
|
|
3
|
+
import type { ActionSchema, BindableIds, CommonProperties, IdRegistrationProps, JSX, MachineSchema, Scope } from "@qualcomm-ui/utils/machine";
|
|
4
|
+
export interface InlineNotificationApiProps extends CommonProperties, DirectionProperty {
|
|
5
|
+
/**
|
|
6
|
+
* Function invoked when the notification is dismissed
|
|
7
|
+
*/
|
|
8
|
+
onDismiss?: () => void;
|
|
9
|
+
/**
|
|
10
|
+
* The WAI-ARIA {@link https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Roles role} of the notification.
|
|
11
|
+
* @option `'alert'`: Use this role when the notification is an alert that requires the user's immediate attention, like for errors or urgent information.
|
|
12
|
+
* @option `'status'`: Use this role when the notification is a status message that doesn't require the user's immediate attention, like for success or informational messages.
|
|
13
|
+
*
|
|
14
|
+
* @default 'status'
|
|
15
|
+
*/
|
|
16
|
+
role?: "alert" | "status";
|
|
17
|
+
}
|
|
18
|
+
export interface InlineNotificationElementIds {
|
|
19
|
+
closeTrigger: string;
|
|
20
|
+
description: string;
|
|
21
|
+
heading: string;
|
|
22
|
+
root: string;
|
|
23
|
+
}
|
|
24
|
+
export interface InlineNotificationScope extends Scope {
|
|
25
|
+
ids: BindableIds<InlineNotificationSchema>;
|
|
26
|
+
}
|
|
27
|
+
export interface InlineNotificationSchema extends MachineSchema {
|
|
28
|
+
actions: ActionSchema<"invokeOnDismiss">;
|
|
29
|
+
events: {
|
|
30
|
+
type: "DISMISS";
|
|
31
|
+
};
|
|
32
|
+
ids: InlineNotificationElementIds;
|
|
33
|
+
props: RequiredBy<InlineNotificationApiProps, "dir" | "role">;
|
|
34
|
+
state: "visible" | "dismissed";
|
|
35
|
+
}
|
|
36
|
+
export interface InlineNotificationCommonBindings extends DirectionProperty {
|
|
37
|
+
"data-scope": "inline-notification";
|
|
38
|
+
}
|
|
39
|
+
export interface InlineNotificationRootBindings extends InlineNotificationCommonBindings {
|
|
40
|
+
"aria-live": "polite" | "assertive";
|
|
41
|
+
"data-part": "root";
|
|
42
|
+
"data-state": "visible" | "dismissed";
|
|
43
|
+
hidden: boolean | undefined;
|
|
44
|
+
role: "alert" | "status";
|
|
45
|
+
}
|
|
46
|
+
export interface InlineNotificationIconBindings extends InlineNotificationCommonBindings {
|
|
47
|
+
"data-part": "status-icon";
|
|
48
|
+
}
|
|
49
|
+
export interface InlineNotificationLabelBindings extends InlineNotificationCommonBindings {
|
|
50
|
+
"data-part": "heading";
|
|
51
|
+
id: string;
|
|
52
|
+
}
|
|
53
|
+
export interface InlineNotificationDescriptionBindings extends InlineNotificationCommonBindings {
|
|
54
|
+
"data-part": "description";
|
|
55
|
+
id: string;
|
|
56
|
+
}
|
|
57
|
+
export interface InlineNotificationActionBindings extends InlineNotificationCommonBindings {
|
|
58
|
+
"data-part": "action";
|
|
59
|
+
}
|
|
60
|
+
export interface InlineNotificationCloseTriggerBindings extends InlineNotificationCommonBindings {
|
|
61
|
+
"aria-label": string;
|
|
62
|
+
"data-part": "close-trigger";
|
|
63
|
+
id: string;
|
|
64
|
+
onClick: JSX.MouseEventHandler;
|
|
65
|
+
type: "button";
|
|
66
|
+
}
|
|
67
|
+
export interface InlineNotificationApi {
|
|
68
|
+
visible: boolean;
|
|
69
|
+
getActionBindings(): InlineNotificationActionBindings;
|
|
70
|
+
getCloseTriggerBindings(props: IdRegistrationProps): InlineNotificationCloseTriggerBindings;
|
|
71
|
+
getDescriptionBindings(props: IdRegistrationProps): InlineNotificationDescriptionBindings;
|
|
72
|
+
getIconBindings(): InlineNotificationIconBindings;
|
|
73
|
+
getLabelBindings(props: IdRegistrationProps): InlineNotificationLabelBindings;
|
|
74
|
+
getRootBindings(props: IdRegistrationProps): InlineNotificationRootBindings;
|
|
75
|
+
}
|
|
76
|
+
//# sourceMappingURL=inline-notification.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inline-notification.types.d.ts","sourceRoot":"","sources":["../../src/inline-notification/inline-notification.types.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAC,iBAAiB,EAAC,MAAM,8BAA8B,CAAA;AACnE,OAAO,KAAK,EAAC,UAAU,EAAC,MAAM,0BAA0B,CAAA;AACxD,OAAO,KAAK,EACV,YAAY,EACZ,WAAW,EACX,gBAAgB,EAChB,mBAAmB,EACnB,GAAG,EACH,aAAa,EACb,KAAK,EACN,MAAM,4BAA4B,CAAA;AAEnC,MAAM,WAAW,0BACf,SAAQ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,SAAQ,gCAAgC;IACxC,WAAW,EAAE,aAAa,CAAA;IAC1B,EAAE,EAAE,MAAM,CAAA;CACX;AAED,MAAM,WAAW,gCACf,SAAQ,gCAAgC;IACxC,WAAW,EAAE,QAAQ,CAAA;CACtB;AAED,MAAM,WAAW,sCACf,SAAQ,gCAAgC;IACxC,YAAY,EAAE,MAAM,CAAA;IACpB,WAAW,EAAE,eAAe,CAAA;IAC5B,EAAE,EAAE,MAAM,CAAA;IACV,OAAO,EAAE,GAAG,CAAC,iBAAiB,CAAA;IAC9B,IAAI,EAAE,QAAQ,CAAA;CACf;AAED,MAAM,WAAW,qBAAqB;IACpC,OAAO,EAAE,OAAO,CAAA;IAGhB,iBAAiB,IAAI,gCAAgC,CAAA;IACrD,uBAAuB,CACrB,KAAK,EAAE,mBAAmB,GACzB,sCAAsC,CAAA;IACzC,sBAAsB,CACpB,KAAK,EAAE,mBAAmB,GACzB,qCAAqC,CAAA;IACxC,eAAe,IAAI,8BAA8B,CAAA;IACjD,gBAAgB,CAAC,KAAK,EAAE,mBAAmB,GAAG,+BAA+B,CAAA;IAC7E,eAAe,CAAC,KAAK,EAAE,mBAAmB,GAAG,8BAA8B,CAAA;CAC5E"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/inline-notification/internal/index.ts"],"names":[],"mappings":"AAAA,cAAc,2BAA2B,CAAA"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { ScopeDomIds } from "@qualcomm-ui/utils/machine";
|
|
2
|
+
import type { InlineNotificationElementIds, InlineNotificationScope } from "../inline-notification.types";
|
|
3
|
+
export declare const domIds: ScopeDomIds<InlineNotificationElementIds, InlineNotificationScope>;
|
|
4
|
+
//# sourceMappingURL=inline-notification.dom.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inline-notification.dom.d.ts","sourceRoot":"","sources":["../../../src/inline-notification/internal/inline-notification.dom.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAC,WAAW,EAAC,MAAM,4BAA4B,CAAA;AAE3D,OAAO,KAAK,EACV,4BAA4B,EAC5B,uBAAuB,EACxB,MAAM,8BAA8B,CAAA;AAErC,eAAO,MAAM,MAAM,EAAE,WAAW,CAC9B,4BAA4B,EAC5B,uBAAuB,CAMxB,CAAA"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var r=Object.defineProperty;var f=Object.getOwnPropertyDescriptor;var i=Object.getOwnPropertyNames;var m=Object.prototype.hasOwnProperty;var n=(t,p,y,o)=>{if(p&&typeof p=="object"||typeof p=="function")for(let e of i(p))!m.call(t,e)&&e!==y&&r(t,e,{get:()=>p[e],enumerable:!(o=f(p,e))||o.enumerable});return t};var s=t=>n(r({},"__esModule",{value:!0}),t);var u={};module.exports=s(u);
|
|
2
|
+
//# sourceMappingURL=index.cjs.map
|