2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-05-18 12:39:41 +03:00
Commit Graph

105 Commits

Author SHA1 Message Date
XhmikosR edf9c40956 Release v5.2.0 (#36768)
* Bump version to 5.2.0

* Dist

* Update masthead.html
2022-07-19 18:43:58 +03:00
Marc Wrobel 705d6857ad Fix typos in code (#36763)
Shoutout is correct but has been replaced by its more common form : Shout-out (https://www.merriam-webster.com/dictionary/shout-out).
2022-07-18 13:30:29 -07:00
louismaxime.piton c137d11aa2 Re-ordering js default objects 2022-06-01 19:24:45 -07:00
Mark Otto f7e8ca91e0 Prepare v5.2.0-beta1 2022-05-13 19:44:01 +03:00
GeoSot 584600bda3 Manipulator: Add JSON parse support (#35077)
Support parsing JSON from each component's main element using the `data-bs-config` attribute.

The `bs-config` attribute will be reserved and omitted during `getDataAttributes` parsing.

With this commit, every component, will create its config object, using:

* defaults
* data-bs-config
* the rest of data attributes
* configuration object given during instance initialization

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Mark Otto <markd.otto@gmail.com>
Co-authored-by: Mark Otto <markdotto@gmail.com>
2022-04-21 21:41:43 +03:00
XhmikosR 62d86c07f8 Rename variables 2022-01-29 13:25:30 +02:00
XhmikosR 3ac4451d47 backdrop.js: cache _getElement calls 2022-01-29 13:25:30 +02:00
XhmikosR 0c3dfe104b Remove a few unneeded variables 2022-01-29 13:25:30 +02:00
Ryan Berliner 14c7dc1e88 Fix: isVisible function behavior in case of a <details> element, on chrome 97 (#35682) 2022-01-13 10:55:05 +02:00
GeoSot 886b940796 Extract Component config functionality to a separate class (#33872)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2021-12-10 18:18:18 +02:00
XhmikosR 871c8bdd3f util/index.js: minor refactoring (#35510)
* rename variables
* remove an unused variable
* be more explicit
* reuse variable
2021-12-10 07:48:04 +02:00
GeoSot 28a5a72ed5 Scrollbar - remove margin/padding properties properly (#35388)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2021-12-09 15:49:28 +02:00
GeoSot 4fd5539c75 ScrollBar.js. Minor refactoring and add test (#35492) 2021-12-09 15:05:50 +02:00
GeoSot 94a596fbcb Add a template factory helper to handle all template cases (#34519)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2021-11-25 19:14:02 +02:00
XhmikosR e8f702666f JS: minor refactoring (#35183)
* add missing comments
* shorten block comments
* reorder constants
* reorder public/private methods
* sort exports alphabetically in util/index.js
* fix a couple of typos
2021-10-13 15:19:28 +03:00
GeoSot db44392bda Swipe: add test to ensure that it ignores pinch events (#35161) 2021-10-12 15:48:19 +03:00
GeoSot 8ec6c94522 Extract Carousel's swipe functionality to a separate Class (#32999) 2021-10-11 17:04:43 +03:00
XhmikosR c44d64ed71 Merge remote-tracking branch 'remotes/origin/v513' 2021-10-09 18:28:28 +03:00
XhmikosR 1a6fdfae6b Bump version to 5.1.3. 2021-10-09 09:43:19 +03:00
XhmikosR 64e13162fa Sanitizer: fix logic and add a test. (#35133)
This was broken in 2596c97 inadvertently.
Added a test so that we don't hit this in the future.
2021-10-07 17:48:36 +03:00
XhmikosR 2596c97034 util/sanitizer.js: use Array.every() (#35120) 2021-10-06 00:23:14 +03:00
XhmikosR 3afe4b8c7d Enable unicorn/numeric-separators-style rule.
This is taken care of by babel via @babel/plugin-proposal-numeric-separator
2021-10-05 19:52:11 +03:00
XhmikosR 666fe596bf Enable unicorn/no-array-for-each rule 2021-10-05 19:52:11 +03:00
XhmikosR 2b4d0d166b Enable unicorn/no-for-loop rule 2021-10-05 19:52:11 +03:00
XhmikosR 9f1579aa04 Enable unicorn/prefer-prototype-methods rule 2021-10-05 19:52:11 +03:00
XhmikosR 5ecef8ac01 Release v5.1.2 (#35114) 2021-10-05 18:50:18 +03:00
XhmikosR 759fc89f4b sanitizer: add sms in the SAFE_URL_PATTERN (#35074) 2021-09-29 07:41:06 +03:00
XhmikosR 8f2e678424 Minor refactoring (#34980)
Rename variables and remove a temporary one
2021-09-15 14:34:24 +03:00
Julien Déramond 499485589f Remove remaining "master" branch references (#34932) 2021-09-08 17:58:50 +03:00
XhmikosR 0d81d3cbc1 Release v5.1.1 (#34869)
* Prepare v5.1.1.

* Dist
2021-09-07 18:37:44 +03:00
XhmikosR f20fece3a8 Prepare v5.1.0. (#34674) 2021-08-04 18:41:51 +03:00
XhmikosR 6d707f4801 Enable a few eslint-config-xo rules (#34620)
* unicorn/prefer-dom-node-append
* unicorn/prefer-dom-node-remove
2021-07-30 00:23:00 +02:00
GeoSot 4bfd8a2cbc Use a streamlined way to trigger component dismiss (#34170)
* use a streamlined way to trigger component dismiss

* add documentation

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2021-07-28 17:39:32 +03:00
Ryan Berliner 7646f6bd33 Add shift-tab keyboard support for dialogs (modal & Offcanvas components) (#33865)
* consolidate dialog focus trap logic

* add shift-tab support to focustrap

* remove redundant null check of trap element

Co-authored-by: GeoSot <geo.sotis@gmail.com>

* remove area support forom focusableChildren

* fix no expectations warning in focustrap tests

Co-authored-by: GeoSot <geo.sotis@gmail.com>
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2021-07-27 08:01:04 +03:00
Ryan Berliner 119cfc3dfe Remove whitespace at beginning of util/index.js (#34545) 2021-07-21 07:49:55 +03:00
GeoSot 5541179b38 Fix Util.reflow function and add documentation (#34543)
* add documentation to reflow function

* refactor to void as it should be

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2021-07-20 17:20:43 +03:00
GeoSot e45b25e08e util.js: remove Selector.findOne() dependency (#34441)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2021-07-14 09:08:10 +03:00
Mark Otto 45d26de728 Variablize backdrop for modal and offcanvas 2021-06-25 13:41:15 -07:00
XhmikosR 688bce4fa6 Release v5.0.2 (#34276)
* Bump version to v5.0.2.

* Dist
2021-06-22 21:29:16 +03:00
alpadev 4927388197 Register only one DOMContentLoaded event listener in onDOMContentLoaded (#34158)
* refactor: reuse one DOMContentLoaded event listener in onDOMContentLoaded function

Instead of adding an event listener everytime the utility function is called, cache the callbacks and execute them all at once.

* refactor: drop iife for onDOMContentLoaded

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2021-06-22 20:19:55 +03:00
GeoSot cb47b8c964 Refactor scrollbar.js to be used as a Class (#33947) 2021-06-06 09:26:36 +03:00
alpadev 4a5029ea29 Fix handling of transitionend events dispatched by nested elements(#33845)
Fix handling of transitionend events dispatched by nested elements
Properly handle events from nested elements

Change `emulateTransitionEnd` to `executeAfterTransition` &&
2021-06-03 14:44:16 +03:00
Ryan Weaver 0cb70e214f Changing Backdrop rootElement to default to a string (#34092)
The current config can cause the "body" to become stale. Specifically,
if the entire body element is swapped out for a new body element, then
the backdrop will continue to append itself to the original body element,
since it's stored in memory as a reference on this object.

This also no longer allows an explicit null to be passed to Backdrop's rootElement

This still accomplishes the laziness of "not finding the rootElement
until the Backdrop is created" to avoid problems of the JavaScript
being included inside <head> (so, before body is available).
2021-05-31 12:35:59 +03:00
GeoSot 544d9ac3cf Change element.parentNode.removeChild(element) to element.remove() (#34071) 2021-05-25 18:30:38 +03:00
alpadev b39b665072 Automatically select an item in the dropdown when using arrow keys (#34052) 2021-05-22 10:58:52 +03:00
Ryan Weaver a2b5901efc Fix bug where backdrop calls method on null if it is already removed from the body (#34014)
Co-authored-by: Rohit Sharma <rohit2sharma95@gmail.com>
2021-05-22 01:16:05 +03:00
Ryan Berliner 4ac711b5b4 Refactor isVisible helper, fixing false positives from deep nesting or alternate means (#33960) 2021-05-20 16:50:53 +03:00
GeoSot 79c3bf47bc Add Tests on scrollbar.js & better handling if a style property doesn't exists (#33948)
* scrollbar.js:
add some tests
transfer test from modal.spec. to scrollbar.spec
proper handling if style property doesn't exist
2021-05-20 16:29:04 +03:00
GeoSot df72a21fa8 Add getNextActiveElement helper function to utils, replacing custom implementation through components (#33608) 2021-05-19 01:23:52 +03:00
XhmikosR 58b1be927f Release v5.0.1 (#33972)
* Bump version to 5.0.1.

* Dist
2021-05-13 19:22:20 +03:00