@coreui/coreui 5.0.0-alpha.0 → 5.0.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +5 -5
- package/README.md +2 -2
- package/dist/css/coreui-grid.css +34 -192
- package/dist/css/coreui-grid.css.map +1 -1
- package/dist/css/coreui-grid.min.css +3 -3
- package/dist/css/coreui-grid.min.css.map +1 -1
- package/dist/css/coreui-grid.rtl.css +118 -275
- package/dist/css/coreui-grid.rtl.css.map +1 -1
- package/dist/css/coreui-grid.rtl.min.css +3 -3
- package/dist/css/coreui-grid.rtl.min.css.map +1 -1
- package/dist/css/coreui-reboot.css +166 -148
- package/dist/css/coreui-reboot.css.map +1 -1
- package/dist/css/coreui-reboot.min.css +3 -3
- package/dist/css/coreui-reboot.min.css.map +1 -1
- package/dist/css/coreui-reboot.rtl.css +170 -156
- package/dist/css/coreui-reboot.rtl.css.map +1 -1
- package/dist/css/coreui-reboot.rtl.min.css +3 -3
- package/dist/css/coreui-reboot.rtl.min.css.map +1 -1
- package/dist/css/coreui-utilities.css +653 -427
- package/dist/css/coreui-utilities.css.map +1 -1
- package/dist/css/coreui-utilities.min.css +3 -3
- package/dist/css/coreui-utilities.min.css.map +1 -1
- package/dist/css/coreui-utilities.rtl.css +824 -703
- package/dist/css/coreui-utilities.rtl.css.map +1 -1
- package/dist/css/coreui-utilities.rtl.min.css +3 -3
- package/dist/css/coreui-utilities.rtl.min.css.map +1 -1
- package/dist/css/coreui.css +2082 -1790
- package/dist/css/coreui.css.map +1 -1
- package/dist/css/coreui.min.css +3 -3
- package/dist/css/coreui.min.css.map +1 -1
- package/dist/css/coreui.rtl.css +2333 -2213
- package/dist/css/coreui.rtl.css.map +1 -1
- package/dist/css/coreui.rtl.min.css +3 -3
- package/dist/css/coreui.rtl.min.css.map +1 -1
- package/dist/js/coreui.bundle.js +313 -292
- package/dist/js/coreui.bundle.js.map +1 -1
- package/dist/js/coreui.bundle.min.js +2 -2
- package/dist/js/coreui.bundle.min.js.map +1 -1
- package/dist/js/coreui.esm.js +273 -246
- package/dist/js/coreui.esm.js.map +1 -1
- package/dist/js/coreui.esm.min.js +2 -2
- package/dist/js/coreui.esm.min.js.map +1 -1
- package/dist/js/coreui.js +276 -248
- package/dist/js/coreui.js.map +1 -1
- package/dist/js/coreui.min.js +2 -2
- package/dist/js/coreui.min.js.map +1 -1
- package/js/dist/alert.js +7 -6
- package/js/dist/alert.js.map +1 -1
- package/js/dist/base-component.js +8 -7
- package/js/dist/base-component.js.map +1 -1
- package/js/dist/button.js +7 -6
- package/js/dist/button.js.map +1 -1
- package/js/dist/carousel.js +8 -7
- package/js/dist/carousel.js.map +1 -1
- package/js/dist/collapse.js +7 -6
- package/js/dist/collapse.js.map +1 -1
- package/js/dist/dom/data.js +3 -3
- package/js/dist/dom/data.js.map +1 -1
- package/js/dist/dom/event-handler.js +7 -7
- package/js/dist/dom/event-handler.js.map +1 -1
- package/js/dist/dom/manipulator.js +4 -4
- package/js/dist/dom/manipulator.js.map +1 -1
- package/js/dist/dom/selector-engine.js +4 -3
- package/js/dist/dom/selector-engine.js.map +1 -1
- package/js/dist/dropdown.js +10 -9
- package/js/dist/dropdown.js.map +1 -1
- package/js/dist/modal.js +9 -10
- package/js/dist/modal.js.map +1 -1
- package/js/dist/navigation.js +7 -6
- package/js/dist/navigation.js.map +1 -1
- package/js/dist/offcanvas.js +11 -10
- package/js/dist/offcanvas.js.map +1 -1
- package/js/dist/popover.js +7 -6
- package/js/dist/popover.js.map +1 -1
- package/js/dist/scrollspy.js +9 -8
- package/js/dist/scrollspy.js.map +1 -1
- package/js/dist/sidebar.js +7 -6
- package/js/dist/sidebar.js.map +1 -1
- package/js/dist/tab.js +21 -12
- package/js/dist/tab.js.map +1 -1
- package/js/dist/toast.js +7 -6
- package/js/dist/toast.js.map +1 -1
- package/js/dist/tooltip.js +12 -11
- package/js/dist/tooltip.js.map +1 -1
- package/js/dist/util/backdrop.js +8 -7
- package/js/dist/util/backdrop.js.map +1 -1
- package/js/dist/util/component-functions.js +8 -7
- package/js/dist/util/component-functions.js.map +1 -1
- package/js/dist/util/config.js +8 -7
- package/js/dist/util/config.js.map +1 -1
- package/js/dist/util/focustrap.js +4 -3
- package/js/dist/util/focustrap.js.map +1 -1
- package/js/dist/util/index.js +3 -3
- package/js/dist/util/index.js.map +1 -1
- package/js/dist/util/sanitizer.js +28 -30
- package/js/dist/util/sanitizer.js.map +1 -1
- package/js/dist/util/scrollbar.js +8 -7
- package/js/dist/util/scrollbar.js.map +1 -1
- package/js/dist/util/swipe.js +8 -7
- package/js/dist/util/swipe.js.map +1 -1
- package/js/dist/util/template-factory.js +8 -7
- package/js/dist/util/template-factory.js.map +1 -1
- package/js/index.esm.js +21 -0
- package/js/index.umd.js +38 -0
- package/js/src/alert.js +3 -3
- package/js/src/base-component.js +3 -3
- package/js/src/button.js +4 -3
- package/js/src/carousel.js +6 -6
- package/js/src/collapse.js +4 -4
- package/js/src/dom/data.js +2 -2
- package/js/src/dom/event-handler.js +4 -5
- package/js/src/dom/manipulator.js +3 -3
- package/js/src/dom/selector-engine.js +2 -2
- package/js/src/dropdown.js +8 -8
- package/js/src/modal.js +8 -9
- package/js/src/navigation.js +3 -3
- package/js/src/offcanvas.js +11 -11
- package/js/src/popover.js +2 -2
- package/js/src/scrollspy.js +5 -5
- package/js/src/sidebar.js +4 -4
- package/js/src/tab.js +19 -9
- package/js/src/toast.js +3 -3
- package/js/src/tooltip.js +9 -9
- package/js/src/util/backdrop.js +3 -3
- package/js/src/util/component-functions.js +3 -3
- package/js/src/util/config.js +3 -3
- package/js/src/util/focustrap.js +2 -2
- package/js/src/util/index.js +2 -2
- package/js/src/util/sanitizer.js +40 -43
- package/js/src/util/scrollbar.js +3 -3
- package/js/src/util/swipe.js +3 -3
- package/js/src/util/template-factory.js +4 -5
- package/package.json +51 -45
- package/scss/_alert.scss +5 -5
- package/scss/_avatar.scss +4 -4
- package/scss/_badge.scss +11 -1
- package/scss/_breadcrumb.scss +9 -4
- package/scss/_button-group.scss +4 -4
- package/scss/_buttons.scss +38 -71
- package/scss/_callout.scss +2 -2
- package/scss/_card.scss +4 -3
- package/scss/_carousel.scss +9 -3
- package/scss/_close.scss +3 -0
- package/scss/_dropdown.scss +14 -14
- package/scss/_functions.scss +59 -0
- package/scss/_grid.scss +8 -0
- package/scss/_header.scss +186 -0
- package/scss/_helpers.scss +2 -0
- package/scss/_images.scss +3 -3
- package/scss/_list-group.scss +12 -19
- package/scss/_maps.scss +75 -21
- package/scss/_mixins.scss +6 -4
- package/scss/_modal.scss +2 -2
- package/scss/_nav.scss +8 -20
- package/scss/_navbar.scss +11 -8
- package/scss/_offcanvas.scss +8 -8
- package/scss/_pagination.scss +2 -2
- package/scss/_progress.scss +43 -0
- package/scss/_reboot.scss +23 -25
- package/scss/_root.scss +70 -63
- package/scss/_sidebar.scss +0 -11
- package/scss/_tables.scss +18 -11
- package/scss/_toasts.scss +2 -2
- package/scss/_tooltip.scss +14 -15
- package/scss/_type.scss +1 -1
- package/scss/_utilities.scss +117 -65
- package/scss/_variables-dark.scss +112 -61
- package/scss/_variables.scss +401 -268
- package/scss/coreui-grid.rtl.scss +4 -0
- package/scss/coreui-grid.scss +2 -5
- package/scss/coreui-reboot.rtl.scss +4 -0
- package/scss/coreui-reboot.scss +1 -1
- package/scss/coreui-utilities.rtl.scss +4 -0
- package/scss/coreui-utilities.scss +1 -1
- package/scss/coreui.rtl.scss +4 -0
- package/scss/coreui.scss +3 -3
- package/scss/forms/_floating-labels.scss +21 -16
- package/scss/forms/_form-check.scss +41 -20
- package/scss/forms/_form-control.scss +18 -5
- package/scss/forms/_form-range.scss +3 -3
- package/scss/forms/_form-select.scss +7 -8
- package/scss/forms/_input-group.scss +5 -5
- package/scss/helpers/_color-bg.scss +13 -4
- package/scss/helpers/_colored-links.scss +20 -2
- package/scss/helpers/_focus-ring.scss +5 -0
- package/scss/helpers/_icon-link.scss +25 -0
- package/scss/helpers/_ratio.scss +1 -1
- package/scss/helpers/_vr.scss +2 -1
- package/scss/mixins/_alert.scss +1 -1
- package/scss/mixins/_banner.scss +3 -3
- package/scss/mixins/_border-radius.scss +7 -7
- package/scss/mixins/_buttons.scss +53 -49
- package/scss/mixins/_caret.scss +3 -3
- package/scss/mixins/_forms.scss +7 -7
- package/scss/mixins/_grid.scss +1 -1
- package/scss/mixins/_list-group.scss +12 -20
- package/scss/mixins/_lists.scss +1 -1
- package/scss/mixins/_ltr-rtl.scss +87 -0
- package/scss/mixins/_utilities.scss +6 -1
- package/scss/mixins/_visually-hidden.scss +5 -1
- package/scss/sidebar/_sidebar-narrow.scss +37 -17
- package/scss/sidebar/_sidebar-nav.scss +115 -20
- package/scss/sidebar/_sidebar.scss +98 -139
- package/scss/vendor/_rfs.scss +24 -30
- package/scss/tests/mixins/_color-modes.test.scss +0 -69
- package/scss/tests/mixins/_utilities.test.scss +0 -393
- package/scss/tests/utilities/_api.test.scss +0 -75
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI dom/manipulator.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's dom/manipulator.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
@@ -55,7 +55,7 @@ const Manipulator = {
|
|
|
55
55
|
}
|
|
56
56
|
|
|
57
57
|
const attributes = {}
|
|
58
|
-
const coreuiKeys = Object.keys(element.dataset).filter(key => key.startsWith('
|
|
58
|
+
const coreuiKeys = Object.keys(element.dataset).filter(key => key.startsWith('coreui') && !key.startsWith('coreuiConfig'))
|
|
59
59
|
|
|
60
60
|
for (const key of coreuiKeys) {
|
|
61
61
|
let pureKey = key.replace(/^coreui/, '')
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI dom/selector-engine.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's dom/selector-engine.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
package/js/src/dropdown.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI dropdown.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
6
|
* This component is a modified version of the Bootstrap's dropdown.js
|
|
@@ -9,6 +9,10 @@
|
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
import * as Popper from '@popperjs/core'
|
|
12
|
+
import BaseComponent from './base-component.js'
|
|
13
|
+
import EventHandler from './dom/event-handler.js'
|
|
14
|
+
import Manipulator from './dom/manipulator.js'
|
|
15
|
+
import SelectorEngine from './dom/selector-engine.js'
|
|
12
16
|
import {
|
|
13
17
|
defineJQueryPlugin,
|
|
14
18
|
execute,
|
|
@@ -20,10 +24,6 @@ import {
|
|
|
20
24
|
isVisible,
|
|
21
25
|
noop
|
|
22
26
|
} from './util/index.js'
|
|
23
|
-
import EventHandler from './dom/event-handler.js'
|
|
24
|
-
import Manipulator from './dom/manipulator.js'
|
|
25
|
-
import SelectorEngine from './dom/selector-engine.js'
|
|
26
|
-
import BaseComponent from './base-component.js'
|
|
27
27
|
|
|
28
28
|
/**
|
|
29
29
|
* Constants
|
|
@@ -99,7 +99,7 @@ class Dropdown extends BaseComponent {
|
|
|
99
99
|
|
|
100
100
|
this._popper = null
|
|
101
101
|
this._parent = this._element.parentNode // dropdown wrapper
|
|
102
|
-
//
|
|
102
|
+
// TODO: v6 revert #37011 & change markup https://getbootstrap.com/docs/5.3/forms/input-group/
|
|
103
103
|
this._menu = SelectorEngine.next(this._element, SELECTOR_MENU)[0] ||
|
|
104
104
|
SelectorEngine.prev(this._element, SELECTOR_MENU)[0] ||
|
|
105
105
|
SelectorEngine.findOne(SELECTOR_MENU, this._parent)
|
|
@@ -314,7 +314,7 @@ class Dropdown extends BaseComponent {
|
|
|
314
314
|
|
|
315
315
|
// Disable Popper if we have a static display or Dropdown is in Navbar
|
|
316
316
|
if (this._inNavbar || this._config.display === 'static') {
|
|
317
|
-
Manipulator.setDataAttribute(this._menu, 'popper', 'static') //
|
|
317
|
+
Manipulator.setDataAttribute(this._menu, 'popper', 'static') // TODO: v6 remove
|
|
318
318
|
defaultBsPopperConfig.modifiers = [{
|
|
319
319
|
name: 'applyStyles',
|
|
320
320
|
enabled: false
|
|
@@ -412,7 +412,7 @@ class Dropdown extends BaseComponent {
|
|
|
412
412
|
|
|
413
413
|
event.preventDefault()
|
|
414
414
|
|
|
415
|
-
//
|
|
415
|
+
// TODO: v6 revert #37011 & change markup https://getbootstrap.com/docs/5.3/forms/input-group/
|
|
416
416
|
const getToggleButton = this.matches(SELECTOR_DATA_TOGGLE) ?
|
|
417
417
|
this :
|
|
418
418
|
(SelectorEngine.prev(this, SELECTOR_DATA_TOGGLE)[0] ||
|
package/js/src/modal.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI modal.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
6
|
* This component is a modified version of the Bootstrap's modal.js
|
|
@@ -8,14 +8,14 @@
|
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
import
|
|
11
|
+
import BaseComponent from './base-component.js'
|
|
12
12
|
import EventHandler from './dom/event-handler.js'
|
|
13
13
|
import SelectorEngine from './dom/selector-engine.js'
|
|
14
|
-
import ScrollBarHelper from './util/scrollbar.js'
|
|
15
|
-
import BaseComponent from './base-component.js'
|
|
16
14
|
import Backdrop from './util/backdrop.js'
|
|
17
|
-
import FocusTrap from './util/focustrap.js'
|
|
18
15
|
import { enableDismissTrigger } from './util/component-functions.js'
|
|
16
|
+
import FocusTrap from './util/focustrap.js'
|
|
17
|
+
import { defineJQueryPlugin, isRTL, isVisible, reflow } from './util/index.js'
|
|
18
|
+
import ScrollBarHelper from './util/scrollbar.js'
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* Constants
|
|
@@ -142,12 +142,12 @@ class Modal extends BaseComponent {
|
|
|
142
142
|
}
|
|
143
143
|
|
|
144
144
|
dispose() {
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
}
|
|
145
|
+
EventHandler.off(window, EVENT_KEY)
|
|
146
|
+
EventHandler.off(this._dialog, EVENT_KEY)
|
|
148
147
|
|
|
149
148
|
this._backdrop.dispose()
|
|
150
149
|
this._focustrap.deactivate()
|
|
150
|
+
|
|
151
151
|
super.dispose()
|
|
152
152
|
}
|
|
153
153
|
|
|
@@ -211,7 +211,6 @@ class Modal extends BaseComponent {
|
|
|
211
211
|
}
|
|
212
212
|
|
|
213
213
|
if (this._config.keyboard) {
|
|
214
|
-
event.preventDefault()
|
|
215
214
|
this.hide()
|
|
216
215
|
return
|
|
217
216
|
}
|
package/js/src/navigation.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI navigation.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
* --------------------------------------------------------------------------
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import
|
|
8
|
+
import BaseComponent from './base-component.js'
|
|
9
9
|
import Data from './dom/data.js'
|
|
10
10
|
import EventHandler from './dom/event-handler.js'
|
|
11
11
|
import Manipulator from './dom/manipulator.js'
|
|
12
12
|
import SelectorEngine from './dom/selector-engine.js'
|
|
13
|
-
import
|
|
13
|
+
import { defineJQueryPlugin } from './util/index.js'
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* ------------------------------------------------------------------------
|
package/js/src/offcanvas.js
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI offcanvas.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
6
|
* This component is a modified version of the Bootstrap's offcanvas.js
|
|
7
|
-
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/
|
|
7
|
+
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
+
import BaseComponent from './base-component.js'
|
|
12
|
+
import EventHandler from './dom/event-handler.js'
|
|
13
|
+
import SelectorEngine from './dom/selector-engine.js'
|
|
14
|
+
import Backdrop from './util/backdrop.js'
|
|
15
|
+
import { enableDismissTrigger } from './util/component-functions.js'
|
|
16
|
+
import FocusTrap from './util/focustrap.js'
|
|
11
17
|
import {
|
|
12
18
|
defineJQueryPlugin,
|
|
13
19
|
isDisabled,
|
|
14
20
|
isVisible
|
|
15
21
|
} from './util/index.js'
|
|
16
22
|
import ScrollBarHelper from './util/scrollbar.js'
|
|
17
|
-
import EventHandler from './dom/event-handler.js'
|
|
18
|
-
import BaseComponent from './base-component.js'
|
|
19
|
-
import SelectorEngine from './dom/selector-engine.js'
|
|
20
|
-
import Backdrop from './util/backdrop.js'
|
|
21
|
-
import FocusTrap from './util/focustrap.js'
|
|
22
|
-
import { enableDismissTrigger } from './util/component-functions.js'
|
|
23
23
|
|
|
24
24
|
/**
|
|
25
25
|
* Constants
|
|
@@ -201,12 +201,12 @@ class Offcanvas extends BaseComponent {
|
|
|
201
201
|
return
|
|
202
202
|
}
|
|
203
203
|
|
|
204
|
-
if (
|
|
205
|
-
|
|
204
|
+
if (this._config.keyboard) {
|
|
205
|
+
this.hide()
|
|
206
206
|
return
|
|
207
207
|
}
|
|
208
208
|
|
|
209
|
-
this.
|
|
209
|
+
EventHandler.trigger(this._element, EVENT_HIDE_PREVENTED)
|
|
210
210
|
})
|
|
211
211
|
}
|
|
212
212
|
|
package/js/src/popover.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI popover.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
6
|
* This component is a modified version of the Bootstrap's popover.js
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
import { defineJQueryPlugin } from './util/index.js'
|
|
12
11
|
import Tooltip from './tooltip.js'
|
|
12
|
+
import { defineJQueryPlugin } from './util/index.js'
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* Constants
|
package/js/src/scrollspy.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI scrollspy.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
6
|
* This component is a modified version of the Bootstrap's scrollspy.js
|
|
@@ -8,10 +8,10 @@
|
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
import
|
|
11
|
+
import BaseComponent from './base-component.js'
|
|
12
12
|
import EventHandler from './dom/event-handler.js'
|
|
13
13
|
import SelectorEngine from './dom/selector-engine.js'
|
|
14
|
-
import
|
|
14
|
+
import { defineJQueryPlugin, getElement, isDisabled, isVisible } from './util/index.js'
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* Constants
|
|
@@ -211,11 +211,11 @@ class ScrollSpy extends BaseComponent {
|
|
|
211
211
|
continue
|
|
212
212
|
}
|
|
213
213
|
|
|
214
|
-
const observableSection = SelectorEngine.findOne(anchor.hash, this._element)
|
|
214
|
+
const observableSection = SelectorEngine.findOne(decodeURI(anchor.hash), this._element)
|
|
215
215
|
|
|
216
216
|
// ensure that the observableSection exists & is visible
|
|
217
217
|
if (isVisible(observableSection)) {
|
|
218
|
-
this._targetLinks.set(anchor.hash, anchor)
|
|
218
|
+
this._targetLinks.set(decodeURI(anchor.hash), anchor)
|
|
219
219
|
this._observableSections.set(anchor.hash, observableSection)
|
|
220
220
|
}
|
|
221
221
|
}
|
package/js/src/sidebar.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI sidebar.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
* --------------------------------------------------------------------------
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
import { defineJQueryPlugin } from './util/index.js'
|
|
9
|
-
import ScrollBarHelper from './util/scrollbar.js'
|
|
10
|
-
import EventHandler from './dom/event-handler.js'
|
|
11
8
|
import BaseComponent from './base-component.js'
|
|
9
|
+
import EventHandler from './dom/event-handler.js'
|
|
12
10
|
import Manipulator from './dom/manipulator.js'
|
|
11
|
+
import { defineJQueryPlugin } from './util/index.js'
|
|
13
12
|
import Backdrop from './util/backdrop.js'
|
|
13
|
+
import ScrollBarHelper from './util/scrollbar.js'
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* ------------------------------------------------------------------------
|
package/js/src/tab.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI tab.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
6
|
* This component is a modified version of the Bootstrap's tab.js
|
|
@@ -8,10 +8,10 @@
|
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
import
|
|
11
|
+
import BaseComponent from './base-component.js'
|
|
12
12
|
import EventHandler from './dom/event-handler.js'
|
|
13
13
|
import SelectorEngine from './dom/selector-engine.js'
|
|
14
|
-
import
|
|
14
|
+
import { defineJQueryPlugin, getNextActiveElement, isDisabled } from './util/index.js'
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* Constants
|
|
@@ -33,6 +33,8 @@ const ARROW_LEFT_KEY = 'ArrowLeft'
|
|
|
33
33
|
const ARROW_RIGHT_KEY = 'ArrowRight'
|
|
34
34
|
const ARROW_UP_KEY = 'ArrowUp'
|
|
35
35
|
const ARROW_DOWN_KEY = 'ArrowDown'
|
|
36
|
+
const HOME_KEY = 'Home'
|
|
37
|
+
const END_KEY = 'End'
|
|
36
38
|
|
|
37
39
|
const CLASS_NAME_ACTIVE = 'active'
|
|
38
40
|
const CLASS_NAME_FADE = 'fade'
|
|
@@ -46,7 +48,7 @@ const NOT_SELECTOR_DROPDOWN_TOGGLE = ':not(.dropdown-toggle)'
|
|
|
46
48
|
const SELECTOR_TAB_PANEL = '.list-group, .nav, [role="tablist"]'
|
|
47
49
|
const SELECTOR_OUTER = '.nav-item, .list-group-item'
|
|
48
50
|
const SELECTOR_INNER = `.nav-link${NOT_SELECTOR_DROPDOWN_TOGGLE}, .list-group-item${NOT_SELECTOR_DROPDOWN_TOGGLE}, [role="tab"]${NOT_SELECTOR_DROPDOWN_TOGGLE}`
|
|
49
|
-
const SELECTOR_DATA_TOGGLE = '[data-coreui-toggle="tab"], [data-coreui-toggle="pill"], [data-coreui-toggle="list"]' //
|
|
51
|
+
const SELECTOR_DATA_TOGGLE = '[data-coreui-toggle="tab"], [data-coreui-toggle="pill"], [data-coreui-toggle="list"]' // TODO: could only be `tab` in v6
|
|
50
52
|
const SELECTOR_INNER_ELEM = `${SELECTOR_INNER}, ${SELECTOR_DATA_TOGGLE}`
|
|
51
53
|
|
|
52
54
|
const SELECTOR_DATA_TOGGLE_ACTIVE = `.${CLASS_NAME_ACTIVE}[data-coreui-toggle="tab"], .${CLASS_NAME_ACTIVE}[data-coreui-toggle="pill"], .${CLASS_NAME_ACTIVE}[data-coreui-toggle="list"]`
|
|
@@ -62,7 +64,7 @@ class Tab extends BaseComponent {
|
|
|
62
64
|
|
|
63
65
|
if (!this._parent) {
|
|
64
66
|
return
|
|
65
|
-
//
|
|
67
|
+
// TODO: should throw exception in v6
|
|
66
68
|
// throw new TypeError(`${element.outerHTML} has not a valid parent ${SELECTOR_INNER_ELEM}`)
|
|
67
69
|
}
|
|
68
70
|
|
|
@@ -154,14 +156,22 @@ class Tab extends BaseComponent {
|
|
|
154
156
|
}
|
|
155
157
|
|
|
156
158
|
_keydown(event) {
|
|
157
|
-
if (!([ARROW_LEFT_KEY, ARROW_RIGHT_KEY, ARROW_UP_KEY, ARROW_DOWN_KEY].includes(event.key))) {
|
|
159
|
+
if (!([ARROW_LEFT_KEY, ARROW_RIGHT_KEY, ARROW_UP_KEY, ARROW_DOWN_KEY, HOME_KEY, END_KEY].includes(event.key))) {
|
|
158
160
|
return
|
|
159
161
|
}
|
|
160
162
|
|
|
161
163
|
event.stopPropagation()// stopPropagation/preventDefault both added to support up/down keys without scrolling the page
|
|
162
164
|
event.preventDefault()
|
|
163
|
-
|
|
164
|
-
const
|
|
165
|
+
|
|
166
|
+
const children = this._getChildren().filter(element => !isDisabled(element))
|
|
167
|
+
let nextActiveElement
|
|
168
|
+
|
|
169
|
+
if ([HOME_KEY, END_KEY].includes(event.key)) {
|
|
170
|
+
nextActiveElement = children[event.key === HOME_KEY ? 0 : children.length - 1]
|
|
171
|
+
} else {
|
|
172
|
+
const isNext = [ARROW_RIGHT_KEY, ARROW_DOWN_KEY].includes(event.key)
|
|
173
|
+
nextActiveElement = getNextActiveElement(children, event.target, isNext, true)
|
|
174
|
+
}
|
|
165
175
|
|
|
166
176
|
if (nextActiveElement) {
|
|
167
177
|
nextActiveElement.focus({ preventScroll: true })
|
|
@@ -215,7 +225,7 @@ class Tab extends BaseComponent {
|
|
|
215
225
|
this._setAttributeIfNotExists(target, 'role', 'tabpanel')
|
|
216
226
|
|
|
217
227
|
if (child.id) {
|
|
218
|
-
this._setAttributeIfNotExists(target, 'aria-labelledby',
|
|
228
|
+
this._setAttributeIfNotExists(target, 'aria-labelledby', `${child.id}`)
|
|
219
229
|
}
|
|
220
230
|
}
|
|
221
231
|
|
package/js/src/toast.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI toast.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
6
|
* This component is a modified version of the Bootstrap's toast.js
|
|
@@ -8,10 +8,10 @@
|
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
import { defineJQueryPlugin, reflow } from './util/index.js'
|
|
12
|
-
import EventHandler from './dom/event-handler.js'
|
|
13
11
|
import BaseComponent from './base-component.js'
|
|
12
|
+
import EventHandler from './dom/event-handler.js'
|
|
14
13
|
import { enableDismissTrigger } from './util/component-functions.js'
|
|
14
|
+
import { defineJQueryPlugin, reflow } from './util/index.js'
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* Constants
|
package/js/src/tooltip.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI tooltip.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
6
|
* This component is a modified version of the Bootstrap's tooltip.js
|
|
@@ -9,11 +9,11 @@
|
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
import * as Popper from '@popperjs/core'
|
|
12
|
-
import
|
|
13
|
-
import { DefaultAllowlist } from './util/sanitizer.js'
|
|
12
|
+
import BaseComponent from './base-component.js'
|
|
14
13
|
import EventHandler from './dom/event-handler.js'
|
|
15
14
|
import Manipulator from './dom/manipulator.js'
|
|
16
|
-
import
|
|
15
|
+
import { defineJQueryPlugin, execute, findShadowRoot, getElement, getUID, isRTL, noop } from './util/index.js'
|
|
16
|
+
import { DefaultAllowlist } from './util/sanitizer.js'
|
|
17
17
|
import TemplateFactory from './util/template-factory.js'
|
|
18
18
|
|
|
19
19
|
/**
|
|
@@ -65,7 +65,7 @@ const Default = {
|
|
|
65
65
|
delay: 0,
|
|
66
66
|
fallbackPlacements: ['top', 'right', 'bottom', 'left'],
|
|
67
67
|
html: false,
|
|
68
|
-
offset: [0,
|
|
68
|
+
offset: [0, 6],
|
|
69
69
|
placement: 'top',
|
|
70
70
|
popperConfig: null,
|
|
71
71
|
sanitize: true,
|
|
@@ -200,7 +200,7 @@ class Tooltip extends BaseComponent {
|
|
|
200
200
|
return
|
|
201
201
|
}
|
|
202
202
|
|
|
203
|
-
//
|
|
203
|
+
// TODO: v6 remove this or make it optional
|
|
204
204
|
this._disposePopper()
|
|
205
205
|
|
|
206
206
|
const tip = this._getTipElement()
|
|
@@ -305,14 +305,14 @@ class Tooltip extends BaseComponent {
|
|
|
305
305
|
_createTipElement(content) {
|
|
306
306
|
const tip = this._getTemplateFactory(content).toHtml()
|
|
307
307
|
|
|
308
|
-
//
|
|
308
|
+
// TODO: remove this check in v6
|
|
309
309
|
if (!tip) {
|
|
310
310
|
return null
|
|
311
311
|
}
|
|
312
312
|
|
|
313
313
|
tip.classList.remove(CLASS_NAME_FADE, CLASS_NAME_SHOW)
|
|
314
|
-
//
|
|
315
|
-
tip.classList.add(`
|
|
314
|
+
// TODO: v6 the following can be achieved with CSS only
|
|
315
|
+
tip.classList.add(`bs-${this.constructor.NAME}-auto`)
|
|
316
316
|
|
|
317
317
|
const tipId = getUID(this.constructor.NAME).toString()
|
|
318
318
|
|
package/js/src/util/backdrop.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI util/backdrop.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's util/backdrop.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
import EventHandler from '../dom/event-handler.js'
|
|
12
|
-
import { execute, executeAfterTransition, getElement, reflow } from './index.js'
|
|
13
12
|
import Config from './config.js'
|
|
13
|
+
import { execute, executeAfterTransition, getElement, reflow } from './index.js'
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* Constants
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI util/component-functions.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's util/component-functions.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
import EventHandler from '../dom/event-handler.js'
|
|
12
|
-
import { isDisabled } from './index.js'
|
|
13
12
|
import SelectorEngine from '../dom/selector-engine.js'
|
|
13
|
+
import { isDisabled } from './index.js'
|
|
14
14
|
|
|
15
15
|
const enableDismissTrigger = (component, method = 'hide') => {
|
|
16
16
|
const clickEvent = `click.dismiss${component.EVENT_KEY}`
|
package/js/src/util/config.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI util/config.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's util/config.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
import { isElement, toType } from './index.js'
|
|
12
11
|
import Manipulator from '../dom/manipulator.js'
|
|
12
|
+
import { isElement, toType } from './index.js'
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* Class definition
|
package/js/src/util/focustrap.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI util/focustrap.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's util/focustrap.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
package/js/src/util/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI util/index.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's util/index.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
package/js/src/util/sanitizer.js
CHANGED
|
@@ -1,56 +1,16 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI util/sanitizer.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's util/sanitizer.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
'background',
|
|
13
|
-
'cite',
|
|
14
|
-
'href',
|
|
15
|
-
'itemtype',
|
|
16
|
-
'longdesc',
|
|
17
|
-
'poster',
|
|
18
|
-
'src',
|
|
19
|
-
'xlink:href'
|
|
20
|
-
])
|
|
21
|
-
|
|
11
|
+
// js-docs-start allow-list
|
|
22
12
|
const ARIA_ATTRIBUTE_PATTERN = /^aria-[\w-]*$/i
|
|
23
13
|
|
|
24
|
-
/**
|
|
25
|
-
* A pattern that recognizes a commonly useful subset of URLs that are safe.
|
|
26
|
-
*
|
|
27
|
-
* Shout-out to Angular https://github.com/angular/angular/blob/12.2.x/packages/core/src/sanitization/url_sanitizer.ts
|
|
28
|
-
*/
|
|
29
|
-
const SAFE_URL_PATTERN = /^(?:(?:https?|mailto|ftp|tel|file|sms):|[^#&/:?]*(?:[#/?]|$))/i
|
|
30
|
-
|
|
31
|
-
/**
|
|
32
|
-
* A pattern that matches safe data URLs. Only matches image, video and audio types.
|
|
33
|
-
*
|
|
34
|
-
* Shout-out to Angular https://github.com/angular/angular/blob/12.2.x/packages/core/src/sanitization/url_sanitizer.ts
|
|
35
|
-
*/
|
|
36
|
-
const DATA_URL_PATTERN = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[\d+/a-z]+=*$/i
|
|
37
|
-
|
|
38
|
-
const allowedAttribute = (attribute, allowedAttributeList) => {
|
|
39
|
-
const attributeName = attribute.nodeName.toLowerCase()
|
|
40
|
-
|
|
41
|
-
if (allowedAttributeList.includes(attributeName)) {
|
|
42
|
-
if (uriAttributes.has(attributeName)) {
|
|
43
|
-
return Boolean(SAFE_URL_PATTERN.test(attribute.nodeValue) || DATA_URL_PATTERN.test(attribute.nodeValue))
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
return true
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
// Check if a regular expression validates the attribute.
|
|
50
|
-
return allowedAttributeList.filter(attributeRegex => attributeRegex instanceof RegExp)
|
|
51
|
-
.some(regex => regex.test(attributeName))
|
|
52
|
-
}
|
|
53
|
-
|
|
54
14
|
export const DefaultAllowlist = {
|
|
55
15
|
// Global attributes allowed on any supplied element below.
|
|
56
16
|
'*': ['class', 'dir', 'id', 'lang', 'role', ARIA_ATTRIBUTE_PATTERN],
|
|
@@ -84,6 +44,43 @@ export const DefaultAllowlist = {
|
|
|
84
44
|
u: [],
|
|
85
45
|
ul: []
|
|
86
46
|
}
|
|
47
|
+
// js-docs-end allow-list
|
|
48
|
+
|
|
49
|
+
const uriAttributes = new Set([
|
|
50
|
+
'background',
|
|
51
|
+
'cite',
|
|
52
|
+
'href',
|
|
53
|
+
'itemtype',
|
|
54
|
+
'longdesc',
|
|
55
|
+
'poster',
|
|
56
|
+
'src',
|
|
57
|
+
'xlink:href'
|
|
58
|
+
])
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* A pattern that recognizes URLs that are safe wrt. XSS in URL navigation
|
|
62
|
+
* contexts.
|
|
63
|
+
*
|
|
64
|
+
* Shout-out to Angular https://github.com/angular/angular/blob/15.2.8/packages/core/src/sanitization/url_sanitizer.ts#L38
|
|
65
|
+
*/
|
|
66
|
+
// eslint-disable-next-line unicorn/better-regex
|
|
67
|
+
const SAFE_URL_PATTERN = /^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i
|
|
68
|
+
|
|
69
|
+
const allowedAttribute = (attribute, allowedAttributeList) => {
|
|
70
|
+
const attributeName = attribute.nodeName.toLowerCase()
|
|
71
|
+
|
|
72
|
+
if (allowedAttributeList.includes(attributeName)) {
|
|
73
|
+
if (uriAttributes.has(attributeName)) {
|
|
74
|
+
return Boolean(SAFE_URL_PATTERN.test(attribute.nodeValue))
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
return true
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
// Check if a regular expression validates the attribute.
|
|
81
|
+
return allowedAttributeList.filter(attributeRegex => attributeRegex instanceof RegExp)
|
|
82
|
+
.some(regex => regex.test(attributeName))
|
|
83
|
+
}
|
|
87
84
|
|
|
88
85
|
export function sanitizeHtml(unsafeHtml, allowList, sanitizeFunction) {
|
|
89
86
|
if (!unsafeHtml.length) {
|
package/js/src/util/scrollbar.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* --------------------------------------------------------------------------
|
|
3
|
-
* CoreUI
|
|
3
|
+
* CoreUI util/scrollBar.js
|
|
4
4
|
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
|
|
5
5
|
*
|
|
6
|
-
* This
|
|
6
|
+
* This is a modified version of the Bootstrap's util/scrollBar.js
|
|
7
7
|
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
|
|
8
8
|
* --------------------------------------------------------------------------
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
|
-
import SelectorEngine from '../dom/selector-engine.js'
|
|
12
11
|
import Manipulator from '../dom/manipulator.js'
|
|
12
|
+
import SelectorEngine from '../dom/selector-engine.js'
|
|
13
13
|
import { isElement } from './index.js'
|
|
14
14
|
|
|
15
15
|
/**
|