@mintplayer/ng-bootstrap 21.31.0 → 21.33.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/package.json +1 -373
- package/fesm2022/mintplayer-ng-bootstrap-a11y.mjs +0 -455
- package/fesm2022/mintplayer-ng-bootstrap-a11y.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-accordion.mjs +0 -94
- package/fesm2022/mintplayer-ng-bootstrap-accordion.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-alert.mjs +0 -45
- package/fesm2022/mintplayer-ng-bootstrap-alert.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-badge.mjs +0 -24
- package/fesm2022/mintplayer-ng-bootstrap-badge.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-breadcrumb.mjs +0 -35
- package/fesm2022/mintplayer-ng-bootstrap-breadcrumb.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-button-group.mjs +0 -21
- package/fesm2022/mintplayer-ng-bootstrap-button-group.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-button-type.mjs +0 -36
- package/fesm2022/mintplayer-ng-bootstrap-button-type.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-calendar-month.mjs +0 -136
- package/fesm2022/mintplayer-ng-bootstrap-calendar-month.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-calendar.mjs +0 -210
- package/fesm2022/mintplayer-ng-bootstrap-calendar.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-card.mjs +0 -33
- package/fesm2022/mintplayer-ng-bootstrap-card.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-carousel.mjs +0 -270
- package/fesm2022/mintplayer-ng-bootstrap-carousel.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-close.mjs +0 -25
- package/fesm2022/mintplayer-ng-bootstrap-close.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-code-snippet.mjs +0 -44
- package/fesm2022/mintplayer-ng-bootstrap-code-snippet.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-color-picker.mjs +0 -654
- package/fesm2022/mintplayer-ng-bootstrap-color-picker.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-container.mjs +0 -18
- package/fesm2022/mintplayer-ng-bootstrap-container.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-context-menu.mjs +0 -88
- package/fesm2022/mintplayer-ng-bootstrap-context-menu.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-copy.mjs +0 -46
- package/fesm2022/mintplayer-ng-bootstrap-copy.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-datatable.mjs +0 -181
- package/fesm2022/mintplayer-ng-bootstrap-datatable.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-datepicker.mjs +0 -30
- package/fesm2022/mintplayer-ng-bootstrap-datepicker.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-dock.mjs +0 -4101
- package/fesm2022/mintplayer-ng-bootstrap-dock.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-dropdown-divider.mjs +0 -23
- package/fesm2022/mintplayer-ng-bootstrap-dropdown-divider.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-dropdown-menu.mjs +0 -195
- package/fesm2022/mintplayer-ng-bootstrap-dropdown-menu.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-dropdown.mjs +0 -326
- package/fesm2022/mintplayer-ng-bootstrap-dropdown.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-enhanced-paste.mjs +0 -62
- package/fesm2022/mintplayer-ng-bootstrap-enhanced-paste.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-enum.mjs +0 -38
- package/fesm2022/mintplayer-ng-bootstrap-enum.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-file-upload.mjs +0 -135
- package/fesm2022/mintplayer-ng-bootstrap-file-upload.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-floating-labels.mjs +0 -25
- package/fesm2022/mintplayer-ng-bootstrap-floating-labels.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-font-color.mjs +0 -34
- package/fesm2022/mintplayer-ng-bootstrap-font-color.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-for.mjs +0 -41
- package/fesm2022/mintplayer-ng-bootstrap-for.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-form.mjs +0 -59
- package/fesm2022/mintplayer-ng-bootstrap-form.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-grid.mjs +0 -122
- package/fesm2022/mintplayer-ng-bootstrap-grid.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-has-id.mjs +0 -4
- package/fesm2022/mintplayer-ng-bootstrap-has-id.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-has-overlay.mjs +0 -32
- package/fesm2022/mintplayer-ng-bootstrap-has-overlay.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-has-property.mjs +0 -23
- package/fesm2022/mintplayer-ng-bootstrap-has-property.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-in-list.mjs +0 -23
- package/fesm2022/mintplayer-ng-bootstrap-in-list.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-input-group.mjs +0 -18
- package/fesm2022/mintplayer-ng-bootstrap-input-group.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-instance-of.mjs +0 -183
- package/fesm2022/mintplayer-ng-bootstrap-instance-of.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-let.mjs +0 -46
- package/fesm2022/mintplayer-ng-bootstrap-let.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-linify.mjs +0 -28
- package/fesm2022/mintplayer-ng-bootstrap-linify.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-list-group.mjs +0 -33
- package/fesm2022/mintplayer-ng-bootstrap-list-group.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-markdown.mjs +0 -118
- package/fesm2022/mintplayer-ng-bootstrap-markdown.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-marquee.mjs +0 -21
- package/fesm2022/mintplayer-ng-bootstrap-marquee.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-modal.mjs +0 -240
- package/fesm2022/mintplayer-ng-bootstrap-modal.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-multi-range.mjs +0 -693
- package/fesm2022/mintplayer-ng-bootstrap-multi-range.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-multiselect.mjs +0 -136
- package/fesm2022/mintplayer-ng-bootstrap-multiselect.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-navbar-toggler.mjs +0 -29
- package/fesm2022/mintplayer-ng-bootstrap-navbar-toggler.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-navbar.mjs +0 -629
- package/fesm2022/mintplayer-ng-bootstrap-navbar.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-navigation-lock.mjs +0 -205
- package/fesm2022/mintplayer-ng-bootstrap-navigation-lock.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-no-noscript.mjs +0 -31
- package/fesm2022/mintplayer-ng-bootstrap-no-noscript.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-offcanvas.mjs +0 -366
- package/fesm2022/mintplayer-ng-bootstrap-offcanvas.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-ordinal-number.mjs +0 -36
- package/fesm2022/mintplayer-ng-bootstrap-ordinal-number.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-pagination.mjs +0 -188
- package/fesm2022/mintplayer-ng-bootstrap-pagination.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-parallax.mjs +0 -26
- package/fesm2022/mintplayer-ng-bootstrap-parallax.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-placeholder.mjs +0 -64
- package/fesm2022/mintplayer-ng-bootstrap-placeholder.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-playlist-toggler.mjs +0 -29
- package/fesm2022/mintplayer-ng-bootstrap-playlist-toggler.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-popover.mjs +0 -246
- package/fesm2022/mintplayer-ng-bootstrap-popover.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-priority-nav.mjs +0 -250
- package/fesm2022/mintplayer-ng-bootstrap-priority-nav.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-progress-bar.mjs +0 -68
- package/fesm2022/mintplayer-ng-bootstrap-progress-bar.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-range.mjs +0 -75
- package/fesm2022/mintplayer-ng-bootstrap-range.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-rating.mjs +0 -79
- package/fesm2022/mintplayer-ng-bootstrap-rating.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-reduced-motion.mjs +0 -59
- package/fesm2022/mintplayer-ng-bootstrap-reduced-motion.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-resizable.mjs +0 -387
- package/fesm2022/mintplayer-ng-bootstrap-resizable.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-scheduler.mjs +0 -237
- package/fesm2022/mintplayer-ng-bootstrap-scheduler.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-scrollspy.mjs +0 -120
- package/fesm2022/mintplayer-ng-bootstrap-scrollspy.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-searchbox.mjs +0 -194
- package/fesm2022/mintplayer-ng-bootstrap-searchbox.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-select.mjs +0 -213
- package/fesm2022/mintplayer-ng-bootstrap-select.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-select2.mjs +0 -205
- package/fesm2022/mintplayer-ng-bootstrap-select2.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-shell.mjs +0 -52
- package/fesm2022/mintplayer-ng-bootstrap-shell.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-signature-pad.mjs +0 -76
- package/fesm2022/mintplayer-ng-bootstrap-signature-pad.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-slugify.mjs +0 -30
- package/fesm2022/mintplayer-ng-bootstrap-slugify.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-spinner.mjs +0 -26
- package/fesm2022/mintplayer-ng-bootstrap-spinner.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-split-string.mjs +0 -25
- package/fesm2022/mintplayer-ng-bootstrap-split-string.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-sticky-footer.mjs +0 -46
- package/fesm2022/mintplayer-ng-bootstrap-sticky-footer.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-tab-control.mjs +0 -124
- package/fesm2022/mintplayer-ng-bootstrap-tab-control.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-table.mjs +0 -40
- package/fesm2022/mintplayer-ng-bootstrap-table.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-tile-manager.mjs +0 -1446
- package/fesm2022/mintplayer-ng-bootstrap-tile-manager.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-timepicker.mjs +0 -104
- package/fesm2022/mintplayer-ng-bootstrap-timepicker.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-toast.mjs +0 -163
- package/fesm2022/mintplayer-ng-bootstrap-toast.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-toggle-button.mjs +0 -236
- package/fesm2022/mintplayer-ng-bootstrap-toggle-button.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-tooltip.mjs +0 -174
- package/fesm2022/mintplayer-ng-bootstrap-tooltip.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-treeview.mjs +0 -100
- package/fesm2022/mintplayer-ng-bootstrap-treeview.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-trust-html.mjs +0 -28
- package/fesm2022/mintplayer-ng-bootstrap-trust-html.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-typeahead.mjs +0 -111
- package/fesm2022/mintplayer-ng-bootstrap-typeahead.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-uc-first.mjs +0 -24
- package/fesm2022/mintplayer-ng-bootstrap-uc-first.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-user-agent.mjs +0 -94
- package/fesm2022/mintplayer-ng-bootstrap-user-agent.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-viewport.mjs +0 -48
- package/fesm2022/mintplayer-ng-bootstrap-viewport.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-virtual-datatable.mjs +0 -282
- package/fesm2022/mintplayer-ng-bootstrap-virtual-datatable.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-web-components-a11y.mjs +0 -74
- package/fesm2022/mintplayer-ng-bootstrap-web-components-a11y.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-web-components-scheduler-core.mjs +0 -1356
- package/fesm2022/mintplayer-ng-bootstrap-web-components-scheduler-core.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-web-components-scheduler.mjs +0 -5224
- package/fesm2022/mintplayer-ng-bootstrap-web-components-scheduler.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-web-components-splitter.mjs +0 -923
- package/fesm2022/mintplayer-ng-bootstrap-web-components-splitter.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-web-components-tab-control.mjs +0 -553
- package/fesm2022/mintplayer-ng-bootstrap-web-components-tab-control.mjs.map +0 -1
- package/fesm2022/mintplayer-ng-bootstrap-word-count.mjs +0 -34
- package/fesm2022/mintplayer-ng-bootstrap-word-count.mjs.map +0 -1
- package/types/mintplayer-ng-bootstrap-a11y.d.ts +0 -196
- package/types/mintplayer-ng-bootstrap-accordion.d.ts +0 -39
- package/types/mintplayer-ng-bootstrap-alert.d.ts +0 -21
- package/types/mintplayer-ng-bootstrap-badge.d.ts +0 -12
- package/types/mintplayer-ng-bootstrap-breadcrumb.d.ts +0 -14
- package/types/mintplayer-ng-bootstrap-button-group.d.ts +0 -9
- package/types/mintplayer-ng-bootstrap-button-type.d.ts +0 -12
- package/types/mintplayer-ng-bootstrap-calendar-month.d.ts +0 -54
- package/types/mintplayer-ng-bootstrap-calendar.d.ts +0 -57
- package/types/mintplayer-ng-bootstrap-card.d.ts +0 -15
- package/types/mintplayer-ng-bootstrap-carousel.d.ts +0 -121
- package/types/mintplayer-ng-bootstrap-close.d.ts +0 -10
- package/types/mintplayer-ng-bootstrap-code-snippet.d.ts +0 -20
- package/types/mintplayer-ng-bootstrap-color-picker.d.ts +0 -236
- package/types/mintplayer-ng-bootstrap-container.d.ts +0 -8
- package/types/mintplayer-ng-bootstrap-context-menu.d.ts +0 -21
- package/types/mintplayer-ng-bootstrap-copy.d.ts +0 -12
- package/types/mintplayer-ng-bootstrap-datatable.d.ts +0 -63
- package/types/mintplayer-ng-bootstrap-datepicker.d.ts +0 -13
- package/types/mintplayer-ng-bootstrap-dock.d.ts +0 -419
- package/types/mintplayer-ng-bootstrap-dropdown-divider.d.ts +0 -8
- package/types/mintplayer-ng-bootstrap-dropdown-menu.d.ts +0 -66
- package/types/mintplayer-ng-bootstrap-dropdown.d.ts +0 -102
- package/types/mintplayer-ng-bootstrap-enhanced-paste.d.ts +0 -20
- package/types/mintplayer-ng-bootstrap-enum.d.ts +0 -17
- package/types/mintplayer-ng-bootstrap-file-upload.d.ts +0 -51
- package/types/mintplayer-ng-bootstrap-floating-labels.d.ts +0 -9
- package/types/mintplayer-ng-bootstrap-font-color.d.ts +0 -10
- package/types/mintplayer-ng-bootstrap-for.d.ts +0 -13
- package/types/mintplayer-ng-bootstrap-form.d.ts +0 -24
- package/types/mintplayer-ng-bootstrap-grid.d.ts +0 -50
- package/types/mintplayer-ng-bootstrap-has-id.d.ts +0 -5
- package/types/mintplayer-ng-bootstrap-has-overlay.d.ts +0 -22
- package/types/mintplayer-ng-bootstrap-has-property.d.ts +0 -10
- package/types/mintplayer-ng-bootstrap-in-list.d.ts +0 -11
- package/types/mintplayer-ng-bootstrap-input-group.d.ts +0 -8
- package/types/mintplayer-ng-bootstrap-instance-of.d.ts +0 -74
- package/types/mintplayer-ng-bootstrap-let.d.ts +0 -44
- package/types/mintplayer-ng-bootstrap-linify.d.ts +0 -10
- package/types/mintplayer-ng-bootstrap-list-group.d.ts +0 -14
- package/types/mintplayer-ng-bootstrap-markdown.d.ts +0 -33
- package/types/mintplayer-ng-bootstrap-marquee.d.ts +0 -9
- package/types/mintplayer-ng-bootstrap-modal.d.ts +0 -82
- package/types/mintplayer-ng-bootstrap-multi-range.d.ts +0 -170
- package/types/mintplayer-ng-bootstrap-multiselect.d.ts +0 -58
- package/types/mintplayer-ng-bootstrap-navbar-toggler.d.ts +0 -13
- package/types/mintplayer-ng-bootstrap-navbar.d.ts +0 -189
- package/types/mintplayer-ng-bootstrap-navigation-lock.d.ts +0 -117
- package/types/mintplayer-ng-bootstrap-no-noscript.d.ts +0 -11
- package/types/mintplayer-ng-bootstrap-offcanvas.d.ts +0 -106
- package/types/mintplayer-ng-bootstrap-ordinal-number.d.ts +0 -12
- package/types/mintplayer-ng-bootstrap-pagination.d.ts +0 -40
- package/types/mintplayer-ng-bootstrap-parallax.d.ts +0 -11
- package/types/mintplayer-ng-bootstrap-placeholder.d.ts +0 -23
- package/types/mintplayer-ng-bootstrap-playlist-toggler.d.ts +0 -13
- package/types/mintplayer-ng-bootstrap-popover.d.ts +0 -67
- package/types/mintplayer-ng-bootstrap-priority-nav.d.ts +0 -64
- package/types/mintplayer-ng-bootstrap-progress-bar.d.ts +0 -27
- package/types/mintplayer-ng-bootstrap-range.d.ts +0 -28
- package/types/mintplayer-ng-bootstrap-rating.d.ts +0 -20
- package/types/mintplayer-ng-bootstrap-reduced-motion.d.ts +0 -36
- package/types/mintplayer-ng-bootstrap-resizable.d.ts +0 -89
- package/types/mintplayer-ng-bootstrap-scheduler.d.ts +0 -171
- package/types/mintplayer-ng-bootstrap-scrollspy.d.ts +0 -36
- package/types/mintplayer-ng-bootstrap-searchbox.d.ts +0 -65
- package/types/mintplayer-ng-bootstrap-select.d.ts +0 -65
- package/types/mintplayer-ng-bootstrap-select2.d.ts +0 -61
- package/types/mintplayer-ng-bootstrap-shell.d.ts +0 -26
- package/types/mintplayer-ng-bootstrap-signature-pad.d.ts +0 -36
- package/types/mintplayer-ng-bootstrap-slugify.d.ts +0 -10
- package/types/mintplayer-ng-bootstrap-spinner.d.ts +0 -14
- package/types/mintplayer-ng-bootstrap-split-string.d.ts +0 -10
- package/types/mintplayer-ng-bootstrap-sticky-footer.d.ts +0 -21
- package/types/mintplayer-ng-bootstrap-tab-control.d.ts +0 -50
- package/types/mintplayer-ng-bootstrap-table.d.ts +0 -24
- package/types/mintplayer-ng-bootstrap-tile-manager.d.ts +0 -304
- package/types/mintplayer-ng-bootstrap-timepicker.d.ts +0 -26
- package/types/mintplayer-ng-bootstrap-toast.d.ts +0 -67
- package/types/mintplayer-ng-bootstrap-toggle-button.d.ts +0 -57
- package/types/mintplayer-ng-bootstrap-tooltip.d.ts +0 -29
- package/types/mintplayer-ng-bootstrap-treeview.d.ts +0 -44
- package/types/mintplayer-ng-bootstrap-trust-html.d.ts +0 -12
- package/types/mintplayer-ng-bootstrap-typeahead.d.ts +0 -34
- package/types/mintplayer-ng-bootstrap-uc-first.d.ts +0 -10
- package/types/mintplayer-ng-bootstrap-user-agent.d.ts +0 -27
- package/types/mintplayer-ng-bootstrap-viewport.d.ts +0 -16
- package/types/mintplayer-ng-bootstrap-virtual-datatable.d.ts +0 -68
- package/types/mintplayer-ng-bootstrap-web-components-a11y.d.ts +0 -34
- package/types/mintplayer-ng-bootstrap-web-components-scheduler-core.d.ts +0 -914
- package/types/mintplayer-ng-bootstrap-web-components-scheduler.d.ts +0 -600
- package/types/mintplayer-ng-bootstrap-web-components-splitter.d.ts +0 -223
- package/types/mintplayer-ng-bootstrap-web-components-tab-control.d.ts +0 -95
- package/types/mintplayer-ng-bootstrap-word-count.d.ts +0 -10
|
@@ -1,923 +0,0 @@
|
|
|
1
|
-
import { unsafeCSS, LitElement, html } from 'lit';
|
|
2
|
-
|
|
3
|
-
var ResizeState;
|
|
4
|
-
(function (ResizeState) {
|
|
5
|
-
ResizeState["Idle"] = "idle";
|
|
6
|
-
ResizeState["Resizing"] = "resizing";
|
|
7
|
-
})(ResizeState || (ResizeState = {}));
|
|
8
|
-
|
|
9
|
-
class SplitterStateManager {
|
|
10
|
-
constructor(initialState) {
|
|
11
|
-
this.listeners = new Set();
|
|
12
|
-
this.state = {
|
|
13
|
-
orientation: 'horizontal',
|
|
14
|
-
panelSizes: [],
|
|
15
|
-
previewSizes: null,
|
|
16
|
-
resizeOperation: null,
|
|
17
|
-
...initialState,
|
|
18
|
-
};
|
|
19
|
-
}
|
|
20
|
-
getState() {
|
|
21
|
-
return { ...this.state };
|
|
22
|
-
}
|
|
23
|
-
subscribe(listener) {
|
|
24
|
-
this.listeners.add(listener);
|
|
25
|
-
return () => {
|
|
26
|
-
this.listeners.delete(listener);
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
notifyListeners() {
|
|
30
|
-
const stateCopy = this.getState();
|
|
31
|
-
for (const listener of this.listeners) {
|
|
32
|
-
listener(stateCopy);
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
setOrientation(orientation) {
|
|
36
|
-
if (this.state.orientation !== orientation) {
|
|
37
|
-
this.state = { ...this.state, orientation };
|
|
38
|
-
this.notifyListeners();
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
setPanelSizes(sizes) {
|
|
42
|
-
this.state = { ...this.state, panelSizes: [...sizes] };
|
|
43
|
-
this.notifyListeners();
|
|
44
|
-
}
|
|
45
|
-
setPreviewSizes(sizes) {
|
|
46
|
-
this.state = { ...this.state, previewSizes: sizes ? [...sizes] : null };
|
|
47
|
-
this.notifyListeners();
|
|
48
|
-
}
|
|
49
|
-
startResize(operation) {
|
|
50
|
-
this.state = {
|
|
51
|
-
...this.state,
|
|
52
|
-
resizeOperation: { ...operation },
|
|
53
|
-
};
|
|
54
|
-
this.notifyListeners();
|
|
55
|
-
}
|
|
56
|
-
updateResize(previewSizes) {
|
|
57
|
-
this.state = {
|
|
58
|
-
...this.state,
|
|
59
|
-
previewSizes: [...previewSizes],
|
|
60
|
-
};
|
|
61
|
-
this.notifyListeners();
|
|
62
|
-
}
|
|
63
|
-
endResize(finalSizes) {
|
|
64
|
-
this.state = {
|
|
65
|
-
...this.state,
|
|
66
|
-
panelSizes: [...finalSizes],
|
|
67
|
-
previewSizes: null,
|
|
68
|
-
resizeOperation: null,
|
|
69
|
-
};
|
|
70
|
-
this.notifyListeners();
|
|
71
|
-
}
|
|
72
|
-
cancelResize() {
|
|
73
|
-
this.state = {
|
|
74
|
-
...this.state,
|
|
75
|
-
previewSizes: null,
|
|
76
|
-
resizeOperation: null,
|
|
77
|
-
};
|
|
78
|
-
this.notifyListeners();
|
|
79
|
-
}
|
|
80
|
-
isResizing() {
|
|
81
|
-
return this.state.resizeOperation?.state === ResizeState.Resizing;
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
function normalizePointerEvent(event) {
|
|
86
|
-
const isTouch = 'touches' in event;
|
|
87
|
-
let clientX;
|
|
88
|
-
let clientY;
|
|
89
|
-
if (isTouch) {
|
|
90
|
-
const touch = event.touches[0] || event.changedTouches[0];
|
|
91
|
-
clientX = touch.clientX;
|
|
92
|
-
clientY = touch.clientY;
|
|
93
|
-
}
|
|
94
|
-
else {
|
|
95
|
-
clientX = event.clientX;
|
|
96
|
-
clientY = event.clientY;
|
|
97
|
-
}
|
|
98
|
-
return {
|
|
99
|
-
clientX,
|
|
100
|
-
clientY,
|
|
101
|
-
point: { x: clientX, y: clientY },
|
|
102
|
-
originalEvent: event,
|
|
103
|
-
isTouch,
|
|
104
|
-
};
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
const RESIZE_KEYS = new Set([
|
|
108
|
-
'ArrowLeft', 'ArrowRight', 'ArrowUp', 'ArrowDown', 'Home', 'End',
|
|
109
|
-
]);
|
|
110
|
-
class InputHandler {
|
|
111
|
-
constructor(callbacks) {
|
|
112
|
-
this.isActive = false;
|
|
113
|
-
this.currentDividerIndex = -1;
|
|
114
|
-
this.currentDividerElement = null;
|
|
115
|
-
this.callbacks = callbacks;
|
|
116
|
-
this.boundMouseMove = this.handleMouseMove.bind(this);
|
|
117
|
-
this.boundMouseUp = this.handleMouseUp.bind(this);
|
|
118
|
-
this.boundTouchMove = this.handleTouchMove.bind(this);
|
|
119
|
-
this.boundTouchEnd = this.handleTouchEnd.bind(this);
|
|
120
|
-
}
|
|
121
|
-
attachDividerListeners(divider, index) {
|
|
122
|
-
divider.addEventListener('mousedown', (e) => this.handleMouseDown(e, index, divider));
|
|
123
|
-
divider.addEventListener('touchstart', (e) => this.handleTouchStart(e, index, divider), { passive: false });
|
|
124
|
-
divider.addEventListener('keydown', (e) => this.handleKeyDown(e, index, divider));
|
|
125
|
-
}
|
|
126
|
-
handleKeyDown(event, dividerIndex, dividerElement) {
|
|
127
|
-
if (!this.callbacks.onResizeKey)
|
|
128
|
-
return;
|
|
129
|
-
if (!RESIZE_KEYS.has(event.key))
|
|
130
|
-
return;
|
|
131
|
-
event.preventDefault();
|
|
132
|
-
this.callbacks.onResizeKey(event.key, event.shiftKey, dividerIndex, dividerElement);
|
|
133
|
-
}
|
|
134
|
-
handleMouseDown(event, dividerIndex, dividerElement) {
|
|
135
|
-
event.preventDefault();
|
|
136
|
-
this.startResize(event, dividerIndex, dividerElement);
|
|
137
|
-
document.addEventListener('mousemove', this.boundMouseMove);
|
|
138
|
-
document.addEventListener('mouseup', this.boundMouseUp);
|
|
139
|
-
}
|
|
140
|
-
handleMouseMove(event) {
|
|
141
|
-
if (!this.isActive)
|
|
142
|
-
return;
|
|
143
|
-
event.preventDefault();
|
|
144
|
-
this.callbacks.onResizeMove(normalizePointerEvent(event));
|
|
145
|
-
}
|
|
146
|
-
handleMouseUp(event) {
|
|
147
|
-
if (!this.isActive)
|
|
148
|
-
return;
|
|
149
|
-
this.endResize(event);
|
|
150
|
-
document.removeEventListener('mousemove', this.boundMouseMove);
|
|
151
|
-
document.removeEventListener('mouseup', this.boundMouseUp);
|
|
152
|
-
}
|
|
153
|
-
handleTouchStart(event, dividerIndex, dividerElement) {
|
|
154
|
-
event.preventDefault();
|
|
155
|
-
this.startResize(event, dividerIndex, dividerElement);
|
|
156
|
-
document.addEventListener('touchmove', this.boundTouchMove, { passive: false });
|
|
157
|
-
document.addEventListener('touchend', this.boundTouchEnd);
|
|
158
|
-
document.addEventListener('touchcancel', this.boundTouchEnd);
|
|
159
|
-
}
|
|
160
|
-
handleTouchMove(event) {
|
|
161
|
-
if (!this.isActive)
|
|
162
|
-
return;
|
|
163
|
-
event.preventDefault();
|
|
164
|
-
this.callbacks.onResizeMove(normalizePointerEvent(event));
|
|
165
|
-
}
|
|
166
|
-
handleTouchEnd(event) {
|
|
167
|
-
if (!this.isActive)
|
|
168
|
-
return;
|
|
169
|
-
this.endResize(event);
|
|
170
|
-
document.removeEventListener('touchmove', this.boundTouchMove);
|
|
171
|
-
document.removeEventListener('touchend', this.boundTouchEnd);
|
|
172
|
-
document.removeEventListener('touchcancel', this.boundTouchEnd);
|
|
173
|
-
}
|
|
174
|
-
startResize(event, dividerIndex, dividerElement) {
|
|
175
|
-
this.isActive = true;
|
|
176
|
-
this.currentDividerIndex = dividerIndex;
|
|
177
|
-
this.currentDividerElement = dividerElement;
|
|
178
|
-
this.callbacks.onResizeStart(normalizePointerEvent(event), dividerIndex, dividerElement);
|
|
179
|
-
}
|
|
180
|
-
endResize(event) {
|
|
181
|
-
this.callbacks.onResizeEnd(normalizePointerEvent(event));
|
|
182
|
-
this.isActive = false;
|
|
183
|
-
this.currentDividerIndex = -1;
|
|
184
|
-
this.currentDividerElement = null;
|
|
185
|
-
}
|
|
186
|
-
dispose() {
|
|
187
|
-
document.removeEventListener('mousemove', this.boundMouseMove);
|
|
188
|
-
document.removeEventListener('mouseup', this.boundMouseUp);
|
|
189
|
-
document.removeEventListener('touchmove', this.boundTouchMove);
|
|
190
|
-
document.removeEventListener('touchend', this.boundTouchEnd);
|
|
191
|
-
document.removeEventListener('touchcancel', this.boundTouchEnd);
|
|
192
|
-
this.isActive = false;
|
|
193
|
-
this.currentDividerIndex = -1;
|
|
194
|
-
this.currentDividerElement = null;
|
|
195
|
-
}
|
|
196
|
-
getIsActive() {
|
|
197
|
-
return this.isActive;
|
|
198
|
-
}
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
class ResizeManager {
|
|
202
|
-
constructor(options = {}) {
|
|
203
|
-
this.options = {
|
|
204
|
-
minPanelSize: options.minPanelSize ?? 50,
|
|
205
|
-
};
|
|
206
|
-
}
|
|
207
|
-
computePanelSizes(panels, orientation) {
|
|
208
|
-
return panels.map((panel) => {
|
|
209
|
-
const rect = panel.getBoundingClientRect();
|
|
210
|
-
return orientation === 'horizontal' ? rect.width : rect.height;
|
|
211
|
-
});
|
|
212
|
-
}
|
|
213
|
-
createResizeOperation(startPoint, currentSizes, dividerIndex, dividerElement) {
|
|
214
|
-
return {
|
|
215
|
-
state: ResizeState.Resizing,
|
|
216
|
-
startPosition: { ...startPoint },
|
|
217
|
-
sizes: [...currentSizes],
|
|
218
|
-
indexBefore: dividerIndex,
|
|
219
|
-
indexAfter: dividerIndex + 1,
|
|
220
|
-
dividerElement,
|
|
221
|
-
};
|
|
222
|
-
}
|
|
223
|
-
calculatePreviewSizes(operation, currentPoint, orientation) {
|
|
224
|
-
const { startPosition, sizes, indexBefore, indexAfter } = operation;
|
|
225
|
-
const delta = orientation === 'horizontal'
|
|
226
|
-
? currentPoint.x - startPosition.x
|
|
227
|
-
: currentPoint.y - startPosition.y;
|
|
228
|
-
const newSizes = [...sizes];
|
|
229
|
-
const sizeBefore = sizes[indexBefore];
|
|
230
|
-
const sizeAfter = sizes[indexAfter];
|
|
231
|
-
let newSizeBefore = sizeBefore + delta;
|
|
232
|
-
let newSizeAfter = sizeAfter - delta;
|
|
233
|
-
// Apply minimum size constraints
|
|
234
|
-
if (newSizeBefore < this.options.minPanelSize) {
|
|
235
|
-
const adjustment = this.options.minPanelSize - newSizeBefore;
|
|
236
|
-
newSizeBefore = this.options.minPanelSize;
|
|
237
|
-
newSizeAfter -= adjustment;
|
|
238
|
-
}
|
|
239
|
-
if (newSizeAfter < this.options.minPanelSize) {
|
|
240
|
-
const adjustment = this.options.minPanelSize - newSizeAfter;
|
|
241
|
-
newSizeAfter = this.options.minPanelSize;
|
|
242
|
-
newSizeBefore -= adjustment;
|
|
243
|
-
}
|
|
244
|
-
// Final clamp
|
|
245
|
-
newSizeBefore = Math.max(newSizeBefore, this.options.minPanelSize);
|
|
246
|
-
newSizeAfter = Math.max(newSizeAfter, this.options.minPanelSize);
|
|
247
|
-
newSizes[indexBefore] = newSizeBefore;
|
|
248
|
-
newSizes[indexAfter] = newSizeAfter;
|
|
249
|
-
return newSizes;
|
|
250
|
-
}
|
|
251
|
-
setMinPanelSize(size) {
|
|
252
|
-
this.options.minPanelSize = size;
|
|
253
|
-
}
|
|
254
|
-
getMinPanelSize() {
|
|
255
|
-
return this.options.minPanelSize;
|
|
256
|
-
}
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
// AUTO-GENERATED — do not edit by hand.
|
|
260
|
-
// Source: splitter.styles.scss
|
|
261
|
-
// Regenerate with the codegen-wc Nx target.
|
|
262
|
-
const splitterStyles = unsafeCSS(`:host {
|
|
263
|
-
display: block;
|
|
264
|
-
width: 100%;
|
|
265
|
-
height: 100%;
|
|
266
|
-
--mp-splitter-size: 8px;
|
|
267
|
-
--mp-splitter-thumb-margin: 3px;
|
|
268
|
-
--mp-splitter-divider-color: #eee;
|
|
269
|
-
--mp-splitter-divider-hover-color: #1389fd;
|
|
270
|
-
}
|
|
271
|
-
|
|
272
|
-
:host([touch-mode]) {
|
|
273
|
-
--mp-splitter-thumb-margin: 20px;
|
|
274
|
-
}
|
|
275
|
-
|
|
276
|
-
* {
|
|
277
|
-
box-sizing: border-box;
|
|
278
|
-
}
|
|
279
|
-
|
|
280
|
-
.splitter-container {
|
|
281
|
-
display: flex;
|
|
282
|
-
width: 100%;
|
|
283
|
-
height: 100%;
|
|
284
|
-
}
|
|
285
|
-
|
|
286
|
-
.splitter-container.horizontal {
|
|
287
|
-
flex-direction: row;
|
|
288
|
-
}
|
|
289
|
-
|
|
290
|
-
.splitter-container.vertical {
|
|
291
|
-
flex-direction: column;
|
|
292
|
-
}
|
|
293
|
-
|
|
294
|
-
.panel-wrapper {
|
|
295
|
-
overflow: hidden;
|
|
296
|
-
position: relative;
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
.panel-wrapper.flex-grow {
|
|
300
|
-
flex: 1 1 0;
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
/* Divider base styles */
|
|
304
|
-
.divider {
|
|
305
|
-
flex-shrink: 0;
|
|
306
|
-
transition: background-color 0.15s ease-in-out;
|
|
307
|
-
z-index: 3;
|
|
308
|
-
touch-action: none;
|
|
309
|
-
}
|
|
310
|
-
|
|
311
|
-
.divider::before {
|
|
312
|
-
content: "";
|
|
313
|
-
display: block;
|
|
314
|
-
background-color: var(--mp-splitter-divider-color);
|
|
315
|
-
background-position: center center;
|
|
316
|
-
background-repeat: no-repeat;
|
|
317
|
-
}
|
|
318
|
-
|
|
319
|
-
.divider:hover::before,
|
|
320
|
-
.divider.active::before,
|
|
321
|
-
.divider:focus-visible::before {
|
|
322
|
-
background-color: var(--mp-splitter-divider-hover-color);
|
|
323
|
-
border-radius: calc(var(--mp-splitter-size) / 2);
|
|
324
|
-
}
|
|
325
|
-
|
|
326
|
-
.divider:focus {
|
|
327
|
-
outline: none;
|
|
328
|
-
}
|
|
329
|
-
|
|
330
|
-
.divider:focus-visible {
|
|
331
|
-
outline: 2px solid var(--mp-splitter-divider-hover-color);
|
|
332
|
-
outline-offset: 1px;
|
|
333
|
-
}
|
|
334
|
-
|
|
335
|
-
/* Horizontal splitter styles */
|
|
336
|
-
.splitter-container.horizontal > .divider {
|
|
337
|
-
width: calc(var(--mp-splitter-size) + 2 * var(--mp-splitter-thumb-margin));
|
|
338
|
-
height: 100%;
|
|
339
|
-
cursor: col-resize;
|
|
340
|
-
border-left: var(--mp-splitter-thumb-margin) solid transparent;
|
|
341
|
-
border-right: var(--mp-splitter-thumb-margin) solid transparent;
|
|
342
|
-
}
|
|
343
|
-
|
|
344
|
-
.splitter-container.horizontal > .divider::before {
|
|
345
|
-
height: 100%;
|
|
346
|
-
width: var(--mp-splitter-size);
|
|
347
|
-
margin: 0 auto;
|
|
348
|
-
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAeCAYAAADkftS9AAAAIklEQVQoU2M4c+bMfxAGAgYYmwGrIIiDjrELjpo5aiZeMwF+yNnOs5KSvgAAAABJRU5ErkJggg==);
|
|
349
|
-
}
|
|
350
|
-
|
|
351
|
-
.splitter-container.horizontal > .panel-wrapper:not(:first-child) {
|
|
352
|
-
margin-left: calc(-1 * var(--mp-splitter-thumb-margin));
|
|
353
|
-
}
|
|
354
|
-
|
|
355
|
-
.splitter-container.horizontal > .panel-wrapper:not(:last-child) {
|
|
356
|
-
margin-right: calc(-1 * var(--mp-splitter-thumb-margin));
|
|
357
|
-
}
|
|
358
|
-
|
|
359
|
-
/* Vertical splitter styles */
|
|
360
|
-
.splitter-container.vertical > .divider {
|
|
361
|
-
width: 100%;
|
|
362
|
-
height: calc(var(--mp-splitter-size) + 2 * var(--mp-splitter-thumb-margin));
|
|
363
|
-
cursor: row-resize;
|
|
364
|
-
border-top: var(--mp-splitter-thumb-margin) solid transparent;
|
|
365
|
-
border-bottom: var(--mp-splitter-thumb-margin) solid transparent;
|
|
366
|
-
}
|
|
367
|
-
|
|
368
|
-
.splitter-container.vertical > .divider::before {
|
|
369
|
-
height: var(--mp-splitter-size);
|
|
370
|
-
width: 100%;
|
|
371
|
-
margin: auto 0;
|
|
372
|
-
background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB4AAAAFCAMAAABl/6zIAAAABlBMVEUAAADMzMzIT8AyAAAAAXRSTlMAQObYZgAAABRJREFUeAFjYGRkwIMJSeMHlBkOABP7AEGzSuPKAAAAAElFTkSuQmCC);
|
|
373
|
-
}
|
|
374
|
-
|
|
375
|
-
.splitter-container.vertical > .panel-wrapper:not(:first-child) {
|
|
376
|
-
margin-top: calc(-1 * var(--mp-splitter-thumb-margin));
|
|
377
|
-
}
|
|
378
|
-
|
|
379
|
-
.splitter-container.vertical > .panel-wrapper:not(:last-child) {
|
|
380
|
-
margin-bottom: calc(-1 * var(--mp-splitter-thumb-margin));
|
|
381
|
-
}
|
|
382
|
-
|
|
383
|
-
/* Resizing state */
|
|
384
|
-
:host([resizing]) .splitter-container {
|
|
385
|
-
cursor: col-resize;
|
|
386
|
-
user-select: none;
|
|
387
|
-
}
|
|
388
|
-
|
|
389
|
-
:host([resizing]) .splitter-container.vertical {
|
|
390
|
-
cursor: row-resize;
|
|
391
|
-
}
|
|
392
|
-
|
|
393
|
-
/* Slot content styling */
|
|
394
|
-
::slotted(*) {
|
|
395
|
-
width: 100%;
|
|
396
|
-
height: 100%;
|
|
397
|
-
}
|
|
398
|
-
|
|
399
|
-
@media (prefers-reduced-motion: reduce) {
|
|
400
|
-
.divider {
|
|
401
|
-
transition: none !important;
|
|
402
|
-
}
|
|
403
|
-
}`);
|
|
404
|
-
|
|
405
|
-
let splitterInstanceCounter = 0;
|
|
406
|
-
/**
|
|
407
|
-
* `<mp-splitter>` — resizable panel splitter.
|
|
408
|
-
*
|
|
409
|
-
* Light-DOM children are projected into named slots (`panel-${i}`) inside a
|
|
410
|
-
* shadow-DOM flex container with auto-inserted dividers between them. Drag a
|
|
411
|
-
* divider to redistribute space; sizes survive container resize via a
|
|
412
|
-
* proportional rescale.
|
|
413
|
-
*
|
|
414
|
-
* Pointer + keyboard interactions both flow through the same path:
|
|
415
|
-
* - Pointer drag → `InputHandler` → `handleResizeStart/Move/End`.
|
|
416
|
-
* - Arrow keys ±10% (Shift = ±1%), Home/End to limits → `handleResizeKey`.
|
|
417
|
-
*
|
|
418
|
-
* ARIA: each divider is a `role="separator"` with `aria-orientation`,
|
|
419
|
-
* `aria-controls` referencing the deterministic IDs of the two adjacent
|
|
420
|
-
* panel wrappers, and percent-based `aria-valuenow / valuemin / valuemax`
|
|
421
|
-
* that update on every drag-preview frame, container resize, and keystroke.
|
|
422
|
-
*
|
|
423
|
-
* Public API: `[orientation]`, `[min-panel-size]`, `[touch-mode]`;
|
|
424
|
-
* `getPanelSizes()` / `setPanelSizes()`; events `resize-start`, `resizing`,
|
|
425
|
-
* `resize-end` carrying `{ sizes, orientation }`.
|
|
426
|
-
*/
|
|
427
|
-
class MpSplitter extends LitElement {
|
|
428
|
-
static { this.styles = [splitterStyles]; }
|
|
429
|
-
static get observedAttributes() {
|
|
430
|
-
return [
|
|
431
|
-
...(super.observedAttributes ?? []),
|
|
432
|
-
'orientation',
|
|
433
|
-
'min-panel-size',
|
|
434
|
-
'touch-mode',
|
|
435
|
-
];
|
|
436
|
-
}
|
|
437
|
-
constructor() {
|
|
438
|
-
super();
|
|
439
|
-
this.container = null;
|
|
440
|
-
this.panelWrappers = [];
|
|
441
|
-
this.dividers = [];
|
|
442
|
-
this.slotElement = null;
|
|
443
|
-
this.mutationObserver = null;
|
|
444
|
-
this.containerResizeObserver = null;
|
|
445
|
-
this.unsubscribeState = null;
|
|
446
|
-
this.instanceId = `mp-splitter-${++splitterInstanceCounter}`;
|
|
447
|
-
this.stateManager = new SplitterStateManager();
|
|
448
|
-
this.resizeManager = new ResizeManager();
|
|
449
|
-
this.inputHandler = new InputHandler({
|
|
450
|
-
onResizeStart: this.handleResizeStart.bind(this),
|
|
451
|
-
onResizeMove: this.handleResizeMove.bind(this),
|
|
452
|
-
onResizeEnd: this.handleResizeEnd.bind(this),
|
|
453
|
-
onResizeKey: this.handleResizeKey.bind(this),
|
|
454
|
-
});
|
|
455
|
-
}
|
|
456
|
-
render() {
|
|
457
|
-
return html `
|
|
458
|
-
<div class="splitter-container"></div>
|
|
459
|
-
<slot></slot>
|
|
460
|
-
`;
|
|
461
|
-
}
|
|
462
|
-
firstUpdated() {
|
|
463
|
-
this.container = this.shadowRoot.querySelector('.splitter-container');
|
|
464
|
-
this.container.classList.add(this.orientation);
|
|
465
|
-
this.slotElement = this.shadowRoot.querySelector('slot');
|
|
466
|
-
// Hide the default slot - we'll project content ourselves via named slots.
|
|
467
|
-
this.slotElement.style.display = 'none';
|
|
468
|
-
this.slotElement.addEventListener('slotchange', () => {
|
|
469
|
-
this.updatePanelsFromSlot();
|
|
470
|
-
});
|
|
471
|
-
this.setupMutationObserver();
|
|
472
|
-
this.subscribeToState();
|
|
473
|
-
this.setupContainerResizeObserver();
|
|
474
|
-
// Initial setup after first render
|
|
475
|
-
requestAnimationFrame(() => {
|
|
476
|
-
this.updatePanelsFromSlot();
|
|
477
|
-
});
|
|
478
|
-
}
|
|
479
|
-
disconnectedCallback() {
|
|
480
|
-
this.inputHandler.dispose();
|
|
481
|
-
if (this.mutationObserver) {
|
|
482
|
-
this.mutationObserver.disconnect();
|
|
483
|
-
this.mutationObserver = null;
|
|
484
|
-
}
|
|
485
|
-
if (this.containerResizeObserver) {
|
|
486
|
-
this.containerResizeObserver.disconnect();
|
|
487
|
-
this.containerResizeObserver = null;
|
|
488
|
-
}
|
|
489
|
-
if (this.unsubscribeState) {
|
|
490
|
-
this.unsubscribeState();
|
|
491
|
-
this.unsubscribeState = null;
|
|
492
|
-
}
|
|
493
|
-
super.disconnectedCallback();
|
|
494
|
-
}
|
|
495
|
-
attributeChangedCallback(name, oldValue, newValue) {
|
|
496
|
-
super.attributeChangedCallback(name, oldValue, newValue);
|
|
497
|
-
if (oldValue === newValue)
|
|
498
|
-
return;
|
|
499
|
-
switch (name) {
|
|
500
|
-
case 'orientation':
|
|
501
|
-
this.stateManager.setOrientation(newValue || 'horizontal');
|
|
502
|
-
this.updateContainerOrientation();
|
|
503
|
-
break;
|
|
504
|
-
case 'min-panel-size':
|
|
505
|
-
const parsedSize = newValue ? parseInt(newValue, 10) : 50;
|
|
506
|
-
this.resizeManager.setMinPanelSize(!isNaN(parsedSize) ? parsedSize : 50);
|
|
507
|
-
break;
|
|
508
|
-
case 'touch-mode':
|
|
509
|
-
// Handled by CSS via :host([touch-mode])
|
|
510
|
-
break;
|
|
511
|
-
}
|
|
512
|
-
}
|
|
513
|
-
// Public API
|
|
514
|
-
get orientation() {
|
|
515
|
-
return this.getAttribute('orientation') || 'horizontal';
|
|
516
|
-
}
|
|
517
|
-
set orientation(value) {
|
|
518
|
-
this.setAttribute('orientation', value);
|
|
519
|
-
}
|
|
520
|
-
get minPanelSize() {
|
|
521
|
-
const attr = this.getAttribute('min-panel-size');
|
|
522
|
-
return attr ? parseInt(attr, 10) : 50;
|
|
523
|
-
}
|
|
524
|
-
set minPanelSize(value) {
|
|
525
|
-
this.setAttribute('min-panel-size', String(value));
|
|
526
|
-
}
|
|
527
|
-
get touchMode() {
|
|
528
|
-
return this.hasAttribute('touch-mode');
|
|
529
|
-
}
|
|
530
|
-
set touchMode(value) {
|
|
531
|
-
if (value) {
|
|
532
|
-
this.setAttribute('touch-mode', '');
|
|
533
|
-
}
|
|
534
|
-
else {
|
|
535
|
-
this.removeAttribute('touch-mode');
|
|
536
|
-
}
|
|
537
|
-
}
|
|
538
|
-
getPanelSizes() {
|
|
539
|
-
return this.stateManager.getState().panelSizes;
|
|
540
|
-
}
|
|
541
|
-
/**
|
|
542
|
-
* Drive a keyboard-style resize on a divider programmatically. Used by the
|
|
543
|
-
* dock manager's intersection-handle keymap so a single keystroke can
|
|
544
|
-
* resize both the horizontal and vertical dividers a 2D handle sits on,
|
|
545
|
-
* without re-implementing the percent-step + clamp math here.
|
|
546
|
-
*
|
|
547
|
-
* `key` is one of the keys handled by the divider keymap
|
|
548
|
-
* (Arrow{Left,Right,Up,Down}, Home, End); `fine` halves the step (matches
|
|
549
|
-
* Shift modifier on the keyboard path).
|
|
550
|
-
*/
|
|
551
|
-
resizeDividerBy(dividerIndex, key, fine = false) {
|
|
552
|
-
const divider = this.dividers[dividerIndex];
|
|
553
|
-
if (!divider)
|
|
554
|
-
return;
|
|
555
|
-
this.handleResizeKey(key, fine, dividerIndex, divider);
|
|
556
|
-
}
|
|
557
|
-
setPanelSizes(sizes) {
|
|
558
|
-
this.applyPanelSizes(sizes);
|
|
559
|
-
this.stateManager.setPanelSizes(sizes);
|
|
560
|
-
}
|
|
561
|
-
// Private methods
|
|
562
|
-
setupMutationObserver() {
|
|
563
|
-
this.mutationObserver = new MutationObserver(() => {
|
|
564
|
-
this.updatePanelsFromSlot();
|
|
565
|
-
});
|
|
566
|
-
this.mutationObserver.observe(this, {
|
|
567
|
-
childList: true,
|
|
568
|
-
subtree: false,
|
|
569
|
-
});
|
|
570
|
-
}
|
|
571
|
-
subscribeToState() {
|
|
572
|
-
this.unsubscribeState = this.stateManager.subscribe((state) => {
|
|
573
|
-
if (state.resizeOperation) {
|
|
574
|
-
this.setAttribute('resizing', '');
|
|
575
|
-
}
|
|
576
|
-
else {
|
|
577
|
-
this.removeAttribute('resizing');
|
|
578
|
-
}
|
|
579
|
-
this.updateDividerAriaValues();
|
|
580
|
-
});
|
|
581
|
-
}
|
|
582
|
-
/**
|
|
583
|
-
* Mirror current panel sizes to each divider's aria-valuenow / valuemin /
|
|
584
|
-
* valuemax as percent of container. Per §10 Q3 of the WC ARIA PRD: percent
|
|
585
|
-
* is more intuitive for SR users than pixels.
|
|
586
|
-
*
|
|
587
|
-
* Per-divider math: divider i sits between panels[i] and panels[i+1] and
|
|
588
|
-
* "owns" the size of panels[i]. valuemin = minPanelSize as % of container;
|
|
589
|
-
* valuemax = (panels[i].size + panels[i+1].size - minPanelSize) as %.
|
|
590
|
-
*/
|
|
591
|
-
updateDividerAriaValues() {
|
|
592
|
-
if (this.dividers.length === 0 || !this.container)
|
|
593
|
-
return;
|
|
594
|
-
const state = this.stateManager.getState();
|
|
595
|
-
const sizes = state.previewSizes ?? state.panelSizes;
|
|
596
|
-
if (sizes.length !== this.panelWrappers.length || sizes.length === 0)
|
|
597
|
-
return;
|
|
598
|
-
const rect = this.container.getBoundingClientRect();
|
|
599
|
-
const containerSize = this.orientation === 'horizontal' ? rect.width : rect.height;
|
|
600
|
-
if (containerSize <= 0)
|
|
601
|
-
return;
|
|
602
|
-
const minPanelSize = this.resizeManager.getMinPanelSize();
|
|
603
|
-
this.dividers.forEach((divider, i) => {
|
|
604
|
-
const before = sizes[i];
|
|
605
|
-
const after = sizes[i + 1];
|
|
606
|
-
if (before === undefined || after === undefined)
|
|
607
|
-
return;
|
|
608
|
-
const valuenow = Math.round((before / containerSize) * 100);
|
|
609
|
-
const valuemin = Math.round((minPanelSize / containerSize) * 100);
|
|
610
|
-
const pairTotal = before + after;
|
|
611
|
-
const valuemax = Math.round(((pairTotal - minPanelSize) / containerSize) * 100);
|
|
612
|
-
divider.setAttribute('aria-valuenow', String(valuenow));
|
|
613
|
-
divider.setAttribute('aria-valuemin', String(valuemin));
|
|
614
|
-
divider.setAttribute('aria-valuemax', String(valuemax));
|
|
615
|
-
});
|
|
616
|
-
}
|
|
617
|
-
updatePanelsFromSlot() {
|
|
618
|
-
if (!this.container)
|
|
619
|
-
return;
|
|
620
|
-
const children = Array.from(this.children).filter((child) => child instanceof HTMLElement);
|
|
621
|
-
if (children.length === 0)
|
|
622
|
-
return;
|
|
623
|
-
// Clear existing wrappers and dividers
|
|
624
|
-
this.container.innerHTML = '';
|
|
625
|
-
this.panelWrappers = [];
|
|
626
|
-
this.dividers = [];
|
|
627
|
-
// Create panel wrappers with slots for each child
|
|
628
|
-
const panelCount = children.length;
|
|
629
|
-
const dividerAriaOrientation = this.orientation === 'horizontal' ? 'vertical' : 'horizontal';
|
|
630
|
-
children.forEach((child, index) => {
|
|
631
|
-
const wrapper = document.createElement('div');
|
|
632
|
-
wrapper.className = 'panel-wrapper flex-grow';
|
|
633
|
-
wrapper.id = `${this.instanceId}-panel-${index}`;
|
|
634
|
-
// Create a named slot for this child
|
|
635
|
-
const namedSlot = document.createElement('slot');
|
|
636
|
-
const slotName = `panel-${index}`;
|
|
637
|
-
namedSlot.name = slotName;
|
|
638
|
-
child.slot = slotName;
|
|
639
|
-
wrapper.appendChild(namedSlot);
|
|
640
|
-
this.panelWrappers.push(wrapper);
|
|
641
|
-
this.container.appendChild(wrapper);
|
|
642
|
-
// Add divider between panels
|
|
643
|
-
if (index < panelCount - 1) {
|
|
644
|
-
const divider = document.createElement('div');
|
|
645
|
-
divider.className = 'divider';
|
|
646
|
-
divider.setAttribute('role', 'separator');
|
|
647
|
-
divider.setAttribute('aria-orientation', dividerAriaOrientation);
|
|
648
|
-
divider.setAttribute('tabindex', '0');
|
|
649
|
-
divider.setAttribute('aria-controls', `${this.instanceId}-panel-${index} ${this.instanceId}-panel-${index + 1}`);
|
|
650
|
-
divider.setAttribute('aria-label', `Resize between panel ${index + 1} and panel ${index + 2}`);
|
|
651
|
-
this.inputHandler.attachDividerListeners(divider, index);
|
|
652
|
-
this.dividers.push(divider);
|
|
653
|
-
this.container.appendChild(divider);
|
|
654
|
-
}
|
|
655
|
-
});
|
|
656
|
-
// Re-apply previously-stored sizes when the panel count still matches.
|
|
657
|
-
// Two cases where this matters:
|
|
658
|
-
// 1. setPanelSizes() was called before firstUpdated's raf populated
|
|
659
|
-
// the wrappers (e.g., the dock schedules its own raf inside
|
|
660
|
-
// renderSplit) — without this, the early call is silently dropped.
|
|
661
|
-
// 2. Slot children change after a drag (e.g., layout re-render) — the
|
|
662
|
-
// wrappers get recreated with `flex: 1 1 0` (equal sizes) and would
|
|
663
|
-
// otherwise discard the user's drag result.
|
|
664
|
-
const storedSizes = this.stateManager.getState().panelSizes;
|
|
665
|
-
if (storedSizes.length > 0 && storedSizes.length === this.panelWrappers.length) {
|
|
666
|
-
this.applyPanelSizes(storedSizes);
|
|
667
|
-
// Consumer-supplied sizes (e.g., from the dock's renderSplit) often
|
|
668
|
-
// sum to the full container size because the consumer doesn't know
|
|
669
|
-
// mp-splitter's internal divider widths. Defer one raf so dividers
|
|
670
|
-
// have laid out, then rescale stored sizes against the actual panel
|
|
671
|
-
// space (container - dividers). Without this step ResizeObserver
|
|
672
|
-
// alone can't catch the discrepancy because the container size
|
|
673
|
-
// hasn't changed — only the panel/divider split inside it has.
|
|
674
|
-
requestAnimationFrame(() => this.handleContainerResize());
|
|
675
|
-
return;
|
|
676
|
-
}
|
|
677
|
-
// No stored sizes (or count mismatch) — pin from the measured layout
|
|
678
|
-
// once the browser has run layout for the new wrappers. A nested raf
|
|
679
|
-
// is needed because the wrappers were created in this very turn and
|
|
680
|
-
// their getBoundingClientRect would return 0 if read synchronously.
|
|
681
|
-
requestAnimationFrame(() => {
|
|
682
|
-
const current = this.stateManager.getState().panelSizes;
|
|
683
|
-
if (current.length === this.panelWrappers.length && current.length > 0) {
|
|
684
|
-
// A consumer (e.g., the dock) called setPanelSizes() between our
|
|
685
|
-
// raf scheduling and execution. Honour their values instead of
|
|
686
|
-
// overwriting with measurements.
|
|
687
|
-
this.applyPanelSizes(current);
|
|
688
|
-
return;
|
|
689
|
-
}
|
|
690
|
-
this.pinSizesFromCurrentLayout();
|
|
691
|
-
});
|
|
692
|
-
}
|
|
693
|
-
/**
|
|
694
|
-
* Read each panel-wrapper's measured pixel size and persist it as the
|
|
695
|
-
* authoritative panel size. After this runs, every wrapper carries an
|
|
696
|
-
* inline `width` (or `height`) — content intrinsic size cannot leak into
|
|
697
|
-
* the parent flex container, so a nested splitter's drag does not shift
|
|
698
|
-
* the parent's layout.
|
|
699
|
-
*/
|
|
700
|
-
pinSizesFromCurrentLayout() {
|
|
701
|
-
if (this.panelWrappers.length === 0)
|
|
702
|
-
return;
|
|
703
|
-
const sizeProperty = this.orientation === 'horizontal' ? 'width' : 'height';
|
|
704
|
-
const measured = this.panelWrappers.map((wrapper) => wrapper.getBoundingClientRect()[sizeProperty]);
|
|
705
|
-
// Layout hasn't run yet for these wrappers — bail rather than write
|
|
706
|
-
// 0 px sizes that would collapse every panel.
|
|
707
|
-
if (measured.every((v) => v <= 0))
|
|
708
|
-
return;
|
|
709
|
-
this.applyPanelSizes(measured);
|
|
710
|
-
this.stateManager.setPanelSizes(measured);
|
|
711
|
-
}
|
|
712
|
-
setupContainerResizeObserver() {
|
|
713
|
-
if (!this.container || typeof ResizeObserver === 'undefined')
|
|
714
|
-
return;
|
|
715
|
-
this.containerResizeObserver = new ResizeObserver(() => {
|
|
716
|
-
this.handleContainerResize();
|
|
717
|
-
});
|
|
718
|
-
this.containerResizeObserver.observe(this.container);
|
|
719
|
-
}
|
|
720
|
-
/**
|
|
721
|
-
* When the splitter's container resizes (window resize, parent splitter
|
|
722
|
-
* pinning its sizes, etc.), scale every panel-wrapper proportionally so
|
|
723
|
-
* the existing ratios are preserved. Without this we'd be stuck with the
|
|
724
|
-
* original pixel sizes when the surrounding viewport changes — what
|
|
725
|
-
* `flex-basis: 0` gave master "for free".
|
|
726
|
-
*/
|
|
727
|
-
handleContainerResize() {
|
|
728
|
-
if (!this.container || this.panelWrappers.length === 0)
|
|
729
|
-
return;
|
|
730
|
-
// applyPanelSizes runs continuously during a drag; its writes can fire
|
|
731
|
-
// ResizeObserver via subpixel rounding. The drag math already keeps
|
|
732
|
-
// panels summing to the container — don't fight it.
|
|
733
|
-
if (this.stateManager.isResizing())
|
|
734
|
-
return;
|
|
735
|
-
const stored = this.stateManager.getState().panelSizes;
|
|
736
|
-
if (stored.length === 0 || stored.length !== this.panelWrappers.length)
|
|
737
|
-
return;
|
|
738
|
-
const rect = this.container.getBoundingClientRect();
|
|
739
|
-
const containerSize = this.orientation === 'horizontal' ? rect.width : rect.height;
|
|
740
|
-
if (containerSize <= 0)
|
|
741
|
-
return;
|
|
742
|
-
const dividerProperty = this.orientation === 'horizontal' ? 'width' : 'height';
|
|
743
|
-
const dividerTotal = this.dividers.reduce((sum, divider) => sum + divider.getBoundingClientRect()[dividerProperty], 0);
|
|
744
|
-
// Adjacent panel-wrappers carry negative margins (`margin-left` /
|
|
745
|
-
// `margin-right` of `-thumb-margin`) so they visually overlap the
|
|
746
|
-
// divider's transparent borders. In the flex calculation those negative
|
|
747
|
-
// margins reduce a divider's effective width contribution; if we ignore
|
|
748
|
-
// them we under-target by 2 * (N-1) * thumb px and the container gets
|
|
749
|
-
// a gap at the trailing edge.
|
|
750
|
-
const startMarginProp = this.orientation === 'horizontal' ? 'marginLeft' : 'marginTop';
|
|
751
|
-
const endMarginProp = this.orientation === 'horizontal' ? 'marginRight' : 'marginBottom';
|
|
752
|
-
const marginTotal = this.panelWrappers.reduce((sum, wrapper) => {
|
|
753
|
-
const cs = getComputedStyle(wrapper);
|
|
754
|
-
return sum + parseFloat(cs[startMarginProp]) + parseFloat(cs[endMarginProp]);
|
|
755
|
-
}, 0);
|
|
756
|
-
const targetPanelTotal = Math.max(0, containerSize - dividerTotal - marginTotal);
|
|
757
|
-
const previousPanelTotal = stored.reduce((a, b) => a + b, 0);
|
|
758
|
-
if (previousPanelTotal <= 0)
|
|
759
|
-
return;
|
|
760
|
-
// Below 1 px we'd be amplifying our own subpixel writes. Skip.
|
|
761
|
-
if (Math.abs(targetPanelTotal - previousPanelTotal) < 1)
|
|
762
|
-
return;
|
|
763
|
-
const scale = targetPanelTotal / previousPanelTotal;
|
|
764
|
-
const newSizes = stored.map((s) => s * scale);
|
|
765
|
-
this.applyPanelSizes(newSizes);
|
|
766
|
-
this.stateManager.setPanelSizes(newSizes);
|
|
767
|
-
this.updateDividerAriaValues();
|
|
768
|
-
}
|
|
769
|
-
updateContainerOrientation() {
|
|
770
|
-
if (!this.container)
|
|
771
|
-
return;
|
|
772
|
-
this.container.className = `splitter-container ${this.orientation}`;
|
|
773
|
-
const dividerAriaOrientation = this.orientation === 'horizontal' ? 'vertical' : 'horizontal';
|
|
774
|
-
this.dividers.forEach((divider) => {
|
|
775
|
-
divider.setAttribute('aria-orientation', dividerAriaOrientation);
|
|
776
|
-
});
|
|
777
|
-
}
|
|
778
|
-
handleResizeStart(event, dividerIndex, dividerElement) {
|
|
779
|
-
const sizes = this.resizeManager.computePanelSizes(this.panelWrappers, this.orientation);
|
|
780
|
-
const operation = this.resizeManager.createResizeOperation(event.point, sizes, dividerIndex, dividerElement);
|
|
781
|
-
this.stateManager.startResize(operation);
|
|
782
|
-
dividerElement.classList.add('active');
|
|
783
|
-
this.dispatchEvent(new CustomEvent('resize-start', {
|
|
784
|
-
bubbles: true,
|
|
785
|
-
detail: {
|
|
786
|
-
sizes,
|
|
787
|
-
orientation: this.orientation,
|
|
788
|
-
},
|
|
789
|
-
}));
|
|
790
|
-
}
|
|
791
|
-
handleResizeMove(event) {
|
|
792
|
-
const state = this.stateManager.getState();
|
|
793
|
-
if (!state.resizeOperation)
|
|
794
|
-
return;
|
|
795
|
-
const previewSizes = this.resizeManager.calculatePreviewSizes(state.resizeOperation, event.point, this.orientation);
|
|
796
|
-
this.stateManager.updateResize(previewSizes);
|
|
797
|
-
this.applyPanelSizes(previewSizes);
|
|
798
|
-
this.dispatchEvent(new CustomEvent('resizing', {
|
|
799
|
-
bubbles: true,
|
|
800
|
-
detail: {
|
|
801
|
-
sizes: previewSizes,
|
|
802
|
-
orientation: this.orientation,
|
|
803
|
-
},
|
|
804
|
-
}));
|
|
805
|
-
}
|
|
806
|
-
handleResizeEnd(_event) {
|
|
807
|
-
const state = this.stateManager.getState();
|
|
808
|
-
if (!state.resizeOperation)
|
|
809
|
-
return;
|
|
810
|
-
const finalSizes = state.previewSizes || state.resizeOperation.sizes;
|
|
811
|
-
if (state.resizeOperation.dividerElement) {
|
|
812
|
-
state.resizeOperation.dividerElement.classList.remove('active');
|
|
813
|
-
}
|
|
814
|
-
this.stateManager.endResize(finalSizes);
|
|
815
|
-
this.dispatchEvent(new CustomEvent('resize-end', {
|
|
816
|
-
bubbles: true,
|
|
817
|
-
detail: {
|
|
818
|
-
sizes: finalSizes,
|
|
819
|
-
orientation: this.orientation,
|
|
820
|
-
},
|
|
821
|
-
}));
|
|
822
|
-
}
|
|
823
|
-
/**
|
|
824
|
-
* Keyboard-driven resize on a focused divider. ArrowKeys ±10% (Shift = ±1%)
|
|
825
|
-
* along the splitter's axis; Home/End shrink/grow panelBefore to its limit.
|
|
826
|
-
* Fires resize-start → resize-end with the new sizes so consumers don't
|
|
827
|
-
* need to special-case keyboard vs. drag.
|
|
828
|
-
*/
|
|
829
|
-
handleResizeKey(key, fine, dividerIndex, dividerElement) {
|
|
830
|
-
if (!this.container)
|
|
831
|
-
return;
|
|
832
|
-
if (this.panelWrappers.length === 0)
|
|
833
|
-
return;
|
|
834
|
-
const sizes = [...this.stateManager.getState().panelSizes];
|
|
835
|
-
if (sizes.length !== this.panelWrappers.length)
|
|
836
|
-
return;
|
|
837
|
-
const before = sizes[dividerIndex];
|
|
838
|
-
const after = sizes[dividerIndex + 1];
|
|
839
|
-
if (before === undefined || after === undefined)
|
|
840
|
-
return;
|
|
841
|
-
const rect = this.container.getBoundingClientRect();
|
|
842
|
-
const containerSize = this.orientation === 'horizontal' ? rect.width : rect.height;
|
|
843
|
-
if (containerSize <= 0)
|
|
844
|
-
return;
|
|
845
|
-
const minPanelSize = this.resizeManager.getMinPanelSize();
|
|
846
|
-
const isHorizontal = this.orientation === 'horizontal';
|
|
847
|
-
const positive = isHorizontal ? 'ArrowRight' : 'ArrowDown';
|
|
848
|
-
const negative = isHorizontal ? 'ArrowLeft' : 'ArrowUp';
|
|
849
|
-
let direction = 0;
|
|
850
|
-
if (key === positive)
|
|
851
|
-
direction = 1;
|
|
852
|
-
else if (key === negative)
|
|
853
|
-
direction = -1;
|
|
854
|
-
let newBefore;
|
|
855
|
-
let newAfter;
|
|
856
|
-
if (key === 'Home') {
|
|
857
|
-
newBefore = minPanelSize;
|
|
858
|
-
newAfter = before + after - minPanelSize;
|
|
859
|
-
}
|
|
860
|
-
else if (key === 'End') {
|
|
861
|
-
newBefore = before + after - minPanelSize;
|
|
862
|
-
newAfter = minPanelSize;
|
|
863
|
-
}
|
|
864
|
-
else if (direction !== 0) {
|
|
865
|
-
const stepPercent = fine ? 1 : 10;
|
|
866
|
-
const deltaPx = (stepPercent / 100) * containerSize * direction;
|
|
867
|
-
newBefore = before + deltaPx;
|
|
868
|
-
newAfter = after - deltaPx;
|
|
869
|
-
// Clamp to min on both sides — symmetric with the pointer path in
|
|
870
|
-
// ResizeManager.calculatePreviewSizes.
|
|
871
|
-
if (newBefore < minPanelSize) {
|
|
872
|
-
newBefore = minPanelSize;
|
|
873
|
-
newAfter = before + after - minPanelSize;
|
|
874
|
-
}
|
|
875
|
-
else if (newAfter < minPanelSize) {
|
|
876
|
-
newAfter = minPanelSize;
|
|
877
|
-
newBefore = before + after - minPanelSize;
|
|
878
|
-
}
|
|
879
|
-
}
|
|
880
|
-
else {
|
|
881
|
-
// Off-axis arrow — silently ignored.
|
|
882
|
-
return;
|
|
883
|
-
}
|
|
884
|
-
if (newBefore === before && newAfter === after)
|
|
885
|
-
return;
|
|
886
|
-
sizes[dividerIndex] = newBefore;
|
|
887
|
-
sizes[dividerIndex + 1] = newAfter;
|
|
888
|
-
this.applyPanelSizes(sizes);
|
|
889
|
-
this.stateManager.setPanelSizes(sizes);
|
|
890
|
-
this.updateDividerAriaValues();
|
|
891
|
-
dividerElement.classList.add('active');
|
|
892
|
-
queueMicrotask(() => dividerElement.classList.remove('active'));
|
|
893
|
-
this.dispatchEvent(new CustomEvent('resize-end', {
|
|
894
|
-
bubbles: true,
|
|
895
|
-
detail: { sizes, orientation: this.orientation },
|
|
896
|
-
}));
|
|
897
|
-
}
|
|
898
|
-
applyPanelSizes(sizes) {
|
|
899
|
-
const sizeProperty = this.orientation === 'horizontal' ? 'width' : 'height';
|
|
900
|
-
const resetProperty = this.orientation === 'horizontal' ? 'height' : 'width';
|
|
901
|
-
this.panelWrappers.forEach((wrapper, index) => {
|
|
902
|
-
if (sizes[index] !== undefined) {
|
|
903
|
-
wrapper.style[sizeProperty] = `${sizes[index]}px`;
|
|
904
|
-
wrapper.style[resetProperty] = '';
|
|
905
|
-
wrapper.classList.remove('flex-grow');
|
|
906
|
-
}
|
|
907
|
-
});
|
|
908
|
-
}
|
|
909
|
-
}
|
|
910
|
-
// Auto-register the custom element
|
|
911
|
-
if (typeof customElements !== 'undefined' &&
|
|
912
|
-
!customElements.get('mp-splitter')) {
|
|
913
|
-
customElements.define('mp-splitter', MpSplitter);
|
|
914
|
-
}
|
|
915
|
-
|
|
916
|
-
// Main component export
|
|
917
|
-
|
|
918
|
-
/**
|
|
919
|
-
* Generated bundle index. Do not edit.
|
|
920
|
-
*/
|
|
921
|
-
|
|
922
|
-
export { InputHandler, MpSplitter, ResizeManager, ResizeState, SplitterStateManager, normalizePointerEvent, splitterStyles };
|
|
923
|
-
//# sourceMappingURL=mintplayer-ng-bootstrap-web-components-splitter.mjs.map
|