@vonage/vivid 5.15.0 → 5.16.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/README.md +1 -1
- package/accordion/definition.cjs +7 -212
- package/accordion/definition.js +2 -204
- package/accordion/index.cjs +4 -4
- package/accordion/index.js +93 -138
- package/accordion-item/definition.cjs +6 -146
- package/accordion-item/definition.js +2 -139
- package/accordion-item/index.cjs +1 -1
- package/accordion-item/index.js +6 -2
- package/action-group/definition.cjs +5 -69
- package/action-group/definition.js +1 -62
- package/action-group/index.cjs +4 -4
- package/action-group/index.js +16 -46
- package/alert/definition.cjs +6 -201
- package/alert/definition.js +2 -194
- package/alert/index.cjs +15 -15
- package/alert/index.js +90 -136
- package/audio-player/definition.cjs +6 -463
- package/audio-player/definition.js +2 -456
- package/audio-player/index.cjs +49 -49
- package/audio-player/index.js +234 -308
- package/avatar/definition.cjs +6 -117
- package/avatar/definition.js +2 -110
- package/avatar/index.cjs +14 -14
- package/avatar/index.js +44 -84
- package/badge/definition.cjs +6 -85
- package/badge/definition.js +2 -78
- package/badge/index.cjs +4 -4
- package/badge/index.js +21 -65
- package/banner/definition.cjs +6 -160
- package/banner/definition.js +2 -153
- package/banner/index.cjs +13 -13
- package/banner/index.js +76 -109
- package/breadcrumb/definition.cjs +5 -98
- package/breadcrumb/definition.js +1 -91
- package/breadcrumb/index.cjs +4 -4
- package/breadcrumb/index.js +33 -60
- package/breadcrumb-item/definition.cjs +7 -47
- package/breadcrumb-item/definition.js +3 -40
- package/breadcrumb-item/index.cjs +5 -5
- package/breadcrumb-item/index.js +20 -32
- package/bundled/affix.cjs +10 -10
- package/bundled/affix.js +44 -57
- package/bundled/anchored.cjs +3 -3
- package/bundled/anchored.js +47 -65
- package/bundled/aria.cjs +1 -1
- package/bundled/aria.js +6 -6
- package/bundled/attribute-binding-behaviour.cjs +1 -1
- package/bundled/attribute-binding-behaviour.js +17 -30
- package/bundled/base-color-picker.cjs +10 -10
- package/bundled/base-color-picker.js +115 -202
- package/bundled/base-progress.cjs +1 -1
- package/bundled/base-progress.js +29 -59
- package/bundled/breadcrumb-item.cjs +1 -1
- package/bundled/breadcrumb-item.js +11 -20
- package/bundled/button.cjs +1 -1
- package/bundled/button.js +65 -109
- package/bundled/calendar-event.cjs +1 -1
- package/bundled/calendar-event.js +11 -34
- package/bundled/calendar-picker.template.cjs +77 -77
- package/bundled/calendar-picker.template.js +2881 -3297
- package/bundled/char-count.cjs +7 -7
- package/bundled/char-count.js +31 -46
- package/bundled/children.cjs +1 -1
- package/bundled/children.js +27 -45
- package/bundled/class-names.cjs +1 -1
- package/bundled/class-names.js +8 -8
- package/bundled/data-grid.options.cjs +1 -1
- package/bundled/data-grid.options.js +22 -26
- package/bundled/decorate.cjs +1 -0
- package/bundled/decorate.js +9 -0
- package/bundled/definition.cjs +1 -39
- package/bundled/definition.js +5 -122
- package/bundled/definition10.cjs +27 -69
- package/bundled/definition10.js +173 -362
- package/bundled/definition11.cjs +19 -12
- package/bundled/definition11.js +77 -93
- package/bundled/definition12.cjs +11 -11
- package/bundled/definition12.js +122 -217
- package/bundled/definition13.cjs +18 -9
- package/bundled/definition13.js +76 -42
- package/bundled/definition14.cjs +10 -1
- package/bundled/definition14.js +28 -19
- package/bundled/definition15.cjs +73 -5
- package/bundled/definition15.js +194 -28
- package/bundled/definition16.cjs +5 -30
- package/bundled/definition16.js +16 -79
- package/bundled/definition17.cjs +13 -19
- package/bundled/definition17.js +81 -105
- package/bundled/definition18.cjs +12 -13
- package/bundled/definition18.js +67 -147
- package/bundled/definition19.cjs +48 -48
- package/bundled/definition19.js +365 -699
- package/bundled/definition2.cjs +8 -8
- package/bundled/definition2.js +80 -124
- package/bundled/definition20.cjs +5 -20
- package/bundled/definition20.js +11 -106
- package/bundled/definition21.cjs +20 -5
- package/bundled/definition21.js +57 -18
- package/bundled/definition22.cjs +16 -16
- package/bundled/definition22.js +79 -141
- package/bundled/definition3.cjs +1 -29
- package/bundled/definition3.js +183 -195
- package/bundled/definition4.cjs +39 -6
- package/bundled/definition4.js +71 -41
- package/bundled/definition5.cjs +30 -1
- package/bundled/definition5.js +48 -351
- package/bundled/definition6.cjs +28 -30
- package/bundled/definition6.js +110 -265
- package/bundled/definition7.cjs +6 -30
- package/bundled/definition7.js +22 -291
- package/bundled/definition8.cjs +13 -18
- package/bundled/definition8.js +150 -143
- package/bundled/definition9.cjs +29 -13
- package/bundled/definition9.js +157 -232
- package/bundled/delegates-aria.cjs +1 -1
- package/bundled/delegates-aria.js +56 -90
- package/bundled/dialog.cjs +1 -0
- package/bundled/dialog.js +6 -0
- package/bundled/divider.cjs +1 -1
- package/bundled/divider.js +16 -33
- package/bundled/dom.cjs +1 -1
- package/bundled/dom.js +5 -5
- package/bundled/enums.cjs +1 -1
- package/bundled/enums.js +16 -9
- package/bundled/floating-ui.dom.cjs +1 -1
- package/bundled/floating-ui.dom.js +953 -1234
- package/bundled/form-associated.cjs +1 -1
- package/bundled/form-associated.js +165 -327
- package/bundled/form-element.cjs +1 -1
- package/bundled/form-element.js +33 -55
- package/bundled/host-semantics.cjs +1 -1
- package/bundled/host-semantics.js +46 -69
- package/bundled/key-codes.cjs +1 -1
- package/bundled/key-codes.js +4 -16
- package/bundled/linkable.cjs +6 -6
- package/bundled/linkable.js +25 -45
- package/bundled/listbox.cjs +1 -1
- package/bundled/listbox.js +176 -368
- package/bundled/localized.cjs +1 -1
- package/bundled/localized.js +451 -564
- package/bundled/mixins.cjs +20 -20
- package/bundled/mixins.js +162 -213
- package/bundled/normalize.cjs +1 -1
- package/bundled/normalize.js +6 -6
- package/bundled/numbers.cjs +1 -1
- package/bundled/numbers.js +9 -11
- package/bundled/picker-field.template.cjs +23 -23
- package/bundled/picker-field.template.js +108 -172
- package/bundled/playbackRates.cjs +1 -1
- package/bundled/playbackRates.js +10 -10
- package/bundled/ref.cjs +1 -1
- package/bundled/ref.js +10 -14
- package/bundled/repeat.cjs +1 -1
- package/bundled/repeat.js +421 -552
- package/bundled/scrollIntoView.cjs +1 -1
- package/bundled/scrollIntoView.js +26 -32
- package/bundled/single-date-picker.cjs +1 -1
- package/bundled/single-date-picker.js +23 -38
- package/bundled/single-value-picker.cjs +1 -1
- package/bundled/single-value-picker.js +58 -86
- package/bundled/slider.template.cjs +13 -13
- package/bundled/slider.template.js +67 -78
- package/bundled/slottable-request.cjs +4 -4
- package/bundled/slottable-request.js +1937 -2904
- package/bundled/slotted.cjs +1 -1
- package/bundled/slotted.js +47 -97
- package/bundled/strings.cjs +1 -1
- package/bundled/strings.js +6 -6
- package/bundled/text-field.cjs +1 -1
- package/bundled/text-field.js +4 -4
- package/bundled/time-selection-picker.template.cjs +26 -26
- package/bundled/time-selection-picker.template.js +355 -555
- package/bundled/trapped-focus.cjs +1 -1
- package/bundled/trapped-focus.js +18 -25
- package/bundled/vivid-element.cjs +4 -5
- package/bundled/vivid-element.js +1778 -2794
- package/bundled/when.cjs +1 -1
- package/bundled/when.js +10 -10
- package/bundled/with-contextual-help.cjs +1 -1
- package/bundled/with-contextual-help.js +15 -31
- package/bundled/with-error-text.cjs +1 -1
- package/bundled/with-error-text.js +25 -38
- package/bundled/with-success-text.cjs +1 -1
- package/bundled/with-success-text.js +8 -15
- package/button/definition.cjs +6 -14
- package/button/definition.js +3 -4
- package/button/index.cjs +1 -1
- package/button/index.js +6 -2
- package/calendar/definition.cjs +5 -360
- package/calendar/definition.js +1 -353
- package/calendar/index.cjs +20 -20
- package/calendar/index.js +346 -403
- package/calendar-event/definition.cjs +6 -58
- package/calendar-event/definition.js +2 -51
- package/calendar-event/index.cjs +7 -7
- package/calendar-event/index.js +25 -41
- package/card/definition.cjs +6 -194
- package/card/definition.js +2 -187
- package/card/index.cjs +34 -34
- package/card/index.js +80 -133
- package/checkbox/definition.cjs +6 -210
- package/checkbox/definition.js +2 -203
- package/checkbox/index.cjs +1 -1
- package/checkbox/index.js +6 -2
- package/color-picker/definition.cjs +6 -1180
- package/color-picker/definition.js +2 -1173
- package/color-picker/index.cjs +94 -94
- package/color-picker/index.js +605 -742
- package/combobox/definition.cjs +6 -653
- package/combobox/definition.js +2 -646
- package/combobox/index.cjs +37 -37
- package/combobox/index.js +254 -465
- package/contextual-help/definition.cjs +6 -63
- package/contextual-help/definition.js +2 -56
- package/contextual-help/index.cjs +1 -1
- package/contextual-help/index.js +6 -2
- package/country/definition.cjs +6 -340
- package/country/definition.js +2 -333
- package/country/index.cjs +6 -6
- package/country/index.js +1209 -308
- package/custom-elements.json +550 -1571
- package/data-grid/definition.cjs +10 -2363
- package/data-grid/definition.js +2 -2352
- package/data-grid/index.cjs +61 -61
- package/data-grid/index.js +642 -1024
- package/date-picker/definition.cjs +6 -152
- package/date-picker/definition.js +2 -145
- package/date-picker/index.cjs +1 -1
- package/date-picker/index.js +66 -114
- package/date-range-picker/definition.cjs +6 -469
- package/date-range-picker/definition.js +2 -462
- package/date-range-picker/index.cjs +1 -1
- package/date-range-picker/index.js +218 -338
- package/date-time-picker/definition.cjs +6 -285
- package/date-time-picker/definition.js +2 -278
- package/date-time-picker/index.cjs +4 -4
- package/date-time-picker/index.js +116 -211
- package/dial-pad/definition.cjs +6 -469
- package/dial-pad/definition.js +2 -462
- package/dial-pad/index.cjs +42 -42
- package/dial-pad/index.js +195 -311
- package/dialog/definition.cjs +6 -350
- package/dialog/definition.js +2 -343
- package/dialog/index.cjs +28 -28
- package/dialog/index.js +148 -230
- package/divider/definition.cjs +6 -42
- package/divider/definition.js +2 -35
- package/divider/index.cjs +1 -1
- package/divider/index.js +5 -2
- package/elevation/definition.cjs +4 -11
- package/elevation/definition.js +2 -2
- package/elevation/index.cjs +1 -1
- package/elevation/index.js +5 -2
- package/empty-state/definition.cjs +6 -86
- package/empty-state/definition.js +2 -79
- package/empty-state/index.cjs +9 -9
- package/empty-state/index.js +28 -60
- package/fab/definition.cjs +6 -106
- package/fab/definition.js +2 -99
- package/fab/index.cjs +17 -17
- package/fab/index.js +46 -82
- package/file-picker/definition.cjs +6 -526
- package/file-picker/definition.js +2 -519
- package/file-picker/index.cjs +25 -25
- package/file-picker/index.js +246 -354
- package/header/definition.cjs +5 -78
- package/header/definition.js +1 -71
- package/header/index.cjs +5 -5
- package/header/index.js +28 -42
- package/icon/definition.cjs +5 -200
- package/icon/definition.js +1 -193
- package/icon/index.cjs +1 -1
- package/icon/index.js +5 -2
- package/index.cjs +350 -356
- package/index.js +79 -78
- package/layout/definition.cjs +5 -72
- package/layout/definition.js +1 -65
- package/layout/index.cjs +2 -2
- package/layout/index.js +10 -51
- package/lib/alert/alert.d.ts +0 -1
- package/lib/audio-player/audio-player.d.ts +0 -1
- package/lib/banner/banner.d.ts +0 -2
- package/lib/button/button.d.ts +0 -1
- package/lib/calendar/calendar.d.ts +0 -1
- package/lib/card/card.d.ts +0 -2
- package/lib/combobox/combobox.d.ts +1 -1
- package/lib/data-grid/data-grid-cell.d.ts +0 -3
- package/lib/data-grid/data-grid-row.d.ts +0 -3
- package/lib/data-grid/data-grid.d.ts +0 -1
- package/lib/fab/fab.d.ts +0 -1
- package/lib/file-picker/file-picker.d.ts +1 -1
- package/lib/icon/icon.d.ts +0 -2
- package/lib/menu/menu.d.ts +0 -1
- package/lib/menu-item/menu-item.d.ts +0 -1
- package/lib/option/option.d.ts +4 -0
- package/lib/pagination/pagination.d.ts +0 -7
- package/lib/popover/popover.d.ts +0 -5
- package/lib/select/select.d.ts +2 -2
- package/lib/split-button/split-button.d.ts +0 -2
- package/lib/tab/tab.d.ts +0 -2
- package/lib/table/table-head.d.ts +1 -0
- package/lib/tabs/tabs.d.ts +0 -1
- package/lib/tag/tag.d.ts +0 -2
- package/lib/text-field/text-field.d.ts +0 -1
- package/lib/toggletip/toggletip.d.ts +0 -1
- package/lib/tree-item/tree-item.d.ts +0 -2
- package/lib/tree-view/tree-view.d.ts +0 -1
- package/locales/de-DE.cjs +382 -492
- package/locales/de-DE.js +383 -490
- package/locales/en-GB.cjs +271 -382
- package/locales/en-GB.js +272 -380
- package/locales/en-US.cjs +2 -552
- package/locales/en-US.js +1 -549
- package/locales/ja-JP.cjs +376 -492
- package/locales/ja-JP.js +377 -490
- package/locales/zh-CN.cjs +378 -495
- package/locales/zh-CN.js +379 -493
- package/menu/definition.cjs +6 -394
- package/menu/definition.js +2 -387
- package/menu/index.cjs +1 -1
- package/menu/index.js +6 -2
- package/menu-item/definition.cjs +7 -14
- package/menu-item/definition.js +3 -3
- package/menu-item/index.cjs +1 -1
- package/menu-item/index.js +6 -2
- package/nav/definition.cjs +5 -27
- package/nav/definition.js +1 -20
- package/nav/index.cjs +3 -3
- package/nav/index.js +7 -10
- package/nav-disclosure/definition.cjs +6 -122
- package/nav-disclosure/definition.js +2 -115
- package/nav-disclosure/index.cjs +8 -8
- package/nav-disclosure/index.js +49 -86
- package/nav-item/definition.cjs +6 -79
- package/nav-item/definition.js +2 -72
- package/nav-item/index.cjs +2 -2
- package/nav-item/index.js +33 -58
- package/note/definition.cjs +6 -61
- package/note/definition.js +2 -54
- package/note/index.cjs +5 -5
- package/note/index.js +24 -38
- package/number-field/definition.cjs +6 -440
- package/number-field/definition.js +2 -433
- package/number-field/index.cjs +31 -31
- package/number-field/index.js +160 -328
- package/option/definition.cjs +6 -13
- package/option/definition.js +3 -3
- package/option/index.cjs +1 -1
- package/option/index.js +6 -2
- package/package.json +24 -23
- package/pagination/definition.cjs +6 -256
- package/pagination/definition.js +2 -249
- package/pagination/index.cjs +37 -37
- package/pagination/index.js +148 -188
- package/popover/definition.cjs +6 -363
- package/popover/definition.js +2 -356
- package/popover/index.cjs +16 -16
- package/popover/index.js +161 -250
- package/popup/definition.cjs +5 -13
- package/popup/definition.js +3 -4
- package/popup/index.cjs +1 -1
- package/popup/index.js +6 -2
- package/progress/definition.cjs +5 -87
- package/progress/definition.js +1 -80
- package/progress/index.cjs +9 -9
- package/progress/index.js +33 -55
- package/progress-ring/definition.cjs +5 -95
- package/progress-ring/definition.js +1 -88
- package/progress-ring/index.cjs +1 -1
- package/progress-ring/index.js +5 -2
- package/radio/definition.cjs +5 -231
- package/radio/definition.js +1 -224
- package/radio/index.cjs +1 -1
- package/radio/index.js +5 -2
- package/radio-group/definition.cjs +6 -361
- package/radio-group/definition.js +2 -354
- package/radio-group/index.cjs +10 -10
- package/radio-group/index.js +160 -242
- package/range-slider/definition.cjs +6 -632
- package/range-slider/definition.js +2 -625
- package/range-slider/index.cjs +41 -41
- package/range-slider/index.js +259 -429
- package/rich-text-editor/definition.cjs +32 -15609
- package/rich-text-editor/definition.js +2 -15576
- package/rich-text-editor/index.cjs +17 -17
- package/rich-text-editor/index.js +9061 -11419
- package/rich-text-view/definition.cjs +5 -171
- package/rich-text-view/definition.js +1 -164
- package/rich-text-view/index.cjs +1 -1
- package/rich-text-view/index.js +68 -102
- package/searchable-select/definition.cjs +5 -1404
- package/searchable-select/definition.js +2 -1398
- package/searchable-select/index.cjs +94 -94
- package/searchable-select/index.js +600 -1019
- package/select/definition.cjs +6 -1012
- package/select/definition.js +2 -1005
- package/select/index.cjs +1 -1
- package/select/index.js +6 -2
- package/selectable-box/definition.cjs +6 -174
- package/selectable-box/definition.js +2 -167
- package/selectable-box/index.cjs +18 -18
- package/selectable-box/index.js +66 -127
- package/side-drawer/definition.cjs +5 -130
- package/side-drawer/definition.js +1 -123
- package/side-drawer/index.cjs +7 -7
- package/side-drawer/index.js +47 -92
- package/simple-color-picker/definition.cjs +6 -216
- package/simple-color-picker/definition.js +2 -209
- package/simple-color-picker/index.cjs +15 -15
- package/simple-color-picker/index.js +98 -135
- package/slider/definition.cjs +6 -504
- package/slider/definition.js +2 -497
- package/slider/index.cjs +1 -1
- package/slider/index.js +6 -2
- package/split-button/definition.cjs +6 -176
- package/split-button/definition.js +2 -169
- package/split-button/index.cjs +15 -15
- package/split-button/index.js +74 -135
- package/status/definition.cjs +6 -76
- package/status/definition.js +2 -69
- package/status/index.cjs +10 -7
- package/status/index.js +38 -48
- package/styles/core/all.css +6 -5
- package/styles/core/theme.css +6 -5
- package/styles/core/typography.css +1 -2
- package/styles/tokens/theme-dark.css +17 -21
- package/styles/tokens/theme-light.css +17 -21
- package/styles/tokens/vivid-2-compat.css +1 -2
- package/switch/definition.cjs +6 -149
- package/switch/definition.js +2 -142
- package/switch/index.cjs +8 -8
- package/switch/index.js +48 -93
- package/tab/definition.cjs +6 -127
- package/tab/definition.js +2 -120
- package/tab/index.cjs +1 -1
- package/tab/index.js +6 -2
- package/tab-panel/definition.cjs +5 -29
- package/tab-panel/definition.js +1 -22
- package/tab-panel/index.cjs +1 -1
- package/tab-panel/index.js +5 -2
- package/table/definition.cjs +15 -168
- package/table/definition.js +1 -151
- package/table/index.cjs +20 -16
- package/table/index.js +36 -85
- package/tabs/definition.cjs +7 -469
- package/tabs/definition.js +2 -461
- package/tabs/index.cjs +11 -11
- package/tabs/index.js +169 -298
- package/tag/definition.cjs +6 -176
- package/tag/definition.js +2 -169
- package/tag/index.cjs +26 -26
- package/tag/index.js +65 -126
- package/tag-group/definition.cjs +5 -40
- package/tag-group/definition.js +1 -33
- package/tag-group/index.cjs +4 -4
- package/tag-group/index.js +10 -21
- package/text-area/definition.cjs +6 -361
- package/text-area/definition.js +2 -354
- package/text-area/index.cjs +11 -11
- package/text-area/index.js +153 -266
- package/text-field/definition.cjs +6 -433
- package/text-field/definition.js +2 -426
- package/text-field/index.cjs +1 -1
- package/text-field/index.js +6 -2
- package/time-picker/definition.cjs +7 -43
- package/time-picker/definition.js +3 -36
- package/time-picker/index.cjs +1 -1
- package/time-picker/index.js +24 -29
- package/toggletip/definition.cjs +6 -161
- package/toggletip/definition.js +2 -154
- package/toggletip/index.cjs +1 -1
- package/toggletip/index.js +6 -2
- package/tooltip/definition.cjs +6 -140
- package/tooltip/definition.js +2 -133
- package/tooltip/index.cjs +1 -1
- package/tooltip/index.js +6 -2
- package/tree-item/definition.cjs +6 -13
- package/tree-item/definition.js +3 -3
- package/tree-item/index.cjs +1 -1
- package/tree-item/index.js +6 -2
- package/tree-view/definition.cjs +6 -318
- package/tree-view/definition.js +2 -311
- package/tree-view/index.cjs +11 -11
- package/tree-view/index.js +145 -190
- package/unbundled/affix.cjs +89 -62
- package/unbundled/affix.js +58 -55
- package/unbundled/anchored.cjs +87 -94
- package/unbundled/anchored.js +74 -90
- package/unbundled/attribute-binding-behaviour.cjs +37 -43
- package/unbundled/attribute-binding-behaviour.js +31 -41
- package/unbundled/base-color-picker.cjs +226 -278
- package/unbundled/base-color-picker.js +214 -275
- package/unbundled/base-progress.cjs +63 -81
- package/unbundled/base-progress.js +57 -79
- package/unbundled/breadcrumb-item.cjs +24 -28
- package/unbundled/breadcrumb-item.js +18 -26
- package/unbundled/button.cjs +115 -175
- package/unbundled/button.js +109 -173
- package/unbundled/calendar-event.cjs +28 -41
- package/unbundled/calendar-event.js +22 -39
- package/unbundled/calendar-picker.template.cjs +620 -785
- package/unbundled/calendar-picker.template.js +560 -774
- package/unbundled/char-count.cjs +50 -80
- package/unbundled/char-count.js +44 -78
- package/unbundled/chunk.cjs +50 -0
- package/unbundled/chunk.js +33 -0
- package/unbundled/data-grid.options.cjs +80 -29
- package/unbundled/data-grid.options.js +51 -23
- package/unbundled/decorate.cjs +14 -0
- package/unbundled/decorate.js +9 -0
- package/unbundled/definition.cjs +42 -226
- package/unbundled/definition.js +24 -221
- package/unbundled/definition10.cjs +253 -0
- package/unbundled/definition10.js +229 -0
- package/unbundled/definition11.cjs +397 -0
- package/unbundled/definition11.js +379 -0
- package/unbundled/definition12.cjs +317 -0
- package/unbundled/definition12.js +287 -0
- package/unbundled/definition13.cjs +328 -0
- package/unbundled/definition13.js +310 -0
- package/unbundled/definition14.cjs +406 -0
- package/unbundled/definition14.js +388 -0
- package/unbundled/definition15.cjs +107 -0
- package/unbundled/definition15.js +89 -0
- package/unbundled/definition16.cjs +63 -0
- package/unbundled/definition16.js +45 -0
- package/unbundled/definition17.cjs +151 -0
- package/unbundled/definition17.js +133 -0
- package/unbundled/definition18.cjs +47 -0
- package/unbundled/definition18.js +35 -0
- package/unbundled/definition19.cjs +98 -0
- package/unbundled/definition19.js +80 -0
- package/unbundled/definition2.cjs +179 -401
- package/unbundled/definition2.js +161 -395
- package/unbundled/definition20.cjs +56 -0
- package/unbundled/definition20.js +43 -0
- package/unbundled/definition21.cjs +305 -0
- package/unbundled/definition21.js +286 -0
- package/unbundled/definition22.cjs +174 -0
- package/unbundled/definition22.js +156 -0
- package/unbundled/definition23.cjs +161 -0
- package/unbundled/definition23.js +143 -0
- package/unbundled/definition24.cjs +1038 -0
- package/unbundled/definition24.js +1020 -0
- package/unbundled/definition25.cjs +360 -0
- package/unbundled/definition25.js +342 -0
- package/unbundled/definition26.cjs +137 -0
- package/unbundled/definition26.js +119 -0
- package/unbundled/definition27.cjs +235 -0
- package/unbundled/definition27.js +211 -0
- package/unbundled/definition28.cjs +546 -0
- package/unbundled/definition28.js +528 -0
- package/unbundled/definition29.cjs +157 -0
- package/unbundled/definition29.js +139 -0
- package/unbundled/definition3.cjs +131 -285
- package/unbundled/definition3.js +113 -280
- package/unbundled/definition30.cjs +75 -0
- package/unbundled/definition30.js +57 -0
- package/unbundled/definition31.cjs +1265 -0
- package/unbundled/definition31.js +1247 -0
- package/unbundled/definition32.cjs +1908 -0
- package/unbundled/definition32.js +1866 -0
- package/unbundled/definition33.cjs +261 -0
- package/unbundled/definition33.js +183 -0
- package/unbundled/definition34.cjs +46 -0
- package/unbundled/definition34.js +33 -0
- package/unbundled/definition35.cjs +152 -0
- package/unbundled/definition35.js +134 -0
- package/unbundled/definition36.cjs +426 -0
- package/unbundled/definition36.js +408 -0
- package/unbundled/definition37.cjs +243 -0
- package/unbundled/definition37.js +225 -0
- package/unbundled/definition38.cjs +409 -0
- package/unbundled/definition38.js +391 -0
- package/unbundled/definition39.cjs +298 -0
- package/unbundled/definition39.js +280 -0
- package/unbundled/definition4.cjs +186 -206
- package/unbundled/definition4.js +162 -201
- package/unbundled/definition40.cjs +81 -0
- package/unbundled/definition40.js +63 -0
- package/unbundled/definition41.cjs +100 -0
- package/unbundled/definition41.js +82 -0
- package/unbundled/definition42.cjs +457 -0
- package/unbundled/definition42.js +439 -0
- package/unbundled/definition43.cjs +86 -0
- package/unbundled/definition43.js +68 -0
- package/unbundled/definition44.cjs +60 -0
- package/unbundled/definition44.js +41 -0
- package/unbundled/definition45.cjs +124 -0
- package/unbundled/definition45.js +106 -0
- package/unbundled/definition46.cjs +85 -0
- package/unbundled/definition46.js +67 -0
- package/unbundled/definition47.cjs +52 -0
- package/unbundled/definition47.js +31 -0
- package/unbundled/definition48.cjs +69 -0
- package/unbundled/definition48.js +51 -0
- package/unbundled/definition49.cjs +377 -0
- package/unbundled/definition49.js +359 -0
- package/unbundled/definition5.cjs +69 -298
- package/unbundled/definition5.js +44 -293
- package/unbundled/definition50.cjs +246 -0
- package/unbundled/definition50.js +228 -0
- package/unbundled/definition51.cjs +337 -0
- package/unbundled/definition51.js +319 -0
- package/unbundled/definition52.cjs +86 -0
- package/unbundled/definition52.js +67 -0
- package/unbundled/definition53.cjs +193 -0
- package/unbundled/definition53.js +174 -0
- package/unbundled/definition54.cjs +297 -0
- package/unbundled/definition54.js +279 -0
- package/unbundled/definition55.cjs +510 -0
- package/unbundled/definition55.js +492 -0
- package/unbundled/definition56.cjs +12728 -0
- package/unbundled/definition56.js +12553 -0
- package/unbundled/definition57.cjs +837 -0
- package/unbundled/definition57.js +819 -0
- package/unbundled/definition58.cjs +146 -0
- package/unbundled/definition58.js +128 -0
- package/unbundled/definition59.cjs +1080 -0
- package/unbundled/definition59.js +1062 -0
- package/unbundled/definition6.cjs +88 -56
- package/unbundled/definition6.js +69 -52
- package/unbundled/definition60.cjs +149 -0
- package/unbundled/definition60.js +131 -0
- package/unbundled/definition61.cjs +116 -0
- package/unbundled/definition61.js +97 -0
- package/unbundled/definition62.cjs +213 -0
- package/unbundled/definition62.js +195 -0
- package/unbundled/definition63.cjs +159 -0
- package/unbundled/definition63.js +141 -0
- package/unbundled/definition64.cjs +86 -0
- package/unbundled/definition64.js +68 -0
- package/unbundled/definition65.cjs +126 -0
- package/unbundled/definition65.js +107 -0
- package/unbundled/definition66.cjs +49 -0
- package/unbundled/definition66.js +28 -0
- package/unbundled/definition67.cjs +119 -0
- package/unbundled/definition67.js +101 -0
- package/unbundled/definition68.cjs +374 -0
- package/unbundled/definition68.js +349 -0
- package/unbundled/definition69.cjs +57 -0
- package/unbundled/definition69.js +38 -0
- package/unbundled/definition7.cjs +190 -0
- package/unbundled/definition7.js +166 -0
- package/unbundled/definition70.cjs +155 -0
- package/unbundled/definition70.js +137 -0
- package/unbundled/definition71.cjs +302 -0
- package/unbundled/definition71.js +284 -0
- package/unbundled/definition72.cjs +49 -0
- package/unbundled/definition72.js +38 -0
- package/unbundled/definition73.cjs +171 -0
- package/unbundled/definition73.js +147 -0
- package/unbundled/definition74.cjs +232 -0
- package/unbundled/definition74.js +213 -0
- package/unbundled/definition75.cjs +52241 -0
- package/unbundled/definition75.js +52223 -0
- package/unbundled/definition8.cjs +63 -0
- package/unbundled/definition8.js +44 -0
- package/unbundled/definition9.cjs +183 -0
- package/unbundled/definition9.js +165 -0
- package/unbundled/delegates-aria.cjs +90 -131
- package/unbundled/delegates-aria.js +77 -127
- package/unbundled/dialog.cjs +15 -0
- package/unbundled/dialog.js +10 -0
- package/unbundled/divider.cjs +42 -50
- package/unbundled/divider.js +30 -47
- package/unbundled/en-US.cjs +447 -0
- package/unbundled/en-US.js +443 -0
- package/unbundled/enums.cjs +166 -107
- package/unbundled/enums.js +95 -94
- package/unbundled/form-associated.cjs +408 -464
- package/unbundled/form-associated.js +396 -461
- package/unbundled/form-element.cjs +74 -83
- package/unbundled/form-element.js +68 -81
- package/unbundled/host-semantics.cjs +70 -88
- package/unbundled/host-semantics.js +57 -84
- package/unbundled/key-codes.cjs +16 -10
- package/unbundled/key-codes.js +5 -7
- package/unbundled/linkable.cjs +35 -56
- package/unbundled/linkable.js +27 -52
- package/unbundled/listbox.cjs +363 -473
- package/unbundled/listbox.js +357 -471
- package/unbundled/localized.cjs +79 -74
- package/unbundled/localized.js +61 -70
- package/unbundled/mixins.cjs +222 -225
- package/unbundled/mixins.js +186 -213
- package/unbundled/picker-field.template.cjs +188 -218
- package/unbundled/picker-field.template.js +165 -209
- package/unbundled/playbackRates.cjs +18 -11
- package/unbundled/playbackRates.js +13 -9
- package/unbundled/scrollIntoView.cjs +38 -44
- package/unbundled/scrollIntoView.js +33 -42
- package/unbundled/single-date-picker.cjs +48 -45
- package/unbundled/single-date-picker.js +43 -43
- package/unbundled/single-value-picker.cjs +106 -114
- package/unbundled/single-value-picker.js +101 -112
- package/unbundled/slider.template.cjs +107 -73
- package/unbundled/slider.template.js +67 -62
- package/unbundled/slottable-request.cjs +3114 -3503
- package/unbundled/slottable-request.js +2995 -3484
- package/unbundled/text-field.cjs +9 -5
- package/unbundled/text-field.js +4 -3
- package/unbundled/time-selection-picker.template.cjs +611 -758
- package/unbundled/time-selection-picker.template.js +554 -745
- package/unbundled/trapped-focus.cjs +45 -35
- package/unbundled/trapped-focus.js +34 -32
- package/unbundled/vivid-element.cjs +281 -273
- package/unbundled/vivid-element.js +239 -265
- package/unbundled/with-contextual-help.cjs +35 -39
- package/unbundled/with-contextual-help.js +29 -37
- package/unbundled/with-error-text.cjs +45 -55
- package/unbundled/with-error-text.js +39 -53
- package/unbundled/with-success-text.cjs +18 -22
- package/unbundled/with-success-text.js +12 -20
- package/video-player/definition.cjs +5 -69602
- package/video-player/definition.js +1 -69595
- package/video-player/index.cjs +44 -55
- package/video-player/index.js +23548 -35488
- package/visually-hidden/definition.cjs +5 -30
- package/visually-hidden/definition.js +1 -23
- package/visually-hidden/index.cjs +1 -1
- package/visually-hidden/index.js +5 -2
- package/vivid.api.json +197 -2003
- package/bundled/index.cjs +0 -1
- package/bundled/index.js +0 -6
- package/unbundled/_commonjsHelpers.cjs +0 -36
- package/unbundled/_commonjsHelpers.js +0 -32
- package/unbundled/index.cjs +0 -11
- package/unbundled/index.js +0 -9
package/bundled/vivid-element.js
CHANGED
|
@@ -1,2815 +1,1799 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/interfaces.js
|
|
2
|
+
var e, t = "fast-kernel";
|
|
3
3
|
try {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
4
|
+
if (document.currentScript) e = document.currentScript.getAttribute(t);
|
|
5
|
+
else {
|
|
6
|
+
let n = document.getElementsByTagName("script");
|
|
7
|
+
e = n[n.length - 1].getAttribute(t);
|
|
8
|
+
}
|
|
10
9
|
} catch {
|
|
11
|
-
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
switch (
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
};
|
|
43
|
-
var tt = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
44
|
-
function ci(i) {
|
|
45
|
-
return i && i.__esModule && Object.prototype.hasOwnProperty.call(i, "default") ? i.default : i;
|
|
46
|
-
}
|
|
47
|
-
function di(i) {
|
|
48
|
-
if (i.__esModule) return i;
|
|
49
|
-
var t = i.default;
|
|
50
|
-
if (typeof t == "function") {
|
|
51
|
-
var e = function s() {
|
|
52
|
-
return this instanceof s ? Reflect.construct(t, arguments, this.constructor) : t.apply(this, arguments);
|
|
53
|
-
};
|
|
54
|
-
e.prototype = t.prototype;
|
|
55
|
-
} else e = {};
|
|
56
|
-
return Object.defineProperty(e, "__esModule", { value: !0 }), Object.keys(i).forEach(function(s) {
|
|
57
|
-
var n = Object.getOwnPropertyDescriptor(i, s);
|
|
58
|
-
Object.defineProperty(e, s, n.get ? n : {
|
|
59
|
-
enumerable: !0,
|
|
60
|
-
get: function() {
|
|
61
|
-
return i[s];
|
|
62
|
-
}
|
|
63
|
-
});
|
|
64
|
-
}), e;
|
|
65
|
-
}
|
|
66
|
-
(function() {
|
|
67
|
-
if (!(typeof globalThis < "u"))
|
|
68
|
-
if (typeof tt < "u")
|
|
69
|
-
tt.globalThis = tt;
|
|
70
|
-
else if (typeof self < "u")
|
|
71
|
-
self.globalThis = self;
|
|
72
|
-
else if (typeof window < "u")
|
|
73
|
-
window.globalThis = window;
|
|
74
|
-
else {
|
|
75
|
-
const t = new Function("return this")();
|
|
76
|
-
t.globalThis = t;
|
|
77
|
-
}
|
|
78
|
-
})();
|
|
10
|
+
e = "isolate";
|
|
11
|
+
}
|
|
12
|
+
var n;
|
|
13
|
+
switch (e) {
|
|
14
|
+
case "share":
|
|
15
|
+
n = Object.freeze({
|
|
16
|
+
updateQueue: 1,
|
|
17
|
+
observable: 2,
|
|
18
|
+
contextEvent: 3,
|
|
19
|
+
elementRegistry: 4
|
|
20
|
+
});
|
|
21
|
+
break;
|
|
22
|
+
case "share-v2":
|
|
23
|
+
n = Object.freeze({
|
|
24
|
+
updateQueue: 1.2,
|
|
25
|
+
observable: 2.2,
|
|
26
|
+
contextEvent: 3.2,
|
|
27
|
+
elementRegistry: 4.2
|
|
28
|
+
});
|
|
29
|
+
break;
|
|
30
|
+
default:
|
|
31
|
+
let e = `-${Math.random().toString(36).substring(2, 8)}`;
|
|
32
|
+
n = Object.freeze({
|
|
33
|
+
updateQueue: `1.2${e}`,
|
|
34
|
+
observable: `2.2${e}`,
|
|
35
|
+
contextEvent: `3.2${e}`,
|
|
36
|
+
elementRegistry: `4.2${e}`
|
|
37
|
+
});
|
|
38
|
+
break;
|
|
39
|
+
}
|
|
40
|
+
var r = (e) => typeof e == "function", i = (e) => typeof e == "string", a = () => void 0;
|
|
79
41
|
(function() {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
42
|
+
if (!(typeof globalThis < "u")) if (typeof global < "u") global.globalThis = global;
|
|
43
|
+
else if (typeof self < "u") self.globalThis = self;
|
|
44
|
+
else if (typeof window < "u") window.globalThis = window;
|
|
45
|
+
else {
|
|
46
|
+
let e = Function("return this")();
|
|
47
|
+
e.globalThis = e;
|
|
48
|
+
}
|
|
49
|
+
})(), (function() {
|
|
50
|
+
"requestIdleCallback" in globalThis || (globalThis.requestIdleCallback = function(e, t) {
|
|
51
|
+
let n = Date.now();
|
|
52
|
+
return setTimeout(() => {
|
|
53
|
+
e({
|
|
54
|
+
didTimeout: t?.timeout ? Date.now() - n >= t.timeout : !1,
|
|
55
|
+
timeRemaining: () => 0
|
|
56
|
+
});
|
|
57
|
+
}, 1);
|
|
58
|
+
}, globalThis.cancelIdleCallback = function(e) {
|
|
59
|
+
clearTimeout(e);
|
|
60
|
+
});
|
|
91
61
|
})();
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
62
|
+
//#endregion
|
|
63
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/platform.js
|
|
64
|
+
var o = {
|
|
65
|
+
configurable: !1,
|
|
66
|
+
enumerable: !1,
|
|
67
|
+
writable: !1
|
|
96
68
|
};
|
|
97
|
-
globalThis.FAST === void 0 && Reflect.defineProperty(globalThis, "FAST", Object.assign({ value:
|
|
98
|
-
|
|
99
|
-
if (
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
addMessages() {
|
|
113
|
-
}
|
|
114
|
-
});
|
|
115
|
-
const hi = Object.freeze([]);
|
|
116
|
-
function Pt() {
|
|
117
|
-
const i = /* @__PURE__ */ new Map();
|
|
118
|
-
return Object.freeze({
|
|
119
|
-
register(t) {
|
|
120
|
-
return i.has(t.type) ? !1 : (i.set(t.type, t), !0);
|
|
121
|
-
},
|
|
122
|
-
getByType(t) {
|
|
123
|
-
return i.get(t);
|
|
124
|
-
},
|
|
125
|
-
getForInstance(t) {
|
|
126
|
-
if (t != null)
|
|
127
|
-
return i.get(t.constructor);
|
|
128
|
-
}
|
|
129
|
-
});
|
|
130
|
-
}
|
|
131
|
-
function zt() {
|
|
132
|
-
const i = /* @__PURE__ */ new WeakMap();
|
|
133
|
-
return function(t) {
|
|
134
|
-
let e = i.get(t);
|
|
135
|
-
if (e === void 0) {
|
|
136
|
-
let s = Reflect.getPrototypeOf(t);
|
|
137
|
-
for (; e === void 0 && s !== null; )
|
|
138
|
-
e = i.get(s), s = Reflect.getPrototypeOf(s);
|
|
139
|
-
e = e === void 0 ? [] : e.slice(0), i.set(t, e);
|
|
140
|
-
}
|
|
141
|
-
return e;
|
|
142
|
-
};
|
|
143
|
-
}
|
|
144
|
-
function x(i) {
|
|
145
|
-
i.prototype.toJSON = pe;
|
|
146
|
-
}
|
|
147
|
-
const y = Object.freeze({
|
|
148
|
-
/**
|
|
149
|
-
* Not aspected.
|
|
150
|
-
*/
|
|
151
|
-
none: 0,
|
|
152
|
-
/**
|
|
153
|
-
* An attribute.
|
|
154
|
-
*/
|
|
155
|
-
attribute: 1,
|
|
156
|
-
/**
|
|
157
|
-
* A boolean attribute.
|
|
158
|
-
*/
|
|
159
|
-
booleanAttribute: 2,
|
|
160
|
-
/**
|
|
161
|
-
* A property.
|
|
162
|
-
*/
|
|
163
|
-
property: 3,
|
|
164
|
-
/**
|
|
165
|
-
* Content
|
|
166
|
-
*/
|
|
167
|
-
content: 4,
|
|
168
|
-
/**
|
|
169
|
-
* A token list.
|
|
170
|
-
*/
|
|
171
|
-
tokenList: 5,
|
|
172
|
-
/**
|
|
173
|
-
* An event.
|
|
174
|
-
*/
|
|
175
|
-
event: 6
|
|
176
|
-
}), pt = (i) => i, be = globalThis.trustedTypes ? globalThis.trustedTypes.createPolicy("fast-html", { createHTML: pt }) : { createHTML: pt };
|
|
177
|
-
let D = Object.freeze({
|
|
178
|
-
createHTML(i) {
|
|
179
|
-
return be.createHTML(i);
|
|
180
|
-
},
|
|
181
|
-
protect(i, t, e, s) {
|
|
182
|
-
return s;
|
|
183
|
-
}
|
|
69
|
+
globalThis.FAST === void 0 && Reflect.defineProperty(globalThis, "FAST", Object.assign({ value: Object.create(null) }, o));
|
|
70
|
+
var s = globalThis.FAST;
|
|
71
|
+
if (s.getById === void 0) {
|
|
72
|
+
let e = Object.create(null);
|
|
73
|
+
Reflect.defineProperty(s, "getById", Object.assign({ value(t, n) {
|
|
74
|
+
let r = e[t];
|
|
75
|
+
return r === void 0 && (r = n ? e[t] = n() : null), r;
|
|
76
|
+
} }, o));
|
|
77
|
+
}
|
|
78
|
+
s.error === void 0 && Object.assign(s, {
|
|
79
|
+
warn() {},
|
|
80
|
+
error(e) {
|
|
81
|
+
return /* @__PURE__ */ Error(`Error ${e}`);
|
|
82
|
+
},
|
|
83
|
+
addMessages() {}
|
|
184
84
|
});
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
85
|
+
var c = Object.freeze([]);
|
|
86
|
+
function l() {
|
|
87
|
+
let e = /* @__PURE__ */ new Map();
|
|
88
|
+
return Object.freeze({
|
|
89
|
+
register(t) {
|
|
90
|
+
return e.has(t.type) ? !1 : (e.set(t.type, t), !0);
|
|
91
|
+
},
|
|
92
|
+
getByType(t) {
|
|
93
|
+
return e.get(t);
|
|
94
|
+
},
|
|
95
|
+
getForInstance(t) {
|
|
96
|
+
if (t != null) return e.get(t.constructor);
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
}
|
|
100
|
+
function u() {
|
|
101
|
+
let e = /* @__PURE__ */ new WeakMap();
|
|
102
|
+
return function(t) {
|
|
103
|
+
let n = e.get(t);
|
|
104
|
+
if (n === void 0) {
|
|
105
|
+
let r = Reflect.getPrototypeOf(t);
|
|
106
|
+
for (; n === void 0 && r !== null;) n = e.get(r), r = Reflect.getPrototypeOf(r);
|
|
107
|
+
n = n === void 0 ? [] : n.slice(0), e.set(t, n);
|
|
108
|
+
}
|
|
109
|
+
return n;
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
function d(e) {
|
|
113
|
+
e.prototype.toJSON = a;
|
|
114
|
+
}
|
|
115
|
+
//#endregion
|
|
116
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/dom.js
|
|
117
|
+
var f = Object.freeze({
|
|
118
|
+
none: 0,
|
|
119
|
+
attribute: 1,
|
|
120
|
+
booleanAttribute: 2,
|
|
121
|
+
property: 3,
|
|
122
|
+
content: 4,
|
|
123
|
+
tokenList: 5,
|
|
124
|
+
event: 6
|
|
125
|
+
}), p = (e) => e, ee = globalThis.trustedTypes ? globalThis.trustedTypes.createPolicy("fast-html", { createHTML: p }) : { createHTML: p }, m = Object.freeze({
|
|
126
|
+
createHTML(e) {
|
|
127
|
+
return ee.createHTML(e);
|
|
128
|
+
},
|
|
129
|
+
protect(e, t, n, r) {
|
|
130
|
+
return r;
|
|
131
|
+
}
|
|
132
|
+
}), te = m, h = Object.freeze({
|
|
133
|
+
get policy() {
|
|
134
|
+
return m;
|
|
135
|
+
},
|
|
136
|
+
setPolicy(e) {
|
|
137
|
+
if (m !== te) throw s.error(1201);
|
|
138
|
+
m = e;
|
|
139
|
+
},
|
|
140
|
+
setAttribute(e, t, n) {
|
|
141
|
+
n == null ? e.removeAttribute(t) : e.setAttribute(t, n);
|
|
142
|
+
},
|
|
143
|
+
setBooleanAttribute(e, t, n) {
|
|
144
|
+
n ? e.setAttribute(t, "") : e.removeAttribute(t);
|
|
145
|
+
}
|
|
146
|
+
}), g = s.getById(n.updateQueue, () => {
|
|
147
|
+
let e = [], t = [], n = globalThis.requestAnimationFrame, r = !0;
|
|
148
|
+
function i() {
|
|
149
|
+
if (t.length) throw t.shift();
|
|
150
|
+
}
|
|
151
|
+
function a(n) {
|
|
152
|
+
try {
|
|
153
|
+
n.call();
|
|
154
|
+
} catch (n) {
|
|
155
|
+
if (r) t.push(n), setTimeout(i, 0);
|
|
156
|
+
else throw e.length = 0, n;
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
function o() {
|
|
160
|
+
let t = 0;
|
|
161
|
+
for (; t < e.length;) if (a(e[t]), t++, t > 1024) {
|
|
162
|
+
for (let n = 0, r = e.length - t; n < r; n++) e[n] = e[n + t];
|
|
163
|
+
e.length -= t, t = 0;
|
|
164
|
+
}
|
|
165
|
+
e.length = 0;
|
|
166
|
+
}
|
|
167
|
+
function s(t) {
|
|
168
|
+
e.push(t), e.length < 2 && (r ? n(o) : o());
|
|
169
|
+
}
|
|
170
|
+
return Object.freeze({
|
|
171
|
+
enqueue: s,
|
|
172
|
+
next: () => new Promise(s),
|
|
173
|
+
process: o,
|
|
174
|
+
setMode: (e) => r = e
|
|
175
|
+
});
|
|
176
|
+
}), _ = class {
|
|
177
|
+
constructor(e, t) {
|
|
178
|
+
this.sub1 = void 0, this.sub2 = void 0, this.spillover = void 0, this.subject = e, this.sub1 = t;
|
|
179
|
+
}
|
|
180
|
+
has(e) {
|
|
181
|
+
return this.spillover === void 0 ? this.sub1 === e || this.sub2 === e : this.spillover.indexOf(e) !== -1;
|
|
182
|
+
}
|
|
183
|
+
subscribe(e) {
|
|
184
|
+
let t = this.spillover;
|
|
185
|
+
if (t === void 0) {
|
|
186
|
+
if (this.has(e)) return;
|
|
187
|
+
if (this.sub1 === void 0) {
|
|
188
|
+
this.sub1 = e;
|
|
189
|
+
return;
|
|
190
|
+
}
|
|
191
|
+
if (this.sub2 === void 0) {
|
|
192
|
+
this.sub2 = e;
|
|
193
|
+
return;
|
|
194
|
+
}
|
|
195
|
+
this.spillover = [
|
|
196
|
+
this.sub1,
|
|
197
|
+
this.sub2,
|
|
198
|
+
e
|
|
199
|
+
], this.sub1 = void 0, this.sub2 = void 0;
|
|
200
|
+
} else t.indexOf(e) === -1 && t.push(e);
|
|
201
|
+
}
|
|
202
|
+
unsubscribe(e) {
|
|
203
|
+
let t = this.spillover;
|
|
204
|
+
if (t === void 0) this.sub1 === e ? this.sub1 = void 0 : this.sub2 === e && (this.sub2 = void 0);
|
|
205
|
+
else {
|
|
206
|
+
let n = t.indexOf(e);
|
|
207
|
+
n !== -1 && t.splice(n, 1);
|
|
208
|
+
}
|
|
209
|
+
}
|
|
210
|
+
notify(e) {
|
|
211
|
+
let t = this.spillover, n = this.subject;
|
|
212
|
+
if (t === void 0) {
|
|
213
|
+
let t = this.sub1, r = this.sub2;
|
|
214
|
+
t !== void 0 && t.handleChange(n, e), r !== void 0 && r.handleChange(n, e);
|
|
215
|
+
} else for (let r = 0, i = t.length; r < i; ++r) t[r].handleChange(n, e);
|
|
216
|
+
}
|
|
217
|
+
}, ne = class {
|
|
218
|
+
constructor(e) {
|
|
219
|
+
this.subscribers = {}, this.subjectSubscribers = null, this.subject = e;
|
|
220
|
+
}
|
|
221
|
+
notify(e) {
|
|
222
|
+
var t, n;
|
|
223
|
+
(t = this.subscribers[e]) == null || t.notify(e), (n = this.subjectSubscribers) == null || n.notify(e);
|
|
224
|
+
}
|
|
225
|
+
subscribe(e, t) {
|
|
226
|
+
let n;
|
|
227
|
+
n = t ? this.subscribers[t] ?? (this.subscribers[t] = new _(this.subject)) : this.subjectSubscribers ??= new _(this.subject), n.subscribe(e);
|
|
228
|
+
}
|
|
229
|
+
unsubscribe(e, t) {
|
|
230
|
+
var n, r;
|
|
231
|
+
t ? (n = this.subscribers[t]) == null || n.unsubscribe(e) : (r = this.subjectSubscribers) == null || r.unsubscribe(e);
|
|
232
|
+
}
|
|
233
|
+
}, v = Object.freeze({
|
|
234
|
+
unknown: void 0,
|
|
235
|
+
coupled: 1
|
|
236
|
+
}), y = s.getById(n.observable, () => {
|
|
237
|
+
let e = g.enqueue, t = /(:|&&|\|\||if|\?\.)/, n = /* @__PURE__ */ new WeakMap(), a, o = (e) => {
|
|
238
|
+
throw s.error(1101);
|
|
239
|
+
};
|
|
240
|
+
function c(e) {
|
|
241
|
+
let t = e.$fastController ?? n.get(e);
|
|
242
|
+
return t === void 0 && (Array.isArray(e) ? t = o(e) : n.set(e, t = new ne(e))), t;
|
|
243
|
+
}
|
|
244
|
+
let l = u();
|
|
245
|
+
class f {
|
|
246
|
+
constructor(e) {
|
|
247
|
+
this.name = e, this.field = `_${e}`, this.callback = `${e}Changed`;
|
|
248
|
+
}
|
|
249
|
+
getValue(e) {
|
|
250
|
+
return a !== void 0 && a.watch(e, this.name), e[this.field];
|
|
251
|
+
}
|
|
252
|
+
setValue(e, t) {
|
|
253
|
+
let n = this.field, i = e[n];
|
|
254
|
+
if (i !== t) {
|
|
255
|
+
e[n] = t;
|
|
256
|
+
let a = e[this.callback];
|
|
257
|
+
r(a) && a.call(e, i, t), c(e).notify(this.name);
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
class p extends _ {
|
|
262
|
+
constructor(e, t, n = !1) {
|
|
263
|
+
super(e, t), this.expression = e, this.isVolatileBinding = n, this.needsRefresh = !0, this.needsQueue = !0, this.isAsync = !0, this.first = this, this.last = null, this.propertySource = void 0, this.propertyName = void 0, this.notifier = void 0, this.next = void 0;
|
|
264
|
+
}
|
|
265
|
+
setMode(e) {
|
|
266
|
+
this.isAsync = this.needsQueue = e;
|
|
267
|
+
}
|
|
268
|
+
bind(e) {
|
|
269
|
+
this.controller = e;
|
|
270
|
+
let t = this.observe(e.source, e.context);
|
|
271
|
+
return !e.isBound && this.requiresUnbind(e) && e.onUnbind(this), t;
|
|
272
|
+
}
|
|
273
|
+
requiresUnbind(e) {
|
|
274
|
+
return e.sourceLifetime !== v.coupled || this.first !== this.last || this.first.propertySource !== e.source;
|
|
275
|
+
}
|
|
276
|
+
unbind(e) {
|
|
277
|
+
this.dispose();
|
|
278
|
+
}
|
|
279
|
+
observe(e, t) {
|
|
280
|
+
this.needsRefresh && this.last !== null && this.dispose();
|
|
281
|
+
let n = a;
|
|
282
|
+
a = this.needsRefresh ? this : void 0, this.needsRefresh = this.isVolatileBinding;
|
|
283
|
+
let r;
|
|
284
|
+
try {
|
|
285
|
+
r = this.expression(e, t);
|
|
286
|
+
} finally {
|
|
287
|
+
a = n;
|
|
288
|
+
}
|
|
289
|
+
return r;
|
|
290
|
+
}
|
|
291
|
+
disconnect() {
|
|
292
|
+
this.dispose();
|
|
293
|
+
}
|
|
294
|
+
dispose() {
|
|
295
|
+
if (this.last !== null) {
|
|
296
|
+
let e = this.first;
|
|
297
|
+
for (; e !== void 0;) e.notifier.unsubscribe(this, e.propertyName), e = e.next;
|
|
298
|
+
this.last = null, this.needsRefresh = this.needsQueue = this.isAsync;
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
watch(e, t) {
|
|
302
|
+
let n = this.last, r = c(e), i = n === null ? this.first : {};
|
|
303
|
+
if (i.propertySource = e, i.propertyName = t, i.notifier = r, r.subscribe(this, t), n !== null) {
|
|
304
|
+
if (!this.needsRefresh) {
|
|
305
|
+
let t;
|
|
306
|
+
a = void 0, t = n.propertySource[n.propertyName], a = this, e === t && (this.needsRefresh = !0);
|
|
307
|
+
}
|
|
308
|
+
n.next = i;
|
|
309
|
+
}
|
|
310
|
+
this.last = i;
|
|
311
|
+
}
|
|
312
|
+
handleChange() {
|
|
313
|
+
this.needsQueue ? (this.needsQueue = !1, e(this)) : this.isAsync || this.call();
|
|
314
|
+
}
|
|
315
|
+
call() {
|
|
316
|
+
this.last !== null && (this.needsQueue = this.isAsync, this.notify(this));
|
|
317
|
+
}
|
|
318
|
+
*records() {
|
|
319
|
+
let e = this.first;
|
|
320
|
+
for (; e !== void 0;) yield e, e = e.next;
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
return d(p), Object.freeze({
|
|
324
|
+
setArrayObserverFactory(e) {
|
|
325
|
+
o = e;
|
|
326
|
+
},
|
|
327
|
+
getNotifier: c,
|
|
328
|
+
track(e, t) {
|
|
329
|
+
a && a.watch(e, t);
|
|
330
|
+
},
|
|
331
|
+
trackVolatile() {
|
|
332
|
+
a && (a.needsRefresh = !0);
|
|
333
|
+
},
|
|
334
|
+
notify(e, t) {
|
|
335
|
+
c(e).notify(t);
|
|
336
|
+
},
|
|
337
|
+
defineProperty(e, t) {
|
|
338
|
+
i(t) && (t = new f(t)), l(e).push(t), Reflect.defineProperty(e, t.name, {
|
|
339
|
+
enumerable: !0,
|
|
340
|
+
get() {
|
|
341
|
+
return t.getValue(this);
|
|
342
|
+
},
|
|
343
|
+
set(e) {
|
|
344
|
+
t.setValue(this, e);
|
|
345
|
+
}
|
|
346
|
+
});
|
|
347
|
+
},
|
|
348
|
+
getAccessors: l,
|
|
349
|
+
binding(e, t, n = this.isVolatileBinding(e)) {
|
|
350
|
+
return new p(e, t, n);
|
|
351
|
+
},
|
|
352
|
+
isVolatileBinding(e) {
|
|
353
|
+
return t.test(e.toString());
|
|
354
|
+
}
|
|
355
|
+
});
|
|
266
356
|
});
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
const s = e.indexOf(t);
|
|
314
|
-
s !== -1 && e.splice(s, 1);
|
|
315
|
-
}
|
|
316
|
-
}
|
|
317
|
-
/**
|
|
318
|
-
* Notifies all subscribers.
|
|
319
|
-
* @param args - Data passed along to subscribers during notification.
|
|
320
|
-
*/
|
|
321
|
-
notify(t) {
|
|
322
|
-
const e = this.spillover, s = this.subject;
|
|
323
|
-
if (e === void 0) {
|
|
324
|
-
const n = this.sub1, r = this.sub2;
|
|
325
|
-
n !== void 0 && n.handleChange(s, t), r !== void 0 && r.handleChange(s, t);
|
|
326
|
-
} else
|
|
327
|
-
for (let n = 0, r = e.length; n < r; ++n)
|
|
328
|
-
e[n].handleChange(s, t);
|
|
329
|
-
}
|
|
330
|
-
}
|
|
331
|
-
class qt {
|
|
332
|
-
/**
|
|
333
|
-
* Creates an instance of PropertyChangeNotifier for the specified subject.
|
|
334
|
-
* @param subject - The object that subscribers will receive notifications for.
|
|
335
|
-
*/
|
|
336
|
-
constructor(t) {
|
|
337
|
-
this.subscribers = {}, this.subjectSubscribers = null, this.subject = t;
|
|
338
|
-
}
|
|
339
|
-
/**
|
|
340
|
-
* Notifies all subscribers, based on the specified property.
|
|
341
|
-
* @param propertyName - The property name, passed along to subscribers during notification.
|
|
342
|
-
*/
|
|
343
|
-
notify(t) {
|
|
344
|
-
var e, s;
|
|
345
|
-
(e = this.subscribers[t]) === null || e === void 0 || e.notify(t), (s = this.subjectSubscribers) === null || s === void 0 || s.notify(t);
|
|
346
|
-
}
|
|
347
|
-
/**
|
|
348
|
-
* Subscribes to notification of changes in an object's state.
|
|
349
|
-
* @param subscriber - The object that is subscribing for change notification.
|
|
350
|
-
* @param propertyToWatch - The name of the property that the subscriber is interested in watching for changes.
|
|
351
|
-
*/
|
|
352
|
-
subscribe(t, e) {
|
|
353
|
-
var s, n;
|
|
354
|
-
let r;
|
|
355
|
-
e ? r = (s = this.subscribers[e]) !== null && s !== void 0 ? s : this.subscribers[e] = new rt(this.subject) : r = (n = this.subjectSubscribers) !== null && n !== void 0 ? n : this.subjectSubscribers = new rt(this.subject), r.subscribe(t);
|
|
356
|
-
}
|
|
357
|
-
/**
|
|
358
|
-
* Unsubscribes from notification of changes in an object's state.
|
|
359
|
-
* @param subscriber - The object that is unsubscribing from change notification.
|
|
360
|
-
* @param propertyToUnwatch - The name of the property that the subscriber is no longer interested in watching.
|
|
361
|
-
*/
|
|
362
|
-
unsubscribe(t, e) {
|
|
363
|
-
var s, n;
|
|
364
|
-
e ? (s = this.subscribers[e]) === null || s === void 0 || s.unsubscribe(t) : (n = this.subjectSubscribers) === null || n === void 0 || n.unsubscribe(t);
|
|
365
|
-
}
|
|
366
|
-
}
|
|
367
|
-
const J = Object.freeze({
|
|
368
|
-
/**
|
|
369
|
-
* The source to controller lifetime relationship is unknown.
|
|
370
|
-
*/
|
|
371
|
-
unknown: void 0,
|
|
372
|
-
/**
|
|
373
|
-
* The source and controller lifetimes are coupled to one another.
|
|
374
|
-
* They can/will be GC'd together.
|
|
375
|
-
*/
|
|
376
|
-
coupled: 1
|
|
377
|
-
}), g = v.getById(N.observable, () => {
|
|
378
|
-
const i = Ut.enqueue, t = /(:|&&|\|\||if|\?\.)/, e = /* @__PURE__ */ new WeakMap();
|
|
379
|
-
let s, n = (l) => {
|
|
380
|
-
throw v.error(
|
|
381
|
-
1101
|
|
382
|
-
/* Message.needsArrayObservation */
|
|
383
|
-
);
|
|
384
|
-
};
|
|
385
|
-
function r(l) {
|
|
386
|
-
var a;
|
|
387
|
-
let h = (a = l.$fastController) !== null && a !== void 0 ? a : e.get(l);
|
|
388
|
-
return h === void 0 && (Array.isArray(l) ? h = n(l) : e.set(l, h = new qt(l))), h;
|
|
389
|
-
}
|
|
390
|
-
const o = zt();
|
|
391
|
-
class c {
|
|
392
|
-
constructor(a) {
|
|
393
|
-
this.name = a, this.field = `_${a}`, this.callback = `${a}Changed`;
|
|
394
|
-
}
|
|
395
|
-
getValue(a) {
|
|
396
|
-
return s !== void 0 && s.watch(a, this.name), a[this.field];
|
|
397
|
-
}
|
|
398
|
-
setValue(a, h) {
|
|
399
|
-
const u = this.field, b = a[u];
|
|
400
|
-
if (b !== h) {
|
|
401
|
-
a[u] = h;
|
|
402
|
-
const k = a[this.callback];
|
|
403
|
-
E(k) && k.call(a, b, h), r(a).notify(this.name);
|
|
404
|
-
}
|
|
405
|
-
}
|
|
406
|
-
}
|
|
407
|
-
class d extends rt {
|
|
408
|
-
constructor(a, h, u = !1) {
|
|
409
|
-
super(a, h), this.expression = a, this.isVolatileBinding = u, this.needsRefresh = !0, this.needsQueue = !0, this.isAsync = !0, this.first = this, this.last = null, this.propertySource = void 0, this.propertyName = void 0, this.notifier = void 0, this.next = void 0;
|
|
410
|
-
}
|
|
411
|
-
setMode(a) {
|
|
412
|
-
this.isAsync = this.needsQueue = a;
|
|
413
|
-
}
|
|
414
|
-
bind(a) {
|
|
415
|
-
this.controller = a;
|
|
416
|
-
const h = this.observe(a.source, a.context);
|
|
417
|
-
return !a.isBound && this.requiresUnbind(a) && a.onUnbind(this), h;
|
|
418
|
-
}
|
|
419
|
-
requiresUnbind(a) {
|
|
420
|
-
return a.sourceLifetime !== J.coupled || this.first !== this.last || this.first.propertySource !== a.source;
|
|
421
|
-
}
|
|
422
|
-
unbind(a) {
|
|
423
|
-
this.dispose();
|
|
424
|
-
}
|
|
425
|
-
observe(a, h) {
|
|
426
|
-
this.needsRefresh && this.last !== null && this.dispose();
|
|
427
|
-
const u = s;
|
|
428
|
-
s = this.needsRefresh ? this : void 0, this.needsRefresh = this.isVolatileBinding;
|
|
429
|
-
let b;
|
|
430
|
-
try {
|
|
431
|
-
b = this.expression(a, h);
|
|
432
|
-
} finally {
|
|
433
|
-
s = u;
|
|
434
|
-
}
|
|
435
|
-
return b;
|
|
436
|
-
}
|
|
437
|
-
// backwards compat with v1 kernel
|
|
438
|
-
disconnect() {
|
|
439
|
-
this.dispose();
|
|
440
|
-
}
|
|
441
|
-
dispose() {
|
|
442
|
-
if (this.last !== null) {
|
|
443
|
-
let a = this.first;
|
|
444
|
-
for (; a !== void 0; )
|
|
445
|
-
a.notifier.unsubscribe(this, a.propertyName), a = a.next;
|
|
446
|
-
this.last = null, this.needsRefresh = this.needsQueue = this.isAsync;
|
|
447
|
-
}
|
|
448
|
-
}
|
|
449
|
-
watch(a, h) {
|
|
450
|
-
const u = this.last, b = r(a), k = u === null ? this.first : {};
|
|
451
|
-
if (k.propertySource = a, k.propertyName = h, k.notifier = b, b.subscribe(this, h), u !== null) {
|
|
452
|
-
if (!this.needsRefresh) {
|
|
453
|
-
let ut;
|
|
454
|
-
s = void 0, ut = u.propertySource[u.propertyName], s = this, a === ut && (this.needsRefresh = !0);
|
|
455
|
-
}
|
|
456
|
-
u.next = k;
|
|
457
|
-
}
|
|
458
|
-
this.last = k;
|
|
459
|
-
}
|
|
460
|
-
handleChange() {
|
|
461
|
-
this.needsQueue ? (this.needsQueue = !1, i(this)) : this.isAsync || this.call();
|
|
462
|
-
}
|
|
463
|
-
call() {
|
|
464
|
-
this.last !== null && (this.needsQueue = this.isAsync, this.notify(this));
|
|
465
|
-
}
|
|
466
|
-
*records() {
|
|
467
|
-
let a = this.first;
|
|
468
|
-
for (; a !== void 0; )
|
|
469
|
-
yield a, a = a.next;
|
|
470
|
-
}
|
|
471
|
-
}
|
|
472
|
-
return x(d), Object.freeze({
|
|
473
|
-
/**
|
|
474
|
-
* @internal
|
|
475
|
-
* @param factory - The factory used to create array observers.
|
|
476
|
-
*/
|
|
477
|
-
setArrayObserverFactory(l) {
|
|
478
|
-
n = l;
|
|
479
|
-
},
|
|
480
|
-
/**
|
|
481
|
-
* Gets a notifier for an object or Array.
|
|
482
|
-
* @param source - The object or Array to get the notifier for.
|
|
483
|
-
*/
|
|
484
|
-
getNotifier: r,
|
|
485
|
-
/**
|
|
486
|
-
* Records a property change for a source object.
|
|
487
|
-
* @param source - The object to record the change against.
|
|
488
|
-
* @param propertyName - The property to track as changed.
|
|
489
|
-
*/
|
|
490
|
-
track(l, a) {
|
|
491
|
-
s && s.watch(l, a);
|
|
492
|
-
},
|
|
493
|
-
/**
|
|
494
|
-
* Notifies watchers that the currently executing property getter or function is volatile
|
|
495
|
-
* with respect to its observable dependencies.
|
|
496
|
-
*/
|
|
497
|
-
trackVolatile() {
|
|
498
|
-
s && (s.needsRefresh = !0);
|
|
499
|
-
},
|
|
500
|
-
/**
|
|
501
|
-
* Notifies subscribers of a source object of changes.
|
|
502
|
-
* @param source - the object to notify of changes.
|
|
503
|
-
* @param args - The change args to pass to subscribers.
|
|
504
|
-
*/
|
|
505
|
-
notify(l, a) {
|
|
506
|
-
r(l).notify(a);
|
|
507
|
-
},
|
|
508
|
-
/**
|
|
509
|
-
* Defines an observable property on an object or prototype.
|
|
510
|
-
* @param target - The target object to define the observable on.
|
|
511
|
-
* @param nameOrAccessor - The name of the property to define as observable;
|
|
512
|
-
* or a custom accessor that specifies the property name and accessor implementation.
|
|
513
|
-
*/
|
|
514
|
-
defineProperty(l, a) {
|
|
515
|
-
B(a) && (a = new c(a)), o(l).push(a), Reflect.defineProperty(l, a.name, {
|
|
516
|
-
enumerable: !0,
|
|
517
|
-
get() {
|
|
518
|
-
return a.getValue(this);
|
|
519
|
-
},
|
|
520
|
-
set(h) {
|
|
521
|
-
a.setValue(this, h);
|
|
522
|
-
}
|
|
523
|
-
});
|
|
524
|
-
},
|
|
525
|
-
/**
|
|
526
|
-
* Finds all the observable accessors defined on the target,
|
|
527
|
-
* including its prototype chain.
|
|
528
|
-
* @param target - The target object to search for accessor on.
|
|
529
|
-
*/
|
|
530
|
-
getAccessors: o,
|
|
531
|
-
/**
|
|
532
|
-
* Creates a {@link ExpressionNotifier} that can watch the
|
|
533
|
-
* provided {@link Expression} for changes.
|
|
534
|
-
* @param expression - The binding to observe.
|
|
535
|
-
* @param initialSubscriber - An initial subscriber to changes in the binding value.
|
|
536
|
-
* @param isVolatileBinding - Indicates whether the binding's dependency list must be re-evaluated on every value evaluation.
|
|
537
|
-
*/
|
|
538
|
-
binding(l, a, h = this.isVolatileBinding(l)) {
|
|
539
|
-
return new d(l, a, h);
|
|
540
|
-
},
|
|
541
|
-
/**
|
|
542
|
-
* Determines whether a binding expression is volatile and needs to have its dependency list re-evaluated
|
|
543
|
-
* on every evaluation of the value.
|
|
544
|
-
* @param expression - The binding to inspect.
|
|
545
|
-
*/
|
|
546
|
-
isVolatileBinding(l) {
|
|
547
|
-
return t.test(l.toString());
|
|
548
|
-
}
|
|
549
|
-
});
|
|
550
|
-
});
|
|
551
|
-
function ui(i, t) {
|
|
552
|
-
g.defineProperty(i, t);
|
|
553
|
-
}
|
|
554
|
-
function fi(i, t, e) {
|
|
555
|
-
return Object.assign({}, e, {
|
|
556
|
-
get() {
|
|
557
|
-
return g.trackVolatile(), e.get.apply(this);
|
|
558
|
-
}
|
|
559
|
-
});
|
|
560
|
-
}
|
|
561
|
-
const bt = v.getById(N.contextEvent, () => {
|
|
562
|
-
let i = null;
|
|
563
|
-
return {
|
|
564
|
-
get() {
|
|
565
|
-
return i;
|
|
566
|
-
},
|
|
567
|
-
set(t) {
|
|
568
|
-
i = t;
|
|
569
|
-
}
|
|
570
|
-
};
|
|
571
|
-
}), O = Object.freeze({
|
|
572
|
-
/**
|
|
573
|
-
* A default execution context.
|
|
574
|
-
*/
|
|
575
|
-
default: {
|
|
576
|
-
index: 0,
|
|
577
|
-
length: 0,
|
|
578
|
-
get event() {
|
|
579
|
-
return O.getEvent();
|
|
580
|
-
},
|
|
581
|
-
eventDetail() {
|
|
582
|
-
return this.event.detail;
|
|
583
|
-
},
|
|
584
|
-
eventTarget() {
|
|
585
|
-
return this.event.target;
|
|
586
|
-
}
|
|
587
|
-
},
|
|
588
|
-
/**
|
|
589
|
-
* Gets the current event.
|
|
590
|
-
* @returns An event object.
|
|
591
|
-
*/
|
|
592
|
-
getEvent() {
|
|
593
|
-
return bt.get();
|
|
594
|
-
},
|
|
595
|
-
/**
|
|
596
|
-
* Sets the current event.
|
|
597
|
-
* @param event - An event object.
|
|
598
|
-
*/
|
|
599
|
-
setEvent(i) {
|
|
600
|
-
bt.set(i);
|
|
601
|
-
}
|
|
602
|
-
});
|
|
603
|
-
class lt {
|
|
604
|
-
/**
|
|
605
|
-
* Creates a binding.
|
|
606
|
-
* @param evaluate - Evaluates the binding.
|
|
607
|
-
* @param policy - The security policy to associate with this binding.
|
|
608
|
-
* @param isVolatile - Indicates whether the binding is volatile.
|
|
609
|
-
*/
|
|
610
|
-
constructor(t, e, s = !1) {
|
|
611
|
-
this.evaluate = t, this.policy = e, this.isVolatile = s;
|
|
612
|
-
}
|
|
613
|
-
}
|
|
614
|
-
class ye extends lt {
|
|
615
|
-
createObserver(t) {
|
|
616
|
-
return g.binding(this.evaluate, t, this.isVolatile);
|
|
617
|
-
}
|
|
618
|
-
}
|
|
619
|
-
function Wt(i, t, e = g.isVolatileBinding(i)) {
|
|
620
|
-
return new ye(i, t, e);
|
|
621
|
-
}
|
|
622
|
-
class Qt extends lt {
|
|
623
|
-
createObserver() {
|
|
624
|
-
return this;
|
|
625
|
-
}
|
|
626
|
-
bind(t) {
|
|
627
|
-
return this.evaluate(t.source, t.context);
|
|
628
|
-
}
|
|
629
|
-
}
|
|
630
|
-
x(Qt);
|
|
631
|
-
function Gt(i, t) {
|
|
632
|
-
return new Qt(i, t);
|
|
633
|
-
}
|
|
634
|
-
let gt;
|
|
635
|
-
function Jt(i) {
|
|
636
|
-
return i.map((t) => t instanceof m ? Jt(t.styles) : [t]).reduce((t, e) => t.concat(e), []);
|
|
637
|
-
}
|
|
638
|
-
class m {
|
|
639
|
-
/**
|
|
640
|
-
* Creates an instance of ElementStyles.
|
|
641
|
-
* @param styles - The styles that will be associated with elements.
|
|
642
|
-
*/
|
|
643
|
-
constructor(t) {
|
|
644
|
-
this.styles = t, this.targets = /* @__PURE__ */ new WeakSet(), this._strategy = null, this.behaviors = t.map((e) => e instanceof m ? e.behaviors : null).reduce((e, s) => s === null ? e : e === null ? s : e.concat(s), null);
|
|
645
|
-
}
|
|
646
|
-
/**
|
|
647
|
-
* Gets the StyleStrategy associated with these element styles.
|
|
648
|
-
*/
|
|
649
|
-
get strategy() {
|
|
650
|
-
return this._strategy === null && this.withStrategy(gt), this._strategy;
|
|
651
|
-
}
|
|
652
|
-
/** @internal */
|
|
653
|
-
addStylesTo(t) {
|
|
654
|
-
this.strategy.addStylesTo(t), this.targets.add(t);
|
|
655
|
-
}
|
|
656
|
-
/** @internal */
|
|
657
|
-
removeStylesFrom(t) {
|
|
658
|
-
this.strategy.removeStylesFrom(t), this.targets.delete(t);
|
|
659
|
-
}
|
|
660
|
-
/** @internal */
|
|
661
|
-
isAttachedTo(t) {
|
|
662
|
-
return this.targets.has(t);
|
|
663
|
-
}
|
|
664
|
-
/**
|
|
665
|
-
* Associates behaviors with this set of styles.
|
|
666
|
-
* @param behaviors - The behaviors to associate.
|
|
667
|
-
*/
|
|
668
|
-
withBehaviors(...t) {
|
|
669
|
-
return this.behaviors = this.behaviors === null ? t : this.behaviors.concat(t), this;
|
|
670
|
-
}
|
|
671
|
-
/**
|
|
672
|
-
* Sets the strategy that handles adding/removing these styles for an element.
|
|
673
|
-
* @param strategy - The strategy to use.
|
|
674
|
-
*/
|
|
675
|
-
withStrategy(t) {
|
|
676
|
-
return this._strategy = new t(Jt(this.styles)), this;
|
|
677
|
-
}
|
|
678
|
-
/**
|
|
679
|
-
* Sets the default strategy type to use when creating style strategies.
|
|
680
|
-
* @param Strategy - The strategy type to construct.
|
|
681
|
-
*/
|
|
682
|
-
static setDefaultStrategy(t) {
|
|
683
|
-
gt = t;
|
|
684
|
-
}
|
|
685
|
-
/**
|
|
686
|
-
* Normalizes a set of composable style options.
|
|
687
|
-
* @param styles - The style options to normalize.
|
|
688
|
-
* @returns A singular ElementStyles instance or undefined.
|
|
689
|
-
*/
|
|
690
|
-
static normalize(t) {
|
|
691
|
-
return t === void 0 ? void 0 : Array.isArray(t) ? new m(t) : t instanceof m ? t : new m([t]);
|
|
692
|
-
}
|
|
693
|
-
}
|
|
694
|
-
m.supportsAdoptedStyleSheets = Array.isArray(document.adoptedStyleSheets) && "replace" in CSSStyleSheet.prototype;
|
|
695
|
-
const yt = /fe-b\$\$start\$\$(\d+)\$\$(.+)\$\$fe-b/, vt = /fe-b\$\$end\$\$(\d+)\$\$(.+)\$\$fe-b/, mt = /fe-repeat\$\$start\$\$(\d+)\$\$fe-repeat/, wt = /fe-repeat\$\$end\$\$(\d+)\$\$fe-repeat/, St = /^(?:.{0,1000})fe-eb\$\$start\$\$(.+?)\$\$fe-eb/, Ct = /fe-eb\$\$end\$\$(.{0,1000})\$\$fe-eb(?:.{0,1000})$/;
|
|
696
|
-
function kt(i) {
|
|
697
|
-
return i && i.nodeType === Node.COMMENT_NODE;
|
|
698
|
-
}
|
|
699
|
-
const w = Object.freeze({
|
|
700
|
-
attributeMarkerName: "data-fe-b",
|
|
701
|
-
attributeBindingSeparator: " ",
|
|
702
|
-
contentBindingStartMarker(i, t) {
|
|
703
|
-
return `fe-b$$start$$${i}$$${t}$$fe-b`;
|
|
704
|
-
},
|
|
705
|
-
contentBindingEndMarker(i, t) {
|
|
706
|
-
return `fe-b$$end$$${i}$$${t}$$fe-b`;
|
|
707
|
-
},
|
|
708
|
-
repeatStartMarker(i) {
|
|
709
|
-
return `fe-repeat$$start$$${i}$$fe-repeat`;
|
|
710
|
-
},
|
|
711
|
-
repeatEndMarker(i) {
|
|
712
|
-
return `fe-repeat$$end$$${i}$$fe-repeat`;
|
|
713
|
-
},
|
|
714
|
-
isContentBindingStartMarker(i) {
|
|
715
|
-
return yt.test(i);
|
|
716
|
-
},
|
|
717
|
-
isContentBindingEndMarker(i) {
|
|
718
|
-
return vt.test(i);
|
|
719
|
-
},
|
|
720
|
-
isRepeatViewStartMarker(i) {
|
|
721
|
-
return mt.test(i);
|
|
722
|
-
},
|
|
723
|
-
isRepeatViewEndMarker(i) {
|
|
724
|
-
return wt.test(i);
|
|
725
|
-
},
|
|
726
|
-
isElementBoundaryStartMarker(i) {
|
|
727
|
-
return kt(i) && St.test(i.data.trim());
|
|
728
|
-
},
|
|
729
|
-
isElementBoundaryEndMarker(i) {
|
|
730
|
-
return kt(i) && Ct.test(i.data);
|
|
731
|
-
},
|
|
732
|
-
/**
|
|
733
|
-
* Returns the indexes of the ViewBehaviorFactories affecting
|
|
734
|
-
* attributes for the element, or null if no factories were found.
|
|
735
|
-
*/
|
|
736
|
-
parseAttributeBinding(i) {
|
|
737
|
-
const t = i.getAttribute(this.attributeMarkerName);
|
|
738
|
-
return t === null ? t : t.split(this.attributeBindingSeparator).map((e) => parseInt(e));
|
|
739
|
-
},
|
|
740
|
-
/**
|
|
741
|
-
* Returns the indexes of the ViewBehaviorFactories affecting
|
|
742
|
-
* attributes for the element, or null if no factories were found.
|
|
743
|
-
*
|
|
744
|
-
* Uses the alternative syntax of data-fe-b-<number>
|
|
745
|
-
*/
|
|
746
|
-
parseEnumeratedAttributeBinding(i) {
|
|
747
|
-
const t = [], e = this.attributeMarkerName.length + 1, s = `${this.attributeMarkerName}-`;
|
|
748
|
-
for (const n of i.getAttributeNames())
|
|
749
|
-
if (n.startsWith(s)) {
|
|
750
|
-
const r = Number(n.slice(e));
|
|
751
|
-
if (!Number.isNaN(r))
|
|
752
|
-
t.push(r);
|
|
753
|
-
else
|
|
754
|
-
throw new Error(`Invalid attribute marker name: ${n}. Expected format is ${s}<number>.`);
|
|
755
|
-
}
|
|
756
|
-
return t.length === 0 ? null : t;
|
|
757
|
-
},
|
|
758
|
-
/**
|
|
759
|
-
* Parses the ViewBehaviorFactory index from string data. Returns
|
|
760
|
-
* the binding index or null if the index cannot be retrieved.
|
|
761
|
-
*/
|
|
762
|
-
parseContentBindingStartMarker(i) {
|
|
763
|
-
return Nt(yt, i);
|
|
764
|
-
},
|
|
765
|
-
parseContentBindingEndMarker(i) {
|
|
766
|
-
return Nt(vt, i);
|
|
767
|
-
},
|
|
768
|
-
/**
|
|
769
|
-
* Parses the index of a repeat directive from a content string.
|
|
770
|
-
*/
|
|
771
|
-
parseRepeatStartMarker(i) {
|
|
772
|
-
return Tt(mt, i);
|
|
773
|
-
},
|
|
774
|
-
parseRepeatEndMarker(i) {
|
|
775
|
-
return Tt(wt, i);
|
|
776
|
-
},
|
|
777
|
-
/**
|
|
778
|
-
* Parses element Id from element boundary markers
|
|
779
|
-
*/
|
|
780
|
-
parseElementBoundaryStartMarker(i) {
|
|
781
|
-
return $t(St, i.trim());
|
|
782
|
-
},
|
|
783
|
-
parseElementBoundaryEndMarker(i) {
|
|
784
|
-
return $t(Ct, i);
|
|
785
|
-
}
|
|
786
|
-
});
|
|
787
|
-
function Tt(i, t) {
|
|
788
|
-
const e = i.exec(t);
|
|
789
|
-
return e === null ? e : parseInt(e[1]);
|
|
790
|
-
}
|
|
791
|
-
function $t(i, t) {
|
|
792
|
-
const e = i.exec(t);
|
|
793
|
-
return e === null ? e : e[1];
|
|
794
|
-
}
|
|
795
|
-
function Nt(i, t) {
|
|
796
|
-
const e = i.exec(t);
|
|
797
|
-
return e === null ? e : [parseInt(e[1]), e[2]];
|
|
798
|
-
}
|
|
799
|
-
const z = Symbol.for("fe-hydration");
|
|
800
|
-
function U(i) {
|
|
801
|
-
return i[z] === z;
|
|
802
|
-
}
|
|
803
|
-
const ct = `fast-${Math.random().toString(36).substring(2, 8)}`, H = `${ct}{`, R = `}${ct}`, ve = R.length;
|
|
804
|
-
let me = 0;
|
|
805
|
-
const j = () => `${ct}-${++me}`, Kt = Object.freeze({
|
|
806
|
-
/**
|
|
807
|
-
* Creates a placeholder string suitable for marking out a location *within*
|
|
808
|
-
* an attribute value or HTML content.
|
|
809
|
-
* @param index - The directive index to create the placeholder for.
|
|
810
|
-
* @remarks
|
|
811
|
-
* Used internally by binding directives.
|
|
812
|
-
*/
|
|
813
|
-
interpolation: (i) => `${H}${i}${R}`,
|
|
814
|
-
/**
|
|
815
|
-
* Creates a placeholder that manifests itself as an attribute on an
|
|
816
|
-
* element.
|
|
817
|
-
* @param attributeName - The name of the custom attribute.
|
|
818
|
-
* @param index - The directive index to create the placeholder for.
|
|
819
|
-
* @remarks
|
|
820
|
-
* Used internally by attribute directives such as `ref`, `slotted`, and `children`.
|
|
821
|
-
*/
|
|
822
|
-
attribute: (i) => `${j()}="${H}${i}${R}"`,
|
|
823
|
-
/**
|
|
824
|
-
* Creates a placeholder that manifests itself as a marker within the DOM structure.
|
|
825
|
-
* @param index - The directive index to create the placeholder for.
|
|
826
|
-
* @remarks
|
|
827
|
-
* Used internally by structural directives such as `repeat`.
|
|
828
|
-
*/
|
|
829
|
-
comment: (i) => `<!--${H}${i}${R}-->`
|
|
830
|
-
}), K = Object.freeze({
|
|
831
|
-
/**
|
|
832
|
-
* Parses text content or HTML attribute content, separating out the static strings
|
|
833
|
-
* from the directives.
|
|
834
|
-
* @param value - The content or attribute string to parse.
|
|
835
|
-
* @param factories - A list of directives to search for in the string.
|
|
836
|
-
* @returns A heterogeneous array of static strings interspersed with
|
|
837
|
-
* directives or null if no directives are found in the string.
|
|
838
|
-
*/
|
|
839
|
-
parse(i, t) {
|
|
840
|
-
const e = i.split(H);
|
|
841
|
-
if (e.length === 1)
|
|
842
|
-
return null;
|
|
843
|
-
const s = [];
|
|
844
|
-
for (let n = 0, r = e.length; n < r; ++n) {
|
|
845
|
-
const o = e[n], c = o.indexOf(R);
|
|
846
|
-
let d;
|
|
847
|
-
if (c === -1)
|
|
848
|
-
d = o;
|
|
849
|
-
else {
|
|
850
|
-
const l = o.substring(0, c);
|
|
851
|
-
s.push(t[l]), d = o.substring(c + ve);
|
|
852
|
-
}
|
|
853
|
-
d !== "" && s.push(d);
|
|
854
|
-
}
|
|
855
|
-
return s;
|
|
856
|
-
}
|
|
857
|
-
}), et = Pt(), $ = Object.freeze({
|
|
858
|
-
/**
|
|
859
|
-
* Gets the directive definition associated with the instance.
|
|
860
|
-
* @param instance - The directive instance to retrieve the definition for.
|
|
861
|
-
*/
|
|
862
|
-
getForInstance: et.getForInstance,
|
|
863
|
-
/**
|
|
864
|
-
* Gets the directive definition associated with the specified type.
|
|
865
|
-
* @param type - The directive type to retrieve the definition for.
|
|
866
|
-
*/
|
|
867
|
-
getByType: et.getByType,
|
|
868
|
-
/**
|
|
869
|
-
* Defines an HTMLDirective based on the options.
|
|
870
|
-
* @param type - The type to define as a directive.
|
|
871
|
-
* @param options - Options that specify the directive's application.
|
|
872
|
-
*/
|
|
873
|
-
define(i, t) {
|
|
874
|
-
return t = t || {}, t.type = i, et.register(t), i;
|
|
875
|
-
},
|
|
876
|
-
/**
|
|
877
|
-
*
|
|
878
|
-
* @param directive - The directive to assign the aspect to.
|
|
879
|
-
* @param value - The value to base the aspect determination on.
|
|
880
|
-
* @remarks
|
|
881
|
-
* If a falsy value is provided, then the content aspect will be assigned.
|
|
882
|
-
*/
|
|
883
|
-
assignAspect(i, t) {
|
|
884
|
-
if (!t) {
|
|
885
|
-
i.aspectType = y.content;
|
|
886
|
-
return;
|
|
887
|
-
}
|
|
888
|
-
switch (i.sourceAspect = t, t[0]) {
|
|
889
|
-
case ":":
|
|
890
|
-
i.targetAspect = t.substring(1), i.aspectType = i.targetAspect === "classList" ? y.tokenList : y.property;
|
|
891
|
-
break;
|
|
892
|
-
case "?":
|
|
893
|
-
i.targetAspect = t.substring(1), i.aspectType = y.booleanAttribute;
|
|
894
|
-
break;
|
|
895
|
-
case "@":
|
|
896
|
-
i.targetAspect = t.substring(1), i.aspectType = y.event;
|
|
897
|
-
break;
|
|
898
|
-
default:
|
|
899
|
-
i.targetAspect = t, i.aspectType = y.attribute;
|
|
900
|
-
break;
|
|
901
|
-
}
|
|
902
|
-
}
|
|
903
|
-
});
|
|
904
|
-
class we {
|
|
905
|
-
/**
|
|
906
|
-
* Creates an instance of RefDirective.
|
|
907
|
-
* @param options - The options to use in configuring the directive.
|
|
908
|
-
*/
|
|
909
|
-
constructor(t) {
|
|
910
|
-
this.options = t;
|
|
911
|
-
}
|
|
912
|
-
/**
|
|
913
|
-
* Creates a placeholder string based on the directive's index within the template.
|
|
914
|
-
* @param index - The index of the directive within the template.
|
|
915
|
-
* @remarks
|
|
916
|
-
* Creates a custom attribute placeholder.
|
|
917
|
-
*/
|
|
918
|
-
createHTML(t) {
|
|
919
|
-
return Kt.attribute(t(this));
|
|
920
|
-
}
|
|
921
|
-
/**
|
|
922
|
-
* Creates a behavior.
|
|
923
|
-
* @param targets - The targets available for behaviors to be attached to.
|
|
924
|
-
*/
|
|
925
|
-
createBehavior() {
|
|
926
|
-
return this;
|
|
927
|
-
}
|
|
928
|
-
}
|
|
929
|
-
x(we);
|
|
930
|
-
class Xt extends Error {
|
|
931
|
-
constructor(t, e, s) {
|
|
932
|
-
super(t), this.factories = e, this.node = s;
|
|
933
|
-
}
|
|
934
|
-
}
|
|
935
|
-
function dt(i) {
|
|
936
|
-
return i.nodeType === Node.COMMENT_NODE;
|
|
937
|
-
}
|
|
938
|
-
function Yt(i) {
|
|
939
|
-
return i.nodeType === Node.TEXT_NODE;
|
|
940
|
-
}
|
|
941
|
-
function Zt(i, t) {
|
|
942
|
-
const e = document.createRange();
|
|
943
|
-
return e.setStart(i, 0), e.setEnd(t, dt(t) || Yt(t) ? t.data.length : t.childNodes.length), e;
|
|
944
|
-
}
|
|
945
|
-
function Se(i) {
|
|
946
|
-
return i instanceof DocumentFragment && "mode" in i;
|
|
947
|
-
}
|
|
948
|
-
function Ce(i, t, e) {
|
|
949
|
-
const s = Zt(i, t), n = s.commonAncestorContainer, r = document.createTreeWalker(n, NodeFilter.SHOW_ELEMENT + NodeFilter.SHOW_COMMENT + NodeFilter.SHOW_TEXT, {
|
|
950
|
-
acceptNode(l) {
|
|
951
|
-
return s.comparePoint(l, 0) === 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_REJECT;
|
|
952
|
-
}
|
|
953
|
-
}), o = {}, c = {};
|
|
954
|
-
let d = r.currentNode = i;
|
|
955
|
-
for (; d !== null; ) {
|
|
956
|
-
switch (d.nodeType) {
|
|
957
|
-
case Node.ELEMENT_NODE: {
|
|
958
|
-
ke(d, e, o);
|
|
959
|
-
break;
|
|
960
|
-
}
|
|
961
|
-
case Node.COMMENT_NODE: {
|
|
962
|
-
Te(d, r, e, o, c);
|
|
963
|
-
break;
|
|
964
|
-
}
|
|
965
|
-
}
|
|
966
|
-
d = r.nextNode();
|
|
967
|
-
}
|
|
968
|
-
return s.detach(), { targets: o, boundaries: c };
|
|
969
|
-
}
|
|
970
|
-
function ke(i, t, e) {
|
|
971
|
-
var s;
|
|
972
|
-
const n = (s = w.parseAttributeBinding(i)) !== null && s !== void 0 ? s : w.parseEnumeratedAttributeBinding(i);
|
|
973
|
-
if (n !== null) {
|
|
974
|
-
for (const r of n) {
|
|
975
|
-
if (!t[r])
|
|
976
|
-
throw new Xt(`HydrationView was unable to successfully target factory on ${i.nodeName} inside ${i.getRootNode().host.nodeName}. This likely indicates a template mismatch between SSR rendering and hydration.`, t, i);
|
|
977
|
-
q(t[r], i, e);
|
|
978
|
-
}
|
|
979
|
-
i.removeAttribute(w.attributeMarkerName);
|
|
980
|
-
}
|
|
981
|
-
}
|
|
982
|
-
function Te(i, t, e, s, n) {
|
|
983
|
-
if (w.isElementBoundaryStartMarker(i)) {
|
|
984
|
-
$e(i, t);
|
|
985
|
-
return;
|
|
986
|
-
}
|
|
987
|
-
if (w.isContentBindingStartMarker(i.data)) {
|
|
988
|
-
const r = w.parseContentBindingStartMarker(i.data);
|
|
989
|
-
if (r === null)
|
|
990
|
-
return;
|
|
991
|
-
const [o, c] = r, d = e[o], l = [];
|
|
992
|
-
let a = t.nextSibling();
|
|
993
|
-
i.data = "";
|
|
994
|
-
const h = a;
|
|
995
|
-
for (; a !== null; ) {
|
|
996
|
-
if (dt(a)) {
|
|
997
|
-
const u = w.parseContentBindingEndMarker(a.data);
|
|
998
|
-
if (u && u[1] === c)
|
|
999
|
-
break;
|
|
1000
|
-
}
|
|
1001
|
-
l.push(a), a = t.nextSibling();
|
|
1002
|
-
}
|
|
1003
|
-
if (a === null) {
|
|
1004
|
-
const u = i.getRootNode();
|
|
1005
|
-
throw new Error(`Error hydrating Comment node inside "${Se(u) ? u.host.nodeName : u.nodeName}".`);
|
|
1006
|
-
}
|
|
1007
|
-
if (a.data = "", l.length === 1 && Yt(l[0]))
|
|
1008
|
-
q(d, l[0], s);
|
|
1009
|
-
else {
|
|
1010
|
-
a !== h && a.previousSibling !== null && (n[d.targetNodeId] = {
|
|
1011
|
-
first: h,
|
|
1012
|
-
last: a.previousSibling
|
|
1013
|
-
});
|
|
1014
|
-
const u = a.parentNode.insertBefore(document.createTextNode(""), a);
|
|
1015
|
-
q(d, u, s);
|
|
1016
|
-
}
|
|
1017
|
-
}
|
|
1018
|
-
}
|
|
1019
|
-
function $e(i, t) {
|
|
1020
|
-
const e = w.parseElementBoundaryStartMarker(i.data);
|
|
1021
|
-
let s = t.nextSibling();
|
|
1022
|
-
for (; s !== null; ) {
|
|
1023
|
-
if (dt(s)) {
|
|
1024
|
-
const n = w.parseElementBoundaryEndMarker(s.data);
|
|
1025
|
-
if (n && n === e)
|
|
1026
|
-
break;
|
|
1027
|
-
}
|
|
1028
|
-
s = t.nextSibling();
|
|
1029
|
-
}
|
|
1030
|
-
}
|
|
1031
|
-
function q(i, t, e) {
|
|
1032
|
-
if (i.targetNodeId === void 0)
|
|
1033
|
-
throw new Error("Factory could not be target to the node");
|
|
1034
|
-
e[i.targetNodeId] = t;
|
|
1035
|
-
}
|
|
1036
|
-
var te;
|
|
1037
|
-
function at(i, t) {
|
|
1038
|
-
const e = i.parentNode;
|
|
1039
|
-
let s = i, n;
|
|
1040
|
-
for (; s !== t; ) {
|
|
1041
|
-
if (n = s.nextSibling, !n)
|
|
1042
|
-
throw new Error(`Unmatched first/last child inside "${t.getRootNode().host.nodeName}".`);
|
|
1043
|
-
e.removeChild(s), s = n;
|
|
1044
|
-
}
|
|
1045
|
-
e.removeChild(t);
|
|
1046
|
-
}
|
|
1047
|
-
class ee {
|
|
1048
|
-
constructor() {
|
|
1049
|
-
this.index = 0, this.length = 0;
|
|
1050
|
-
}
|
|
1051
|
-
/**
|
|
1052
|
-
* The current event within an event handler.
|
|
1053
|
-
*/
|
|
1054
|
-
get event() {
|
|
1055
|
-
return O.getEvent();
|
|
1056
|
-
}
|
|
1057
|
-
/**
|
|
1058
|
-
* Indicates whether the current item within a repeat context
|
|
1059
|
-
* has an even index.
|
|
1060
|
-
*/
|
|
1061
|
-
get isEven() {
|
|
1062
|
-
return this.index % 2 === 0;
|
|
1063
|
-
}
|
|
1064
|
-
/**
|
|
1065
|
-
* Indicates whether the current item within a repeat context
|
|
1066
|
-
* has an odd index.
|
|
1067
|
-
*/
|
|
1068
|
-
get isOdd() {
|
|
1069
|
-
return this.index % 2 !== 0;
|
|
1070
|
-
}
|
|
1071
|
-
/**
|
|
1072
|
-
* Indicates whether the current item within a repeat context
|
|
1073
|
-
* is the first item in the collection.
|
|
1074
|
-
*/
|
|
1075
|
-
get isFirst() {
|
|
1076
|
-
return this.index === 0;
|
|
1077
|
-
}
|
|
1078
|
-
/**
|
|
1079
|
-
* Indicates whether the current item within a repeat context
|
|
1080
|
-
* is somewhere in the middle of the collection.
|
|
1081
|
-
*/
|
|
1082
|
-
get isInMiddle() {
|
|
1083
|
-
return !this.isFirst && !this.isLast;
|
|
1084
|
-
}
|
|
1085
|
-
/**
|
|
1086
|
-
* Indicates whether the current item within a repeat context
|
|
1087
|
-
* is the last item in the collection.
|
|
1088
|
-
*/
|
|
1089
|
-
get isLast() {
|
|
1090
|
-
return this.index === this.length - 1;
|
|
1091
|
-
}
|
|
1092
|
-
/**
|
|
1093
|
-
* Returns the typed event detail of a custom event.
|
|
1094
|
-
*/
|
|
1095
|
-
eventDetail() {
|
|
1096
|
-
return this.event.detail;
|
|
1097
|
-
}
|
|
1098
|
-
/**
|
|
1099
|
-
* Returns the typed event target of the event.
|
|
1100
|
-
*/
|
|
1101
|
-
eventTarget() {
|
|
1102
|
-
return this.event.target;
|
|
1103
|
-
}
|
|
1104
|
-
}
|
|
1105
|
-
class X extends ee {
|
|
1106
|
-
/**
|
|
1107
|
-
* Constructs an instance of HTMLView.
|
|
1108
|
-
* @param fragment - The html fragment that contains the nodes for this view.
|
|
1109
|
-
* @param behaviors - The behaviors to be applied to this view.
|
|
1110
|
-
*/
|
|
1111
|
-
constructor(t, e, s) {
|
|
1112
|
-
super(), this.fragment = t, this.factories = e, this.targets = s, this.behaviors = null, this.unbindables = [], this.source = null, this.isBound = !1, this.sourceLifetime = J.unknown, this.context = this, this.firstChild = t.firstChild, this.lastChild = t.lastChild;
|
|
1113
|
-
}
|
|
1114
|
-
/**
|
|
1115
|
-
* Appends the view's DOM nodes to the referenced node.
|
|
1116
|
-
* @param node - The parent node to append the view's DOM nodes to.
|
|
1117
|
-
*/
|
|
1118
|
-
appendTo(t) {
|
|
1119
|
-
t.appendChild(this.fragment);
|
|
1120
|
-
}
|
|
1121
|
-
/**
|
|
1122
|
-
* Inserts the view's DOM nodes before the referenced node.
|
|
1123
|
-
* @param node - The node to insert the view's DOM before.
|
|
1124
|
-
*/
|
|
1125
|
-
insertBefore(t) {
|
|
1126
|
-
if (this.fragment.hasChildNodes())
|
|
1127
|
-
t.parentNode.insertBefore(this.fragment, t);
|
|
1128
|
-
else {
|
|
1129
|
-
const e = this.lastChild;
|
|
1130
|
-
if (t.previousSibling === e)
|
|
1131
|
-
return;
|
|
1132
|
-
const s = t.parentNode;
|
|
1133
|
-
let n = this.firstChild, r;
|
|
1134
|
-
for (; n !== e; )
|
|
1135
|
-
r = n.nextSibling, s.insertBefore(n, t), n = r;
|
|
1136
|
-
s.insertBefore(e, t);
|
|
1137
|
-
}
|
|
1138
|
-
}
|
|
1139
|
-
/**
|
|
1140
|
-
* Removes the view's DOM nodes.
|
|
1141
|
-
* The nodes are not disposed and the view can later be re-inserted.
|
|
1142
|
-
*/
|
|
1143
|
-
remove() {
|
|
1144
|
-
const t = this.fragment, e = this.lastChild;
|
|
1145
|
-
let s = this.firstChild, n;
|
|
1146
|
-
for (; s !== e; )
|
|
1147
|
-
n = s.nextSibling, t.appendChild(s), s = n;
|
|
1148
|
-
t.appendChild(e);
|
|
1149
|
-
}
|
|
1150
|
-
/**
|
|
1151
|
-
* Removes the view and unbinds its behaviors, disposing of DOM nodes afterward.
|
|
1152
|
-
* Once a view has been disposed, it cannot be inserted or bound again.
|
|
1153
|
-
*/
|
|
1154
|
-
dispose() {
|
|
1155
|
-
at(this.firstChild, this.lastChild), this.unbind();
|
|
1156
|
-
}
|
|
1157
|
-
onUnbind(t) {
|
|
1158
|
-
this.unbindables.push(t);
|
|
1159
|
-
}
|
|
1160
|
-
/**
|
|
1161
|
-
* Binds a view's behaviors to its binding source.
|
|
1162
|
-
* @param source - The binding source for the view's binding behaviors.
|
|
1163
|
-
* @param context - The execution context to run the behaviors within.
|
|
1164
|
-
*/
|
|
1165
|
-
bind(t, e = this) {
|
|
1166
|
-
if (this.source === t)
|
|
1167
|
-
return;
|
|
1168
|
-
let s = this.behaviors;
|
|
1169
|
-
if (s === null) {
|
|
1170
|
-
this.source = t, this.context = e, this.behaviors = s = new Array(this.factories.length);
|
|
1171
|
-
const n = this.factories;
|
|
1172
|
-
for (let r = 0, o = n.length; r < o; ++r) {
|
|
1173
|
-
const c = n[r].createBehavior();
|
|
1174
|
-
c.bind(this), s[r] = c;
|
|
1175
|
-
}
|
|
1176
|
-
} else {
|
|
1177
|
-
this.source !== null && this.evaluateUnbindables(), this.isBound = !1, this.source = t, this.context = e;
|
|
1178
|
-
for (let n = 0, r = s.length; n < r; ++n)
|
|
1179
|
-
s[n].bind(this);
|
|
1180
|
-
}
|
|
1181
|
-
this.isBound = !0;
|
|
1182
|
-
}
|
|
1183
|
-
/**
|
|
1184
|
-
* Unbinds a view's behaviors from its binding source.
|
|
1185
|
-
*/
|
|
1186
|
-
unbind() {
|
|
1187
|
-
!this.isBound || this.source === null || (this.evaluateUnbindables(), this.source = null, this.context = this, this.isBound = !1);
|
|
1188
|
-
}
|
|
1189
|
-
evaluateUnbindables() {
|
|
1190
|
-
const t = this.unbindables;
|
|
1191
|
-
for (let e = 0, s = t.length; e < s; ++e)
|
|
1192
|
-
t[e].unbind(this);
|
|
1193
|
-
t.length = 0;
|
|
1194
|
-
}
|
|
1195
|
-
/**
|
|
1196
|
-
* Efficiently disposes of a contiguous range of synthetic view instances.
|
|
1197
|
-
* @param views - A contiguous range of views to be disposed.
|
|
1198
|
-
*/
|
|
1199
|
-
static disposeContiguousBatch(t) {
|
|
1200
|
-
if (t.length !== 0) {
|
|
1201
|
-
at(t[0].firstChild, t[t.length - 1].lastChild);
|
|
1202
|
-
for (let e = 0, s = t.length; e < s; ++e)
|
|
1203
|
-
t[e].unbind();
|
|
1204
|
-
}
|
|
1205
|
-
}
|
|
1206
|
-
}
|
|
1207
|
-
x(X);
|
|
1208
|
-
g.defineProperty(X.prototype, "index");
|
|
1209
|
-
g.defineProperty(X.prototype, "length");
|
|
1210
|
-
const A = {
|
|
1211
|
-
unhydrated: "unhydrated",
|
|
1212
|
-
hydrating: "hydrating",
|
|
1213
|
-
hydrated: "hydrated"
|
|
357
|
+
function re(e, t) {
|
|
358
|
+
y.defineProperty(e, t);
|
|
359
|
+
}
|
|
360
|
+
function ie(e, t, n) {
|
|
361
|
+
return Object.assign({}, n, { get() {
|
|
362
|
+
return y.trackVolatile(), n.get.apply(this);
|
|
363
|
+
} });
|
|
364
|
+
}
|
|
365
|
+
var ae = s.getById(n.contextEvent, () => {
|
|
366
|
+
let e = null;
|
|
367
|
+
return {
|
|
368
|
+
get() {
|
|
369
|
+
return e;
|
|
370
|
+
},
|
|
371
|
+
set(t) {
|
|
372
|
+
e = t;
|
|
373
|
+
}
|
|
374
|
+
};
|
|
375
|
+
}), b = Object.freeze({
|
|
376
|
+
default: {
|
|
377
|
+
index: 0,
|
|
378
|
+
length: 0,
|
|
379
|
+
get event() {
|
|
380
|
+
return b.getEvent();
|
|
381
|
+
},
|
|
382
|
+
eventDetail() {
|
|
383
|
+
return this.event.detail;
|
|
384
|
+
},
|
|
385
|
+
eventTarget() {
|
|
386
|
+
return this.event.target;
|
|
387
|
+
}
|
|
388
|
+
},
|
|
389
|
+
getEvent() {
|
|
390
|
+
return ae.get();
|
|
391
|
+
},
|
|
392
|
+
setEvent(e) {
|
|
393
|
+
ae.set(e);
|
|
394
|
+
}
|
|
395
|
+
}), x = class {
|
|
396
|
+
constructor(e, t, n = !1) {
|
|
397
|
+
this.evaluate = e, this.policy = t, this.isVolatile = n;
|
|
398
|
+
}
|
|
399
|
+
}, oe = class extends x {
|
|
400
|
+
createObserver(e) {
|
|
401
|
+
return y.binding(this.evaluate, e, this.isVolatile);
|
|
402
|
+
}
|
|
1214
403
|
};
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
class
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
get targets() {
|
|
1228
|
-
return this._targets;
|
|
1229
|
-
}
|
|
1230
|
-
get bindingViewBoundaries() {
|
|
1231
|
-
return this._bindingViewBoundaries;
|
|
1232
|
-
}
|
|
1233
|
-
/**
|
|
1234
|
-
* no-op. Hydrated views are don't need to be moved from a documentFragment
|
|
1235
|
-
* to the target node.
|
|
1236
|
-
*/
|
|
1237
|
-
insertBefore(t) {
|
|
1238
|
-
if (this.fragment !== null)
|
|
1239
|
-
if (this.fragment.hasChildNodes())
|
|
1240
|
-
t.parentNode.insertBefore(this.fragment, t);
|
|
1241
|
-
else {
|
|
1242
|
-
const e = this.lastChild;
|
|
1243
|
-
if (t.previousSibling === e)
|
|
1244
|
-
return;
|
|
1245
|
-
const s = t.parentNode;
|
|
1246
|
-
let n = this.firstChild, r;
|
|
1247
|
-
for (; n !== e; )
|
|
1248
|
-
r = n.nextSibling, s.insertBefore(n, t), n = r;
|
|
1249
|
-
s.insertBefore(e, t);
|
|
1250
|
-
}
|
|
1251
|
-
}
|
|
1252
|
-
/**
|
|
1253
|
-
* Appends the view to a node. In cases where this is called before the
|
|
1254
|
-
* view has been removed, the method will no-op.
|
|
1255
|
-
* @param node - the node to append the view to.
|
|
1256
|
-
*/
|
|
1257
|
-
appendTo(t) {
|
|
1258
|
-
this.fragment !== null && t.appendChild(this.fragment);
|
|
1259
|
-
}
|
|
1260
|
-
remove() {
|
|
1261
|
-
const t = this.fragment || (this.fragment = document.createDocumentFragment()), e = this.lastChild;
|
|
1262
|
-
let s = this.firstChild, n;
|
|
1263
|
-
for (; s !== e; ) {
|
|
1264
|
-
if (n = s.nextSibling, !n)
|
|
1265
|
-
throw new Error(`Unmatched first/last child inside "${e.getRootNode().host.nodeName}".`);
|
|
1266
|
-
t.appendChild(s), s = n;
|
|
1267
|
-
}
|
|
1268
|
-
t.appendChild(e);
|
|
1269
|
-
}
|
|
1270
|
-
bind(t, e = this) {
|
|
1271
|
-
var s;
|
|
1272
|
-
if (this.hydrationStage !== A.hydrated && (this._hydrationStage = A.hydrating), this.source === t)
|
|
1273
|
-
return;
|
|
1274
|
-
let n = this.behaviors;
|
|
1275
|
-
if (n === null) {
|
|
1276
|
-
this.source = t, this.context = e;
|
|
1277
|
-
try {
|
|
1278
|
-
const { targets: o, boundaries: c } = Ce(this.firstChild, this.lastChild, this.factories);
|
|
1279
|
-
this._targets = o, this._bindingViewBoundaries = c;
|
|
1280
|
-
} catch (o) {
|
|
1281
|
-
if (o instanceof Xt) {
|
|
1282
|
-
let c = this.sourceTemplate.html;
|
|
1283
|
-
typeof c != "string" && (c = c.innerHTML), o.templateString = c;
|
|
1284
|
-
}
|
|
1285
|
-
throw o;
|
|
1286
|
-
}
|
|
1287
|
-
this.behaviors = n = new Array(this.factories.length);
|
|
1288
|
-
const r = this.factories;
|
|
1289
|
-
for (let o = 0, c = r.length; o < c; ++o) {
|
|
1290
|
-
const d = r[o];
|
|
1291
|
-
if (d.targetNodeId === "h" && this.hostBindingTarget && q(d, this.hostBindingTarget, this._targets), d.targetNodeId in this.targets) {
|
|
1292
|
-
const l = d.createBehavior();
|
|
1293
|
-
l.bind(this), n[o] = l;
|
|
1294
|
-
} else {
|
|
1295
|
-
let l = this.sourceTemplate.html;
|
|
1296
|
-
typeof l != "string" && (l = l.innerHTML);
|
|
1297
|
-
const a = ((s = this.firstChild) === null || s === void 0 ? void 0 : s.getRootNode()).host, h = a?.nodeName || "unknown", u = d, b = [
|
|
1298
|
-
`HydrationView was unable to successfully target bindings inside "<${h.toLowerCase()}>".`,
|
|
1299
|
-
`
|
|
1300
|
-
Mismatch Details:`,
|
|
1301
|
-
` - Expected target node ID: "${d.targetNodeId}"`,
|
|
1302
|
-
` - Available target IDs: [${Object.keys(this.targets).join(", ") || "none"}]`
|
|
1303
|
-
];
|
|
1304
|
-
throw d.targetTagName && b.push(` - Expected tag name: "${d.targetTagName}"`), u.sourceAspect && b.push(` - Source aspect: "${u.sourceAspect}"`), u.aspectType !== void 0 && b.push(` - Aspect type: ${u.aspectType}`), b.push(`
|
|
1305
|
-
This usually means:`, " 1. The server-rendered HTML doesn't match the client template", " 2. The hydration markers are missing or corrupted", " 3. The DOM structure was modified before hydration", `
|
|
1306
|
-
Template: ${l.slice(0, 200)}${l.length > 200 ? "..." : ""}`), new Ne(b.join(`
|
|
1307
|
-
`), d, Zt(this.firstChild, this.lastChild).cloneContents(), l);
|
|
1308
|
-
}
|
|
1309
|
-
}
|
|
1310
|
-
} else {
|
|
1311
|
-
this.source !== null && this.evaluateUnbindables(), this.isBound = !1, this.source = t, this.context = e;
|
|
1312
|
-
for (let r = 0, o = n.length; r < o; ++r)
|
|
1313
|
-
n[r].bind(this);
|
|
1314
|
-
}
|
|
1315
|
-
this.isBound = !0, this._hydrationStage = A.hydrated;
|
|
1316
|
-
}
|
|
1317
|
-
unbind() {
|
|
1318
|
-
!this.isBound || this.source === null || (this.evaluateUnbindables(), this.source = null, this.context = this, this.isBound = !1);
|
|
1319
|
-
}
|
|
1320
|
-
/**
|
|
1321
|
-
* Removes the view and unbinds its behaviors, disposing of DOM nodes afterward.
|
|
1322
|
-
* Once a view has been disposed, it cannot be inserted or bound again.
|
|
1323
|
-
*/
|
|
1324
|
-
dispose() {
|
|
1325
|
-
at(this.firstChild, this.lastChild), this.unbind();
|
|
1326
|
-
}
|
|
1327
|
-
onUnbind(t) {
|
|
1328
|
-
this.unbindables.push(t);
|
|
1329
|
-
}
|
|
1330
|
-
evaluateUnbindables() {
|
|
1331
|
-
const t = this.unbindables;
|
|
1332
|
-
for (let e = 0, s = t.length; e < s; ++e)
|
|
1333
|
-
t[e].unbind(this);
|
|
1334
|
-
t.length = 0;
|
|
1335
|
-
}
|
|
1336
|
-
}
|
|
1337
|
-
te = z;
|
|
1338
|
-
x(Be);
|
|
1339
|
-
function xe(i) {
|
|
1340
|
-
return i.create !== void 0;
|
|
1341
|
-
}
|
|
1342
|
-
function Ae(i, t, e, s) {
|
|
1343
|
-
if (e == null && (e = ""), xe(e)) {
|
|
1344
|
-
i.textContent = "";
|
|
1345
|
-
let n = i.$fastView;
|
|
1346
|
-
if (n === void 0)
|
|
1347
|
-
if (U(s) && U(e) && s.bindingViewBoundaries[this.targetNodeId] !== void 0 && s.hydrationStage !== A.hydrated) {
|
|
1348
|
-
const r = s.bindingViewBoundaries[this.targetNodeId];
|
|
1349
|
-
n = e.hydrate(r.first, r.last);
|
|
1350
|
-
} else
|
|
1351
|
-
n = e.create();
|
|
1352
|
-
else
|
|
1353
|
-
i.$fastTemplate !== e && (n.isComposed && (n.remove(), n.unbind()), n = e.create());
|
|
1354
|
-
n.isComposed ? n.needsBindOnly && (n.needsBindOnly = !1, n.bind(s.source, s.context)) : (n.isComposed = !0, n.bind(s.source, s.context), n.insertBefore(i), i.$fastView = n, i.$fastTemplate = e);
|
|
1355
|
-
} else {
|
|
1356
|
-
const n = i.$fastView;
|
|
1357
|
-
n !== void 0 && n.isComposed && (n.isComposed = !1, n.remove(), n.needsBindOnly ? n.needsBindOnly = !1 : n.unbind()), i.textContent = e;
|
|
1358
|
-
}
|
|
1359
|
-
}
|
|
1360
|
-
function Me(i, t, e) {
|
|
1361
|
-
var s;
|
|
1362
|
-
const n = `${this.id}-t`, r = (s = i[n]) !== null && s !== void 0 ? s : i[n] = { v: 0, cv: /* @__PURE__ */ Object.create(null) }, o = r.cv;
|
|
1363
|
-
let c = r.v;
|
|
1364
|
-
const d = i[t];
|
|
1365
|
-
if (e != null && e.length) {
|
|
1366
|
-
const l = e.split(/\s+/);
|
|
1367
|
-
for (let a = 0, h = l.length; a < h; ++a) {
|
|
1368
|
-
const u = l[a];
|
|
1369
|
-
u !== "" && (o[u] = c, d.add(u));
|
|
1370
|
-
}
|
|
1371
|
-
}
|
|
1372
|
-
if (r.v = c + 1, c !== 0) {
|
|
1373
|
-
c -= 1;
|
|
1374
|
-
for (const l in o)
|
|
1375
|
-
o[l] === c && d.remove(l);
|
|
1376
|
-
}
|
|
1377
|
-
}
|
|
1378
|
-
const Oe = {
|
|
1379
|
-
[y.attribute]: T.setAttribute,
|
|
1380
|
-
[y.booleanAttribute]: T.setBooleanAttribute,
|
|
1381
|
-
[y.property]: (i, t, e) => i[t] = e,
|
|
1382
|
-
[y.content]: Ae,
|
|
1383
|
-
[y.tokenList]: Me,
|
|
1384
|
-
[y.event]: () => {
|
|
1385
|
-
}
|
|
404
|
+
function se(e, t, n = y.isVolatileBinding(e)) {
|
|
405
|
+
return new oe(e, t, n);
|
|
406
|
+
}
|
|
407
|
+
//#endregion
|
|
408
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/binding/one-time.js
|
|
409
|
+
var ce = class extends x {
|
|
410
|
+
createObserver() {
|
|
411
|
+
return this;
|
|
412
|
+
}
|
|
413
|
+
bind(e) {
|
|
414
|
+
return this.evaluate(e.source, e.context);
|
|
415
|
+
}
|
|
1386
416
|
};
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
break;
|
|
1426
|
-
case y.content:
|
|
1427
|
-
t.onUnbind(this);
|
|
1428
|
-
default:
|
|
1429
|
-
const r = (e = s[this.data]) !== null && e !== void 0 ? e : s[this.data] = this.dataBinding.createObserver(this, this);
|
|
1430
|
-
if (r.target = s, r.controller = t, n && (this.aspectType === y.attribute || this.aspectType === y.booleanAttribute)) {
|
|
1431
|
-
r.bind(t);
|
|
1432
|
-
break;
|
|
1433
|
-
}
|
|
1434
|
-
this.updateTarget(s, this.targetAspect, r.bind(t), t);
|
|
1435
|
-
break;
|
|
1436
|
-
}
|
|
1437
|
-
}
|
|
1438
|
-
/** @internal */
|
|
1439
|
-
unbind(t) {
|
|
1440
|
-
const s = t.targets[this.targetNodeId].$fastView;
|
|
1441
|
-
s !== void 0 && s.isComposed && (s.unbind(), s.needsBindOnly = !0);
|
|
1442
|
-
}
|
|
1443
|
-
/** @internal */
|
|
1444
|
-
handleEvent(t) {
|
|
1445
|
-
const e = t.currentTarget[this.data];
|
|
1446
|
-
if (e.isBound) {
|
|
1447
|
-
O.setEvent(t);
|
|
1448
|
-
const s = this.dataBinding.evaluate(e.source, e.context);
|
|
1449
|
-
O.setEvent(null), s !== !0 && t.preventDefault();
|
|
1450
|
-
}
|
|
1451
|
-
}
|
|
1452
|
-
/** @internal */
|
|
1453
|
-
handleChange(t, e) {
|
|
1454
|
-
const s = e.target, n = e.controller;
|
|
1455
|
-
this.updateTarget(s, this.targetAspect, e.bind(n), n);
|
|
1456
|
-
}
|
|
1457
|
-
}
|
|
1458
|
-
$.define(M, { aspected: !0 });
|
|
1459
|
-
const ie = (i, t) => `${i}.${t}`, Bt = {}, C = {
|
|
1460
|
-
index: 0,
|
|
1461
|
-
node: null
|
|
417
|
+
d(ce);
|
|
418
|
+
function le(e, t) {
|
|
419
|
+
return new ce(e, t);
|
|
420
|
+
}
|
|
421
|
+
//#endregion
|
|
422
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/styles/element-styles.js
|
|
423
|
+
var ue;
|
|
424
|
+
function de(e) {
|
|
425
|
+
return e.map((e) => e instanceof S ? de(e.styles) : [e]).reduce((e, t) => e.concat(t), []);
|
|
426
|
+
}
|
|
427
|
+
var S = class e {
|
|
428
|
+
constructor(t) {
|
|
429
|
+
this.styles = t, this.targets = /* @__PURE__ */ new WeakSet(), this._strategy = null, this.behaviors = t.map((t) => t instanceof e ? t.behaviors : null).reduce((e, t) => t === null ? e : e === null ? t : e.concat(t), null);
|
|
430
|
+
}
|
|
431
|
+
get strategy() {
|
|
432
|
+
return this._strategy === null && this.withStrategy(ue), this._strategy;
|
|
433
|
+
}
|
|
434
|
+
addStylesTo(e) {
|
|
435
|
+
this.strategy.addStylesTo(e), this.targets.add(e);
|
|
436
|
+
}
|
|
437
|
+
removeStylesFrom(e) {
|
|
438
|
+
this.strategy.removeStylesFrom(e), this.targets.delete(e);
|
|
439
|
+
}
|
|
440
|
+
isAttachedTo(e) {
|
|
441
|
+
return this.targets.has(e);
|
|
442
|
+
}
|
|
443
|
+
withBehaviors(...e) {
|
|
444
|
+
return this.behaviors = this.behaviors === null ? e : this.behaviors.concat(e), this;
|
|
445
|
+
}
|
|
446
|
+
withStrategy(e) {
|
|
447
|
+
return this._strategy = new e(de(this.styles)), this;
|
|
448
|
+
}
|
|
449
|
+
static setDefaultStrategy(e) {
|
|
450
|
+
ue = e;
|
|
451
|
+
}
|
|
452
|
+
static normalize(t) {
|
|
453
|
+
return t === void 0 ? void 0 : Array.isArray(t) ? new e(t) : t instanceof e ? t : new e([t]);
|
|
454
|
+
}
|
|
1462
455
|
};
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
456
|
+
S.supportsAdoptedStyleSheets = Array.isArray(document.adoptedStyleSheets) && "replace" in CSSStyleSheet.prototype;
|
|
457
|
+
//#endregion
|
|
458
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/components/hydration.js
|
|
459
|
+
var fe = /fe-b\$\$start\$\$(\d+)\$\$(.+)\$\$fe-b/, pe = /fe-b\$\$end\$\$(\d+)\$\$(.+)\$\$fe-b/, me = /fe-repeat\$\$start\$\$(\d+)\$\$fe-repeat/, he = /fe-repeat\$\$end\$\$(\d+)\$\$fe-repeat/, ge = /^(?:.{0,1000})fe-eb\$\$start\$\$(.+?)\$\$fe-eb/, _e = /fe-eb\$\$end\$\$(.{0,1000})\$\$fe-eb(?:.{0,1000})$/;
|
|
460
|
+
function ve(e) {
|
|
461
|
+
return e && e.nodeType === Node.COMMENT_NODE;
|
|
462
|
+
}
|
|
463
|
+
var C = Object.freeze({
|
|
464
|
+
attributeMarkerName: "data-fe-b",
|
|
465
|
+
attributeBindingSeparator: " ",
|
|
466
|
+
contentBindingStartMarker(e, t) {
|
|
467
|
+
return `fe-b$$start$$${e}$$${t}$$fe-b`;
|
|
468
|
+
},
|
|
469
|
+
contentBindingEndMarker(e, t) {
|
|
470
|
+
return `fe-b$$end$$${e}$$${t}$$fe-b`;
|
|
471
|
+
},
|
|
472
|
+
repeatStartMarker(e) {
|
|
473
|
+
return `fe-repeat$$start$$${e}$$fe-repeat`;
|
|
474
|
+
},
|
|
475
|
+
repeatEndMarker(e) {
|
|
476
|
+
return `fe-repeat$$end$$${e}$$fe-repeat`;
|
|
477
|
+
},
|
|
478
|
+
isContentBindingStartMarker(e) {
|
|
479
|
+
return fe.test(e);
|
|
480
|
+
},
|
|
481
|
+
isContentBindingEndMarker(e) {
|
|
482
|
+
return pe.test(e);
|
|
483
|
+
},
|
|
484
|
+
isRepeatViewStartMarker(e) {
|
|
485
|
+
return me.test(e);
|
|
486
|
+
},
|
|
487
|
+
isRepeatViewEndMarker(e) {
|
|
488
|
+
return he.test(e);
|
|
489
|
+
},
|
|
490
|
+
isElementBoundaryStartMarker(e) {
|
|
491
|
+
return ve(e) && ge.test(e.data.trim());
|
|
492
|
+
},
|
|
493
|
+
isElementBoundaryEndMarker(e) {
|
|
494
|
+
return ve(e) && _e.test(e.data);
|
|
495
|
+
},
|
|
496
|
+
parseAttributeBinding(e) {
|
|
497
|
+
let t = e.getAttribute(this.attributeMarkerName);
|
|
498
|
+
return t === null ? t : t.split(this.attributeBindingSeparator).map((e) => parseInt(e));
|
|
499
|
+
},
|
|
500
|
+
parseEnumeratedAttributeBinding(e) {
|
|
501
|
+
let t = [], n = this.attributeMarkerName.length + 1, r = `${this.attributeMarkerName}-`;
|
|
502
|
+
for (let i of e.getAttributeNames()) if (i.startsWith(r)) {
|
|
503
|
+
let e = Number(i.slice(n));
|
|
504
|
+
if (!Number.isNaN(e)) t.push(e);
|
|
505
|
+
else throw Error(`Invalid attribute marker name: ${i}. Expected format is ${r}<number>.`);
|
|
506
|
+
}
|
|
507
|
+
return t.length === 0 ? null : t;
|
|
508
|
+
},
|
|
509
|
+
parseContentBindingStartMarker(e) {
|
|
510
|
+
return xe(fe, e);
|
|
511
|
+
},
|
|
512
|
+
parseContentBindingEndMarker(e) {
|
|
513
|
+
return xe(pe, e);
|
|
514
|
+
},
|
|
515
|
+
parseRepeatStartMarker(e) {
|
|
516
|
+
return ye(me, e);
|
|
517
|
+
},
|
|
518
|
+
parseRepeatEndMarker(e) {
|
|
519
|
+
return ye(he, e);
|
|
520
|
+
},
|
|
521
|
+
parseElementBoundaryStartMarker(e) {
|
|
522
|
+
return be(ge, e.trim());
|
|
523
|
+
},
|
|
524
|
+
parseElementBoundaryEndMarker(e) {
|
|
525
|
+
return be(_e, e);
|
|
526
|
+
}
|
|
1475
527
|
});
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
}
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
break;
|
|
1549
|
-
case 3:
|
|
1550
|
-
return _e(i, e, t, n, s);
|
|
1551
|
-
case 8:
|
|
1552
|
-
const r = K.parse(e.data, i.directives);
|
|
1553
|
-
r !== null && i.addFactory(
|
|
1554
|
-
/* eslint-disable-next-line @typescript-eslint/no-use-before-define */
|
|
1555
|
-
ht.aggregate(r),
|
|
1556
|
-
t,
|
|
1557
|
-
n,
|
|
1558
|
-
s,
|
|
1559
|
-
null
|
|
1560
|
-
);
|
|
1561
|
-
break;
|
|
1562
|
-
}
|
|
1563
|
-
return C.index = s + 1, C.node = e.nextSibling, C;
|
|
1564
|
-
}
|
|
1565
|
-
function je(i, t) {
|
|
1566
|
-
return i && i.nodeType == 8 && K.parse(i.data, t) !== null;
|
|
1567
|
-
}
|
|
1568
|
-
const At = "TEMPLATE", ht = {
|
|
1569
|
-
/**
|
|
1570
|
-
* Compiles a template and associated directives into a compilation
|
|
1571
|
-
* result which can be used to create views.
|
|
1572
|
-
* @param html - The html string or template element to compile.
|
|
1573
|
-
* @param factories - The behavior factories referenced by the template.
|
|
1574
|
-
* @param policy - The security policy to compile the html with.
|
|
1575
|
-
* @remarks
|
|
1576
|
-
* The template that is provided for compilation is altered in-place
|
|
1577
|
-
* and cannot be compiled again. If the original template must be preserved,
|
|
1578
|
-
* it is recommended that you clone the original and pass the clone to this API.
|
|
1579
|
-
* @public
|
|
1580
|
-
*/
|
|
1581
|
-
compile(i, t, e = T.policy) {
|
|
1582
|
-
let s;
|
|
1583
|
-
if (B(i)) {
|
|
1584
|
-
s = document.createElement(At), s.innerHTML = e.createHTML(i);
|
|
1585
|
-
const o = s.content.firstElementChild;
|
|
1586
|
-
o !== null && o.tagName === At && (s = o);
|
|
1587
|
-
} else
|
|
1588
|
-
s = i;
|
|
1589
|
-
!s.content.firstChild && !s.content.lastChild && s.content.appendChild(document.createComment(""));
|
|
1590
|
-
const n = document.adoptNode(s.content), r = new Re(n, t, e);
|
|
1591
|
-
return se(
|
|
1592
|
-
r,
|
|
1593
|
-
"",
|
|
1594
|
-
s,
|
|
1595
|
-
/* host */
|
|
1596
|
-
"h",
|
|
1597
|
-
0,
|
|
1598
|
-
!0
|
|
1599
|
-
), // If the first node in a fragment is a marker, that means it's an unstable first node,
|
|
1600
|
-
// because something like a when, repeat, etc. could add nodes before the marker.
|
|
1601
|
-
// To mitigate this, we insert a stable first node. However, if we insert a node,
|
|
1602
|
-
// that will alter the result of the TreeWalker. So, we also need to offset the target index.
|
|
1603
|
-
(je(n.firstChild, t) || // Or if there is only one node and a directive, it means the template's content
|
|
1604
|
-
// is *only* the directive. In that case, HTMLView.dispose() misses any nodes inserted by
|
|
1605
|
-
// the directive. Inserting a new node ensures proper disposal of nodes added by the directive.
|
|
1606
|
-
n.childNodes.length === 1 && Object.keys(t).length > 0) && n.insertBefore(document.createComment(""), n.firstChild), ne(
|
|
1607
|
-
r,
|
|
1608
|
-
n,
|
|
1609
|
-
/* root */
|
|
1610
|
-
"r"
|
|
1611
|
-
), C.node = null, r.freeze();
|
|
1612
|
-
},
|
|
1613
|
-
/**
|
|
1614
|
-
* Sets the default compilation strategy that will be used by the ViewTemplate whenever
|
|
1615
|
-
* it needs to compile a view preprocessed with the html template function.
|
|
1616
|
-
* @param strategy - The compilation strategy to use when compiling templates.
|
|
1617
|
-
*/
|
|
1618
|
-
setDefaultStrategy(i) {
|
|
1619
|
-
this.compile = i;
|
|
1620
|
-
},
|
|
1621
|
-
/**
|
|
1622
|
-
* Aggregates an array of strings and directives into a single directive.
|
|
1623
|
-
* @param parts - A heterogeneous array of static strings interspersed with
|
|
1624
|
-
* directives.
|
|
1625
|
-
* @param policy - The security policy to use with the aggregated bindings.
|
|
1626
|
-
* @returns A single inline directive that aggregates the behavior of all the parts.
|
|
1627
|
-
*/
|
|
1628
|
-
aggregate(i, t = T.policy) {
|
|
1629
|
-
if (i.length === 1)
|
|
1630
|
-
return i[0];
|
|
1631
|
-
let e, s = !1, n;
|
|
1632
|
-
const r = i.length, o = i.map((l) => B(l) ? () => l : (e = l.sourceAspect || e, s = s || l.dataBinding.isVolatile, n = n || l.dataBinding.policy, l.dataBinding.evaluate)), c = (l, a) => {
|
|
1633
|
-
let h = "";
|
|
1634
|
-
for (let u = 0; u < r; ++u)
|
|
1635
|
-
h += o[u](l, a);
|
|
1636
|
-
return h;
|
|
1637
|
-
}, d = new M(Wt(c, n ?? t, s));
|
|
1638
|
-
return $.assignAspect(d, e), d;
|
|
1639
|
-
}
|
|
1640
|
-
}, Le = (
|
|
1641
|
-
/* eslint-disable-next-line no-control-regex, max-len */
|
|
1642
|
-
/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/
|
|
1643
|
-
), Ve = /* @__PURE__ */ Object.create(null);
|
|
1644
|
-
class L {
|
|
1645
|
-
/**
|
|
1646
|
-
* Creates an instance of InlineTemplateDirective.
|
|
1647
|
-
* @param template - The template to inline.
|
|
1648
|
-
*/
|
|
1649
|
-
constructor(t, e = Ve) {
|
|
1650
|
-
this.html = t, this.factories = e;
|
|
1651
|
-
}
|
|
1652
|
-
/**
|
|
1653
|
-
* Creates HTML to be used within a template.
|
|
1654
|
-
* @param add - Can be used to add behavior factories to a template.
|
|
1655
|
-
*/
|
|
1656
|
-
createHTML(t) {
|
|
1657
|
-
const e = this.factories;
|
|
1658
|
-
for (const s in e)
|
|
1659
|
-
t(e[s]);
|
|
1660
|
-
return this.html;
|
|
1661
|
-
}
|
|
1662
|
-
}
|
|
1663
|
-
L.empty = new L("");
|
|
1664
|
-
$.define(L);
|
|
1665
|
-
function Fe(i, t, e, s = $.getForInstance(i)) {
|
|
1666
|
-
if (s.aspected) {
|
|
1667
|
-
const n = Le.exec(t);
|
|
1668
|
-
n !== null && $.assignAspect(i, n[2]);
|
|
1669
|
-
}
|
|
1670
|
-
return i.createHTML(e);
|
|
1671
|
-
}
|
|
1672
|
-
class Y {
|
|
1673
|
-
/**
|
|
1674
|
-
* Creates an instance of ViewTemplate.
|
|
1675
|
-
* @param html - The html representing what this template will instantiate, including placeholders for directives.
|
|
1676
|
-
* @param factories - The directives that will be connected to placeholders in the html.
|
|
1677
|
-
* @param policy - The security policy to use when compiling this template.
|
|
1678
|
-
*/
|
|
1679
|
-
constructor(t, e = {}, s) {
|
|
1680
|
-
this.policy = s, this.result = null, this.html = t, this.factories = e;
|
|
1681
|
-
}
|
|
1682
|
-
/**
|
|
1683
|
-
* @internal
|
|
1684
|
-
*/
|
|
1685
|
-
compile() {
|
|
1686
|
-
return this.result === null && (this.result = ht.compile(this.html, this.factories, this.policy)), this.result;
|
|
1687
|
-
}
|
|
1688
|
-
/**
|
|
1689
|
-
* Creates an HTMLView instance based on this template definition.
|
|
1690
|
-
* @param hostBindingTarget - The element that host behaviors will be bound to.
|
|
1691
|
-
*/
|
|
1692
|
-
create(t) {
|
|
1693
|
-
return this.compile().createView(t);
|
|
1694
|
-
}
|
|
1695
|
-
/**
|
|
1696
|
-
* Returns a directive that can inline the template.
|
|
1697
|
-
*/
|
|
1698
|
-
inline() {
|
|
1699
|
-
return new L(B(this.html) ? this.html : this.html.innerHTML, this.factories);
|
|
1700
|
-
}
|
|
1701
|
-
/**
|
|
1702
|
-
* Sets the DOMPolicy for this template.
|
|
1703
|
-
* @param policy - The policy to associated with this template.
|
|
1704
|
-
* @returns The modified template instance.
|
|
1705
|
-
* @remarks
|
|
1706
|
-
* The DOMPolicy can only be set once for a template and cannot be
|
|
1707
|
-
* set after the template is compiled.
|
|
1708
|
-
*/
|
|
1709
|
-
withPolicy(t) {
|
|
1710
|
-
if (this.result)
|
|
1711
|
-
throw v.error(
|
|
1712
|
-
1208
|
|
1713
|
-
/* Message.cannotSetTemplatePolicyAfterCompilation */
|
|
1714
|
-
);
|
|
1715
|
-
if (this.policy)
|
|
1716
|
-
throw v.error(
|
|
1717
|
-
1207
|
|
1718
|
-
/* Message.onlySetTemplatePolicyOnce */
|
|
1719
|
-
);
|
|
1720
|
-
return this.policy = t, this;
|
|
1721
|
-
}
|
|
1722
|
-
/**
|
|
1723
|
-
* Creates an HTMLView from this template, binds it to the source, and then appends it to the host.
|
|
1724
|
-
* @param source - The data source to bind the template to.
|
|
1725
|
-
* @param host - The Element where the template will be rendered.
|
|
1726
|
-
* @param hostBindingTarget - An HTML element to target the host bindings at if different from the
|
|
1727
|
-
* host that the template is being attached to.
|
|
1728
|
-
*/
|
|
1729
|
-
render(t, e, s) {
|
|
1730
|
-
const n = this.create(s);
|
|
1731
|
-
return n.bind(t), n.appendTo(e), n;
|
|
1732
|
-
}
|
|
1733
|
-
/**
|
|
1734
|
-
* Creates a template based on a set of static strings and dynamic values.
|
|
1735
|
-
* @param strings - The static strings to create the template with.
|
|
1736
|
-
* @param values - The dynamic values to create the template with.
|
|
1737
|
-
* @param policy - The DOMPolicy to associated with the template.
|
|
1738
|
-
* @returns A ViewTemplate.
|
|
1739
|
-
* @remarks
|
|
1740
|
-
* This API should not be used directly under normal circumstances because constructing
|
|
1741
|
-
* a template in this way, if not done properly, can open up the application to XSS
|
|
1742
|
-
* attacks. When using this API, provide a strong DOMPolicy that can properly sanitize
|
|
1743
|
-
* and also be sure to manually sanitize all static strings particularly if they can
|
|
1744
|
-
* come from user input.
|
|
1745
|
-
*/
|
|
1746
|
-
static create(t, e, s) {
|
|
1747
|
-
let n = "";
|
|
1748
|
-
const r = /* @__PURE__ */ Object.create(null), o = (c) => {
|
|
1749
|
-
var d;
|
|
1750
|
-
const l = (d = c.id) !== null && d !== void 0 ? d : c.id = j();
|
|
1751
|
-
return r[l] = c, l;
|
|
1752
|
-
};
|
|
1753
|
-
for (let c = 0, d = t.length - 1; c < d; ++c) {
|
|
1754
|
-
const l = t[c];
|
|
1755
|
-
let a = e[c], h;
|
|
1756
|
-
if (n += l, E(a))
|
|
1757
|
-
a = new M(Wt(a));
|
|
1758
|
-
else if (a instanceof lt)
|
|
1759
|
-
a = new M(a);
|
|
1760
|
-
else if (!(h = $.getForInstance(a))) {
|
|
1761
|
-
const u = a;
|
|
1762
|
-
a = new M(Gt(() => u));
|
|
1763
|
-
}
|
|
1764
|
-
n += Fe(a, l, o, h);
|
|
1765
|
-
}
|
|
1766
|
-
return new Y(n + t[t.length - 1], r, s);
|
|
1767
|
-
}
|
|
1768
|
-
}
|
|
1769
|
-
x(Y);
|
|
1770
|
-
const re = (i, ...t) => {
|
|
1771
|
-
if (Array.isArray(i) && Array.isArray(i.raw))
|
|
1772
|
-
return Y.create(i, t);
|
|
1773
|
-
throw v.error(
|
|
1774
|
-
1206
|
|
1775
|
-
/* Message.directCallToHTMLTagNotAllowed */
|
|
1776
|
-
);
|
|
528
|
+
function ye(e, t) {
|
|
529
|
+
let n = e.exec(t);
|
|
530
|
+
return n === null ? n : parseInt(n[1]);
|
|
531
|
+
}
|
|
532
|
+
function be(e, t) {
|
|
533
|
+
let n = e.exec(t);
|
|
534
|
+
return n === null ? n : n[1];
|
|
535
|
+
}
|
|
536
|
+
function xe(e, t) {
|
|
537
|
+
let n = e.exec(t);
|
|
538
|
+
return n === null ? n : [parseInt(n[1]), n[2]];
|
|
539
|
+
}
|
|
540
|
+
var w = Symbol.for("fe-hydration");
|
|
541
|
+
function T(e) {
|
|
542
|
+
return e[w] === w;
|
|
543
|
+
}
|
|
544
|
+
//#endregion
|
|
545
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/templating/markup.js
|
|
546
|
+
var Se = `fast-${Math.random().toString(36).substring(2, 8)}`, E = `${Se}{`, D = `}${Se}`, Ce = D.length, we = 0, O = () => `${Se}-${++we}`, Te = Object.freeze({
|
|
547
|
+
interpolation: (e) => `${E}${e}${D}`,
|
|
548
|
+
attribute: (e) => `${O()}="${E}${e}${D}"`,
|
|
549
|
+
comment: (e) => `<!--${E}${e}${D}-->`
|
|
550
|
+
}), k = Object.freeze({ parse(e, t) {
|
|
551
|
+
let n = e.split(E);
|
|
552
|
+
if (n.length === 1) return null;
|
|
553
|
+
let r = [];
|
|
554
|
+
for (let e = 0, i = n.length; e < i; ++e) {
|
|
555
|
+
let i = n[e], a = i.indexOf(D), o;
|
|
556
|
+
if (a === -1) o = i;
|
|
557
|
+
else {
|
|
558
|
+
let e = i.substring(0, a);
|
|
559
|
+
r.push(t[e]), o = i.substring(a + Ce);
|
|
560
|
+
}
|
|
561
|
+
o !== "" && r.push(o);
|
|
562
|
+
}
|
|
563
|
+
return r;
|
|
564
|
+
} }), A = l(), j = Object.freeze({
|
|
565
|
+
getForInstance: A.getForInstance,
|
|
566
|
+
getByType: A.getByType,
|
|
567
|
+
define(e, t) {
|
|
568
|
+
return t ||= {}, t.type = e, A.register(t), e;
|
|
569
|
+
},
|
|
570
|
+
assignAspect(e, t) {
|
|
571
|
+
if (!t) {
|
|
572
|
+
e.aspectType = f.content;
|
|
573
|
+
return;
|
|
574
|
+
}
|
|
575
|
+
switch (e.sourceAspect = t, t[0]) {
|
|
576
|
+
case ":":
|
|
577
|
+
e.targetAspect = t.substring(1), e.aspectType = e.targetAspect === "classList" ? f.tokenList : f.property;
|
|
578
|
+
break;
|
|
579
|
+
case "?":
|
|
580
|
+
e.targetAspect = t.substring(1), e.aspectType = f.booleanAttribute;
|
|
581
|
+
break;
|
|
582
|
+
case "@":
|
|
583
|
+
e.targetAspect = t.substring(1), e.aspectType = f.event;
|
|
584
|
+
break;
|
|
585
|
+
default:
|
|
586
|
+
e.targetAspect = t, e.aspectType = f.attribute;
|
|
587
|
+
break;
|
|
588
|
+
}
|
|
589
|
+
}
|
|
590
|
+
}), Ee = class {
|
|
591
|
+
constructor(e) {
|
|
592
|
+
this.options = e;
|
|
593
|
+
}
|
|
594
|
+
createHTML(e) {
|
|
595
|
+
return Te.attribute(e(this));
|
|
596
|
+
}
|
|
597
|
+
createBehavior() {
|
|
598
|
+
return this;
|
|
599
|
+
}
|
|
1777
600
|
};
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
}
|
|
1785
|
-
toView(i) {
|
|
1786
|
-
return i ? "true" : "false";
|
|
1787
|
-
},
|
|
1788
|
-
fromView(i) {
|
|
1789
|
-
return !(i == null || i === "false" || i === !1 || i === 0);
|
|
1790
|
-
}
|
|
601
|
+
d(Ee);
|
|
602
|
+
//#endregion
|
|
603
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/hydration/target-builder.js
|
|
604
|
+
var De = class extends Error {
|
|
605
|
+
constructor(e, t, n) {
|
|
606
|
+
super(e), this.factories = t, this.node = n;
|
|
607
|
+
}
|
|
1791
608
|
};
|
|
1792
|
-
function
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
}
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
609
|
+
function M(e) {
|
|
610
|
+
return e.nodeType === Node.COMMENT_NODE;
|
|
611
|
+
}
|
|
612
|
+
function Oe(e) {
|
|
613
|
+
return e.nodeType === Node.TEXT_NODE;
|
|
614
|
+
}
|
|
615
|
+
function ke(e, t) {
|
|
616
|
+
let n = document.createRange();
|
|
617
|
+
return n.setStart(e, 0), n.setEnd(t, M(t) || Oe(t) ? t.data.length : t.childNodes.length), n;
|
|
618
|
+
}
|
|
619
|
+
function Ae(e) {
|
|
620
|
+
return e instanceof DocumentFragment && "mode" in e;
|
|
621
|
+
}
|
|
622
|
+
function je(e, t, n) {
|
|
623
|
+
let r = ke(e, t), i = r.commonAncestorContainer, a = document.createTreeWalker(i, NodeFilter.SHOW_ELEMENT + NodeFilter.SHOW_COMMENT + NodeFilter.SHOW_TEXT, { acceptNode(e) {
|
|
624
|
+
return r.comparePoint(e, 0) === 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_REJECT;
|
|
625
|
+
} }), o = {}, s = {}, c = a.currentNode = e;
|
|
626
|
+
for (; c !== null;) {
|
|
627
|
+
switch (c.nodeType) {
|
|
628
|
+
case Node.ELEMENT_NODE:
|
|
629
|
+
Me(c, n, o);
|
|
630
|
+
break;
|
|
631
|
+
case Node.COMMENT_NODE:
|
|
632
|
+
Ne(c, a, n, o, s);
|
|
633
|
+
break;
|
|
634
|
+
}
|
|
635
|
+
c = a.nextNode();
|
|
636
|
+
}
|
|
637
|
+
return r.detach(), {
|
|
638
|
+
targets: o,
|
|
639
|
+
boundaries: s
|
|
640
|
+
};
|
|
641
|
+
}
|
|
642
|
+
function Me(e, t, n) {
|
|
643
|
+
let r = C.parseAttributeBinding(e) ?? C.parseEnumeratedAttributeBinding(e);
|
|
644
|
+
if (r !== null) {
|
|
645
|
+
for (let i of r) {
|
|
646
|
+
if (!t[i]) throw new De(`HydrationView was unable to successfully target factory on ${e.nodeName} inside ${e.getRootNode().host.nodeName}. This likely indicates a template mismatch between SSR rendering and hydration.`, t, e);
|
|
647
|
+
N(t[i], e, n);
|
|
648
|
+
}
|
|
649
|
+
e.removeAttribute(C.attributeMarkerName);
|
|
650
|
+
}
|
|
651
|
+
}
|
|
652
|
+
function Ne(e, t, n, r, i) {
|
|
653
|
+
if (C.isElementBoundaryStartMarker(e)) {
|
|
654
|
+
Pe(e, t);
|
|
655
|
+
return;
|
|
656
|
+
}
|
|
657
|
+
if (C.isContentBindingStartMarker(e.data)) {
|
|
658
|
+
let a = C.parseContentBindingStartMarker(e.data);
|
|
659
|
+
if (a === null) return;
|
|
660
|
+
let [o, s] = a, c = n[o], l = [], u = t.nextSibling();
|
|
661
|
+
e.data = "";
|
|
662
|
+
let d = u;
|
|
663
|
+
for (; u !== null;) {
|
|
664
|
+
if (M(u)) {
|
|
665
|
+
let e = C.parseContentBindingEndMarker(u.data);
|
|
666
|
+
if (e && e[1] === s) break;
|
|
667
|
+
}
|
|
668
|
+
l.push(u), u = t.nextSibling();
|
|
669
|
+
}
|
|
670
|
+
if (u === null) {
|
|
671
|
+
let t = e.getRootNode();
|
|
672
|
+
throw Error(`Error hydrating Comment node inside "${Ae(t) ? t.host.nodeName : t.nodeName}".`);
|
|
673
|
+
}
|
|
674
|
+
u.data = "", l.length === 1 && Oe(l[0]) ? N(c, l[0], r) : (u !== d && u.previousSibling !== null && (i[c.targetNodeId] = {
|
|
675
|
+
first: d,
|
|
676
|
+
last: u.previousSibling
|
|
677
|
+
}), N(c, u.parentNode.insertBefore(document.createTextNode(""), u), r));
|
|
678
|
+
}
|
|
679
|
+
}
|
|
680
|
+
function Pe(e, t) {
|
|
681
|
+
let n = C.parseElementBoundaryStartMarker(e.data), r = t.nextSibling();
|
|
682
|
+
for (; r !== null;) {
|
|
683
|
+
if (M(r)) {
|
|
684
|
+
let e = C.parseElementBoundaryEndMarker(r.data);
|
|
685
|
+
if (e && e === n) break;
|
|
686
|
+
}
|
|
687
|
+
r = t.nextSibling();
|
|
688
|
+
}
|
|
689
|
+
}
|
|
690
|
+
function N(e, t, n) {
|
|
691
|
+
if (e.targetNodeId === void 0) throw Error("Factory could not be target to the node");
|
|
692
|
+
n[e.targetNodeId] = t;
|
|
693
|
+
}
|
|
694
|
+
//#endregion
|
|
695
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/templating/view.js
|
|
696
|
+
var Fe;
|
|
697
|
+
function P(e, t) {
|
|
698
|
+
let n = e.parentNode, r = e, i;
|
|
699
|
+
for (; r !== t;) {
|
|
700
|
+
if (i = r.nextSibling, !i) throw Error(`Unmatched first/last child inside "${t.getRootNode().host.nodeName}".`);
|
|
701
|
+
n.removeChild(r), r = i;
|
|
702
|
+
}
|
|
703
|
+
n.removeChild(t);
|
|
704
|
+
}
|
|
705
|
+
var Ie = class {
|
|
706
|
+
constructor() {
|
|
707
|
+
this.index = 0, this.length = 0;
|
|
708
|
+
}
|
|
709
|
+
get event() {
|
|
710
|
+
return b.getEvent();
|
|
711
|
+
}
|
|
712
|
+
get isEven() {
|
|
713
|
+
return this.index % 2 == 0;
|
|
714
|
+
}
|
|
715
|
+
get isOdd() {
|
|
716
|
+
return this.index % 2 != 0;
|
|
717
|
+
}
|
|
718
|
+
get isFirst() {
|
|
719
|
+
return this.index === 0;
|
|
720
|
+
}
|
|
721
|
+
get isInMiddle() {
|
|
722
|
+
return !this.isFirst && !this.isLast;
|
|
723
|
+
}
|
|
724
|
+
get isLast() {
|
|
725
|
+
return this.index === this.length - 1;
|
|
726
|
+
}
|
|
727
|
+
eventDetail() {
|
|
728
|
+
return this.event.detail;
|
|
729
|
+
}
|
|
730
|
+
eventTarget() {
|
|
731
|
+
return this.event.target;
|
|
732
|
+
}
|
|
733
|
+
}, F = class extends Ie {
|
|
734
|
+
constructor(e, t, n) {
|
|
735
|
+
super(), this.fragment = e, this.factories = t, this.targets = n, this.behaviors = null, this.unbindables = [], this.source = null, this.isBound = !1, this.sourceLifetime = v.unknown, this.context = this, this.firstChild = e.firstChild, this.lastChild = e.lastChild;
|
|
736
|
+
}
|
|
737
|
+
appendTo(e) {
|
|
738
|
+
e.appendChild(this.fragment);
|
|
739
|
+
}
|
|
740
|
+
insertBefore(e) {
|
|
741
|
+
if (this.fragment.hasChildNodes()) e.parentNode.insertBefore(this.fragment, e);
|
|
742
|
+
else {
|
|
743
|
+
let t = this.lastChild;
|
|
744
|
+
if (e.previousSibling === t) return;
|
|
745
|
+
let n = e.parentNode, r = this.firstChild, i;
|
|
746
|
+
for (; r !== t;) i = r.nextSibling, n.insertBefore(r, e), r = i;
|
|
747
|
+
n.insertBefore(t, e);
|
|
748
|
+
}
|
|
749
|
+
}
|
|
750
|
+
remove() {
|
|
751
|
+
let e = this.fragment, t = this.lastChild, n = this.firstChild, r;
|
|
752
|
+
for (; n !== t;) r = n.nextSibling, e.appendChild(n), n = r;
|
|
753
|
+
e.appendChild(t);
|
|
754
|
+
}
|
|
755
|
+
dispose() {
|
|
756
|
+
P(this.firstChild, this.lastChild), this.unbind();
|
|
757
|
+
}
|
|
758
|
+
onUnbind(e) {
|
|
759
|
+
this.unbindables.push(e);
|
|
760
|
+
}
|
|
761
|
+
bind(e, t = this) {
|
|
762
|
+
if (this.source === e) return;
|
|
763
|
+
let n = this.behaviors;
|
|
764
|
+
if (n === null) {
|
|
765
|
+
this.source = e, this.context = t, this.behaviors = n = Array(this.factories.length);
|
|
766
|
+
let r = this.factories;
|
|
767
|
+
for (let e = 0, t = r.length; e < t; ++e) {
|
|
768
|
+
let t = r[e].createBehavior();
|
|
769
|
+
t.bind(this), n[e] = t;
|
|
770
|
+
}
|
|
771
|
+
} else {
|
|
772
|
+
this.source !== null && this.evaluateUnbindables(), this.isBound = !1, this.source = e, this.context = t;
|
|
773
|
+
for (let e = 0, t = n.length; e < t; ++e) n[e].bind(this);
|
|
774
|
+
}
|
|
775
|
+
this.isBound = !0;
|
|
776
|
+
}
|
|
777
|
+
unbind() {
|
|
778
|
+
!this.isBound || this.source === null || (this.evaluateUnbindables(), this.source = null, this.context = this, this.isBound = !1);
|
|
779
|
+
}
|
|
780
|
+
evaluateUnbindables() {
|
|
781
|
+
let e = this.unbindables;
|
|
782
|
+
for (let t = 0, n = e.length; t < n; ++t) e[t].unbind(this);
|
|
783
|
+
e.length = 0;
|
|
784
|
+
}
|
|
785
|
+
static disposeContiguousBatch(e) {
|
|
786
|
+
if (e.length !== 0) {
|
|
787
|
+
P(e[0].firstChild, e[e.length - 1].lastChild);
|
|
788
|
+
for (let t = 0, n = e.length; t < n; ++t) e[t].unbind();
|
|
789
|
+
}
|
|
790
|
+
}
|
|
1804
791
|
};
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
}
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
}
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
}
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
l(s.throw(a));
|
|
1903
|
-
} catch (h) {
|
|
1904
|
-
o(h);
|
|
1905
|
-
}
|
|
1906
|
-
}
|
|
1907
|
-
function l(a) {
|
|
1908
|
-
a.done ? r(a.value) : n(a.value).then(c, d);
|
|
1909
|
-
}
|
|
1910
|
-
l((s = s.apply(i, t || [])).next());
|
|
1911
|
-
});
|
|
792
|
+
d(F), y.defineProperty(F.prototype, "index"), y.defineProperty(F.prototype, "length");
|
|
793
|
+
var I = {
|
|
794
|
+
unhydrated: "unhydrated",
|
|
795
|
+
hydrating: "hydrating",
|
|
796
|
+
hydrated: "hydrated"
|
|
797
|
+
}, Le = class extends Error {
|
|
798
|
+
constructor(e, t, n, r) {
|
|
799
|
+
super(e), this.factory = t, this.fragment = n, this.templateString = r;
|
|
800
|
+
}
|
|
801
|
+
}, Re = class extends Ie {
|
|
802
|
+
constructor(e, t, n, r) {
|
|
803
|
+
super(), this.firstChild = e, this.lastChild = t, this.sourceTemplate = n, this.hostBindingTarget = r, this[Fe] = w, this.context = this, this.source = null, this.isBound = !1, this.sourceLifetime = v.unknown, this.unbindables = [], this.fragment = null, this.behaviors = null, this._hydrationStage = I.unhydrated, this._bindingViewBoundaries = {}, this._targets = {}, this.factories = n.compile().factories;
|
|
804
|
+
}
|
|
805
|
+
get hydrationStage() {
|
|
806
|
+
return this._hydrationStage;
|
|
807
|
+
}
|
|
808
|
+
get targets() {
|
|
809
|
+
return this._targets;
|
|
810
|
+
}
|
|
811
|
+
get bindingViewBoundaries() {
|
|
812
|
+
return this._bindingViewBoundaries;
|
|
813
|
+
}
|
|
814
|
+
insertBefore(e) {
|
|
815
|
+
if (this.fragment !== null) if (this.fragment.hasChildNodes()) e.parentNode.insertBefore(this.fragment, e);
|
|
816
|
+
else {
|
|
817
|
+
let t = this.lastChild;
|
|
818
|
+
if (e.previousSibling === t) return;
|
|
819
|
+
let n = e.parentNode, r = this.firstChild, i;
|
|
820
|
+
for (; r !== t;) i = r.nextSibling, n.insertBefore(r, e), r = i;
|
|
821
|
+
n.insertBefore(t, e);
|
|
822
|
+
}
|
|
823
|
+
}
|
|
824
|
+
appendTo(e) {
|
|
825
|
+
this.fragment !== null && e.appendChild(this.fragment);
|
|
826
|
+
}
|
|
827
|
+
remove() {
|
|
828
|
+
let e = this.fragment ||= document.createDocumentFragment(), t = this.lastChild, n = this.firstChild, r;
|
|
829
|
+
for (; n !== t;) {
|
|
830
|
+
if (r = n.nextSibling, !r) throw Error(`Unmatched first/last child inside "${t.getRootNode().host.nodeName}".`);
|
|
831
|
+
e.appendChild(n), n = r;
|
|
832
|
+
}
|
|
833
|
+
e.appendChild(t);
|
|
834
|
+
}
|
|
835
|
+
bind(e, t = this) {
|
|
836
|
+
if (this.hydrationStage !== I.hydrated && (this._hydrationStage = I.hydrating), this.source === e) return;
|
|
837
|
+
let n = this.behaviors;
|
|
838
|
+
if (n === null) {
|
|
839
|
+
this.source = e, this.context = t;
|
|
840
|
+
try {
|
|
841
|
+
let { targets: e, boundaries: t } = je(this.firstChild, this.lastChild, this.factories);
|
|
842
|
+
this._targets = e, this._bindingViewBoundaries = t;
|
|
843
|
+
} catch (e) {
|
|
844
|
+
if (e instanceof De) {
|
|
845
|
+
let t = this.sourceTemplate.html;
|
|
846
|
+
typeof t != "string" && (t = t.innerHTML), e.templateString = t;
|
|
847
|
+
}
|
|
848
|
+
throw e;
|
|
849
|
+
}
|
|
850
|
+
this.behaviors = n = Array(this.factories.length);
|
|
851
|
+
let r = this.factories;
|
|
852
|
+
for (let e = 0, t = r.length; e < t; ++e) {
|
|
853
|
+
let t = r[e];
|
|
854
|
+
if (t.targetNodeId === "h" && this.hostBindingTarget && N(t, this.hostBindingTarget, this._targets), t.targetNodeId in this.targets) {
|
|
855
|
+
let r = t.createBehavior();
|
|
856
|
+
r.bind(this), n[e] = r;
|
|
857
|
+
} else {
|
|
858
|
+
let e = this.sourceTemplate.html;
|
|
859
|
+
typeof e != "string" && (e = e.innerHTML);
|
|
860
|
+
let n = (this.firstChild?.getRootNode()).host?.nodeName || "unknown", r = t, i = [
|
|
861
|
+
`HydrationView was unable to successfully target bindings inside "<${n.toLowerCase()}>".`,
|
|
862
|
+
"\nMismatch Details:",
|
|
863
|
+
` - Expected target node ID: "${t.targetNodeId}"`,
|
|
864
|
+
` - Available target IDs: [${Object.keys(this.targets).join(", ") || "none"}]`
|
|
865
|
+
];
|
|
866
|
+
throw t.targetTagName && i.push(` - Expected tag name: "${t.targetTagName}"`), r.sourceAspect && i.push(` - Source aspect: "${r.sourceAspect}"`), r.aspectType !== void 0 && i.push(` - Aspect type: ${r.aspectType}`), i.push("\nThis usually means:", " 1. The server-rendered HTML doesn't match the client template", " 2. The hydration markers are missing or corrupted", " 3. The DOM structure was modified before hydration", `\nTemplate: ${e.slice(0, 200)}${e.length > 200 ? "..." : ""}`), new Le(i.join("\n"), t, ke(this.firstChild, this.lastChild).cloneContents(), e);
|
|
867
|
+
}
|
|
868
|
+
}
|
|
869
|
+
} else {
|
|
870
|
+
this.source !== null && this.evaluateUnbindables(), this.isBound = !1, this.source = e, this.context = t;
|
|
871
|
+
for (let e = 0, t = n.length; e < t; ++e) n[e].bind(this);
|
|
872
|
+
}
|
|
873
|
+
this.isBound = !0, this._hydrationStage = I.hydrated;
|
|
874
|
+
}
|
|
875
|
+
unbind() {
|
|
876
|
+
!this.isBound || this.source === null || (this.evaluateUnbindables(), this.source = null, this.context = this, this.isBound = !1);
|
|
877
|
+
}
|
|
878
|
+
dispose() {
|
|
879
|
+
P(this.firstChild, this.lastChild), this.unbind();
|
|
880
|
+
}
|
|
881
|
+
onUnbind(e) {
|
|
882
|
+
this.unbindables.push(e);
|
|
883
|
+
}
|
|
884
|
+
evaluateUnbindables() {
|
|
885
|
+
let e = this.unbindables;
|
|
886
|
+
for (let t = 0, n = e.length; t < n; ++t) e[t].unbind(this);
|
|
887
|
+
e.length = 0;
|
|
888
|
+
}
|
|
1912
889
|
};
|
|
1913
|
-
|
|
1914
|
-
|
|
890
|
+
Fe = w, d(Re);
|
|
891
|
+
//#endregion
|
|
892
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/templating/html-binding-directive.js
|
|
893
|
+
function ze(e) {
|
|
894
|
+
return e.create !== void 0;
|
|
895
|
+
}
|
|
896
|
+
function Be(e, t, n, r) {
|
|
897
|
+
if (n ??= "", ze(n)) {
|
|
898
|
+
e.textContent = "";
|
|
899
|
+
let t = e.$fastView;
|
|
900
|
+
if (t === void 0) if (T(r) && T(n) && r.bindingViewBoundaries[this.targetNodeId] !== void 0 && r.hydrationStage !== I.hydrated) {
|
|
901
|
+
let e = r.bindingViewBoundaries[this.targetNodeId];
|
|
902
|
+
t = n.hydrate(e.first, e.last);
|
|
903
|
+
} else t = n.create();
|
|
904
|
+
else e.$fastTemplate !== n && (t.isComposed && (t.remove(), t.unbind()), t = n.create());
|
|
905
|
+
t.isComposed ? t.needsBindOnly && (t.needsBindOnly = !1, t.bind(r.source, r.context)) : (t.isComposed = !0, t.bind(r.source, r.context), t.insertBefore(e), e.$fastView = t, e.$fastTemplate = n);
|
|
906
|
+
} else {
|
|
907
|
+
let t = e.$fastView;
|
|
908
|
+
t !== void 0 && t.isComposed && (t.isComposed = !1, t.remove(), t.needsBindOnly ? t.needsBindOnly = !1 : t.unbind()), e.textContent = n;
|
|
909
|
+
}
|
|
910
|
+
}
|
|
911
|
+
function Ve(e, t, n) {
|
|
912
|
+
let r = `${this.id}-t`, i = e[r] ?? (e[r] = {
|
|
913
|
+
v: 0,
|
|
914
|
+
cv: Object.create(null)
|
|
915
|
+
}), a = i.cv, o = i.v, s = e[t];
|
|
916
|
+
if (n != null && n.length) {
|
|
917
|
+
let e = n.split(/\s+/);
|
|
918
|
+
for (let t = 0, n = e.length; t < n; ++t) {
|
|
919
|
+
let n = e[t];
|
|
920
|
+
n !== "" && (a[n] = o, s.add(n));
|
|
921
|
+
}
|
|
922
|
+
}
|
|
923
|
+
if (i.v = o + 1, o !== 0) {
|
|
924
|
+
--o;
|
|
925
|
+
for (let e in a) a[e] === o && s.remove(e);
|
|
926
|
+
}
|
|
927
|
+
}
|
|
928
|
+
var He = {
|
|
929
|
+
[f.attribute]: h.setAttribute,
|
|
930
|
+
[f.booleanAttribute]: h.setBooleanAttribute,
|
|
931
|
+
[f.property]: (e, t, n) => e[t] = n,
|
|
932
|
+
[f.content]: Be,
|
|
933
|
+
[f.tokenList]: Ve,
|
|
934
|
+
[f.event]: () => void 0
|
|
935
|
+
}, L = class {
|
|
936
|
+
constructor(e) {
|
|
937
|
+
this.dataBinding = e, this.updateTarget = null, this.aspectType = f.content;
|
|
938
|
+
}
|
|
939
|
+
createHTML(e) {
|
|
940
|
+
return Te.interpolation(e(this));
|
|
941
|
+
}
|
|
942
|
+
createBehavior() {
|
|
943
|
+
if (this.updateTarget === null) {
|
|
944
|
+
let e = He[this.aspectType], t = this.dataBinding.policy ?? this.policy;
|
|
945
|
+
if (!e) throw s.error(1205);
|
|
946
|
+
this.data = `${this.id}-d`, this.updateTarget = t.protect(this.targetTagName, this.aspectType, this.targetAspect, e);
|
|
947
|
+
}
|
|
948
|
+
return this;
|
|
949
|
+
}
|
|
950
|
+
bind(e) {
|
|
951
|
+
let t = e.targets[this.targetNodeId], n = T(e) && e.hydrationStage && e.hydrationStage !== I.hydrated;
|
|
952
|
+
switch (this.aspectType) {
|
|
953
|
+
case f.event:
|
|
954
|
+
t[this.data] = e, t.addEventListener(this.targetAspect, this, this.dataBinding.options);
|
|
955
|
+
break;
|
|
956
|
+
case f.content: e.onUnbind(this);
|
|
957
|
+
default:
|
|
958
|
+
let r = t[this.data] ?? (t[this.data] = this.dataBinding.createObserver(this, this));
|
|
959
|
+
if (r.target = t, r.controller = e, n && (this.aspectType === f.attribute || this.aspectType === f.booleanAttribute)) {
|
|
960
|
+
r.bind(e);
|
|
961
|
+
break;
|
|
962
|
+
}
|
|
963
|
+
this.updateTarget(t, this.targetAspect, r.bind(e), e);
|
|
964
|
+
break;
|
|
965
|
+
}
|
|
966
|
+
}
|
|
967
|
+
unbind(e) {
|
|
968
|
+
let t = e.targets[this.targetNodeId].$fastView;
|
|
969
|
+
t !== void 0 && t.isComposed && (t.unbind(), t.needsBindOnly = !0);
|
|
970
|
+
}
|
|
971
|
+
handleEvent(e) {
|
|
972
|
+
let t = e.currentTarget[this.data];
|
|
973
|
+
if (t.isBound) {
|
|
974
|
+
b.setEvent(e);
|
|
975
|
+
let n = this.dataBinding.evaluate(t.source, t.context);
|
|
976
|
+
b.setEvent(null), n !== !0 && e.preventDefault();
|
|
977
|
+
}
|
|
978
|
+
}
|
|
979
|
+
handleChange(e, t) {
|
|
980
|
+
let n = t.target, r = t.controller;
|
|
981
|
+
this.updateTarget(n, this.targetAspect, t.bind(r), r);
|
|
982
|
+
}
|
|
1915
983
|
};
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
const h = r[l];
|
|
1923
|
-
o[l] = h.attribute, c[h.name] = h, d[h.attribute] = h, g.defineProperty(n, h);
|
|
1924
|
-
}
|
|
1925
|
-
Reflect.defineProperty(t, "observedAttributes", {
|
|
1926
|
-
value: o,
|
|
1927
|
-
enumerable: !0
|
|
1928
|
-
}), this.attributes = r, this.propertyLookup = c, this.attributeLookup = d, this.shadowOptions = e.shadowOptions === void 0 ? Rt : e.shadowOptions === null ? void 0 : Object.assign(Object.assign({}, Rt), e.shadowOptions), this.elementOptions = e.elementOptions === void 0 ? _t : Object.assign(Object.assign({}, _t), e.elementOptions), this.styles = m.normalize(e.styles), _.register(this), g.defineProperty(p.isRegistered, this.name), p.isRegistered[this.name] = this.type;
|
|
1929
|
-
}
|
|
1930
|
-
/**
|
|
1931
|
-
* Indicates if this element has been defined in at least one registry.
|
|
1932
|
-
*/
|
|
1933
|
-
get isDefined() {
|
|
1934
|
-
return this.platformDefined;
|
|
1935
|
-
}
|
|
1936
|
-
/**
|
|
1937
|
-
* Defines a custom element based on this definition.
|
|
1938
|
-
* @param registry - The element registry to define the element in.
|
|
1939
|
-
* @remarks
|
|
1940
|
-
* This operation is idempotent per registry.
|
|
1941
|
-
*/
|
|
1942
|
-
define(t = this.registry) {
|
|
1943
|
-
var e, s;
|
|
1944
|
-
const n = this.type;
|
|
1945
|
-
return t.get(this.name) || (this.platformDefined = !0, t.define(this.name, n, this.elementOptions), (s = (e = this.lifecycleCallbacks) === null || e === void 0 ? void 0 : e.elementDidDefine) === null || s === void 0 || s.call(e, this.name)), this;
|
|
1946
|
-
}
|
|
1947
|
-
/**
|
|
1948
|
-
* Creates an instance of FASTElementDefinition.
|
|
1949
|
-
* @param type - The type this definition is being created for.
|
|
1950
|
-
* @param nameOrDef - The name of the element to define or a config object
|
|
1951
|
-
* that describes the element to define.
|
|
1952
|
-
*/
|
|
1953
|
-
static compose(t, e) {
|
|
1954
|
-
return it.has(t) || _.getByType(t) ? new p(class extends t {
|
|
1955
|
-
}, e) : new p(t, e);
|
|
1956
|
-
}
|
|
1957
|
-
/**
|
|
1958
|
-
* Registers a FASTElement base type.
|
|
1959
|
-
* @param type - The type to register as a base type.
|
|
1960
|
-
* @internal
|
|
1961
|
-
*/
|
|
1962
|
-
static registerBaseType(t) {
|
|
1963
|
-
it.add(t);
|
|
1964
|
-
}
|
|
1965
|
-
/**
|
|
1966
|
-
* Creates an instance of FASTElementDefinition asynchronously. This option assumes
|
|
1967
|
-
* that a template and shadowOptions will be provided and completes when those requirements
|
|
1968
|
-
* are met.
|
|
1969
|
-
* @param type - The type this definition is being created for.
|
|
1970
|
-
* @param nameOrDef - The name of the element to define or a config object
|
|
1971
|
-
* that describes the element to define.
|
|
1972
|
-
* @alpha
|
|
1973
|
-
*/
|
|
1974
|
-
static composeAsync(t, e) {
|
|
1975
|
-
return new Promise((s) => {
|
|
1976
|
-
(it.has(t) || _.getByType(t)) && s(new p(class extends t {
|
|
1977
|
-
}, e));
|
|
1978
|
-
const n = new p(t, e);
|
|
1979
|
-
g.getNotifier(n).subscribe({
|
|
1980
|
-
handleChange: () => {
|
|
1981
|
-
var r, o;
|
|
1982
|
-
(o = (r = n.lifecycleCallbacks) === null || r === void 0 ? void 0 : r.templateDidUpdate) === null || o === void 0 || o.call(r, n.name), s(n);
|
|
1983
|
-
}
|
|
1984
|
-
}, "template");
|
|
1985
|
-
});
|
|
1986
|
-
}
|
|
1987
|
-
}
|
|
1988
|
-
p.isRegistered = {};
|
|
1989
|
-
p.getByType = _.getByType;
|
|
1990
|
-
p.getForInstance = _.getForInstance;
|
|
1991
|
-
p.registerAsync = (i) => Pe(void 0, void 0, void 0, function* () {
|
|
1992
|
-
return new Promise((t) => {
|
|
1993
|
-
p.isRegistered[i] && t(p.isRegistered[i]), g.getNotifier(p.isRegistered).subscribe({ handleChange: () => t(p.isRegistered[i]) }, i);
|
|
1994
|
-
});
|
|
1995
|
-
});
|
|
1996
|
-
g.defineProperty(p.prototype, "template");
|
|
1997
|
-
class Ue extends MutationObserver {
|
|
1998
|
-
/**
|
|
1999
|
-
* Creates an instance of UnobservableMutationObserver.
|
|
2000
|
-
* @param callback - The callback to invoke when observed nodes are changed.
|
|
2001
|
-
*/
|
|
2002
|
-
constructor(t) {
|
|
2003
|
-
function e(s) {
|
|
2004
|
-
this.callback.call(null, s.filter((n) => this.observedNodes.has(n.target)));
|
|
2005
|
-
}
|
|
2006
|
-
super(e), this.callback = t, this.observedNodes = /* @__PURE__ */ new Set();
|
|
2007
|
-
}
|
|
2008
|
-
observe(t, e) {
|
|
2009
|
-
this.observedNodes.add(t), super.observe(t, e);
|
|
2010
|
-
}
|
|
2011
|
-
unobserve(t) {
|
|
2012
|
-
this.observedNodes.delete(t), this.observedNodes.size < 1 && this.disconnect();
|
|
2013
|
-
}
|
|
2014
|
-
}
|
|
2015
|
-
const bi = Object.freeze({
|
|
2016
|
-
/**
|
|
2017
|
-
* Creates a ViewBehaviorOrchestrator.
|
|
2018
|
-
* @param source - The source to to associate behaviors with.
|
|
2019
|
-
* @returns A ViewBehaviorOrchestrator.
|
|
2020
|
-
*/
|
|
2021
|
-
create(i) {
|
|
2022
|
-
const t = [], e = {};
|
|
2023
|
-
let s = null, n = !1;
|
|
2024
|
-
return {
|
|
2025
|
-
source: i,
|
|
2026
|
-
context: O.default,
|
|
2027
|
-
targets: e,
|
|
2028
|
-
get isBound() {
|
|
2029
|
-
return n;
|
|
2030
|
-
},
|
|
2031
|
-
addBehaviorFactory(r, o) {
|
|
2032
|
-
var c, d, l, a;
|
|
2033
|
-
const h = r;
|
|
2034
|
-
h.id = (c = h.id) !== null && c !== void 0 ? c : j(), h.targetNodeId = (d = h.targetNodeId) !== null && d !== void 0 ? d : j(), h.targetTagName = (l = o.tagName) !== null && l !== void 0 ? l : null, h.policy = (a = h.policy) !== null && a !== void 0 ? a : T.policy, this.addTarget(h.targetNodeId, o), this.addBehavior(h.createBehavior());
|
|
2035
|
-
},
|
|
2036
|
-
addTarget(r, o) {
|
|
2037
|
-
e[r] = o;
|
|
2038
|
-
},
|
|
2039
|
-
addBehavior(r) {
|
|
2040
|
-
t.push(r), n && r.bind(this);
|
|
2041
|
-
},
|
|
2042
|
-
onUnbind(r) {
|
|
2043
|
-
s === null && (s = []), s.push(r);
|
|
2044
|
-
},
|
|
2045
|
-
connectedCallback(r) {
|
|
2046
|
-
n || (n = !0, t.forEach((o) => o.bind(this)));
|
|
2047
|
-
},
|
|
2048
|
-
disconnectedCallback(r) {
|
|
2049
|
-
n && (n = !1, s !== null && s.forEach((o) => o.unbind(this)));
|
|
2050
|
-
}
|
|
2051
|
-
};
|
|
2052
|
-
}
|
|
2053
|
-
}), qe = {
|
|
2054
|
-
bubbles: !0,
|
|
2055
|
-
composed: !0,
|
|
2056
|
-
cancelable: !0
|
|
2057
|
-
}, P = "isConnected", oe = /* @__PURE__ */ new WeakMap();
|
|
2058
|
-
function I(i) {
|
|
2059
|
-
var t, e;
|
|
2060
|
-
return (e = (t = i.shadowRoot) !== null && t !== void 0 ? t : oe.get(i)) !== null && e !== void 0 ? e : null;
|
|
2061
|
-
}
|
|
2062
|
-
let It;
|
|
2063
|
-
class S extends qt {
|
|
2064
|
-
/**
|
|
2065
|
-
* Creates a Controller to control the specified element.
|
|
2066
|
-
* @param element - The element to be controlled by this controller.
|
|
2067
|
-
* @param definition - The element definition metadata that instructs this
|
|
2068
|
-
* controller in how to handle rendering and other platform integrations.
|
|
2069
|
-
* @internal
|
|
2070
|
-
*/
|
|
2071
|
-
constructor(t, e) {
|
|
2072
|
-
super(t), this.boundObservables = null, this.needsInitialization = !0, this.hasExistingShadowRoot = !1, this._template = null, this.stage = 3, this.guardBehaviorConnection = !1, this.behaviors = null, this.behaviorsConnected = !1, this._mainStyles = null, this.$fastController = this, this.view = null, this.source = t, this.definition = e, this.shadowOptions = e.shadowOptions;
|
|
2073
|
-
const s = g.getAccessors(t);
|
|
2074
|
-
if (s.length > 0) {
|
|
2075
|
-
const n = this.boundObservables = /* @__PURE__ */ Object.create(null);
|
|
2076
|
-
for (let r = 0, o = s.length; r < o; ++r) {
|
|
2077
|
-
const c = s[r].name, d = t[c];
|
|
2078
|
-
d !== void 0 && (delete t[c], n[c] = d);
|
|
2079
|
-
}
|
|
2080
|
-
}
|
|
2081
|
-
}
|
|
2082
|
-
/**
|
|
2083
|
-
* Indicates whether or not the custom element has been
|
|
2084
|
-
* connected to the document.
|
|
2085
|
-
*/
|
|
2086
|
-
get isConnected() {
|
|
2087
|
-
return g.track(this, P), this.stage === 1;
|
|
2088
|
-
}
|
|
2089
|
-
/**
|
|
2090
|
-
* The context the expression is evaluated against.
|
|
2091
|
-
*/
|
|
2092
|
-
get context() {
|
|
2093
|
-
var t, e;
|
|
2094
|
-
return (e = (t = this.view) === null || t === void 0 ? void 0 : t.context) !== null && e !== void 0 ? e : O.default;
|
|
2095
|
-
}
|
|
2096
|
-
/**
|
|
2097
|
-
* Indicates whether the controller is bound.
|
|
2098
|
-
*/
|
|
2099
|
-
get isBound() {
|
|
2100
|
-
var t, e;
|
|
2101
|
-
return (e = (t = this.view) === null || t === void 0 ? void 0 : t.isBound) !== null && e !== void 0 ? e : !1;
|
|
2102
|
-
}
|
|
2103
|
-
/**
|
|
2104
|
-
* Indicates how the source's lifetime relates to the controller's lifetime.
|
|
2105
|
-
*/
|
|
2106
|
-
get sourceLifetime() {
|
|
2107
|
-
var t;
|
|
2108
|
-
return (t = this.view) === null || t === void 0 ? void 0 : t.sourceLifetime;
|
|
2109
|
-
}
|
|
2110
|
-
/**
|
|
2111
|
-
* Gets/sets the template used to render the component.
|
|
2112
|
-
* @remarks
|
|
2113
|
-
* This value can only be accurately read after connect but can be set at any time.
|
|
2114
|
-
*/
|
|
2115
|
-
get template() {
|
|
2116
|
-
var t;
|
|
2117
|
-
if (this._template === null) {
|
|
2118
|
-
const e = this.definition;
|
|
2119
|
-
this.source.resolveTemplate ? this._template = this.source.resolveTemplate() : e.template && (this._template = (t = e.template) !== null && t !== void 0 ? t : null);
|
|
2120
|
-
}
|
|
2121
|
-
return this._template;
|
|
2122
|
-
}
|
|
2123
|
-
set template(t) {
|
|
2124
|
-
this._template !== t && (this._template = t, this.needsInitialization || this.renderTemplate(t));
|
|
2125
|
-
}
|
|
2126
|
-
/**
|
|
2127
|
-
* The shadow root options for the component.
|
|
2128
|
-
*/
|
|
2129
|
-
get shadowOptions() {
|
|
2130
|
-
return this._shadowRootOptions;
|
|
2131
|
-
}
|
|
2132
|
-
set shadowOptions(t) {
|
|
2133
|
-
if (this._shadowRootOptions === void 0 && t !== void 0) {
|
|
2134
|
-
this._shadowRootOptions = t;
|
|
2135
|
-
let e = this.source.shadowRoot;
|
|
2136
|
-
e ? this.hasExistingShadowRoot = !0 : (e = this.source.attachShadow(t), t.mode === "closed" && oe.set(this.source, e));
|
|
2137
|
-
}
|
|
2138
|
-
}
|
|
2139
|
-
/**
|
|
2140
|
-
* The main set of styles used for the component, independent
|
|
2141
|
-
* of any dynamically added styles.
|
|
2142
|
-
*/
|
|
2143
|
-
get mainStyles() {
|
|
2144
|
-
var t;
|
|
2145
|
-
if (this._mainStyles === null) {
|
|
2146
|
-
const e = this.definition;
|
|
2147
|
-
this.source.resolveStyles ? this._mainStyles = this.source.resolveStyles() : e.styles && (this._mainStyles = (t = e.styles) !== null && t !== void 0 ? t : null);
|
|
2148
|
-
}
|
|
2149
|
-
return this._mainStyles;
|
|
2150
|
-
}
|
|
2151
|
-
set mainStyles(t) {
|
|
2152
|
-
this._mainStyles !== t && (this._mainStyles !== null && this.removeStyles(this._mainStyles), this._mainStyles = t, this.needsInitialization || this.addStyles(t));
|
|
2153
|
-
}
|
|
2154
|
-
/**
|
|
2155
|
-
* Registers an unbind handler with the controller.
|
|
2156
|
-
* @param behavior - An object to call when the controller unbinds.
|
|
2157
|
-
*/
|
|
2158
|
-
onUnbind(t) {
|
|
2159
|
-
var e;
|
|
2160
|
-
(e = this.view) === null || e === void 0 || e.onUnbind(t);
|
|
2161
|
-
}
|
|
2162
|
-
/**
|
|
2163
|
-
* Adds the behavior to the component.
|
|
2164
|
-
* @param behavior - The behavior to add.
|
|
2165
|
-
*/
|
|
2166
|
-
addBehavior(t) {
|
|
2167
|
-
var e, s;
|
|
2168
|
-
const n = (e = this.behaviors) !== null && e !== void 0 ? e : this.behaviors = /* @__PURE__ */ new Map(), r = (s = n.get(t)) !== null && s !== void 0 ? s : 0;
|
|
2169
|
-
r === 0 ? (n.set(t, 1), t.addedCallback && t.addedCallback(this), t.connectedCallback && !this.guardBehaviorConnection && (this.stage === 1 || this.stage === 0) && t.connectedCallback(this)) : n.set(t, r + 1);
|
|
2170
|
-
}
|
|
2171
|
-
/**
|
|
2172
|
-
* Removes the behavior from the component.
|
|
2173
|
-
* @param behavior - The behavior to remove.
|
|
2174
|
-
* @param force - Forces removal even if this behavior was added more than once.
|
|
2175
|
-
*/
|
|
2176
|
-
removeBehavior(t, e = !1) {
|
|
2177
|
-
const s = this.behaviors;
|
|
2178
|
-
if (s === null)
|
|
2179
|
-
return;
|
|
2180
|
-
const n = s.get(t);
|
|
2181
|
-
n !== void 0 && (n === 1 || e ? (s.delete(t), t.disconnectedCallback && this.stage !== 3 && t.disconnectedCallback(this), t.removedCallback && t.removedCallback(this)) : s.set(t, n - 1));
|
|
2182
|
-
}
|
|
2183
|
-
/**
|
|
2184
|
-
* Adds styles to this element. Providing an HTMLStyleElement will attach the element instance to the shadowRoot.
|
|
2185
|
-
* @param styles - The styles to add.
|
|
2186
|
-
*/
|
|
2187
|
-
addStyles(t) {
|
|
2188
|
-
var e;
|
|
2189
|
-
if (!t)
|
|
2190
|
-
return;
|
|
2191
|
-
const s = this.source;
|
|
2192
|
-
if (t instanceof HTMLElement)
|
|
2193
|
-
((e = I(s)) !== null && e !== void 0 ? e : this.source).append(t);
|
|
2194
|
-
else if (!t.isAttachedTo(s)) {
|
|
2195
|
-
const n = t.behaviors;
|
|
2196
|
-
if (t.addStylesTo(s), n !== null)
|
|
2197
|
-
for (let r = 0, o = n.length; r < o; ++r)
|
|
2198
|
-
this.addBehavior(n[r]);
|
|
2199
|
-
}
|
|
2200
|
-
}
|
|
2201
|
-
/**
|
|
2202
|
-
* Removes styles from this element. Providing an HTMLStyleElement will detach the element instance from the shadowRoot.
|
|
2203
|
-
* @param styles - the styles to remove.
|
|
2204
|
-
*/
|
|
2205
|
-
removeStyles(t) {
|
|
2206
|
-
var e;
|
|
2207
|
-
if (!t)
|
|
2208
|
-
return;
|
|
2209
|
-
const s = this.source;
|
|
2210
|
-
if (t instanceof HTMLElement)
|
|
2211
|
-
((e = I(s)) !== null && e !== void 0 ? e : s).removeChild(t);
|
|
2212
|
-
else if (t.isAttachedTo(s)) {
|
|
2213
|
-
const n = t.behaviors;
|
|
2214
|
-
if (t.removeStylesFrom(s), n !== null)
|
|
2215
|
-
for (let r = 0, o = n.length; r < o; ++r)
|
|
2216
|
-
this.removeBehavior(n[r]);
|
|
2217
|
-
}
|
|
2218
|
-
}
|
|
2219
|
-
/**
|
|
2220
|
-
* Runs connected lifecycle behavior on the associated element.
|
|
2221
|
-
*/
|
|
2222
|
-
connect() {
|
|
2223
|
-
this.stage === 3 && (this.stage = 0, this.bindObservables(), this.connectBehaviors(), this.needsInitialization ? (this.renderTemplate(this.template), this.addStyles(this.mainStyles), this.needsInitialization = !1) : this.view !== null && this.view.bind(this.source), this.stage = 1, g.notify(this, P));
|
|
2224
|
-
}
|
|
2225
|
-
/**
|
|
2226
|
-
* Binds any observables that were set before upgrade.
|
|
2227
|
-
*/
|
|
2228
|
-
bindObservables() {
|
|
2229
|
-
if (this.boundObservables !== null) {
|
|
2230
|
-
const t = this.source, e = this.boundObservables, s = Object.keys(e);
|
|
2231
|
-
for (let n = 0, r = s.length; n < r; ++n) {
|
|
2232
|
-
const o = s[n];
|
|
2233
|
-
t[o] = e[o];
|
|
2234
|
-
}
|
|
2235
|
-
this.boundObservables = null;
|
|
2236
|
-
}
|
|
2237
|
-
}
|
|
2238
|
-
/**
|
|
2239
|
-
* Connects any existing behaviors on the associated element.
|
|
2240
|
-
*/
|
|
2241
|
-
connectBehaviors() {
|
|
2242
|
-
if (this.behaviorsConnected === !1) {
|
|
2243
|
-
const t = this.behaviors;
|
|
2244
|
-
if (t !== null) {
|
|
2245
|
-
this.guardBehaviorConnection = !0;
|
|
2246
|
-
for (const e of t.keys())
|
|
2247
|
-
e.connectedCallback && e.connectedCallback(this);
|
|
2248
|
-
this.guardBehaviorConnection = !1;
|
|
2249
|
-
}
|
|
2250
|
-
this.behaviorsConnected = !0;
|
|
2251
|
-
}
|
|
2252
|
-
}
|
|
2253
|
-
/**
|
|
2254
|
-
* Disconnects any behaviors on the associated element.
|
|
2255
|
-
*/
|
|
2256
|
-
disconnectBehaviors() {
|
|
2257
|
-
if (this.behaviorsConnected === !0) {
|
|
2258
|
-
const t = this.behaviors;
|
|
2259
|
-
if (t !== null)
|
|
2260
|
-
for (const e of t.keys())
|
|
2261
|
-
e.disconnectedCallback && e.disconnectedCallback(this);
|
|
2262
|
-
this.behaviorsConnected = !1;
|
|
2263
|
-
}
|
|
2264
|
-
}
|
|
2265
|
-
/**
|
|
2266
|
-
* Runs disconnected lifecycle behavior on the associated element.
|
|
2267
|
-
*/
|
|
2268
|
-
disconnect() {
|
|
2269
|
-
this.stage === 1 && (this.stage = 2, g.notify(this, P), this.view !== null && this.view.unbind(), this.disconnectBehaviors(), this.stage = 3);
|
|
2270
|
-
}
|
|
2271
|
-
/**
|
|
2272
|
-
* Runs the attribute changed callback for the associated element.
|
|
2273
|
-
* @param name - The name of the attribute that changed.
|
|
2274
|
-
* @param oldValue - The previous value of the attribute.
|
|
2275
|
-
* @param newValue - The new value of the attribute.
|
|
2276
|
-
*/
|
|
2277
|
-
onAttributeChangedCallback(t, e, s) {
|
|
2278
|
-
const n = this.definition.attributeLookup[t];
|
|
2279
|
-
n !== void 0 && n.onAttributeChangedCallback(this.source, s);
|
|
2280
|
-
}
|
|
2281
|
-
/**
|
|
2282
|
-
* Emits a custom HTML event.
|
|
2283
|
-
* @param type - The type name of the event.
|
|
2284
|
-
* @param detail - The event detail object to send with the event.
|
|
2285
|
-
* @param options - The event options. By default bubbles and composed.
|
|
2286
|
-
* @remarks
|
|
2287
|
-
* Only emits events if connected.
|
|
2288
|
-
*/
|
|
2289
|
-
emit(t, e, s) {
|
|
2290
|
-
return this.stage === 1 ? this.source.dispatchEvent(new CustomEvent(t, Object.assign(Object.assign({ detail: e }, qe), s))) : !1;
|
|
2291
|
-
}
|
|
2292
|
-
/**
|
|
2293
|
-
* Renders the provided template to the element.
|
|
2294
|
-
*
|
|
2295
|
-
* @param template - The template to render.
|
|
2296
|
-
* @remarks
|
|
2297
|
-
* If `null` is provided, any existing view will be removed.
|
|
2298
|
-
*/
|
|
2299
|
-
renderTemplate(t) {
|
|
2300
|
-
var e;
|
|
2301
|
-
const s = this.source, n = (e = I(s)) !== null && e !== void 0 ? e : s;
|
|
2302
|
-
if (this.view !== null)
|
|
2303
|
-
this.view.dispose(), this.view = null;
|
|
2304
|
-
else if (!this.needsInitialization || this.hasExistingShadowRoot) {
|
|
2305
|
-
this.hasExistingShadowRoot = !1;
|
|
2306
|
-
for (let r = n.firstChild; r !== null; r = n.firstChild)
|
|
2307
|
-
n.removeChild(r);
|
|
2308
|
-
}
|
|
2309
|
-
t && (this.view = t.render(s, n, s), this.view.sourceLifetime = J.coupled);
|
|
2310
|
-
}
|
|
2311
|
-
/**
|
|
2312
|
-
* Locates or creates a controller for the specified element.
|
|
2313
|
-
* @param element - The element to return the controller for.
|
|
2314
|
-
* @param override - Reset the controller even if one has been defined.
|
|
2315
|
-
* @remarks
|
|
2316
|
-
* The specified element must have a {@link FASTElementDefinition}
|
|
2317
|
-
* registered either through the use of the {@link customElement}
|
|
2318
|
-
* decorator or a call to `FASTElement.define`.
|
|
2319
|
-
*/
|
|
2320
|
-
static forCustomElement(t, e = !1) {
|
|
2321
|
-
const s = t.$fastController;
|
|
2322
|
-
if (s !== void 0 && !e)
|
|
2323
|
-
return s;
|
|
2324
|
-
const n = p.getForInstance(t);
|
|
2325
|
-
if (n === void 0)
|
|
2326
|
-
throw v.error(
|
|
2327
|
-
1401
|
|
2328
|
-
/* Message.missingElementDefinition */
|
|
2329
|
-
);
|
|
2330
|
-
return g.getNotifier(n).subscribe({
|
|
2331
|
-
handleChange: () => {
|
|
2332
|
-
S.forCustomElement(t, !0), t.$fastController.connect();
|
|
2333
|
-
}
|
|
2334
|
-
}, "template"), g.getNotifier(n).subscribe({
|
|
2335
|
-
handleChange: () => {
|
|
2336
|
-
S.forCustomElement(t, !0), t.$fastController.connect();
|
|
2337
|
-
}
|
|
2338
|
-
}, "shadowOptions"), t.$fastController = new It(t, n);
|
|
2339
|
-
}
|
|
2340
|
-
/**
|
|
2341
|
-
* Sets the strategy that ElementController.forCustomElement uses to construct
|
|
2342
|
-
* ElementController instances for an element.
|
|
2343
|
-
* @param strategy - The strategy to use.
|
|
2344
|
-
*/
|
|
2345
|
-
static setStrategy(t) {
|
|
2346
|
-
It = t;
|
|
2347
|
-
}
|
|
2348
|
-
}
|
|
2349
|
-
x(S);
|
|
2350
|
-
S.setStrategy(S);
|
|
2351
|
-
function Q(i) {
|
|
2352
|
-
var t;
|
|
2353
|
-
return "adoptedStyleSheets" in i ? i : (t = I(i)) !== null && t !== void 0 ? t : i.getRootNode();
|
|
2354
|
-
}
|
|
2355
|
-
class Z {
|
|
2356
|
-
constructor(t) {
|
|
2357
|
-
const e = Z.styleSheetCache;
|
|
2358
|
-
this.sheets = t.map((s) => {
|
|
2359
|
-
if (s instanceof CSSStyleSheet)
|
|
2360
|
-
return s;
|
|
2361
|
-
let n = e.get(s);
|
|
2362
|
-
return n === void 0 && (n = new CSSStyleSheet(), n.replaceSync(s), e.set(s, n)), n;
|
|
2363
|
-
});
|
|
2364
|
-
}
|
|
2365
|
-
addStylesTo(t) {
|
|
2366
|
-
le(Q(t), this.sheets);
|
|
2367
|
-
}
|
|
2368
|
-
removeStylesFrom(t) {
|
|
2369
|
-
ce(Q(t), this.sheets);
|
|
2370
|
-
}
|
|
2371
|
-
}
|
|
2372
|
-
Z.styleSheetCache = /* @__PURE__ */ new Map();
|
|
2373
|
-
let We = 0;
|
|
2374
|
-
const Qe = () => `fast-${++We}`;
|
|
2375
|
-
function jt(i) {
|
|
2376
|
-
return i === document ? document.body : i;
|
|
2377
|
-
}
|
|
2378
|
-
class Ge {
|
|
2379
|
-
constructor(t) {
|
|
2380
|
-
this.styles = t, this.styleClass = Qe();
|
|
2381
|
-
}
|
|
2382
|
-
addStylesTo(t) {
|
|
2383
|
-
t = jt(Q(t));
|
|
2384
|
-
const e = this.styles, s = this.styleClass;
|
|
2385
|
-
for (let n = 0; n < e.length; n++) {
|
|
2386
|
-
const r = document.createElement("style");
|
|
2387
|
-
r.innerHTML = e[n], r.className = s, t.append(r);
|
|
2388
|
-
}
|
|
2389
|
-
}
|
|
2390
|
-
removeStylesFrom(t) {
|
|
2391
|
-
t = jt(Q(t));
|
|
2392
|
-
const e = t.querySelectorAll(`.${this.styleClass}`);
|
|
2393
|
-
for (let s = 0, n = e.length; s < n; ++s)
|
|
2394
|
-
t.removeChild(e[s]);
|
|
2395
|
-
}
|
|
2396
|
-
}
|
|
2397
|
-
let le = (i, t) => {
|
|
2398
|
-
i.adoptedStyleSheets = [...i.adoptedStyleSheets, ...t];
|
|
2399
|
-
}, ce = (i, t) => {
|
|
2400
|
-
i.adoptedStyleSheets = i.adoptedStyleSheets.filter((e) => t.indexOf(e) === -1);
|
|
984
|
+
j.define(L, { aspected: !0 });
|
|
985
|
+
//#endregion
|
|
986
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/templating/compiler.js
|
|
987
|
+
var Ue = (e, t) => `${e}.${t}`, We = {}, R = {
|
|
988
|
+
index: 0,
|
|
989
|
+
node: null
|
|
2401
990
|
};
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2426
|
-
|
|
2427
|
-
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2460
|
-
|
|
2461
|
-
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
|
|
2467
|
-
|
|
2468
|
-
|
|
2469
|
-
|
|
2470
|
-
|
|
2471
|
-
|
|
2472
|
-
|
|
2473
|
-
|
|
2474
|
-
|
|
2475
|
-
|
|
2476
|
-
|
|
2477
|
-
|
|
2478
|
-
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
2537
|
-
|
|
2538
|
-
|
|
2539
|
-
|
|
2540
|
-
|
|
2541
|
-
|
|
2542
|
-
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
|
|
2546
|
-
|
|
2547
|
-
|
|
2548
|
-
|
|
2549
|
-
|
|
2550
|
-
|
|
2551
|
-
}
|
|
2552
|
-
|
|
2553
|
-
|
|
2554
|
-
|
|
2555
|
-
|
|
2556
|
-
|
|
2557
|
-
|
|
2558
|
-
|
|
2559
|
-
|
|
2560
|
-
|
|
2561
|
-
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
|
|
2565
|
-
|
|
2566
|
-
|
|
2567
|
-
|
|
2568
|
-
|
|
2569
|
-
|
|
2570
|
-
|
|
2571
|
-
|
|
2572
|
-
|
|
2573
|
-
|
|
2574
|
-
* @public
|
|
2575
|
-
*/
|
|
2576
|
-
compose: Je,
|
|
2577
|
-
/**
|
|
2578
|
-
* Defines metadata for a FASTElement which can be used after it has been resolved to define the element.
|
|
2579
|
-
* @alpha
|
|
2580
|
-
*/
|
|
2581
|
-
defineAsync: Ke
|
|
991
|
+
function Ge(e) {
|
|
992
|
+
e.startsWith("fast-") || s.warn(1204, { name: e });
|
|
993
|
+
}
|
|
994
|
+
var Ke = new Proxy(document.createElement("div"), {
|
|
995
|
+
get(e, t) {
|
|
996
|
+
Ge(t);
|
|
997
|
+
let n = Reflect.get(e, t);
|
|
998
|
+
return r(n) ? n.bind(e) : n;
|
|
999
|
+
},
|
|
1000
|
+
set(e, t, n) {
|
|
1001
|
+
return Ge(t), Reflect.set(e, t, n);
|
|
1002
|
+
}
|
|
1003
|
+
}), qe = class {
|
|
1004
|
+
constructor(e, t, n) {
|
|
1005
|
+
this.fragment = e, this.directives = t, this.policy = n, this.proto = null, this.nodeIds = /* @__PURE__ */ new Set(), this.descriptors = {}, this.factories = [];
|
|
1006
|
+
}
|
|
1007
|
+
addFactory(e, t, n, r, i) {
|
|
1008
|
+
this.nodeIds.has(n) || (this.nodeIds.add(n), this.addTargetDescriptor(t, n, r)), e.id = e.id ?? O(), e.targetNodeId = n, e.targetTagName = i, e.policy = e.policy ?? this.policy, this.factories.push(e);
|
|
1009
|
+
}
|
|
1010
|
+
freeze() {
|
|
1011
|
+
return this.proto = Object.create(null, this.descriptors), this;
|
|
1012
|
+
}
|
|
1013
|
+
addTargetDescriptor(e, t, n) {
|
|
1014
|
+
let r = this.descriptors;
|
|
1015
|
+
if (t === "r" || t === "h" || r[t]) return;
|
|
1016
|
+
if (!r[e]) {
|
|
1017
|
+
let t = e.lastIndexOf("."), n = e.substring(0, t), r = parseInt(e.substring(t + 1));
|
|
1018
|
+
this.addTargetDescriptor(n, e, r);
|
|
1019
|
+
}
|
|
1020
|
+
let i = We[t];
|
|
1021
|
+
if (!i) {
|
|
1022
|
+
let r = `_${t}`;
|
|
1023
|
+
We[t] = i = { get() {
|
|
1024
|
+
return this[r] ?? (this[r] = this[e].childNodes[n]);
|
|
1025
|
+
} };
|
|
1026
|
+
}
|
|
1027
|
+
r[t] = i;
|
|
1028
|
+
}
|
|
1029
|
+
createView(e) {
|
|
1030
|
+
let t = this.fragment.cloneNode(!0), n = Object.create(this.proto);
|
|
1031
|
+
n.r = t, n.h = e ?? Ke;
|
|
1032
|
+
for (let e of this.nodeIds) n[e];
|
|
1033
|
+
return new F(t, this.factories, n);
|
|
1034
|
+
}
|
|
1035
|
+
};
|
|
1036
|
+
function Je(e, t, n, r, i, a = !1) {
|
|
1037
|
+
let o = n.attributes, s = e.directives;
|
|
1038
|
+
for (let c = 0, l = o.length; c < l; ++c) {
|
|
1039
|
+
let u = o[c], d = u.value, f = k.parse(d, s), p = null;
|
|
1040
|
+
f === null ? a && (p = new L(le(() => d, e.policy)), j.assignAspect(p, u.name)) : p = z.aggregate(f, e.policy), p !== null && (n.removeAttributeNode(u), c--, l--, e.addFactory(p, t, r, i, n.tagName));
|
|
1041
|
+
}
|
|
1042
|
+
}
|
|
1043
|
+
function Ye(e, t, n, r, a) {
|
|
1044
|
+
let o = k.parse(t.textContent, e.directives);
|
|
1045
|
+
if (o === null) return R.node = t.nextSibling, R.index = a + 1, R;
|
|
1046
|
+
let s, c = s = t;
|
|
1047
|
+
for (let t = 0, l = o.length; t < l; ++t) {
|
|
1048
|
+
let l = o[t];
|
|
1049
|
+
t !== 0 && (a++, r = Ue(n, a), s = c.parentNode.insertBefore(document.createTextNode(""), c.nextSibling)), i(l) ? s.textContent = l : (s.textContent = " ", j.assignAspect(l), e.addFactory(l, n, r, a, null)), c = s;
|
|
1050
|
+
}
|
|
1051
|
+
return R.index = a + 1, R.node = c.nextSibling, R;
|
|
1052
|
+
}
|
|
1053
|
+
function Xe(e, t, n) {
|
|
1054
|
+
let r = 0, i = t.firstChild;
|
|
1055
|
+
for (; i;) {
|
|
1056
|
+
let t = Ze(e, n, i, r);
|
|
1057
|
+
i = t.node, r = t.index;
|
|
1058
|
+
}
|
|
1059
|
+
}
|
|
1060
|
+
function Ze(e, t, n, r) {
|
|
1061
|
+
let i = Ue(t, r);
|
|
1062
|
+
switch (n.nodeType) {
|
|
1063
|
+
case 1:
|
|
1064
|
+
Je(e, t, n, i, r), Xe(e, n, i);
|
|
1065
|
+
break;
|
|
1066
|
+
case 3: return Ye(e, n, t, i, r);
|
|
1067
|
+
case 8:
|
|
1068
|
+
let a = k.parse(n.data, e.directives);
|
|
1069
|
+
a !== null && e.addFactory(z.aggregate(a), t, i, r, null);
|
|
1070
|
+
break;
|
|
1071
|
+
}
|
|
1072
|
+
return R.index = r + 1, R.node = n.nextSibling, R;
|
|
1073
|
+
}
|
|
1074
|
+
function Qe(e, t) {
|
|
1075
|
+
return e && e.nodeType == 8 && k.parse(e.data, t) !== null;
|
|
1076
|
+
}
|
|
1077
|
+
var $e = "TEMPLATE", z = {
|
|
1078
|
+
compile(e, t, n = h.policy) {
|
|
1079
|
+
let r;
|
|
1080
|
+
if (i(e)) {
|
|
1081
|
+
r = document.createElement($e), r.innerHTML = n.createHTML(e);
|
|
1082
|
+
let t = r.content.firstElementChild;
|
|
1083
|
+
t !== null && t.tagName === $e && (r = t);
|
|
1084
|
+
} else r = e;
|
|
1085
|
+
!r.content.firstChild && !r.content.lastChild && r.content.appendChild(document.createComment(""));
|
|
1086
|
+
let a = document.adoptNode(r.content), o = new qe(a, t, n);
|
|
1087
|
+
return Je(o, "", r, "h", 0, !0), (Qe(a.firstChild, t) || a.childNodes.length === 1 && Object.keys(t).length > 0) && a.insertBefore(document.createComment(""), a.firstChild), Xe(o, a, "r"), R.node = null, o.freeze();
|
|
1088
|
+
},
|
|
1089
|
+
setDefaultStrategy(e) {
|
|
1090
|
+
this.compile = e;
|
|
1091
|
+
},
|
|
1092
|
+
aggregate(e, t = h.policy) {
|
|
1093
|
+
if (e.length === 1) return e[0];
|
|
1094
|
+
let n, r = !1, a, o = e.length, s = e.map((e) => i(e) ? () => e : (n = e.sourceAspect || n, r ||= e.dataBinding.isVolatile, a ||= e.dataBinding.policy, e.dataBinding.evaluate)), c = new L(se((e, t) => {
|
|
1095
|
+
let n = "";
|
|
1096
|
+
for (let r = 0; r < o; ++r) n += s[r](e, t);
|
|
1097
|
+
return n;
|
|
1098
|
+
}, a ?? t, r));
|
|
1099
|
+
return j.assignAspect(c, n), c;
|
|
1100
|
+
}
|
|
1101
|
+
}, et = /([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/, tt = Object.create(null), B = class {
|
|
1102
|
+
constructor(e, t = tt) {
|
|
1103
|
+
this.html = e, this.factories = t;
|
|
1104
|
+
}
|
|
1105
|
+
createHTML(e) {
|
|
1106
|
+
let t = this.factories;
|
|
1107
|
+
for (let n in t) e(t[n]);
|
|
1108
|
+
return this.html;
|
|
1109
|
+
}
|
|
1110
|
+
};
|
|
1111
|
+
B.empty = new B(""), j.define(B);
|
|
1112
|
+
function nt(e, t, n, r = j.getForInstance(e)) {
|
|
1113
|
+
if (r.aspected) {
|
|
1114
|
+
let n = et.exec(t);
|
|
1115
|
+
n !== null && j.assignAspect(e, n[2]);
|
|
1116
|
+
}
|
|
1117
|
+
return e.createHTML(n);
|
|
1118
|
+
}
|
|
1119
|
+
var rt = class e {
|
|
1120
|
+
constructor(e, t = {}, n) {
|
|
1121
|
+
this.policy = n, this.result = null, this.html = e, this.factories = t;
|
|
1122
|
+
}
|
|
1123
|
+
compile() {
|
|
1124
|
+
return this.result === null && (this.result = z.compile(this.html, this.factories, this.policy)), this.result;
|
|
1125
|
+
}
|
|
1126
|
+
create(e) {
|
|
1127
|
+
return this.compile().createView(e);
|
|
1128
|
+
}
|
|
1129
|
+
inline() {
|
|
1130
|
+
return new B(i(this.html) ? this.html : this.html.innerHTML, this.factories);
|
|
1131
|
+
}
|
|
1132
|
+
withPolicy(e) {
|
|
1133
|
+
if (this.result) throw s.error(1208);
|
|
1134
|
+
if (this.policy) throw s.error(1207);
|
|
1135
|
+
return this.policy = e, this;
|
|
1136
|
+
}
|
|
1137
|
+
render(e, t, n) {
|
|
1138
|
+
let r = this.create(n);
|
|
1139
|
+
return r.bind(e), r.appendTo(t), r;
|
|
1140
|
+
}
|
|
1141
|
+
static create(t, n, i) {
|
|
1142
|
+
let a = "", o = Object.create(null), s = (e) => {
|
|
1143
|
+
let t = e.id ??= O();
|
|
1144
|
+
return o[t] = e, t;
|
|
1145
|
+
};
|
|
1146
|
+
for (let e = 0, i = t.length - 1; e < i; ++e) {
|
|
1147
|
+
let i = t[e], o = n[e], c;
|
|
1148
|
+
if (a += i, r(o)) o = new L(se(o));
|
|
1149
|
+
else if (o instanceof x) o = new L(o);
|
|
1150
|
+
else if (!(c = j.getForInstance(o))) {
|
|
1151
|
+
let e = o;
|
|
1152
|
+
o = new L(le(() => e));
|
|
1153
|
+
}
|
|
1154
|
+
a += nt(o, i, s, c);
|
|
1155
|
+
}
|
|
1156
|
+
return new e(a + t[t.length - 1], o, i);
|
|
1157
|
+
}
|
|
1158
|
+
};
|
|
1159
|
+
d(rt);
|
|
1160
|
+
var V = ((e, ...t) => {
|
|
1161
|
+
if (Array.isArray(e) && Array.isArray(e.raw)) return rt.create(e, t);
|
|
1162
|
+
throw s.error(1206);
|
|
2582
1163
|
});
|
|
2583
|
-
|
|
2584
|
-
|
|
2585
|
-
|
|
2586
|
-
|
|
2587
|
-
|
|
2588
|
-
|
|
2589
|
-
|
|
2590
|
-
|
|
2591
|
-
|
|
2592
|
-
|
|
2593
|
-
}), Lt.add(r), nt.set(o, r);
|
|
2594
|
-
for (const a of n.dependencies)
|
|
2595
|
-
s(a);
|
|
2596
|
-
const c = new Map([
|
|
2597
|
-
[n.type, r],
|
|
2598
|
-
...n.dependencies.map(
|
|
2599
|
-
(a) => [a.type, e(a.name)]
|
|
2600
|
-
)
|
|
2601
|
-
]), l = {
|
|
2602
|
-
tagFor: (a, h) => {
|
|
2603
|
-
if (!c.has(a))
|
|
2604
|
-
throw new Error(
|
|
2605
|
-
`Could not get tag for ${a.name} as it is not a dependency of ${n.name}.`
|
|
2606
|
-
);
|
|
2607
|
-
const u = c.get(a);
|
|
2608
|
-
return h ? u : re.partial(u);
|
|
2609
|
-
},
|
|
2610
|
-
tagForNonDependency(a) {
|
|
2611
|
-
return e(a);
|
|
2612
|
-
}
|
|
2613
|
-
};
|
|
2614
|
-
p.compose(o, {
|
|
2615
|
-
...n.options,
|
|
2616
|
-
template: ti(
|
|
2617
|
-
n.template,
|
|
2618
|
-
l
|
|
2619
|
-
),
|
|
2620
|
-
name: `${t}-${n.name}`
|
|
2621
|
-
}).define();
|
|
2622
|
-
};
|
|
2623
|
-
s(i);
|
|
2624
|
-
}, yi = (i, t, e, s, n) => ({
|
|
2625
|
-
name: i,
|
|
2626
|
-
type: t,
|
|
2627
|
-
template: e,
|
|
2628
|
-
dependencies: s,
|
|
2629
|
-
options: n
|
|
2630
|
-
}), Vt = /* @__PURE__ */ new WeakMap(), he = (i) => {
|
|
2631
|
-
let t = Vt.get(i);
|
|
2632
|
-
return t || (t = [], Vt.set(i, t)), t;
|
|
2633
|
-
}, vi = (i, t) => {
|
|
2634
|
-
he(i).push(t);
|
|
2635
|
-
}, ei = (i, t) => {
|
|
2636
|
-
he(i).forEach((e) => e(i, t));
|
|
2637
|
-
}, ii = (i) => i === "delegate", Ft = (i) => `vvd${i.charAt(0).toUpperCase()}${i.slice(1)}`, ue = (i, t) => {
|
|
2638
|
-
if (ii(i._vividAriaBehaviour)) {
|
|
2639
|
-
const e = i[t];
|
|
2640
|
-
i[`_${t}`] = null, i.removeAttribute(ot(t)), i[`_${t}`] = e, i[t] !== null ? i.dataset[Ft(t)] = i[t] : delete i.dataset[Ft(t)];
|
|
2641
|
-
} else
|
|
2642
|
-
T.setAttribute(
|
|
2643
|
-
i,
|
|
2644
|
-
ot(t),
|
|
2645
|
-
i[t]
|
|
2646
|
-
);
|
|
2647
|
-
}, G = /* @__PURE__ */ new WeakMap(), si = (i, t) => {
|
|
2648
|
-
const e = G.get(i);
|
|
2649
|
-
e ? e.add(t) : G.set(i, /* @__PURE__ */ new Set([t]));
|
|
2650
|
-
}, ni = (i, t) => {
|
|
2651
|
-
i.isConnected ? ue(i, t) : si(i, t);
|
|
2652
|
-
}, ri = (i) => {
|
|
2653
|
-
const t = G.get(i);
|
|
2654
|
-
if (t) {
|
|
2655
|
-
for (const e of t)
|
|
2656
|
-
ue(i, e);
|
|
2657
|
-
G.delete(i);
|
|
2658
|
-
}
|
|
2659
|
-
}, Dt = [
|
|
2660
|
-
"role",
|
|
2661
|
-
"ariaAtomic",
|
|
2662
|
-
"ariaAutoComplete",
|
|
2663
|
-
"ariaBusy",
|
|
2664
|
-
"ariaChecked",
|
|
2665
|
-
"ariaColCount",
|
|
2666
|
-
"ariaColIndex",
|
|
2667
|
-
"ariaColIndexText",
|
|
2668
|
-
"ariaColSpan",
|
|
2669
|
-
"ariaCurrent",
|
|
2670
|
-
"ariaDescription",
|
|
2671
|
-
"ariaDisabled",
|
|
2672
|
-
"ariaExpanded",
|
|
2673
|
-
"ariaHasPopup",
|
|
2674
|
-
"ariaHidden",
|
|
2675
|
-
"ariaInvalid",
|
|
2676
|
-
"ariaKeyShortcuts",
|
|
2677
|
-
"ariaLabel",
|
|
2678
|
-
"ariaLevel",
|
|
2679
|
-
"ariaLive",
|
|
2680
|
-
"ariaModal",
|
|
2681
|
-
"ariaMultiLine",
|
|
2682
|
-
"ariaMultiSelectable",
|
|
2683
|
-
"ariaOrientation",
|
|
2684
|
-
"ariaPlaceholder",
|
|
2685
|
-
"ariaPosInSet",
|
|
2686
|
-
"ariaPressed",
|
|
2687
|
-
"ariaReadOnly",
|
|
2688
|
-
"ariaRequired",
|
|
2689
|
-
"ariaRoleDescription",
|
|
2690
|
-
"ariaRowCount",
|
|
2691
|
-
"ariaRowIndex",
|
|
2692
|
-
"ariaRowIndexText",
|
|
2693
|
-
"ariaRowSpan",
|
|
2694
|
-
"ariaSelected",
|
|
2695
|
-
"ariaSetSize",
|
|
2696
|
-
"ariaSort",
|
|
2697
|
-
"ariaValueMax",
|
|
2698
|
-
"ariaValueMin",
|
|
2699
|
-
"ariaValueNow",
|
|
2700
|
-
"ariaValueText",
|
|
2701
|
-
"ariaRelevant"
|
|
2702
|
-
// Non-standard
|
|
2703
|
-
], ot = (i) => i.replace("aria", "aria-").toLowerCase(), ai = (i) => {
|
|
2704
|
-
class t extends i {
|
|
2705
|
-
constructor(...s) {
|
|
2706
|
-
super(...s), this._vividAriaBehaviour = "default";
|
|
2707
|
-
for (const n of Dt)
|
|
2708
|
-
this[`_${n}`] = null;
|
|
2709
|
-
}
|
|
2710
|
-
connectedCallback() {
|
|
2711
|
-
super.connectedCallback(), ri(this);
|
|
2712
|
-
}
|
|
2713
|
-
}
|
|
2714
|
-
for (const e of Dt)
|
|
2715
|
-
He({
|
|
2716
|
-
attribute: ot(e),
|
|
2717
|
-
mode: "fromView"
|
|
2718
|
-
})(t.prototype, e), t.prototype[`${e}Changed`] = function() {
|
|
2719
|
-
ni(this, e), this._vividAriaBehaviour !== "default" && ei(this, e);
|
|
2720
|
-
};
|
|
2721
|
-
return t;
|
|
1164
|
+
V.partial = (e) => new B(e);
|
|
1165
|
+
//#endregion
|
|
1166
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/components/attributes.js
|
|
1167
|
+
var it = "boolean", at = "reflect", ot = Object.freeze({ locate: u() }), st = {
|
|
1168
|
+
toView(e) {
|
|
1169
|
+
return e ? "true" : "false";
|
|
1170
|
+
},
|
|
1171
|
+
fromView(e) {
|
|
1172
|
+
return !(e == null || e === "false" || e === !1 || e === 0);
|
|
1173
|
+
}
|
|
2722
1174
|
};
|
|
2723
|
-
function
|
|
2724
|
-
|
|
2725
|
-
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
},
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
|
|
2739
|
-
|
|
2740
|
-
|
|
2741
|
-
|
|
2742
|
-
|
|
2743
|
-
|
|
2744
|
-
|
|
2745
|
-
|
|
2746
|
-
|
|
2747
|
-
|
|
2748
|
-
|
|
2749
|
-
|
|
2750
|
-
|
|
2751
|
-
|
|
2752
|
-
|
|
2753
|
-
|
|
2754
|
-
|
|
2755
|
-
|
|
2756
|
-
|
|
2757
|
-
|
|
2758
|
-
|
|
2759
|
-
|
|
2760
|
-
|
|
2761
|
-
|
|
2762
|
-
|
|
1175
|
+
function ct(e) {
|
|
1176
|
+
if (e == null) return null;
|
|
1177
|
+
let t = e * 1;
|
|
1178
|
+
return isNaN(t) ? null : t;
|
|
1179
|
+
}
|
|
1180
|
+
var lt = {
|
|
1181
|
+
toView(e) {
|
|
1182
|
+
let t = ct(e);
|
|
1183
|
+
return t && t.toString();
|
|
1184
|
+
},
|
|
1185
|
+
fromView: ct
|
|
1186
|
+
}, ut = class e {
|
|
1187
|
+
constructor(e, t, n = t.toLowerCase(), r = at, i) {
|
|
1188
|
+
this.guards = /* @__PURE__ */ new Set(), this.Owner = e, this.name = t, this.attribute = n, this.mode = r, this.converter = i, this.fieldName = `_${t}`, this.callbackName = `${t}Changed`, this.hasCallback = this.callbackName in e.prototype, r === it && i === void 0 && (this.converter = st);
|
|
1189
|
+
}
|
|
1190
|
+
setValue(e, t) {
|
|
1191
|
+
let n = e[this.fieldName], r = this.converter;
|
|
1192
|
+
r !== void 0 && (t = r.fromView(t)), n !== t && (e[this.fieldName] = t, this.tryReflectToAttribute(e), this.hasCallback && e[this.callbackName](n, t), e.$fastController.notify(this.name));
|
|
1193
|
+
}
|
|
1194
|
+
getValue(e) {
|
|
1195
|
+
return y.track(e, this.name), e[this.fieldName];
|
|
1196
|
+
}
|
|
1197
|
+
onAttributeChangedCallback(e, t) {
|
|
1198
|
+
this.guards.has(e) || (this.guards.add(e), this.setValue(e, t), this.guards.delete(e));
|
|
1199
|
+
}
|
|
1200
|
+
tryReflectToAttribute(e) {
|
|
1201
|
+
let t = this.mode, n = this.guards;
|
|
1202
|
+
n.has(e) || t === "fromView" || g.enqueue(() => {
|
|
1203
|
+
n.add(e);
|
|
1204
|
+
let r = e[this.fieldName];
|
|
1205
|
+
switch (t) {
|
|
1206
|
+
case at:
|
|
1207
|
+
let t = this.converter;
|
|
1208
|
+
h.setAttribute(e, this.attribute, t === void 0 ? r : t.toView(r));
|
|
1209
|
+
break;
|
|
1210
|
+
case it:
|
|
1211
|
+
h.setBooleanAttribute(e, this.attribute, r);
|
|
1212
|
+
break;
|
|
1213
|
+
}
|
|
1214
|
+
n.delete(e);
|
|
1215
|
+
});
|
|
1216
|
+
}
|
|
1217
|
+
static collect(t, ...n) {
|
|
1218
|
+
let r = [];
|
|
1219
|
+
n.push(ot.locate(t));
|
|
1220
|
+
for (let a = 0, o = n.length; a < o; ++a) {
|
|
1221
|
+
let o = n[a];
|
|
1222
|
+
if (o !== void 0) for (let n = 0, a = o.length; n < a; ++n) {
|
|
1223
|
+
let a = o[n];
|
|
1224
|
+
i(a) ? r.push(new e(t, a)) : r.push(new e(t, a.property, a.attribute, a.mode, a.converter));
|
|
1225
|
+
}
|
|
1226
|
+
}
|
|
1227
|
+
return r;
|
|
1228
|
+
}
|
|
2763
1229
|
};
|
|
2764
|
-
|
|
2765
|
-
|
|
2766
|
-
|
|
2767
|
-
|
|
2768
|
-
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2798
|
-
|
|
2799
|
-
|
|
2800
|
-
|
|
2801
|
-
|
|
2802
|
-
|
|
2803
|
-
|
|
2804
|
-
|
|
2805
|
-
|
|
2806
|
-
|
|
2807
|
-
|
|
2808
|
-
|
|
2809
|
-
|
|
2810
|
-
|
|
2811
|
-
|
|
2812
|
-
|
|
2813
|
-
|
|
2814
|
-
|
|
1230
|
+
function dt(e, t) {
|
|
1231
|
+
let n;
|
|
1232
|
+
function r(e, t) {
|
|
1233
|
+
arguments.length > 1 && (n.property = t), ot.locate(e.constructor).push(n);
|
|
1234
|
+
}
|
|
1235
|
+
if (arguments.length > 1) {
|
|
1236
|
+
n = {}, r(e, t);
|
|
1237
|
+
return;
|
|
1238
|
+
}
|
|
1239
|
+
return n = e === void 0 ? {} : e, r;
|
|
1240
|
+
}
|
|
1241
|
+
//#endregion
|
|
1242
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/components/fast-definitions.js
|
|
1243
|
+
var ft = function(e, t, n, r) {
|
|
1244
|
+
function i(e) {
|
|
1245
|
+
return e instanceof n ? e : new n(function(t) {
|
|
1246
|
+
t(e);
|
|
1247
|
+
});
|
|
1248
|
+
}
|
|
1249
|
+
return new (n ||= Promise)(function(n, a) {
|
|
1250
|
+
function o(e) {
|
|
1251
|
+
try {
|
|
1252
|
+
c(r.next(e));
|
|
1253
|
+
} catch (e) {
|
|
1254
|
+
a(e);
|
|
1255
|
+
}
|
|
1256
|
+
}
|
|
1257
|
+
function s(e) {
|
|
1258
|
+
try {
|
|
1259
|
+
c(r.throw(e));
|
|
1260
|
+
} catch (e) {
|
|
1261
|
+
a(e);
|
|
1262
|
+
}
|
|
1263
|
+
}
|
|
1264
|
+
function c(e) {
|
|
1265
|
+
e.done ? n(e.value) : i(e.value).then(o, s);
|
|
1266
|
+
}
|
|
1267
|
+
c((r = r.apply(e, t || [])).next());
|
|
1268
|
+
});
|
|
1269
|
+
}, pt = { mode: "open" }, mt = {}, H = /* @__PURE__ */ new Set(), U = s.getById(n.elementRegistry, () => l()), ht = { deferAndHydrate: "defer-and-hydrate" }, W = class e {
|
|
1270
|
+
constructor(t, n = t.definition) {
|
|
1271
|
+
this.platformDefined = !1, i(n) && (n = { name: n }), this.type = t, this.name = n.name, this.template = n.template, this.templateOptions = n.templateOptions, this.registry = n.registry ?? customElements;
|
|
1272
|
+
let r = t.prototype, a = ut.collect(t, n.attributes), o = Array(a.length), s = {}, c = {};
|
|
1273
|
+
for (let e = 0, t = a.length; e < t; ++e) {
|
|
1274
|
+
let t = a[e];
|
|
1275
|
+
o[e] = t.attribute, s[t.name] = t, c[t.attribute] = t, y.defineProperty(r, t);
|
|
1276
|
+
}
|
|
1277
|
+
Reflect.defineProperty(t, "observedAttributes", {
|
|
1278
|
+
value: o,
|
|
1279
|
+
enumerable: !0
|
|
1280
|
+
}), this.attributes = a, this.propertyLookup = s, this.attributeLookup = c, this.shadowOptions = n.shadowOptions === void 0 ? pt : n.shadowOptions === null ? void 0 : Object.assign(Object.assign({}, pt), n.shadowOptions), this.elementOptions = n.elementOptions === void 0 ? mt : Object.assign(Object.assign({}, mt), n.elementOptions), this.styles = S.normalize(n.styles), U.register(this), y.defineProperty(e.isRegistered, this.name), e.isRegistered[this.name] = this.type;
|
|
1281
|
+
}
|
|
1282
|
+
get isDefined() {
|
|
1283
|
+
return this.platformDefined;
|
|
1284
|
+
}
|
|
1285
|
+
define(e = this.registry) {
|
|
1286
|
+
var t, n;
|
|
1287
|
+
let r = this.type;
|
|
1288
|
+
return e.get(this.name) || (this.platformDefined = !0, e.define(this.name, r, this.elementOptions), (n = (t = this.lifecycleCallbacks)?.elementDidDefine) == null || n.call(t, this.name)), this;
|
|
1289
|
+
}
|
|
1290
|
+
static compose(t, n) {
|
|
1291
|
+
return H.has(t) || U.getByType(t) ? new e(class extends t {}, n) : new e(t, n);
|
|
1292
|
+
}
|
|
1293
|
+
static registerBaseType(e) {
|
|
1294
|
+
H.add(e);
|
|
1295
|
+
}
|
|
1296
|
+
static composeAsync(t, n) {
|
|
1297
|
+
return new Promise((r) => {
|
|
1298
|
+
(H.has(t) || U.getByType(t)) && r(new e(class extends t {}, n));
|
|
1299
|
+
let i = new e(t, n);
|
|
1300
|
+
y.getNotifier(i).subscribe({ handleChange: () => {
|
|
1301
|
+
var e, t;
|
|
1302
|
+
(t = (e = i.lifecycleCallbacks)?.templateDidUpdate) == null || t.call(e, i.name), r(i);
|
|
1303
|
+
} }, "template");
|
|
1304
|
+
});
|
|
1305
|
+
}
|
|
1306
|
+
};
|
|
1307
|
+
W.isRegistered = {}, W.getByType = U.getByType, W.getForInstance = U.getForInstance, W.registerAsync = (e) => ft(void 0, void 0, void 0, function* () {
|
|
1308
|
+
return new Promise((t) => {
|
|
1309
|
+
W.isRegistered[e] && t(W.isRegistered[e]), y.getNotifier(W.isRegistered).subscribe({ handleChange: () => t(W.isRegistered[e]) }, e);
|
|
1310
|
+
});
|
|
1311
|
+
}), y.defineProperty(W.prototype, "template");
|
|
1312
|
+
//#endregion
|
|
1313
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/utilities.js
|
|
1314
|
+
var gt = class extends MutationObserver {
|
|
1315
|
+
constructor(e) {
|
|
1316
|
+
function t(e) {
|
|
1317
|
+
this.callback.call(null, e.filter((e) => this.observedNodes.has(e.target)));
|
|
1318
|
+
}
|
|
1319
|
+
super(t), this.callback = e, this.observedNodes = /* @__PURE__ */ new Set();
|
|
1320
|
+
}
|
|
1321
|
+
observe(e, t) {
|
|
1322
|
+
this.observedNodes.add(e), super.observe(e, t);
|
|
1323
|
+
}
|
|
1324
|
+
unobserve(e) {
|
|
1325
|
+
this.observedNodes.delete(e), this.observedNodes.size < 1 && this.disconnect();
|
|
1326
|
+
}
|
|
1327
|
+
}, _t = Object.freeze({ create(e) {
|
|
1328
|
+
let t = [], n = {}, r = null, i = !1;
|
|
1329
|
+
return {
|
|
1330
|
+
source: e,
|
|
1331
|
+
context: b.default,
|
|
1332
|
+
targets: n,
|
|
1333
|
+
get isBound() {
|
|
1334
|
+
return i;
|
|
1335
|
+
},
|
|
1336
|
+
addBehaviorFactory(e, t) {
|
|
1337
|
+
let n = e;
|
|
1338
|
+
n.id = n.id ?? O(), n.targetNodeId = n.targetNodeId ?? O(), n.targetTagName = t.tagName ?? null, n.policy = n.policy ?? h.policy, this.addTarget(n.targetNodeId, t), this.addBehavior(n.createBehavior());
|
|
1339
|
+
},
|
|
1340
|
+
addTarget(e, t) {
|
|
1341
|
+
n[e] = t;
|
|
1342
|
+
},
|
|
1343
|
+
addBehavior(e) {
|
|
1344
|
+
t.push(e), i && e.bind(this);
|
|
1345
|
+
},
|
|
1346
|
+
onUnbind(e) {
|
|
1347
|
+
r === null && (r = []), r.push(e);
|
|
1348
|
+
},
|
|
1349
|
+
connectedCallback(e) {
|
|
1350
|
+
i || (i = !0, t.forEach((e) => e.bind(this)));
|
|
1351
|
+
},
|
|
1352
|
+
disconnectedCallback(e) {
|
|
1353
|
+
i && (i = !1, r !== null && r.forEach((e) => e.unbind(this)));
|
|
1354
|
+
}
|
|
1355
|
+
};
|
|
1356
|
+
} }), vt = {
|
|
1357
|
+
bubbles: !0,
|
|
1358
|
+
composed: !0,
|
|
1359
|
+
cancelable: !0
|
|
1360
|
+
}, G = "isConnected", yt = /* @__PURE__ */ new WeakMap();
|
|
1361
|
+
function K(e) {
|
|
1362
|
+
return e.shadowRoot ?? yt.get(e) ?? null;
|
|
1363
|
+
}
|
|
1364
|
+
var bt, q = class e extends ne {
|
|
1365
|
+
constructor(e, t) {
|
|
1366
|
+
super(e), this.boundObservables = null, this.needsInitialization = !0, this.hasExistingShadowRoot = !1, this._template = null, this.stage = 3, this.guardBehaviorConnection = !1, this.behaviors = null, this.behaviorsConnected = !1, this._mainStyles = null, this.$fastController = this, this.view = null, this.source = e, this.definition = t, this.shadowOptions = t.shadowOptions;
|
|
1367
|
+
let n = y.getAccessors(e);
|
|
1368
|
+
if (n.length > 0) {
|
|
1369
|
+
let t = this.boundObservables = Object.create(null);
|
|
1370
|
+
for (let r = 0, i = n.length; r < i; ++r) {
|
|
1371
|
+
let i = n[r].name, a = e[i];
|
|
1372
|
+
a !== void 0 && (delete e[i], t[i] = a);
|
|
1373
|
+
}
|
|
1374
|
+
}
|
|
1375
|
+
}
|
|
1376
|
+
get isConnected() {
|
|
1377
|
+
return y.track(this, G), this.stage === 1;
|
|
1378
|
+
}
|
|
1379
|
+
get context() {
|
|
1380
|
+
return this.view?.context ?? b.default;
|
|
1381
|
+
}
|
|
1382
|
+
get isBound() {
|
|
1383
|
+
return this.view?.isBound ?? !1;
|
|
1384
|
+
}
|
|
1385
|
+
get sourceLifetime() {
|
|
1386
|
+
return this.view?.sourceLifetime;
|
|
1387
|
+
}
|
|
1388
|
+
get template() {
|
|
1389
|
+
if (this._template === null) {
|
|
1390
|
+
let e = this.definition;
|
|
1391
|
+
this.source.resolveTemplate ? this._template = this.source.resolveTemplate() : e.template && (this._template = e.template ?? null);
|
|
1392
|
+
}
|
|
1393
|
+
return this._template;
|
|
1394
|
+
}
|
|
1395
|
+
set template(e) {
|
|
1396
|
+
this._template !== e && (this._template = e, this.needsInitialization || this.renderTemplate(e));
|
|
1397
|
+
}
|
|
1398
|
+
get shadowOptions() {
|
|
1399
|
+
return this._shadowRootOptions;
|
|
1400
|
+
}
|
|
1401
|
+
set shadowOptions(e) {
|
|
1402
|
+
if (this._shadowRootOptions === void 0 && e !== void 0) {
|
|
1403
|
+
this._shadowRootOptions = e;
|
|
1404
|
+
let t = this.source.shadowRoot;
|
|
1405
|
+
t ? this.hasExistingShadowRoot = !0 : (t = this.source.attachShadow(e), e.mode === "closed" && yt.set(this.source, t));
|
|
1406
|
+
}
|
|
1407
|
+
}
|
|
1408
|
+
get mainStyles() {
|
|
1409
|
+
if (this._mainStyles === null) {
|
|
1410
|
+
let e = this.definition;
|
|
1411
|
+
this.source.resolveStyles ? this._mainStyles = this.source.resolveStyles() : e.styles && (this._mainStyles = e.styles ?? null);
|
|
1412
|
+
}
|
|
1413
|
+
return this._mainStyles;
|
|
1414
|
+
}
|
|
1415
|
+
set mainStyles(e) {
|
|
1416
|
+
this._mainStyles !== e && (this._mainStyles !== null && this.removeStyles(this._mainStyles), this._mainStyles = e, this.needsInitialization || this.addStyles(e));
|
|
1417
|
+
}
|
|
1418
|
+
onUnbind(e) {
|
|
1419
|
+
var t;
|
|
1420
|
+
(t = this.view) == null || t.onUnbind(e);
|
|
1421
|
+
}
|
|
1422
|
+
addBehavior(e) {
|
|
1423
|
+
let t = this.behaviors ??= /* @__PURE__ */ new Map(), n = t.get(e) ?? 0;
|
|
1424
|
+
n === 0 ? (t.set(e, 1), e.addedCallback && e.addedCallback(this), e.connectedCallback && !this.guardBehaviorConnection && (this.stage === 1 || this.stage === 0) && e.connectedCallback(this)) : t.set(e, n + 1);
|
|
1425
|
+
}
|
|
1426
|
+
removeBehavior(e, t = !1) {
|
|
1427
|
+
let n = this.behaviors;
|
|
1428
|
+
if (n === null) return;
|
|
1429
|
+
let r = n.get(e);
|
|
1430
|
+
r !== void 0 && (r === 1 || t ? (n.delete(e), e.disconnectedCallback && this.stage !== 3 && e.disconnectedCallback(this), e.removedCallback && e.removedCallback(this)) : n.set(e, r - 1));
|
|
1431
|
+
}
|
|
1432
|
+
addStyles(e) {
|
|
1433
|
+
if (!e) return;
|
|
1434
|
+
let t = this.source;
|
|
1435
|
+
if (e instanceof HTMLElement) (K(t) ?? this.source).append(e);
|
|
1436
|
+
else if (!e.isAttachedTo(t)) {
|
|
1437
|
+
let n = e.behaviors;
|
|
1438
|
+
if (e.addStylesTo(t), n !== null) for (let e = 0, t = n.length; e < t; ++e) this.addBehavior(n[e]);
|
|
1439
|
+
}
|
|
1440
|
+
}
|
|
1441
|
+
removeStyles(e) {
|
|
1442
|
+
if (!e) return;
|
|
1443
|
+
let t = this.source;
|
|
1444
|
+
if (e instanceof HTMLElement) (K(t) ?? t).removeChild(e);
|
|
1445
|
+
else if (e.isAttachedTo(t)) {
|
|
1446
|
+
let n = e.behaviors;
|
|
1447
|
+
if (e.removeStylesFrom(t), n !== null) for (let e = 0, t = n.length; e < t; ++e) this.removeBehavior(n[e]);
|
|
1448
|
+
}
|
|
1449
|
+
}
|
|
1450
|
+
connect() {
|
|
1451
|
+
this.stage === 3 && (this.stage = 0, this.bindObservables(), this.connectBehaviors(), this.needsInitialization ? (this.renderTemplate(this.template), this.addStyles(this.mainStyles), this.needsInitialization = !1) : this.view !== null && this.view.bind(this.source), this.stage = 1, y.notify(this, G));
|
|
1452
|
+
}
|
|
1453
|
+
bindObservables() {
|
|
1454
|
+
if (this.boundObservables !== null) {
|
|
1455
|
+
let e = this.source, t = this.boundObservables, n = Object.keys(t);
|
|
1456
|
+
for (let r = 0, i = n.length; r < i; ++r) {
|
|
1457
|
+
let i = n[r];
|
|
1458
|
+
e[i] = t[i];
|
|
1459
|
+
}
|
|
1460
|
+
this.boundObservables = null;
|
|
1461
|
+
}
|
|
1462
|
+
}
|
|
1463
|
+
connectBehaviors() {
|
|
1464
|
+
if (this.behaviorsConnected === !1) {
|
|
1465
|
+
let e = this.behaviors;
|
|
1466
|
+
if (e !== null) {
|
|
1467
|
+
this.guardBehaviorConnection = !0;
|
|
1468
|
+
for (let t of e.keys()) t.connectedCallback && t.connectedCallback(this);
|
|
1469
|
+
this.guardBehaviorConnection = !1;
|
|
1470
|
+
}
|
|
1471
|
+
this.behaviorsConnected = !0;
|
|
1472
|
+
}
|
|
1473
|
+
}
|
|
1474
|
+
disconnectBehaviors() {
|
|
1475
|
+
if (this.behaviorsConnected === !0) {
|
|
1476
|
+
let e = this.behaviors;
|
|
1477
|
+
if (e !== null) for (let t of e.keys()) t.disconnectedCallback && t.disconnectedCallback(this);
|
|
1478
|
+
this.behaviorsConnected = !1;
|
|
1479
|
+
}
|
|
1480
|
+
}
|
|
1481
|
+
disconnect() {
|
|
1482
|
+
this.stage === 1 && (this.stage = 2, y.notify(this, G), this.view !== null && this.view.unbind(), this.disconnectBehaviors(), this.stage = 3);
|
|
1483
|
+
}
|
|
1484
|
+
onAttributeChangedCallback(e, t, n) {
|
|
1485
|
+
let r = this.definition.attributeLookup[e];
|
|
1486
|
+
r !== void 0 && r.onAttributeChangedCallback(this.source, n);
|
|
1487
|
+
}
|
|
1488
|
+
emit(e, t, n) {
|
|
1489
|
+
return this.stage === 1 ? this.source.dispatchEvent(new CustomEvent(e, Object.assign(Object.assign({ detail: t }, vt), n))) : !1;
|
|
1490
|
+
}
|
|
1491
|
+
renderTemplate(e) {
|
|
1492
|
+
let t = this.source, n = K(t) ?? t;
|
|
1493
|
+
if (this.view !== null) this.view.dispose(), this.view = null;
|
|
1494
|
+
else if (!this.needsInitialization || this.hasExistingShadowRoot) {
|
|
1495
|
+
this.hasExistingShadowRoot = !1;
|
|
1496
|
+
for (let e = n.firstChild; e !== null; e = n.firstChild) n.removeChild(e);
|
|
1497
|
+
}
|
|
1498
|
+
e && (this.view = e.render(t, n, t), this.view.sourceLifetime = v.coupled);
|
|
1499
|
+
}
|
|
1500
|
+
static forCustomElement(t, n = !1) {
|
|
1501
|
+
let r = t.$fastController;
|
|
1502
|
+
if (r !== void 0 && !n) return r;
|
|
1503
|
+
let i = W.getForInstance(t);
|
|
1504
|
+
if (i === void 0) throw s.error(1401);
|
|
1505
|
+
return y.getNotifier(i).subscribe({ handleChange: () => {
|
|
1506
|
+
e.forCustomElement(t, !0), t.$fastController.connect();
|
|
1507
|
+
} }, "template"), y.getNotifier(i).subscribe({ handleChange: () => {
|
|
1508
|
+
e.forCustomElement(t, !0), t.$fastController.connect();
|
|
1509
|
+
} }, "shadowOptions"), t.$fastController = new bt(t, i);
|
|
1510
|
+
}
|
|
1511
|
+
static setStrategy(e) {
|
|
1512
|
+
bt = e;
|
|
1513
|
+
}
|
|
1514
|
+
};
|
|
1515
|
+
d(q), q.setStrategy(q);
|
|
1516
|
+
function J(e) {
|
|
1517
|
+
return "adoptedStyleSheets" in e ? e : K(e) ?? e.getRootNode();
|
|
1518
|
+
}
|
|
1519
|
+
var xt = class e {
|
|
1520
|
+
constructor(t) {
|
|
1521
|
+
let n = e.styleSheetCache;
|
|
1522
|
+
this.sheets = t.map((e) => {
|
|
1523
|
+
if (e instanceof CSSStyleSheet) return e;
|
|
1524
|
+
let t = n.get(e);
|
|
1525
|
+
return t === void 0 && (t = new CSSStyleSheet(), t.replaceSync(e), n.set(e, t)), t;
|
|
1526
|
+
});
|
|
1527
|
+
}
|
|
1528
|
+
addStylesTo(e) {
|
|
1529
|
+
Et(J(e), this.sheets);
|
|
1530
|
+
}
|
|
1531
|
+
removeStylesFrom(e) {
|
|
1532
|
+
Dt(J(e), this.sheets);
|
|
1533
|
+
}
|
|
1534
|
+
};
|
|
1535
|
+
xt.styleSheetCache = /* @__PURE__ */ new Map();
|
|
1536
|
+
var St = 0, Ct = () => `fast-${++St}`;
|
|
1537
|
+
function wt(e) {
|
|
1538
|
+
return e === document ? document.body : e;
|
|
1539
|
+
}
|
|
1540
|
+
var Tt = class {
|
|
1541
|
+
constructor(e) {
|
|
1542
|
+
this.styles = e, this.styleClass = Ct();
|
|
1543
|
+
}
|
|
1544
|
+
addStylesTo(e) {
|
|
1545
|
+
e = wt(J(e));
|
|
1546
|
+
let t = this.styles, n = this.styleClass;
|
|
1547
|
+
for (let r = 0; r < t.length; r++) {
|
|
1548
|
+
let i = document.createElement("style");
|
|
1549
|
+
i.innerHTML = t[r], i.className = n, e.append(i);
|
|
1550
|
+
}
|
|
1551
|
+
}
|
|
1552
|
+
removeStylesFrom(e) {
|
|
1553
|
+
e = wt(J(e));
|
|
1554
|
+
let t = e.querySelectorAll(`.${this.styleClass}`);
|
|
1555
|
+
for (let n = 0, r = t.length; n < r; ++n) e.removeChild(t[n]);
|
|
1556
|
+
}
|
|
1557
|
+
}, Et = (e, t) => {
|
|
1558
|
+
e.adoptedStyleSheets = [...e.adoptedStyleSheets, ...t];
|
|
1559
|
+
}, Dt = (e, t) => {
|
|
1560
|
+
e.adoptedStyleSheets = e.adoptedStyleSheets.filter((e) => t.indexOf(e) === -1);
|
|
1561
|
+
};
|
|
1562
|
+
if (S.supportsAdoptedStyleSheets) {
|
|
1563
|
+
try {
|
|
1564
|
+
document.adoptedStyleSheets.push(), document.adoptedStyleSheets.splice(), Et = (e, t) => {
|
|
1565
|
+
e.adoptedStyleSheets.push(...t);
|
|
1566
|
+
}, Dt = (e, t) => {
|
|
1567
|
+
for (let n of t) {
|
|
1568
|
+
let t = e.adoptedStyleSheets.indexOf(n);
|
|
1569
|
+
t !== -1 && e.adoptedStyleSheets.splice(t, 1);
|
|
1570
|
+
}
|
|
1571
|
+
};
|
|
1572
|
+
} catch {}
|
|
1573
|
+
S.setDefaultStrategy(xt);
|
|
1574
|
+
} else S.setDefaultStrategy(Tt);
|
|
1575
|
+
var Ot = "defer-hydration", kt = "needs-hydration", Y = class e extends q {
|
|
1576
|
+
get shadowOptions() {
|
|
1577
|
+
return super.shadowOptions;
|
|
1578
|
+
}
|
|
1579
|
+
set shadowOptions(e) {
|
|
1580
|
+
super.shadowOptions = e, (this.hasExistingShadowRoot || e !== void 0 && !this.template) && this.definition.templateOptions === ht.deferAndHydrate && (this.source.toggleAttribute(Ot, !0), this.source.toggleAttribute(kt, !0));
|
|
1581
|
+
}
|
|
1582
|
+
addHydratingInstance() {
|
|
1583
|
+
if (!e.hydratingInstances) return;
|
|
1584
|
+
let t = this.definition.name, n = e.hydratingInstances.get(t);
|
|
1585
|
+
n || (n = /* @__PURE__ */ new Set(), e.hydratingInstances.set(t, n)), n.add(this.source);
|
|
1586
|
+
}
|
|
1587
|
+
static config(t) {
|
|
1588
|
+
return e.lifecycleCallbacks = t, this;
|
|
1589
|
+
}
|
|
1590
|
+
static hydrationObserverHandler(t) {
|
|
1591
|
+
for (let n of t) n.target.hasAttribute("defer-hydration") || (e.hydrationObserver.unobserve(n.target), n.target.$fastController.connect());
|
|
1592
|
+
}
|
|
1593
|
+
static checkHydrationComplete(t) {
|
|
1594
|
+
var n, r;
|
|
1595
|
+
if (t.didTimeout) {
|
|
1596
|
+
e.idleCallbackId = requestIdleCallback(e.checkHydrationComplete, { timeout: 50 });
|
|
1597
|
+
return;
|
|
1598
|
+
}
|
|
1599
|
+
e.hydratingInstances?.size === 0 && ((r = (n = e.lifecycleCallbacks)?.hydrationComplete) == null || r.call(n), q.setStrategy(q));
|
|
1600
|
+
}
|
|
1601
|
+
connect() {
|
|
1602
|
+
var t, n, r;
|
|
1603
|
+
if (this.needsHydration = this.needsHydration ?? this.source.hasAttribute(kt), this.needsHydration && ((n = (t = e.lifecycleCallbacks)?.elementWillHydrate) == null || n.call(t, this.definition.name)), this.source.hasAttribute("defer-hydration")) {
|
|
1604
|
+
this.addHydratingInstance(), e.hydrationObserver.observe(this.source, { attributeFilter: [Ot] });
|
|
1605
|
+
return;
|
|
1606
|
+
}
|
|
1607
|
+
if (!this.needsHydration) {
|
|
1608
|
+
super.connect(), this.removeHydratingInstance();
|
|
1609
|
+
return;
|
|
1610
|
+
}
|
|
1611
|
+
if (this.stage === 3) {
|
|
1612
|
+
if (this.stage = 0, this.bindObservables(), this.connectBehaviors(), this.template) if (T(this.template)) {
|
|
1613
|
+
let e = this.source, t = K(e) ?? e, n = t.firstChild, i = t.lastChild;
|
|
1614
|
+
e.shadowRoot === null && (C.isElementBoundaryStartMarker(n) && (n.data = "", n = n.nextSibling), C.isElementBoundaryEndMarker(i) && (i.data = "", i = i.previousSibling)), this.view = this.template.hydrate(n, i, e), (r = this.view) == null || r.bind(this.source);
|
|
1615
|
+
} else this.renderTemplate(this.template);
|
|
1616
|
+
this.addStyles(this.mainStyles), this.stage = 1, this.source.removeAttribute(kt), this.needsInitialization = this.needsHydration = !1, this.removeHydratingInstance(), y.notify(this, G);
|
|
1617
|
+
}
|
|
1618
|
+
}
|
|
1619
|
+
removeHydratingInstance() {
|
|
1620
|
+
var t, n;
|
|
1621
|
+
if (!e.hydratingInstances) return;
|
|
1622
|
+
let r = this.definition.name, i = e.hydratingInstances.get(r);
|
|
1623
|
+
(n = (t = e.lifecycleCallbacks)?.elementDidHydrate) == null || n.call(t, this.definition.name), i && (i.delete(this.source), i.size || e.hydratingInstances.delete(r), e.idleCallbackId && cancelIdleCallback(e.idleCallbackId), e.idleCallbackId = requestIdleCallback(e.checkHydrationComplete, { timeout: 50 }));
|
|
1624
|
+
}
|
|
1625
|
+
disconnect() {
|
|
1626
|
+
super.disconnect(), e.hydrationObserver.unobserve(this.source);
|
|
1627
|
+
}
|
|
1628
|
+
static install() {
|
|
1629
|
+
q.setStrategy(e);
|
|
1630
|
+
}
|
|
1631
|
+
};
|
|
1632
|
+
Y.hydrationObserver = new gt(Y.hydrationObserverHandler), Y.idleCallbackId = null, Y.hydratingInstances = /* @__PURE__ */ new Map();
|
|
1633
|
+
//#endregion
|
|
1634
|
+
//#region ../../node_modules/.pnpm/@microsoft+fast-element@2.8.3/node_modules/@microsoft/fast-element/dist/esm/components/fast-element.js
|
|
1635
|
+
function At(e) {
|
|
1636
|
+
let t = class extends e {
|
|
1637
|
+
constructor() {
|
|
1638
|
+
super(), q.forCustomElement(this);
|
|
1639
|
+
}
|
|
1640
|
+
$emit(e, t, n) {
|
|
1641
|
+
return this.$fastController.emit(e, t, n);
|
|
1642
|
+
}
|
|
1643
|
+
connectedCallback() {
|
|
1644
|
+
this.$fastController.connect();
|
|
1645
|
+
}
|
|
1646
|
+
disconnectedCallback() {
|
|
1647
|
+
this.$fastController.disconnect();
|
|
1648
|
+
}
|
|
1649
|
+
attributeChangedCallback(e, t, n) {
|
|
1650
|
+
this.$fastController.onAttributeChangedCallback(e, t, n);
|
|
1651
|
+
}
|
|
1652
|
+
};
|
|
1653
|
+
return W.registerBaseType(t), t;
|
|
1654
|
+
}
|
|
1655
|
+
function jt(e, t) {
|
|
1656
|
+
return r(e) ? W.compose(e, t) : W.compose(this, e);
|
|
1657
|
+
}
|
|
1658
|
+
function Mt(e, t) {
|
|
1659
|
+
return r(e) ? new Promise((n) => {
|
|
1660
|
+
W.composeAsync(e, t).then((e) => {
|
|
1661
|
+
n(e);
|
|
1662
|
+
});
|
|
1663
|
+
}).then((e) => e.define().type) : new Promise((t) => {
|
|
1664
|
+
W.composeAsync(this, e).then((e) => {
|
|
1665
|
+
t(e);
|
|
1666
|
+
});
|
|
1667
|
+
}).then((e) => e.define().type);
|
|
1668
|
+
}
|
|
1669
|
+
function Nt(e, t) {
|
|
1670
|
+
return r(e) ? W.compose(e, t).define().type : W.compose(this, e).define().type;
|
|
1671
|
+
}
|
|
1672
|
+
function Pt(e) {
|
|
1673
|
+
return At(e);
|
|
1674
|
+
}
|
|
1675
|
+
var Ft = Object.assign(At(HTMLElement), {
|
|
1676
|
+
from: Pt,
|
|
1677
|
+
define: Nt,
|
|
1678
|
+
compose: jt,
|
|
1679
|
+
defineAsync: Mt
|
|
1680
|
+
});
|
|
1681
|
+
//#endregion
|
|
1682
|
+
//#region src/shared/design-system/createRegisterFunction.ts
|
|
1683
|
+
function It(e, t) {
|
|
1684
|
+
return e instanceof Function ? e(t) : e;
|
|
1685
|
+
}
|
|
1686
|
+
var Lt = /* @__PURE__ */ new Set(), X = /* @__PURE__ */ new Map(), Rt = (e) => (t = "vwc") => {
|
|
1687
|
+
let n = (e) => `${t}-${e}`, r = (e) => {
|
|
1688
|
+
let i = n(e.name), a = e.type;
|
|
1689
|
+
if (a.componentName = e.name, Lt.has(i)) return;
|
|
1690
|
+
X.has(a) && X.get(a) !== i && (a = class extends a {}), Lt.add(i), X.set(a, i);
|
|
1691
|
+
for (let t of e.dependencies) r(t);
|
|
1692
|
+
let o = new Map([[e.type, i], ...e.dependencies.map((e) => [e.type, n(e.name)])]), s = {
|
|
1693
|
+
tagFor: (t, n) => {
|
|
1694
|
+
if (!o.has(t)) throw Error(`Could not get tag for ${t.name} as it is not a dependency of ${e.name}.`);
|
|
1695
|
+
let r = o.get(t);
|
|
1696
|
+
return n ? r : V.partial(r);
|
|
1697
|
+
},
|
|
1698
|
+
tagForNonDependency(e) {
|
|
1699
|
+
return n(e);
|
|
1700
|
+
}
|
|
1701
|
+
};
|
|
1702
|
+
W.compose(a, {
|
|
1703
|
+
...e.options,
|
|
1704
|
+
template: It(e.template, s),
|
|
1705
|
+
name: `${t}-${e.name}`
|
|
1706
|
+
}).define();
|
|
1707
|
+
};
|
|
1708
|
+
r(e);
|
|
1709
|
+
}, zt = (e, t, n, r, i) => ({
|
|
1710
|
+
name: e,
|
|
1711
|
+
type: t,
|
|
1712
|
+
template: n,
|
|
1713
|
+
dependencies: r,
|
|
1714
|
+
options: i
|
|
1715
|
+
}), Bt = /* @__PURE__ */ new WeakMap(), Vt = (e) => {
|
|
1716
|
+
let t = Bt.get(e);
|
|
1717
|
+
return t || (t = [], Bt.set(e, t)), t;
|
|
1718
|
+
}, Ht = (e, t) => {
|
|
1719
|
+
Vt(e).push(t);
|
|
1720
|
+
}, Ut = (e, t) => {
|
|
1721
|
+
Vt(e).forEach((n) => n(e, t));
|
|
1722
|
+
}, Wt = (e) => e === "delegate", Gt = (e) => `vvd${e.charAt(0).toUpperCase()}${e.slice(1)}`, Kt = (e, t) => {
|
|
1723
|
+
if (Wt(e._vividAriaBehaviour)) {
|
|
1724
|
+
let n = e[t];
|
|
1725
|
+
e[`_${t}`] = null, e.removeAttribute($(t)), e[`_${t}`] = n, e[t] === null ? delete e.dataset[Gt(t)] : e.dataset[Gt(t)] = e[t];
|
|
1726
|
+
} else h.setAttribute(e, $(t), e[t]);
|
|
1727
|
+
}, Z = /* @__PURE__ */ new WeakMap(), qt = (e, t) => {
|
|
1728
|
+
let n = Z.get(e);
|
|
1729
|
+
n ? n.add(t) : Z.set(e, new Set([t]));
|
|
1730
|
+
}, Jt = (e, t) => {
|
|
1731
|
+
e.isConnected ? Kt(e, t) : qt(e, t);
|
|
1732
|
+
}, Yt = (e) => {
|
|
1733
|
+
let t = Z.get(e);
|
|
1734
|
+
if (t) {
|
|
1735
|
+
for (let n of t) Kt(e, n);
|
|
1736
|
+
Z.delete(e);
|
|
1737
|
+
}
|
|
1738
|
+
}, Q = /* @__PURE__ */ "role.ariaAtomic.ariaAutoComplete.ariaBusy.ariaChecked.ariaColCount.ariaColIndex.ariaColIndexText.ariaColSpan.ariaCurrent.ariaDescription.ariaDisabled.ariaExpanded.ariaHasPopup.ariaHidden.ariaInvalid.ariaKeyShortcuts.ariaLabel.ariaLevel.ariaLive.ariaModal.ariaMultiLine.ariaMultiSelectable.ariaOrientation.ariaPlaceholder.ariaPosInSet.ariaPressed.ariaReadOnly.ariaRequired.ariaRoleDescription.ariaRowCount.ariaRowIndex.ariaRowIndexText.ariaRowSpan.ariaSelected.ariaSetSize.ariaSort.ariaValueMax.ariaValueMin.ariaValueNow.ariaValueText.ariaRelevant".split("."), $ = (e) => e.replace("aria", "aria-").toLowerCase(), Xt = (e) => {
|
|
1739
|
+
class t extends e {
|
|
1740
|
+
constructor(...e) {
|
|
1741
|
+
super(...e), this._vividAriaBehaviour = "default";
|
|
1742
|
+
for (let e of Q) this[`_${e}`] = null;
|
|
1743
|
+
}
|
|
1744
|
+
connectedCallback() {
|
|
1745
|
+
super.connectedCallback(), Yt(this);
|
|
1746
|
+
}
|
|
1747
|
+
}
|
|
1748
|
+
for (let e of Q) dt({
|
|
1749
|
+
attribute: $(e),
|
|
1750
|
+
mode: "fromView"
|
|
1751
|
+
})(t.prototype, e), t.prototype[`${e}Changed`] = function() {
|
|
1752
|
+
Jt(this, e), this._vividAriaBehaviour !== "default" && Ut(this, e);
|
|
1753
|
+
};
|
|
1754
|
+
return t;
|
|
1755
|
+
};
|
|
1756
|
+
//#endregion
|
|
1757
|
+
//#region src/shared/deprecation/replaced-props.ts
|
|
1758
|
+
function Zt() {
|
|
1759
|
+
let e = /* @__PURE__ */ new WeakMap();
|
|
1760
|
+
return (t) => (e.has(t) || e.set(t, []), e.get(t));
|
|
1761
|
+
}
|
|
1762
|
+
var Qt = Zt(), $t = (e) => (t, n) => {
|
|
1763
|
+
Qt(t.constructor).push({
|
|
1764
|
+
newPropertyName: n,
|
|
1765
|
+
...e
|
|
1766
|
+
});
|
|
1767
|
+
}, en = (e) => {
|
|
1768
|
+
class t extends e {
|
|
1769
|
+
#e(e) {
|
|
1770
|
+
let t = !1, n = !1, r = (t) => n && e.fromDeprecated(t[e.deprecatedPropertyName]) === t[e.newPropertyName], i = (n) => t && e.toDeprecated && e.toDeprecated(n[e.newPropertyName]) === n[e.deprecatedPropertyName], a = { handleChange(a, o) {
|
|
1771
|
+
if (o === e.newPropertyName) {
|
|
1772
|
+
if (t = !0, !e.toDeprecated || r(a)) return;
|
|
1773
|
+
a[e.deprecatedPropertyName] = e.toDeprecated(a[e.newPropertyName]);
|
|
1774
|
+
}
|
|
1775
|
+
if (o === e.deprecatedPropertyName) {
|
|
1776
|
+
if (n = !0, i(a)) return;
|
|
1777
|
+
a[e.newPropertyName] = e.fromDeprecated(a[e.deprecatedPropertyName]);
|
|
1778
|
+
}
|
|
1779
|
+
} }, o = y.getNotifier(this);
|
|
1780
|
+
o.subscribe(a, e.newPropertyName), o.subscribe(a, e.deprecatedPropertyName);
|
|
1781
|
+
}
|
|
1782
|
+
constructor(...e) {
|
|
1783
|
+
super(...e);
|
|
1784
|
+
for (let e of Qt(this.constructor)) this.#e(e);
|
|
1785
|
+
}
|
|
1786
|
+
}
|
|
1787
|
+
return t;
|
|
1788
|
+
}, tn = class extends Xt(en(Ft)) {
|
|
1789
|
+
static {
|
|
1790
|
+
this.VIVID_VERSION = "5.16.0";
|
|
1791
|
+
}
|
|
1792
|
+
connectedCallback() {
|
|
1793
|
+
super.connectedCallback();
|
|
1794
|
+
let e = this.constructor.componentName;
|
|
1795
|
+
this.setAttribute("data-vvd-component", e);
|
|
1796
|
+
}
|
|
2815
1797
|
};
|
|
1798
|
+
//#endregion
|
|
1799
|
+
export { c as A, b as C, _ as D, ie as E, i as M, a as N, g as O, x as S, re as T, C as _, Ht as a, le as b, _t as c, V as d, F as f, Te as g, Ee as h, Q as i, r as j, h as k, dt as l, j as m, $t as n, zt as o, I as p, $ as r, Rt as s, tn as t, lt as u, T as v, y as w, se as x, S as y };
|