@refinitiv-ui/elements 6.9.0-next.0 → 6.9.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/CHANGELOG.md +218 -380
- package/LICENSE +1 -1
- package/README.md +12 -10
- package/lib/accordion/index.d.ts +1 -1
- package/lib/accordion/index.js +4 -7
- package/lib/accordion/themes/halo/dark/index.js +0 -1
- package/lib/accordion/themes/halo/light/index.js +0 -1
- package/lib/accordion/themes/solar/charcoal/index.js +0 -1
- package/lib/accordion/themes/solar/pearl/index.js +0 -1
- package/lib/appstate-bar/index.d.ts +2 -2
- package/lib/appstate-bar/index.js +10 -4
- package/lib/appstate-bar/themes/halo/dark/index.js +0 -1
- package/lib/appstate-bar/themes/halo/light/index.js +0 -1
- package/lib/appstate-bar/themes/solar/charcoal/index.js +0 -1
- package/lib/appstate-bar/themes/solar/pearl/index.js +0 -1
- package/lib/autosuggest/index.d.ts +7 -7
- package/lib/autosuggest/index.js +89 -84
- package/lib/autosuggest/themes/halo/dark/index.js +0 -1
- package/lib/autosuggest/themes/halo/light/index.js +0 -1
- package/lib/autosuggest/themes/solar/charcoal/index.js +1 -2
- package/lib/autosuggest/themes/solar/pearl/index.js +1 -2
- package/lib/button/index.js +7 -10
- package/lib/button/themes/halo/dark/index.js +0 -1
- package/lib/button/themes/halo/light/index.js +0 -1
- package/lib/button/themes/solar/charcoal/index.js +0 -1
- package/lib/button/themes/solar/pearl/index.js +0 -1
- package/lib/button-bar/index.d.ts +1 -1
- package/lib/button-bar/index.js +12 -12
- package/lib/button-bar/themes/halo/dark/index.js +0 -1
- package/lib/button-bar/themes/halo/light/index.js +0 -1
- package/lib/button-bar/themes/solar/charcoal/index.js +0 -1
- package/lib/button-bar/themes/solar/pearl/index.js +0 -1
- package/lib/calendar/index.d.ts +39 -39
- package/lib/calendar/index.js +165 -132
- package/lib/calendar/themes/halo/dark/index.js +0 -1
- package/lib/calendar/themes/halo/light/index.js +0 -1
- package/lib/calendar/themes/solar/charcoal/index.js +0 -1
- package/lib/calendar/themes/solar/pearl/index.js +0 -1
- package/lib/calendar/utils.js +2 -2
- package/lib/canvas/index.d.ts +1 -1
- package/lib/canvas/index.js +2 -4
- package/lib/canvas/themes/halo/dark/index.js +0 -1
- package/lib/canvas/themes/halo/light/index.js +0 -1
- package/lib/canvas/themes/solar/charcoal/index.js +0 -1
- package/lib/canvas/themes/solar/pearl/index.js +0 -1
- package/lib/card/helpers/types.d.ts +2 -2
- package/lib/card/index.d.ts +5 -5
- package/lib/card/index.js +34 -28
- package/lib/card/themes/halo/dark/index.js +0 -1
- package/lib/card/themes/halo/light/index.js +0 -1
- package/lib/card/themes/solar/charcoal/index.js +0 -1
- package/lib/card/themes/solar/pearl/index.js +0 -1
- package/lib/chart/helpers/legend.js +10 -8
- package/lib/chart/index.d.ts +3 -3
- package/lib/chart/index.js +17 -17
- package/lib/chart/plugins/doughnut-center-label.js +7 -6
- package/lib/chart/themes/halo/dark/index.js +0 -1
- package/lib/chart/themes/halo/light/index.js +0 -1
- package/lib/chart/themes/solar/charcoal/index.js +0 -1
- package/lib/chart/themes/solar/pearl/index.js +0 -1
- package/lib/checkbox/index.d.ts +1 -1
- package/lib/checkbox/index.js +12 -13
- package/lib/checkbox/themes/halo/dark/index.js +0 -1
- package/lib/checkbox/themes/halo/light/index.js +0 -1
- package/lib/checkbox/themes/solar/charcoal/index.js +0 -1
- package/lib/checkbox/themes/solar/pearl/index.js +0 -1
- package/lib/clock/index.d.ts +55 -55
- package/lib/clock/index.js +84 -95
- package/lib/clock/themes/halo/dark/index.js +1 -2
- package/lib/clock/themes/halo/light/index.js +1 -2
- package/lib/clock/themes/solar/charcoal/index.js +1 -2
- package/lib/clock/themes/solar/pearl/index.js +1 -2
- package/lib/collapse/index.d.ts +1 -1
- package/lib/collapse/index.js +28 -19
- package/lib/collapse/themes/halo/dark/index.js +1 -2
- package/lib/collapse/themes/halo/light/index.js +1 -2
- package/lib/collapse/themes/solar/charcoal/index.js +0 -1
- package/lib/collapse/themes/solar/pearl/index.js +0 -1
- package/lib/color-dialog/elements/color-palettes.d.ts +1 -1
- package/lib/color-dialog/elements/color-palettes.js +5 -6
- package/lib/color-dialog/elements/grayscale-palettes.d.ts +1 -1
- package/lib/color-dialog/elements/grayscale-palettes.js +9 -9
- package/lib/color-dialog/elements/palettes.js +5 -4
- package/lib/color-dialog/helpers/value-model.js +7 -9
- package/lib/color-dialog/index.d.ts +6 -6
- package/lib/color-dialog/index.js +53 -37
- package/lib/color-dialog/themes/halo/dark/index.js +0 -1
- package/lib/color-dialog/themes/halo/light/index.js +0 -1
- package/lib/color-dialog/themes/solar/charcoal/index.js +0 -1
- package/lib/color-dialog/themes/solar/pearl/index.js +0 -1
- package/lib/color-picker/index.d.ts +2 -2
- package/lib/color-picker/index.js +40 -34
- package/lib/color-picker/themes/halo/dark/index.js +0 -1
- package/lib/color-picker/themes/halo/light/index.js +0 -1
- package/lib/color-picker/themes/solar/charcoal/index.js +0 -1
- package/lib/color-picker/themes/solar/pearl/index.js +0 -1
- package/lib/combo-box/helpers/filter.d.ts +2 -2
- package/lib/combo-box/helpers/types.d.ts +1 -1
- package/lib/combo-box/index.d.ts +9 -9
- package/lib/combo-box/index.js +61 -55
- package/lib/combo-box/themes/halo/dark/index.js +0 -1
- package/lib/combo-box/themes/halo/light/index.js +0 -1
- package/lib/combo-box/themes/solar/charcoal/index.js +0 -1
- package/lib/combo-box/themes/solar/pearl/index.js +0 -1
- package/lib/configuration/custom-elements.json +15 -0
- package/lib/configuration/custom-elements.md +7 -0
- package/lib/{config/elements/config.d.ts → configuration/elements/configuration.d.ts} +14 -7
- package/lib/{config/elements/config.js → configuration/elements/configuration.js} +17 -15
- package/lib/configuration/helpers/context.d.ts +5 -0
- package/lib/configuration/helpers/context.js +3 -0
- package/lib/{config/helpers/context.d.ts → configuration/helpers/types.d.ts} +0 -3
- package/lib/configuration/helpers/types.js +1 -0
- package/lib/configuration/index.d.ts +3 -0
- package/lib/{config → configuration}/index.js +1 -1
- package/lib/counter/index.d.ts +4 -4
- package/lib/counter/index.js +9 -7
- package/lib/counter/themes/halo/dark/index.js +0 -1
- package/lib/counter/themes/halo/light/index.js +0 -1
- package/lib/counter/themes/solar/charcoal/index.js +0 -1
- package/lib/counter/themes/solar/pearl/index.js +0 -1
- package/lib/datetime-field/index.d.ts +4 -5
- package/lib/datetime-field/index.js +32 -23
- package/lib/datetime-field/themes/halo/dark/index.js +0 -1
- package/lib/datetime-field/themes/halo/light/index.js +0 -1
- package/lib/datetime-field/themes/solar/charcoal/index.js +0 -1
- package/lib/datetime-field/themes/solar/pearl/index.js +0 -1
- package/lib/datetime-field/utils.js +11 -1
- package/lib/datetime-picker/index.d.ts +75 -75
- package/lib/datetime-picker/index.js +154 -135
- package/lib/datetime-picker/locales.js +5 -5
- package/lib/datetime-picker/themes/halo/dark/index.js +0 -1
- package/lib/datetime-picker/themes/halo/light/index.js +0 -1
- package/lib/datetime-picker/themes/solar/charcoal/index.js +0 -1
- package/lib/datetime-picker/themes/solar/pearl/index.js +0 -1
- package/lib/datetime-picker/utils.js +9 -9
- package/lib/dialog/custom-elements.json +0 -11
- package/lib/dialog/custom-elements.md +3 -4
- package/lib/dialog/draggable-element.js +1 -2
- package/lib/dialog/index.d.ts +7 -7
- package/lib/dialog/index.js +48 -38
- package/lib/dialog/themes/halo/dark/index.js +0 -1
- package/lib/dialog/themes/halo/light/index.js +0 -1
- package/lib/dialog/themes/solar/charcoal/index.js +0 -1
- package/lib/dialog/themes/solar/pearl/index.js +0 -1
- package/lib/email-field/index.d.ts +1 -1
- package/lib/email-field/index.js +6 -6
- package/lib/email-field/themes/halo/dark/index.js +0 -1
- package/lib/email-field/themes/halo/light/index.js +0 -1
- package/lib/email-field/themes/solar/charcoal/index.js +0 -1
- package/lib/email-field/themes/solar/pearl/index.js +0 -1
- package/lib/events.d.ts +1 -1
- package/lib/flag/custom-elements.json +0 -12
- package/lib/flag/custom-elements.md +0 -3
- package/lib/flag/index.d.ts +12 -8
- package/lib/flag/index.js +20 -12
- package/lib/flag/themes/halo/dark/index.js +0 -1
- package/lib/flag/themes/halo/light/index.js +0 -1
- package/lib/flag/themes/solar/charcoal/index.js +0 -1
- package/lib/flag/themes/solar/pearl/index.js +0 -1
- package/lib/flag/utils/FlagLoader.js +1 -1
- package/lib/header/index.d.ts +1 -1
- package/lib/header/index.js +2 -2
- package/lib/header/themes/halo/dark/index.js +1 -2
- package/lib/header/themes/halo/light/index.js +1 -2
- package/lib/header/themes/solar/charcoal/index.js +1 -2
- package/lib/header/themes/solar/pearl/index.js +1 -2
- package/lib/heatmap/helpers/color.d.ts +1 -1
- package/lib/heatmap/helpers/color.js +11 -5
- package/lib/heatmap/helpers/track.js +3 -3
- package/lib/heatmap/helpers/types.d.ts +10 -10
- package/lib/heatmap/index.d.ts +9 -9
- package/lib/heatmap/index.js +104 -65
- package/lib/heatmap/themes/halo/dark/index.js +0 -1
- package/lib/heatmap/themes/halo/light/index.js +0 -1
- package/lib/heatmap/themes/solar/charcoal/index.js +0 -1
- package/lib/heatmap/themes/solar/pearl/index.js +0 -1
- package/lib/icon/custom-elements.json +0 -13
- package/lib/icon/custom-elements.md +0 -1
- package/lib/icon/index.d.ts +16 -6
- package/lib/icon/index.js +22 -11
- package/lib/icon/themes/halo/dark/index.js +0 -1
- package/lib/icon/themes/halo/light/index.js +0 -1
- package/lib/icon/themes/solar/charcoal/index.js +0 -1
- package/lib/icon/themes/solar/pearl/index.js +0 -1
- package/lib/icon/utils/IconLoader.d.ts +1 -0
- package/lib/icon/utils/IconLoader.js +9 -1
- package/lib/interactive-chart/custom-elements.json +5 -0
- package/lib/interactive-chart/custom-elements.md +1 -0
- package/lib/interactive-chart/helpers/types.d.ts +3 -3
- package/lib/interactive-chart/index.d.ts +40 -36
- package/lib/interactive-chart/index.js +78 -59
- package/lib/interactive-chart/themes/halo/dark/index.js +0 -1
- package/lib/interactive-chart/themes/halo/light/index.js +0 -1
- package/lib/interactive-chart/themes/solar/charcoal/index.js +0 -1
- package/lib/interactive-chart/themes/solar/pearl/index.js +0 -1
- package/lib/item/helpers/types.d.ts +1 -1
- package/lib/item/index.d.ts +3 -3
- package/lib/item/index.js +24 -20
- package/lib/item/themes/halo/dark/index.js +0 -1
- package/lib/item/themes/halo/light/index.js +0 -1
- package/lib/item/themes/solar/charcoal/index.js +0 -1
- package/lib/item/themes/solar/pearl/index.js +0 -1
- package/lib/jsx.d.ts +6 -4
- package/lib/label/index.d.ts +1 -1
- package/lib/label/index.js +11 -8
- package/lib/label/themes/halo/dark/index.js +0 -1
- package/lib/label/themes/halo/light/index.js +0 -1
- package/lib/label/themes/solar/charcoal/index.js +0 -1
- package/lib/label/themes/solar/pearl/index.js +0 -1
- package/lib/layout/index.d.ts +7 -7
- package/lib/layout/index.js +7 -7
- package/lib/layout/themes/halo/dark/index.js +0 -1
- package/lib/layout/themes/halo/light/index.js +0 -1
- package/lib/layout/themes/solar/charcoal/index.js +0 -1
- package/lib/layout/themes/solar/pearl/index.js +0 -1
- package/lib/led-gauge/index.d.ts +1 -1
- package/lib/led-gauge/index.js +10 -10
- package/lib/led-gauge/themes/halo/dark/index.js +0 -1
- package/lib/led-gauge/themes/halo/light/index.js +0 -1
- package/lib/led-gauge/themes/solar/charcoal/index.js +0 -1
- package/lib/led-gauge/themes/solar/pearl/index.js +0 -1
- package/lib/list/elements/list.d.ts +3 -3
- package/lib/list/elements/list.js +10 -12
- package/lib/list/helpers/renderer.js +2 -2
- package/lib/list/helpers/types.d.ts +1 -1
- package/lib/list/index.d.ts +1 -1
- package/lib/list/renderer.d.ts +7 -7
- package/lib/list/themes/halo/dark/index.js +0 -2
- package/lib/list/themes/halo/light/index.js +0 -2
- package/lib/list/themes/solar/charcoal/index.js +0 -2
- package/lib/list/themes/solar/pearl/index.js +0 -2
- package/lib/loader/index.js +7 -8
- package/lib/loader/themes/halo/dark/index.js +0 -1
- package/lib/loader/themes/halo/light/index.js +0 -1
- package/lib/loader/themes/solar/charcoal/index.js +0 -1
- package/lib/loader/themes/solar/pearl/index.js +0 -1
- package/lib/multi-input/index.d.ts +6 -6
- package/lib/multi-input/index.js +39 -45
- package/lib/multi-input/themes/halo/dark/index.js +0 -1
- package/lib/multi-input/themes/halo/light/index.js +0 -1
- package/lib/multi-input/themes/solar/charcoal/index.js +0 -1
- package/lib/multi-input/themes/solar/pearl/index.js +0 -1
- package/lib/notification/elements/notification-tray.d.ts +2 -2
- package/lib/notification/elements/notification-tray.js +3 -3
- package/lib/notification/elements/notification.d.ts +2 -2
- package/lib/notification/elements/notification.js +17 -14
- package/lib/notification/helpers/status.js +1 -1
- package/lib/notification/themes/halo/dark/index.js +1 -3
- package/lib/notification/themes/halo/light/index.js +1 -3
- package/lib/notification/themes/solar/charcoal/index.js +1 -3
- package/lib/notification/themes/solar/pearl/index.js +1 -3
- package/lib/number-field/index.d.ts +12 -6
- package/lib/number-field/index.js +64 -48
- package/lib/number-field/themes/halo/dark/index.js +0 -1
- package/lib/number-field/themes/halo/light/index.js +0 -1
- package/lib/number-field/themes/solar/charcoal/index.js +0 -1
- package/lib/number-field/themes/solar/pearl/index.js +0 -1
- package/lib/overlay/elements/overlay-viewport.d.ts +1 -1
- package/lib/overlay/elements/overlay.d.ts +2 -2
- package/lib/overlay/elements/overlay.js +154 -98
- package/lib/overlay/helpers/types.d.ts +1 -1
- package/lib/overlay/managers/backdrop-manager.d.ts +1 -1
- package/lib/overlay/managers/backdrop-manager.js +2 -2
- package/lib/overlay/managers/close-manager.js +2 -1
- package/lib/overlay/managers/focus-manager.js +23 -13
- package/lib/overlay/managers/interaction-lock-manager.d.ts +4 -4
- package/lib/overlay/managers/interaction-lock-manager.js +33 -25
- package/lib/overlay/managers/viewport-manager.d.ts +2 -2
- package/lib/overlay/managers/viewport-manager.js +3 -2
- package/lib/overlay/managers/zindex-manager.js +4 -2
- package/lib/overlay/themes/halo/dark/index.js +0 -2
- package/lib/overlay/themes/halo/light/index.js +0 -2
- package/lib/overlay/themes/solar/charcoal/index.js +0 -2
- package/lib/overlay/themes/solar/pearl/index.js +0 -2
- package/lib/overlay-menu/helpers/types.d.ts +2 -2
- package/lib/overlay-menu/index.d.ts +1 -1
- package/lib/overlay-menu/index.js +44 -33
- package/lib/overlay-menu/managers/menu-manager.d.ts +10 -10
- package/lib/overlay-menu/managers/menu-manager.js +15 -13
- package/lib/overlay-menu/themes/halo/dark/index.js +0 -1
- package/lib/overlay-menu/themes/halo/light/index.js +0 -1
- package/lib/overlay-menu/themes/solar/charcoal/index.js +0 -1
- package/lib/overlay-menu/themes/solar/pearl/index.js +0 -1
- package/lib/pagination/index.d.ts +4 -4
- package/lib/pagination/index.js +39 -14
- package/lib/pagination/themes/halo/dark/index.js +0 -1
- package/lib/pagination/themes/halo/light/index.js +0 -1
- package/lib/pagination/themes/solar/charcoal/index.js +0 -1
- package/lib/pagination/themes/solar/pearl/index.js +0 -1
- package/lib/panel/index.js +1 -1
- package/lib/panel/themes/halo/dark/index.js +0 -1
- package/lib/panel/themes/halo/light/index.js +0 -1
- package/lib/panel/themes/solar/charcoal/index.js +0 -1
- package/lib/panel/themes/solar/pearl/index.js +0 -1
- package/lib/password-field/index.d.ts +2 -2
- package/lib/password-field/index.js +7 -4
- package/lib/password-field/themes/halo/dark/index.js +1 -2
- package/lib/password-field/themes/halo/light/index.js +1 -2
- package/lib/password-field/themes/solar/charcoal/index.js +1 -2
- package/lib/password-field/themes/solar/pearl/index.js +1 -2
- package/lib/pill/index.d.ts +1 -1
- package/lib/pill/index.js +22 -19
- package/lib/pill/themes/halo/dark/index.js +0 -1
- package/lib/pill/themes/halo/light/index.js +0 -1
- package/lib/pill/themes/solar/charcoal/index.js +0 -1
- package/lib/pill/themes/solar/pearl/index.js +0 -1
- package/lib/progress-bar/index.d.ts +1 -1
- package/lib/progress-bar/index.js +38 -37
- package/lib/progress-bar/themes/halo/dark/index.js +0 -1
- package/lib/progress-bar/themes/halo/light/index.js +0 -1
- package/lib/progress-bar/themes/solar/charcoal/index.js +0 -1
- package/lib/progress-bar/themes/solar/pearl/index.js +0 -1
- package/lib/radio-button/index.d.ts +2 -2
- package/lib/radio-button/index.js +17 -12
- package/lib/radio-button/radio-button-registry.js +8 -5
- package/lib/radio-button/themes/halo/dark/index.js +0 -1
- package/lib/radio-button/themes/halo/light/index.js +0 -1
- package/lib/radio-button/themes/solar/charcoal/index.js +0 -1
- package/lib/radio-button/themes/solar/pearl/index.js +0 -1
- package/lib/rating/index.d.ts +1 -1
- package/lib/rating/index.js +2 -5
- package/lib/rating/themes/halo/dark/index.js +0 -1
- package/lib/rating/themes/halo/light/index.js +0 -1
- package/lib/rating/themes/solar/charcoal/index.js +0 -1
- package/lib/rating/themes/solar/pearl/index.js +0 -1
- package/lib/rating/utils.d.ts +6 -6
- package/lib/rating/utils.js +6 -6
- package/lib/search-field/index.d.ts +2 -2
- package/lib/search-field/index.js +4 -4
- package/lib/search-field/themes/halo/dark/index.js +0 -1
- package/lib/search-field/themes/halo/light/index.js +0 -1
- package/lib/search-field/themes/solar/charcoal/index.js +0 -1
- package/lib/search-field/themes/solar/pearl/index.js +0 -1
- package/lib/select/index.d.ts +34 -34
- package/lib/select/index.js +70 -83
- package/lib/select/themes/halo/dark/index.js +0 -1
- package/lib/select/themes/halo/light/index.js +0 -1
- package/lib/select/themes/solar/charcoal/index.js +0 -1
- package/lib/select/themes/solar/pearl/index.js +0 -1
- package/lib/sidebar-layout/index.d.ts +2 -2
- package/lib/sidebar-layout/index.js +7 -9
- package/lib/sidebar-layout/themes/halo/dark/index.js +0 -1
- package/lib/sidebar-layout/themes/halo/light/index.js +0 -1
- package/lib/sidebar-layout/themes/solar/charcoal/index.js +0 -1
- package/lib/sidebar-layout/themes/solar/pearl/index.js +0 -1
- package/lib/slider/index.d.ts +2 -2
- package/lib/slider/index.js +72 -49
- package/lib/slider/themes/halo/dark/index.js +0 -1
- package/lib/slider/themes/halo/light/index.js +0 -1
- package/lib/slider/themes/solar/charcoal/index.js +0 -1
- package/lib/slider/themes/solar/pearl/index.js +0 -1
- package/lib/slider/utils.d.ts +10 -10
- package/lib/slider/utils.js +10 -10
- package/lib/sparkline/index.d.ts +1 -1
- package/lib/sparkline/index.js +7 -8
- package/lib/sparkline/themes/halo/dark/index.js +0 -1
- package/lib/sparkline/themes/halo/light/index.js +0 -1
- package/lib/sparkline/themes/solar/charcoal/index.js +0 -1
- package/lib/sparkline/themes/solar/pearl/index.js +0 -1
- package/lib/swing-gauge/helpers.js +2 -2
- package/lib/swing-gauge/index.d.ts +19 -19
- package/lib/swing-gauge/index.js +91 -81
- package/lib/swing-gauge/themes/halo/dark/index.js +0 -1
- package/lib/swing-gauge/themes/halo/light/index.js +0 -1
- package/lib/swing-gauge/themes/solar/charcoal/index.js +0 -1
- package/lib/swing-gauge/themes/solar/pearl/index.js +0 -1
- package/lib/tab/index.d.ts +1 -1
- package/lib/tab/index.js +16 -27
- package/lib/tab/themes/halo/dark/index.js +1 -2
- package/lib/tab/themes/halo/light/index.js +1 -2
- package/lib/tab/themes/solar/charcoal/index.js +1 -2
- package/lib/tab/themes/solar/pearl/index.js +1 -2
- package/lib/tab-bar/helpers/animate.js +1 -1
- package/lib/tab-bar/index.d.ts +1 -1
- package/lib/tab-bar/index.js +34 -18
- package/lib/tab-bar/themes/halo/dark/index.js +1 -2
- package/lib/tab-bar/themes/halo/light/index.js +1 -2
- package/lib/tab-bar/themes/solar/charcoal/index.js +0 -1
- package/lib/tab-bar/themes/solar/pearl/index.js +0 -1
- package/lib/text-field/index.d.ts +1 -1
- package/lib/text-field/index.js +36 -33
- package/lib/text-field/themes/halo/dark/index.js +0 -1
- package/lib/text-field/themes/halo/light/index.js +0 -1
- package/lib/text-field/themes/solar/charcoal/index.js +0 -1
- package/lib/text-field/themes/solar/pearl/index.js +0 -1
- package/lib/time-picker/index.d.ts +6 -6
- package/lib/time-picker/index.js +104 -90
- package/lib/time-picker/themes/halo/dark/index.js +0 -1
- package/lib/time-picker/themes/halo/light/index.js +0 -1
- package/lib/time-picker/themes/solar/charcoal/index.js +0 -1
- package/lib/time-picker/themes/solar/pearl/index.js +0 -1
- package/lib/toggle/index.d.ts +1 -1
- package/lib/toggle/index.js +4 -3
- package/lib/toggle/themes/halo/dark/index.js +1 -2
- package/lib/toggle/themes/halo/light/index.js +1 -2
- package/lib/toggle/themes/solar/charcoal/index.js +1 -2
- package/lib/toggle/themes/solar/pearl/index.js +1 -2
- package/lib/tooltip/elements/title-tooltip.js +2 -2
- package/lib/tooltip/helpers/renderer.d.ts +1 -1
- package/lib/tooltip/helpers/renderer.js +3 -3
- package/lib/tooltip/index.d.ts +27 -27
- package/lib/tooltip/index.js +42 -38
- package/lib/tooltip/managers/tooltip-manager.d.ts +1 -1
- package/lib/tooltip/themes/halo/dark/index.js +0 -1
- package/lib/tooltip/themes/halo/light/index.js +0 -1
- package/lib/tooltip/themes/solar/charcoal/index.js +0 -1
- package/lib/tooltip/themes/solar/pearl/index.js +0 -1
- package/lib/tornado-chart/elements/tornado-chart.d.ts +1 -1
- package/lib/tornado-chart/elements/tornado-chart.js +1 -1
- package/lib/tornado-chart/elements/tornado-item.d.ts +2 -2
- package/lib/tornado-chart/elements/tornado-item.js +12 -10
- package/lib/tornado-chart/themes/halo/dark/index.js +0 -2
- package/lib/tornado-chart/themes/halo/light/index.js +0 -2
- package/lib/tornado-chart/themes/solar/charcoal/index.js +0 -2
- package/lib/tornado-chart/themes/solar/pearl/index.js +0 -2
- package/lib/tree/elements/tree-item.d.ts +3 -3
- package/lib/tree/elements/tree-item.js +21 -19
- package/lib/tree/elements/tree.d.ts +1 -1
- package/lib/tree/elements/tree.js +12 -11
- package/lib/tree/helpers/renderer.js +4 -3
- package/lib/tree/index.d.ts +1 -1
- package/lib/tree/managers/tree-manager.d.ts +1 -1
- package/lib/tree/managers/tree-manager.js +17 -18
- package/lib/tree/themes/halo/dark/index.js +0 -2
- package/lib/tree/themes/halo/light/index.js +0 -2
- package/lib/tree/themes/solar/charcoal/index.js +1 -3
- package/lib/tree/themes/solar/pearl/index.js +1 -3
- package/lib/tree-select/index.d.ts +9 -9
- package/lib/tree-select/index.js +91 -82
- package/lib/tree-select/themes/halo/dark/index.js +1 -2
- package/lib/tree-select/themes/halo/light/index.js +1 -2
- package/lib/tree-select/themes/solar/charcoal/index.js +1 -2
- package/lib/tree-select/themes/solar/pearl/index.js +1 -2
- package/lib/version.js +1 -1
- package/package.json +19 -18
- package/tsconfig.tsbuildinfo +1 -0
- package/lib/config/custom-elements.json +0 -23
- package/lib/config/custom-elements.md +0 -8
- package/lib/config/helpers/context.js +0 -2
- package/lib/config/index.d.ts +0 -2
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Element Framework
|
|
2
2
|
|
|
3
|
-
Element Framework (EF) is a collection of elements that includes theming capability within the Refinitiv's design system. The elements are a set of web components which is a standard web technology and can be utilized across all browsers.
|
|
3
|
+
Element Framework (EF) is a collection of elements that includes theming capability within the Refinitiv Workspace's design system. The elements are a set of web components which is a standard web technology and can be utilized across all browsers.
|
|
4
4
|
|
|
5
5
|
## Usage
|
|
6
6
|
|
|
@@ -10,43 +10,44 @@ EF elements are published under single package.
|
|
|
10
10
|
npm install @refinitiv-ui/elements
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
The elements are required theme to instantiate itself in the app. Refinitiv's design system is called Halo theme and you can install it from npm command.
|
|
13
|
+
The elements are required theme to instantiate itself in the app. Refinitiv Workspace's design system is called Halo theme and you can install it from npm command.
|
|
14
14
|
|
|
15
15
|
```sh
|
|
16
16
|
npm install @refinitiv-ui/halo-theme
|
|
17
17
|
```
|
|
18
18
|
|
|
19
|
-
Finally, import both elements that you want to use and its themes into your application and it is ready to go. To follow Refinitiv design system, it is required styles of some native elements e.g. typography.
|
|
19
|
+
Finally, import both elements that you want to use and its themes into your application and it is ready to go. To follow Refinitiv Workspace's design system, it is required styles of some native elements e.g. typography.
|
|
20
20
|
|
|
21
21
|
<br>
|
|
22
22
|
|
|
23
|
-
>The font "Proxima Nova Fin" shall only be used within Refinitiv products or services. The copyright owner must approve any use of such font outside of Refinitiv products or services, which may be subject to a fee. Please see https://www.fontspring.com/lic/fontspring/webfont#license_text
|
|
23
|
+
> The font "Proxima Nova Fin" shall only be used within Refinitiv products or services. The copyright owner must approve any use of such font outside of Refinitiv products or services, which may be subject to a fee. Please see https://www.fontspring.com/lic/fontspring/webfont#license_text
|
|
24
24
|
|
|
25
25
|
<br>
|
|
26
26
|
|
|
27
27
|
```javascript
|
|
28
28
|
// import element and its Halo dark theme
|
|
29
29
|
import '@refinitiv-ui/elements/button';
|
|
30
|
+
import '@refinitiv-ui/elements/button/themes/halo/dark';
|
|
30
31
|
import '@refinitiv-ui/elements/panel';
|
|
32
|
+
import '@refinitiv-ui/elements/panel/themes/halo/dark';
|
|
33
|
+
|
|
31
34
|
// import native styles for typography, css variables, etc.
|
|
32
35
|
import '@refinitiv-ui/halo-theme/dark/imports/native-elements';
|
|
33
|
-
import '@refinitiv-ui/elements/button/themes/halo/dark';
|
|
34
|
-
import '@refinitiv-ui/elements/panel/themes/halo/dark';
|
|
35
36
|
```
|
|
36
37
|
|
|
37
38
|
Now, you can use the elements in your app.
|
|
38
39
|
|
|
39
40
|
```css
|
|
40
41
|
.content {
|
|
41
|
-
|
|
42
|
-
|
|
42
|
+
width: 100%;
|
|
43
|
+
height: 500px;
|
|
43
44
|
}
|
|
44
45
|
```
|
|
45
46
|
|
|
46
47
|
```html
|
|
47
48
|
<ef-panel class="content" spacing>
|
|
48
|
-
|
|
49
|
-
|
|
49
|
+
<h2>Hello EF!</h2>
|
|
50
|
+
<ef-button cta>OK</ef-button>
|
|
50
51
|
</ef-panel>
|
|
51
52
|
```
|
|
52
53
|
|
|
@@ -55,4 +56,5 @@ Now, you can use the elements in your app.
|
|
|
55
56
|
See list of elements, demo and more tutorial by visiting [EF Documentation](https://ui.refinitiv.com/).
|
|
56
57
|
|
|
57
58
|
# License
|
|
59
|
+
|
|
58
60
|
Apache License 2.0. However, Halo theme shall only be used within Refinitiv products or services due to license of the font "Proxima Nova Fin".
|
package/lib/accordion/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { JSXInterface } from '../jsx';
|
|
2
|
-
import { PropertyValues, TemplateResult
|
|
2
|
+
import { CSSResultGroup, PropertyValues, TemplateResult } from '@refinitiv-ui/core';
|
|
3
3
|
import { Collapse } from '../collapse/index.js';
|
|
4
4
|
/**
|
|
5
5
|
* Used to display a group of `Collapse` control.
|
package/lib/accordion/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { __decorate } from "tslib";
|
|
2
|
-
import {
|
|
2
|
+
import { css, html } from '@refinitiv-ui/core';
|
|
3
3
|
import { customElement } from '@refinitiv-ui/core/decorators/custom-element.js';
|
|
4
4
|
import { property } from '@refinitiv-ui/core/decorators/property.js';
|
|
5
|
-
import { VERSION } from '../version.js';
|
|
6
5
|
import { Collapse } from '../collapse/index.js';
|
|
6
|
+
import { VERSION } from '../version.js';
|
|
7
7
|
/**
|
|
8
8
|
* Finds closest accordion parent of element.
|
|
9
9
|
* Created, because IE11 doesn't support closest() method.
|
|
@@ -95,8 +95,7 @@ let Accordion = class Accordion extends Collapse {
|
|
|
95
95
|
* @returns array of accordion items
|
|
96
96
|
*/
|
|
97
97
|
getChildItems() {
|
|
98
|
-
return [...this.querySelectorAll('ef-collapse')]
|
|
99
|
-
.filter((el) => isDirectAccordionChild(el, this));
|
|
98
|
+
return [...this.querySelectorAll('ef-collapse')].filter((el) => isDirectAccordionChild(el, this));
|
|
100
99
|
}
|
|
101
100
|
/**
|
|
102
101
|
* collapse non selected child items on click
|
|
@@ -117,9 +116,7 @@ let Accordion = class Accordion extends Collapse {
|
|
|
117
116
|
* @return {TemplateResult} Render template
|
|
118
117
|
*/
|
|
119
118
|
render() {
|
|
120
|
-
return html `
|
|
121
|
-
<slot></slot>
|
|
122
|
-
`;
|
|
119
|
+
return html ` <slot></slot> `;
|
|
123
120
|
}
|
|
124
121
|
};
|
|
125
122
|
__decorate([
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/collapse/themes/halo/dark';
|
|
2
|
-
|
|
3
2
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-accordion', styles: ':host([spacing]) ::slotted(ef-collapse){--panel-padding:12px 8px}:host ::slotted(ef-collapse:not(:last-child):not([expanded])){border-bottom:1px solid #404040}' }}));
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/collapse/themes/halo/light';
|
|
2
|
-
|
|
3
2
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-accordion', styles: ':host([spacing]) ::slotted(ef-collapse){--panel-padding:12px 8px}:host ::slotted(ef-collapse:not(:last-child):not([expanded])){border-bottom:1px solid #d9d9d9}' }}));
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/collapse/themes/solar/charcoal';
|
|
2
|
-
|
|
3
2
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-accordion', styles: ':host([spacing]) ::slotted(ef-collapse){--panel-padding:6px 10px}:host ::slotted(ef-collapse:not(:last-child):not([expanded])){border-bottom:1px solid #0a0a0a}' }}));
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/collapse/themes/solar/pearl';
|
|
2
|
-
|
|
3
2
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-accordion', styles: ':host([spacing]) ::slotted(ef-collapse){--panel-padding:6px 10px}:host ::slotted(ef-collapse:not(:last-child):not([expanded])){border-bottom:1px solid #d5d8db}' }}));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { JSXInterface } from '../jsx';
|
|
2
|
-
import { BasicElement,
|
|
3
|
-
import { Translate } from '@refinitiv-ui/translate';
|
|
2
|
+
import { BasicElement, CSSResultGroup, PropertyValues, TemplateResult } from '@refinitiv-ui/core';
|
|
4
3
|
import '@refinitiv-ui/phrasebook/locale/en/appstate-bar.js';
|
|
4
|
+
import { Translate } from '@refinitiv-ui/translate';
|
|
5
5
|
import '../icon/index.js';
|
|
6
6
|
/**
|
|
7
7
|
* Used to display at the top of application to provide a status or information.
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { __decorate } from "tslib";
|
|
2
|
-
import { BasicElement,
|
|
2
|
+
import { BasicElement, css, html } from '@refinitiv-ui/core';
|
|
3
3
|
import { customElement } from '@refinitiv-ui/core/decorators/custom-element.js';
|
|
4
4
|
import { property } from '@refinitiv-ui/core/decorators/property.js';
|
|
5
|
-
import { VERSION } from '../version.js';
|
|
6
|
-
import { translate } from '@refinitiv-ui/translate';
|
|
7
5
|
import '@refinitiv-ui/phrasebook/locale/en/appstate-bar.js';
|
|
6
|
+
import { translate } from '@refinitiv-ui/translate';
|
|
8
7
|
import '../icon/index.js';
|
|
8
|
+
import { VERSION } from '../version.js';
|
|
9
9
|
/**
|
|
10
10
|
* Used to display at the top of application to provide a status or information.
|
|
11
11
|
* @slot right - Place custom content on the right of bar.
|
|
@@ -78,7 +78,13 @@ let AppstateBar = class AppstateBar extends BasicElement {
|
|
|
78
78
|
<div part="heading">${this.heading}</div>
|
|
79
79
|
<div part="message"><slot></slot></div>
|
|
80
80
|
<div part="right"><slot name="right"></slot></div>
|
|
81
|
-
<ef-icon
|
|
81
|
+
<ef-icon
|
|
82
|
+
role="button"
|
|
83
|
+
part="close"
|
|
84
|
+
@tap="${this.clear}"
|
|
85
|
+
icon="cross"
|
|
86
|
+
aria-label="${this.t('CLOSE')}"
|
|
87
|
+
></ef-icon>
|
|
82
88
|
`;
|
|
83
89
|
}
|
|
84
90
|
};
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/icon/themes/halo/dark';
|
|
2
|
-
|
|
3
2
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-appstate-bar', styles: ':host{--heading-text-color:#CCCCCC;--heading-background-color:#334BFF;--text-color:#000000;--background-color:hsl(236, 77%, 92%);--border-color:#404040;display:flex;align-items:center;background:var(--background-color);color:var(--text-color);outline:solid 1px var(--border-color);font-size:12px;height:28px;--heading-text-color:#FFFFFF;--heading-background-color:#0F1E8A;--text-color:#CCCCCC;--background-color:#262626}:host([state=highlight]){--heading-background-color:hsl(337, 80%, 49%);--heading-background-color:#334BFF}:host([state=info]){--heading-background-color:#6678FF;--heading-background-color:#007678}:host ::slotted(*){padding-right:10px}:host [part=heading]{display:flex;flex:0 0 auto;align-items:center;height:100%;text-transform:uppercase;font-weight:600;background:var(--heading-background-color);color:var(--heading-text-color);padding:0 8px}:host [part=message]{flex:1 1000000 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding-left:10px;text-align:inherit}:host [part=right]{flex:0 1 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host [part=close]{touch-action:manipulation;flex:0 0 auto;width:16px;height:16px;margin-right:10px;stroke-width:.11em;cursor:pointer}' }}));
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/icon/themes/halo/light';
|
|
2
|
-
|
|
3
2
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-appstate-bar', styles: ':host{--heading-text-color:#0D0D0D;--heading-background-color:#334BFF;--text-color:#000000;--background-color:hsl(236, 77%, 92%);--border-color:#595959;display:flex;align-items:center;background:var(--background-color);color:var(--text-color);outline:solid 1px var(--border-color);font-size:12px;height:28px;--heading-text-color:#FFFFFF;--heading-background-color:#0F1E8A;--text-color:#0D0D0D;--background-color:#F2F2F2;--border-color:#CCCCCC}:host([state=highlight]){--heading-background-color:hsl(337, 80%, 49%);--heading-background-color:#334BFF}:host([state=info]){--heading-background-color:#6678FF;--heading-background-color:#007678}:host ::slotted(*){padding-right:10px}:host [part=heading]{display:flex;flex:0 0 auto;align-items:center;height:100%;text-transform:uppercase;font-weight:600;background:var(--heading-background-color);color:var(--heading-text-color);padding:0 8px}:host [part=message]{flex:1 1000000 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding-left:10px;text-align:inherit}:host [part=right]{flex:0 1 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host [part=close]{touch-action:manipulation;flex:0 0 auto;width:16px;height:16px;margin-right:10px;stroke-width:.11em;cursor:pointer}' }}));
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/icon/themes/solar/charcoal';
|
|
2
|
-
|
|
3
2
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-appstate-bar', styles: ':host{--heading-text-color:#E2E2E2;--heading-background-color:#FF9933;--text-color:#000000;--background-color:hsl(236, 77%, 92%);--border-color:#4A4A52;display:flex;align-items:center;background:var(--background-color);color:var(--text-color);outline:solid 1px var(--border-color);font-size:14px;--heading-text-color:#46A0F0;--heading-background-color:#142E45;--text-color:#C2C2C2;--background-color:#0F2233;--border-color:#000000;height:24px}:host([state=highlight]){--heading-background-color:hsl(337, 80%, 49%);--heading-text-color:#000000;--heading-background-color:#FF9933}:host([state=info]){--heading-background-color:#b35900;--heading-text-color:#C2C2C2;--heading-background-color:#282E33}:host ::slotted(*){padding-right:10px}:host [part=heading]{display:flex;flex:0 0 auto;align-items:center;height:100%;text-transform:uppercase;font-weight:600;background:var(--heading-background-color);color:var(--heading-text-color);padding:0 10px}:host [part=message]{flex:1 1000000 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding-left:10px;text-align:inherit}:host [part=right]{flex:0 1 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host [part=close]{touch-action:manipulation;flex:0 0 auto;margin-right:10px;stroke-width:.11em;cursor:pointer;width:15px;height:15px;stroke-width:.12em}' }}));
|
|
@@ -1,3 +1,2 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/icon/themes/solar/pearl';
|
|
2
|
-
|
|
3
2
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-appstate-bar', styles: ':host{--heading-text-color:#484848;--heading-background-color:#FF9933;--text-color:#000000;--background-color:hsl(236, 77%, 92%);--border-color:#A9AFBA;display:flex;align-items:center;background:var(--background-color);color:var(--text-color);outline:solid 1px var(--border-color);font-size:14px;--heading-text-color:#FFFFFF;--heading-background-color:#2A6090;--text-color:#484848;--background-color:#C1E3FE;--border-color:#FFFFFF;height:24px}:host([state=highlight]){--heading-background-color:hsl(337, 80%, 49%);--heading-text-color:#FFFFFF;--heading-background-color:#CC7F33}:host([state=info]){--heading-background-color:#EE7600;--heading-text-color:#FFFFFF;--heading-background-color:#666570}:host ::slotted(*){padding-right:10px}:host [part=heading]{display:flex;flex:0 0 auto;align-items:center;height:100%;text-transform:uppercase;font-weight:600;background:var(--heading-background-color);color:var(--heading-text-color);padding:0 10px}:host [part=message]{flex:1 1000000 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;padding-left:10px;text-align:inherit}:host [part=right]{flex:0 1 auto;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}:host [part=close]{touch-action:manipulation;flex:0 0 auto;margin-right:10px;stroke-width:.11em;cursor:pointer;width:15px;height:15px;stroke-width:.12em}' }}));
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { JSXInterface } from '../jsx';
|
|
2
2
|
import { CSSResultGroup, ElementSize, PropertyValues, TemplateResult } from '@refinitiv-ui/core';
|
|
3
|
+
import '@refinitiv-ui/phrasebook/locale/en/autosuggest.js';
|
|
3
4
|
import { TranslateDirective } from '@refinitiv-ui/translate';
|
|
4
|
-
import type { AutosuggestTargetElement, AutosuggestHighlightable, AutosuggestMethodType, AutosuggestQuery, AutosuggestRenderer, AutosuggestReason, AutosuggestItem, AutosuggestSelectItemEvent, AutosuggestHighlightItemEvent } from './helpers/types';
|
|
5
|
-
import { escapeRegExp, itemHighlightable, queryWordSelect } from './helpers/utils.js';
|
|
6
|
-
import { renderer } from './helpers/renderer.js';
|
|
7
|
-
import { Overlay } from '../overlay/index.js';
|
|
8
|
-
import '../loader/index.js';
|
|
9
5
|
import '../item/index.js';
|
|
10
|
-
import '
|
|
11
|
-
import
|
|
6
|
+
import '../loader/index.js';
|
|
7
|
+
import { Overlay } from '../overlay/index.js';
|
|
8
|
+
import { renderer } from './helpers/renderer.js';
|
|
9
|
+
import { escapeRegExp, itemHighlightable, queryWordSelect } from './helpers/utils.js';
|
|
10
|
+
import type { AutosuggestHighlightItemEvent, AutosuggestHighlightable, AutosuggestItem, AutosuggestMethodType, AutosuggestQuery, AutosuggestReason, AutosuggestRenderer, AutosuggestSelectItemEvent, AutosuggestTargetElement } from './helpers/types';
|
|
11
|
+
import type { AddAttachTargetEventsEvent, ItemHighlightEvent, ItemSelectEvent, RemoveAttachTargetEventsEvent, SuggestionsChangedEvent, SuggestionsClearRequestedEvent, SuggestionsFetchRequestedEvent, SuggestionsQueryEvent } from './helpers/types';
|
|
12
12
|
export type { AutosuggestTargetElement, AutosuggestHighlightable, AutosuggestMethodType, AutosuggestQuery, AutosuggestRenderer, AutosuggestReason, AutosuggestItem, ItemHighlightEvent, AddAttachTargetEventsEvent, RemoveAttachTargetEventsEvent, ItemSelectEvent, SuggestionsFetchRequestedEvent, SuggestionsClearRequestedEvent, SuggestionsQueryEvent, SuggestionsChangedEvent };
|
|
13
13
|
export { updateElementContent } from './helpers/utils.js';
|
|
14
14
|
export { itemHighlightable, escapeRegExp, queryWordSelect, renderer, renderer as itemRenderer };
|
package/lib/autosuggest/index.js
CHANGED
|
@@ -2,20 +2,20 @@ var Autosuggest_1;
|
|
|
2
2
|
import { __decorate } from "tslib";
|
|
3
3
|
import { css, html } from '@refinitiv-ui/core';
|
|
4
4
|
import { customElement } from '@refinitiv-ui/core/decorators/custom-element.js';
|
|
5
|
-
import { query } from '@refinitiv-ui/core/decorators/query.js';
|
|
6
5
|
import { property } from '@refinitiv-ui/core/decorators/property.js';
|
|
7
|
-
import {
|
|
6
|
+
import { query } from '@refinitiv-ui/core/decorators/query.js';
|
|
7
|
+
import { createRef, ref } from '@refinitiv-ui/core/directives/ref.js';
|
|
8
8
|
import { unsafeHTML } from '@refinitiv-ui/core/directives/unsafe-html.js';
|
|
9
|
-
import
|
|
9
|
+
import '@refinitiv-ui/phrasebook/locale/en/autosuggest.js';
|
|
10
|
+
import { TranslatePropertyKey, translate } from '@refinitiv-ui/translate';
|
|
10
11
|
import { AnimationTaskRunner, TimeoutTaskRunner } from '@refinitiv-ui/utils/async.js';
|
|
11
12
|
import { isIE, isMobile } from '@refinitiv-ui/utils/browser.js';
|
|
12
|
-
import { translate, TranslatePropertyKey } from '@refinitiv-ui/translate';
|
|
13
|
-
import { escapeRegExp, itemHighlightable, queryWordSelect } from './helpers/utils.js';
|
|
14
|
-
import { renderer } from './helpers/renderer.js';
|
|
15
|
-
import { Overlay } from '../overlay/index.js';
|
|
16
|
-
import '../loader/index.js';
|
|
17
13
|
import '../item/index.js';
|
|
18
|
-
import '
|
|
14
|
+
import '../loader/index.js';
|
|
15
|
+
import { Overlay } from '../overlay/index.js';
|
|
16
|
+
import { VERSION } from '../version.js';
|
|
17
|
+
import { renderer } from './helpers/renderer.js';
|
|
18
|
+
import { escapeRegExp, itemHighlightable, queryWordSelect } from './helpers/utils.js';
|
|
19
19
|
export { updateElementContent } from './helpers/utils.js';
|
|
20
20
|
export { itemHighlightable, escapeRegExp, queryWordSelect, renderer, renderer as itemRenderer // compatibility
|
|
21
21
|
};
|
|
@@ -64,13 +64,14 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
64
64
|
display: flex;
|
|
65
65
|
flex-direction: column;
|
|
66
66
|
}
|
|
67
|
-
[part=content] {
|
|
67
|
+
[part='content'] {
|
|
68
68
|
flex: 1 1 auto;
|
|
69
69
|
overflow-x: hidden;
|
|
70
70
|
overflow-y: auto;
|
|
71
71
|
-webkit-overflow-scrolling: touch;
|
|
72
72
|
}
|
|
73
|
-
[part=header],
|
|
73
|
+
[part='header'],
|
|
74
|
+
[part='footer'] {
|
|
74
75
|
flex: none;
|
|
75
76
|
}
|
|
76
77
|
`
|
|
@@ -190,76 +191,76 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
190
191
|
// TODO: think of a nicer way to do this
|
|
191
192
|
this.xmlSerializer = null;
|
|
192
193
|
/**
|
|
193
|
-
|
|
194
|
-
|
|
194
|
+
* @ignore
|
|
195
|
+
*/
|
|
195
196
|
this.position = ['bottom-start', 'top-start', 'right-middle'];
|
|
196
197
|
/**
|
|
197
|
-
|
|
198
|
-
|
|
198
|
+
* @ignore
|
|
199
|
+
*/
|
|
199
200
|
this.noCancelOnEscKey = true;
|
|
200
201
|
/**
|
|
201
|
-
|
|
202
|
-
|
|
202
|
+
* @ignore
|
|
203
|
+
*/
|
|
203
204
|
this.noCancelOnOutsideClick = true;
|
|
204
205
|
/**
|
|
205
|
-
|
|
206
|
-
|
|
206
|
+
* @ignore
|
|
207
|
+
*/
|
|
207
208
|
this.noAutofocus = true;
|
|
208
209
|
/**
|
|
209
|
-
|
|
210
|
-
|
|
210
|
+
* @ignore
|
|
211
|
+
*/
|
|
211
212
|
this.noOverlap = true;
|
|
212
213
|
/**
|
|
213
|
-
|
|
214
|
-
|
|
214
|
+
* @ignore
|
|
215
|
+
*/
|
|
215
216
|
this.withShadow = false;
|
|
216
217
|
/**
|
|
217
218
|
* @ignore
|
|
218
219
|
*/
|
|
219
220
|
this.noFocusManagement = true;
|
|
220
221
|
/**
|
|
221
|
-
|
|
222
|
-
|
|
222
|
+
* @ignore
|
|
223
|
+
*/
|
|
223
224
|
this.onInputValueChange = this.onInputValueChange.bind(this);
|
|
224
225
|
/**
|
|
225
|
-
|
|
226
|
-
|
|
226
|
+
* @ignore
|
|
227
|
+
*/
|
|
227
228
|
this.onInputKeyDown = this.onInputKeyDown.bind(this);
|
|
228
229
|
/**
|
|
229
|
-
|
|
230
|
-
|
|
230
|
+
* @ignore
|
|
231
|
+
*/
|
|
231
232
|
this.onInputBlur = this.onInputBlur.bind(this);
|
|
232
233
|
/**
|
|
233
|
-
|
|
234
|
-
|
|
234
|
+
* @ignore
|
|
235
|
+
*/
|
|
235
236
|
this.onInputFocus = this.onInputFocus.bind(this);
|
|
236
237
|
/**
|
|
237
|
-
|
|
238
|
-
|
|
238
|
+
* @ignore
|
|
239
|
+
*/
|
|
239
240
|
this.suggestionsQueryAction = this.suggestionsQueryAction.bind(this);
|
|
240
241
|
/**
|
|
241
|
-
|
|
242
|
-
|
|
242
|
+
* @ignore
|
|
243
|
+
*/
|
|
243
244
|
this.itemSelectAction = this.itemSelectAction.bind(this);
|
|
244
245
|
/**
|
|
245
|
-
|
|
246
|
-
|
|
246
|
+
* @ignore
|
|
247
|
+
*/
|
|
247
248
|
this.itemHighlightAction = this.itemHighlightAction.bind(this);
|
|
248
249
|
/**
|
|
249
|
-
|
|
250
|
-
|
|
250
|
+
* @ignore
|
|
251
|
+
*/
|
|
251
252
|
this.suggestionsFetchRequestedAction = this.suggestionsFetchRequestedAction.bind(this);
|
|
252
253
|
/**
|
|
253
|
-
|
|
254
|
-
|
|
254
|
+
* @ignore
|
|
255
|
+
*/
|
|
255
256
|
this.suggestionsClearRequestedAction = this.suggestionsClearRequestedAction.bind(this);
|
|
256
257
|
/**
|
|
257
|
-
|
|
258
|
-
|
|
258
|
+
* @ignore
|
|
259
|
+
*/
|
|
259
260
|
this.attachEventsAddAction = this.attachEventsAddAction.bind(this);
|
|
260
261
|
/**
|
|
261
|
-
|
|
262
|
-
|
|
262
|
+
* @ignore
|
|
263
|
+
*/
|
|
263
264
|
this.attachEventsRemoveAction = this.attachEventsRemoveAction.bind(this);
|
|
264
265
|
/**
|
|
265
266
|
* @ignore
|
|
@@ -280,7 +281,8 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
280
281
|
* @returns {void}
|
|
281
282
|
*/
|
|
282
283
|
onInputValueChange(event) {
|
|
283
|
-
if (!this.suspended) {
|
|
284
|
+
if (!this.suspended) {
|
|
285
|
+
// avoid circular
|
|
284
286
|
/* istanbul ignore next */
|
|
285
287
|
if (isMobile) {
|
|
286
288
|
this.lastActiveElement = event.target;
|
|
@@ -398,7 +400,7 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
398
400
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
399
401
|
onSlotChange(event) {
|
|
400
402
|
const contentSlot = this.contentSlotRef.value;
|
|
401
|
-
const nodes =
|
|
403
|
+
const nodes = contentSlot?.assignedNodes() ?? [];
|
|
402
404
|
this.setOpened(this.attachTargetFocused && this.hasContent);
|
|
403
405
|
// make a brave assumption that suggestions are populated as well
|
|
404
406
|
const suggestions = this.suggestions;
|
|
@@ -433,7 +435,7 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
433
435
|
const { detail: { query, suggestion } } = event;
|
|
434
436
|
/* istanbul ignore next */
|
|
435
437
|
if (this.attachTarget) {
|
|
436
|
-
this.attachTarget.value = suggestion && suggestion?.label || query;
|
|
438
|
+
this.attachTarget.value = (suggestion && suggestion?.label) || query;
|
|
437
439
|
}
|
|
438
440
|
}
|
|
439
441
|
/**
|
|
@@ -559,12 +561,14 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
559
561
|
}
|
|
560
562
|
const query = this.xmlSerializer.serializeToString(document.createTextNode(this.query ? this.query.toString() : ''));
|
|
561
563
|
return html `
|
|
562
|
-
<span part="more-results-text"
|
|
564
|
+
<span part="more-results-text"
|
|
565
|
+
>${this.moreSearchText
|
|
563
566
|
? unsafeHTML(this.moreSearchText.replace(/{0\}/g, `<mark>${query}</mark>`))
|
|
564
567
|
: this.t('MORE_RESULTS', {
|
|
565
568
|
query,
|
|
566
569
|
mark: (chunks) => `<mark>${chunks}</mark>`
|
|
567
|
-
})}</span
|
|
570
|
+
})}</span
|
|
571
|
+
>
|
|
568
572
|
<span part="more-results-keys" slot="right"><kbd>SHIFT</kbd> + <kbd>ENTER</kbd></span>
|
|
569
573
|
`;
|
|
570
574
|
}
|
|
@@ -577,7 +581,8 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
577
581
|
*/
|
|
578
582
|
requestSuggestions(reason, debounce = false) {
|
|
579
583
|
this.dispatchSuggestionsQuery(reason);
|
|
580
|
-
if (this.preservedQueryValue === this.query) {
|
|
584
|
+
if (this.preservedQueryValue === this.query) {
|
|
585
|
+
// if the query is the same do not re-issue the request, instead try to open auto suggest
|
|
581
586
|
if (!this.opened && ((this.suggestions && this.suggestions.length) || this.moreResults)) {
|
|
582
587
|
this.setOpened(true);
|
|
583
588
|
}
|
|
@@ -752,6 +757,7 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
752
757
|
get renderedSuggestions() {
|
|
753
758
|
const keys = [];
|
|
754
759
|
this.suggestionMap.forEach((value, key) => {
|
|
760
|
+
// support IE11
|
|
755
761
|
keys.push(key);
|
|
756
762
|
});
|
|
757
763
|
if (this.moreResults && this.moreResultsItem) {
|
|
@@ -784,13 +790,13 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
784
790
|
* @returns true if some of changedProperties modified
|
|
785
791
|
*/
|
|
786
792
|
shouldAutosuggestUpdate(changedProperties) {
|
|
787
|
-
return changedProperties.has('attach')
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
793
|
+
return (changedProperties.has('attach') ||
|
|
794
|
+
changedProperties.has('suggestions') ||
|
|
795
|
+
changedProperties.has('moreResults') ||
|
|
796
|
+
changedProperties.has('moreSearchText') ||
|
|
797
|
+
changedProperties.has('loading') ||
|
|
798
|
+
changedProperties.has('debounceRate') ||
|
|
799
|
+
changedProperties.has(TranslatePropertyKey));
|
|
794
800
|
}
|
|
795
801
|
/**
|
|
796
802
|
* Run when document click event happens.
|
|
@@ -897,8 +903,8 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
897
903
|
*/
|
|
898
904
|
suggestionsChange() {
|
|
899
905
|
const contentSlot = this.contentSlotRef.value;
|
|
900
|
-
contentSlot
|
|
901
|
-
node.parentNode
|
|
906
|
+
contentSlot?.assignedNodes().forEach((node) => {
|
|
907
|
+
node.parentNode?.removeChild(node);
|
|
902
908
|
});
|
|
903
909
|
this.appendChild(this.suggestions.reduce((fragment, suggestion) => this.generateSuggestionsFragment(fragment, suggestion), document.createDocumentFragment()));
|
|
904
910
|
}
|
|
@@ -1000,7 +1006,7 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
1000
1006
|
* @returns focused true if attach target is focused
|
|
1001
1007
|
*/
|
|
1002
1008
|
get attachTargetFocused() {
|
|
1003
|
-
return this.isFocused(document.activeElement) || this.attachTarget === this.lastActiveElement;
|
|
1009
|
+
return (this.isFocused(document.activeElement) || this.attachTarget === this.lastActiveElement);
|
|
1004
1010
|
}
|
|
1005
1011
|
/**
|
|
1006
1012
|
* Walk through shadowDOM to find activeElement
|
|
@@ -1026,7 +1032,7 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
1026
1032
|
}
|
|
1027
1033
|
// Space characters (e.g. space, tab, EOL) don't count as having content
|
|
1028
1034
|
const contentSlot = this.contentSlotRef.value;
|
|
1029
|
-
const nodes = contentSlot
|
|
1035
|
+
const nodes = contentSlot?.assignedNodes() ?? [];
|
|
1030
1036
|
return nodes.some(({ nodeType, textContent }) => nodeType === Node.ELEMENT_NODE || (textContent && textContent.search(/\S/) >= 0)); // If node is element always return true
|
|
1031
1037
|
}
|
|
1032
1038
|
/**
|
|
@@ -1097,6 +1103,7 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
1097
1103
|
if (focusElement) {
|
|
1098
1104
|
this.highlightItem(focusElement, false);
|
|
1099
1105
|
focusElement.scrollIntoView({
|
|
1106
|
+
// TODO: this has different behaviour in IE11
|
|
1100
1107
|
behavior: 'auto',
|
|
1101
1108
|
block: 'nearest'
|
|
1102
1109
|
});
|
|
@@ -1185,10 +1192,9 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
1185
1192
|
return null;
|
|
1186
1193
|
}
|
|
1187
1194
|
return html `
|
|
1188
|
-
<ef-item tabIndex="-1"
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
part="more-results">${this.moreResultsTextTemplate}</ef-item>
|
|
1195
|
+
<ef-item tabIndex="-1" role="option" id="moreResults" part="more-results"
|
|
1196
|
+
>${this.moreResultsTextTemplate}</ef-item
|
|
1197
|
+
>
|
|
1192
1198
|
`;
|
|
1193
1199
|
}
|
|
1194
1200
|
/**
|
|
@@ -1198,24 +1204,23 @@ let Autosuggest = Autosuggest_1 = class Autosuggest extends Overlay {
|
|
|
1198
1204
|
*/
|
|
1199
1205
|
render() {
|
|
1200
1206
|
return html `
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
${this.loaderTemplate}
|
|
1207
|
+
<div ${ref(this.headerElementRef)} part="header">
|
|
1208
|
+
<slot id="headerSlot" name="header"></slot>
|
|
1209
|
+
</div>
|
|
1210
|
+
<div
|
|
1211
|
+
${ref(this.contentElementRef)}
|
|
1212
|
+
part="content"
|
|
1213
|
+
@mousemove="${this.onItemMouseMove}"
|
|
1214
|
+
@mouseleave="${this.onItemMouseLeave}"
|
|
1215
|
+
@tap="${this.onItemMouseClick}"
|
|
1216
|
+
>
|
|
1217
|
+
<slot ${ref(this.contentSlotRef)} @slotchange="${this.onSlotChange}"></slot>
|
|
1218
|
+
${this.moreResultsTemplate}
|
|
1219
|
+
</div>
|
|
1220
|
+
<div ${ref(this.footerElementRef)} part="footer">
|
|
1221
|
+
<slot id="footerSlot" name="footer"></slot>
|
|
1222
|
+
</div>
|
|
1223
|
+
${this.loaderTemplate}
|
|
1219
1224
|
`;
|
|
1220
1225
|
}
|
|
1221
1226
|
/**
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/item/themes/halo/dark';
|
|
2
2
|
import '@refinitiv-ui/elements/overlay/themes/halo/dark';
|
|
3
3
|
import '@refinitiv-ui/elements/loader/themes/halo/dark';
|
|
4
|
-
|
|
5
4
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-autosuggest', styles: 'mark{color:#fff;background-color:#334bff}:host{min-height:0;max-height:350px;border:1px solid #404040;background-color:#0d0d0d}:host([loading]){min-height:50px;min-width:150px}:host [part=content]{overflow:auto;touch-action:manipulation;scrollbar-face-color:#595959;scrollbar-shadow-color:#595959;scrollbar-highlight-color:#595959;scrollbar-arrow-color:#595959;scrollbar-track-color:#1a1a1a;scrollbar-3dlight-color:#1a1a1a;scrollbar-darkshadow-color:#1a1a1a;scrollbar-color:#595959 #1a1a1a;scrollbar-width:thin}:host [part=more-results]{border-top:1px solid #404040}:host [part=more-results] mark{background-color:inherit;font-weight:500}:host [part=more-results-text]{font-size:.76em;font-size:inherit}:host [part=more-results-keys],:host [part=more-results] mark{color:#fff}:host [part=loader]{top:0;bottom:0;left:0;right:0;position:absolute}:host [part=backdrop]{background-color:#000;opacity:.6;width:100%;height:100%}::-webkit-scrollbar-corner{background:0 0}::-webkit-scrollbar{width:8px;height:8px}::-webkit-scrollbar-thumb{background:#595959;border-radius:0;border:1px solid transparent}::-webkit-scrollbar-thumb:hover{background:#1429bd}::-webkit-scrollbar-thumb:active{background:#0f1e8a}::-webkit-scrollbar-track{background:#1a1a1a}::-webkit-scrollbar-thumb:horizontal{background-size:auto 6px;background-repeat:repeat-x;background-image:linear-gradient(to bottom,#595959,#595959);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:horizontal:hover{background-image:linear-gradient(to bottom,#1429bd,#1429bd);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:horizontal:active{background-image:linear-gradient(to bottom,#0f1e8a,#0f1e8a);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:vertical{background-size:6px auto;background-repeat:repeat-y;background-image:linear-gradient(to right,#595959,#595959);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:vertical:hover{background-image:linear-gradient(to right,#1429bd,#1429bd);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:vertical:active{background-image:linear-gradient(to right,#0f1e8a,#0f1e8a);background-color:transparent;background-position:center}::-webkit-scrollbar-track:horizontal{border-top:1px solid #0d0d0d;border-bottom:1px solid #0d0d0d}::-webkit-scrollbar-track:vertical{border-left:1px solid #0d0d0d;border-right:1px solid #0d0d0d}::-webkit-scrollbar-button{background:0 0/1px 2px no-repeat #1a1a1a;height:16px;width:16px;display:none;border:1px solid #0d0d0d}::-webkit-scrollbar-button:end:decrement,::-webkit-scrollbar-button:start:increment{display:none}::-webkit-scrollbar-button:hover{background-color:#1429bd;border:1px solid #1429bd}::-webkit-scrollbar-button:active{background-color:#0f1e8a;border:1px solid #0d0d0d}::-webkit-scrollbar-button:horizontal{background-size:2px 1px}::-webkit-scrollbar-button:vertical:start:decrement{border-bottom-color:#0d0d0d;background-image:linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc);background-position:10.55px 8px,9.55px 7px,8.55px 6px,7.55px 5px,6.55px 4px,5.55px 5px,4.55px 6px,3.55px 7px,2.55px 8px}::-webkit-scrollbar-button:vertical:start:decrement:hover{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:10.55px 8px,9.55px 7px,8.55px 6px,7.55px 5px,6.55px 4px,5.55px 5px,4.55px 6px,3.55px 7px,2.55px 8px;border-bottom-color:#1429bd}::-webkit-scrollbar-button:vertical:start:decrement:active{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:10.55px 8px,9.55px 7px,8.55px 6px,7.55px 5px,6.55px 4px,5.55px 5px,4.55px 6px,3.55px 7px,2.55px 8px;border-bottom-color:#0d0d0d}::-webkit-scrollbar-button:vertical:end:increment{border-top-color:#0d0d0d;background-image:linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc);background-position:10.55px 4px,9.55px 5px,8.55px 6px,7.55px 7px,6.55px 8px,5.55px 7px,4.55px 6px,3.55px 5px,2.55px 4px}::-webkit-scrollbar-button:vertical:end:increment:hover{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:10.55px 4px,9.55px 5px,8.55px 6px,7.55px 7px,6.55px 8px,5.55px 7px,4.55px 6px,3.55px 5px,2.55px 4px;border-top-color:#1429bd}::-webkit-scrollbar-button:vertical:end:increment:active{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:10.55px 4px,9.55px 5px,8.55px 6px,7.55px 7px,6.55px 8px,5.55px 7px,4.55px 6px,3.55px 5px,2.55px 4px;border-top-color:#0d0d0d}::-webkit-scrollbar-button:horizontal:start:decrement{border-right-color:#0d0d0d;background-image:linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc);background-position:7.5px 10.55px,6.5px 9.55px,5.5px 8.55px,4.5px 7.55px,3.5px 6.55px,4.5px 5.55px,5.5px 4.55px,6.5px 3.55px,7.5px 2.55px}::-webkit-scrollbar-button:horizontal:start:decrement:hover{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:7.5px 10.55px,6.5px 9.55px,5.5px 8.55px,4.5px 7.55px,3.5px 6.55px,4.5px 5.55px,5.5px 4.55px,6.5px 3.55px,7.5px 2.55px;border-right-color:#1429bd}::-webkit-scrollbar-button:horizontal:start:decrement:active{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:7.5px 10.55px,6.5px 9.55px,5.5px 8.55px,4.5px 7.55px,3.5px 6.55px,4.5px 5.55px,5.5px 4.55px,6.5px 3.55px,7.5px 2.55px;border-right-color:#0d0d0d}::-webkit-scrollbar-button:horizontal:end:increment{border-left-color:#0d0d0d;background-image:linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc),linear-gradient(#ccc,#ccc);background-position:5px 10.55px,6px 9.55px,7px 8.55px,8px 7.55px,9px 6.55px,8px 5.55px,7px 4.55px,6px 3.55px,5px 2.55px}::-webkit-scrollbar-button:horizontal:end:increment:hover{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:5px 10.55px,6px 9.55px,7px 8.55px,8px 7.55px,9px 6.55px,8px 5.55px,7px 4.55px,6px 3.55px,5px 2.55px;border-left-color:#1429bd}::-webkit-scrollbar-button:horizontal:end:increment:active{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:5px 10.55px,6px 9.55px,7px 8.55px,8px 7.55px,9px 6.55px,8px 5.55px,7px 4.55px,6px 3.55px,5px 2.55px;border-left-color:#0d0d0d}kbd{font-family:inherit;justify-content:center;align-items:center;vertical-align:middle;box-sizing:border-box;box-shadow:0 1px 3px rgba(0,0,0,.3);min-width:1.33em;display:inline-block;color:#fff;background-color:#404040;box-shadow:0 0 0 2px #404040;font-weight:600;font-family:inherit;font-size:.83333333em;border-radius:1em;padding:0 .5em;height:1.2em;margin-top:-.1em}:host{border-color:#334bff;margin:2px 0}:host [part=content] ::slotted(ef-item:not([part=more-results])){background-color:#262626}:host [part=content] ::slotted(ef-item:not([type=header]):not([part=more-results])){color:#ccc}:host [part=content] ::slotted(ef-item:not([part=more-results]):not(:first-child)){box-shadow:0 -1px 0 #404040}:host [part=content] ::slotted(ef-item:not([part=more-results]):focus),:host [part=content] ::slotted(ef-item:not([part=more-results])[highlighted]){background-color:#333}:host [part=content] ::slotted(ef-item:not([part=more-results]):focus:not([selected])),:host [part=content] ::slotted(ef-item:not([part=more-results])[highlighted]:not([selected])){color:#fff}:host [part=more-results]{border-top-color:#404040;color:#ccc;background-color:#1a1a1a}:host [part=more-results]:focus,:host [part=more-results][highlighted]{background-color:#333;color:#ccc}:host [part=more-results-keys] kbd{margin-left:4px;margin-right:4px}:host [part=more-results-keys] kbd:first-of-type{margin-left:0}:host [part=more-results-keys] kbd:last-of-type{margin-right:0}' }}));
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import '@refinitiv-ui/elements/item/themes/halo/light';
|
|
2
2
|
import '@refinitiv-ui/elements/overlay/themes/halo/light';
|
|
3
3
|
import '@refinitiv-ui/elements/loader/themes/halo/light';
|
|
4
|
-
|
|
5
4
|
dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-autosuggest', styles: 'mark{color:#fff;background-color:#334bff}:host{min-height:0;max-height:350px;border:1px solid #595959;background-color:#fff}:host([loading]){min-height:50px;min-width:150px}:host [part=content]{overflow:auto;touch-action:manipulation;scrollbar-face-color:#999;scrollbar-shadow-color:#999;scrollbar-highlight-color:#999;scrollbar-arrow-color:#999;scrollbar-track-color:#f2f2f2;scrollbar-3dlight-color:#f2f2f2;scrollbar-darkshadow-color:#f2f2f2;scrollbar-color:#999 #f2f2f2;scrollbar-width:thin}:host [part=more-results]{border-top:1px solid #595959}:host [part=more-results] mark{background-color:inherit;font-weight:500}:host [part=more-results-text]{font-size:.76em;font-size:inherit}:host [part=more-results-keys],:host [part=more-results] mark{color:#0d0d0d}:host [part=loader]{top:0;bottom:0;left:0;right:0;position:absolute}:host [part=backdrop]{background-color:#000;opacity:.6;width:100%;height:100%}::-webkit-scrollbar-corner{background:0 0}::-webkit-scrollbar{width:8px;height:8px}::-webkit-scrollbar-thumb{background:#999;border-radius:0;border:1px solid transparent}::-webkit-scrollbar-thumb:hover{background:#1429bd}::-webkit-scrollbar-thumb:active{background:#0f1e8a}::-webkit-scrollbar-track{background:#f2f2f2}::-webkit-scrollbar-thumb:horizontal{background-size:auto 6px;background-repeat:repeat-x;background-image:linear-gradient(to bottom,#999,#999);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:horizontal:hover{background-image:linear-gradient(to bottom,#1429bd,#1429bd);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:horizontal:active{background-image:linear-gradient(to bottom,#0f1e8a,#0f1e8a);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:vertical{background-size:6px auto;background-repeat:repeat-y;background-image:linear-gradient(to right,#999,#999);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:vertical:hover{background-image:linear-gradient(to right,#1429bd,#1429bd);background-color:transparent;background-position:center}::-webkit-scrollbar-thumb:vertical:active{background-image:linear-gradient(to right,#0f1e8a,#0f1e8a);background-color:transparent;background-position:center}::-webkit-scrollbar-track:horizontal{border-top:1px solid #fff;border-bottom:1px solid #fff}::-webkit-scrollbar-track:vertical{border-left:1px solid #fff;border-right:1px solid #fff}::-webkit-scrollbar-button{background:0 0/1px 2px no-repeat #f2f2f2;height:16px;width:16px;display:none;border:1px solid #fff}::-webkit-scrollbar-button:end:decrement,::-webkit-scrollbar-button:start:increment{display:none}::-webkit-scrollbar-button:hover{background-color:#1429bd;border:1px solid #1429bd}::-webkit-scrollbar-button:active{background-color:#0f1e8a;border:1px solid #fff}::-webkit-scrollbar-button:horizontal{background-size:2px 1px}::-webkit-scrollbar-button:vertical:start:decrement{border-bottom-color:#fff;background-image:linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959);background-position:10.55px 8px,9.55px 7px,8.55px 6px,7.55px 5px,6.55px 4px,5.55px 5px,4.55px 6px,3.55px 7px,2.55px 8px}::-webkit-scrollbar-button:vertical:start:decrement:hover{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:10.55px 8px,9.55px 7px,8.55px 6px,7.55px 5px,6.55px 4px,5.55px 5px,4.55px 6px,3.55px 7px,2.55px 8px;border-bottom-color:#1429bd}::-webkit-scrollbar-button:vertical:start:decrement:active{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:10.55px 8px,9.55px 7px,8.55px 6px,7.55px 5px,6.55px 4px,5.55px 5px,4.55px 6px,3.55px 7px,2.55px 8px;border-bottom-color:#fff}::-webkit-scrollbar-button:vertical:end:increment{border-top-color:#fff;background-image:linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959);background-position:10.55px 4px,9.55px 5px,8.55px 6px,7.55px 7px,6.55px 8px,5.55px 7px,4.55px 6px,3.55px 5px,2.55px 4px}::-webkit-scrollbar-button:vertical:end:increment:hover{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:10.55px 4px,9.55px 5px,8.55px 6px,7.55px 7px,6.55px 8px,5.55px 7px,4.55px 6px,3.55px 5px,2.55px 4px;border-top-color:#1429bd}::-webkit-scrollbar-button:vertical:end:increment:active{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:10.55px 4px,9.55px 5px,8.55px 6px,7.55px 7px,6.55px 8px,5.55px 7px,4.55px 6px,3.55px 5px,2.55px 4px;border-top-color:#fff}::-webkit-scrollbar-button:horizontal:start:decrement{border-right-color:#fff;background-image:linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959);background-position:7.5px 10.55px,6.5px 9.55px,5.5px 8.55px,4.5px 7.55px,3.5px 6.55px,4.5px 5.55px,5.5px 4.55px,6.5px 3.55px,7.5px 2.55px}::-webkit-scrollbar-button:horizontal:start:decrement:hover{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:7.5px 10.55px,6.5px 9.55px,5.5px 8.55px,4.5px 7.55px,3.5px 6.55px,4.5px 5.55px,5.5px 4.55px,6.5px 3.55px,7.5px 2.55px;border-right-color:#1429bd}::-webkit-scrollbar-button:horizontal:start:decrement:active{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:7.5px 10.55px,6.5px 9.55px,5.5px 8.55px,4.5px 7.55px,3.5px 6.55px,4.5px 5.55px,5.5px 4.55px,6.5px 3.55px,7.5px 2.55px;border-right-color:#fff}::-webkit-scrollbar-button:horizontal:end:increment{border-left-color:#fff;background-image:linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959),linear-gradient(#595959,#595959);background-position:5px 10.55px,6px 9.55px,7px 8.55px,8px 7.55px,9px 6.55px,8px 5.55px,7px 4.55px,6px 3.55px,5px 2.55px}::-webkit-scrollbar-button:horizontal:end:increment:hover{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:5px 10.55px,6px 9.55px,7px 8.55px,8px 7.55px,9px 6.55px,8px 5.55px,7px 4.55px,6px 3.55px,5px 2.55px;border-left-color:#1429bd}::-webkit-scrollbar-button:horizontal:end:increment:active{background-image:linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff),linear-gradient(#fff,#fff);background-position:5px 10.55px,6px 9.55px,7px 8.55px,8px 7.55px,9px 6.55px,8px 5.55px,7px 4.55px,6px 3.55px,5px 2.55px;border-left-color:#fff}kbd{font-family:inherit;justify-content:center;align-items:center;vertical-align:middle;box-sizing:border-box;box-shadow:0 1px 3px rgba(0,0,0,.3);min-width:1.33em;display:inline-block;color:#0d0d0d;background-color:#d9d9d9;box-shadow:0 0 0 2px #d9d9d9;font-weight:600;font-family:inherit;font-size:.83333333em;border-radius:1em;padding:0 .5em;height:1.2em;margin-top:-.1em}:host{border-color:#334bff;margin:2px 0}:host [part=content] ::slotted(ef-item:not([part=more-results])){background-color:#f2f2f2}:host [part=content] ::slotted(ef-item:not([type=header]):not([part=more-results])){color:#404040}:host [part=content] ::slotted(ef-item:not([part=more-results]):not(:first-child)){box-shadow:0 -1px 0 #d9d9d9}:host [part=content] ::slotted(ef-item:not([part=more-results]):focus),:host [part=content] ::slotted(ef-item:not([part=more-results])[highlighted]){background-color:#e6e6e6}:host [part=content] ::slotted(ef-item:not([part=more-results]):focus:not([selected])),:host [part=content] ::slotted(ef-item:not([part=more-results])[highlighted]:not([selected])){color:#0d0d0d}:host [part=more-results]{border-top-color:#d9d9d9;color:#737373;background-color:#fafafa}:host [part=more-results]:focus,:host [part=more-results][highlighted]{background-color:#e6e6e6;color:#737373}:host [part=more-results-keys] kbd{margin-left:4px;margin-right:4px}:host [part=more-results-keys] kbd:first-of-type{margin-left:0}:host [part=more-results-keys] kbd:last-of-type{margin-right:0}' }}));
|