@coreui/coreui 4.2.5 → 4.3.0-alpha.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.
Files changed (194) hide show
  1. package/LICENSE +5 -6
  2. package/README.md +2 -2
  3. package/dist/css/coreui-grid.css +36 -83
  4. package/dist/css/coreui-grid.css.map +1 -1
  5. package/dist/css/coreui-grid.min.css +4 -6
  6. package/dist/css/coreui-grid.min.css.map +1 -1
  7. package/dist/css/coreui-grid.rtl.css +40 -89
  8. package/dist/css/coreui-grid.rtl.css.map +1 -1
  9. package/dist/css/coreui-grid.rtl.min.css +8 -12
  10. package/dist/css/coreui-grid.rtl.min.css.map +1 -1
  11. package/dist/css/coreui-reboot.css +176 -48
  12. package/dist/css/coreui-reboot.css.map +1 -1
  13. package/dist/css/coreui-reboot.min.css +4 -6
  14. package/dist/css/coreui-reboot.min.css.map +1 -1
  15. package/dist/css/coreui-reboot.rtl.css +180 -54
  16. package/dist/css/coreui-reboot.rtl.css.map +1 -1
  17. package/dist/css/coreui-reboot.rtl.min.css +8 -12
  18. package/dist/css/coreui-reboot.rtl.min.css.map +1 -1
  19. package/dist/css/coreui-utilities.css +1328 -95
  20. package/dist/css/coreui-utilities.css.map +1 -1
  21. package/dist/css/coreui-utilities.min.css +4 -6
  22. package/dist/css/coreui-utilities.min.css.map +1 -1
  23. package/dist/css/coreui-utilities.rtl.css +1237 -101
  24. package/dist/css/coreui-utilities.rtl.css.map +1 -1
  25. package/dist/css/coreui-utilities.rtl.min.css +8 -12
  26. package/dist/css/coreui-utilities.rtl.min.css.map +1 -1
  27. package/dist/css/coreui.css +2372 -889
  28. package/dist/css/coreui.css.map +1 -1
  29. package/dist/css/coreui.min.css +4 -6
  30. package/dist/css/coreui.min.css.map +1 -1
  31. package/dist/css/coreui.rtl.css +2295 -902
  32. package/dist/css/coreui.rtl.css.map +1 -1
  33. package/dist/css/coreui.rtl.min.css +8 -12
  34. package/dist/css/coreui.rtl.min.css.map +1 -1
  35. package/dist/js/coreui.bundle.js +289 -264
  36. package/dist/js/coreui.bundle.js.map +1 -1
  37. package/dist/js/coreui.bundle.min.js +4 -4
  38. package/dist/js/coreui.bundle.min.js.map +1 -1
  39. package/dist/js/coreui.esm.js +255 -230
  40. package/dist/js/coreui.esm.js.map +1 -1
  41. package/dist/js/coreui.esm.min.js +4 -4
  42. package/dist/js/coreui.esm.min.js.map +1 -1
  43. package/dist/js/coreui.js +258 -232
  44. package/dist/js/coreui.js.map +1 -1
  45. package/dist/js/coreui.min.js +4 -4
  46. package/dist/js/coreui.min.js.map +1 -1
  47. package/js/dist/alert.js +10 -9
  48. package/js/dist/alert.js.map +1 -1
  49. package/js/dist/base-component.js +11 -10
  50. package/js/dist/base-component.js.map +1 -1
  51. package/js/dist/button.js +10 -9
  52. package/js/dist/button.js.map +1 -1
  53. package/js/dist/carousel.js +11 -10
  54. package/js/dist/carousel.js.map +1 -1
  55. package/js/dist/collapse.js +10 -9
  56. package/js/dist/collapse.js.map +1 -1
  57. package/js/dist/dom/data.js +5 -5
  58. package/js/dist/dom/data.js.map +1 -1
  59. package/js/dist/dom/event-handler.js +9 -9
  60. package/js/dist/dom/event-handler.js.map +1 -1
  61. package/js/dist/dom/manipulator.js +5 -5
  62. package/js/dist/dom/manipulator.js.map +1 -1
  63. package/js/dist/dom/selector-engine.js +6 -5
  64. package/js/dist/dom/selector-engine.js.map +1 -1
  65. package/js/dist/dropdown.js +13 -12
  66. package/js/dist/dropdown.js.map +1 -1
  67. package/js/dist/modal.js +12 -13
  68. package/js/dist/modal.js.map +1 -1
  69. package/js/dist/navigation.js +10 -9
  70. package/js/dist/navigation.js.map +1 -1
  71. package/js/dist/offcanvas.js +13 -12
  72. package/js/dist/offcanvas.js.map +1 -1
  73. package/js/dist/popover.js +10 -9
  74. package/js/dist/popover.js.map +1 -1
  75. package/js/dist/scrollspy.js +14 -13
  76. package/js/dist/scrollspy.js.map +1 -1
  77. package/js/dist/sidebar.js +10 -9
  78. package/js/dist/sidebar.js.map +1 -1
  79. package/js/dist/tab.js +13 -12
  80. package/js/dist/tab.js.map +1 -1
  81. package/js/dist/toast.js +10 -9
  82. package/js/dist/toast.js.map +1 -1
  83. package/js/dist/tooltip.js +14 -13
  84. package/js/dist/tooltip.js.map +1 -1
  85. package/js/dist/util/backdrop.js +10 -9
  86. package/js/dist/util/backdrop.js.map +1 -1
  87. package/js/dist/util/component-functions.js +10 -9
  88. package/js/dist/util/component-functions.js.map +1 -1
  89. package/js/dist/util/config.js +10 -9
  90. package/js/dist/util/config.js.map +1 -1
  91. package/js/dist/util/focustrap.js +6 -5
  92. package/js/dist/util/focustrap.js.map +1 -1
  93. package/js/dist/util/index.js +5 -5
  94. package/js/dist/util/index.js.map +1 -1
  95. package/js/dist/util/sanitizer.js +10 -6
  96. package/js/dist/util/sanitizer.js.map +1 -1
  97. package/js/dist/util/scrollbar.js +10 -9
  98. package/js/dist/util/scrollbar.js.map +1 -1
  99. package/js/dist/util/swipe.js +10 -9
  100. package/js/dist/util/swipe.js.map +1 -1
  101. package/js/dist/util/template-factory.js +10 -9
  102. package/js/dist/util/template-factory.js.map +1 -1
  103. package/js/index.esm.js +21 -0
  104. package/js/index.umd.js +38 -0
  105. package/js/src/alert.js +4 -4
  106. package/js/src/base-component.js +4 -4
  107. package/js/src/button.js +4 -4
  108. package/js/src/carousel.js +7 -7
  109. package/js/src/collapse.js +5 -5
  110. package/js/src/dom/data.js +2 -2
  111. package/js/src/dom/event-handler.js +4 -5
  112. package/js/src/dom/manipulator.js +2 -2
  113. package/js/src/dom/selector-engine.js +2 -2
  114. package/js/src/dropdown.js +9 -9
  115. package/js/src/modal.js +9 -10
  116. package/js/src/navigation.js +4 -4
  117. package/js/src/offcanvas.js +11 -11
  118. package/js/src/popover.js +3 -3
  119. package/js/src/scrollspy.js +6 -6
  120. package/js/src/sidebar.js +5 -5
  121. package/js/src/tab.js +7 -7
  122. package/js/src/toast.js +4 -4
  123. package/js/src/tooltip.js +9 -9
  124. package/js/src/util/backdrop.js +3 -3
  125. package/js/src/util/component-functions.js +3 -3
  126. package/js/src/util/config.js +3 -3
  127. package/js/src/util/focustrap.js +2 -2
  128. package/js/src/util/index.js +2 -2
  129. package/js/src/util/sanitizer.js +6 -4
  130. package/js/src/util/scrollbar.js +3 -3
  131. package/js/src/util/swipe.js +3 -3
  132. package/js/src/util/template-factory.js +4 -4
  133. package/package.json +54 -44
  134. package/scss/_accordion.scss +9 -1
  135. package/scss/_alert.scss +6 -10
  136. package/scss/_badge.scss +2 -1
  137. package/scss/_button-group.scss +4 -4
  138. package/scss/_buttons.scss +23 -1
  139. package/scss/_card.scss +8 -3
  140. package/scss/_carousel.scss +24 -8
  141. package/scss/_close.scss +32 -9
  142. package/scss/_dropdown.scss +3 -3
  143. package/scss/_functions.scss +6 -22
  144. package/scss/_grid.scss +8 -0
  145. package/scss/_helpers.scss +2 -0
  146. package/scss/_list-group.scss +11 -2
  147. package/scss/_maps.scss +125 -0
  148. package/scss/_mixins.scss +1 -4
  149. package/scss/_nav.scss +7 -0
  150. package/scss/_navbar.scss +17 -4
  151. package/scss/_offcanvas.scss +4 -2
  152. package/scss/_pagination.scss +1 -1
  153. package/scss/_progress.scss +10 -1
  154. package/scss/_reboot.scss +2 -3
  155. package/scss/_root.scss +144 -16
  156. package/scss/_tables.scss +18 -15
  157. package/scss/_tooltip.scss +5 -6
  158. package/scss/_type.scss +3 -1
  159. package/scss/_utilities.scss +182 -23
  160. package/scss/_variables-dark.scss +169 -0
  161. package/scss/_variables.scss +357 -340
  162. package/scss/coreui-grid.rtl.scss +2 -7
  163. package/scss/coreui-grid.scss +3 -10
  164. package/scss/coreui-reboot.rtl.scss +2 -7
  165. package/scss/coreui-reboot.scss +4 -7
  166. package/scss/coreui-utilities.rtl.scss +2 -7
  167. package/scss/coreui-utilities.scss +3 -7
  168. package/scss/coreui.rtl.scss +2 -7
  169. package/scss/coreui.scss +3 -7
  170. package/scss/forms/_floating-labels.scss +23 -4
  171. package/scss/forms/_form-check.scss +22 -24
  172. package/scss/forms/_form-control.scss +33 -13
  173. package/scss/forms/_form-range.scss +8 -8
  174. package/scss/forms/_form-select.scss +19 -10
  175. package/scss/forms/_form-text.scss +1 -1
  176. package/scss/forms/_input-group.scss +1 -1
  177. package/scss/forms/_labels.scss +2 -2
  178. package/scss/helpers/_color-bg.scss +12 -2
  179. package/scss/helpers/_colored-links.scss +20 -2
  180. package/scss/helpers/_focus-ring.scss +5 -0
  181. package/scss/helpers/_icon-link.scss +25 -0
  182. package/scss/mixins/_alert.scss +4 -1
  183. package/scss/mixins/_banner.scss +7 -0
  184. package/scss/mixins/_breakpoints.scss +0 -13
  185. package/scss/mixins/_caret.scss +31 -26
  186. package/scss/mixins/_color-mode.scss +21 -0
  187. package/scss/mixins/_forms.scss +8 -7
  188. package/scss/mixins/_grid.scss +1 -1
  189. package/scss/mixins/_list-group.scss +3 -0
  190. package/scss/mixins/_utilities.scss +35 -15
  191. package/scss/mixins/_visually-hidden.scss +5 -1
  192. package/scss/sidebar/_sidebar.scss +10 -2
  193. package/scss/vendor/_rfs.scss +24 -30
  194. package/scss/mixins/_css-vars.scss +0 -87
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): dropdown.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI dropdown.js
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
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
@@ -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
- // todo: v6 revert #37011 & change markup https://getbootstrap.com/docs/5.2/forms/input-group/
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') // todo:v6 remove
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
- // todo: v6 revert #37011 & change markup https://getbootstrap.com/docs/5.2/forms/input-group/
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,21 +1,21 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): modal.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI modal.js
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
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
8
8
  * --------------------------------------------------------------------------
9
9
  */
10
10
 
11
- import { defineJQueryPlugin, isRTL, isVisible, reflow } from './util/index.js'
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
- for (const htmlElement of [window, this._dialog]) {
146
- EventHandler.off(htmlElement, EVENT_KEY)
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
  }
@@ -1,16 +1,16 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): navigation.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI navigation.js
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'
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 BaseComponent from './base-component.js'
13
+ import { defineJQueryPlugin } from './util/index.js'
14
14
 
15
15
  /**
16
16
  * ------------------------------------------------------------------------
@@ -1,25 +1,25 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): dropdown.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI offcanvas.js
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
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 (!this._config.keyboard) {
205
- EventHandler.trigger(this._element, EVENT_HIDE_PREVENTED)
204
+ if (this._config.keyboard) {
205
+ this.hide()
206
206
  return
207
207
  }
208
208
 
209
- this.hide()
209
+ EventHandler.trigger(this._element, EVENT_HIDE_PREVENTED)
210
210
  })
211
211
  }
212
212
 
package/js/src/popover.js CHANGED
@@ -1,15 +1,15 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): popover.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI popover.js
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
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
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
@@ -1,17 +1,17 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): scrollspy.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI scrollspy.js
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
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
8
8
  * --------------------------------------------------------------------------
9
9
  */
10
10
 
11
- import { defineJQueryPlugin, getElement, isDisabled, isVisible } from './util/index'
12
- import EventHandler from './dom/event-handler'
13
- import SelectorEngine from './dom/selector-engine'
14
- import BaseComponent from './base-component'
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 { defineJQueryPlugin, getElement, isDisabled, isVisible } from './util/index.js'
15
15
 
16
16
  /**
17
17
  * Constants
package/js/src/sidebar.js CHANGED
@@ -1,16 +1,16 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): sidebar.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI sidebar.js
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,17 +1,17 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI tab.js
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
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
8
8
  * --------------------------------------------------------------------------
9
9
  */
10
10
 
11
- import { defineJQueryPlugin, getNextActiveElement, isDisabled } from './util/index.js'
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 BaseComponent from './base-component.js'
14
+ import { defineJQueryPlugin, getNextActiveElement, isDisabled } from './util/index.js'
15
15
 
16
16
  /**
17
17
  * Constants
@@ -46,7 +46,7 @@ const NOT_SELECTOR_DROPDOWN_TOGGLE = ':not(.dropdown-toggle)'
46
46
  const SELECTOR_TAB_PANEL = '.list-group, .nav, [role="tablist"]'
47
47
  const SELECTOR_OUTER = '.nav-item, .list-group-item'
48
48
  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"]' // todo:v6: could be only `tab`
49
+ const SELECTOR_DATA_TOGGLE = '[data-coreui-toggle="tab"], [data-coreui-toggle="pill"], [data-coreui-toggle="list"]' // TODO: could only be `tab` in v6
50
50
  const SELECTOR_INNER_ELEM = `${SELECTOR_INNER}, ${SELECTOR_DATA_TOGGLE}`
51
51
 
52
52
  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 +62,7 @@ class Tab extends BaseComponent {
62
62
 
63
63
  if (!this._parent) {
64
64
  return
65
- // todo: should Throw exception on v6
65
+ // TODO: should throw exception in v6
66
66
  // throw new TypeError(`${element.outerHTML} has not a valid parent ${SELECTOR_INNER_ELEM}`)
67
67
  }
68
68
 
@@ -215,7 +215,7 @@ class Tab extends BaseComponent {
215
215
  this._setAttributeIfNotExists(target, 'role', 'tabpanel')
216
216
 
217
217
  if (child.id) {
218
- this._setAttributeIfNotExists(target, 'aria-labelledby', `#${child.id}`)
218
+ this._setAttributeIfNotExists(target, 'aria-labelledby', `${child.id}`)
219
219
  }
220
220
  }
221
221
 
package/js/src/toast.js CHANGED
@@ -1,17 +1,17 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): toast.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI toast.js
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
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
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,7 +1,7 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tooltip.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI tooltip.js
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
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
@@ -9,11 +9,11 @@
9
9
  */
10
10
 
11
11
  import * as Popper from '@popperjs/core'
12
- import { defineJQueryPlugin, execute, findShadowRoot, getElement, getUID, isRTL, noop } from './util/index.js'
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 BaseComponent from './base-component.js'
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, 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
- // todo v6 remove this OR make it optional
203
+ // TODO: v6 remove this or make it optional
204
204
  this._disposePopper()
205
205
 
206
206
  const tip = this._getTipElement()
@@ -305,13 +305,13 @@ class Tooltip extends BaseComponent {
305
305
  _createTipElement(content) {
306
306
  const tip = this._getTemplateFactory(content).toHtml()
307
307
 
308
- // todo: remove this check on v6
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
- // todo: on v6 the following can be achieved with CSS only
314
+ // TODO: v6 the following can be achieved with CSS only
315
315
  tip.classList.add(`bs-${this.constructor.NAME}-auto`)
316
316
 
317
317
  const tipId = getUID(this.constructor.NAME).toString()
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/backdrop.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
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)
@@ -9,8 +9,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,7 +1,7 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/component-functions.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
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)
@@ -9,8 +9,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}`
@@ -1,15 +1,15 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/config.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
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
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/focustrap.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
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)
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/index.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
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)
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/sanitizer.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
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)
@@ -19,8 +19,6 @@ const uriAttributes = new Set([
19
19
  'xlink:href'
20
20
  ])
21
21
 
22
- const ARIA_ATTRIBUTE_PATTERN = /^aria-[\w-]*$/i
23
-
24
22
  /**
25
23
  * A pattern that recognizes a commonly useful subset of URLs that are safe.
26
24
  *
@@ -51,6 +49,9 @@ const allowedAttribute = (attribute, allowedAttributeList) => {
51
49
  .some(regex => regex.test(attributeName))
52
50
  }
53
51
 
52
+ // js-docs-start allow-list
53
+ const ARIA_ATTRIBUTE_PATTERN = /^aria-[\w-]*$/i
54
+
54
55
  export const DefaultAllowlist = {
55
56
  // Global attributes allowed on any supplied element below.
56
57
  '*': ['class', 'dir', 'id', 'lang', 'role', ARIA_ATTRIBUTE_PATTERN],
@@ -84,6 +85,7 @@ export const DefaultAllowlist = {
84
85
  u: [],
85
86
  ul: []
86
87
  }
88
+ // js-docs-end allow-list
87
89
 
88
90
  export function sanitizeHtml(unsafeHtml, allowList, sanitizeFunction) {
89
91
  if (!unsafeHtml.length) {
@@ -1,15 +1,15 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/scrollBar.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
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
  /**
@@ -1,15 +1,15 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/swipe.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
6
  * This is a modified version of the Bootstrap's util/swipe.js
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
8
8
  * --------------------------------------------------------------------------
9
9
  */
10
10
 
11
- import Config from './config.js'
12
11
  import EventHandler from '../dom/event-handler.js'
12
+ import Config from './config.js'
13
13
  import { execute } from './index.js'
14
14
 
15
15
  /**
@@ -1,17 +1,17 @@
1
1
  /**
2
2
  * --------------------------------------------------------------------------
3
- * CoreUI (v4.2.5): tab.js
4
- * Licensed under MIT (https://coreui.io/license)
3
+ * CoreUI util/template-factory.js
4
+ * Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
5
5
  *
6
6
  * This is a modified version of the Bootstrap's util/template-factory.js
7
7
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
8
8
  * --------------------------------------------------------------------------
9
9
  */
10
10
 
11
- import { DefaultAllowlist, sanitizeHtml } from './sanitizer.js'
12
- import { execute, getElement, isElement } from './index.js'
13
11
  import SelectorEngine from '../dom/selector-engine.js'
14
12
  import Config from './config.js'
13
+ import { DefaultAllowlist, sanitizeHtml } from './sanitizer.js'
14
+ import { execute, getElement, isElement } from './index.js'
15
15
 
16
16
  /**
17
17
  * Constants