igniteui-webcomponents 7.2.4 → 7.3.0-beta.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 +142 -0
- package/animations/player.js +1 -1
- package/animations/player.js.map +1 -1
- package/animations/view-transition.js +1 -1
- package/animations/view-transition.js.map +1 -1
- package/components/accordion/accordion.d.ts +1 -1
- package/components/accordion/accordion.js +7 -6
- package/components/accordion/accordion.js.map +1 -1
- package/components/avatar/avatar.js +3 -3
- package/components/avatar/avatar.js.map +1 -1
- package/components/avatar/themes/themes.d.ts +1 -1
- package/components/avatar/themes/themes.js.map +1 -1
- package/components/badge/badge.d.ts +1 -1
- package/components/badge/badge.js +5 -5
- package/components/badge/badge.js.map +1 -1
- package/components/badge/themes/themes.d.ts +1 -1
- package/components/badge/themes/themes.js.map +1 -1
- package/components/banner/banner.d.ts +2 -2
- package/components/banner/banner.js +8 -8
- package/components/banner/banner.js.map +1 -1
- package/components/banner/themes/themes.d.ts +1 -1
- package/components/banner/themes/themes.js.map +1 -1
- package/components/button/button-base.d.ts +2 -2
- package/components/button/button-base.js +9 -8
- package/components/button/button-base.js.map +1 -1
- package/components/button/button.d.ts +3 -3
- package/components/button/button.js +2 -2
- package/components/button/button.js.map +1 -1
- package/components/button/icon-button.js +3 -3
- package/components/button/icon-button.js.map +1 -1
- package/components/button/themes/button/themes.d.ts +1 -1
- package/components/button/themes/button/themes.js.map +1 -1
- package/components/button/themes/icon-button/themes.d.ts +1 -1
- package/components/button/themes/icon-button/themes.js.map +1 -1
- package/components/button-group/button-group.d.ts +42 -21
- package/components/button-group/button-group.js +101 -106
- package/components/button-group/button-group.js.map +1 -1
- package/components/button-group/themes/button.d.ts +1 -1
- package/components/button-group/themes/button.js.map +1 -1
- package/components/button-group/themes/group.d.ts +1 -1
- package/components/button-group/themes/group.js.map +1 -1
- package/components/button-group/toggle-button.d.ts +17 -10
- package/components/button-group/toggle-button.js +28 -13
- package/components/button-group/toggle-button.js.map +1 -1
- package/components/calendar/base.d.ts +29 -10
- package/components/calendar/base.js +12 -15
- package/components/calendar/base.js.map +1 -1
- package/components/calendar/calendar.d.ts +39 -8
- package/components/calendar/calendar.js +96 -85
- package/components/calendar/calendar.js.map +1 -1
- package/components/calendar/days-view/days-view.d.ts +49 -22
- package/components/calendar/days-view/days-view.js +102 -163
- package/components/calendar/days-view/days-view.js.map +1 -1
- package/components/calendar/helpers.d.ts +3 -62
- package/components/calendar/helpers.js +6 -110
- package/components/calendar/helpers.js.map +1 -1
- package/components/calendar/months-view/months-view.d.ts +7 -21
- package/components/calendar/months-view/months-view.js +30 -83
- package/components/calendar/months-view/months-view.js.map +1 -1
- package/components/calendar/selection.d.ts +21 -0
- package/components/calendar/selection.js +42 -0
- package/components/calendar/selection.js.map +1 -0
- package/components/calendar/themes/calendar.d.ts +1 -1
- package/components/calendar/themes/calendar.js.map +1 -1
- package/components/calendar/themes/days.d.ts +1 -1
- package/components/calendar/themes/days.js.map +1 -1
- package/components/calendar/themes/year-month.d.ts +1 -1
- package/components/calendar/themes/year-month.js.map +1 -1
- package/components/calendar/types.d.ts +18 -0
- package/components/calendar/types.js.map +1 -1
- package/components/calendar/year-month-view.base.d.ts +44 -0
- package/components/calendar/year-month-view.base.js +89 -0
- package/components/calendar/year-month-view.base.js.map +1 -0
- package/components/calendar/years-view/years-view.d.ts +7 -20
- package/components/calendar/years-view/years-view.js +25 -79
- package/components/calendar/years-view/years-view.js.map +1 -1
- package/components/card/card.actions.js +2 -2
- package/components/card/card.actions.js.map +1 -1
- package/components/card/card.content.d.ts +1 -1
- package/components/card/card.content.js +2 -2
- package/components/card/card.content.js.map +1 -1
- package/components/card/card.d.ts +1 -1
- package/components/card/card.header.js +2 -2
- package/components/card/card.header.js.map +1 -1
- package/components/card/card.js +2 -2
- package/components/card/card.js.map +1 -1
- package/components/card/card.media.d.ts +1 -1
- package/components/card/card.media.js +1 -1
- package/components/card/card.media.js.map +1 -1
- package/components/card/themes/actions.d.ts +1 -1
- package/components/card/themes/actions.js.map +1 -1
- package/components/card/themes/container.d.ts +1 -1
- package/components/card/themes/container.js.map +1 -1
- package/components/card/themes/content.d.ts +1 -1
- package/components/card/themes/content.js.map +1 -1
- package/components/card/themes/header.d.ts +1 -1
- package/components/card/themes/header.js.map +1 -1
- package/components/carousel/animations.d.ts +1 -1
- package/components/carousel/animations.js +2 -2
- package/components/carousel/animations.js.map +1 -1
- package/components/carousel/carousel-indicator-container.js +4 -4
- package/components/carousel/carousel-indicator-container.js.map +1 -1
- package/components/carousel/carousel-indicator.d.ts +1 -1
- package/components/carousel/carousel-indicator.js +5 -5
- package/components/carousel/carousel-indicator.js.map +1 -1
- package/components/carousel/carousel-slide.d.ts +1 -1
- package/components/carousel/carousel-slide.js +9 -9
- package/components/carousel/carousel-slide.js.map +1 -1
- package/components/carousel/carousel.d.ts +7 -7
- package/components/carousel/carousel.js +39 -28
- package/components/carousel/carousel.js.map +1 -1
- package/components/carousel/themes/container.d.ts +1 -1
- package/components/carousel/themes/container.js.map +1 -1
- package/components/carousel/themes/indicator-container.d.ts +1 -1
- package/components/carousel/themes/indicator-container.js.map +1 -1
- package/components/chat/chat-input.d.ts +4 -4
- package/components/chat/chat-input.js +9 -8
- package/components/chat/chat-input.js.map +1 -1
- package/components/chat/chat-message.d.ts +1 -1
- package/components/chat/chat-message.js +7 -6
- package/components/chat/chat-message.js.map +1 -1
- package/components/chat/chat-state.d.ts +2 -2
- package/components/chat/chat-state.js +2 -1
- package/components/chat/chat-state.js.map +1 -1
- package/components/chat/chat.d.ts +4 -4
- package/components/chat/chat.js +7 -7
- package/components/chat/chat.js.map +1 -1
- package/components/chat/message-attachments.js +5 -5
- package/components/chat/message-attachments.js.map +1 -1
- package/components/chat/themes/attachments.d.ts +1 -1
- package/components/chat/themes/attachments.js.map +1 -1
- package/components/chat/themes/input.d.ts +1 -1
- package/components/chat/themes/input.js.map +1 -1
- package/components/chat/themes/message.d.ts +1 -1
- package/components/chat/themes/message.js.map +1 -1
- package/components/chat/themes/themes.d.ts +1 -1
- package/components/chat/themes/themes.js.map +1 -1
- package/components/chat/types.d.ts +2 -2
- package/components/chat/types.js.map +1 -1
- package/components/chat/utils.d.ts +1 -1
- package/components/chat/utils.js +3 -3
- package/components/chat/utils.js.map +1 -1
- package/components/checkbox/checkbox-base.d.ts +7 -7
- package/components/checkbox/checkbox-base.js +7 -7
- package/components/checkbox/checkbox-base.js.map +1 -1
- package/components/checkbox/checkbox.js +7 -6
- package/components/checkbox/checkbox.js.map +1 -1
- package/components/checkbox/switch.js +7 -6
- package/components/checkbox/switch.js.map +1 -1
- package/components/checkbox/themes/checkbox-themes.d.ts +1 -1
- package/components/checkbox/themes/checkbox-themes.js.map +1 -1
- package/components/checkbox/themes/switch-themes.d.ts +1 -1
- package/components/checkbox/themes/switch-themes.js.map +1 -1
- package/components/checkbox/validators.d.ts +1 -1
- package/components/checkbox/validators.js +1 -1
- package/components/checkbox/validators.js.map +1 -1
- package/components/chip/chip.d.ts +9 -3
- package/components/chip/chip.js +10 -6
- package/components/chip/chip.js.map +1 -1
- package/components/chip/themes/chip.base.css.js +1 -1
- package/components/chip/themes/chip.base.css.js.map +1 -1
- package/components/chip/themes/dark/chip.bootstrap.css.js +1 -1
- package/components/chip/themes/dark/chip.bootstrap.css.js.map +1 -1
- package/components/chip/themes/dark/chip.fluent.css.js +1 -1
- package/components/chip/themes/dark/chip.fluent.css.js.map +1 -1
- package/components/chip/themes/dark/chip.indigo.css.js +1 -1
- package/components/chip/themes/dark/chip.indigo.css.js.map +1 -1
- package/components/chip/themes/dark/chip.material.css.js +1 -1
- package/components/chip/themes/dark/chip.material.css.js.map +1 -1
- package/components/chip/themes/light/chip.bootstrap.css.js +1 -1
- package/components/chip/themes/light/chip.bootstrap.css.js.map +1 -1
- package/components/chip/themes/light/chip.fluent.css.js +1 -1
- package/components/chip/themes/light/chip.fluent.css.js.map +1 -1
- package/components/chip/themes/light/chip.indigo.css.js +1 -1
- package/components/chip/themes/light/chip.indigo.css.js.map +1 -1
- package/components/chip/themes/light/chip.material.css.js +1 -1
- package/components/chip/themes/light/chip.material.css.js.map +1 -1
- package/components/chip/themes/light/chip.shared.css.js +1 -1
- package/components/chip/themes/light/chip.shared.css.js.map +1 -1
- package/components/chip/themes/shared/chip.bootstrap.css.js +1 -1
- package/components/chip/themes/shared/chip.bootstrap.css.js.map +1 -1
- package/components/chip/themes/shared/chip.common.css.js +1 -1
- package/components/chip/themes/shared/chip.common.css.js.map +1 -1
- package/components/chip/themes/shared/chip.fluent.css.js +1 -1
- package/components/chip/themes/shared/chip.fluent.css.js.map +1 -1
- package/components/chip/themes/shared/chip.indigo.css.js +1 -1
- package/components/chip/themes/shared/chip.indigo.css.js.map +1 -1
- package/components/chip/themes/themes.d.ts +1 -1
- package/components/chip/themes/themes.js.map +1 -1
- package/components/combo/combo-header.js +2 -2
- package/components/combo/combo-header.js.map +1 -1
- package/components/combo/combo-item.d.ts +0 -2
- package/components/combo/combo-item.js +4 -7
- package/components/combo/combo-item.js.map +1 -1
- package/components/combo/combo.d.ts +84 -27
- package/components/combo/combo.js +194 -157
- package/components/combo/combo.js.map +1 -1
- package/components/combo/controllers/data.d.ts +30 -3
- package/components/combo/controllers/data.js +34 -9
- package/components/combo/controllers/data.js.map +1 -1
- package/components/combo/controllers/navigation.d.ts +8 -2
- package/components/combo/controllers/navigation.js +11 -12
- package/components/combo/controllers/navigation.js.map +1 -1
- package/components/combo/operations/filter.d.ts +17 -1
- package/components/combo/operations/filter.js +29 -9
- package/components/combo/operations/filter.js.map +1 -1
- package/components/combo/operations/group.js +1 -1
- package/components/combo/operations/group.js.map +1 -1
- package/components/combo/themes/combo.base.css.js +1 -1
- package/components/combo/themes/combo.base.css.js.map +1 -1
- package/components/combo/themes/themes.d.ts +1 -1
- package/components/combo/themes/themes.js.map +1 -1
- package/components/combo/types.d.ts +8 -4
- package/components/combo/types.js.map +1 -1
- package/components/combo/validators.d.ts +1 -1
- package/components/combo/validators.js.map +1 -1
- package/components/date-picker/date-picker.base.d.ts +294 -0
- package/components/date-picker/date-picker.base.js +480 -0
- package/components/date-picker/date-picker.base.js.map +1 -0
- package/components/date-picker/date-picker.d.ts +53 -174
- package/components/date-picker/date-picker.js +88 -399
- package/components/date-picker/date-picker.js.map +1 -1
- package/components/date-picker/themes/themes.d.ts +1 -1
- package/components/date-picker/themes/themes.js.map +1 -1
- package/components/date-picker/validators.d.ts +1 -1
- package/components/date-picker/validators.js +2 -2
- package/components/date-picker/validators.js.map +1 -1
- package/components/date-range-picker/date-range-input.d.ts +12 -14
- package/components/date-range-picker/date-range-input.js +42 -98
- package/components/date-range-picker/date-range-input.js.map +1 -1
- package/components/date-range-picker/date-range-mask-parser.d.ts +22 -34
- package/components/date-range-picker/date-range-mask-parser.js +38 -69
- package/components/date-range-picker/date-range-mask-parser.js.map +1 -1
- package/components/date-range-picker/date-range-picker.d.ts +97 -191
- package/components/date-range-picker/date-range-picker.js +210 -532
- package/components/date-range-picker/date-range-picker.js.map +1 -1
- package/components/date-range-picker/predefined-ranges-area.d.ts +2 -2
- package/components/date-range-picker/predefined-ranges-area.js +5 -5
- package/components/date-range-picker/predefined-ranges-area.js.map +1 -1
- package/components/date-range-picker/themes/ranges-themes.d.ts +1 -1
- package/components/date-range-picker/themes/ranges-themes.js.map +1 -1
- package/components/date-range-picker/themes/themes.d.ts +1 -1
- package/components/date-range-picker/themes/themes.js.map +1 -1
- package/components/date-range-picker/validators.d.ts +1 -1
- package/components/date-range-picker/validators.js +15 -22
- package/components/date-range-picker/validators.js.map +1 -1
- package/components/date-time-input/date-part.d.ts +18 -1
- package/components/date-time-input/date-part.js +10 -0
- package/components/date-time-input/date-part.js.map +1 -1
- package/components/date-time-input/date-time-input.base.d.ts +72 -25
- package/components/date-time-input/date-time-input.base.js +100 -36
- package/components/date-time-input/date-time-input.base.js.map +1 -1
- package/components/date-time-input/date-time-input.d.ts +13 -23
- package/components/date-time-input/date-time-input.js +45 -65
- package/components/date-time-input/date-time-input.js.map +1 -1
- package/components/date-time-input/datetime-mask-parser.d.ts +45 -109
- package/components/date-time-input/datetime-mask-parser.js +88 -139
- package/components/date-time-input/datetime-mask-parser.js.map +1 -1
- package/components/date-time-input/validators.d.ts +1 -1
- package/components/date-time-input/validators.js +2 -2
- package/components/date-time-input/validators.js.map +1 -1
- package/components/dialog/dialog.d.ts +2 -2
- package/components/dialog/dialog.js +17 -18
- package/components/dialog/dialog.js.map +1 -1
- package/components/dialog/themes/themes.d.ts +1 -1
- package/components/dialog/themes/themes.js.map +1 -1
- package/components/divider/divider.d.ts +2 -1
- package/components/divider/divider.js +3 -3
- package/components/divider/divider.js.map +1 -1
- package/components/divider/themes/themes.d.ts +1 -1
- package/components/divider/themes/themes.js.map +1 -1
- package/components/dropdown/dropdown-group.d.ts +10 -3
- package/components/dropdown/dropdown-group.js +21 -5
- package/components/dropdown/dropdown-group.js.map +1 -1
- package/components/dropdown/dropdown-header.d.ts +2 -2
- package/components/dropdown/dropdown-header.js +7 -2
- package/components/dropdown/dropdown-header.js.map +1 -1
- package/components/dropdown/dropdown-item.d.ts +4 -4
- package/components/dropdown/dropdown-item.js +3 -3
- package/components/dropdown/dropdown-item.js.map +1 -1
- package/components/dropdown/dropdown.d.ts +75 -32
- package/components/dropdown/dropdown.js +189 -110
- package/components/dropdown/dropdown.js.map +1 -1
- package/components/dropdown/themes/container.d.ts +1 -1
- package/components/dropdown/themes/container.js.map +1 -1
- package/components/dropdown/themes/group.d.ts +1 -1
- package/components/dropdown/themes/group.js.map +1 -1
- package/components/dropdown/themes/header.d.ts +1 -1
- package/components/dropdown/themes/header.js.map +1 -1
- package/components/dropdown/themes/item.d.ts +1 -1
- package/components/dropdown/themes/item.js.map +1 -1
- package/components/expansion-panel/expansion-panel.d.ts +14 -5
- package/components/expansion-panel/expansion-panel.js +10 -9
- package/components/expansion-panel/expansion-panel.js.map +1 -1
- package/components/expansion-panel/themes/themes.d.ts +1 -1
- package/components/expansion-panel/themes/themes.js.map +1 -1
- package/components/file-input/file-input.d.ts +20 -12
- package/components/file-input/file-input.js +17 -12
- package/components/file-input/file-input.js.map +1 -1
- package/components/file-input/themes/themes.d.ts +1 -1
- package/components/file-input/themes/themes.js.map +1 -1
- package/components/file-input/validators.d.ts +1 -1
- package/components/file-input/validators.js +1 -1
- package/components/file-input/validators.js.map +1 -1
- package/components/focus-trap/focus-trap.js +3 -2
- package/components/focus-trap/focus-trap.js.map +1 -1
- package/components/highlight/highlight.js +2 -2
- package/components/highlight/highlight.js.map +1 -1
- package/components/highlight/service.d.ts +4 -1
- package/components/highlight/service.js +23 -7
- package/components/highlight/service.js.map +1 -1
- package/components/highlight/themes/themes.d.ts +1 -1
- package/components/highlight/themes/themes.js.map +1 -1
- package/components/icon/icon-references.d.ts +3 -2
- package/components/icon/icon-references.js +103 -491
- package/components/icon/icon-references.js.map +1 -1
- package/components/icon/icon-state.broadcast.d.ts +14 -17
- package/components/icon/icon-state.broadcast.js +19 -20
- package/components/icon/icon-state.broadcast.js.map +1 -1
- package/components/icon/icon.d.ts +12 -24
- package/components/icon/icon.js +36 -28
- package/components/icon/icon.js.map +1 -1
- package/components/icon/icon.registry.d.ts +69 -131
- package/components/icon/icon.registry.js +51 -53
- package/components/icon/icon.registry.js.map +1 -1
- package/components/icon/internal-icons-lib.js +2 -2
- package/components/icon/internal-icons-lib.js.map +1 -1
- package/components/icon/registry/parser.d.ts +15 -3
- package/components/icon/registry/parser.js +36 -11
- package/components/icon/registry/parser.js.map +1 -1
- package/components/icon/registry/types.d.ts +55 -11
- package/components/icon/registry/types.js.map +1 -1
- package/components/icon/themes/icon.base.css.js +1 -1
- package/components/icon/themes/icon.base.css.js.map +1 -1
- package/components/icon/themes/shared/icon.common.css.js +1 -1
- package/components/icon/themes/shared/icon.common.css.js.map +1 -1
- package/components/icon/themes/themes.d.ts +1 -1
- package/components/icon/themes/themes.js.map +1 -1
- package/components/input/input-base.d.ts +10 -25
- package/components/input/input-base.js +14 -23
- package/components/input/input-base.js.map +1 -1
- package/components/input/input.d.ts +15 -12
- package/components/input/input.js +8 -9
- package/components/input/input.js.map +1 -1
- package/components/input/themes/input.base.css.js +1 -1
- package/components/input/themes/input.base.css.js.map +1 -1
- package/components/input/themes/shared/input.bootstrap.css.js +1 -1
- package/components/input/themes/shared/input.bootstrap.css.js.map +1 -1
- package/components/input/themes/shared/input.common.css.js +1 -1
- package/components/input/themes/shared/input.common.css.js.map +1 -1
- package/components/input/themes/shared/input.fluent.css.js +1 -1
- package/components/input/themes/shared/input.fluent.css.js.map +1 -1
- package/components/input/themes/shared/input.indigo.css.js +1 -1
- package/components/input/themes/shared/input.indigo.css.js.map +1 -1
- package/components/input/themes/shared/input.material.css.js +1 -1
- package/components/input/themes/shared/input.material.css.js.map +1 -1
- package/components/input/themes/themes.d.ts +1 -1
- package/components/input/themes/themes.js.map +1 -1
- package/components/input/validators.d.ts +1 -1
- package/components/input/validators.js +1 -1
- package/components/input/validators.js.map +1 -1
- package/components/list/list-header.js +3 -3
- package/components/list/list-header.js.map +1 -1
- package/components/list/list-item.js +3 -3
- package/components/list/list-item.js.map +1 -1
- package/components/list/list.js +3 -3
- package/components/list/list.js.map +1 -1
- package/components/list/themes/container.d.ts +1 -1
- package/components/list/themes/container.js.map +1 -1
- package/components/list/themes/header.d.ts +1 -1
- package/components/list/themes/header.js.map +1 -1
- package/components/list/themes/item.d.ts +1 -1
- package/components/list/themes/item.js.map +1 -1
- package/components/mask-input/mask-history.d.ts +99 -0
- package/components/mask-input/mask-history.js +95 -0
- package/components/mask-input/mask-history.js.map +1 -0
- package/components/mask-input/mask-input.d.ts +14 -9
- package/components/mask-input/mask-input.js +20 -24
- package/components/mask-input/mask-input.js.map +1 -1
- package/components/mask-input/mask-parser.d.ts +20 -2
- package/components/mask-input/mask-parser.js +21 -13
- package/components/mask-input/mask-parser.js.map +1 -1
- package/components/mask-input/validators.d.ts +1 -1
- package/components/mask-input/validators.js +1 -1
- package/components/mask-input/validators.js.map +1 -1
- package/components/nav-drawer/nav-drawer-header-item.d.ts +1 -1
- package/components/nav-drawer/nav-drawer-header-item.js +2 -2
- package/components/nav-drawer/nav-drawer-header-item.js.map +1 -1
- package/components/nav-drawer/nav-drawer-item.d.ts +2 -2
- package/components/nav-drawer/nav-drawer-item.js +4 -4
- package/components/nav-drawer/nav-drawer-item.js.map +1 -1
- package/components/nav-drawer/nav-drawer.d.ts +3 -3
- package/components/nav-drawer/nav-drawer.js +11 -14
- package/components/nav-drawer/nav-drawer.js.map +1 -1
- package/components/nav-drawer/themes/container.base.css.js +1 -1
- package/components/nav-drawer/themes/container.base.css.js.map +1 -1
- package/components/nav-drawer/themes/container.d.ts +1 -1
- package/components/nav-drawer/themes/container.js +2 -3
- package/components/nav-drawer/themes/container.js.map +1 -1
- package/components/nav-drawer/themes/dark/container/nav-drawer.shared.css.js +1 -1
- package/components/nav-drawer/themes/dark/container/nav-drawer.shared.css.js.map +1 -1
- package/components/nav-drawer/themes/header-item.d.ts +1 -1
- package/components/nav-drawer/themes/header-item.js.map +1 -1
- package/components/nav-drawer/themes/item.d.ts +1 -1
- package/components/nav-drawer/themes/item.js.map +1 -1
- package/components/nav-drawer/themes/light/container/nav-drawer.bootstrap.css.js +1 -1
- package/components/nav-drawer/themes/light/container/nav-drawer.bootstrap.css.js.map +1 -1
- package/components/nav-drawer/themes/light/container/nav-drawer.fluent.css.js +1 -1
- package/components/nav-drawer/themes/light/container/nav-drawer.fluent.css.js.map +1 -1
- package/components/nav-drawer/themes/light/container/nav-drawer.indigo.css.js +1 -1
- package/components/nav-drawer/themes/light/container/nav-drawer.indigo.css.js.map +1 -1
- package/components/nav-drawer/themes/light/container/nav-drawer.shared.css.js +1 -1
- package/components/nav-drawer/themes/light/container/nav-drawer.shared.css.js.map +1 -1
- package/components/nav-drawer/themes/shared/container/nav-drawer.bootstrap.css.js +1 -1
- package/components/nav-drawer/themes/shared/container/nav-drawer.bootstrap.css.js.map +1 -1
- package/components/nav-drawer/themes/shared/container/nav-drawer.indigo.css.js +1 -1
- package/components/nav-drawer/themes/shared/container/nav-drawer.indigo.css.js.map +1 -1
- package/components/nav-drawer/themes/shared/container/nav-drawer.material.css.js +1 -1
- package/components/nav-drawer/themes/shared/container/nav-drawer.material.css.js.map +1 -1
- package/components/navbar/navbar.js +2 -2
- package/components/navbar/navbar.js.map +1 -1
- package/components/navbar/themes/themes.d.ts +1 -1
- package/components/navbar/themes/themes.js.map +1 -1
- package/components/popover/popover.d.ts +10 -3
- package/components/popover/popover.js +114 -99
- package/components/popover/popover.js.map +1 -1
- package/components/progress/base.d.ts +1 -1
- package/components/progress/base.js +5 -4
- package/components/progress/base.js.map +1 -1
- package/components/progress/circular-gradient.d.ts +2 -2
- package/components/progress/circular-gradient.js +1 -1
- package/components/progress/circular-gradient.js.map +1 -1
- package/components/progress/circular-progress.d.ts +15 -15
- package/components/progress/circular-progress.js +7 -6
- package/components/progress/circular-progress.js.map +1 -1
- package/components/progress/linear-progress.d.ts +12 -12
- package/components/progress/linear-progress.js +4 -4
- package/components/progress/linear-progress.js.map +1 -1
- package/components/progress/themes/circular/circular.progress.base.css.js +1 -1
- package/components/progress/themes/circular/circular.progress.base.css.js.map +1 -1
- package/components/progress/themes/circular/themes.d.ts +1 -1
- package/components/progress/themes/circular/themes.js.map +1 -1
- package/components/progress/themes/linear/linear.progress.base.css.js +1 -1
- package/components/progress/themes/linear/linear.progress.base.css.js.map +1 -1
- package/components/progress/themes/linear/themes.d.ts +1 -1
- package/components/progress/themes/linear/themes.js.map +1 -1
- package/components/qr-code/model/encode.d.ts +20 -0
- package/components/qr-code/model/encode.js +166 -0
- package/components/qr-code/model/encode.js.map +1 -0
- package/components/qr-code/model/error-correction.d.ts +15 -0
- package/components/qr-code/model/error-correction.js +1114 -0
- package/components/qr-code/model/error-correction.js.map +1 -0
- package/components/qr-code/model/mask.d.ts +11 -0
- package/components/qr-code/model/mask.js +161 -0
- package/components/qr-code/model/mask.js.map +1 -0
- package/components/qr-code/model/matrix.d.ts +15 -0
- package/components/qr-code/model/matrix.js +277 -0
- package/components/qr-code/model/matrix.js.map +1 -0
- package/components/qr-code/qr-code.d.ts +134 -0
- package/components/qr-code/qr-code.js +221 -0
- package/components/qr-code/qr-code.js.map +1 -0
- package/components/qr-code/renderer/constants.d.ts +26 -0
- package/components/qr-code/renderer/constants.js +5 -0
- package/components/qr-code/renderer/constants.js.map +1 -0
- package/components/qr-code/renderer/corner.d.ts +23 -0
- package/components/qr-code/renderer/corner.js +25 -0
- package/components/qr-code/renderer/corner.js.map +1 -0
- package/components/qr-code/renderer/dots.d.ts +14 -0
- package/components/qr-code/renderer/dots.js +7 -0
- package/components/qr-code/renderer/dots.js.map +1 -0
- package/components/qr-code/renderer/helpers.d.ts +18 -0
- package/components/qr-code/renderer/helpers.js +158 -0
- package/components/qr-code/renderer/helpers.js.map +1 -0
- package/components/qr-code/renderer/image.d.ts +23 -0
- package/components/qr-code/renderer/image.js +29 -0
- package/components/qr-code/renderer/image.js.map +1 -0
- package/components/qr-code/themes/dark/qr-code.bootstrap.css.js +3 -0
- package/components/qr-code/themes/dark/qr-code.bootstrap.css.js.map +1 -0
- package/components/qr-code/themes/dark/qr-code.fluent.css.d.ts +1 -0
- package/components/qr-code/themes/dark/qr-code.fluent.css.js +3 -0
- package/components/qr-code/themes/dark/qr-code.fluent.css.js.map +1 -0
- package/components/qr-code/themes/dark/qr-code.indigo.css.d.ts +1 -0
- package/components/qr-code/themes/dark/qr-code.indigo.css.js +3 -0
- package/components/qr-code/themes/dark/qr-code.indigo.css.js.map +1 -0
- package/components/qr-code/themes/dark/qr-code.material.css.d.ts +1 -0
- package/components/qr-code/themes/dark/qr-code.material.css.js +3 -0
- package/components/qr-code/themes/dark/qr-code.material.css.js.map +1 -0
- package/components/qr-code/themes/light/qr-code.bootstrap.css.d.ts +1 -0
- package/components/qr-code/themes/light/qr-code.bootstrap.css.js +3 -0
- package/components/qr-code/themes/light/qr-code.bootstrap.css.js.map +1 -0
- package/components/qr-code/themes/light/qr-code.fluent.css.d.ts +1 -0
- package/components/qr-code/themes/light/qr-code.fluent.css.js +3 -0
- package/components/qr-code/themes/light/qr-code.fluent.css.js.map +1 -0
- package/components/qr-code/themes/light/qr-code.indigo.css.d.ts +1 -0
- package/components/qr-code/themes/light/qr-code.indigo.css.js +3 -0
- package/components/qr-code/themes/light/qr-code.indigo.css.js.map +1 -0
- package/components/qr-code/themes/light/qr-code.material.css.d.ts +1 -0
- package/components/qr-code/themes/light/qr-code.material.css.js +3 -0
- package/components/qr-code/themes/light/qr-code.material.css.js.map +1 -0
- package/components/qr-code/themes/light/qr-code.shared.css.d.ts +1 -0
- package/components/qr-code/themes/light/qr-code.shared.css.js +3 -0
- package/components/qr-code/themes/light/qr-code.shared.css.js.map +1 -0
- package/components/qr-code/themes/qr-code.base.css.d.ts +1 -0
- package/components/qr-code/themes/qr-code.base.css.js +3 -0
- package/components/qr-code/themes/qr-code.base.css.js.map +1 -0
- package/components/qr-code/themes/shared/qr-code.common.css.d.ts +1 -0
- package/components/qr-code/themes/shared/qr-code.common.css.js +3 -0
- package/components/qr-code/themes/shared/qr-code.common.css.js.map +1 -0
- package/components/qr-code/themes/themes.d.ts +2 -0
- package/components/qr-code/themes/themes.js +46 -0
- package/components/qr-code/themes/themes.js.map +1 -0
- package/components/qr-code/types.d.ts +16 -0
- package/components/qr-code/types.js +2 -0
- package/components/qr-code/types.js.map +1 -0
- package/components/radio/controller.d.ts +35 -0
- package/components/radio/controller.js +100 -0
- package/components/radio/controller.js.map +1 -0
- package/components/radio/radio.d.ts +26 -14
- package/components/radio/radio.js +47 -36
- package/components/radio/radio.js.map +1 -1
- package/components/radio/themes/themes.d.ts +1 -1
- package/components/radio/themes/themes.js.map +1 -1
- package/components/radio/validators.d.ts +1 -1
- package/components/radio/validators.js +5 -3
- package/components/radio/validators.js.map +1 -1
- package/components/radio-group/radio-group.d.ts +19 -10
- package/components/radio-group/radio-group.js +50 -41
- package/components/radio-group/radio-group.js.map +1 -1
- package/components/radio-group/themes/themes.d.ts +1 -1
- package/components/radio-group/themes/themes.js.map +1 -1
- package/components/rating/rating-symbol.d.ts +1 -1
- package/components/rating/rating-symbol.js +1 -1
- package/components/rating/rating-symbol.js.map +1 -1
- package/components/rating/rating.d.ts +6 -6
- package/components/rating/rating.js +12 -9
- package/components/rating/rating.js.map +1 -1
- package/components/rating/themes/themes.d.ts +1 -1
- package/components/rating/themes/themes.js.map +1 -1
- package/components/resize-container/resize-container.d.ts +4 -4
- package/components/resize-container/resize-container.js +4 -4
- package/components/resize-container/resize-container.js.map +1 -1
- package/components/resize-container/resize-controller.js +2 -2
- package/components/resize-container/resize-controller.js.map +1 -1
- package/components/resize-container/themes/themes.d.ts +1 -1
- package/components/resize-container/themes/themes.js.map +1 -1
- package/components/ripple/ripple.d.ts +1 -1
- package/components/ripple/ripple.js +3 -2
- package/components/ripple/ripple.js.map +1 -1
- package/components/select/select-group.d.ts +9 -2
- package/components/select/select-group.js +21 -5
- package/components/select/select-group.js.map +1 -1
- package/components/select/select-header.d.ts +1 -1
- package/components/select/select-header.js +7 -2
- package/components/select/select-header.js.map +1 -1
- package/components/select/select-item.d.ts +4 -4
- package/components/select/select-item.js +3 -3
- package/components/select/select-item.js.map +1 -1
- package/components/select/select.d.ts +48 -27
- package/components/select/select.js +128 -74
- package/components/select/select.js.map +1 -1
- package/components/select/themes/select.base.css.js +1 -1
- package/components/select/themes/select.base.css.js.map +1 -1
- package/components/select/themes/themes.d.ts +1 -1
- package/components/select/themes/themes.js.map +1 -1
- package/components/select/validators.d.ts +1 -1
- package/components/select/validators.js +1 -1
- package/components/select/validators.js.map +1 -1
- package/components/slider/range-slider.d.ts +2 -2
- package/components/slider/range-slider.js +3 -3
- package/components/slider/range-slider.js.map +1 -1
- package/components/slider/slider-base.js +9 -5
- package/components/slider/slider-base.js.map +1 -1
- package/components/slider/slider-label.js +1 -1
- package/components/slider/slider-label.js.map +1 -1
- package/components/slider/slider.d.ts +3 -3
- package/components/slider/slider.js +6 -6
- package/components/slider/slider.js.map +1 -1
- package/components/slider/themes/themes.d.ts +1 -1
- package/components/slider/themes/themes.js.map +1 -1
- package/components/snackbar/snackbar.d.ts +3 -3
- package/components/snackbar/snackbar.js +4 -4
- package/components/snackbar/snackbar.js.map +1 -1
- package/components/snackbar/themes/themes.d.ts +1 -1
- package/components/snackbar/themes/themes.js.map +1 -1
- package/components/splitter/splitter.d.ts +106 -23
- package/components/splitter/splitter.js +234 -147
- package/components/splitter/splitter.js.map +1 -1
- package/components/splitter/themes/themes.d.ts +1 -1
- package/components/splitter/themes/themes.js.map +1 -1
- package/components/splitter/types.d.ts +14 -3
- package/components/splitter/types.js.map +1 -1
- package/components/stepper/common/animations.d.ts +1 -1
- package/components/stepper/common/animations.js +2 -2
- package/components/stepper/common/animations.js.map +1 -1
- package/components/stepper/step.d.ts +1 -1
- package/components/stepper/step.js +7 -7
- package/components/stepper/step.js.map +1 -1
- package/components/stepper/stepper.d.ts +5 -5
- package/components/stepper/stepper.js +12 -9
- package/components/stepper/stepper.js.map +1 -1
- package/components/stepper/themes/step/themes.d.ts +1 -1
- package/components/stepper/themes/step/themes.js.map +1 -1
- package/components/tabs/tab-dom.d.ts +31 -28
- package/components/tabs/tab-dom.js +84 -34
- package/components/tabs/tab-dom.js.map +1 -1
- package/components/tabs/tab.d.ts +24 -6
- package/components/tabs/tab.js +34 -13
- package/components/tabs/tab.js.map +1 -1
- package/components/tabs/tabs.d.ts +36 -22
- package/components/tabs/tabs.js +113 -102
- package/components/tabs/tabs.js.map +1 -1
- package/components/tabs/themes/shared/tabs/tabs.indigo.css.js +1 -1
- package/components/tabs/themes/shared/tabs/tabs.indigo.css.js.map +1 -1
- package/components/tabs/themes/tab-themes.d.ts +1 -1
- package/components/tabs/themes/tab-themes.js.map +1 -1
- package/components/tabs/themes/tabs-themes.d.ts +1 -1
- package/components/tabs/themes/tabs-themes.js.map +1 -1
- package/components/tabs/themes/tabs.base.css.js +1 -1
- package/components/tabs/themes/tabs.base.css.js.map +1 -1
- package/components/textarea/textarea.d.ts +19 -14
- package/components/textarea/textarea.js +22 -17
- package/components/textarea/textarea.js.map +1 -1
- package/components/textarea/themes/themes.d.ts +1 -1
- package/components/textarea/themes/themes.js.map +1 -1
- package/components/textarea/validators.d.ts +1 -1
- package/components/textarea/validators.js +1 -1
- package/components/textarea/validators.js.map +1 -1
- package/components/theme-provider/theme-provider.d.ts +1 -1
- package/components/theme-provider/theme-provider.js +2 -2
- package/components/theme-provider/theme-provider.js.map +1 -1
- package/components/tile-manager/position.d.ts +1 -1
- package/components/tile-manager/position.js +2 -2
- package/components/tile-manager/position.js.map +1 -1
- package/components/tile-manager/resize-state.js +4 -3
- package/components/tile-manager/resize-state.js.map +1 -1
- package/components/tile-manager/themes/container.d.ts +1 -1
- package/components/tile-manager/themes/container.js.map +1 -1
- package/components/tile-manager/themes/tile.d.ts +1 -1
- package/components/tile-manager/themes/tile.js.map +1 -1
- package/components/tile-manager/tile-ghost-util.js +1 -1
- package/components/tile-manager/tile-ghost-util.js.map +1 -1
- package/components/tile-manager/tile-manager.d.ts +1 -1
- package/components/tile-manager/tile-manager.js +7 -7
- package/components/tile-manager/tile-manager.js.map +1 -1
- package/components/tile-manager/tile.d.ts +4 -4
- package/components/tile-manager/tile.js +16 -13
- package/components/tile-manager/tile.js.map +1 -1
- package/components/toast/themes/themes.d.ts +1 -1
- package/components/toast/themes/themes.js.map +1 -1
- package/components/toast/toast.d.ts +1 -1
- package/components/toast/toast.js +3 -3
- package/components/toast/toast.js.map +1 -1
- package/components/tooltip/controller.d.ts +18 -16
- package/components/tooltip/controller.js +62 -41
- package/components/tooltip/controller.js.map +1 -1
- package/components/tooltip/service.d.ts +2 -1
- package/components/tooltip/service.js +10 -15
- package/components/tooltip/service.js.map +1 -1
- package/components/tooltip/themes/shared/tooltip.common.css.js +1 -1
- package/components/tooltip/themes/shared/tooltip.common.css.js.map +1 -1
- package/components/tooltip/themes/shared/tooltip.indigo.css.js +1 -1
- package/components/tooltip/themes/shared/tooltip.indigo.css.js.map +1 -1
- package/components/tooltip/themes/themes.d.ts +1 -1
- package/components/tooltip/themes/themes.js.map +1 -1
- package/components/tooltip/themes/tooltip.base.css.js +1 -1
- package/components/tooltip/themes/tooltip.base.css.js.map +1 -1
- package/components/tooltip/tooltip.d.ts +64 -18
- package/components/tooltip/tooltip.js +110 -60
- package/components/tooltip/tooltip.js.map +1 -1
- package/components/tree/themes/container.base.css.js +1 -1
- package/components/tree/themes/container.base.css.js.map +1 -1
- package/components/tree/themes/container.d.ts +1 -1
- package/components/tree/themes/container.js.map +1 -1
- package/components/tree/themes/item.base.css.js +1 -1
- package/components/tree/themes/item.base.css.js.map +1 -1
- package/components/tree/themes/item.d.ts +1 -1
- package/components/tree/themes/item.js.map +1 -1
- package/components/tree/tree-item.d.ts +62 -36
- package/components/tree/tree-item.js +198 -208
- package/components/tree/tree-item.js.map +1 -1
- package/components/tree/tree.common.d.ts +16 -1
- package/components/tree/tree.common.js +40 -1
- package/components/tree/tree.common.js.map +1 -1
- package/components/tree/tree.d.ts +21 -14
- package/components/tree/tree.js +64 -72
- package/components/tree/tree.js.map +1 -1
- package/components/tree/tree.navigation.d.ts +39 -29
- package/components/tree/tree.navigation.js +140 -192
- package/components/tree/tree.navigation.js.map +1 -1
- package/components/tree/tree.selection.d.ts +32 -31
- package/components/tree/tree.selection.js +184 -178
- package/components/tree/tree.selection.js.map +1 -1
- package/components/types.js.map +1 -1
- package/components/validation-container/validation-container.d.ts +1 -1
- package/components/validation-container/validation-container.js +7 -6
- package/components/validation-container/validation-container.js.map +1 -1
- package/components/virtualization/engine.d.ts +92 -0
- package/components/virtualization/engine.js +217 -0
- package/components/virtualization/engine.js.map +1 -0
- package/components/virtualization/types.d.ts +53 -0
- package/components/virtualization/types.js +14 -0
- package/components/virtualization/types.js.map +1 -0
- package/components/virtualization/virtualization.d.ts +235 -0
- package/components/virtualization/virtualization.js +474 -0
- package/components/virtualization/virtualization.js.map +1 -0
- package/components/visually-hidden/visually-hidden.js +1 -1
- package/components/visually-hidden/visually-hidden.js.map +1 -1
- package/custom-elements.json +57745 -48130
- package/extras/chat-markdown-renderer.d.ts +1 -1
- package/extras/chat-markdown-renderer.js.map +1 -1
- package/igniteui-webcomponents.css-data.json +2 -2
- package/igniteui-webcomponents.html-data.json +1 -1
- package/index.d.ts +17 -12
- package/index.js +11 -9
- package/index.js.map +1 -1
- package/internals/abort-handler.js.map +1 -0
- package/internals/context.d.ts +39 -0
- package/{components/common → internals}/context.js +2 -1
- package/internals/context.js.map +1 -0
- package/internals/controllers/adopt-styles.d.ts +76 -0
- package/internals/controllers/adopt-styles.js +173 -0
- package/internals/controllers/adopt-styles.js.map +1 -0
- package/internals/controllers/aria-projection.d.ts +144 -0
- package/internals/controllers/aria-projection.js +138 -0
- package/internals/controllers/aria-projection.js.map +1 -0
- package/{components/common → internals}/controllers/async-consumer.js +8 -7
- package/internals/controllers/async-consumer.js.map +1 -0
- package/internals/controllers/command.js.map +1 -0
- package/{components/common → internals}/controllers/drag.js +3 -2
- package/internals/controllers/drag.js.map +1 -0
- package/{components/common → internals}/controllers/focus-ring.js +5 -2
- package/internals/controllers/focus-ring.js.map +1 -0
- package/{components/common → internals}/controllers/fullscreen.js +6 -3
- package/internals/controllers/fullscreen.js.map +1 -0
- package/{components/common → internals}/controllers/gestures.d.ts +1 -1
- package/{components/common → internals}/controllers/gestures.js +4 -4
- package/internals/controllers/gestures.js.map +1 -0
- package/{components/common → internals}/controllers/id-resolver.js +15 -21
- package/internals/controllers/id-resolver.js.map +1 -0
- package/{components/common → internals}/controllers/internals.d.ts +39 -3
- package/{components/common → internals}/controllers/internals.js +28 -0
- package/internals/controllers/internals.js.map +1 -0
- package/{components/common → internals}/controllers/key-bindings.d.ts +3 -6
- package/{components/common → internals}/controllers/key-bindings.js +43 -29
- package/internals/controllers/key-bindings.js.map +1 -0
- package/{components/common → internals}/controllers/mutation-observer.d.ts +3 -2
- package/{components/common → internals}/controllers/mutation-observer.js +24 -22
- package/internals/controllers/mutation-observer.js.map +1 -0
- package/{components/common → internals}/controllers/resize-observer.d.ts +11 -1
- package/{components/common → internals}/controllers/resize-observer.js +13 -2
- package/internals/controllers/resize-observer.js.map +1 -0
- package/{components/common → internals}/controllers/root-click.js +8 -13
- package/internals/controllers/root-click.js.map +1 -0
- package/{components/common → internals}/controllers/root-scroll.d.ts +11 -8
- package/internals/controllers/root-scroll.js +71 -0
- package/internals/controllers/root-scroll.js.map +1 -0
- package/{components/common → internals}/controllers/slot.d.ts +17 -1
- package/{components/common → internals}/controllers/slot.js +18 -6
- package/internals/controllers/slot.js.map +1 -0
- package/internals/date/compare.d.ts +2 -0
- package/internals/date/compare.js +23 -0
- package/internals/date/compare.js.map +1 -0
- package/internals/date/converters.d.ts +18 -0
- package/internals/date/converters.js +73 -0
- package/internals/date/converters.js.map +1 -0
- package/{components/calendar → internals/date}/model.d.ts +6 -3
- package/{components/calendar → internals/date}/model.js +23 -0
- package/internals/date/model.js.map +1 -0
- package/internals/decorators/blazorAdditionalDependencies.js.map +1 -0
- package/internals/decorators/blazorDeepImport.js.map +1 -0
- package/internals/decorators/blazorInclude.js.map +1 -0
- package/internals/decorators/blazorIndirectRender.js.map +1 -0
- package/internals/decorators/blazorSuppressComponent.js.map +1 -0
- package/internals/decorators/shadow-options.js.map +1 -0
- package/internals/decorators/watch.js.map +1 -0
- package/internals/definitions/defineAllComponents.js +153 -0
- package/internals/definitions/defineAllComponents.js.map +1 -0
- package/internals/definitions/defineComponents.js.map +1 -0
- package/internals/definitions/register.js.map +1 -0
- package/{components/common → internals}/i18n/EN/calendar.resources.js +1 -1
- package/internals/i18n/EN/calendar.resources.js.map +1 -0
- package/internals/i18n/EN/chat.resources.js.map +1 -0
- package/internals/i18n/EN/date-picker.resources.js.map +1 -0
- package/internals/i18n/EN/date-range-picker.resources.js.map +1 -0
- package/internals/i18n/i18n-controller.js.map +1 -0
- package/{components/common → internals}/i18n/utils.js +1 -1
- package/internals/i18n/utils.js.map +1 -0
- package/{components/common → internals}/mixins/alert.d.ts +2 -2
- package/{components/common → internals}/mixins/alert.js +3 -3
- package/internals/mixins/alert.js.map +1 -0
- package/{components/common → internals}/mixins/combo-box.d.ts +10 -2
- package/{components/common → internals}/mixins/combo-box.js +9 -4
- package/internals/mixins/combo-box.js.map +1 -0
- package/internals/mixins/constructor.js.map +1 -0
- package/internals/mixins/event-emitter.js.map +1 -0
- package/{components/common → internals}/mixins/forms/associated-required.js +10 -19
- package/internals/mixins/forms/associated-required.js.map +1 -0
- package/{components/common → internals}/mixins/forms/associated.js +45 -38
- package/internals/mixins/forms/associated.js.map +1 -0
- package/{components/common → internals}/mixins/forms/form-transformers.d.ts +1 -1
- package/{components/common → internals}/mixins/forms/form-transformers.js +2 -2
- package/internals/mixins/forms/form-transformers.js.map +1 -0
- package/internals/mixins/forms/form-value.js.map +1 -0
- package/{components/common → internals}/mixins/forms/types.d.ts +5 -6
- package/internals/mixins/forms/types.js.map +1 -0
- package/{components/common → internals}/mixins/mask-behavior.d.ts +11 -3
- package/{components/common → internals}/mixins/mask-behavior.js +117 -29
- package/internals/mixins/mask-behavior.js.map +1 -0
- package/{components/common → internals}/mixins/option.d.ts +0 -2
- package/{components/common → internals}/mixins/option.js +1 -4
- package/internals/mixins/option.js.map +1 -0
- package/internals/part-map.js.map +1 -0
- package/{components/common → internals}/templates/input-shell.d.ts +8 -1
- package/{components/common → internals}/templates/input-shell.js +14 -4
- package/internals/templates/input-shell.js.map +1 -0
- package/{components/common → internals}/templates/masked-input.d.ts +8 -4
- package/{components/common → internals}/templates/masked-input.js +4 -3
- package/internals/templates/masked-input.js.map +1 -0
- package/internals/utils/arrays.d.ts +53 -0
- package/internals/utils/arrays.js +31 -0
- package/internals/utils/arrays.js.map +1 -0
- package/internals/utils/dom.d.ts +92 -0
- package/internals/utils/dom.js +143 -0
- package/internals/utils/dom.js.map +1 -0
- package/internals/utils/events.d.ts +41 -0
- package/internals/utils/events.js +37 -0
- package/internals/utils/events.js.map +1 -0
- package/internals/utils/lit.d.ts +8 -0
- package/internals/utils/lit.js +15 -0
- package/internals/utils/lit.js.map +1 -0
- package/internals/utils/math.d.ts +50 -0
- package/internals/utils/math.js +38 -0
- package/internals/utils/math.js.map +1 -0
- package/internals/utils/objects.d.ts +25 -0
- package/internals/utils/objects.js +125 -0
- package/internals/utils/objects.js.map +1 -0
- package/internals/utils/strings.d.ts +44 -0
- package/internals/utils/strings.js +46 -0
- package/internals/utils/strings.js.map +1 -0
- package/internals/utils/types.d.ts +13 -0
- package/internals/utils/types.js +31 -0
- package/internals/utils/types.js.map +1 -0
- package/{components/common → internals}/validators.d.ts +1 -1
- package/{components/common → internals}/validators.js +4 -2
- package/internals/validators.js.map +1 -0
- package/package.json +15 -7
- package/themes/dark/bootstrap.css +1 -1
- package/themes/dark/fluent.css +1 -1
- package/themes/dark/indigo.css +1 -1
- package/themes/dark/material.css +1 -1
- package/themes/light/bootstrap.css +1 -1
- package/themes/light/fluent.css +1 -1
- package/themes/light/indigo.css +1 -1
- package/themes/light/material.css +1 -1
- package/theming/theming-controller.d.ts +2 -2
- package/theming/theming-controller.js.map +1 -1
- package/web-types.json +3 -3
- package/components/calendar/model.js.map +0 -1
- package/components/combo/combo-list.d.ts +0 -11
- package/components/combo/combo-list.js +0 -13
- package/components/combo/combo-list.js.map +0 -1
- package/components/common/abort-handler.js.map +0 -1
- package/components/common/context.d.ts +0 -25
- package/components/common/context.js.map +0 -1
- package/components/common/controllers/adopt-styles.d.ts +0 -124
- package/components/common/controllers/adopt-styles.js +0 -75
- package/components/common/controllers/adopt-styles.js.map +0 -1
- package/components/common/controllers/async-consumer.js.map +0 -1
- package/components/common/controllers/command.js.map +0 -1
- package/components/common/controllers/drag.js.map +0 -1
- package/components/common/controllers/focus-ring.js.map +0 -1
- package/components/common/controllers/fullscreen.js.map +0 -1
- package/components/common/controllers/gestures.js.map +0 -1
- package/components/common/controllers/id-resolver.js.map +0 -1
- package/components/common/controllers/internals.js.map +0 -1
- package/components/common/controllers/key-bindings.js.map +0 -1
- package/components/common/controllers/mutation-observer.js.map +0 -1
- package/components/common/controllers/resize-observer.js.map +0 -1
- package/components/common/controllers/root-click.js.map +0 -1
- package/components/common/controllers/root-scroll.js +0 -63
- package/components/common/controllers/root-scroll.js.map +0 -1
- package/components/common/controllers/slot.js.map +0 -1
- package/components/common/decorators/blazorAdditionalDependencies.js.map +0 -1
- package/components/common/decorators/blazorDeepImport.js.map +0 -1
- package/components/common/decorators/blazorInclude.js.map +0 -1
- package/components/common/decorators/blazorIndirectRender.js.map +0 -1
- package/components/common/decorators/blazorSuppressComponent.js.map +0 -1
- package/components/common/decorators/shadow-options.js.map +0 -1
- package/components/common/decorators/watch.js.map +0 -1
- package/components/common/definitions/defineAllComponents.js +0 -151
- package/components/common/definitions/defineAllComponents.js.map +0 -1
- package/components/common/definitions/defineComponents.js.map +0 -1
- package/components/common/definitions/register.js.map +0 -1
- package/components/common/i18n/EN/calendar.resources.js.map +0 -1
- package/components/common/i18n/EN/chat.resources.js.map +0 -1
- package/components/common/i18n/EN/date-picker.resources.js.map +0 -1
- package/components/common/i18n/EN/date-range-picker.resources.js.map +0 -1
- package/components/common/i18n/i18n-controller.js.map +0 -1
- package/components/common/i18n/utils.js.map +0 -1
- package/components/common/mixins/alert.js.map +0 -1
- package/components/common/mixins/combo-box.js.map +0 -1
- package/components/common/mixins/constructor.js.map +0 -1
- package/components/common/mixins/event-emitter.js.map +0 -1
- package/components/common/mixins/forms/associated-required.js.map +0 -1
- package/components/common/mixins/forms/associated.js.map +0 -1
- package/components/common/mixins/forms/form-transformers.js.map +0 -1
- package/components/common/mixins/forms/form-value.js.map +0 -1
- package/components/common/mixins/forms/types.js.map +0 -1
- package/components/common/mixins/mask-behavior.js.map +0 -1
- package/components/common/mixins/option.js.map +0 -1
- package/components/common/part-map.js.map +0 -1
- package/components/common/templates/input-shell.js.map +0 -1
- package/components/common/templates/masked-input.js.map +0 -1
- package/components/common/util.d.ts +0 -196
- package/components/common/util.js +0 -390
- package/components/common/util.js.map +0 -1
- package/components/common/validators.js.map +0 -1
- package/components/icon/registry/default-map.d.ts +0 -107
- package/components/icon/registry/default-map.js +0 -25
- package/components/icon/registry/default-map.js.map +0 -1
- package/components/nav-drawer/themes/shared/container/nav-drawer.fluent.css.js +0 -3
- package/components/nav-drawer/themes/shared/container/nav-drawer.fluent.css.js.map +0 -1
- package/components/radio/utils.d.ts +0 -13
- package/components/radio/utils.js +0 -37
- package/components/radio/utils.js.map +0 -1
- /package/components/{nav-drawer/themes/shared/container/nav-drawer.fluent.css.d.ts → qr-code/themes/dark/qr-code.bootstrap.css.d.ts} +0 -0
- /package/{components/common → internals}/abort-handler.d.ts +0 -0
- /package/{components/common → internals}/abort-handler.js +0 -0
- /package/{components/common → internals}/controllers/async-consumer.d.ts +0 -0
- /package/{components/common → internals}/controllers/command.d.ts +0 -0
- /package/{components/common → internals}/controllers/command.js +0 -0
- /package/{components/common → internals}/controllers/drag.d.ts +0 -0
- /package/{components/common → internals}/controllers/focus-ring.d.ts +0 -0
- /package/{components/common → internals}/controllers/fullscreen.d.ts +0 -0
- /package/{components/common → internals}/controllers/id-resolver.d.ts +0 -0
- /package/{components/common → internals}/controllers/root-click.d.ts +0 -0
- /package/{components/common → internals}/decorators/blazorAdditionalDependencies.d.ts +0 -0
- /package/{components/common → internals}/decorators/blazorAdditionalDependencies.js +0 -0
- /package/{components/common → internals}/decorators/blazorDeepImport.d.ts +0 -0
- /package/{components/common → internals}/decorators/blazorDeepImport.js +0 -0
- /package/{components/common → internals}/decorators/blazorInclude.d.ts +0 -0
- /package/{components/common → internals}/decorators/blazorInclude.js +0 -0
- /package/{components/common → internals}/decorators/blazorIndirectRender.d.ts +0 -0
- /package/{components/common → internals}/decorators/blazorIndirectRender.js +0 -0
- /package/{components/common → internals}/decorators/blazorSuppressComponent.d.ts +0 -0
- /package/{components/common → internals}/decorators/blazorSuppressComponent.js +0 -0
- /package/{components/common → internals}/decorators/shadow-options.d.ts +0 -0
- /package/{components/common → internals}/decorators/shadow-options.js +0 -0
- /package/{components/common → internals}/decorators/watch.d.ts +0 -0
- /package/{components/common → internals}/decorators/watch.js +0 -0
- /package/{components/common → internals}/definitions/defineAllComponents.d.ts +0 -0
- /package/{components/common → internals}/definitions/defineComponents.d.ts +0 -0
- /package/{components/common → internals}/definitions/defineComponents.js +0 -0
- /package/{components/common → internals}/definitions/register.d.ts +0 -0
- /package/{components/common → internals}/definitions/register.js +0 -0
- /package/{components/common → internals}/i18n/EN/calendar.resources.d.ts +0 -0
- /package/{components/common → internals}/i18n/EN/chat.resources.d.ts +0 -0
- /package/{components/common → internals}/i18n/EN/chat.resources.js +0 -0
- /package/{components/common → internals}/i18n/EN/date-picker.resources.d.ts +0 -0
- /package/{components/common → internals}/i18n/EN/date-picker.resources.js +0 -0
- /package/{components/common → internals}/i18n/EN/date-range-picker.resources.d.ts +0 -0
- /package/{components/common → internals}/i18n/EN/date-range-picker.resources.js +0 -0
- /package/{components/common → internals}/i18n/i18n-controller.d.ts +0 -0
- /package/{components/common → internals}/i18n/i18n-controller.js +0 -0
- /package/{components/common → internals}/i18n/utils.d.ts +0 -0
- /package/{components/common → internals}/mixins/constructor.d.ts +0 -0
- /package/{components/common → internals}/mixins/constructor.js +0 -0
- /package/{components/common → internals}/mixins/event-emitter.d.ts +0 -0
- /package/{components/common → internals}/mixins/event-emitter.js +0 -0
- /package/{components/common → internals}/mixins/forms/associated-required.d.ts +0 -0
- /package/{components/common → internals}/mixins/forms/associated.d.ts +0 -0
- /package/{components/common → internals}/mixins/forms/form-value.d.ts +0 -0
- /package/{components/common → internals}/mixins/forms/form-value.js +0 -0
- /package/{components/common → internals}/mixins/forms/types.js +0 -0
- /package/{components/common → internals}/part-map.d.ts +0 -0
- /package/{components/common → internals}/part-map.js +0 -0
|
@@ -8,20 +8,31 @@ var IgcDaysViewComponent_1;
|
|
|
8
8
|
import { getDateFormatter, getDisplayNamesFormatter } from 'igniteui-i18n-core';
|
|
9
9
|
import { html, nothing } from 'lit';
|
|
10
10
|
import { property, query, state } from 'lit/decorators.js';
|
|
11
|
-
import {
|
|
12
|
-
import { addKeybindings } from '
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
11
|
+
import { addInternalsController } from '#internals/controllers/internals.js';
|
|
12
|
+
import { addKeybindings } from '#internals/controllers/key-bindings.js';
|
|
13
|
+
import { CalendarDay, DAYS_IN_WEEK } from '#internals/date/model.js';
|
|
14
|
+
import { blazorIndirectRender } from '#internals/decorators/blazorIndirectRender.js';
|
|
15
|
+
import { blazorSuppressComponent } from '#internals/decorators/blazorSuppressComponent.js';
|
|
16
|
+
import { registerComponent } from '#internals/definitions/register.js';
|
|
17
|
+
import { EventEmitterMixin } from '#internals/mixins/event-emitter.js';
|
|
18
|
+
import { partMap } from '#internals/part-map.js';
|
|
19
|
+
import { chunk, firstOf, lastOf } from '#internals/utils/arrays.js';
|
|
20
|
+
import { addSafeEventListener } from '#internals/utils/events.js';
|
|
21
|
+
import { addThemingController } from '#theming/theming-controller.js';
|
|
19
22
|
import { IgcCalendarBaseComponent } from '../base.js';
|
|
20
|
-
import { areSameMonth,
|
|
21
|
-
import {
|
|
22
|
-
import { all } from '../themes/days.js';
|
|
23
|
+
import { areSameMonth, generateMonth, getViewElement, isDateInRanges, isNextMonth, isPreviousMonth, } from '../helpers.js';
|
|
24
|
+
import { selectDate } from '../selection.js';
|
|
23
25
|
import { styles } from '../themes/days-view.base.css.js';
|
|
24
|
-
import {
|
|
26
|
+
import { all } from '../themes/days.js';
|
|
27
|
+
function boundsOf(first, second) {
|
|
28
|
+
const [a, b] = [first.timestamp, second.timestamp];
|
|
29
|
+
return { min: Math.min(a, b), max: Math.max(a, b) };
|
|
30
|
+
}
|
|
31
|
+
function isInBounds(day, bounds) {
|
|
32
|
+
return bounds
|
|
33
|
+
? day.timestamp >= bounds.min && day.timestamp <= bounds.max
|
|
34
|
+
: false;
|
|
35
|
+
}
|
|
25
36
|
let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(IgcCalendarBaseComponent) {
|
|
26
37
|
static { IgcDaysViewComponent_1 = this; }
|
|
27
38
|
static { this.tagName = 'igc-days-view'; }
|
|
@@ -30,10 +41,10 @@ let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(
|
|
|
30
41
|
registerComponent(IgcDaysViewComponent_1);
|
|
31
42
|
}
|
|
32
43
|
get _rangeStart() {
|
|
33
|
-
return this._hasValues ?
|
|
44
|
+
return this._hasValues ? firstOf(this._values) : undefined;
|
|
34
45
|
}
|
|
35
46
|
get _rangeEnd() {
|
|
36
|
-
return this._hasValues ?
|
|
47
|
+
return this._hasValues ? lastOf(this._values) : undefined;
|
|
37
48
|
}
|
|
38
49
|
get _weekLabel() {
|
|
39
50
|
return getDisplayNamesFormatter().getWeekLabel(this.locale, {
|
|
@@ -49,20 +60,20 @@ let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(
|
|
|
49
60
|
constructor() {
|
|
50
61
|
super();
|
|
51
62
|
this._dates = [];
|
|
52
|
-
this.active =
|
|
63
|
+
this.active = true;
|
|
53
64
|
this.hideLeadingDays = false;
|
|
54
65
|
this.hideTrailingDays = false;
|
|
55
66
|
this.weekDayFormat = 'narrow';
|
|
67
|
+
addInternalsController(this, {
|
|
68
|
+
initialARIA: { role: 'grid' },
|
|
69
|
+
reflectRole: true,
|
|
70
|
+
});
|
|
56
71
|
addThemingController(this, all);
|
|
57
72
|
addKeybindings(this).setActivateHandler(this._handleInteraction);
|
|
58
73
|
addSafeEventListener(this, 'click', this._handleInteraction);
|
|
59
74
|
}
|
|
60
|
-
connectedCallback() {
|
|
61
|
-
super.connectedCallback();
|
|
62
|
-
this.role = 'grid';
|
|
63
|
-
}
|
|
64
75
|
update(props) {
|
|
65
|
-
if (props.has('
|
|
76
|
+
if (props.has('_activeDate') || props.has('weekStart')) {
|
|
66
77
|
this._dates = Array.from(generateMonth(this._activeDate, this._firstDayOfWeek));
|
|
67
78
|
}
|
|
68
79
|
super.update(props);
|
|
@@ -84,72 +95,22 @@ let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(
|
|
|
84
95
|
}
|
|
85
96
|
}
|
|
86
97
|
_selectDate(value) {
|
|
87
|
-
|
|
98
|
+
const selection = selectDate({ value: this._value, values: this._values }, value, { selection: this.selection, disabledDates: this._disabledDates });
|
|
99
|
+
if (!selection) {
|
|
88
100
|
return false;
|
|
89
101
|
}
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
if (this._value?.equalTo(value)) {
|
|
93
|
-
return false;
|
|
94
|
-
}
|
|
95
|
-
this._value = value;
|
|
96
|
-
break;
|
|
97
|
-
case 'multiple':
|
|
98
|
-
this._selectMultiple(value);
|
|
99
|
-
break;
|
|
100
|
-
case 'range':
|
|
101
|
-
this._selectRange(value);
|
|
102
|
-
break;
|
|
103
|
-
}
|
|
102
|
+
this._value = selection.value;
|
|
103
|
+
this._values = selection.values;
|
|
104
104
|
return true;
|
|
105
105
|
}
|
|
106
|
-
|
|
107
|
-
const idx = this._values.findIndex((v) => v.equalTo(day));
|
|
108
|
-
if (idx < 0) {
|
|
109
|
-
this._values.push(day);
|
|
110
|
-
}
|
|
111
|
-
else {
|
|
112
|
-
this._values.splice(idx, 1);
|
|
113
|
-
}
|
|
114
|
-
this._values = this._values.toSorted((a, b) => a.timestamp - b.timestamp);
|
|
115
|
-
}
|
|
116
|
-
_selectRange(day) {
|
|
117
|
-
if (this._values.length !== 1) {
|
|
118
|
-
this._values = [day];
|
|
119
|
-
return;
|
|
120
|
-
}
|
|
121
|
-
const rangeStart = this._rangeStart;
|
|
122
|
-
if (rangeStart.equalTo(day)) {
|
|
123
|
-
this._values = [];
|
|
124
|
-
return;
|
|
125
|
-
}
|
|
126
|
-
const [start, end] = rangeStart.greaterThan(day)
|
|
127
|
-
? [day, rangeStart]
|
|
128
|
-
: [rangeStart, day];
|
|
129
|
-
const range = Array.from(calendarRange({ start, end }));
|
|
130
|
-
range.push(last(range).add('day', 1));
|
|
131
|
-
this._values = range.filter((v) => !isDateInRanges(v, this._disabledDates));
|
|
132
|
-
}
|
|
133
|
-
_isSelected(day) {
|
|
134
|
-
if (isDateInRanges(day, this._disabledDates)) {
|
|
135
|
-
return false;
|
|
136
|
-
}
|
|
106
|
+
_isSelected(day, context) {
|
|
137
107
|
switch (this.selection) {
|
|
138
108
|
case 'single':
|
|
139
109
|
return Boolean(this._value?.equalTo(day));
|
|
140
110
|
case 'multiple':
|
|
141
|
-
return (
|
|
142
|
-
isDateInRanges(day, [
|
|
143
|
-
{ type: DateRangeType.Specific, dateRange: this.values },
|
|
144
|
-
]));
|
|
111
|
+
return context.selectedDates.has(day.timestamp);
|
|
145
112
|
case 'range':
|
|
146
|
-
return (
|
|
147
|
-
isDateInRanges(day, [
|
|
148
|
-
{
|
|
149
|
-
type: DateRangeType.Between,
|
|
150
|
-
dateRange: [this._rangeStart.native, this._rangeEnd.native],
|
|
151
|
-
},
|
|
152
|
-
]));
|
|
113
|
+
return isInBounds(day, context.selectedRange);
|
|
153
114
|
}
|
|
154
115
|
}
|
|
155
116
|
_setRangePreviewDate(day) {
|
|
@@ -159,7 +120,7 @@ let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(
|
|
|
159
120
|
});
|
|
160
121
|
}
|
|
161
122
|
_changeRangePreview(day) {
|
|
162
|
-
if (this._values.length === 1 && !
|
|
123
|
+
if (this._values.length === 1 && !this._rangeStart.equalTo(day)) {
|
|
163
124
|
this._setRangePreviewDate(day);
|
|
164
125
|
}
|
|
165
126
|
}
|
|
@@ -168,66 +129,50 @@ let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(
|
|
|
168
129
|
this._setRangePreviewDate();
|
|
169
130
|
}
|
|
170
131
|
}
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
if (
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
]);
|
|
206
|
-
}
|
|
207
|
-
_isRangePreview(day) {
|
|
208
|
-
if (!this._hasValues || !this._rangePreviewDate)
|
|
209
|
-
return false;
|
|
210
|
-
return isDateInRanges(day, [
|
|
211
|
-
{
|
|
212
|
-
type: DateRangeType.Between,
|
|
213
|
-
dateRange: [this._rangeStart.native, this._rangePreviewDate.native],
|
|
214
|
-
},
|
|
215
|
-
]);
|
|
132
|
+
_createRenderContext() {
|
|
133
|
+
const context = {
|
|
134
|
+
today: CalendarDay.today,
|
|
135
|
+
formatter: getDateFormatter().getIntlFormatter(this.locale, {
|
|
136
|
+
weekday: 'long',
|
|
137
|
+
year: 'numeric',
|
|
138
|
+
month: 'long',
|
|
139
|
+
day: 'numeric',
|
|
140
|
+
}),
|
|
141
|
+
selectedDates: new Set(),
|
|
142
|
+
};
|
|
143
|
+
if (this._isMultiple) {
|
|
144
|
+
for (const value of this._values) {
|
|
145
|
+
context.selectedDates.add(value.timestamp);
|
|
146
|
+
}
|
|
147
|
+
return context;
|
|
148
|
+
}
|
|
149
|
+
if (!this._isRange || !this._hasValues) {
|
|
150
|
+
return context;
|
|
151
|
+
}
|
|
152
|
+
const start = this._rangeStart;
|
|
153
|
+
const end = this._rangeEnd;
|
|
154
|
+
const preview = this._rangePreviewDate;
|
|
155
|
+
context.selectedRange = boundsOf(start, end);
|
|
156
|
+
context.first = (preview?.lessThan(start) ? preview : start).timestamp;
|
|
157
|
+
context.last = (preview?.greaterThan(end) ? preview : end).timestamp;
|
|
158
|
+
if (preview) {
|
|
159
|
+
context.previewDates = boundsOf(start, preview);
|
|
160
|
+
}
|
|
161
|
+
const rangeEnd = this._values.length === 1 ? preview : end;
|
|
162
|
+
if (rangeEnd) {
|
|
163
|
+
context.rangeDates = boundsOf(start, rangeEnd);
|
|
164
|
+
}
|
|
165
|
+
return context;
|
|
216
166
|
}
|
|
217
|
-
_intlFormatDay(day) {
|
|
218
|
-
const
|
|
219
|
-
weekday: 'long',
|
|
220
|
-
year: 'numeric',
|
|
221
|
-
month: 'long',
|
|
222
|
-
day: 'numeric',
|
|
223
|
-
});
|
|
167
|
+
_intlFormatDay(day, context) {
|
|
168
|
+
const { formatter, first, last } = context;
|
|
224
169
|
if (this._rangePreviewDate?.equalTo(day)) {
|
|
225
|
-
return
|
|
170
|
+
return formatter.formatRange(this._rangeStart.native, this._rangePreviewDate.native);
|
|
226
171
|
}
|
|
227
|
-
if (
|
|
228
|
-
return
|
|
172
|
+
if (day.timestamp === first || day.timestamp === last) {
|
|
173
|
+
return formatter.formatRange(this._rangeStart.native, this._rangeEnd.native);
|
|
229
174
|
}
|
|
230
|
-
return
|
|
175
|
+
return formatter.format(day.native);
|
|
231
176
|
}
|
|
232
177
|
_getDayHandlers(day) {
|
|
233
178
|
if (!this._isRange) {
|
|
@@ -238,31 +183,31 @@ let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(
|
|
|
238
183
|
clearPreview: this._clearRangePreview.bind(this),
|
|
239
184
|
};
|
|
240
185
|
}
|
|
241
|
-
_getDayProperties(day,
|
|
186
|
+
_getDayProperties(day, context) {
|
|
242
187
|
const inactive = !areSameMonth(day, this._activeDate);
|
|
243
188
|
const disabled = isDateInRanges(day, this._disabledDates);
|
|
244
189
|
const hidden = (this.hideLeadingDays && isPreviousMonth(day, this._activeDate)) ||
|
|
245
190
|
(this.hideTrailingDays && isNextMonth(day, this._activeDate));
|
|
246
191
|
return {
|
|
247
192
|
disabled: disabled || hidden,
|
|
248
|
-
first:
|
|
249
|
-
last:
|
|
250
|
-
range:
|
|
251
|
-
preview:
|
|
252
|
-
current: !inactive && day.equalTo(today),
|
|
193
|
+
first: day.timestamp === context.first,
|
|
194
|
+
last: day.timestamp === context.last,
|
|
195
|
+
range: isInBounds(day, context.rangeDates),
|
|
196
|
+
preview: isInBounds(day, context.previewDates),
|
|
197
|
+
current: !inactive && day.equalTo(context.today),
|
|
253
198
|
inactive,
|
|
254
199
|
hidden,
|
|
255
200
|
weekend: day.weekend,
|
|
256
201
|
single: !this._isRange,
|
|
257
|
-
selected: !disabled && this._isSelected(day),
|
|
202
|
+
selected: !disabled && this._isSelected(day, context),
|
|
258
203
|
special: !inactive && isDateInRanges(day, this._specialDates),
|
|
259
204
|
};
|
|
260
205
|
}
|
|
261
206
|
focusActiveDate(options) {
|
|
262
207
|
this._activeDay?.focus(options);
|
|
263
208
|
}
|
|
264
|
-
_renderDayWithProps(day, props) {
|
|
265
|
-
const ariaLabel = this._intlFormatDay(day);
|
|
209
|
+
_renderDayWithProps(day, props, context) {
|
|
210
|
+
const ariaLabel = this._intlFormatDay(day, context);
|
|
266
211
|
const { changePreview, clearPreview } = this._getDayHandlers(day);
|
|
267
212
|
return html `
|
|
268
213
|
<span part=${partMap({ date: true, ...props })}>
|
|
@@ -273,7 +218,7 @@ let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(
|
|
|
273
218
|
aria-disabled=${props.disabled}
|
|
274
219
|
aria-selected=${props.selected}
|
|
275
220
|
data-value=${day.timestamp}
|
|
276
|
-
tabindex=${day.equalTo(this._activeDate) ? 0 : -1}
|
|
221
|
+
tabindex=${this.active && day.equalTo(this._activeDate) ? 0 : -1}
|
|
277
222
|
@focus=${changePreview}
|
|
278
223
|
@blur=${clearPreview}
|
|
279
224
|
@pointerenter=${changePreview}
|
|
@@ -310,39 +255,33 @@ let IgcDaysViewComponent = class IgcDaysViewComponent extends EventEmitterMixin(
|
|
|
310
255
|
const weekNumber = this.showWeekNumbers
|
|
311
256
|
? this._renderHeaderWeekNumber()
|
|
312
257
|
: nothing;
|
|
313
|
-
const headers =
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
</span>
|
|
323
|
-
`)
|
|
324
|
-
.toArray();
|
|
258
|
+
const headers = this._dates.slice(0, DAYS_IN_WEEK).map((day) => html `
|
|
259
|
+
<span
|
|
260
|
+
role="columnheader"
|
|
261
|
+
part="label"
|
|
262
|
+
aria-label=${aria.format(day.native)}
|
|
263
|
+
>
|
|
264
|
+
<span part="label-inner">${label.format(day.native)}</span>
|
|
265
|
+
</span>
|
|
266
|
+
`);
|
|
325
267
|
return html `
|
|
326
268
|
<div role="row" part="days-row first">${weekNumber}${headers}</div>
|
|
327
269
|
`;
|
|
328
270
|
}
|
|
329
271
|
*_renderWeeks() {
|
|
330
|
-
const
|
|
272
|
+
const context = this._createRenderContext();
|
|
331
273
|
const weeks = Array.from(chunk(this._dates, DAYS_IN_WEEK));
|
|
332
274
|
const lastIndex = weeks.length - 1;
|
|
333
|
-
const dayPropertiesMap = new Map();
|
|
334
|
-
for (const day of this._dates) {
|
|
335
|
-
dayPropertiesMap.set(day.timestamp, this._getDayProperties(day, today));
|
|
336
|
-
}
|
|
337
275
|
for (const [idx, week] of weeks.entries()) {
|
|
338
276
|
const isLast = idx === lastIndex;
|
|
339
|
-
const
|
|
277
|
+
const properties = week.map((day) => this._getDayProperties(day, context));
|
|
278
|
+
const hidden = properties.every((props) => props.hidden);
|
|
340
279
|
yield html `
|
|
341
280
|
<div role="row" part="days-row" aria-hidden=${hidden}>
|
|
342
281
|
${this.showWeekNumbers
|
|
343
282
|
? this._renderWeekNumber(week[0], isLast)
|
|
344
283
|
: nothing}
|
|
345
|
-
${week.map((day) => this._renderDayWithProps(day,
|
|
284
|
+
${week.map((day, i) => this._renderDayWithProps(day, properties[i], context))}
|
|
346
285
|
</div>
|
|
347
286
|
`;
|
|
348
287
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"days-view.js","sourceRoot":"","sources":["../../../../src/components/calendar/days-view/days-view.ts"],"names":[],"mappings":";;;;;;;AAAA,OAAO,EAAE,gBAAgB,EAAE,wBAAwB,EAAE,MAAM,oBAAoB,CAAC;AAChF,OAAO,EAAE,IAAI,EAAE,OAAO,EAA4C,MAAM,KAAK,CAAC;AAC9E,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,EAAE,oBAAoB,EAAE,MAAM,wCAAwC,CAAC;AAC9E,OAAO,EAAE,cAAc,EAAE,MAAM,0CAA0C,CAAC;AAC1E,OAAO,EAAE,oBAAoB,EAAE,MAAM,iDAAiD,CAAC;AACvF,OAAO,EAAE,uBAAuB,EAAE,MAAM,oDAAoD,CAAC;AAC7F,OAAO,EAAE,iBAAiB,EAAE,MAAM,sCAAsC,CAAC;AAEzE,OAAO,EAAE,iBAAiB,EAAE,MAAM,sCAAsC,CAAC;AACzE,OAAO,EAAE,OAAO,EAAE,MAAM,0BAA0B,CAAC;AACnD,OAAO,EAAE,oBAAoB,EAAE,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAChF,OAAO,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AACtD,OAAO,EACL,YAAY,EACZ,aAAa,EACb,aAAa,EACb,cAAc,EACd,cAAc,EACd,WAAW,EACX,eAAe,GAChB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AACxD,OAAO,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AACxC,OAAO,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAC;AACzD,OAAO,EAAE,aAAa,EAAqC,MAAM,aAAa,CAAC;AAsChE,IAAM,oBAAoB,GAA1B,MAAM,oBAAqB,SAAQ,iBAAiB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esContent":["import { getDateFormatter, getDisplayNamesFormatter } from 'igniteui-i18n-core';\nimport { html, nothing, type PropertyValues, type TemplateResult } from 'lit';\nimport { property, query, state } from 'lit/decorators.js';\nimport { addThemingController } from '../../../theming/theming-controller.js';\nimport { addKeybindings } from '../../common/controllers/key-bindings.js';\nimport { blazorIndirectRender } from '../../common/decorators/blazorIndirectRender.js';\nimport { blazorSuppressComponent } from '../../common/decorators/blazorSuppressComponent.js';\nimport { registerComponent } from '../../common/definitions/register.js';\nimport type { Constructor } from '../../common/mixins/constructor.js';\nimport { EventEmitterMixin } from '../../common/mixins/event-emitter.js';\nimport { partMap } from '../../common/part-map.js';\nimport { addSafeEventListener, chunk, first, last } from '../../common/util.js';\nimport { IgcCalendarBaseComponent } from '../base.js';\nimport {\n areSameMonth,\n calendarRange,\n generateMonth,\n getViewElement,\n isDateInRanges,\n isNextMonth,\n isPreviousMonth,\n} from '../helpers.js';\nimport { CalendarDay, DAYS_IN_WEEK } from '../model.js';\nimport { all } from '../themes/days.js';\nimport { styles } from '../themes/days-view.base.css.js';\nimport { DateRangeType, type IgcCalendarComponentEventMap } from '../types.js';\n\nexport interface IgcDaysViewEventMap extends IgcCalendarComponentEventMap {\n igcActiveDateChange: CustomEvent<Date>;\n igcRangePreviewDateChange: CustomEvent<Date>;\n}\n\ninterface DayProperties {\n disabled: boolean;\n first: boolean;\n last: boolean;\n range: boolean;\n preview: boolean;\n current: boolean;\n inactive: boolean;\n hidden: boolean;\n weekend: boolean;\n single: boolean;\n selected: boolean;\n special: boolean;\n}\n\n/**\n * Instantiate a days view as a separate component in the calendar.\n *\n * @element igc-days-view\n *\n * @fires igcActiveDateChange - Emitted when the active date changes.\n * @fires igcRangePreviewDateChange - Emitted when the range preview date changes.\n *\n * @csspart days-row - The days row container.\n * @csspart label - The label container.\n * @csspart label-inner - The inner label container.\n * @csspart week-number - The week number container.\n * @csspart week-number-inner - The inner week number container.\n */\n@blazorSuppressComponent\n@blazorIndirectRender\nexport default class IgcDaysViewComponent extends EventEmitterMixin<\n IgcDaysViewEventMap,\n Constructor<IgcCalendarBaseComponent>\n>(IgcCalendarBaseComponent) {\n public static readonly tagName = 'igc-days-view';\n public static styles = styles;\n\n /* blazorSuppress */\n public static register(): void {\n registerComponent(IgcDaysViewComponent);\n }\n\n //#region Internal properties and state\n\n @state()\n private _dates: CalendarDay[] = [];\n\n @query('[tabindex=\"0\"]')\n private _activeDay?: HTMLElement;\n\n /** Returns the first date in the current range selection. */\n private get _rangeStart(): CalendarDay | undefined {\n return this._hasValues ? first(this._values) : undefined;\n }\n\n /** Returns the last date in the current range selection. */\n private get _rangeEnd(): CalendarDay | undefined {\n return this._hasValues ? last(this._values) : undefined;\n }\n\n private get _weekLabel(): string {\n return getDisplayNamesFormatter().getWeekLabel(this.locale, {\n style: 'short',\n });\n }\n\n //#endregion\n\n //#region Public attributes and properties\n\n /** The active state of the component. */\n @property({ type: Boolean })\n public active = false;\n\n /**\n * Whether to show leading days which do not belong to the current month.\n * @attr hide-leading-days\n */\n @property({ type: Boolean, attribute: 'hide-leading-days' })\n public hideLeadingDays = false;\n\n /**\n * Whether to show trailing days which do not belong to the current month.\n * @attr hide-trailing-days\n */\n @property({ type: Boolean, attribute: 'hide-trailing-days' })\n public hideTrailingDays = false;\n\n /** The range preview date. */\n @property({ attribute: false })\n public set rangePreviewDate(value: Date | undefined) {\n this._rangePreviewDate = value ? CalendarDay.from(value) : undefined;\n }\n\n public get rangePreviewDate(): Date | undefined {\n return this._rangePreviewDate?.native;\n }\n\n /**\n * The format of the days. Defaults to narrow.\n * @attr week-day-format\n */\n @property({ attribute: 'week-day-format' })\n public weekDayFormat: 'long' | 'short' | 'narrow' = 'narrow';\n\n //#endregion\n\n //#region Lifecycle hooks\n\n constructor() {\n super();\n\n addThemingController(this, all);\n addKeybindings(this).setActivateHandler(this._handleInteraction);\n addSafeEventListener(this, 'click', this._handleInteraction);\n }\n\n /** @internal */\n public override connectedCallback(): void {\n super.connectedCallback();\n this.role = 'grid';\n }\n\n /** @internal */\n protected override update(props: PropertyValues<this>): void {\n if (props.has('activeDate') || props.has('weekStart')) {\n this._dates = Array.from(\n generateMonth(this._activeDate, this._firstDayOfWeek)\n );\n }\n\n super.update(props);\n }\n\n //#endregion\n\n //#region Event handlers\n\n protected _handleInteraction(event: Event): void {\n const value = getViewElement(event);\n\n if (value !== -1) {\n const date = CalendarDay.from(new Date(value));\n\n if (this._rangePreviewDate) {\n this._setRangePreviewDate();\n }\n\n if (this._selectDate(date)) {\n this.emitEvent('igcChange', { detail: date.native });\n }\n\n if (event.type === 'click') {\n this.emitEvent('igcActiveDateChange', { detail: date.native });\n this._activeDate = date;\n }\n }\n }\n\n //#endregion\n\n //#region Internal selection methods\n\n private _selectDate(value: CalendarDay): boolean {\n if (isDateInRanges(value, this._disabledDates)) {\n return false;\n }\n\n switch (this.selection) {\n case 'single':\n if (this._value?.equalTo(value)) {\n return false;\n }\n this._value = value;\n break;\n case 'multiple':\n this._selectMultiple(value);\n break;\n case 'range':\n this._selectRange(value);\n break;\n }\n\n return true;\n }\n\n private _selectMultiple(day: CalendarDay): void {\n const idx = this._values.findIndex((v) => v.equalTo(day));\n\n if (idx < 0) {\n this._values.push(day);\n } else {\n this._values.splice(idx, 1);\n }\n\n this._values = this._values.toSorted((a, b) => a.timestamp - b.timestamp);\n }\n\n private _selectRange(day: CalendarDay): void {\n // Start a new range selection\n if (this._values.length !== 1) {\n this._values = [day];\n return;\n }\n\n const rangeStart = this._rangeStart!;\n\n // Clicking the same date clears the selection\n if (rangeStart.equalTo(day)) {\n this._values = [];\n return;\n }\n\n // Build the complete range, ensuring correct order\n const [start, end] = rangeStart.greaterThan(day)\n ? [day, rangeStart]\n : [rangeStart, day];\n\n const range = Array.from(calendarRange({ start, end }));\n range.push(last(range).add('day', 1));\n\n // Filter out disabled dates\n this._values = range.filter((v) => !isDateInRanges(v, this._disabledDates));\n }\n\n private _isSelected(day: CalendarDay): boolean {\n if (isDateInRanges(day, this._disabledDates)) {\n return false;\n }\n\n switch (this.selection) {\n case 'single':\n return Boolean(this._value?.equalTo(day));\n\n case 'multiple':\n return (\n this._hasValues &&\n isDateInRanges(day, [\n { type: DateRangeType.Specific, dateRange: this.values },\n ])\n );\n\n case 'range':\n return (\n this._hasValues &&\n isDateInRanges(day, [\n {\n type: DateRangeType.Between,\n dateRange: [this._rangeStart!.native, this._rangeEnd!.native],\n },\n ])\n );\n }\n }\n\n //#endregion\n\n //#region Range helpers\n\n private _setRangePreviewDate(day?: CalendarDay): void {\n this._rangePreviewDate = day;\n this.emitEvent('igcRangePreviewDateChange', {\n detail: day ? day.native : undefined,\n });\n }\n\n private _changeRangePreview(day: CalendarDay): void {\n if (this._values.length === 1 && !first(this._values).equalTo(day)) {\n this._setRangePreviewDate(day);\n }\n }\n\n private _clearRangePreview(): void {\n if (this._rangePreviewDate) {\n this._setRangePreviewDate();\n }\n }\n\n /** Gets the effective start of the visual range, accounting for preview. */\n private _getEffectiveRangeStart(): CalendarDay | undefined {\n if (!this._rangeStart) return undefined;\n\n return this._rangePreviewDate?.lessThan(this._rangeStart)\n ? this._rangePreviewDate\n : this._rangeStart;\n }\n\n /** Gets the effective end of the visual range, accounting for preview. */\n private _getEffectiveRangeEnd(): CalendarDay | undefined {\n if (!this._rangeEnd) return undefined;\n\n return this._rangePreviewDate?.greaterThan(this._rangeEnd)\n ? this._rangePreviewDate\n : this._rangeEnd;\n }\n\n private _isFirstInRange(day: CalendarDay): boolean {\n const effectiveStart = this._getEffectiveRangeStart();\n return this._isRange && Boolean(effectiveStart?.equalTo(day));\n }\n\n private _isLastInRange(day: CalendarDay): boolean {\n const effectiveEnd = this._getEffectiveRangeEnd();\n return this._isRange && Boolean(effectiveEnd?.equalTo(day));\n }\n\n private _isRangeDate(day: CalendarDay): boolean {\n if (!this._hasValues) return false;\n\n const isSingleSelection = this._values.length === 1;\n if (isSingleSelection && !this._rangePreviewDate) return false;\n\n const max = isSingleSelection ? this._rangePreviewDate! : this._rangeEnd!;\n\n return isDateInRanges(day, [\n {\n type: DateRangeType.Between,\n dateRange: [this._rangeStart!.native, max.native],\n },\n ]);\n }\n\n private _isRangePreview(day: CalendarDay): boolean {\n if (!this._hasValues || !this._rangePreviewDate) return false;\n\n return isDateInRanges(day, [\n {\n type: DateRangeType.Between,\n dateRange: [this._rangeStart!.native, this._rangePreviewDate.native],\n },\n ]);\n }\n\n //#endregion\n\n //#region Internal methods\n\n private _intlFormatDay(day: CalendarDay): string {\n const fmt = getDateFormatter().getIntlFormatter(this.locale, {\n weekday: 'long',\n year: 'numeric',\n month: 'long',\n day: 'numeric',\n });\n\n // Range selection in progress\n if (this._rangePreviewDate?.equalTo(day)) {\n return fmt.formatRange(\n first(this._values).native,\n this._rangePreviewDate.native\n );\n }\n\n // Range selection finished\n if (this._isFirstInRange(day) || this._isLastInRange(day)) {\n return fmt.formatRange(\n first(this._values).native,\n last(this._values).native\n );\n }\n\n // Default\n return fmt.format(day.native);\n }\n\n private _getDayHandlers(day: CalendarDay) {\n if (!this._isRange) {\n return { changePreview: nothing, clearPreview: nothing };\n }\n\n return {\n changePreview: this._changeRangePreview.bind(this, day),\n clearPreview: this._clearRangePreview.bind(this),\n };\n }\n\n private _getDayProperties(\n day: CalendarDay,\n today: CalendarDay\n ): DayProperties {\n const inactive = !areSameMonth(day, this._activeDate);\n const disabled = isDateInRanges(day, this._disabledDates);\n\n const hidden =\n (this.hideLeadingDays && isPreviousMonth(day, this._activeDate)) ||\n (this.hideTrailingDays && isNextMonth(day, this._activeDate));\n\n return {\n disabled: disabled || hidden,\n first: this._isFirstInRange(day),\n last: this._isLastInRange(day),\n range: this._isRange && this._isRangeDate(day),\n preview: this._isRange && this._isRangePreview(day),\n current: !inactive && day.equalTo(today),\n inactive,\n hidden,\n weekend: day.weekend,\n single: !this._isRange,\n selected: !disabled && this._isSelected(day),\n special: !inactive && isDateInRanges(day, this._specialDates),\n };\n }\n\n //#endregion\n\n //#region Public methods\n\n /** Focuses the active date. */\n public focusActiveDate(options?: FocusOptions): void {\n this._activeDay?.focus(options);\n }\n\n //#endregion\n\n protected _renderDayWithProps(\n day: CalendarDay,\n props: DayProperties\n ): TemplateResult {\n const ariaLabel = this._intlFormatDay(day);\n const { changePreview, clearPreview } = this._getDayHandlers(day);\n\n return html`\n <span part=${partMap({ date: true, ...props })}>\n <span\n role=\"gridcell\"\n part=${partMap({ 'date-inner': true, ...props })}\n aria-label=${ariaLabel}\n aria-disabled=${props.disabled}\n aria-selected=${props.selected}\n data-value=${day.timestamp}\n tabindex=${day.equalTo(this._activeDate) ? 0 : -1}\n @focus=${changePreview}\n @blur=${clearPreview}\n @pointerenter=${changePreview}\n @pointerleave=${clearPreview}\n >\n ${day.date}\n </span>\n </span>\n `;\n }\n\n protected _renderHeaderWeekNumber() {\n return html`\n <span role=\"columnheader\" part=\"label week-number first\">\n <span part=\"week-number-inner first\"> ${this._weekLabel} </span>\n </span>\n `;\n }\n\n protected _renderWeekNumber(start: CalendarDay, last: boolean) {\n return html`\n <span role=\"rowheader\" part=${partMap({ 'week-number': true, last })}>\n <span part=${partMap({ 'week-number-inner': true, last })}>\n ${start.week}\n </span>\n </span>\n `;\n }\n\n protected _renderHeaders() {\n const label = getDateFormatter().getIntlFormatter(this.locale, {\n weekday: this.weekDayFormat,\n });\n const aria = getDateFormatter().getIntlFormatter(this.locale, {\n weekday: 'long',\n });\n\n const weekNumber = this.showWeekNumbers\n ? this._renderHeaderWeekNumber()\n : nothing;\n\n const headers = generateMonth(this._activeDate, this._firstDayOfWeek)\n .take(DAYS_IN_WEEK)\n .map(\n (day) => html`\n <span\n role=\"columnheader\"\n part=\"label\"\n aria-label=${aria.format(day.native)}\n >\n <span part=\"label-inner\">${label.format(day.native)}</span>\n </span>\n `\n )\n .toArray();\n\n return html`\n <div role=\"row\" part=\"days-row first\">${weekNumber}${headers}</div>\n `;\n }\n\n protected *_renderWeeks(): Generator<TemplateResult> {\n const today = CalendarDay.today;\n const weeks = Array.from(chunk(this._dates, DAYS_IN_WEEK));\n const lastIndex = weeks.length - 1;\n\n // Pre-compute day properties for all dates to avoid redundant calculations\n const dayPropertiesMap = new Map<number, DayProperties>();\n\n for (const day of this._dates) {\n dayPropertiesMap.set(day.timestamp, this._getDayProperties(day, today));\n }\n\n for (const [idx, week] of weeks.entries()) {\n const isLast = idx === lastIndex;\n\n const hidden = week.every(\n (day) => dayPropertiesMap.get(day.timestamp)!.hidden\n );\n\n yield html`\n <div role=\"row\" part=\"days-row\" aria-hidden=${hidden}>\n ${\n this.showWeekNumbers\n ? this._renderWeekNumber(week[0], isLast)\n : nothing\n }\n ${week.map((day) =>\n this._renderDayWithProps(day, dayPropertiesMap.get(day.timestamp)!)\n )}\n </div>\n `;\n }\n }\n\n protected override render() {\n return html`${this._renderHeaders()}${this._renderWeeks()}`;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'igc-days-view': IgcDaysViewComponent;\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"days-view.js","sourceRoot":"","sources":["../../../../src/components/calendar/days-view/days-view.ts"],"names":[],"mappings":";;;;;;;AAAA,OAAO,EAAE,gBAAgB,EAAE,wBAAwB,EAAE,MAAM,oBAAoB,CAAC;AAChF,OAAO,EAAE,IAAI,EAAE,OAAO,EAA4C,MAAM,KAAK,CAAC;AAC9E,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,EAAE,sBAAsB,EAAE,MAAM,qCAAqC,CAAC;AAC7E,OAAO,EAAE,cAAc,EAAE,MAAM,wCAAwC,CAAC;AACxE,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AACrE,OAAO,EAAE,oBAAoB,EAAE,MAAM,+CAA+C,CAAC;AACrF,OAAO,EAAE,uBAAuB,EAAE,MAAM,kDAAkD,CAAC;AAC3F,OAAO,EAAE,iBAAiB,EAAE,MAAM,oCAAoC,CAAC;AAEvE,OAAO,EAAE,iBAAiB,EAAE,MA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, type PropertyValues, type TemplateResult } from 'lit';\nimport { property, query, state } from 'lit/decorators.js';\nimport { addInternalsController } from '#internals/controllers/internals.js';\nimport { addKeybindings } from '#internals/controllers/key-bindings.js';\nimport { CalendarDay, DAYS_IN_WEEK } from '#internals/date/model.js';\nimport { blazorIndirectRender } from '#internals/decorators/blazorIndirectRender.js';\nimport { blazorSuppressComponent } from '#internals/decorators/blazorSuppressComponent.js';\nimport { registerComponent } from '#internals/definitions/register.js';\nimport type { Constructor } from '#internals/mixins/constructor.js';\nimport { EventEmitterMixin } from '#internals/mixins/event-emitter.js';\nimport { partMap } from '#internals/part-map.js';\nimport { chunk, firstOf, lastOf } from '#internals/utils/arrays.js';\nimport { addSafeEventListener } from '#internals/utils/events.js';\nimport { addThemingController } from '#theming/theming-controller.js';\nimport { IgcCalendarBaseComponent } from '../base.js';\nimport {\n areSameMonth,\n generateMonth,\n getViewElement,\n isDateInRanges,\n isNextMonth,\n isPreviousMonth,\n} from '../helpers.js';\nimport { selectDate } from '../selection.js';\nimport { styles } from '../themes/days-view.base.css.js';\nimport { all } from '../themes/days.js';\nimport type { IgcCalendarViewComponentEventMap } from '../types.js';\n\nexport interface IgcDaysViewEventMap extends IgcCalendarViewComponentEventMap {\n igcActiveDateChange: CustomEvent<Date>;\n igcRangePreviewDateChange: CustomEvent<Date>;\n}\n\n/** Inclusive timestamp bounds of a range of days. */\ninterface DayBounds {\n min: number;\n max: number;\n}\n\n/** State derived once per render pass and shared by every day cell. */\ninterface DayRenderContext {\n today: CalendarDay;\n /** Formats the accessible label of a cell. */\n formatter: Intl.DateTimeFormat;\n /** The dates selected in `multiple` selection. */\n selectedDates: Set<number>;\n /** The selected range in `range` selection. */\n selectedRange?: DayBounds;\n /** The dates rendered as part of the current range, including the previewed ones. */\n rangeDates?: DayBounds;\n /** The dates rendered as previewed. */\n previewDates?: DayBounds;\n /** The first date of the current range, accounting for the preview. */\n first?: number;\n /** The last date of the current range, accounting for the preview. */\n last?: number;\n}\n\nfunction boundsOf(first: CalendarDay, second: CalendarDay): DayBounds {\n const [a, b] = [first.timestamp, second.timestamp];\n return { min: Math.min(a, b), max: Math.max(a, b) };\n}\n\nfunction isInBounds(day: CalendarDay, bounds?: DayBounds): boolean {\n return bounds\n ? day.timestamp >= bounds.min && day.timestamp <= bounds.max\n : false;\n}\n\ninterface DayProperties {\n disabled: boolean;\n first: boolean;\n last: boolean;\n range: boolean;\n preview: boolean;\n current: boolean;\n inactive: boolean;\n hidden: boolean;\n weekend: boolean;\n single: boolean;\n selected: boolean;\n special: boolean;\n}\n\n/**\n * Instantiate a days view as a separate component in the calendar.\n *\n * @element igc-days-view\n *\n * @fires igcActiveDateChange - Emitted when the active date changes.\n * @fires igcRangePreviewDateChange - Emitted when the range preview date changes.\n *\n * @csspart days-row - The days row container.\n * @csspart label - The label container.\n * @csspart label-inner - The inner label container.\n * @csspart week-number - The week number container.\n * @csspart week-number-inner - The inner week number container.\n */\n@blazorSuppressComponent\n@blazorIndirectRender\nexport default class IgcDaysViewComponent extends EventEmitterMixin<\n IgcDaysViewEventMap,\n Constructor<IgcCalendarBaseComponent>\n>(IgcCalendarBaseComponent) {\n public static readonly tagName = 'igc-days-view';\n public static styles = styles;\n\n /* blazorSuppress */\n public static register(): void {\n registerComponent(IgcDaysViewComponent);\n }\n\n //#region Internal properties and state\n\n @state()\n private _dates: CalendarDay[] = [];\n\n @query('[tabindex=\"0\"]')\n private _activeDay?: HTMLElement;\n\n private get _rangeStart(): CalendarDay | undefined {\n return this._hasValues ? firstOf(this._values) : undefined;\n }\n\n private get _rangeEnd(): CalendarDay | undefined {\n return this._hasValues ? lastOf(this._values) : undefined;\n }\n\n private get _weekLabel(): string {\n return getDisplayNamesFormatter().getWeekLabel(this.locale, {\n style: 'short',\n });\n }\n\n //#endregion\n\n //#region Public attributes and properties\n\n /**\n * The active state of the component.\n *\n * @remarks\n * Only the active view holds the tab stop of its active date, so that a multi-month\n * calendar exposes a single tab stop instead of one per rendered month.\n *\n * @default true\n */\n @property({ type: Boolean })\n public active = true;\n\n /**\n * Whether to show leading days which do not belong to the current month.\n * @attr hide-leading-days\n */\n @property({ type: Boolean, attribute: 'hide-leading-days' })\n public hideLeadingDays = false;\n\n /**\n * Whether to show trailing days which do not belong to the current month.\n * @attr hide-trailing-days\n */\n @property({ type: Boolean, attribute: 'hide-trailing-days' })\n public hideTrailingDays = false;\n\n /** The range preview date. */\n @property({ attribute: false })\n public set rangePreviewDate(value: Date | undefined) {\n this._rangePreviewDate = value ? CalendarDay.from(value) : undefined;\n }\n\n public get rangePreviewDate(): Date | undefined {\n return this._rangePreviewDate?.native;\n }\n\n /**\n * The format of the days. Defaults to narrow.\n * @attr week-day-format\n */\n @property({ attribute: 'week-day-format' })\n public weekDayFormat: 'long' | 'short' | 'narrow' = 'narrow';\n\n //#endregion\n\n //#region Lifecycle hooks\n\n constructor() {\n super();\n\n addInternalsController(this, {\n initialARIA: { role: 'grid' },\n reflectRole: true,\n });\n addThemingController(this, all);\n addKeybindings(this).setActivateHandler(this._handleInteraction);\n addSafeEventListener(this, 'click', this._handleInteraction);\n }\n\n /** @internal */\n protected override update(props: PropertyValues): void {\n if (props.has('_activeDate') || props.has('weekStart')) {\n this._dates = Array.from(\n generateMonth(this._activeDate, this._firstDayOfWeek)\n );\n }\n\n super.update(props);\n }\n\n //#endregion\n\n //#region Event handlers\n\n protected _handleInteraction(event: Event): void {\n const value = getViewElement(event);\n\n if (value !== -1) {\n const date = CalendarDay.from(new Date(value));\n\n if (this._rangePreviewDate) {\n this._setRangePreviewDate();\n }\n\n if (this._selectDate(date)) {\n this.emitEvent('igcChange', { detail: date.native });\n }\n\n if (event.type === 'click') {\n this.emitEvent('igcActiveDateChange', { detail: date.native });\n this._activeDate = date;\n }\n }\n }\n\n //#endregion\n\n //#region Internal selection methods\n\n /**\n * Applies the activation of `value` to the selection of this view.\n *\n * @remarks\n * A view inside a calendar has its selection pushed back down by it on the next render.\n * This is what keeps a stand-alone one selecting on its own.\n */\n private _selectDate(value: CalendarDay): boolean {\n const selection = selectDate(\n { value: this._value, values: this._values },\n value,\n { selection: this.selection, disabledDates: this._disabledDates }\n );\n\n if (!selection) {\n return false;\n }\n\n this._value = selection.value;\n this._values = selection.values;\n\n return true;\n }\n\n /** Whether `day` is selected. Disabled dates are excluded by the caller. */\n private _isSelected(day: CalendarDay, context: DayRenderContext): boolean {\n switch (this.selection) {\n case 'single':\n return Boolean(this._value?.equalTo(day));\n\n case 'multiple':\n return context.selectedDates.has(day.timestamp);\n\n case 'range':\n return isInBounds(day, context.selectedRange);\n }\n }\n\n //#endregion\n\n //#region Range helpers\n\n private _setRangePreviewDate(day?: CalendarDay): void {\n this._rangePreviewDate = day;\n this.emitEvent('igcRangePreviewDateChange', {\n detail: day ? day.native : undefined,\n });\n }\n\n private _changeRangePreview(day: CalendarDay): void {\n if (this._values.length === 1 && !this._rangeStart!.equalTo(day)) {\n this._setRangePreviewDate(day);\n }\n }\n\n private _clearRangePreview(): void {\n if (this._rangePreviewDate) {\n this._setRangePreviewDate();\n }\n }\n\n //#endregion\n\n //#region Internal methods\n\n /** Resolves the selection state shared by all cells of the current render pass. */\n private _createRenderContext(): DayRenderContext {\n const context: DayRenderContext = {\n today: CalendarDay.today,\n formatter: getDateFormatter().getIntlFormatter(this.locale, {\n weekday: 'long',\n year: 'numeric',\n month: 'long',\n day: 'numeric',\n }),\n selectedDates: new Set(),\n };\n\n if (this._isMultiple) {\n for (const value of this._values) {\n context.selectedDates.add(value.timestamp);\n }\n return context;\n }\n\n if (!this._isRange || !this._hasValues) {\n return context;\n }\n\n const start = this._rangeStart!;\n const end = this._rangeEnd!;\n const preview = this._rangePreviewDate;\n\n context.selectedRange = boundsOf(start, end);\n\n // The endpoints of the range extend to the previewed date while it is outside of it\n context.first = (preview?.lessThan(start) ? preview : start).timestamp;\n context.last = (preview?.greaterThan(end) ? preview : end).timestamp;\n\n if (preview) {\n context.previewDates = boundsOf(start, preview);\n }\n\n // A single selected date renders as a range only while a second one is previewed\n const rangeEnd = this._values.length === 1 ? preview : end;\n\n if (rangeEnd) {\n context.rangeDates = boundsOf(start, rangeEnd);\n }\n\n return context;\n }\n\n private _intlFormatDay(day: CalendarDay, context: DayRenderContext): string {\n const { formatter, first, last } = context;\n\n // Range selection in progress\n if (this._rangePreviewDate?.equalTo(day)) {\n return formatter.formatRange(\n this._rangeStart!.native,\n this._rangePreviewDate.native\n );\n }\n\n // Range selection finished\n if (day.timestamp === first || day.timestamp === last) {\n return formatter.formatRange(\n this._rangeStart!.native,\n this._rangeEnd!.native\n );\n }\n\n return formatter.format(day.native);\n }\n\n private _getDayHandlers(day: CalendarDay) {\n if (!this._isRange) {\n return { changePreview: nothing, clearPreview: nothing };\n }\n\n return {\n changePreview: this._changeRangePreview.bind(this, day),\n clearPreview: this._clearRangePreview.bind(this),\n };\n }\n\n private _getDayProperties(\n day: CalendarDay,\n context: DayRenderContext\n ): DayProperties {\n const inactive = !areSameMonth(day, this._activeDate);\n const disabled = isDateInRanges(day, this._disabledDates);\n\n const hidden =\n (this.hideLeadingDays && isPreviousMonth(day, this._activeDate)) ||\n (this.hideTrailingDays && isNextMonth(day, this._activeDate));\n\n return {\n disabled: disabled || hidden,\n first: day.timestamp === context.first,\n last: day.timestamp === context.last,\n range: isInBounds(day, context.rangeDates),\n preview: isInBounds(day, context.previewDates),\n current: !inactive && day.equalTo(context.today),\n inactive,\n hidden,\n weekend: day.weekend,\n single: !this._isRange,\n selected: !disabled && this._isSelected(day, context),\n special: !inactive && isDateInRanges(day, this._specialDates),\n };\n }\n\n //#endregion\n\n //#region Public methods\n\n /** Focuses the active date. */\n public focusActiveDate(options?: FocusOptions): void {\n this._activeDay?.focus(options);\n }\n\n //#endregion\n\n protected _renderDayWithProps(\n day: CalendarDay,\n props: DayProperties,\n context: DayRenderContext\n ): TemplateResult {\n const ariaLabel = this._intlFormatDay(day, context);\n const { changePreview, clearPreview } = this._getDayHandlers(day);\n\n return html`\n <span part=${partMap({ date: true, ...props })}>\n <span\n role=\"gridcell\"\n part=${partMap({ 'date-inner': true, ...props })}\n aria-label=${ariaLabel}\n aria-disabled=${props.disabled}\n aria-selected=${props.selected}\n data-value=${day.timestamp}\n tabindex=${this.active && day.equalTo(this._activeDate) ? 0 : -1}\n @focus=${changePreview}\n @blur=${clearPreview}\n @pointerenter=${changePreview}\n @pointerleave=${clearPreview}\n >\n ${day.date}\n </span>\n </span>\n `;\n }\n\n protected _renderHeaderWeekNumber() {\n return html`\n <span role=\"columnheader\" part=\"label week-number first\">\n <span part=\"week-number-inner first\"> ${this._weekLabel} </span>\n </span>\n `;\n }\n\n protected _renderWeekNumber(start: CalendarDay, last: boolean) {\n return html`\n <span role=\"rowheader\" part=${partMap({ 'week-number': true, last })}>\n <span part=${partMap({ 'week-number-inner': true, last })}>\n ${start.week}\n </span>\n </span>\n `;\n }\n\n protected _renderHeaders() {\n const label = getDateFormatter().getIntlFormatter(this.locale, {\n weekday: this.weekDayFormat,\n });\n const aria = getDateFormatter().getIntlFormatter(this.locale, {\n weekday: 'long',\n });\n\n const weekNumber = this.showWeekNumbers\n ? this._renderHeaderWeekNumber()\n : nothing;\n\n // The first week of the grid, so that the labels cannot disagree with it\n const headers = this._dates.slice(0, DAYS_IN_WEEK).map(\n (day) => html`\n <span\n role=\"columnheader\"\n part=\"label\"\n aria-label=${aria.format(day.native)}\n >\n <span part=\"label-inner\">${label.format(day.native)}</span>\n </span>\n `\n );\n\n return html`\n <div role=\"row\" part=\"days-row first\">${weekNumber}${headers}</div>\n `;\n }\n\n protected *_renderWeeks(): Generator<TemplateResult> {\n const context = this._createRenderContext();\n const weeks = Array.from(chunk(this._dates, DAYS_IN_WEEK));\n const lastIndex = weeks.length - 1;\n\n for (const [idx, week] of weeks.entries()) {\n const isLast = idx === lastIndex;\n const properties = week.map((day) =>\n this._getDayProperties(day, context)\n );\n const hidden = properties.every((props) => props.hidden);\n\n yield html`\n <div role=\"row\" part=\"days-row\" aria-hidden=${hidden}>\n ${\n this.showWeekNumbers\n ? this._renderWeekNumber(week[0], isLast)\n : nothing\n }\n ${week.map((day, i) =>\n this._renderDayWithProps(day, properties[i], context)\n )}\n </div>\n `;\n }\n }\n\n protected override render() {\n return html`${this._renderHeaders()}${this._renderWeeks()}`;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'igc-days-view': IgcDaysViewComponent;\n }\n}\n"]}
|
|
@@ -1,66 +1,15 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import { CalendarDay, type CalendarRangeParams, type DayParameter } from './model.js';
|
|
1
|
+
import { CalendarDay, type DayParameter } from '#internals/date/model.js';
|
|
3
2
|
import { type DateRangeDescriptor, type WeekDays } from './types.js';
|
|
4
3
|
export declare const MONTHS_PER_ROW = 3;
|
|
5
4
|
export declare const YEARS_PER_ROW = 3;
|
|
6
5
|
export declare const YEARS_PER_PAGE = 15;
|
|
7
|
-
/**
|
|
8
|
-
* Type guard to check if a value is a valid Date object.
|
|
9
|
-
*/
|
|
10
|
-
export declare function isValidDate(value: unknown): value is Date;
|
|
11
|
-
export declare function parseISODate(string: string): Date | null;
|
|
12
|
-
/**
|
|
13
|
-
* Converts the given value to a Date object.
|
|
14
|
-
*
|
|
15
|
-
* If the value is already a valid Date object, it is returned directly.
|
|
16
|
-
* If the value is a string, it is parsed into a Date object.
|
|
17
|
-
* If the value is null or undefined, null is returned.
|
|
18
|
-
* If the parsing fails, null is returned.
|
|
19
|
-
*/
|
|
20
|
-
export declare function convertToDate(value?: Date | string | null): Date | null;
|
|
21
|
-
/**
|
|
22
|
-
* Converts the given value to a DateRangeValue object.
|
|
23
|
-
*
|
|
24
|
-
* If the value is already a valid DateRangeValue object, it is returned directly.
|
|
25
|
-
* If the value is a string, it is parsed to object and returned if it fields are valid dates.
|
|
26
|
-
* If the value is null or undefined, null is returned.
|
|
27
|
-
* If the parsing fails, null is returned.
|
|
28
|
-
*/
|
|
29
|
-
export declare function convertToDateRange(value?: DateRangeValue | string | null): DateRangeValue | null;
|
|
30
|
-
/**
|
|
31
|
-
* Converts a Date object to an ISO 8601 string.
|
|
32
|
-
*
|
|
33
|
-
* If the `value` is a `Date` object, it is converted to an ISO 8601 string.
|
|
34
|
-
* If the `value` is null or undefined, null is returned.
|
|
35
|
-
*/
|
|
36
|
-
export declare function getDateFormValue(value: Date | null): string | null;
|
|
37
|
-
/**
|
|
38
|
-
* Converts a comma-separated string of ISO 8601 dates or an array of Date objects | ISO 8601 strings into
|
|
39
|
-
* an array of Date objects.
|
|
40
|
-
*
|
|
41
|
-
* If the `value` is null or undefined, null is returned.
|
|
42
|
-
* If the `value` is an array of `Date` objects, a filtered array of valid `Date` objects is returned.
|
|
43
|
-
* If the `value` is a string, it is split by commas and each part is parsed into a `Date` object.
|
|
44
|
-
* If the parsing fails for any date, it is skipped.
|
|
45
|
-
*/
|
|
46
|
-
export declare function convertToDates(value?: (Date | string)[] | string | null): Date[] | null;
|
|
47
|
-
/**
|
|
48
|
-
* Returns the value of the selected/activated element (day/month/year) in the calendar view.
|
|
49
|
-
*/
|
|
6
|
+
/** The value of the activated day/month/year element of a calendar view, or -1. */
|
|
50
7
|
export declare function getViewElement(event: Event): number;
|
|
51
8
|
export declare function getWeekDayNumber(value: WeekDays): number;
|
|
52
9
|
export declare function areSameMonth(first: DayParameter, second: DayParameter): boolean;
|
|
53
10
|
export declare function isNextMonth(target: DayParameter, origin: DayParameter): boolean;
|
|
54
11
|
export declare function isPreviousMonth(target: DayParameter, origin: DayParameter): boolean;
|
|
55
|
-
/**
|
|
56
|
-
* Returns a generator yielding day values between `start` and `end` (non-inclusive by default)
|
|
57
|
-
* by a given `unit` as a step.
|
|
58
|
-
* To include the end date set the `inclusive` option to true.
|
|
59
|
-
*
|
|
60
|
-
* @remarks
|
|
61
|
-
* By default, `unit` is set to 'day'.
|
|
62
|
-
*/
|
|
63
|
-
export declare function calendarRange(options: CalendarRangeParams): Generator<CalendarDay, void, unknown>;
|
|
12
|
+
/** Yields the days rendered by a single days view - six weeks starting on `firstWeekDay`. */
|
|
64
13
|
export declare function generateMonth(value: DayParameter, firstWeekDay: number): Generator<CalendarDay, void, unknown>;
|
|
65
14
|
export declare function getYearRange(current: DayParameter, range: number): {
|
|
66
15
|
start: number;
|
|
@@ -68,11 +17,3 @@ export declare function getYearRange(current: DayParameter, range: number): {
|
|
|
68
17
|
};
|
|
69
18
|
export declare function isDateInRanges(date: DayParameter, ranges: DateRangeDescriptor[]): boolean;
|
|
70
19
|
export declare function createDateConstraints(min: Date | null, max: Date | null, disabledDates?: DateRangeDescriptor[]): DateRangeDescriptor[] | undefined;
|
|
71
|
-
/**
|
|
72
|
-
* Checks if a date is greater than a maximum date value.
|
|
73
|
-
*/
|
|
74
|
-
export declare function isDateExceedingMax(value: Date, maxValue: Date, includeTime?: boolean, includeDate?: boolean): boolean;
|
|
75
|
-
/**
|
|
76
|
-
* Checks if a date is less than a minimum date value.
|
|
77
|
-
*/
|
|
78
|
-
export declare function isDateLessThanMin(value: Date, minValue: Date, includeTime?: boolean, includeDate?: boolean): boolean;
|