Compare commits

..

459 commits

Author SHA1 Message Date
Mark Otto
614593c379 WIP: Add dependencies to our Sass files 2020-09-29 21:42:22 -07:00
Mark Otto
f927a95b6c
Backport #31300 (#31769)
* Manually backport JS bundle guidance

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-09-28 10:57:42 +03:00
Johann-S
e45fbe7f72 add suggested fix for gpu acceleration 2020-09-24 15:06:30 +03:00
XhmikosR
16aa05752b Update popovers.md 2020-09-24 15:06:30 +03:00
Mark Otto
34208778ba v4: Mention GPU acceleration fix in docs callout
Closes #22610
2020-09-24 15:06:30 +03:00
XhmikosR
400364c7fd Update devDependencies 2020-09-21 14:58:34 +03:00
XhmikosR
30c3cd45a2 icons.md: add icofont like in v5 2020-09-21 14:58:34 +03:00
XhmikosR
6994dacee4 Backport #31689
docs: fix a few redirects

* Fix GitHub's permanent redirects

* Fix a11yproject redirects
2020-09-21 14:58:34 +03:00
XhmikosR
dfefd48c34 Backport #31516
Add new icons set - CoreUI Icons
2020-09-21 14:58:34 +03:00
XhmikosR
31eb108811 Add parentheses around multiple spread conditions 2020-09-21 14:58:34 +03:00
XhmikosR
b31046aab3 Cache a few variables. 2020-09-21 14:58:34 +03:00
XhmikosR
c86b74fe88 Unbreak lines and remove a TODO comment 2020-09-21 14:58:34 +03:00
XhmikosR
be18957933 Backport 65d130fbd8
Mention the quotes requirement in the docs too
2020-09-21 14:58:34 +03:00
Mark Otto
8acd7c9fbe Add a comment for escape-svg function
Closes #30835 by leaving a comment in the source that the escape-svg() function must have quotes around data URIs.

(cherry picked from commit 849fea5a1e)
2020-09-21 14:58:34 +03:00
Joakim Riedel
b0a0c56788
ensure hidePrevented.bs.modal can be prevented (#31696) 2020-09-21 14:41:40 +03:00
Mr. Will
ab0aec397e
Add new Chinese Simplified translation (#31540) 2020-09-20 14:24:13 +03:00
Patrick H. Lauke
63b8a6ffdd
Docs: Add top/bottom margin to highlighted code samples (#31706)
Backport of #31036 to v4
2020-09-19 18:59:56 +03:00
Mark Otto
7539cfb29c
Update _custom-forms.scss (#31693)
Typo in box-shadow attribute, global variable used instead of local.

Co-authored-by: Arthur Shlain <artur.slain@gmail.com>
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-09-18 11:21:30 +03:00
XhmikosR
dc2f1e68cd
Dropdown: fix variable always evaluating to true (#31673) 2020-09-18 10:22:24 +03:00
XhmikosR
1bd1d78a78
Update devDependencies and gems (#31624)
* Update devDependencies and gems

* Bump bundlewatch limits
2020-09-15 08:31:57 +03:00
XhmikosR
3be585990c Comply to the new rules 2020-09-10 12:06:30 +03:00
XhmikosR
1c37a2ba77 Switch to xo and remove babel-eslint 2020-09-10 12:06:30 +03:00
Gaël Poupard
39282bcc9d
docs(build tools): mention how to get the sources (#31589) 2020-09-04 20:17:37 +03:00
XhmikosR
5f2480a90a
Prepare v4.5.2. (#31444) 2020-08-06 19:22:43 +03:00
Martijn Cuppens
c0aa405632 Remove undefined $ignore-warning 2020-08-06 19:08:24 +03:00
XhmikosR
e6ab4ad86a Deprecate the make-container-max-widths mixin 2020-08-06 19:08:24 +03:00
Mark Otto
af4419b723 Restore make-container-max-widths mixin 2020-08-06 19:08:24 +03:00
XhmikosR
f083759d03
Remove flex: 1 0 100% from rows (#31439) (#31445)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>

Co-authored-by: Mark Otto <markd.otto@gmail.com>
2020-08-06 18:59:17 +03:00
XhmikosR
89dc9750ec
Prepare v4.5.1. (#31408) 2020-08-04 19:24:33 +03:00
XhmikosR
e0f89dc90b
Backport #31339 (#31414)
* Backport #31339

Add view on GitHub links for easier content editing from the docs
2020-08-04 18:54:01 +03:00
XhmikosR
30d375b33f
Remove overflow: hidden from toasts (#31381) (#31407)
Co-authored-by: Mark Otto <markd.otto@gmail.com>
2020-08-03 19:13:32 +03:00
XhmikosR
6879a3c51d Update devDependencies and gems
* @babel/cli                   ^7.10.4  →  ^7.11.0
* @babel/core                  ^7.10.4  →  ^7.11.0
* @rollup/plugin-babel          ^5.0.4  →   ^5.1.0
* @rollup/plugin-commonjs      ^13.0.0  →  ^14.0.0
* @rollup/plugin-node-resolve   ^8.1.0  →   ^8.4.0
* autoprefixer                  ^9.8.4  →   ^9.8.6
* eslint                        ^7.4.0  →   ^7.6.0
* karma                         ^5.1.0  →   ^5.1.1
* rollup                       ^2.21.0  →  ^2.23.0
2020-08-03 19:06:36 +03:00
XhmikosR
d44a1e105e Backport #31344
Add toasts to the components requiring JavaScript
2020-08-03 19:06:36 +03:00
Gaël Poupard
81d3e2b917 docs(skippy): prevent skip links from overlapping header 2020-08-03 19:06:36 +03:00
Rohit Sharma
1abe9264aa Add unit test for toast to check clearTimeout to have been called (#31298) 2020-08-03 19:06:36 +03:00
Rohit Sharma
f530ab7549 Clear timeout before showing the toast (#31155)
* clear timeout before showing the toast

* Add unit test

* Remove the check for timeout

* Check for clearTimeout to have been called

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
# Conflicts:
#	js/tests/unit/toast.spec.js
2020-08-03 19:06:36 +03:00
XhmikosR
0ec2ce44b4
Update to Ruby 2.7/Bundler 2.x. (#31296) 2020-08-02 16:26:19 +03:00
Patrick H. Lauke
cc49a5b506
Turn off scroll anchoring for accordions (#31347)
New default behavior for scroll anchoring (rolled out in Chrome 84?) leads to unsightly/odd accordion interactions - see #31341
This rule suppresses this new behavior and reverts back to the old way.

See https://drafts.csswg.org/css-scroll-anchoring/
2020-07-21 21:44:41 +01:00
Patrick H. Lauke
99013a5c54
Docs: forms accessibility cleanup (backport from v5) (#31234)
* Expand advice for anchor-based controls

* Expand accessibility note in input group

* Correct statement about validation, fix server example

* Tweak label > accessible name

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Mark Otto <markd.otto@gmail.com>
2020-07-12 07:57:48 +03:00
XhmikosR
38bcf108c9
Update dependencies, gems and regenerate package-lock.json (#31261)
* @rollup/plugin-node-resolve 8.1.0
* popper.js 1.16.1
* qunit 2.10.1
* rollup 2.21.0
2020-07-09 15:21:41 +03:00
XhmikosR
f40e1b651b Update devDependencies and gems 2020-07-06 16:40:27 +03:00
XhmikosR
ad8d3a6c54 Update Babel config (#31011)
* remove plugin-proposal-object-rest-spread
* add bugfixes
* `exclude: ['transform-typeof-symbol']` did nothing with our config
2020-07-06 16:40:27 +03:00
ysds
9a6cfeb36e Backport #30326 (Unit test) 2020-07-06 16:40:27 +03:00
XhmikosR
ea01c29294 Backport #30326
Prevent overflowing static backdrop modal animation

TODO: backport the test too
2020-07-06 16:40:27 +03:00
XhmikosR
234dd96abf Backport #31135
* Move color utility callouts to start of page

Hierarchically/structurally, in the position they are currently at, the two callouts seem like they "belong" just to the "background color" section. Moving them to the start makes it clearer that those two callouts relate to everything in the page (both "Color" and "Background color" classes.

* Change heading level

otherwise the assistive technology callout looks like it's hierarchically under the "Dealing with specificity" heading
2020-07-06 16:40:27 +03:00
XhmikosR
c49b084158 BrowserStack: test on Edge 15 2020-07-06 16:40:27 +03:00
Mark Otto
b2ef98f154 Remove backdrop-filter from toasts 2020-07-06 16:40:27 +03:00
Gaël Poupard
04dbb6c24c Floating labels improvements (#30966)
* docs(example): floating-labels' better Edge fallback

* docs(example): refactor floating-labels' CSS
2020-06-24 15:16:58 +03:00
XhmikosR
5a9fc2938c Update devDependencies and gems 2020-06-24 15:16:58 +03:00
Patrick H. Lauke
c995886c0f Docs: add Gaël Poupard to the core team page (#31081)
Docs: add Gaël Poupard to the core team page
2020-06-24 15:16:58 +03:00
XhmikosR
9b241e630c Backport #31070
* Make example less broken-looking

don't want to give impression that now it's ok to just sprinkle `role="button"` around. this at least makes the `span` keyboard-focusable, similar to at least the start of a custom control
2020-06-24 15:16:58 +03:00
XhmikosR
920dc619a4 README.md: update badges
* remove .svg from shields.io badges since it's the default
* switch to shields.io for the OC badges too
* fix badgesize badges' labels
2020-06-24 15:16:58 +03:00
XhmikosR
f6b74b8b41 Fix typo 2020-06-24 15:16:58 +03:00
XhmikosR
2e991732de Update issue templates from main. 2020-06-24 15:16:58 +03:00
XhmikosR
2314247825 Remove unused issue templates 2020-06-24 15:16:58 +03:00
XhmikosR
3349eb6a41 Update links to point to v4-dev or main branches 2020-06-24 15:16:58 +03:00
XhmikosR
6c04d186e2 Split GitHub Actions. 2020-06-24 15:16:58 +03:00
XhmikosR
7de8582657 Stylelint: remove redundant inline suppressions 2020-06-24 15:16:58 +03:00
XhmikosR
242f75cd1f Update .gitattributes (#30934)
This requires git >= 2.10 but it was released almost 4 years ago.
2020-06-24 15:16:58 +03:00
XhmikosR
78a51cb12f Backport #30973
Remove the class `.nav-item` from `.nav-link` inside the non `ul` or `ol` based navs.
This makes the consistency for `.nav-item` (This class will not be required on the `.nav-link`).
`.nav-item` was only required when you use `.nav-fill` or `.nav-justified` on the `.nav`. In other cases, it was redundant. And the purpose of `.nav-item` on `.nav-link`s can be achieved via flexbox utilities as well (Mentioned in the docs also).
2020-06-24 15:16:58 +03:00
Gaël Poupard
89be07b51f Prevent .row from shrinking in flex container (#30940) 2020-06-24 15:16:58 +03:00
Martijn Cuppens
4f44a2afd0
Remove duplicate properties after #30922 (#31148) 2020-06-23 09:28:13 +03:00
Gaël Poupard
7b5e48d307
fix(custom forms): disabled checked states weren't overriding background-image (#30922) 2020-06-15 08:41:12 +03:00
k-utsumi
c3572ceca9
Avoid duplication of container breakpoints (#30969) 2020-06-14 00:25:39 +03:00
Gaël Poupard
7c6a0db820
Floating labels examples in IE (#30965)
* docs(example): drop IE workaround since it works fine in IE

* Serial comma

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Mark Otto <markd.otto@gmail.com>
2020-06-13 09:38:13 +03:00
Gaël Poupard
5b8163301c
Backport #30979 (#30999)
fix(grid)[manual backport]: zero min-width on .col has too much side-effects
2020-06-10 16:12:12 +03:00
Laussel Loïc
e9f039d1fe
avoid preventing input event onclick (#30992)
* instead of stopping event if onclick is triggered on input, call toggle method only if its not on checkbox inside a label

* add unit test

* add a dedicated test to ensure click event is forward to label

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-06-10 15:45:31 +03:00
Gaël Poupard
ba6d5e802b docs(toasts): centered examples flexbugs #3 in IE11 2020-06-10 08:14:30 +03:00
Gaël Poupard
8429acf460 fix(toasts): IE11 shrinks toasts when in flex container, unless we specify flex-basis 2020-06-10 08:14:30 +03:00
XhmikosR
3caea1ca02 visual/modal.html: fix close buttons placement 2020-06-04 17:53:16 +03:00
XhmikosR
7ac763bcdc Bump bundlewatch limits 2020-06-04 17:53:16 +03:00
XhmikosR
8bc6dcd280 Backport #30936
Add role="dialog" in modals via JavaScript
2020-06-04 17:53:16 +03:00
XhmikosR
288b9b82b5 Backport #30932
Restore word-break: break-word on .text-break to fix text breaking on flex containers
2020-06-04 17:53:16 +03:00
XhmikosR
ac3c2e2356 Update devDependencies and gems 2020-06-04 17:53:16 +03:00
XhmikosR
24d5a1e996 CI: update to actions/cache@2 2020-06-04 17:53:16 +03:00
XhmikosR
35310454b1 Remove ESLint object-curly-newline rule. 2020-06-04 17:53:16 +03:00
XhmikosR
7a9bbd4489 Backport #30742
Update to `@rollup/plugin-babel`
2020-06-04 17:53:16 +03:00
Martijn Cuppens
fdb596b2c3 Prevent conflicts with components with classes (#30830) 2020-06-04 17:53:16 +03:00
Mark Otto
ce23903a76 v5: Add border-radius to .card-img-overlay (#30817)
Allows use of background-color and more. Fixes #29033 for v5.
2020-06-04 17:53:16 +03:00
Mark Otto
ac48bbe081 Simplify list-group borders in cards (#30808) 2020-06-04 17:53:16 +03:00
Mark Otto
f4a7888af5
v4: Add z-index to .custom-check to fix custom checks in CSS columns (#30810)
For some reason, custom checks in CSS columns need a new stacking order to maintain visibility. This PR adds `z-index: 1` to trigger that new stacking order. Since v5's forms are being redone entirely, and we're dropping IE10/11 there, I think this is totally fine to ship with v4 only. Will need to check v5's forms it in Edge though.

Fixes #29607.

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-06-04 16:11:33 +03:00
Gaël Poupard
4e685e70b7
fix(custom forms): nullify box-shadow for custom forms' states (#30957)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-06-04 09:34:30 +03:00
Gaël Poupard
b287736327
fix(forms): IE11 misalign validation tooltips in input-groups (#30960) 2020-06-04 09:27:08 +03:00
Gaël Poupard
6f4d9fff02
docs(cards): fix card-img-bottom example (#30925) 2020-05-29 18:01:40 +03:00
Gaël Poupard
daa01aacb5
docs(CDN): improve wording to match master and fix #30873 (#30896) 2020-05-26 18:48:53 +03:00
Mark Otto
58dd4cc66c
v4: Update docs callout for responsive SVG images (#30809)
Turns out this applies to IE11 as well as IE10, so this clarifies the docs callout.

Closes #25242.

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-05-14 09:18:01 +03:00
Mark Otto
a8eb919f44
v4: Mention Bootstrap Icons in extend/icons.md (#30813)
- Closes #30796
2020-05-14 09:06:08 +03:00
XhmikosR
700c6036aa
Fix release script docs (#30797) 2020-05-13 09:13:27 +03:00
XhmikosR
7a6da5e3e7 Dist 2020-05-12 20:44:42 +03:00
XhmikosR
109ad5db90 Bump version to 4.5.0. 2020-05-12 20:44:42 +03:00
Mark Otto
4a0ddb02db Wording fixes 2020-05-12 19:21:36 +03:00
XhmikosR
0f26be5ff3 Move the input groups validation workaround in docs. 2020-05-12 19:21:36 +03:00
XhmikosR
842b0d2ae4 Remove mention of build tools
They are not included in npm.
2020-05-12 19:21:36 +03:00
XhmikosR
32932d27d5 Grammar fixes 2020-05-12 19:21:36 +03:00
XhmikosR
4a26e51540 Include the newly added utilities/interactions.scss file
We missed it in #30562
2020-05-12 19:21:36 +03:00
XhmikosR
0f3eda8254 Update devDependencies and gems. 2020-05-12 19:21:36 +03:00
XhmikosR
30e7df6cca Backport d59de33 from #30772
Add a test about the scrollbar issue on non-integer width
2020-05-12 19:21:36 +03:00
Giovanni Mendoza
f1827ce9cd Avoid bad scrollbar replacement into width values
Refs #30772
2020-05-12 19:21:36 +03:00
XhmikosR
eb1df3e079 Update codeql.yml (#30777)
Remove moot fail-fast option
2020-05-12 19:21:36 +03:00
XhmikosR
df91d2cab0 Improve build/zip-examples.js (#30759)
* remove favicons meta tags
* copy the two brand images we use in the examples
* copy dist and brand images into an assets folder
2020-05-12 19:21:36 +03:00
Rohit Sharma
d2f9fbd055 Removed role="document" from the modal dialog (#30755) 2020-05-12 19:21:36 +03:00
XhmikosR
bad48dc3b9 CI: simplify cache
While it might not be possible to invalidate the cache by changing test.yml, this should speed things up a lot due to `bundle i` taking most of the time.
2020-05-12 19:21:36 +03:00
XhmikosR
86f2c01459 Partially revert "Use regex.test() when we want to check for a Boolean. (#29969)"
This partially reverts commit 6c46493803.
2020-05-12 19:21:36 +03:00
XhmikosR
955c437f32 collapse.js: combine classes 2020-05-12 19:21:36 +03:00
XhmikosR
eb720f20ff Minor lint tweaks and rules cleanup 2020-05-12 19:21:36 +03:00
XhmikosR
53eace04df build-plugins.js: add missing shebang (#30743) 2020-05-12 19:21:36 +03:00
XhmikosR
1c9e203c52 dropdown.js: switch to a ternary 2020-05-12 19:21:36 +03:00
XhmikosR
5f79b75ea8 tests: switch to strictEqual/notStrictEqual 2020-05-12 19:21:36 +03:00
XhmikosR
195585f5a6 scrollspy.js add more tests 2020-05-12 19:21:36 +03:00
XhmikosR
fa8a7eca06 Remove variables used once. 2020-05-12 19:21:36 +03:00
XhmikosR
52fdab8d70 Join/break a few lines, no functional changes 2020-05-12 19:21:36 +03:00
XhmikosR
b3601aae5b README.md: change Tests badge to point to v4-dev 2020-05-12 19:21:36 +03:00
XhmikosR
456194da11 package.json: add a docs-build script
Make the `docs-compile` one an alias of `docs-build`.
2020-05-12 19:21:36 +03:00
XhmikosR
fb4c8eacb0 CI: stop updating RubyGems since it's not needed 2020-05-12 19:21:36 +03:00
Mark Otto
5d10e4a58e
Add new interaction utilities and role attr to Reboot (#30562)
- Adds .user-select-* utils from v5
- Adds button role attribute util, one of the top requested features in our issues for adding pointer cursors
- Adds new docs page to demonstrate both
- Includes Sass list for customizing user select
2020-05-11 20:57:29 +03:00
XhmikosR
fce3370843 Backport #29272 and adapt if for v4-dev
docs: fix tap targets
2020-05-10 12:19:58 -07:00
XhmikosR
345d68cdbb Add loading="lazy" in images
Backport of #30199 after adapting it for v4-dev.
2020-05-10 12:19:58 -07:00
Mark Otto
a1d8ed4413 v4: Update homepage, examples, and general docs styles
- Refreshes the look and feel of the homepage with fresh colors, new content, and simplified styles.
- Updates docs button styles
- Replaces bytesize icons with Bootstrap icons
- Adds themes callout to examples page
2020-05-10 12:19:58 -07:00
XhmikosR
4111242cbb Update devDependencies and gems 2020-05-07 09:31:49 +03:00
XhmikosR
e82888daf4 Revert "Avoid bad scrollbar replacement into width values (#30690)"
This reverts commit 5f00bba652.
2020-05-07 09:31:49 +03:00
Johann-S
015aaf3c3d ensure build plugins can exit in error (#30744)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-05-07 09:31:49 +03:00
Johann-S
22f75ca2e3 enforce element check on scrollspy target 2020-05-07 09:31:49 +03:00
XhmikosR
5f267b1854 Update jQuery to v3.5.1. 2020-05-07 09:31:49 +03:00
XhmikosR
0f6cb9139f scrollspy.js: remove temporary variable (#30724) 2020-05-07 09:31:49 +03:00
XhmikosR
f3aed77dc7 Backport #30723
Move babel whitelist helpers to a common file
2020-05-07 09:31:49 +03:00
XhmikosR
d8691fcd5a Update codeql.yml (#30719)
Remove `pull_request` event since it's not supported.
2020-05-07 09:31:49 +03:00
XhmikosR
566c829a1c package.json: fix release script for v4. 2020-05-07 09:31:49 +03:00
Mark Otto
e51a09a2b8 Wording fixes 2020-05-06 20:56:04 +03:00
XhmikosR
8876866399 Update browser-bugs.md
Add a danger callout that the page is outdated
2020-05-06 20:56:04 +03:00
Quy
d63b651f37
Fix typo (#30745)
Use possessive form of it
2020-05-06 06:54:42 +03:00
XhmikosR
1fef25b777
Revert "v4: Add Release Drafter (#30701)" (#30711)
This reverts commit f93e58eddb.
2020-05-04 20:00:19 +03:00
XhmikosR
63dbe4705d search.js: make the check for URL stricter (#30695) 2020-05-02 15:39:19 +03:00
Johann-S
5f00bba652 Avoid bad scrollbar replacement into width values (#30690) 2020-05-02 15:39:19 +03:00
XhmikosR
c06a1f305d Backport #30130
Add a script to zip the built examples
2020-05-02 15:39:19 +03:00
Johann-S
1b16736a72 fix package.json add extension in main field 2020-05-02 15:39:19 +03:00
Martijn Cuppens
ec637483f2 Backport #30685
`<pre>`: Disable auto-hiding scrollbar in IE & legacy Edge
2020-05-02 15:39:19 +03:00
XhmikosR
971738b4b5 Backport the CodeQL Action addition 2020-05-02 15:39:19 +03:00
XhmikosR
33f47771ca Fix redirect 2020-05-02 15:39:19 +03:00
XhmikosR
6d9256d2b1 Backport #30362
Remove unneeded og:image:secure_url from social.html

The image is always available over HTTPS anyway
2020-05-02 15:39:19 +03:00
Mark Otto
f93e58eddb
v4: Add Release Drafter (#30701)
* Create release-drafter.yml
* Create release-notes.yml
2020-05-01 11:22:10 +03:00
Shohei Yoshida
e344ed4446
v4: Change input group validation examples (#30180)
* Change input group examples

* Update forms.md

* Update site/docs/4.4/components/forms.md

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Mark Otto <markd.otto@gmail.com>
Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-04-30 09:29:03 +03:00
Mark Otto
f79d14f7c8
Fixes #30503 to replace renamed position utility (#30505) 2020-04-30 08:11:51 +02:00
XhmikosR
748b1b9a5a CI: remove no longer needed steps (#30674)
The latest `actions/setup-node` prints this info by default
2020-04-28 20:59:30 +03:00
XhmikosR
5ecccd1171 Update devDependencies and gems. 2020-04-28 20:59:30 +03:00
Martijn Cuppens
92fe8445b1 Prevent list group style leaks (#30660) 2020-04-28 20:59:30 +03:00
XhmikosR
9c7ee5e554 CI: set CI_BRANCH_BASE to v4-dev
This is so that bundlewatch compares against v4-dev and not master.
2020-04-28 20:59:30 +03:00
XhmikosR
f5c7da4c78 Backport 9b97dc6
Tweak syntax highlighting colors to be WCAG2AA valid.

Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-04-28 20:59:30 +03:00
Martijn Cuppens
7a678fc64f Backport #30633
Remove caret element
2020-04-28 20:59:30 +03:00
Martijn Cuppens
a66d9a3d50 Backport #30605
grid: checks for `$grid-columns > 0`
2020-04-28 20:59:30 +03:00
Catalin Zalog
9d0097013a Backport #30606 (#30612)
checks for `$grid-row-columns`
2020-04-28 20:59:30 +03:00
Catalin Zalog
4853c5b527 feat: checks for $grid-breakpoints map list (#30609)
Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-04-28 20:59:30 +03:00
Mark Otto
c4355e4a6b v5: Improve the responsiveness of our Dashboard example (#30573)
Cleans up some column classes to ensure things line up across all viewports. Also fixes some broken padding on the .navbar-brand.

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-04-28 20:59:30 +03:00
k-utsumi
0321c632ed Delete appearance from button.close (#30582) 2020-04-28 20:59:30 +03:00
XhmikosR
e33e344410 Revert "Add dependabot config for v4 (#30008)"
This reverts commit 04b8219c18.
2020-04-28 20:59:30 +03:00
Martijn Cuppens
9f7fc4ac2b
Deprecate bg-gradient-variant mixin (#30594)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-04-18 09:12:51 +03:00
XhmikosR
f5ec0dbf74 collapse: fix error with jQuery v3.5.0. 2020-04-17 11:41:32 +03:00
XhmikosR
d848c32297 Fix tests for jQuery v3.5.0. 2020-04-17 11:41:32 +03:00
XhmikosR
05cfefd32b Update jQuery to v3.5.0. 2020-04-17 11:41:32 +03:00
XhmikosR
04b8219c18
Add dependabot config for v4 (#30008) 2020-04-13 21:51:22 +03:00
XhmikosR
341ad62517 Update clipboard.js to v2.0.6 2020-04-13 21:12:29 +03:00
XhmikosR
5053725870 Update bs-custom-file-input.js to v1.3.4 2020-04-13 21:12:29 +03:00
XhmikosR
04c1ecd79d Update devDependencies and gems 2020-04-13 21:12:29 +03:00
Martijn Cuppens
abc17a4858 Backport #30555
Use `box-shadow` mixin for `.form-select`
2020-04-13 21:12:29 +03:00
Martijn Cuppens
4d863effdb Backport #30512
Use `box-shadow` mixin for `.btn`
2020-04-13 21:12:29 +03:00
XhmikosR
5455e30048 Backport #30542
Remove redundant class and line height
2020-04-13 21:12:29 +03:00
XhmikosR
c1a75a7d8f Add v4-dev in bundlewatch config. (#30541) 2020-04-13 21:12:29 +03:00
XhmikosR
adb08ca33a Replace bundlesize with bundlewatch. (#30538) 2020-04-13 21:12:29 +03:00
Mark Otto
5f15f8cdbd Fix spinner-grow animation (#30504)
* Fix spinner-grow animation

Safari seems to be interpreting the old keyframes animation as incomplete. Adding `transform` to the second frame seems to resolve the issue.

Co-Authored-By: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-04-13 21:12:29 +03:00
Catalin Zalog
6edeaa4291 Add .card-footer color (#30515) 2020-04-13 21:12:29 +03:00
Martijn Cuppens
fe9384c216 Backport #30497
Fix card list group borders & radii
2020-04-13 21:12:29 +03:00
Martijn Cuppens
ddc58343d3 Backport #30480
Use `box-shadow` mixin for form controls
2020-04-13 21:12:29 +03:00
Martijn Cuppens
706bd3602d Backport #30391
transition() mixin prevent redundant 'transition: none' and pass `null`
2020-04-13 21:12:29 +03:00
Laussel Loïc
0cf29baf63
v4 tabs - accessibility issue when using ul/li semantic (#30381)
Add aria-role presentation on li element when ul element has role tablist and remove dropdown from visual tests as they've been removed from doc
2020-04-10 08:35:09 +03:00
luktom
8cc9defbc0
Fix event propagation from inactive and disabled dropdowns (#30510) (#30511) 2020-04-07 21:16:17 +03:00
Martijn Cuppens
1b575c27cd
Backport #30353 (#30361)
Remove appearance from date inputs

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-04-01 08:53:07 +03:00
XhmikosR
f7ed579d91
Switch to string constants. (#30490)
This allows the minifier to mangle the constants. It also allows the linter to find unused strings properly.

While at it, remove a few unused properties.

File                        Before      After       Diff
--------------------------------------------------------
bootstrap.bundle.min.js     22.09 kB    21.13 kB    -0.96 kB (-4.35 %)
bootstrap.min.js            15.4 kB     14.46 kB    -0.94 kB (-3.86 %)
2020-03-31 21:27:35 +03:00
XhmikosR
0225c1173b Bump devDependencies and gems. 2020-03-31 21:11:29 +03:00
XhmikosR
467c961976 Remove holder.js leftovers (#30469) 2020-03-31 21:11:29 +03:00
Tim Dujardin
b30c68f8a1 Added focus state to .btn-link (#30036) 2020-03-31 21:11:29 +03:00
XhmikosR
573c10f099 Backport #30041 and #30448
Switch links to the GitHub organization and fix redirected links
2020-03-31 21:11:29 +03:00
Shohei Yoshida
effe4e9588 Update modal docs (#30325) 2020-03-31 21:11:29 +03:00
Johann-S
dabd458b4b Backport (#30383)
fix: ensure totype always return stringified null when null passed
2020-03-31 21:11:29 +03:00
XhmikosR
0c8d8a48e1 Backport (#30418)
Open icons in a new tab like the rest of the external links
2020-03-31 21:11:29 +03:00
XhmikosR
03fec36b44 Clarify card group behavior (#30416)
Co-authored-by: Mark Otto <markd.otto@gmail.com>
2020-03-31 21:11:29 +03:00
XhmikosR
138e8da421 CI: switch to Ruby 2.6. 2020-03-31 21:11:29 +03:00
Frank Liepert
45c99f7130
Prevent vertical offset in IE 11 (#29413)
Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-03-31 14:09:09 +02:00
Laussel Loïc
8b6dd449d7
fix $().button('toggle') not working for checkbox inside label (#30388) 2020-03-16 14:28:33 +02:00
XhmikosR
ac5685d368 Update .github/workflows/test.yml 2020-03-09 16:26:10 +02:00
XhmikosR
81e8f52fcb Revert "CI: switch to Ruby 2.6" 2020-03-09 16:26:10 +02:00
XhmikosR
d65977a991 Backport #29920
Add lockfile-lint
2020-03-09 16:26:10 +02:00
XhmikosR
90fef3086d CI: switch to Ruby 2.6 2020-03-09 16:26:10 +02:00
XhmikosR
9b71d9817d Update CI caching 2020-03-09 16:26:10 +02:00
XhmikosR
3b5283602c Replace uglify-js with terser. 2020-03-09 16:26:10 +02:00
XhmikosR
cc3ca2586f Update Jekyll to v4.0.0. 2020-03-09 16:26:10 +02:00
XhmikosR
906a5de548 Replace broken-link-checker with linkinator 2020-03-09 16:26:10 +02:00
XhmikosR
61276d0881 Drop Node.js < 10 support and update all devDependencies.
* sinon 8.x doesn't work with IE, so leave it at 7.x.
2020-03-09 16:26:10 +02:00
XhmikosR
0ca1ec6fc3 Update devDependencies and gems 2020-03-09 16:08:41 +02:00
XhmikosR
f852dff122 build/ship.sh: shellcheck fixes. (#30197)
Also add `set -e` so that if a command fails the whole script fails too.
2020-03-09 16:08:41 +02:00
Martijn Cuppens
efb3fc402e $link-decoration: underline affects some components (#30262)
Co-authored-by: Shohei Yoshida <fellows3@gmail.com>
Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-03-09 16:08:41 +02:00
Martijn Cuppens
81ba76bb3c CSS & alignment tweaks 2020-03-09 16:08:41 +02:00
Minobi
39ac525f6e Example dashboard: fix menu disappearing on small viewport 2020-03-09 16:08:41 +02:00
Shohei Yoshida
fa7510c6af Fix centered modal scrolling issue (#30244)
Use the `min-content` property.
2020-03-09 16:08:41 +02:00
XhmikosR
69f36286f9 Update jekyll-toc to v0.13.1. 2020-02-17 21:33:54 +02:00
XhmikosR
52c13233a3 Update devDependencies and gems. 2020-02-17 21:33:54 +02:00
XhmikosR
642d1001e3 .gitattributes: add .sh and remove .rb files. (#30196) 2020-02-17 21:33:54 +02:00
Gaël Poupard
473d36ff38 docs(theming): improve headings hierarchy under Sass → Functions (#30207) 2020-02-17 21:33:54 +02:00
XhmikosR
4a7cbd5b9f Backport #29971
Remove old versions from docs-navbar.html
2020-02-17 21:33:54 +02:00
Shohei Yoshida
c40b71318c Remove unnecessary reduce motion when $enable-transition: false (#30183) 2020-02-17 21:33:54 +02:00
Christian Oliff
037bad148c Add Microsoft Edge for MacOS to supported browsers (#29956)
The new Chromium-based Edge has been available as a beta for sometime and general availability of the final version is expected to ship from Jan 15. I think it makes sense to add it as a supported browser once it's out of beta.
REF: https://blogs.windows.com/windowsexperience/2019/11/04/introducing-the-new-microsoft-edge-and-bing/
2020-02-17 21:33:54 +02:00
Giovanni Mendoza
0bd57ce212 Added new variable for padding on dropdown header (#29946)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-02-17 21:33:54 +02:00
XhmikosR
8c4b61e30c change-version.js: Remove nuspec files (#30161)
The version in the nuspec files is updated automatically from package.json through MyGet.ps1
2020-02-17 21:33:54 +02:00
Shohei Yoshida
c77ec4fb06 Avoid border-radius functions return negative values (#30166)
* Avoid border-radius functions return negative values

* Update _border-radius.scss

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-02-17 21:33:54 +02:00
XhmikosR
4ea685a001 Bump bootstrap.min.js bundle size limit. 2020-02-17 21:33:54 +02:00
Martijn Cuppens
0d35f10842 Add ysds to the team page (#30145) 2020-02-17 21:33:54 +02:00
Giovanni Mendoza
6daae47cc0 Backport #29886
Close modal with keyboard=true & backdrop=static
2020-02-17 21:33:54 +02:00
Jesse Mandel
0f0a8c364d Updated nuspec content files and icon (#30148)
* #30045 - Update nuspec for updated content type

* Update iconUrl (deprecated) to icon

Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-02-17 21:33:54 +02:00
Jens Luyten
7ca811315f Prevent grid with default cols from breaking when large pre was present (#30049) 2020-02-17 21:33:54 +02:00
Martijn Cuppens
1884b8a421 Backport #29325. (#30074)
`.text-break` fix
2020-02-17 21:33:54 +02:00
jorimvanhove
92525e9ec4 IE auto-size input-group to column (#30043) 2020-02-17 21:33:54 +02:00
XhmikosR
6c46493803 Use regex.test() when we want to check for a Boolean. (#29969) 2020-02-17 21:33:54 +02:00
XhmikosR
f737c73a27 javascript.md: Add srcset in sanitizer docs (#30007) 2020-02-17 21:33:54 +02:00
XhmikosR
411922b14d sanitizer.js: Add srcset in the allowed attributes (#29968) 2020-02-17 21:33:54 +02:00
Martijn Cuppens
21041eecb7
Backport #30090 (#30175)
Add version number to documentation `<title>`
2020-02-14 22:15:04 +02:00
Martijn Cuppens
fbf294a605
Fix disabled .btn cursor (#30004) 2020-02-03 19:54:29 +01:00
XhmikosR
0d1aee6a2f reboot.md: Add missing Noto Sans font (#29937)
* reboot.md: Add missing Noto Sans font

* Sans serif order fix

Co-authored-by: Martijn Cuppens <martijn.cuppens@gmail.com>
2020-01-02 12:11:56 +02:00
XhmikosR
3c0cf9365b Bump copyright year to 2020. (#29944) 2020-01-02 12:11:56 +02:00
XhmikosR
0e09c6b831 package.json: move funding property higher. (#29936) 2020-01-02 12:11:56 +02:00
XhmikosR
80d842b501 Update devDependencies and gems 2020-01-02 12:11:56 +02:00
Martijn Cuppens
55945dcc36 README.md: show sponsors first (#29931) 2020-01-02 12:11:56 +02:00
XhmikosR
42714733b6 CI: fix Ruby caching 2020-01-02 12:11:56 +02:00
Martijn Cuppens
35d5cbf4fd Escape brackets (#29857)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-01-02 12:11:56 +02:00
Martijn Cuppens
0d08c74d2f Allow percentages in container widths (#29819) 2020-01-02 12:11:56 +02:00
Martijn Cuppens
00b0e0a9b7 Documentation fix: move width after make-container() mixin (#29820)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
2020-01-02 12:11:56 +02:00
XhmikosR
16a82e7e99 Update test.yml (#29863)
Fix cache name
2020-01-02 12:11:56 +02:00
XhmikosR
e2530bf312 Update devDependencies and gems 2019-12-14 17:09:46 +02:00
XhmikosR
2d54fa9c3f Actions: add gems caching 2019-12-14 17:09:46 +02:00
XhmikosR
97e2e0da7c CI: update to actions/checkout@v2 (#29847) 2019-12-14 17:09:46 +02:00
XhmikosR
b77af55325 Actions: add npm cache (#29765) 2019-12-14 17:09:46 +02:00
AlexKoala
52aceee0ab docs: Add Korean translation link 2019-12-14 17:09:46 +02:00
719media
70de5e8398 Fix breadcrumb spacing with whitespace (#29745) 2019-12-14 17:09:46 +02:00
Shohei Yoshida
52762f83d8 Improve wrapping and hit area of accordion example titles (#29782) 2019-12-14 17:09:46 +02:00
XhmikosR
dca1ab7d87 Release v4.4.1. 2019-11-28 14:59:49 +02:00
Shohei Yoshida
b07b6f743c Fix dart Sass compatibility for subtract (#29763) 2019-11-28 14:59:49 +02:00
Shohei Yoshida
0d148d8854 V4: Add :disabled for disabled fieldset (#29762) 2019-11-28 14:59:49 +02:00
Martijn Cuppens
c24aaa6cbf Fix dart Sass compatibility (#29755) 2019-11-28 14:59:49 +02:00
XhmikosR
301ee1972d Update Gemfile.lock 2019-11-28 14:59:49 +02:00
XhmikosR
593574d510
Release v4.4.0 (#29735) 2019-11-26 19:12:00 +02:00
XhmikosR
d61bba584f Backport #29734
justify-content:between ⇒ justify-content:space-between
2019-11-26 09:51:27 +02:00
XhmikosR
7aa1722a97 Update change-version.js (#29736)
Add `.nuspec` to the extensions list
2019-11-26 09:51:27 +02:00
XhmikosR
340009e6de Update devDependencies and gems. 2019-11-25 13:12:53 +02:00
XhmikosR
bdd8752994 Switch to the Coveralls Action (#29478)
This is the official way of using Coveralls with Actions. Also this brings back Coveralls for PRs.
2019-11-25 13:12:53 +02:00
XhmikosR
e0a2d5890d Backport #29624
config.yml: update popper.js to v1.16.0
2019-11-25 13:12:53 +02:00
XhmikosR
136afcf59b Update anchor.js to v4.2.1 (#29662) 2019-11-25 13:12:53 +02:00
Sam Duvall
eb1e1cfb49 Fixed input-height-sm and input-height-lg calculations (#29653) 2019-11-25 13:12:53 +02:00
Martijn Cuppens
5be0fe8820 package.json: Add funding property (#29646) 2019-11-25 13:12:53 +02:00
XhmikosR
a0bb417691 Fix icons link. 2019-11-25 13:12:53 +02:00
Martijn Cuppens
590c1baeeb progress: Fix IE overflow (#29629) 2019-11-25 13:12:53 +02:00
XhmikosR
f12ae8cea2 Sass: fix version in deprecation messages.
The final version will be bumped when the next version is released.
2019-11-25 13:12:53 +02:00
Gary PEGEOT
6b7ca1234b Make check label cursor customizable (#29633) 2019-11-07 21:02:10 +02:00
XhmikosR
0aa6a81c11 Update devDependencies and gems. 2019-11-02 10:02:07 +02:00
XhmikosR
7629daedc1 Update modal.md (#29621)
Fix typo
2019-11-02 10:02:07 +02:00
Johann-S
dd96b832f7 backport #29516: added animation when modal backdrop is static 2019-11-02 10:02:07 +02:00
Johann-S
29f585365f backport #29523: skip hidden dropdowns while focusing 2019-11-02 10:02:07 +02:00
Martijn Cuppens
f55566e36b Add configurable button text wrapping (#29554) 2019-11-02 10:02:07 +02:00
XhmikosR
7ecfa6a343 Backport #29585
Enable eslint no-console rule except for build directory
2019-11-02 10:02:07 +02:00
XhmikosR
7453733ff6 Backport #29544
Add link to Icons site in our docs
2019-11-02 10:02:07 +02:00
XhmikosR
dd6b8682a6 CI: disable gem docs globally 2019-11-02 10:02:07 +02:00
XhmikosR
8e935b60c8 CI: install bundler 1.17 and without docs 2019-11-02 10:02:07 +02:00
Mark Otto
9be7aac831 Add make-col-auto mixin (#29367) 2019-11-02 10:02:07 +02:00
XhmikosR
f830450ca8 Fix highlighting.
v4-dev is using Jekyll, not Hugo.
2019-11-01 20:22:37 +02:00
Martijn Cuppens
b0b8d3c982 Convert v4-dev calc() left overs to add/subtract functions 2019-11-01 20:22:37 +02:00
Martijn Cuppens
90d4b72e06 Add calc() to function blacklist 2019-11-01 20:22:37 +02:00
Mark Otto
ea1d09c444 Doc tweaks. 2019-11-01 20:22:37 +02:00
ysds
7bd70e54f2 Add add and subtract function 2019-11-01 20:22:37 +02:00
Martijn Cuppens
ed4a4e6081 Link to versioned RFS repo (#29598) 2019-10-28 08:41:08 +02:00
Christian Oliff
087d0ea1e1 The HTML5 Boilerplate Print CSS moved to a separate repo (#29522)
The HTML5 Boilerplate CSS has moved to a separate GitHub repo (h5bp/main.css) so the source link referenced here no longer works. This PR updates the link to the new correct location.
2019-10-15 09:40:01 +03:00
XhmikosR
8cf6c209d8 Update devDependencies and gems.
Locked qunit to v2.9.2 to prevent test failures. We should revisit qunit later.
2019-10-14 12:12:05 +03:00
ysds
db19e8c706 Fix incorrect aspect ratio on IE11 2019-10-14 12:12:05 +03:00
Martijn Cuppens
510a446be6 Remove redundant properties 2019-10-14 12:12:05 +03:00
Martijn Cuppens
327bfca418 Fix top level ampersand (#29518)
Fixes dart sass compatibility.
2019-10-14 12:12:05 +03:00
XhmikosR
be452a0ed3 CI: move CI env variable to the root of the workflow. (#29499)
This way we match the Travis CI behavior, and it's inherited by all steps.
2019-10-14 12:12:05 +03:00
XhmikosR
23a78f0ab1 Update .gitignore.
Remove the old Hugo static dist folder.
2019-10-14 12:12:05 +03:00
Martijn Cuppens
6c9640c245 Backport #29445
Remove outline from select box in Firefox
2019-10-14 12:12:05 +03:00
astrahov
1260b4fb3f Add variable for $breadcrumb-font-size (#29467) 2019-10-14 12:12:05 +03:00
Martijn Cuppens
d521e147f9 Fix border for single card in accordion (#29453) 2019-10-14 12:12:05 +03:00
Martijn Cuppens
f47243460e Variable card height (#29462) 2019-10-14 12:12:05 +03:00
XhmikosR
91a9fd96b9 coveralls: Add COVERALLS_GIT_BRANCH (#29458)
Without this, coveralls didn't receive the branch info thus leading to failures when we switched branches.
2019-10-14 12:12:05 +03:00
XhmikosR
5e304b60a1 workflows/test.yml: specify CI=true (#29440) 2019-10-14 12:12:05 +03:00
XhmikosR
4c74d58f26 README.md: link to the Actions page for Tests (#29480) 2019-10-14 12:12:05 +03:00
Martijn Cuppens
cd64a164f1 IE image fix (#29483) 2019-10-08 08:49:29 +03:00
XhmikosR
1f2b048312 Use 180 for the grid-cards placeholder images' height. 2019-09-26 18:37:07 +03:00
XhmikosR
caf889e49e Update devDependencies and gems. 2019-09-26 18:37:07 +03:00
Shohei Yoshida
b5ba078b12 Grid card example tweaks (#29409)
Stack in cards in one column when < md
2019-09-26 18:37:07 +03:00
XhmikosR
cdfba0be4a GH Actions updates. (#29429) 2019-09-26 18:37:07 +03:00
XhmikosR
61cc86d68d workflows/test.yml: use ruby-version.
`version` is deprecated.
2019-09-26 18:37:07 +03:00
XhmikosR
846b603413 workflows/test.yml: switch to setup-node@v1. (#29410) 2019-09-26 18:37:07 +03:00
XhmikosR
791b1943f2 Bump bundlesize limits. 2019-09-26 18:37:07 +03:00
ysds
8741eed7a5 Add responsive example 2019-09-26 18:37:07 +03:00
ysds
afc9cae32c Allow override default col width 2019-09-26 18:37:07 +03:00
Mark Otto
d08567797f Cleanup
- Rename and move the variable to variables file
- Move code to the grid file
- Use the mixin to generate our own classes
- Wrap in a grid classes enabled conditional
- Document the mixin
2019-09-26 18:37:07 +03:00
Mark Otto
acb2b7061c Move margins, and equal height via utility example 2019-09-26 18:37:07 +03:00
Mark Otto
9ed860ef24 First pass at .row-cols classes
Trying to find a new way to do responsive card decks while not locking ourselves into the cards themselves. My thinking here is we can easily control the column (.col) width by the parent, but I don't know how many we need (have 0-5 now) across each breakpoint. This works for cards so far, and I think could get us equal height, too.
2019-09-26 18:37:07 +03:00
XhmikosR
28758a03f0 carousel.md: Remove duplicate bd-example div. (#29341)
The example shortcode already adds this.
2019-09-26 18:37:07 +03:00
XhmikosR
f732bf025a docs: remove swatches for theme colors. (#29327)
Use the built-in utilities instead.
2019-09-26 18:37:07 +03:00
XhmikosR
68ddcec057 theming.md: bring :root up to par with Scss. (#29323)
Also, add a warning in _root.scss so that we don't miss it again.
2019-09-26 18:37:07 +03:00
XhmikosR
6d5739320e blog example: remove unused CSS. (#29316) 2019-09-26 18:37:07 +03:00
Martijn Cuppens
5d39e36083 Don't bind validation to form controls 2019-09-26 18:37:07 +03:00
XhmikosR
269e5351aa Update devDependencies and gems. 2019-08-27 16:32:25 +03:00
Johann-S
ef1c7aadbc Backport #29298
dropdown show method should do the same as toggle
2019-08-27 16:32:25 +03:00
XhmikosR
dd181e91bd Actions CI tweaks (#29276)
* Allow bundlesize to run for forks too.
* Add name for clone step.
* Add` fail-fast: false`
2019-08-27 16:32:25 +03:00
Johann-S
bab999701c Backport #29277
dropdown - destroy old popper.js references
2019-08-27 16:32:25 +03:00
tracyjordan
41b8ce278b fixed minor typo (#29291) 2019-08-27 16:32:25 +03:00
XhmikosR
de94f6003f test.yml: reindent. 2019-08-27 16:32:25 +03:00
XhmikosR
3a3b0a4eae change-version.js: Add _gh_pages folder in ignores. (#29270) 2019-08-27 16:32:25 +03:00
Martijn Cuppens
c4e5aa0d32 docs: fix tap targets (#29272) 2019-08-27 16:32:25 +03:00
Johann-S
7652d326e4 Backport #29251
allow to pass popper.js configuration for tooltip/popover and dropdown
2019-08-27 16:32:25 +03:00
Martijn Cuppens
6381c63fb1 Add deprecation warning 2019-08-26 09:29:50 +02:00
Martijn Cuppens
9e1ef5623f Deprecate nav-divider() mixin 2019-08-22 08:10:03 +02:00
Martijn Cuppens
9519b9e055 Enable wrapping for elements in .modal-footer (#25103) 2019-08-17 17:03:00 +03:00
Martijn Cuppens
94395af932 Restore cursor: pointer for checkbox/radio buttons (#29239) 2019-08-17 17:03:00 +03:00
Martijn Cuppens
81d5e6eb1b Clarify order documentation (#29252) 2019-08-17 17:03:00 +03:00
XhmikosR
38d055e7fb Fix redirects. (#29254) 2019-08-17 17:03:00 +03:00
XhmikosR
727c1684bb Update devDependencies and gems. 2019-08-17 17:03:00 +03:00
Martijn Cuppens
e538b9f23e Fix Firefox rendering issue (#29234) 2019-08-17 17:03:00 +03:00
XhmikosR
116da0b746 Bump bootstrap.min.css bundlesize limit. 2019-08-17 17:03:00 +03:00
Shohei Yoshida
c387223720 Fix min-width of input-group flex items (#29209) 2019-08-17 17:03:00 +03:00
Mark Otto
81fa902454 Responsive containers (follow-up to #29095) (#29118)
* Follow-up to #29095

This PR fixes the responsive containers that were added in #29095, originally stubbed out in #25631. Apologies to @browner12 for getting that wrong.

Fixes #25631.

* update navbar as well because we cannot reset all containers uniformly

* Update navbars example to include container-xl example to ensure containers match

* rewrite responsive containers docs, add table of max-widths

* Update container docs
- Move table up to the intro
- Remove the container example because it's actually hella confusing
- Update and link to grid example as a demo instead
2019-08-17 17:03:00 +03:00
XhmikosR
d55f6c3073 Simplify css-prefix scripts. (#29205) 2019-08-17 17:03:00 +03:00
Martijn Cuppens
e5a3ee5e9c Extend .container-fluid (#29106) 2019-08-17 17:03:00 +03:00
Mark Otto
3695c3a1fb fix broken classes 2019-08-17 17:03:00 +03:00
Mark Otto
2892675f65 v4/v5: Add responsive containers (#29095)
* create responsive containers

provide more flexibility and allow the user to determine when containers switch from fluid to fixed width.

* fix the base container code

this commit fixes the non-media portion of the generated CSS. I learned about the `@extends` directive and was able to put it to good use.

I create a new temporary map that contains all the main `$container-max-widths` and join it to our 2 special cases of 'xs' and 'fluid'.  Then we loop through that and, with the appropriate infixes, extend our placeholder

* formatting for style

forgot to run my tests before the last push, i think these are better.

* finish incomplete comment

* fix the responsive containers

using the `@extend` directive I was able to clean up this code

* fix responsive containers in the navbar

mostly we just look through all of our breakpoints so we can include all of the responsive container classes in the tweaks we have to do for the navbar (redeclaring flex properties, don't double up on padding, etc)

* Simplify container extends

* Simplify navbar containers

* Rearrange, add comments, ensure everything is nested in $enable-grid-classes

* Reduce new CSS by using attribute selector

We avoid using `@extend` whenever possible, and this is more readable

* Update _grid.scss

* Update _navbar.scss

* Add docs for responsive containers, redesign the container layout page

* Add to the Grid example
2019-08-17 17:03:00 +03:00
XhmikosR
9abaafa546
Add workflows/test.yml for v4-dev. (#29230) 2019-08-09 10:38:33 +03:00
XhmikosR
c93fdec2f0
Disallow crawling on Netlify. (#29194) 2019-08-03 17:09:25 +03:00
Herst
8c3a1298f7 Add missing role="document" (#29172) 2019-07-31 11:37:39 +03:00
XhmikosR
fb6266a8df carousel: fix transition properties order. (#29173) 2019-07-31 11:37:39 +03:00
XhmikosR
96d4a64944 Update devDependencies and gems. 2019-07-31 11:37:39 +03:00
Patrick H. Lauke
cf07b5a7ab Fix minor typo (#29168) 2019-07-31 11:37:39 +03:00
Shohei Yoshida
f6b00cda24 Fix reboot for placeholder links (#29164) 2019-07-31 11:37:39 +03:00
Patrick H. Lauke
af0786b10f Minor: fix sentence (#29160)
"Popovers whose both title..."
2019-07-31 11:37:39 +03:00
Patrick H. Lauke
d5266dc995 Fix reboot for placeholder links (#29162)
Backport of #29140
2019-07-31 11:37:39 +03:00
Chandan Deep
397359154c Change property from background to background-image (#29149)
For Gradient, We have to use the background-image instead of only background.
2019-07-31 11:37:39 +03:00
Brian Juul Andersen
cd58245f10 Update scrollspy.md (#29156)
Fixed minor grammatical error:

"... the best method get scroll ..."

=>

"... the best method to get scroll ..."
2019-07-31 11:37:39 +03:00
Johann-S
e4d4c5d0bc Backport #29155
allow dynamic modal body for scrollable modals
2019-07-31 11:37:39 +03:00
Martijn Cuppens
8f95b26d65 Haha, floats. It's 2019 (#29147) 2019-07-31 11:37:39 +03:00
XhmikosR
e1cd51e4fb Update docs vendor libs (#29134)
* Update bs-custom-file-input.min.js to v1.3.2.
* Update anchor.min.js to v4.2.0.
2019-07-31 11:37:39 +03:00
XhmikosR
dcdd9be0b3 Backport #29121.
Remove https://glyph.smarticons.co/ from list of suggestions.
The domain is now for sale and is triggers warnings in Firefox and Chrome
2019-07-31 11:37:39 +03:00
Martijn Cuppens
48e86c5796 Apply at-mixin-argumentless-call-parentheses: always stylelint rule for v4 mixins 2019-07-31 11:37:39 +03:00
Martijn Cuppens
d59aa2c702 Apply at-mixin-argumentless-call-parentheses: always stylelint rule 2019-07-31 11:37:39 +03:00
XhmikosR
22f6a4beea Add --continue-on-error in the css-lint script. (#29119) 2019-07-31 11:37:39 +03:00
Shohei Yoshida
470adc3f16 Force reflow for fade-in animation (#29113) 2019-07-31 11:37:39 +03:00
XhmikosR
e01103e3f9 Downgrade karma-browserstack-launcher to v1.4.0. (#29109)
This might fix the build failures we are getting.
2019-07-31 11:37:39 +03:00
Martijn Cuppens
9322cc83bc Simplify css-compile-main script (#29102) 2019-07-31 11:37:39 +03:00
XhmikosR
0f376c1107 Update svgo.yml. (#29089) 2019-07-31 11:37:39 +03:00
Kitten King
b66abdf3b1 Fix Typos across Bootstrap repository (#29082) 2019-07-31 11:37:39 +03:00
XhmikosR
1bee3c03cf Remove iconic and add feather icons. (#29079) 2019-07-31 11:37:39 +03:00
Martijn Cuppens
a2a38058af .custom-select: combine properties. 2019-07-30 15:43:38 +03:00
XhmikosR
41fd25abe1 Optimize the inline SVGs. 2019-07-30 15:43:38 +03:00
XhmikosR
f233e05acc Disable the !default rule for our docs variables. 2019-07-30 15:43:38 +03:00
XhmikosR
eeea633150 Use the background shorthand. 2019-07-30 15:43:38 +03:00
XhmikosR
a5d280365b docs: use the escape_svg function. 2019-07-30 15:43:38 +03:00
Martijn Cuppens
c26e68427c Backport "Use escape-svg() function (#29077)"
Adapted for v4-dev.
2019-07-30 15:43:38 +03:00
XhmikosR
68ab243ffa SVGs: lowercase hex values. 2019-07-30 15:43:38 +03:00
XhmikosR
cac30c0722 Update devDependencies. 2019-07-17 14:48:26 +03:00
XhmikosR
def8173e7b Fix bootstrap-themes.png. (#29061)
For some reason the old image was bad quality.
2019-07-17 14:48:26 +03:00
M. Wacker
921f17a650 Fix breaking layout breaking error in code (#28328)
Change `word-break: break-word;` to `word-wrap: break-word;`
2019-07-17 14:48:26 +03:00
Brian Juul Andersen
636204974b Updated sentence (#29051)
Checkboxes and radios use are built to support HTML-based form

=>

Checkboxes and radio buttons support ...
2019-07-17 14:48:26 +03:00
Manuel Alcaraz
c6cbae6b2a #29034 Fix broken links (#29035) 2019-07-17 14:48:26 +03:00
Sunny Dhoke
4e4a1febb0 Added link to creative commons license (#29032)
The previous link is dead one.
2019-07-17 14:48:26 +03:00
Brian Juul Andersen
f2185b9b5f Update collapse.md (#29025)
Corrected minor spelling error.
2019-07-17 14:48:26 +03:00
Johann-S
a894ea3a51 updated babel 2019-07-17 14:48:26 +03:00
XhmikosR
0ad0985ac0 Update devDependencies and gems.
Also lock babel versions, since we get failures with newer ones.
2019-07-10 11:03:54 +03:00
XhmikosR
d361194a99 Move bundlesize config to a separate file. (#29002) 2019-07-10 11:03:54 +03:00
Patrick H. Lauke
3d72b94ee9 Add prefers-reduced-motion callout to toast documentation (#28993)
x-ref #28987
2019-07-10 11:03:54 +03:00
Bardi Harborow
d395dfaafc Add ARIA search landmark to documentation. (#28983) 2019-07-10 11:03:54 +03:00
Martijn Cuppens
e61d609bc0 Ignore the bg-variant deprecation warning in our files. 2019-07-10 11:03:54 +03:00
Martijn Cuppens
23d7dd6dbd Remove redundant radius properties (#28956) 2019-07-10 11:03:54 +03:00
Patrick H. Lauke
be80d26cdb Ensure button plugin sets/removes active class correctly on page load (#28952)
* Ensure correct active class is set on button toggles/checkboxes/radios on page load

Sanity check, ensures that the UI visually matches the actual values/states of controls. Also ensures that if any autocomplete/autofill happened, this is visually accounted for
by having the correct class set.

Includes unit tests (and `autocomplete` has been removed from these as it's no longer necessary)

* Remove now unnecessary autocomplete attribute

As the attribute was there to force/ensure that the visual presentation matched the state, and this is now taken care of programmatically, there's no need to unnecessarily suppress autocomplete...let them autocomplete if they want to...
2019-07-10 11:03:54 +03:00
Sergey Kovalenko
22f6b373f9 Remove negative margins for group list items (#28940)
To fix RGBA borders overlapping issue.
2019-07-10 11:03:54 +03:00
XhmikosR
a92f838c8d Minor wording changes. 2019-07-10 11:03:54 +03:00
Jonathan Hawkins
e76fce5852 Combine duplicate documentation examples into one to fix the confusing text. 2019-07-10 11:03:54 +03:00
Martijn Cuppens
c121778b49 Change invalid icon from cross to exclamation mark (#28944)
The cross icon was confusing since some browsers use it as a reset button.
2019-07-10 11:03:54 +03:00
Robin D'Arcy
4376d92ea7 Docs – update extend/approach.md (#28941) 2019-07-10 11:03:54 +03:00
Martijn Cuppens
de163b337c
Deprecate bg-variant() mixin (#28938) 2019-06-20 21:30:09 +02:00
Patrick H. Lauke
5f44e01dab Add missing dropdown unit test for closing with ESC (#28929)
Backport of the unit test from https://github.com/twbs/bootstrap/pull/28928
2019-06-19 13:43:48 +03:00
Martijn Cuppens
1c5e1cb3c9 Typo fix (#28920) 2019-06-18 15:02:58 +03:00
Shohei Yoshida
b165aff2f7 Fix position of browser default validation message (#28852) 2019-06-18 15:02:58 +03:00
Morteza Ziyae
1bdeab8159 Fix width and height of data svg images in IE10 (#28883) 2019-06-18 15:02:58 +03:00
Patrick H. Lauke
1da3aa3103 Don't open dropdown on ESC on trigger element (#28912)
* Don't open dropdown on ESC on trigger element

Closes #28751
2019-06-18 15:02:58 +03:00
XhmikosR
6587e5cf80 Update devDependencies and gems. 2019-06-18 15:02:58 +03:00
Johann-S
6c9f833a90 tooltip dispose:removing only own event handler (#28896) 2019-06-18 15:02:58 +03:00
Patrick H. Lauke
24abed1336 Fix keyboard handling of button-style checkbox/radio button groups (#28834)
- adds more defensive checks to make sure no unnecessary toggling happens on disabled buttons; this also fixes an up-to-now undiscovered bug where a toggle button with `.disabled` class would still have its `aria-pressed` toggled
- adds a set of explicit tests for the above case of disabled buttons and `aria-pressed`
- remove a now irrelevant (or at least very nonsensical) test for `<label>` containing both an actionable and a `hidden` `<input>`
- expand the test for disabled checkbox to also explicitly test starting conditions (used mainly in my debugging)
- ensure that `$btn[0].click()` is used to click checkboxes in tests, rather than the `click()` on the jquery object which is simply a shorthand for `trigger('click')` and does not actually trigger the browser default behavior
- remove the `preventDefault()` from the button handling, which was preventing correct keyboard functionality for checkboxes/radio buttons
- add extra logic to the button.js code to handle checkboxes correctly and avoid double-triggering as a result of mouse interactions (which saw the checkboxes being toggled twice, thus returning them to their original state)
- add logic that prevents the `checked` property from being added incorrectly for any inputs other than radio buttons and checkboxes
- added more tests (including the most basic test for a properly triggered fake checkbox button)
- work around Firefox bug #1540995 (which this code was hitting after removing the `preventDefault()`, due to Firefox's incorrect toggling of disabled checkboxes when programmatically (but not manually) activated with a `click()` event
2019-06-18 15:02:58 +03:00
Patrick H. Lauke
5bf876cb0f Docs: add accessibility/keyboard callout to popovers, tweak tooltips callout (#28851)
- Add same advice about keyboard/AT handling to popovers as a callout; also add information about not adding excessive content or interactive controls (and the suggestion to opt for a modal)
- Tweak the tooltips callout for consistency
2019-06-18 15:02:58 +03:00
Shohei Yoshida
911b72cf78 Workaround for the image size bug in IE (#28855) 2019-06-18 15:02:58 +03:00
Christian Oliff
e0d0f5a1c6 HTTPS link to codeguide.co (#28860) 2019-06-18 15:02:58 +03:00
XhmikosR
5baad13902 Use npm-run-all in the netlify script. (#28846) 2019-05-30 11:58:34 +03:00
XhmikosR
d9a8b8ea80 Update devDependencies and gems. 2019-05-30 11:58:34 +03:00
Jay Pinho
1161bff6eb Make example description more accurate (#28842) 2019-05-30 11:58:34 +03:00
Shohei Yoshida
a84a05a56a Clean input group flex basis (#28785) 2019-05-30 11:58:34 +03:00
Shohei Yoshida
9d075734cb Calc modal header/footer border radius according to the border width (#28775) 2019-05-30 11:58:34 +03:00
Aditya Shankar
9508c4c11b Correct grammar in modal.scss (#28829) 2019-05-30 11:58:34 +03:00
Sezer Esen
01a71532d9 Fix background position (#28814) 2019-05-30 11:58:34 +03:00
XhmikosR
621391255b vnu.jar: Update ignores. (#28817)
Pass the `--no-langdetect` flag instead of ignoring the warning manually.
2019-05-30 11:58:34 +03:00
Johann-S
c6dd1a7d93 Backport #28777.
Toast should allow prevent default for hide and show events
2019-05-30 11:58:34 +03:00
Shohei Yoshida
fe777292b5 Fix z-index according to our z-index rule (#28784)
https://getbootstrap.com/docs/4.3/extend/approach/#z-index-scales
2019-05-30 11:58:34 +03:00
Christian Oliff
67be130c7b Update Yarn package link to link to the Bootstrap package (#28781)
I think it makes more sense to link to the Bootstrap package on Yarn here (like the package link for NPM above)
2019-05-30 11:58:34 +03:00
XhmikosR
be7198a05b Travis CI: Add Node.js 12. 2019-05-30 11:58:34 +03:00
XhmikosR
f72d2511ba Update devDependencies. 2019-05-09 21:30:32 +03:00
Shohei Yoshida
4251c23f71 Reset input padding for cross browser consistency (#28208) 2019-05-09 21:30:32 +03:00
zhangbao
fc745a3ec8 Consistency modification (#28750) 2019-05-09 21:30:32 +03:00
Martijn Cuppens
e9d8c1a9dd Backport #28679.
* Documentation tweaks
* Remove redundant `col-12` classes
2019-05-09 21:30:32 +03:00
Patrick H. Lauke
36ea7e7421 Album example: remove misleading jumbotron-heading classname (#28741) 2019-05-09 21:30:32 +03:00
Shohei Yoshida
aa7b055064 Fix incorrect variable for popover border radius (#28733)
* Use $popover-border-radius

* Move and rename the local $offset-border-width to the global variable
2019-05-09 21:30:32 +03:00
Christian Oliff
add38103ad Fix broken link to css-discuss.incutio.com/wiki/Printing_Tables (#28637)
Instead now pointing to the most recent Wayback Machine archive copy.
2019-05-09 21:30:32 +03:00
Martijn Cuppens
5c65ea6a38 Scrollbar fix (#28417) 2019-05-09 21:30:32 +03:00
XhmikosR
27287a6884 Update devDependencies including jQuery to v3.4.1. 2019-05-02 16:59:49 +03:00
XhmikosR
cc5292f510 Backport #28551.
Show the other navbar items on small screens too.
2019-05-02 16:59:49 +03:00
XhmikosR
7da9729a62 Update (dev)Dependencies and gems.
Also, fix the `update-deps` excludes and add karma since 4.x requires Node.js >= 8.
2019-04-29 17:41:28 +03:00
Mark Otto
605704d7f5 Prevent form validation mixin from generating invalid CSS (#28447)
Extrapolates the previously used selector into a new mixin that only generates valid CSS by creating psuedo-classes for `valid` and `invalid`, and nothing else.

Fixes #28380.
2019-04-29 17:41:28 +03:00
Shohei Yoshida
68932330f0 Sync plain text font-size with $input-font-size (#28464) 2019-04-29 17:41:28 +03:00
Martijn Cuppens
78f47133e9 Remove redundant slashes (#28677) 2019-04-29 17:41:28 +03:00
Johann-S
c50c1e9d23 fix unit tests for chrome mobile 2019-04-29 17:41:28 +03:00
Shohei Yoshida
10f91729aa Add $custom-control-label-color variable (#28633) 2019-04-29 17:41:28 +03:00
ysds
57ff6ee9ef Call hide() after delay time 2019-04-29 17:41:28 +03:00
XhmikosR
77973cd7fb Fix clean-css breakWith option. 2019-04-29 17:41:28 +03:00
Matěj Kříž
41eea9edc4 Fix buttons :focus state styles (#27890)
* Fix buttons :focus state styles

Buttons :hover and :focus state shares styles.
Buttons :focus text color on 'a.btn' is now consistent with others '.btn'.

* `:focus` styles should be in sync with `.focus`.

So shared styles with hover were copy to focus definition. Rather then using
`hover-focus` mixin which do not contain `.focus`.
2019-04-29 17:41:28 +03:00
XhmikosR
060880296a karma.conf.js: switch to CI === true. (#28588) 2019-04-29 17:41:28 +03:00
Loïc Goyet
1c7cb61072 Remove scss variable defined twice (#28567) 2019-04-29 17:41:28 +03:00
XhmikosR
3bf08d87c9 Update devDependencies and gems. 2019-03-27 20:57:28 +02:00
Johann-S
8fda884ad3 Reset carousel touch delta x to prevent click transformation in swipe (#28558) 2019-03-27 20:57:28 +02:00
XhmikosR
c0b2f72a06 Add a netlify npm script. (#28552) 2019-03-27 20:57:28 +02:00
XhmikosR
12532dc913 Remove http from docs search. (#28557)
We use only `https` for a few months now.
2019-03-27 20:57:28 +02:00
Patrick H. Lauke
3ab0441667 Check prefers-reduced-motion variable before adding reduced motion media query for animated progress bars (#28530) 2019-03-27 20:57:28 +02:00
Shohei Yoshida
60f31b32f8 Workaround for MS edge bug (#28275) 2019-03-27 20:57:28 +02:00
XhmikosR
77212386c0 Revert back to the old snippet and just add anonymize IP.
We don't need the extra bloat of gtag.
2019-03-27 20:57:28 +02:00
Mark Otto
e34ba3532f Update GA to latest script & anonymize IPs 2019-03-27 20:57:28 +02:00
XhmikosR
72a1437dae .gitignore: add the Hugo folders. 2019-03-27 20:57:28 +02:00
XhmikosR
413c313644 Use local doc versions favicon.ico. 2019-03-27 20:57:28 +02:00
XhmikosR
c9159ccf05 Include favicons for examples. 2019-03-27 20:57:28 +02:00
Jim Jiang
9ba80d31d4 Remove redundant placeholders in forms docs (#28406)
* Change state field to select
* Include "Choose..." placeholder for select
* Change validated select to .custom-select
2019-03-12 15:23:12 +02:00
Patrick H. Lauke
86a97d197e Remove indiscriminate outline suppression for tabindex="-1" elements (#28437)
instead, only apply outline suppression if the browser wouldn't normally apply the focus outline, using the (currently experimental) `:focus-visible` pseudo-class
2019-03-12 15:16:49 +02:00
Shohei Yoshida
87527d8149 Add <ol> to nav's comment (#28426) 2019-03-08 00:30:25 +02:00
mspae
be8ef5f655 disable assert assending check if the previous unit was a percentual value (#28400) 2019-03-08 00:30:25 +02:00
Johann-S
86de1d3875 fix jquery detection 2019-03-08 00:30:24 +02:00
XhmikosR
dad0765ed3 Update devDependencies and gems. (#28347) 2019-03-08 00:30:24 +02:00
Chris Barr
f2b9055c2b Fix issue template links to the contributing guidelines (#28378) 2019-03-08 00:29:21 +02:00
Laussel Loïc
a5179125b0 put secondary navigation in an explicit landmark nav and add a label on each nav (#28361) 2019-03-08 00:29:21 +02:00
Laussel Loïc
1a8886b7f7 add an explicit aria-label on link with svg on sample pages (#28360) 2019-03-08 00:29:21 +02:00
Martijn Cuppens
ba641ae507 Fix border if only one card (#28365) 2019-03-08 00:29:21 +02:00
XhmikosR
11c40217cf Add --continue-on-error in npm run lint. (#28338)
So if one of the two sub-tasks fails, it still completes linting the other one.
2019-03-08 00:29:21 +02:00
Pierre GIRAUD
3b6c5ee620 Fix indentation (#28321) 2019-03-08 00:29:21 +02:00
XhmikosR
d30039c1a9 Update CONTRIBUTING.md for the current state of things. (#28283) 2019-03-08 00:29:20 +02:00
Laussel Loïc
a46866c950 add tabindex="-1" and aria-disabled="true" on disabled links (#28305) 2019-03-08 00:29:20 +02:00
Bardi Harborow
146cfa21a3 Create SECURITY.md (#28288) 2019-03-08 00:29:20 +02:00
XhmikosR
5e9fd345da Use npm-run-all for the release script. (#28307)
It's shorter.
2019-03-08 00:29:20 +02:00
XhmikosR
b2e9341b8c Update devDependencies. (#28292) 2019-03-01 17:26:36 +02:00
XhmikosR
58a1c6ef92 Update devDependencies. (#28271) 2019-03-01 17:26:35 +02:00
Martijn Cuppens
fad6dda456 Deprecate form-control-focus mixin (#28262) 2019-03-01 17:25:58 +02:00
XhmikosR
60ba89b9a7 Replace 4.3.0 with 4.3.1 in nuget files. (#28273) 2019-03-01 17:25:58 +02:00
XhmikosR
8d109b62ba Update docs and meta for 3.4.1. (#28255) 2019-03-01 17:25:58 +02:00
806 changed files with 56064 additions and 97034 deletions

View file

@ -8,5 +8,10 @@ module.exports = {
modules: false modules: false
} }
] ]
] ],
env: {
test: {
plugins: [ 'istanbul' ]
}
}
}; };

View file

@ -1,15 +1,13 @@
# https://github.com/browserslist/browserslist#readme # https://github.com/browserslist/browserslist#readme
>= 0.5% >= 1%
last 2 major versions last 1 major version
not dead not dead
Chrome >= 60 Chrome >= 45
Firefox >= 60 Firefox >= 38
# needed since Legacy Edge still has usage; 79 was the first Chromium Edge version Edge >= 12
# should be removed in the future when its usage drops or when it's moved to dead browsers Explorer >= 10
not Edge < 79 iOS >= 9
Firefox ESR Safari >= 9
iOS >= 10 Android >= 4.4
Safari >= 10 Opera >= 30
Android >= 6
not Explorer <= 11

View file

@ -6,55 +6,39 @@
}, },
{ {
"path": "./dist/css/bootstrap-grid.min.css", "path": "./dist/css/bootstrap-grid.min.css",
"maxSize": "6 kB" "maxSize": "6.25 kB"
}, },
{ {
"path": "./dist/css/bootstrap-reboot.css", "path": "./dist/css/bootstrap-reboot.css",
"maxSize": "2.25 kB" "maxSize": "2 kB"
}, },
{ {
"path": "./dist/css/bootstrap-reboot.min.css", "path": "./dist/css/bootstrap-reboot.min.css",
"maxSize": "2 kB" "maxSize": "2 kB"
}, },
{
"path": "./dist/css/bootstrap-utilities.css",
"maxSize": "7.5 kB"
},
{
"path": "./dist/css/bootstrap-utilities.min.css",
"maxSize": "6.75 kB"
},
{ {
"path": "./dist/css/bootstrap.css", "path": "./dist/css/bootstrap.css",
"maxSize": "24 kB" "maxSize": "25.5 kB"
}, },
{ {
"path": "./dist/css/bootstrap.min.css", "path": "./dist/css/bootstrap.min.css",
"maxSize": "22 kB" "maxSize": "23.5 kB"
}, },
{ {
"path": "./dist/js/bootstrap.bundle.js", "path": "./dist/js/bootstrap.bundle.js",
"maxSize": "41 kB" "maxSize": "48 kB"
}, },
{ {
"path": "./dist/js/bootstrap.bundle.min.js", "path": "./dist/js/bootstrap.bundle.min.js",
"maxSize": "21.5 kB" "maxSize": "21.5 kB"
}, },
{
"path": "./dist/js/bootstrap.esm.js",
"maxSize": "27 kB"
},
{
"path": "./dist/js/bootstrap.esm.min.js",
"maxSize": "18 kB"
},
{ {
"path": "./dist/js/bootstrap.js", "path": "./dist/js/bootstrap.js",
"maxSize": "28 kB" "maxSize": "25.5 kB"
}, },
{ {
"path": "./dist/js/bootstrap.min.js", "path": "./dist/js/bootstrap.min.js",
"maxSize": "15.5 kB" "maxSize": "14.75 kB"
} }
], ],
"ci": { "ci": {

View file

@ -9,3 +9,6 @@ indent_size = 2
indent_style = space indent_style = space
insert_final_newline = true insert_final_newline = true
trim_trailing_whitespace = true trim_trailing_whitespace = true
[*.md]
trim_trailing_whitespace = false

View file

@ -3,4 +3,5 @@
**/vendor/ **/vendor/
/_gh_pages/ /_gh_pages/
/js/coverage/ /js/coverage/
/site/static/sw.js /site/sw.js
/package.js

View file

@ -21,17 +21,10 @@
"warn", "warn",
5 5
], ],
"multiline-ternary": [ "new-cap": "off",
"error",
"always-multiline"
],
"new-cap": [
"error",
{
"properties": false
}
],
"no-console": "error", "no-console": "error",
"no-mixed-operators": "off",
"no-negated-condition": "off",
"object-curly-spacing": [ "object-curly-spacing": [
"error", "error",
"always" "always"
@ -43,16 +36,22 @@
], ],
"unicorn/consistent-function-scoping": "off", "unicorn/consistent-function-scoping": "off",
"unicorn/explicit-length-check": "off", "unicorn/explicit-length-check": "off",
"unicorn/no-array-callback-reference": "off", "unicorn/import-index": "off",
"unicorn/no-fn-reference-in-iterator": "off",
"unicorn/no-for-loop": "off", "unicorn/no-for-loop": "off",
"unicorn/no-null": "off", "unicorn/no-null": "off",
"unicorn/no-unused-properties": "error", "unicorn/no-unused-properties": "error",
"unicorn/no-useless-undefined": "off", "unicorn/no-useless-undefined": "off",
"unicorn/prefer-dom-node-append": "off", "unicorn/prefer-array-find": "off",
"unicorn/prefer-dom-node-dataset": "off", "unicorn/prefer-dataset": "off",
"unicorn/prefer-dom-node-remove": "off", "unicorn/prefer-includes": "off",
"unicorn/prefer-node-append": "off",
"unicorn/prefer-node-remove": "off",
"unicorn/prefer-number-properties": "off",
"unicorn/prefer-optional-catch-binding": "off", "unicorn/prefer-optional-catch-binding": "off",
"unicorn/prefer-query-selector": "off", "unicorn/prefer-query-selector": "off",
"unicorn/prefer-reflect-apply": "off",
"unicorn/prefer-set-has": "off",
"unicorn/prevent-abbreviations": "off" "unicorn/prevent-abbreviations": "off"
} }
} }

View file

@ -19,7 +19,7 @@ and [submitting pull requests](#pull-requests), but please respect the following
restrictions: restrictions:
* Please **do not** use the issue tracker for personal support requests. Stack * Please **do not** use the issue tracker for personal support requests. Stack
Overflow ([`bootstrap-5`](https://stackoverflow.com/questions/tagged/bootstrap-5) tag), Overflow ([`bootstrap-4`](https://stackoverflow.com/questions/tagged/bootstrap-4) tag),
[Slack](https://bootstrap-slack.herokuapp.com/) or [IRC](README.md#community) are better places to get help. [Slack](https://bootstrap-slack.herokuapp.com/) or [IRC](README.md#community) are better places to get help.
* Please **do not** derail or troll issues. Keep the discussion on topic and * Please **do not** derail or troll issues. Keep the discussion on topic and
@ -58,14 +58,14 @@ Good bug reports are extremely helpful, so thanks!
Guidelines for bug reports: Guidelines for bug reports:
0. **[Validate your HTML](https://html5.validator.nu/)** to ensure your 0. **[validate your HTML](https://html5.validator.nu/)** to ensure your
problem isn't caused by a simple error in your own code. problem isn't caused by a simple error in your own code.
1. **Use the GitHub issue search** &mdash; check if the issue has already been 1. **Use the GitHub issue search** &mdash; check if the issue has already been
reported. reported.
2. **Check if the issue has been fixed** &mdash; try to reproduce it using the 2. **Check if the issue has been fixed** &mdash; try to reproduce it using the
latest `main` (or `v4-dev` branch if the issue is about v4) in the repository. latest `master` or `v4-dev` branch in the repository.
3. **Isolate the problem** &mdash; ideally create a [reduced test 3. **Isolate the problem** &mdash; ideally create a [reduced test
case](https://css-tricks.com/reduced-test-cases/) and a live example. case](https://css-tricks.com/reduced-test-cases/) and a live example.
@ -100,13 +100,14 @@ Example:
### Reporting upstream browser bugs ### Reporting upstream browser bugs
Sometimes bugs reported to us are actually caused by bugs in the browser(s) themselves, not bugs in Bootstrap per se. Sometimes bugs reported to us are actually caused by bugs in the browser(s) themselves, not bugs in Bootstrap per se.
When feasible, we aim to report such upstream bugs to the relevant browser vendor(s), and then list them on our [Wall of Browser Bugs](https://getbootstrap.com/browser-bugs/) and [document them in MDN](https://developer.mozilla.org/en-US/docs/Web).
| Vendor(s) | Browser(s) | Rendering engine | Bug reporting website(s) | Notes | | Vendor(s) | Browser(s) | Rendering engine | Bug reporting website(s) | Notes |
| ------------- | ---------------------------- | ---------------- | ------------------------------------------------------ | -------------------------------------------------------- | | ------------- | ---------------------------- | ---------------- | ------------------------------------------------------------------------------------- | -------------------------------------------------------- |
| Mozilla | Firefox | Gecko | https://bugzilla.mozilla.org/enter_bug.cgi | "Core" is normally the right product option to choose. | | Mozilla | Firefox | Gecko | https://bugzilla.mozilla.org/enter_bug.cgi | "Core" is normally the right product option to choose. |
| Apple | Safari | WebKit | https://bugs.webkit.org/enter_bug.cgi?product=WebKit | In Apple's bug reporter, choose "Safari" as the product. | | Apple | Safari | WebKit | https://bugs.webkit.org/enter_bug.cgi?product=WebKit <br> https://bugreport.apple.com/ | In Apple's bug reporter, choose "Safari" as the product. |
| Google, Opera | Chrome, Chromium, Opera v15+ | Blink | https://bugs.chromium.org/p/chromium/issues/list | Click the "New issue" button. | | Google, Opera | Chrome, Chromium, Opera v15+ | Blink | https://bugs.chromium.org/p/chromium/issues/list | Click the "New issue" button. |
| Microsoft | Edge | Blink | https://developer.microsoft.com/en-us/microsoft-edge/ | Go to "Help > Send Feedback" from the browser | | Microsoft | Edge | EdgeHTML | https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/ | |
## Feature requests ## Feature requests
@ -123,25 +124,23 @@ Good pull requests—patches, improvements, new features—are a fantastic
help. They should remain focused in scope and avoid containing unrelated help. They should remain focused in scope and avoid containing unrelated
commits. commits.
**Please ask first** before embarking on any **significant** pull request (e.g. **Please ask first** before embarking on any significant pull request (e.g.
implementing features, refactoring code, porting to a different language), implementing features, refactoring code, porting to a different language),
otherwise you risk spending a lot of time working on something that the otherwise you risk spending a lot of time working on something that the
project's developers might not want to merge into the project. For trivial project's developers might not want to merge into the project.
things, or things that don't require a lot of your time, you can go ahead and
make a PR.
Please adhere to the [coding guidelines](#code-guidelines) used throughout the Please adhere to the [coding guidelines](#code-guidelines) used throughout the
project (indentation, accurate comments, etc.) and any other requirements project (indentation, accurate comments, etc.) and any other requirements
(such as test coverage). (such as test coverage).
**Do not edit `bootstrap.css` or `bootstrap.js`, and do not commit **Do not edit `bootstrap.css`, or `bootstrap.js`
any dist files (`dist/` or `js/dist`).** Those files are automatically generated by our build tools. You should directly!** Those files are automatically generated. You should edit the
edit the source files in [`/bootstrap/scss/`](https://github.com/twbs/bootstrap/tree/main/scss) source files in [`/bootstrap/scss/`](https://github.com/twbs/bootstrap/tree/v4-dev/scss)
and/or [`/bootstrap/js/src/`](https://github.com/twbs/bootstrap/tree/main/js/src) instead. and/or [`/bootstrap/js/src/`](https://github.com/twbs/bootstrap/tree/v4-dev/js/src) instead.
Similarly, when contributing to Bootstrap's documentation, you should edit the Similarly, when contributing to Bootstrap's documentation, you should edit the
documentation source files in documentation source files in
[the `/bootstrap/site/content/docs/` directory of the `main` branch](https://github.com/twbs/bootstrap/tree/main/site/content/docs). [the `/bootstrap/site/docs/` directory of the `v4-dev` branch](https://github.com/twbs/bootstrap/tree/v4-dev/site/docs).
**Do not edit the `gh-pages` branch.** That branch is generated from the **Do not edit the `gh-pages` branch.** That branch is generated from the
documentation source files and is managed separately by the Bootstrap Core Team. documentation source files and is managed separately by the Bootstrap Core Team.
@ -163,8 +162,8 @@ included in the project:
2. If you cloned a while ago, get the latest changes from upstream: 2. If you cloned a while ago, get the latest changes from upstream:
```bash ```bash
git checkout main git checkout v4-dev
git pull upstream main git pull upstream v4-dev
``` ```
3. Create a new topic branch (off the main project development branch) to 3. Create a new topic branch (off the main project development branch) to
@ -183,7 +182,7 @@ included in the project:
5. Locally merge (or rebase) the upstream development branch into your topic branch: 5. Locally merge (or rebase) the upstream development branch into your topic branch:
```bash ```bash
git pull [--rebase] upstream main git pull [--rebase] upstream v4-dev
``` ```
6. Push your topic branch up to your fork: 6. Push your topic branch up to your fork:
@ -193,7 +192,7 @@ included in the project:
``` ```
7. [Open a Pull Request](https://help.github.com/articles/about-pull-requests/) 7. [Open a Pull Request](https://help.github.com/articles/about-pull-requests/)
with a clear title and description against the `main` branch. with a clear title and description against the `v4-dev` branch.
**IMPORTANT**: By submitting a patch, you agree to allow the project owners to **IMPORTANT**: By submitting a patch, you agree to allow the project owners to
license your work under the terms of the [MIT License](../LICENSE) (if it license your work under the terms of the [MIT License](../LICENSE) (if it
@ -225,6 +224,7 @@ includes code changes) and under the terms of the
- 2 spaces (no tabs) - 2 spaces (no tabs)
- strict mode - strict mode
- "Attractive" - "Attractive"
- Don't use [jQuery event alias convenience methods](https://github.com/jquery/jquery/blob/master/src/event/alias.js) (such as `$().focus()`). Instead, use [`$().trigger(eventType, ...)`](https://api.jquery.com/trigger/) or [`$().on(eventType, ...)`](https://api.jquery.com/on/), depending on whether you're firing an event or listening for an event. (For example, `$().trigger('focus')` or `$().on('focus', function (event) { /* handle focus event */ })`) We do this to be compatible with custom builds of jQuery where the event aliases module has been excluded.
### Checking coding style ### Checking coding style

3
.github/FUNDING.yml vendored
View file

@ -1,3 +0,0 @@
# These are supported funding model platforms
open_collective: bootstrap

View file

@ -11,10 +11,10 @@ Before opening:
- [Search for duplicate or closed issues](https://github.com/twbs/bootstrap/issues?utf8=%E2%9C%93&q=is%3Aissue) - [Search for duplicate or closed issues](https://github.com/twbs/bootstrap/issues?utf8=%E2%9C%93&q=is%3Aissue)
- [Validate](https://html5.validator.nu/) any HTML to avoid common problems - [Validate](https://html5.validator.nu/) any HTML to avoid common problems
- Read the [contributing guidelines](https://github.com/twbs/bootstrap/blob/main/.github/CONTRIBUTING.md) - Read the [contributing guidelines](https://github.com/twbs/bootstrap/blob/v4-dev/.github/CONTRIBUTING.md)
Bug reports must include: Bug reports must include:
- Operating system and version (Windows, macOS, Android, iOS) - Operating system and version (Windows, macOS, Android, iOS)
- Browser and version (Chrome, Firefox, Safari, Microsoft Edge, Opera, Android Browser) - Browser and version (Chrome, Firefox, Safari, Internet Explorer, Microsoft Edge, Opera, Android Browser)
- A [reduced test case](https://css-tricks.com/reduced-test-cases/) or suggested fix using [CodePen](https://codepen.io/) or [JS Bin](https://jsbin.com/) - A [reduced test case](https://css-tricks.com/reduced-test-cases/) or suggested fix using [CodePen](https://codepen.io/) or [JS Bin](https://jsbin.com/)

View file

@ -1,4 +0,0 @@
contact_links:
- name: Ask a question
url: https://github.com/twbs/bootstrap/discussions/new
about: Ask and discuss questions with other Bootstrap community members

View file

@ -10,7 +10,7 @@ assignees: ''
Before opening: Before opening:
- [Search for duplicate or closed issues](https://github.com/twbs/bootstrap/issues?utf8=%E2%9C%93&q=is%3Aissue) - [Search for duplicate or closed issues](https://github.com/twbs/bootstrap/issues?utf8=%E2%9C%93&q=is%3Aissue)
- Read the [contributing guidelines](https://github.com/twbs/bootstrap/blob/main/.github/CONTRIBUTING.md) - Read the [contributing guidelines](https://github.com/twbs/bootstrap/blob/v4-dev/.github/CONTRIBUTING.md)
Feature requests must include: Feature requests must include:

2
.github/SUPPORT.md vendored
View file

@ -8,4 +8,4 @@ For general troubleshooting or help getting started:
- Join [the official Slack room](https://bootstrap-slack.herokuapp.com/). - Join [the official Slack room](https://bootstrap-slack.herokuapp.com/).
- Chat with fellow Bootstrappers in IRC. On the `irc.freenode.net` server, in the `##bootstrap` channel. - Chat with fellow Bootstrappers in IRC. On the `irc.freenode.net` server, in the `##bootstrap` channel.
- Ask and explore Stack Overflow with the [`bootstrap-5`](https://stackoverflow.com/questions/tagged/bootstrap-5) tag. - Ask and explore Stack Overflow with the [`bootstrap-4`](https://stackoverflow.com/questions/tagged/bootstrap-4) tag.

View file

@ -1,24 +0,0 @@
version: 2
updates:
- package-ecosystem: npm
directory: "/"
schedule:
interval: weekly
day: tuesday
time: "12:00"
timezone: Europe/Athens
open-pull-requests-limit: 10
reviewers:
- XhmikosR
labels:
- dependencies
- v5
versioning-strategy: increase
rebase-strategy: disabled
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: weekly
day: tuesday
time: "12:00"
timezone: Europe/Athens

View file

@ -1,54 +0,0 @@
name-template: 'v$NEXT_MAJOR_VERSION'
tag-template: 'v$NEXT_MAJOR_VERSION'
prerelease: true
exclude-labels:
- 'skip-changelog'
categories:
- title: '❗ Breaking Changes'
labels:
- 'breaking-change'
- title: '🚀 Features'
labels:
- 'new-feature'
- 'feature'
- 'enhancement'
- title: '🐛 Bug fixes'
labels:
- 'fix'
- 'bugfix'
- 'bug'
- title: '⚡ Performance Improvements'
labels:
- 'performance'
- title: '🎨 CSS'
labels:
- 'css'
- title: '☕️ JavaScript'
labels:
- 'js'
- title: '📖 Docs'
labels:
- 'docs'
- title: '🌎 Accessibility'
labels:
- 'accessibility'
- title: '🔧 Utility API'
labels:
- 'utility API'
- 'utilities'
- title: '🏭 Tests'
labels:
- 'tests'
- title: '🧰 Misc'
labels:
- 'build'
- 'meta'
- 'chore'
- 'CI'
- title: '📦 Dependencies'
labels:
- 'dependencies'
change-template: '- #$NUMBER: $TITLE'
template: |
## Changes
$CHANGES

View file

@ -1,24 +1,20 @@
name: BrowserStack name: BrowserStack
on: [push]
on:
push:
env: env:
FORCE_COLOR: 2 CI: true
NODE: 14 NODE: 12.x
jobs: jobs:
browserstack: browserstack:
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: github.repository == 'twbs/bootstrap' && (!contains(github.event.commits[0].message, '[ci skip]') && !contains(github.event.commits[0].message, '[skip ci]')) if: github.repository == 'twbs/bootstrap'
timeout-minutes: 30
steps: steps:
- name: Clone repository - name: Clone repository
uses: actions/checkout@v2 uses: actions/checkout@v2
- name: Set up Node.js - name: Set Node.js version
uses: actions/setup-node@v2 uses: actions/setup-node@v1
with: with:
node-version: "${{ env.NODE }}" node-version: "${{ env.NODE }}"
@ -28,8 +24,8 @@ jobs:
path: ~/.npm path: ~/.npm
key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: | restore-keys: |
${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} ${{ runner.OS }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
${{ runner.os }}-node-v${{ env.NODE }}- ${{ runner.OS }}-node-v${{ env.NODE }}-
- name: Install npm dependencies - name: Install npm dependencies
run: npm ci run: npm ci

View file

@ -1,14 +1,8 @@
name: Bundlewatch name: Bundlewatch
on: [push, pull_request]
on:
push:
branches-ignore:
- "dependabot/**"
pull_request:
env: env:
FORCE_COLOR: 2 CI: true
NODE: 14 NODE: 12.x
jobs: jobs:
bundlewatch: bundlewatch:
@ -18,8 +12,8 @@ jobs:
- name: Clone repository - name: Clone repository
uses: actions/checkout@v2 uses: actions/checkout@v2
- name: Set up Node.js - name: Set Node.js version
uses: actions/setup-node@v2 uses: actions/setup-node@v1
with: with:
node-version: "${{ env.NODE }}" node-version: "${{ env.NODE }}"
@ -29,8 +23,8 @@ jobs:
path: ~/.npm path: ~/.npm
key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: | restore-keys: |
${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} ${{ runner.OS }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
${{ runner.os }}-node-v${{ env.NODE }}- ${{ runner.OS }}-node-v${{ env.NODE }}-
- name: Install npm dependencies - name: Install npm dependencies
run: npm ci run: npm ci
@ -42,4 +36,4 @@ jobs:
run: npm run bundlewatch run: npm run bundlewatch
env: env:
BUNDLEWATCH_GITHUB_TOKEN: "${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }}" BUNDLEWATCH_GITHUB_TOKEN: "${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }}"
CI_BRANCH_BASE: main CI_BRANCH_BASE: v4-dev

View file

@ -1,33 +1,22 @@
name: "CodeQL" name: "Code Scanning - Action"
on: on:
push: push:
branches:
- main
- v4-dev
- "!dependabot/**"
pull_request:
# The branches below must be a subset of the branches above
branches:
- main
- v4-dev
schedule: schedule:
- cron: "0 2 * * 5" - cron: "0 0 * * 0"
jobs: jobs:
analyze: CodeQL-Build:
name: Analyze
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout repository - name: Checkout repository
uses: actions/checkout@v2 uses: actions/checkout@v2
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL - name: Initialize CodeQL
uses: github/codeql-action/init@v1 uses: github/codeql-action/init@v1
with: with:
languages: "javascript" languages: javascript
- name: Autobuild - name: Autobuild
uses: github/codeql-action/autobuild@v1 uses: github/codeql-action/autobuild@v1

View file

@ -1,14 +1,8 @@
name: CSS name: CSS
on: [push, pull_request]
on:
push:
branches-ignore:
- "dependabot/**"
pull_request:
env: env:
FORCE_COLOR: 2 CI: true
NODE: 14 NODE: 12.x
jobs: jobs:
css: css:
@ -18,8 +12,8 @@ jobs:
- name: Clone repository - name: Clone repository
uses: actions/checkout@v2 uses: actions/checkout@v2
- name: Set up Node.js - name: Set Node.js version
uses: actions/setup-node@v2 uses: actions/setup-node@v1
with: with:
node-version: "${{ env.NODE }}" node-version: "${{ env.NODE }}"
@ -29,8 +23,8 @@ jobs:
path: ~/.npm path: ~/.npm
key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: | restore-keys: |
${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} ${{ runner.OS }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
${{ runner.os }}-node-v${{ env.NODE }}- ${{ runner.OS }}-node-v${{ env.NODE }}-
- name: Install npm dependencies - name: Install npm dependencies
run: npm ci run: npm ci

24
.github/workflows/dart-sass.yml vendored Normal file
View file

@ -0,0 +1,24 @@
name: CSS (Dart Sass)
on: [push, pull_request]
env:
CI: true
NODE: 12.x
jobs:
css:
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v2
- name: Set Node.js version
uses: actions/setup-node@v1
with:
node-version: "${{ env.NODE }}"
- name: Build CSS with Dart Sass
run: |
npx --package sass@latest sass --version
npx --package sass@latest sass --style expanded --source-map --embed-sources --no-error-css scss/:dist-sass/css/
ls -Al dist-sass/css

View file

@ -1,14 +1,9 @@
name: Docs name: Docs
on: [push, pull_request]
on:
push:
branches-ignore:
- "dependabot/**"
pull_request:
env: env:
FORCE_COLOR: 2 CI: true
NODE: 14 NODE: 12.x
RUBY: 2.7.x
jobs: jobs:
docs: docs:
@ -18,12 +13,30 @@ jobs:
- name: Clone repository - name: Clone repository
uses: actions/checkout@v2 uses: actions/checkout@v2
- name: Set up Node.js - name: Set Node.js version
uses: actions/setup-node@v2 uses: actions/setup-node@v1
with: with:
node-version: "${{ env.NODE }}" node-version: "${{ env.NODE }}"
- run: java -version - name: Set up Ruby
uses: actions/setup-ruby@v1
with:
ruby-version: ${{ env.RUBY }}
- name: Set up Ruby env
run: |
echo "gem: --no-document" > ~/.gemrc # Disable gem docs
bundle config set clean 'true'
bundle config set deployment 'true'
- name: Set up Ruby cache
uses: actions/cache@v2
with:
path: vendor/bundle
key: ${{ runner.os }}-ruby-v${{ env.RUBY }}-${{ hashFiles('Gemfile') }}-${{ hashFiles('Gemfile.lock') }}
restore-keys: |
${{ runner.os }}-ruby-v${{ env.RUBY }}-${{ hashFiles('Gemfile') }}-${{ hashFiles('Gemfile.lock') }}
${{ runner.os }}-ruby-v${{ env.RUBY }}-
- name: Set up npm cache - name: Set up npm cache
uses: actions/cache@v2 uses: actions/cache@v2
@ -31,11 +44,22 @@ jobs:
path: ~/.npm path: ~/.npm
key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: | restore-keys: |
${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} ${{ runner.OS }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
${{ runner.os }}-node-v${{ env.NODE }}- ${{ runner.OS }}-node-v${{ env.NODE }}-
- run: ruby --version
- run: gem --version
- run: bundle --version
- run: java -version
- name: Install npm dependencies - name: Install npm dependencies
run: npm ci run: npm ci
- name: Install bundler dependencies
run: bundle install --deployment --jobs=4 --retry=3 --clean
- name: Copy CSS and JS
run: npm run css-copy && npm run js-copy
- name: Test docs - name: Test docs
run: npm run docs run: npm run docs

View file

@ -1,13 +1,7 @@
name: JS Tests name: JS Tests
on: [push, pull_request]
on:
push:
branches-ignore:
- "dependabot/**"
pull_request:
env: env:
FORCE_COLOR: 2 CI: true
jobs: jobs:
run: run:
@ -17,14 +11,14 @@ jobs:
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
node: [10, 12, 14] node: [10, 12]
steps: steps:
- name: Clone repository - name: Clone repository
uses: actions/checkout@v2 uses: actions/checkout@v2
- name: Set up Node.js - name: Set Node.js version
uses: actions/setup-node@v2 uses: actions/setup-node@v1
with: with:
node-version: ${{ matrix.node }} node-version: ${{ matrix.node }}
@ -34,8 +28,8 @@ jobs:
path: ~/.npm path: ~/.npm
key: ${{ runner.os }}-node-v${{ matrix.node }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}} key: ${{ runner.os }}-node-v${{ matrix.node }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}}
restore-keys: | restore-keys: |
${{ runner.os }}-node-v${{ matrix.node }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} ${{ runner.OS }}-node-v${{ matrix.node }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
${{ runner.os }}-node-v${{ matrix.node }}- ${{ runner.OS }}-node-v${{ matrix.node }}-
- name: Install npm dependencies - name: Install npm dependencies
run: npm ci run: npm ci
@ -48,7 +42,7 @@ jobs:
- name: Run Coveralls - name: Run Coveralls
uses: coverallsapp/github-action@master uses: coverallsapp/github-action@master
if: matrix.node == 14 if: matrix.node == 12
with: with:
github-token: "${{ secrets.GITHUB_TOKEN }}" github-token: "${{ secrets.GITHUB_TOKEN }}"
path-to-lcov: "./js/coverage/lcov.info" path-to-lcov: "./js/coverage/lcov.info"

View file

@ -1,14 +1,8 @@
name: Lint name: Lint
on: [push, pull_request]
on:
push:
branches-ignore:
- "dependabot/**"
pull_request:
env: env:
FORCE_COLOR: 2 CI: true
NODE: 14 NODE: 12.x
jobs: jobs:
lint: lint:
@ -18,8 +12,8 @@ jobs:
- name: Clone repository - name: Clone repository
uses: actions/checkout@v2 uses: actions/checkout@v2
- name: Set up Node.js - name: Set Node.js version
uses: actions/setup-node@v2 uses: actions/setup-node@v1
with: with:
node-version: "${{ env.NODE }}" node-version: "${{ env.NODE }}"
@ -29,8 +23,8 @@ jobs:
path: ~/.npm path: ~/.npm
key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} key: ${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: | restore-keys: |
${{ runner.os }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }} ${{ runner.OS }}-node-v${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
${{ runner.os }}-node-v${{ env.NODE }}- ${{ runner.OS }}-node-v${{ env.NODE }}-
- name: Install npm dependencies - name: Install npm dependencies
run: npm ci run: npm ci

View file

@ -1,30 +0,0 @@
name: CSS (node-sass)
on:
push:
branches-ignore:
- "dependabot/**"
pull_request:
env:
FORCE_COLOR: 2
NODE: 14
jobs:
css:
runs-on: ubuntu-latest
steps:
- name: Clone repository
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "${{ env.NODE }}"
- name: Build CSS with node-sass
run: |
npx --package node-sass@latest node-sass --version
npx --package node-sass@latest node-sass --output-style expanded --source-map true --source-map-contents true --precision 6 scss/ -o dist-sass/css/
ls -Al dist-sass/css

View file

@ -1,14 +0,0 @@
name: Release notes
on:
push:
branches:
- main
jobs:
update_release_draft:
runs-on: ubuntu-latest
steps:
- uses: release-drafter/release-drafter@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

13
.gitignore vendored
View file

@ -1,8 +1,16 @@
# Ignore docs files # Ignore docs files
/_gh_pages/ /_gh_pages/
# Hugo resources folder /site/.jekyll-cache
/site/.jekyll-metadata
/site/docs/**/dist/
# Hugo folders
/resources/ /resources/
# Ignore ruby/bundler files
/.bundle/
/vendor/
/.ruby-version
# Numerous always-ignore extensions # Numerous always-ignore extensions
*.diff *.diff
*.err *.err
@ -28,9 +36,6 @@
*.sublime-workspace *.sublime-workspace
nbproject nbproject
Thumbs.db Thumbs.db
/.vscode/
# Local Netlify folder
.netlify
# Komodo # Komodo
.komodotools .komodotools

View file

@ -2,4 +2,3 @@
**/dist/ **/dist/
**/vendor/ **/vendor/
/_gh_pages/ /_gh_pages/
/js/coverage/

View file

@ -3,16 +3,7 @@
"stylelint-config-twbs-bootstrap/scss" "stylelint-config-twbs-bootstrap/scss"
], ],
"rules": { "rules": {
"declaration-property-value-disallowed-list": { "property-blacklist": [
"border": "none",
"outline": "none"
},
"function-disallowed-list": [
"calc",
"lighten",
"darken"
],
"property-disallowed-list": [
"border-radius", "border-radius",
"border-top-left-radius", "border-top-left-radius",
"border-top-right-radius", "border-top-right-radius",
@ -20,12 +11,6 @@
"border-bottom-left-radius", "border-bottom-left-radius",
"transition" "transition"
], ],
"scss/dollar-variable-default": [ "function-blacklist": ["calc"]
true,
{
"ignore": "local"
}
],
"scss/selector-no-union-class-name": true
} }
} }

View file

@ -8,19 +8,19 @@ In the interest of fostering an open and welcoming environment, we as contributo
Examples of behavior that contributes to creating a positive environment include: Examples of behavior that contributes to creating a positive environment include:
- Using welcoming and inclusive language * Using welcoming and inclusive language
- Being respectful of differing viewpoints and experiences * Being respectful of differing viewpoints and experiences
- Gracefully accepting constructive criticism * Gracefully accepting constructive criticism
- Focusing on what is best for the community * Focusing on what is best for the community
- Showing empathy towards other community members * Showing empathy towards other community members
Examples of unacceptable behavior by participants include: Examples of unacceptable behavior by participants include:
- The use of sexualized language or imagery and unwelcome sexual attention or advances * The use of sexualized language or imagery and unwelcome sexual attention or advances
- Trolling, insulting/derogatory comments, and personal or political attacks * Trolling, insulting/derogatory comments, and personal or political attacks
- Public or private harassment * Public or private harassment
- Publishing others' private information, such as a physical or electronic address, without explicit permission * Publishing others' private information, such as a physical or electronic address, without explicit permission
- Other conduct which could reasonably be considered inappropriate in a professional setting * Other conduct which could reasonably be considered inappropriate in a professional setting
## Our Responsibilities ## Our Responsibilities
@ -40,4 +40,7 @@ Project maintainers who do not follow or enforce the Code of Conduct in good fai
## Attribution ## Attribution
This Code of Conduct is adapted from the [Contributor Covenant](https://www.contributor-covenant.org/), version 1.4, available at <https://www.contributor-covenant.org/version/1/4/code-of-conduct/> This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [https://www.contributor-covenant.org/version/1/4/code-of-conduct.html][version]
[homepage]: https://www.contributor-covenant.org/
[version]: https://www.contributor-covenant.org/version/1/4/code-of-conduct.html

9
Gemfile Normal file
View file

@ -0,0 +1,9 @@
source 'https://rubygems.org'
group :development, :test do
gem 'jekyll', '~> 4.1.1'
gem 'jekyll-redirect-from', '~> 0.16.0'
gem 'jekyll-sitemap', '~> 1.4.0'
gem 'jekyll-toc', '~> 0.14.0'
gem 'wdm', '~> 0.1.1', :install_if => Gem.win_platform?
end

89
Gemfile.lock Normal file
View file

@ -0,0 +1,89 @@
GEM
remote: https://rubygems.org/
specs:
addressable (2.7.0)
public_suffix (>= 2.0.2, < 5.0)
colorator (1.1.0)
concurrent-ruby (1.1.7)
em-websocket (0.5.1)
eventmachine (>= 0.12.9)
http_parser.rb (~> 0.6.0)
eventmachine (1.2.7)
eventmachine (1.2.7-x64-mingw32)
ffi (1.13.1)
ffi (1.13.1-x64-mingw32)
forwardable-extended (2.6.0)
http_parser.rb (0.6.0)
i18n (1.8.5)
concurrent-ruby (~> 1.0)
jekyll (4.1.1)
addressable (~> 2.4)
colorator (~> 1.0)
em-websocket (~> 0.5)
i18n (~> 1.0)
jekyll-sass-converter (~> 2.0)
jekyll-watch (~> 2.0)
kramdown (~> 2.1)
kramdown-parser-gfm (~> 1.0)
liquid (~> 4.0)
mercenary (~> 0.4.0)
pathutil (~> 0.9)
rouge (~> 3.0)
safe_yaml (~> 1.0)
terminal-table (~> 1.8)
jekyll-redirect-from (0.16.0)
jekyll (>= 3.3, < 5.0)
jekyll-sass-converter (2.1.0)
sassc (> 2.0.1, < 3.0)
jekyll-sitemap (1.4.0)
jekyll (>= 3.7, < 5.0)
jekyll-toc (0.14.0)
jekyll (>= 3.8)
nokogiri (~> 1.10)
jekyll-watch (2.2.1)
listen (~> 3.0)
kramdown (2.3.0)
rexml
kramdown-parser-gfm (1.1.0)
kramdown (~> 2.0)
liquid (4.0.3)
listen (3.2.1)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
mercenary (0.4.0)
mini_portile2 (2.4.0)
nokogiri (1.10.10)
mini_portile2 (~> 2.4.0)
nokogiri (1.10.10-x64-mingw32)
mini_portile2 (~> 2.4.0)
pathutil (0.16.2)
forwardable-extended (~> 2.6)
public_suffix (4.0.6)
rb-fsevent (0.10.4)
rb-inotify (0.10.1)
ffi (~> 1.0)
rexml (3.2.4)
rouge (3.23.0)
safe_yaml (1.0.5)
sassc (2.4.0)
ffi (~> 1.9)
sassc (2.4.0-x64-mingw32)
ffi (~> 1.9)
terminal-table (1.8.0)
unicode-display_width (~> 1.1, >= 1.1.1)
unicode-display_width (1.7.0)
wdm (0.1.1)
PLATFORMS
ruby
x64-mingw32
DEPENDENCIES
jekyll (~> 4.1.1)
jekyll-redirect-from (~> 0.16.0)
jekyll-sitemap (~> 1.4.0)
jekyll-toc (~> 0.14.0)
wdm (~> 0.1.1)
BUNDLED WITH
2.1.4

View file

@ -1,7 +1,7 @@
The MIT License (MIT) The MIT License (MIT)
Copyright (c) 2011-2021 Twitter, Inc. Copyright (c) 2011-2020 Twitter, Inc.
Copyright (c) 2011-2021 The Bootstrap Authors Copyright (c) 2011-2020 The Bootstrap Authors
Permission is hereby granted, free of charge, to any person obtaining a copy Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal of this software and associated documentation files (the "Software"), to deal

146
README.md
View file

@ -1,6 +1,6 @@
<p align="center"> <p align="center">
<a href="https://getbootstrap.com/"> <a href="https://getbootstrap.com/">
<img src="https://getbootstrap.com/docs/5.0/assets/brand/bootstrap-logo-shadow.png" alt="Bootstrap logo" width="200" height="165"> <img src="https://getbootstrap.com/docs/4.5/assets/brand/bootstrap-solid.svg" alt="Bootstrap logo" width="72" height="72">
</a> </a>
</p> </p>
@ -9,7 +9,7 @@
<p align="center"> <p align="center">
Sleek, intuitive, and powerful front-end framework for faster and easier web development. Sleek, intuitive, and powerful front-end framework for faster and easier web development.
<br> <br>
<a href="https://getbootstrap.com/docs/5.0/"><strong>Explore Bootstrap docs »</strong></a> <a href="https://getbootstrap.com/docs/4.5/"><strong>Explore Bootstrap docs »</strong></a>
<br> <br>
<br> <br>
<a href="https://github.com/twbs/bootstrap/issues/new?template=bug_report.md">Report bug</a> <a href="https://github.com/twbs/bootstrap/issues/new?template=bug_report.md">Report bug</a>
@ -22,11 +22,6 @@
</p> </p>
## Bootstrap 4
Our default branch is for development of our upcoming Bootstrap 5 release. Head to the [`v4-dev` branch](https://github.com/twbs/bootstrap/tree/v4-dev) to view the readme, documentation, and source code for Bootstrap 4.
## Table of contents ## Table of contents
- [Quick start](#quick-start) - [Quick start](#quick-start)
@ -46,20 +41,20 @@ Our default branch is for development of our upcoming Bootstrap 5 release. Head
Several quick start options are available: Several quick start options are available:
- [Download the latest release](https://github.com/twbs/bootstrap/archive/v5.0.0-beta1.zip) - [Download the latest release.](https://github.com/twbs/bootstrap/archive/v4.5.2.zip)
- Clone the repo: `git clone https://github.com/twbs/bootstrap.git` - Clone the repo: `git clone https://github.com/twbs/bootstrap.git`
- Install with [npm](https://www.npmjs.com/): `npm install bootstrap@next` - Install with [npm](https://www.npmjs.com/): `npm install bootstrap`
- Install with [yarn](https://yarnpkg.com/): `yarn add bootstrap@next` - Install with [yarn](https://yarnpkg.com/): `yarn add bootstrap@4.5.2`
- Install with [Composer](https://getcomposer.org/): `composer require twbs/bootstrap:5.0.0-beta1` - Install with [Composer](https://getcomposer.org/): `composer require twbs/bootstrap:4.5.2`
- Install with [NuGet](https://www.nuget.org/): CSS: `Install-Package bootstrap` Sass: `Install-Package bootstrap.sass` - Install with [NuGet](https://www.nuget.org/): CSS: `Install-Package bootstrap` Sass: `Install-Package bootstrap.sass`
Read the [Getting started page](https://getbootstrap.com/docs/5.0/getting-started/introduction/) for information on the framework contents, templates and examples, and more. Read the [Getting started page](https://getbootstrap.com/docs/4.5/getting-started/introduction/) for information on the framework contents, templates and examples, and more.
## Status ## Status
[![Slack](https://bootstrap-slack.herokuapp.com/badge.svg)](https://bootstrap-slack.herokuapp.com/) [![Slack](https://bootstrap-slack.herokuapp.com/badge.svg)](https://bootstrap-slack.herokuapp.com/)
[![Build Status](https://github.com/twbs/bootstrap/workflows/JS%20Tests/badge.svg?branch=main)](https://github.com/twbs/bootstrap/actions?query=workflow%3AJS+Tests+branch%3Amain) [![Build Status](https://github.com/twbs/bootstrap/workflows/JS%20Tests/badge.svg?branch=v4-dev)](https://github.com/twbs/bootstrap/actions?query=workflow%3AJS+Tests+branch%3Av4-dev)
[![npm version](https://img.shields.io/npm/v/bootstrap)](https://www.npmjs.com/package/bootstrap) [![npm version](https://img.shields.io/npm/v/bootstrap)](https://www.npmjs.com/package/bootstrap)
[![Gem version](https://img.shields.io/gem/v/bootstrap)](https://rubygems.org/gems/bootstrap) [![Gem version](https://img.shields.io/gem/v/bootstrap)](https://rubygems.org/gems/bootstrap)
[![Meteor Atmosphere](https://img.shields.io/badge/meteor-twbs%3Abootstrap-blue)](https://atmospherejs.com/twbs/bootstrap) [![Meteor Atmosphere](https://img.shields.io/badge/meteor-twbs%3Abootstrap-blue)](https://atmospherejs.com/twbs/bootstrap)
@ -67,11 +62,9 @@ Read the [Getting started page](https://getbootstrap.com/docs/5.0/getting-starte
[![NuGet](https://img.shields.io/nuget/vpre/bootstrap)](https://www.nuget.org/packages/bootstrap/absoluteLatest) [![NuGet](https://img.shields.io/nuget/vpre/bootstrap)](https://www.nuget.org/packages/bootstrap/absoluteLatest)
[![peerDependencies Status](https://img.shields.io/david/peer/twbs/bootstrap)](https://david-dm.org/twbs/bootstrap?type=peer) [![peerDependencies Status](https://img.shields.io/david/peer/twbs/bootstrap)](https://david-dm.org/twbs/bootstrap?type=peer)
[![devDependency Status](https://img.shields.io/david/dev/twbs/bootstrap)](https://david-dm.org/twbs/bootstrap?type=dev) [![devDependency Status](https://img.shields.io/david/dev/twbs/bootstrap)](https://david-dm.org/twbs/bootstrap?type=dev)
[![Coverage Status](https://img.shields.io/coveralls/github/twbs/bootstrap/main)](https://coveralls.io/github/twbs/bootstrap?branch=main) [![Coverage Status](https://img.shields.io/coveralls/github/twbs/bootstrap/v4-dev)](https://coveralls.io/github/twbs/bootstrap?branch=v4-dev)
[![CSS gzip size](https://img.badgesize.io/twbs/bootstrap/main/dist/css/bootstrap.min.css?compression=gzip&label=CSS%20gzip%20size)](https://github.com/twbs/bootstrap/blob/main/dist/css/bootstrap.min.css) [![CSS gzip size](https://img.badgesize.io/twbs/bootstrap/v4-dev/dist/css/bootstrap.min.css?compression=gzip&label=CSS%20gzip%20size)](https://github.com/twbs/bootstrap/blob/v4-dev/dist/css/bootstrap.min.css)
[![CSS Brotli size](https://img.badgesize.io/twbs/bootstrap/main/dist/css/bootstrap.min.css?compression=brotli&label=CSS%20Brotli%20size)](https://github.com/twbs/bootstrap/blob/main/dist/css/bootstrap.min.css) [![JS gzip size](https://img.badgesize.io/twbs/bootstrap/v4-dev/dist/js/bootstrap.min.js?compression=gzip&label=JS%20gzip%20size)](https://github.com/twbs/bootstrap/blob/v4-dev/dist/js/bootstrap.min.js)
[![JS gzip size](https://img.badgesize.io/twbs/bootstrap/main/dist/js/bootstrap.min.js?compression=gzip&label=JS%20gzip%20size)](https://github.com/twbs/bootstrap/blob/main/dist/js/bootstrap.min.js)
[![JS Brotli size](https://img.badgesize.io/twbs/bootstrap/main/dist/js/bootstrap.min.js?compression=brotli&label=JS%20Brotli%20size)](https://github.com/twbs/bootstrap/blob/main/dist/js/bootstrap.min.js)
[![BrowserStack Status](https://www.browserstack.com/automate/badge.svg?badge_key=SkxZcStBeExEdVJqQ2hWYnlWckpkNmNEY213SFp6WHFETWk2bGFuY3pCbz0tLXhqbHJsVlZhQnRBdEpod3NLSDMzaHc9PQ==--3d0b75245708616eb93113221beece33e680b229)](https://www.browserstack.com/automate/public-build/SkxZcStBeExEdVJqQ2hWYnlWckpkNmNEY213SFp6WHFETWk2bGFuY3pCbz0tLXhqbHJsVlZhQnRBdEpod3NLSDMzaHc9PQ==--3d0b75245708616eb93113221beece33e680b229) [![BrowserStack Status](https://www.browserstack.com/automate/badge.svg?badge_key=SkxZcStBeExEdVJqQ2hWYnlWckpkNmNEY213SFp6WHFETWk2bGFuY3pCbz0tLXhqbHJsVlZhQnRBdEpod3NLSDMzaHc9PQ==--3d0b75245708616eb93113221beece33e680b229)](https://www.browserstack.com/automate/public-build/SkxZcStBeExEdVJqQ2hWYnlWckpkNmNEY213SFp6WHFETWk2bGFuY3pCbz0tLXhqbHJsVlZhQnRBdEpod3NLSDMzaHc9PQ==--3d0b75245708616eb93113221beece33e680b229)
[![Backers on Open Collective](https://img.shields.io/opencollective/backers/bootstrap)](#backers) [![Backers on Open Collective](https://img.shields.io/opencollective/backers/bootstrap)](#backers)
[![Sponsors on Open Collective](https://img.shields.io/opencollective/sponsors/bootstrap)](#sponsors) [![Sponsors on Open Collective](https://img.shields.io/opencollective/sponsors/bootstrap)](#sponsors)
@ -83,76 +76,53 @@ Within the download you'll find the following directories and files, logically g
```text ```text
bootstrap/ bootstrap/
├── css/ └── dist/
│ ├── bootstrap-grid.css ├── css/
│ ├── bootstrap-grid.css.map │ ├── bootstrap-grid.css
│ ├── bootstrap-grid.min.css │ ├── bootstrap-grid.css.map
│ ├── bootstrap-grid.min.css.map │ ├── bootstrap-grid.min.css
│ ├── bootstrap-grid.rtl.css │ ├── bootstrap-grid.min.css.map
│ ├── bootstrap-grid.rtl.css.map │ ├── bootstrap-reboot.css
│ ├── bootstrap-grid.rtl.min.css │ ├── bootstrap-reboot.css.map
│ ├── bootstrap-grid.rtl.min.css.map │ ├── bootstrap-reboot.min.css
│ ├── bootstrap-reboot.css │ ├── bootstrap-reboot.min.css.map
│ ├── bootstrap-reboot.css.map │ ├── bootstrap.css
│ ├── bootstrap-reboot.min.css │ ├── bootstrap.css.map
│ ├── bootstrap-reboot.min.css.map │ ├── bootstrap.min.css
│ ├── bootstrap-reboot.rtl.css │ └── bootstrap.min.css.map
│ ├── bootstrap-reboot.rtl.css.map └── js/
│ ├── bootstrap-reboot.rtl.min.css ├── bootstrap.bundle.js
│ ├── bootstrap-reboot.rtl.min.css.map ├── bootstrap.bundle.js.map
│ ├── bootstrap-utilities.css ├── bootstrap.bundle.min.js
│ ├── bootstrap-utilities.css.map ├── bootstrap.bundle.min.js.map
│ ├── bootstrap-utilities.min.css ├── bootstrap.js
│ ├── bootstrap-utilities.min.css.map ├── bootstrap.js.map
│ ├── bootstrap-utilities.rtl.css ├── bootstrap.min.js
│ ├── bootstrap-utilities.rtl.css.map └── bootstrap.min.js.map
│ ├── bootstrap-utilities.rtl.min.css
│ ├── bootstrap-utilities.rtl.min.css.map
│ ├── bootstrap.css
│ ├── bootstrap.css.map
│ ├── bootstrap.min.css
│ ├── bootstrap.min.css.map
│ ├── bootstrap.rtl.css
│ ├── bootstrap.rtl.css.map
│ ├── bootstrap.rtl.min.css
│ └── bootstrap.rtl.min.css.map
└── js/
├── bootstrap.bundle.js
├── bootstrap.bundle.js.map
├── bootstrap.bundle.min.js
├── bootstrap.bundle.min.js.map
├── bootstrap.esm.js
├── bootstrap.esm.js.map
├── bootstrap.esm.min.js
├── bootstrap.esm.min.js.map
├── bootstrap.js
├── bootstrap.js.map
├── bootstrap.min.js
└── bootstrap.min.js.map
``` ```
We provide compiled CSS and JS (`bootstrap.*`), as well as compiled and minified CSS and JS (`bootstrap.min.*`). [source maps](https://developers.google.com/web/tools/chrome-devtools/javascript/source-maps) (`bootstrap.*.map`) are available for use with certain browsers' developer tools. Bundled JS files (`bootstrap.bundle.js` and minified `bootstrap.bundle.min.js`) include [Popper](https://popper.js.org/). We provide compiled CSS and JS (`bootstrap.*`), as well as compiled and minified CSS and JS (`bootstrap.min.*`). [source maps](https://developers.google.com/web/tools/chrome-devtools/javascript/source-maps) (`bootstrap.*.map`) are available for use with certain browsers' developer tools. Bundled JS files (`bootstrap.bundle.js` and minified `bootstrap.bundle.min.js`) include [Popper](https://popper.js.org/), but not [jQuery](https://jquery.com/).
## Bugs and feature requests ## Bugs and feature requests
Have a bug or a feature request? Please first read the [issue guidelines](https://github.com/twbs/bootstrap/blob/main/.github/CONTRIBUTING.md#using-the-issue-tracker) and search for existing and closed issues. If your problem or idea is not addressed yet, [please open a new issue](https://github.com/twbs/bootstrap/issues/new). Have a bug or a feature request? Please first read the [issue guidelines](https://github.com/twbs/bootstrap/blob/v4-dev/.github/CONTRIBUTING.md#using-the-issue-tracker) and search for existing and closed issues. If your problem or idea is not addressed yet, [please open a new issue](https://github.com/twbs/bootstrap/issues/new).
## Documentation ## Documentation
Bootstrap's documentation, included in this repo in the root directory, is built with [Hugo](https://gohugo.io/) and publicly hosted on GitHub Pages at <https://getbootstrap.com/>. The docs may also be run locally. Bootstrap's documentation, included in this repo in the root directory, is built with [Jekyll](https://jekyllrb.com/) and publicly hosted on GitHub Pages at <https://getbootstrap.com/>. The docs may also be run locally.
Documentation search is powered by [Algolia's DocSearch](https://community.algolia.com/docsearch/). Working on our search? Be sure to set `debug: true` in `site/assets/js/search.js`. Documentation search is powered by [Algolia's DocSearch](https://community.algolia.com/docsearch/). Working on our search? Be sure to set `debug: true` in `site/docs/4.5/assets/js/src/search.js` file.
### Running documentation locally ### Running documentation locally
1. Run `npm install` to install the Node.js dependencies, including Hugo (the site builder). 1. Run through the [tooling setup](https://getbootstrap.com/docs/4.5/getting-started/build-tools/#tooling-setup) to install Jekyll (the site builder) and other Ruby dependencies with `bundle install`.
2. Run `npm run test` (or a specific npm script) to rebuild distributed CSS and JavaScript files, as well as our docs assets. 2. Run `npm install` to install Node.js dependencies.
3. From the root `/bootstrap` directory, run `npm run docs-serve` in the command line. 3. Run `npm start` to compile CSS and JavaScript files, generate our docs, and watch for changes.
4. Open `http://localhost:9001/` in your browser, and voilà. 4. Open `http://localhost:9001` in your browser, and voilà.
Learn more about using Hugo by reading its [documentation](https://gohugo.io/documentation/). Learn more about using Jekyll by reading its [documentation](https://jekyllrb.com/docs/).
### Documentation for previous releases ### Documentation for previous releases
@ -163,11 +133,11 @@ You can find all our previous releases docs on <https://getbootstrap.com/docs/ve
## Contributing ## Contributing
Please read through our [contributing guidelines](https://github.com/twbs/bootstrap/blob/main/.github/CONTRIBUTING.md). Included are directions for opening issues, coding standards, and notes on development. Please read through our [contributing guidelines](https://github.com/twbs/bootstrap/blob/v4-dev/.github/CONTRIBUTING.md). Included are directions for opening issues, coding standards, and notes on development.
Moreover, if your pull request contains JavaScript patches or features, you must include [relevant unit tests](https://github.com/twbs/bootstrap/tree/main/js/tests). All HTML and CSS should conform to the [Code Guide](https://github.com/mdo/code-guide), maintained by [Mark Otto](https://github.com/mdo). Moreover, if your pull request contains JavaScript patches or features, you must include [relevant unit tests](https://github.com/twbs/bootstrap/tree/v4-dev/js/tests). All HTML and CSS should conform to the [Code Guide](https://github.com/mdo/code-guide), maintained by [Mark Otto](https://github.com/mdo).
Editor preferences are available in the [editor config](https://github.com/twbs/bootstrap/blob/main/.editorconfig) for easy use in common text editors. Read more and download plugins at <https://editorconfig.org/>. Editor preferences are available in the [editor config](https://github.com/twbs/bootstrap/blob/v4-dev/.editorconfig) for easy use in common text editors. Read more and download plugins at <https://editorconfig.org/>.
## Community ## Community
@ -178,7 +148,7 @@ Get updates on Bootstrap's development and chat with the project maintainers and
- Read and subscribe to [The Official Bootstrap Blog](https://blog.getbootstrap.com/). - Read and subscribe to [The Official Bootstrap Blog](https://blog.getbootstrap.com/).
- Join [the official Slack room](https://bootstrap-slack.herokuapp.com/). - Join [the official Slack room](https://bootstrap-slack.herokuapp.com/).
- Chat with fellow Bootstrappers in IRC. On the `irc.freenode.net` server, in the `##bootstrap` channel. - Chat with fellow Bootstrappers in IRC. On the `irc.freenode.net` server, in the `##bootstrap` channel.
- Implementation help may be found at Stack Overflow (tagged [`bootstrap-5`](https://stackoverflow.com/questions/tagged/bootstrap-5)). - Implementation help may be found at Stack Overflow (tagged [`bootstrap-4`](https://stackoverflow.com/questions/tagged/bootstrap-4)).
- Developers should use the keyword `bootstrap` on packages which modify or add to the functionality of Bootstrap when distributing through [npm](https://www.npmjs.com/browse/keyword/bootstrap) or similar delivery mechanisms for maximum discoverability. - Developers should use the keyword `bootstrap` on packages which modify or add to the functionality of Bootstrap when distributing through [npm](https://www.npmjs.com/browse/keyword/bootstrap) or similar delivery mechanisms for maximum discoverability.
@ -215,16 +185,16 @@ Thanks to [BrowserStack](https://www.browserstack.com/) for providing the infras
Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/bootstrap#sponsor)] Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/bootstrap#sponsor)]
[![OC sponsor 0](https://opencollective.com/bootstrap/sponsor/0/avatar.svg)](https://opencollective.com/bootstrap/sponsor/0/website) [![](https://opencollective.com/bootstrap/sponsor/0/avatar.svg)](https://opencollective.com/bootstrap/sponsor/0/website)
[![OC sponsor 1](https://opencollective.com/bootstrap/sponsor/1/avatar.svg)](https://opencollective.com/bootstrap/sponsor/1/website) [![](https://opencollective.com/bootstrap/sponsor/1/avatar.svg)](https://opencollective.com/bootstrap/sponsor/1/website)
[![OC sponsor 2](https://opencollective.com/bootstrap/sponsor/2/avatar.svg)](https://opencollective.com/bootstrap/sponsor/2/website) [![](https://opencollective.com/bootstrap/sponsor/2/avatar.svg)](https://opencollective.com/bootstrap/sponsor/2/website)
[![OC sponsor 3](https://opencollective.com/bootstrap/sponsor/3/avatar.svg)](https://opencollective.com/bootstrap/sponsor/3/website) [![](https://opencollective.com/bootstrap/sponsor/3/avatar.svg)](https://opencollective.com/bootstrap/sponsor/3/website)
[![OC sponsor 4](https://opencollective.com/bootstrap/sponsor/4/avatar.svg)](https://opencollective.com/bootstrap/sponsor/4/website) [![](https://opencollective.com/bootstrap/sponsor/4/avatar.svg)](https://opencollective.com/bootstrap/sponsor/4/website)
[![OC sponsor 5](https://opencollective.com/bootstrap/sponsor/5/avatar.svg)](https://opencollective.com/bootstrap/sponsor/5/website) [![](https://opencollective.com/bootstrap/sponsor/5/avatar.svg)](https://opencollective.com/bootstrap/sponsor/5/website)
[![OC sponsor 6](https://opencollective.com/bootstrap/sponsor/6/avatar.svg)](https://opencollective.com/bootstrap/sponsor/6/website) [![](https://opencollective.com/bootstrap/sponsor/6/avatar.svg)](https://opencollective.com/bootstrap/sponsor/6/website)
[![OC sponsor 7](https://opencollective.com/bootstrap/sponsor/7/avatar.svg)](https://opencollective.com/bootstrap/sponsor/7/website) [![](https://opencollective.com/bootstrap/sponsor/7/avatar.svg)](https://opencollective.com/bootstrap/sponsor/7/website)
[![OC sponsor 8](https://opencollective.com/bootstrap/sponsor/8/avatar.svg)](https://opencollective.com/bootstrap/sponsor/8/website) [![](https://opencollective.com/bootstrap/sponsor/8/avatar.svg)](https://opencollective.com/bootstrap/sponsor/8/website)
[![OC sponsor 9](https://opencollective.com/bootstrap/sponsor/9/avatar.svg)](https://opencollective.com/bootstrap/sponsor/9/website) [![](https://opencollective.com/bootstrap/sponsor/9/avatar.svg)](https://opencollective.com/bootstrap/sponsor/9/website)
## Backers ## Backers
@ -236,4 +206,4 @@ Thank you to all our backers! 🙏 [[Become a backer](https://opencollective.com
## Copyright and license ## Copyright and license
Code and documentation copyright 20112021 the [Bootstrap Authors](https://github.com/twbs/bootstrap/graphs/contributors) and [Twitter, Inc.](https://twitter.com) Code released under the [MIT License](https://github.com/twbs/bootstrap/blob/main/LICENSE). Docs released under [Creative Commons](https://creativecommons.org/licenses/by/3.0/). Code and documentation copyright 2011-2020 the [Bootstrap Authors](https://github.com/twbs/bootstrap/graphs/contributors) and [Twitter, Inc.](https://twitter.com) Code released under the [MIT License](https://github.com/twbs/bootstrap/blob/main/LICENSE). Docs released under [Creative Commons](https://creativecommons.org/licenses/by/3.0/).

74
_config.yml Normal file
View file

@ -0,0 +1,74 @@
# Dependencies
markdown: kramdown
highlighter: rouge
kramdown:
auto_ids: true
# Permalinks
permalink: pretty
# Server
source: "site"
destination: ./_gh_pages
host: "localhost"
port: 9001
baseurl: ""
url: "https://getbootstrap.com"
encoding: UTF-8
exclude:
- docs/4.5/assets/scss/
plugins:
- jekyll-redirect-from
- jekyll-sitemap
- jekyll-toc
redirect_from:
json: false
# Social
title: Bootstrap
description: "The most popular HTML, CSS, and JS library in the world."
twitter: getbootstrap
authors: "Mark Otto, Jacob Thornton, and Bootstrap contributors"
social_image_path: /docs/4.5/assets/brand/bootstrap-social.png
social_logo_path: /docs/4.5/assets/brand/bootstrap-social-logo.png
# Custom variables
current_version: 4.5.2
current_ruby_version: 4.5.2
docs_version: 4.5
github_org: "https://github.com/twbs"
repo: "https://github.com/twbs/bootstrap"
slack: "https://bootstrap-slack.herokuapp.com"
opencollective: "https://opencollective.com/bootstrap"
blog: "https://blog.getbootstrap.com"
expo: "https://expo.getbootstrap.com"
themes: "https://themes.getbootstrap.com"
icons: "https://icons.getbootstrap.com"
download:
source: "https://github.com/twbs/bootstrap/archive/v4.5.2.zip"
dist: "https://github.com/twbs/bootstrap/releases/download/v4.5.2/bootstrap-4.5.2-dist.zip"
dist_examples: "https://github.com/twbs/bootstrap/releases/download/v4.5.2/bootstrap-4.5.2-examples.zip"
cdn:
# See https://www.srihash.org for info on how to generate the hashes
css: "https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css"
css_hash: "sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z"
js: "https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js"
js_hash: "sha384-B4gt1jrGC7Jh4AgTPSdUtOBvfO8shuf57BaghqFfPlYxofvL8/KUEfYiJOMMV+rV"
js_bundle: "https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.bundle.min.js"
js_bundle_hash: "sha384-LtrjvnR4Twt/qOuYxE721u19sVFLVSA4hf/rRt6PrZTmiPltdZcI7q7PXQBYTKyf"
jquery: "https://code.jquery.com/jquery-3.5.1.slim.min.js"
jquery_hash: "sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj"
popper: "https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js"
popper_hash: "sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN"
toc:
min_level: 2
max_level: 4
no_toc_section_class:
- "bd-callout"
- "bd-example"

View file

@ -2,8 +2,8 @@
/*! /*!
* Script to build our plugins to use them separately. * Script to build our plugins to use them separately.
* Copyright 2020-2021 The Bootstrap Authors * Copyright 2020 The Bootstrap Authors
* Copyright 2020-2021 Twitter, Inc. * Copyright 2020 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
@ -14,22 +14,17 @@ const rollup = require('rollup')
const { babel } = require('@rollup/plugin-babel') const { babel } = require('@rollup/plugin-babel')
const banner = require('./banner.js') const banner = require('./banner.js')
const rootPath = path.resolve(__dirname, '../js/dist/') const TEST = process.env.NODE_ENV === 'test'
const plugins = [ const plugins = [
babel({ babel({
// Only transpile our source code // Only transpile our source code
exclude: 'node_modules/**', exclude: 'node_modules/**',
// Include the helpers in each file, at most one copy of each // Inline the required helpers in each file
babelHelpers: 'bundled' babelHelpers: 'inline'
}) })
] ]
const bsPlugins = { const bsPlugins = {
Data: path.resolve(__dirname, '../js/src/dom/data.js'),
EventHandler: path.resolve(__dirname, '../js/src/dom/event-handler.js'),
Manipulator: path.resolve(__dirname, '../js/src/dom/manipulator.js'),
SelectorEngine: path.resolve(__dirname, '../js/src/dom/selector-engine.js'),
Alert: path.resolve(__dirname, '../js/src/alert.js'), Alert: path.resolve(__dirname, '../js/src/alert.js'),
Base: path.resolve(__dirname, '../js/src/base-component.js'),
Button: path.resolve(__dirname, '../js/src/button.js'), Button: path.resolve(__dirname, '../js/src/button.js'),
Carousel: path.resolve(__dirname, '../js/src/carousel.js'), Carousel: path.resolve(__dirname, '../js/src/carousel.js'),
Collapse: path.resolve(__dirname, '../js/src/collapse.js'), Collapse: path.resolve(__dirname, '../js/src/collapse.js'),
@ -39,124 +34,33 @@ const bsPlugins = {
ScrollSpy: path.resolve(__dirname, '../js/src/scrollspy.js'), ScrollSpy: path.resolve(__dirname, '../js/src/scrollspy.js'),
Tab: path.resolve(__dirname, '../js/src/tab.js'), Tab: path.resolve(__dirname, '../js/src/tab.js'),
Toast: path.resolve(__dirname, '../js/src/toast.js'), Toast: path.resolve(__dirname, '../js/src/toast.js'),
Tooltip: path.resolve(__dirname, '../js/src/tooltip.js') Tooltip: path.resolve(__dirname, '../js/src/tooltip.js'),
Util: path.resolve(__dirname, '../js/src/util.js')
} }
const rootPath = TEST ? '../js/coverage/dist/' : '../js/dist/'
const defaultPluginConfig = {
external: [
bsPlugins.Data,
bsPlugins.Base,
bsPlugins.EventHandler,
bsPlugins.SelectorEngine
],
globals: {
[bsPlugins.Data]: 'Data',
[bsPlugins.Base]: 'Base',
[bsPlugins.EventHandler]: 'EventHandler',
[bsPlugins.SelectorEngine]: 'SelectorEngine'
}
}
const getConfigByPluginKey = pluginKey => {
if (
pluginKey === 'Data' ||
pluginKey === 'Manipulator' ||
pluginKey === 'EventHandler' ||
pluginKey === 'SelectorEngine' ||
pluginKey === 'Util' ||
pluginKey === 'Sanitizer'
) {
return {
external: []
}
}
if (pluginKey === 'Alert' || pluginKey === 'Tab') {
return defaultPluginConfig
}
if (
pluginKey === 'Base' ||
pluginKey === 'Button' ||
pluginKey === 'Carousel' ||
pluginKey === 'Collapse' ||
pluginKey === 'Modal' ||
pluginKey === 'ScrollSpy'
) {
const config = Object.assign(defaultPluginConfig)
config.external.push(bsPlugins.Manipulator)
config.globals[bsPlugins.Manipulator] = 'Manipulator'
return config
}
if (pluginKey === 'Dropdown' || pluginKey === 'Tooltip') {
const config = Object.assign(defaultPluginConfig)
config.external.push(bsPlugins.Manipulator, '@popperjs/core')
config.globals[bsPlugins.Manipulator] = 'Manipulator'
config.globals['@popperjs/core'] = 'Popper'
return config
}
if (pluginKey === 'Popover') {
return {
external: [
bsPlugins.Data,
bsPlugins.SelectorEngine,
bsPlugins.Tooltip
],
globals: {
[bsPlugins.Data]: 'Data',
[bsPlugins.SelectorEngine]: 'SelectorEngine',
[bsPlugins.Tooltip]: 'Tooltip'
}
}
}
if (pluginKey === 'Toast') {
return {
external: [
bsPlugins.Data,
bsPlugins.Base,
bsPlugins.EventHandler,
bsPlugins.Manipulator
],
globals: {
[bsPlugins.Data]: 'Data',
[bsPlugins.Base]: 'Base',
[bsPlugins.EventHandler]: 'EventHandler',
[bsPlugins.Manipulator]: 'Manipulator'
}
}
}
}
const utilObjects = new Set([
'Util',
'Sanitizer'
])
const domObjects = new Set([
'Data',
'EventHandler',
'Manipulator',
'SelectorEngine'
])
const build = async plugin => { const build = async plugin => {
console.log(`Building ${plugin} plugin...`) console.log(`Building ${plugin} plugin...`)
const { external, globals } = getConfigByPluginKey(plugin) const external = ['jquery', 'popper.js']
const pluginFilename = path.basename(bsPlugins[plugin]) const globals = {
let pluginPath = rootPath jquery: 'jQuery', // Ensure we use jQuery which is always available even in noConflict mode
'popper.js': 'Popper'
if (utilObjects.has(plugin)) {
pluginPath = `${rootPath}/util/`
} }
if (domObjects.has(plugin)) { // Do not bundle Util in plugins
pluginPath = `${rootPath}/dom/` if (plugin !== 'Util') {
external.push(bsPlugins.Util)
globals[bsPlugins.Util] = 'Util'
} }
// Do not bundle Tooltip in Popover
if (plugin === 'Popover') {
external.push(bsPlugins.Tooltip)
globals[bsPlugins.Tooltip] = 'Tooltip'
}
const pluginFilename = `${plugin.toLowerCase()}.js`
const bundle = await rollup.rollup({ const bundle = await rollup.rollup({
input: bsPlugins[plugin], input: bsPlugins[plugin],
plugins, plugins,
@ -169,7 +73,7 @@ const build = async plugin => {
name: plugin, name: plugin,
sourcemap: true, sourcemap: true,
globals, globals,
file: path.resolve(__dirname, `${pluginPath}/${pluginFilename}`) file: path.resolve(__dirname, `${rootPath}${pluginFilename}`)
}) })
console.log(`Building ${plugin} plugin... Done!`) console.log(`Building ${plugin} plugin... Done!`)

30
build/change-version.js Normal file → Executable file
View file

@ -2,8 +2,8 @@
/*! /*!
* Script to update version number references in the project. * Script to update version number references in the project.
* Copyright 2017-2021 The Bootstrap Authors * Copyright 2017-2020 The Bootstrap Authors
* Copyright 2017-2021 Twitter, Inc. * Copyright 2017-2020 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
@ -17,7 +17,7 @@ sh.config.fatal = true
// Blame TC39... https://github.com/benjamingr/RegExp.escape/issues/37 // Blame TC39... https://github.com/benjamingr/RegExp.escape/issues/37
function regExpQuote(string) { function regExpQuote(string) {
return string.replace(/[$()*+-.?[\\\]^{|}]/g, '\\$&') return string.replace(/[$()*+.?[\\\]^{|}-]/g, '\\$&')
} }
function regExpQuoteReplacement(string) { function regExpQuoteReplacement(string) {
@ -58,19 +58,17 @@ function walkAsync(directory, excludedDirectories, fileCallback, errback) {
function replaceRecursively(directory, excludedDirectories, allowedExtensions, original, replacement) { function replaceRecursively(directory, excludedDirectories, allowedExtensions, original, replacement) {
original = new RegExp(regExpQuote(original), 'g') original = new RegExp(regExpQuote(original), 'g')
replacement = regExpQuoteReplacement(replacement) replacement = regExpQuoteReplacement(replacement)
const updateFile = DRY_RUN ? const updateFile = DRY_RUN ? filepath => {
filepath => { if (allowedExtensions.has(path.parse(filepath).ext)) {
if (allowedExtensions.has(path.parse(filepath).ext)) { console.log(`FILE: ${filepath}`)
console.log(`FILE: ${filepath}`) } else {
} else { console.log(`EXCLUDED:${filepath}`)
console.log(`EXCLUDED:${filepath}`)
}
} :
filepath => {
if (allowedExtensions.has(path.parse(filepath).ext)) {
sh.sed('-i', original, replacement, filepath)
}
} }
} : filepath => {
if (allowedExtensions.has(path.parse(filepath).ext)) {
sh.sed('-i', original, replacement, filepath)
}
}
walkAsync(directory, excludedDirectories, updateFile, err => { walkAsync(directory, excludedDirectories, updateFile, err => {
console.error('ERROR while traversing directory!:') console.error('ERROR while traversing directory!:')
@ -95,7 +93,7 @@ function main(args) {
'vendor' 'vendor'
]) ])
const INCLUDED_EXTENSIONS = new Set([ const INCLUDED_EXTENSIONS = new Set([
// This extension allowlist is how we avoid modifying binary files // This extension whitelist is how we avoid modifying binary files
'', '',
'.css', '.css',
'.html', '.html',

View file

@ -5,8 +5,8 @@
* Remember to use the same vendor files as the CDN ones, * Remember to use the same vendor files as the CDN ones,
* otherwise the hashes won't match! * otherwise the hashes won't match!
* *
* Copyright 2017-2021 The Bootstrap Authors * Copyright 2017-2020 The Bootstrap Authors
* Copyright 2017-2021 Twitter, Inc. * Copyright 2017-2020 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
@ -17,22 +17,20 @@ const fs = require('fs')
const path = require('path') const path = require('path')
const sh = require('shelljs') const sh = require('shelljs')
const pkg = require('../package.json')
sh.config.fatal = true sh.config.fatal = true
const configFile = path.join(__dirname, '../config.yml') const configFile = path.join(__dirname, '../_config.yml')
// Array of objects which holds the files to generate SRI hashes for. // Array of objects which holds the files to generate SRI hashes for.
// `file` is the path from the root folder // `file` is the path from the root folder
// `configPropertyName` is the config.yml variable's name of the file // `configPropertyName` is the _config.yml variable's name of the file
const files = [ const files = [
{ {
file: 'dist/css/bootstrap.min.css', file: 'dist/css/bootstrap.min.css',
configPropertyName: 'css_hash' configPropertyName: 'css_hash'
}, },
{
file: 'dist/css/bootstrap.rtl.min.css',
configPropertyName: 'css_rtl_hash'
},
{ {
file: 'dist/js/bootstrap.min.js', file: 'dist/js/bootstrap.min.js',
configPropertyName: 'js_hash' configPropertyName: 'js_hash'
@ -42,7 +40,11 @@ const files = [
configPropertyName: 'js_bundle_hash' configPropertyName: 'js_bundle_hash'
}, },
{ {
file: 'node_modules/@popperjs/core/dist/umd/popper.min.js', file: `site/docs/${pkg.version_short}/assets/js/vendor/jquery.slim.min.js`,
configPropertyName: 'jquery_hash'
},
{
file: 'node_modules/popper.js/dist/umd/popper.min.js',
configPropertyName: 'popper_hash' configPropertyName: 'popper_hash'
} }
] ]
@ -59,6 +61,6 @@ files.forEach(file => {
console.log(`${file.configPropertyName}: ${integrity}`) console.log(`${file.configPropertyName}: ${integrity}`)
sh.sed('-i', new RegExp(`^(\\s+${file.configPropertyName}:\\s+["'])\\S*(["'])`), `$1${integrity}$2`, configFile) sh.sed('-i', new RegExp(`(\\s${file.configPropertyName}:\\s+"|')(\\S+)("|')`), `$1${integrity}$3`, configFile)
}) })
}) })

View file

@ -1,19 +1,14 @@
'use strict' 'use strict'
module.exports = ctx => { module.exports = ctx => ({
return { map: ctx.file.dirname.includes('examples') ? false : {
map: ctx.file.dirname.includes('examples') ? inline: false,
false : annotation: true,
{ sourcesContent: true
inline: false, },
annotation: true, plugins: {
sourcesContent: true autoprefixer: {
}, cascade: false
plugins: {
autoprefixer: {
cascade: false
},
rtlcss: ctx.env === 'RTL' ? {} : false
} }
} }
} })

View file

@ -3,14 +3,12 @@
const path = require('path') const path = require('path')
const { babel } = require('@rollup/plugin-babel') const { babel } = require('@rollup/plugin-babel')
const { nodeResolve } = require('@rollup/plugin-node-resolve') const { nodeResolve } = require('@rollup/plugin-node-resolve')
const replace = require('@rollup/plugin-replace')
const banner = require('./banner.js') const banner = require('./banner.js')
const BUNDLE = process.env.BUNDLE === 'true' const BUNDLE = process.env.BUNDLE === 'true'
const ESM = process.env.ESM === 'true'
let fileDest = `bootstrap${ESM ? '.esm' : ''}` let fileDest = 'bootstrap.js'
const external = ['@popperjs/core'] const external = ['jquery', 'popper.js']
const plugins = [ const plugins = [
babel({ babel({
// Only transpile our source code // Only transpile our source code
@ -20,31 +18,27 @@ const plugins = [
}) })
] ]
const globals = { const globals = {
'@popperjs/core': 'Popper' jquery: 'jQuery', // Ensure we use jQuery which is always available even in noConflict mode
'popper.js': 'Popper'
} }
if (BUNDLE) { if (BUNDLE) {
fileDest += '.bundle' fileDest = 'bootstrap.bundle.js'
// Remove last entry in external array to bundle Popper // Remove last entry in external array to bundle Popper
external.pop() external.pop()
delete globals['@popperjs/core'] delete globals['popper.js']
plugins.push(replace({ 'process.env.NODE_ENV': '"production"' }), nodeResolve()) plugins.push(nodeResolve())
} }
const rollupConfig = { module.exports = {
input: path.resolve(__dirname, `../js/index.${ESM ? 'esm' : 'umd'}.js`), input: path.resolve(__dirname, '../js/src/index.js'),
output: { output: {
banner, banner,
file: path.resolve(__dirname, `../dist/js/${fileDest}.js`), file: path.resolve(__dirname, `../dist/js/${fileDest}`),
format: ESM ? 'esm' : 'umd', format: 'umd',
globals globals,
name: 'bootstrap'
}, },
external, external,
plugins plugins
} }
if (!ESM) {
rollupConfig.output.name = 'bootstrap'
}
module.exports = rollupConfig

2
build/ship.sh Normal file → Executable file
View file

@ -29,7 +29,7 @@ fi
printf "\n%s=======================================================%s" "$magenta" "$end" printf "\n%s=======================================================%s" "$magenta" "$end"
printf "\n%sPulling latest changes...%s" "$magenta" "$end" printf "\n%sPulling latest changes...%s" "$magenta" "$end"
printf "\n%s=======================================================\n\n%s" "$magenta" "$end" printf "\n%s=======================================================\n\n%s" "$magenta" "$end"
git pull origin main git pull origin v4-dev
# Update version number # Update version number
printf "\n%s=======================================================%s" "$magenta" "$end" printf "\n%s=======================================================%s" "$magenta" "$end"

View file

@ -15,9 +15,10 @@ js2svg:
indent: 2 indent: 2
plugins: plugins:
# - addAttributesToSVGElement: # remove this with IE 11 is no longer supported
# attributes: - addAttributesToSVGElement:
# - focusable: false attributes:
- focusable: false
- cleanupAttrs: true - cleanupAttrs: true
- cleanupEnableBackground: true - cleanupEnableBackground: true
- cleanupIDs: true - cleanupIDs: true

View file

@ -2,8 +2,8 @@
/*! /*!
* Script to run vnu-jar if Java is available. * Script to run vnu-jar if Java is available.
* Copyright 2017-2021 The Bootstrap Authors * Copyright 2017-2020 The Bootstrap Authors
* Copyright 2017-2021 Twitter, Inc. * Copyright 2017-2020 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
@ -33,11 +33,10 @@ childProcess.exec('java -version', (error, stdout, stderr) => {
// Content → Reboot uses various date/time inputs as a visual example. // Content → Reboot uses various date/time inputs as a visual example.
// Documentation does not rely on them being usable. // Documentation does not rely on them being usable.
'The “date” input type is not supported in all browsers.*', 'The “date” input type is not supported in all browsers.*',
'The “week” input type is not supported in all browsers.*', 'The “time” input type is not supported in all browsers.*',
'The “month” input type is not supported in all browsers.*', // IE11 doesn't recognise <main> / give the element an implicit "main" landmark.
'The “color” input type is not supported in all browsers.*', // Explicit role="main" is redundant for other modern browsers, but still valid.
'The “datetime-local” input type is not supported in all browsers.*', 'The “main” role is unnecessary for element “main”.'
'The “time” input type is not supported in all browsers.*'
].join('|') ].join('|')
const args = [ const args = [

View file

@ -3,7 +3,7 @@
/*! /*!
* Script to create the built examples zip archive; * Script to create the built examples zip archive;
* requires the `zip` command to be present! * requires the `zip` command to be present!
* Copyright 2020-2021 The Bootstrap Authors * Copyright 2020 The Bootstrap Authors
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
@ -12,67 +12,38 @@
const path = require('path') const path = require('path')
const sh = require('shelljs') const sh = require('shelljs')
const pkg = require('../package.json') const {
version, version_short: versionShort
} = require('../package.json')
const versionShort = pkg.config.version_short const folderName = `bootstrap-${version}-examples`
const distFolder = `bootstrap-${pkg.version}-examples`
const rootDocsDir = '_gh_pages'
const docsDir = `${rootDocsDir}/docs/${versionShort}/`
// these are the files we need in the examples
const cssFiles = [
'bootstrap.min.css',
'bootstrap.min.css.map',
'bootstrap.rtl.min.css',
'bootstrap.rtl.min.css.map'
]
const jsFiles = [
'bootstrap.bundle.min.js',
'bootstrap.bundle.min.js.map'
]
const imgFiles = [
'bootstrap-logo.svg',
'bootstrap-logo-white.svg'
]
sh.config.fatal = true sh.config.fatal = true
if (!sh.test('-d', rootDocsDir)) { if (!sh.test('-d', '_gh_pages')) {
throw new Error(`The "${rootDocsDir}" folder does not exist, did you forget building the docs?`) throw new Error('The "_gh_pages" folder does not exist, did you forget building the docs?')
} }
// switch to the root dir // switch to the root dir
sh.cd(path.join(__dirname, '..')) sh.cd(path.join(__dirname, '..'))
// remove any previously created folder/zip with the same name // remove any previously created folder with the same name
sh.rm('-rf', [distFolder, `${distFolder}.zip`]) sh.rm('-rf', folderName)
// create any folders so that `cp` works // create any folders so that `cp` works
sh.mkdir('-p', [ sh.mkdir('-p', folderName)
distFolder, sh.mkdir('-p', `${folderName}/assets/brand/`)
`${distFolder}/assets/brand/`,
`${distFolder}/assets/dist/css/`,
`${distFolder}/assets/dist/js/`
])
sh.cp('-Rf', `${docsDir}/examples/*`, distFolder) sh.cp('-Rf', `_gh_pages/docs/${versionShort}/examples/*`, folderName)
sh.cp('-Rf', `_gh_pages/docs/${versionShort}/dist/`, `${folderName}/assets/`)
cssFiles.forEach(file => { // also copy the two brand images we use in the examples
sh.cp('-f', `${docsDir}/dist/css/${file}`, `${distFolder}/assets/dist/css/`) sh.cp('-f', [
}) `_gh_pages/docs/${versionShort}/assets/brand/bootstrap-outline.svg`,
`_gh_pages/docs/${versionShort}/assets/brand/bootstrap-solid.svg`
jsFiles.forEach(file => { ], `${folderName}/assets/brand/`)
sh.cp('-f', `${docsDir}/dist/js/${file}`, `${distFolder}/assets/dist/js/`) sh.rm(`${folderName}/index.html`)
})
imgFiles.forEach(file => {
sh.cp('-f', `${docsDir}/assets/brand/${file}`, `${distFolder}/assets/brand/`)
})
sh.rm(`${distFolder}/index.html`)
// get all examples' HTML files // get all examples' HTML files
sh.find(`${distFolder}/**/*.html`).forEach(file => { sh.find(`${folderName}/**/*.html`).forEach(file => {
const fileContents = sh.cat(file) const fileContents = sh.cat(file)
.toString() .toString()
.replace(new RegExp(`"/docs/${versionShort}/`, 'g'), '"../') .replace(new RegExp(`"/docs/${versionShort}/`, 'g'), '"../')
@ -84,7 +55,9 @@ sh.find(`${distFolder}/**/*.html`).forEach(file => {
}) })
// create the zip file // create the zip file
sh.exec(`zip -r9 "${distFolder}.zip" "${distFolder}"`) sh.exec(`zip -r9 "${folderName}.zip" "${folderName}"`, {
fatal: true
})
// remove the folder we created // remove the folder we created
sh.rm('-rf', distFolder) sh.rm('-rf', folderName)

View file

@ -26,6 +26,11 @@
"issues": "https://github.com/twbs/bootstrap/issues" "issues": "https://github.com/twbs/bootstrap/issues"
}, },
"license": "MIT", "license": "MIT",
"extra": {
"branch-alias": {
"dev-master": "3.3.x-dev"
}
},
"replace": { "replace": {
"twitter/bootstrap": "self.version" "twitter/bootstrap": "self.version"
} }

View file

@ -1,79 +0,0 @@
languageCode: "en"
title: "Bootstrap"
baseURL: "https://getbootstrap.com"
enableInlineShortcodes: true
markup:
goldmark:
renderer:
unsafe: true
highlight:
noClasses: false
tableOfContents:
startLevel: 2
endLevel: 6
buildDrafts: true
buildFuture: true
enableRobotsTXT: true
metaDataFormat: "yaml"
disableKinds: ["404", "taxonomy", "taxonomyTerm", "RSS"]
publishDir: "_gh_pages"
module:
mounts:
- source: dist
target: static/docs/5.0/dist
- source: site/assets
target: assets
- source: site/content
target: content
- source: site/data
target: data
- source: site/layouts
target: layouts
- source: site/static
target: static
- source: site/static/docs/5.0/assets/img/favicons/apple-touch-icon.png
target: static/apple-touch-icon.png
- source: site/static/docs/5.0/assets/img/favicons/favicon.ico
target: static/favicon.ico
params:
description: "The most popular HTML, CSS, and JS library in the world."
authors: "Mark Otto, Jacob Thornton, and Bootstrap contributors"
social_image_path: /docs/5.0/assets/brand/bootstrap-social.png
social_logo_path: /docs/5.0/assets/brand/bootstrap-social-logo.png
current_version: "5.0.0-beta1"
current_ruby_version: "5.0.0.beta1"
docs_version: "5.0"
rfs_version: "9.0.3"
github_org: "https://github.com/twbs"
repo: "https://github.com/twbs/bootstrap"
twitter: "getbootstrap"
slack: "https://bootstrap-slack.herokuapp.com/"
opencollective: "https://opencollective.com/bootstrap"
blog: "https://blog.getbootstrap.com/"
themes: "https://themes.getbootstrap.com/"
icons: "https://icons.getbootstrap.com/"
download:
source: "https://github.com/twbs/bootstrap/archive/v5.0.0-beta1.zip"
dist: "https://github.com/twbs/bootstrap/releases/download/v5.0.0-beta1/bootstrap-5.0.0-beta1-dist.zip"
dist_examples: "https://github.com/twbs/bootstrap/releases/download/v5.0.0-beta1/bootstrap-5.0.0-beta1-examples.zip"
cdn:
# See https://www.srihash.org for info on how to generate the hashes
css: "https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta1/dist/css/bootstrap.min.css"
css_hash: "sha384-giJF6kkoqNQ00vy+HMDP7azOuL0xtbfIcaT9wjKHr8RbDVddVHyTfAAsrekwKmP1"
css_rtl: "https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta1/dist/css/bootstrap.rtl.min.css"
css_rtl_hash: "sha384-mUkCBeyHPdg0tqB6JDd+65Gpw5h/l8DKcCTV2D2UpaMMFd7Jo8A+mDAosaWgFBPl"
js: "https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta1/dist/js/bootstrap.min.js"
js_hash: "sha384-pQQkAEnwaBkjpqZ8RU1fF1AKtTcHJwFl3pblpTlHXybJjHpMYo79HY3hIi4NKxyj"
js_bundle: "https://cdn.jsdelivr.net/npm/bootstrap@5.0.0-beta1/dist/js/bootstrap.bundle.min.js"
js_bundle_hash: "sha384-ygbV9kiqUc6oa4msXn9868pTtWMgiQaeYH7/t7LECLbyPA2x65Kgf80OJFdroafW"
popper: "https://cdn.jsdelivr.net/npm/@popperjs/core@2.6.0/dist/umd/popper.min.js"
popper_hash: "sha384-KsvD1yqQ1/1+IA7gi3P0tyJcT3vR+NdBTt13hSJ2lnve8agRGXTTyNaBYmCR/Nwi"

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -1,5 +1,5 @@
/*! /*!
* Bootstrap Reboot v5.0.0-beta1 (https://getbootstrap.com/) * Bootstrap Reboot v4.5.2 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors * Copyright 2011-2020 The Bootstrap Authors
* Copyright 2011-2020 Twitter, Inc. * Copyright 2011-2020 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
@ -11,22 +11,26 @@
box-sizing: border-box; box-sizing: border-box;
} }
@media (prefers-reduced-motion: no-preference) { html {
:root { font-family: sans-serif;
scroll-behavior: smooth; line-height: 1.15;
} -webkit-text-size-adjust: 100%;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
article, aside, figcaption, figure, footer, header, hgroup, main, nav, section {
display: block;
} }
body { body {
margin: 0; margin: 0;
font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
font-size: 1rem; font-size: 1rem;
font-weight: 400; font-weight: 400;
line-height: 1.5; line-height: 1.5;
color: #212529; color: #212529;
text-align: left;
background-color: #fff; background-color: #fff;
-webkit-text-size-adjust: 100%;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
} }
[tabindex="-1"]:focus:not(:focus-visible) { [tabindex="-1"]:focus:not(:focus-visible) {
@ -34,66 +38,14 @@ body {
} }
hr { hr {
margin: 1rem 0; box-sizing: content-box;
color: inherit; height: 0;
background-color: currentColor; overflow: visible;
border: 0;
opacity: 0.25;
} }
hr:not([size]) { h1, h2, h3, h4, h5, h6 {
height: 1px;
}
h6, h5, h4, h3, h2, h1 {
margin-top: 0; margin-top: 0;
margin-bottom: 0.5rem; margin-bottom: 0.5rem;
font-weight: 500;
line-height: 1.2;
}
h1 {
font-size: calc(1.375rem + 1.5vw);
}
@media (min-width: 1200px) {
h1 {
font-size: 2.5rem;
}
}
h2 {
font-size: calc(1.325rem + 0.9vw);
}
@media (min-width: 1200px) {
h2 {
font-size: 2rem;
}
}
h3 {
font-size: calc(1.3rem + 0.6vw);
}
@media (min-width: 1200px) {
h3 {
font-size: 1.75rem;
}
}
h4 {
font-size: calc(1.275rem + 0.3vw);
}
@media (min-width: 1200px) {
h4 {
font-size: 1.5rem;
}
}
h5 {
font-size: 1.25rem;
}
h6 {
font-size: 1rem;
} }
p { p {
@ -102,11 +54,12 @@ p {
} }
abbr[title], abbr[title],
abbr[data-bs-original-title] { abbr[data-original-title] {
text-decoration: underline; text-decoration: underline;
-webkit-text-decoration: underline dotted; -webkit-text-decoration: underline dotted;
text-decoration: underline dotted; text-decoration: underline dotted;
cursor: help; cursor: help;
border-bottom: 0;
-webkit-text-decoration-skip-ink: none; -webkit-text-decoration-skip-ink: none;
text-decoration-skip-ink: none; text-decoration-skip-ink: none;
} }
@ -117,11 +70,6 @@ address {
line-height: inherit; line-height: inherit;
} }
ol,
ul {
padding-left: 2rem;
}
ol, ol,
ul, ul,
dl { dl {
@ -141,7 +89,7 @@ dt {
} }
dd { dd {
margin-bottom: 0.5rem; margin-bottom: .5rem;
margin-left: 0; margin-left: 0;
} }
@ -155,39 +103,42 @@ strong {
} }
small { small {
font-size: 0.875em; font-size: 80%;
}
mark {
padding: 0.2em;
background-color: #fcf8e3;
} }
sub, sub,
sup { sup {
position: relative; position: relative;
font-size: 0.75em; font-size: 75%;
line-height: 0; line-height: 0;
vertical-align: baseline; vertical-align: baseline;
} }
sub { sub {
bottom: -0.25em; bottom: -.25em;
} }
sup { sup {
top: -0.5em; top: -.5em;
} }
a { a {
color: #0d6efd; color: #007bff;
text-decoration: underline; text-decoration: none;
} background-color: transparent;
a:hover {
color: #0a58ca;
} }
a:not([href]):not([class]), a:not([href]):not([class]):hover { a:hover {
color: #0056b3;
text-decoration: underline;
}
a:not([href]):not([class]) {
color: inherit;
text-decoration: none;
}
a:not([href]):not([class]):hover {
color: inherit; color: inherit;
text-decoration: none; text-decoration: none;
} }
@ -198,84 +149,48 @@ kbd,
samp { samp {
font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 1em; font-size: 1em;
direction: ltr /* rtl:ignore */;
unicode-bidi: bidi-override;
} }
pre { pre {
display: block;
margin-top: 0; margin-top: 0;
margin-bottom: 1rem; margin-bottom: 1rem;
overflow: auto; overflow: auto;
font-size: 0.875em; -ms-overflow-style: scrollbar;
}
pre code {
font-size: inherit;
color: inherit;
word-break: normal;
}
code {
font-size: 0.875em;
color: #d63384;
word-wrap: break-word;
}
a > code {
color: inherit;
}
kbd {
padding: 0.2rem 0.4rem;
font-size: 0.875em;
color: #fff;
background-color: #212529;
border-radius: 0.2rem;
}
kbd kbd {
padding: 0;
font-size: 1em;
font-weight: 700;
} }
figure { figure {
margin: 0 0 1rem; margin: 0 0 1rem;
} }
img, img {
vertical-align: middle;
border-style: none;
}
svg { svg {
overflow: hidden;
vertical-align: middle; vertical-align: middle;
} }
table { table {
caption-side: bottom;
border-collapse: collapse; border-collapse: collapse;
} }
caption { caption {
padding-top: 0.5rem; padding-top: 0.75rem;
padding-bottom: 0.5rem; padding-bottom: 0.75rem;
color: #6c757d; color: #6c757d;
text-align: left; text-align: left;
caption-side: bottom;
} }
th { th {
text-align: inherit; text-align: inherit;
text-align: -webkit-match-parent;
}
thead,
tbody,
tfoot,
tr,
td,
th {
border-color: inherit;
border-style: solid;
border-width: 0;
} }
label { label {
display: inline-block; display: inline-block;
margin-bottom: 0.5rem;
} }
button { button {
@ -283,8 +198,8 @@ button {
} }
button:focus { button:focus {
outline: dotted 1px; outline: 1px dotted;
outline: -webkit-focus-ring-color auto 5px; outline: 5px auto -webkit-focus-ring-color;
} }
input, input,
@ -298,12 +213,17 @@ textarea {
line-height: inherit; line-height: inherit;
} }
button,
input {
overflow: visible;
}
button, button,
select { select {
text-transform: none; text-transform: none;
} }
[role=button] { [role="button"] {
cursor: pointer; cursor: pointer;
} }
@ -311,29 +231,36 @@ select {
word-wrap: normal; word-wrap: normal;
} }
[list]::-webkit-calendar-picker-indicator {
display: none;
}
button, button,
[type=button], [type="button"],
[type=reset], [type="reset"],
[type=submit] { [type="submit"] {
-webkit-appearance: button; -webkit-appearance: button;
} }
button:not(:disabled), button:not(:disabled),
[type=button]:not(:disabled), [type="button"]:not(:disabled),
[type=reset]:not(:disabled), [type="reset"]:not(:disabled),
[type=submit]:not(:disabled) { [type="submit"]:not(:disabled) {
cursor: pointer; cursor: pointer;
} }
::-moz-focus-inner { button::-moz-focus-inner,
[type="button"]::-moz-focus-inner,
[type="reset"]::-moz-focus-inner,
[type="submit"]::-moz-focus-inner {
padding: 0; padding: 0;
border-style: none; border-style: none;
} }
input[type="radio"],
input[type="checkbox"] {
box-sizing: border-box;
padding: 0;
}
textarea { textarea {
overflow: auto;
resize: vertical; resize: vertical;
} }
@ -345,59 +272,33 @@ fieldset {
} }
legend { legend {
float: left; display: block;
width: 100%; width: 100%;
max-width: 100%;
padding: 0; padding: 0;
margin-bottom: 0.5rem; margin-bottom: .5rem;
font-size: calc(1.275rem + 0.3vw); font-size: 1.5rem;
line-height: inherit; line-height: inherit;
} color: inherit;
@media (min-width: 1200px) { white-space: normal;
legend {
font-size: 1.5rem;
}
}
legend + * {
clear: left;
} }
::-webkit-datetime-edit-fields-wrapper, progress {
::-webkit-datetime-edit-text, vertical-align: baseline;
::-webkit-datetime-edit-minute,
::-webkit-datetime-edit-hour-field,
::-webkit-datetime-edit-day-field,
::-webkit-datetime-edit-month-field,
::-webkit-datetime-edit-year-field {
padding: 0;
} }
::-webkit-inner-spin-button { [type="number"]::-webkit-inner-spin-button,
[type="number"]::-webkit-outer-spin-button {
height: auto; height: auto;
} }
[type=search] { [type="search"] {
outline-offset: -2px; outline-offset: -2px;
-webkit-appearance: textfield;
}
/* rtl:raw:
[type="tel"],
[type="url"],
[type="email"],
[type="number"] {
direction: ltr;
}
*/
::-webkit-search-decoration {
-webkit-appearance: none; -webkit-appearance: none;
} }
::-webkit-color-swatch-wrapper { [type="search"]::-webkit-search-decoration {
padding: 0; -webkit-appearance: none;
}
::file-selector-button {
font: inherit;
} }
::-webkit-file-upload-button { ::-webkit-file-upload-button {
@ -409,21 +310,16 @@ output {
display: inline-block; display: inline-block;
} }
iframe {
border: 0;
}
summary { summary {
display: list-item; display: list-item;
cursor: pointer; cursor: pointer;
} }
progress { template {
vertical-align: baseline; display: none;
} }
[hidden] { [hidden] {
display: none !important; display: none !important;
} }
/*# sourceMappingURL=bootstrap-reboot.css.map */ /*# sourceMappingURL=bootstrap-reboot.css.map */

File diff suppressed because one or more lines are too long

View file

@ -1,8 +1,8 @@
/*! /*!
* Bootstrap Reboot v5.0.0-beta1 (https://getbootstrap.com/) * Bootstrap Reboot v4.5.2 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors * Copyright 2011-2020 The Bootstrap Authors
* Copyright 2011-2020 Twitter, Inc. * Copyright 2011-2020 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* Forked from Normalize.css, licensed MIT (https://github.com/necolas/normalize.css/blob/master/LICENSE.md) * Forked from Normalize.css, licensed MIT (https://github.com/necolas/normalize.css/blob/master/LICENSE.md)
*/*,::after,::before{box-sizing:border-box}@media (prefers-reduced-motion:no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans","Liberation Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";font-size:1rem;font-weight:400;line-height:1.5;color:#212529;background-color:#fff;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}[tabindex="-1"]:focus:not(:focus-visible){outline:0!important}hr{margin:1rem 0;color:inherit;background-color:currentColor;border:0;opacity:.25}hr:not([size]){height:1px}h1,h2,h3,h4,h5,h6{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}h1{font-size:calc(1.375rem + 1.5vw)}@media (min-width:1200px){h1{font-size:2.5rem}}h2{font-size:calc(1.325rem + .9vw)}@media (min-width:1200px){h2{font-size:2rem}}h3{font-size:calc(1.3rem + .6vw)}@media (min-width:1200px){h3{font-size:1.75rem}}h4{font-size:calc(1.275rem + .3vw)}@media (min-width:1200px){h4{font-size:1.5rem}}h5{font-size:1.25rem}h6{font-size:1rem}p{margin-top:0;margin-bottom:1rem}abbr[data-bs-original-title],abbr[title]{text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;cursor:help;-webkit-text-decoration-skip-ink:none;text-decoration-skip-ink:none}address{margin-bottom:1rem;font-style:normal;line-height:inherit}ol,ul{padding-left:2rem}dl,ol,ul{margin-top:0;margin-bottom:1rem}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:.5rem;margin-left:0}blockquote{margin:0 0 1rem}b,strong{font-weight:bolder}small{font-size:.875em}mark{padding:.2em;background-color:#fcf8e3}sub,sup{position:relative;font-size:.75em;line-height:0;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}a{color:#0d6efd;text-decoration:underline}a:hover{color:#0a58ca}a:not([href]):not([class]),a:not([href]):not([class]):hover{color:inherit;text-decoration:none}code,kbd,pre,samp{font-family:SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;font-size:1em;direction:ltr;unicode-bidi:bidi-override}pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}pre code{font-size:inherit;color:inherit;word-break:normal}code{font-size:.875em;color:#d63384;word-wrap:break-word}a>code{color:inherit}kbd{padding:.2rem .4rem;font-size:.875em;color:#fff;background-color:#212529;border-radius:.2rem}kbd kbd{padding:0;font-size:1em;font-weight:700}figure{margin:0 0 1rem}img,svg{vertical-align:middle}table{caption-side:bottom;border-collapse:collapse}caption{padding-top:.5rem;padding-bottom:.5rem;color:#6c757d;text-align:left}th{text-align:inherit;text-align:-webkit-match-parent}tbody,td,tfoot,th,thead,tr{border-color:inherit;border-style:solid;border-width:0}label{display:inline-block}button{border-radius:0}button:focus{outline:dotted 1px;outline:-webkit-focus-ring-color auto 5px}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,select{text-transform:none}[role=button]{cursor:pointer}select{word-wrap:normal}[list]::-webkit-calendar-picker-indicator{display:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}[type=button]:not(:disabled),[type=reset]:not(:disabled),[type=submit]:not(:disabled),button:not(:disabled){cursor:pointer}::-moz-focus-inner{padding:0;border-style:none}textarea{resize:vertical}fieldset{min-width:0;padding:0;margin:0;border:0}legend{float:left;width:100%;padding:0;margin-bottom:.5rem;font-size:calc(1.275rem + .3vw);line-height:inherit}@media (min-width:1200px){legend{font-size:1.5rem}}legend+*{clear:left}::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-fields-wrapper,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-text,::-webkit-datetime-edit-year-field{padding:0}::-webkit-inner-spin-button{height:auto}[type=search]{outline-offset:-2px;-webkit-appearance:textfield}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-color-swatch-wrapper{padding:0}::file-selector-button{font:inherit}::-webkit-file-upload-button{font:inherit;-webkit-appearance:button}output{display:inline-block}iframe{border:0}summary{display:list-item;cursor:pointer}progress{vertical-align:baseline}[hidden]{display:none!important} */*,::after,::before{box-sizing:border-box}html{font-family:sans-serif;line-height:1.15;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}article,aside,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}body{margin:0;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";font-size:1rem;font-weight:400;line-height:1.5;color:#212529;text-align:left;background-color:#fff}[tabindex="-1"]:focus:not(:focus-visible){outline:0!important}hr{box-sizing:content-box;height:0;overflow:visible}h1,h2,h3,h4,h5,h6{margin-top:0;margin-bottom:.5rem}p{margin-top:0;margin-bottom:1rem}abbr[data-original-title],abbr[title]{text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;cursor:help;border-bottom:0;-webkit-text-decoration-skip-ink:none;text-decoration-skip-ink:none}address{margin-bottom:1rem;font-style:normal;line-height:inherit}dl,ol,ul{margin-top:0;margin-bottom:1rem}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:.5rem;margin-left:0}blockquote{margin:0 0 1rem}b,strong{font-weight:bolder}small{font-size:80%}sub,sup{position:relative;font-size:75%;line-height:0;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}a{color:#007bff;text-decoration:none;background-color:transparent}a:hover{color:#0056b3;text-decoration:underline}a:not([href]):not([class]){color:inherit;text-decoration:none}a:not([href]):not([class]):hover{color:inherit;text-decoration:none}code,kbd,pre,samp{font-family:SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;font-size:1em}pre{margin-top:0;margin-bottom:1rem;overflow:auto;-ms-overflow-style:scrollbar}figure{margin:0 0 1rem}img{vertical-align:middle;border-style:none}svg{overflow:hidden;vertical-align:middle}table{border-collapse:collapse}caption{padding-top:.75rem;padding-bottom:.75rem;color:#6c757d;text-align:left;caption-side:bottom}th{text-align:inherit}label{display:inline-block;margin-bottom:.5rem}button{border-radius:0}button:focus{outline:1px dotted;outline:5px auto -webkit-focus-ring-color}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,input{overflow:visible}button,select{text-transform:none}[role=button]{cursor:pointer}select{word-wrap:normal}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}[type=button]:not(:disabled),[type=reset]:not(:disabled),[type=submit]:not(:disabled),button:not(:disabled){cursor:pointer}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{padding:0;border-style:none}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}textarea{overflow:auto;resize:vertical}fieldset{min-width:0;padding:0;margin:0;border:0}legend{display:block;width:100%;max-width:100%;padding:0;margin-bottom:.5rem;font-size:1.5rem;line-height:inherit;color:inherit;white-space:normal}progress{vertical-align:baseline}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{outline-offset:-2px;-webkit-appearance:none}[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{font:inherit;-webkit-appearance:button}output{display:inline-block}summary{display:list-item;cursor:pointer}template{display:none}[hidden]{display:none!important}
/*# sourceMappingURL=bootstrap-reboot.min.css.map */ /*# sourceMappingURL=bootstrap-reboot.min.css.map */

File diff suppressed because one or more lines are too long

View file

@ -1,426 +0,0 @@
/*!
* Bootstrap Reboot v5.0.0-beta1 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors
* Copyright 2011-2020 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* Forked from Normalize.css, licensed MIT (https://github.com/necolas/normalize.css/blob/master/LICENSE.md)
*/
*,
*::before,
*::after {
box-sizing: border-box;
}
@media (prefers-reduced-motion: no-preference) {
:root {
scroll-behavior: smooth;
}
}
body {
margin: 0;
font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
font-size: 1rem;
font-weight: 400;
line-height: 1.5;
color: #212529;
background-color: #fff;
-webkit-text-size-adjust: 100%;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
[tabindex="-1"]:focus:not(:focus-visible) {
outline: 0 !important;
}
hr {
margin: 1rem 0;
color: inherit;
background-color: currentColor;
border: 0;
opacity: 0.25;
}
hr:not([size]) {
height: 1px;
}
h6, h5, h4, h3, h2, h1 {
margin-top: 0;
margin-bottom: 0.5rem;
font-weight: 500;
line-height: 1.2;
}
h1 {
font-size: calc(1.375rem + 1.5vw);
}
@media (min-width: 1200px) {
h1 {
font-size: 2.5rem;
}
}
h2 {
font-size: calc(1.325rem + 0.9vw);
}
@media (min-width: 1200px) {
h2 {
font-size: 2rem;
}
}
h3 {
font-size: calc(1.3rem + 0.6vw);
}
@media (min-width: 1200px) {
h3 {
font-size: 1.75rem;
}
}
h4 {
font-size: calc(1.275rem + 0.3vw);
}
@media (min-width: 1200px) {
h4 {
font-size: 1.5rem;
}
}
h5 {
font-size: 1.25rem;
}
h6 {
font-size: 1rem;
}
p {
margin-top: 0;
margin-bottom: 1rem;
}
abbr[title],
abbr[data-bs-original-title] {
text-decoration: underline;
-webkit-text-decoration: underline dotted;
text-decoration: underline dotted;
cursor: help;
-webkit-text-decoration-skip-ink: none;
text-decoration-skip-ink: none;
}
address {
margin-bottom: 1rem;
font-style: normal;
line-height: inherit;
}
ol,
ul {
padding-right: 2rem;
}
ol,
ul,
dl {
margin-top: 0;
margin-bottom: 1rem;
}
ol ol,
ul ul,
ol ul,
ul ol {
margin-bottom: 0;
}
dt {
font-weight: 700;
}
dd {
margin-bottom: 0.5rem;
margin-right: 0;
}
blockquote {
margin: 0 0 1rem;
}
b,
strong {
font-weight: bolder;
}
small {
font-size: 0.875em;
}
mark {
padding: 0.2em;
background-color: #fcf8e3;
}
sub,
sup {
position: relative;
font-size: 0.75em;
line-height: 0;
vertical-align: baseline;
}
sub {
bottom: -0.25em;
}
sup {
top: -0.5em;
}
a {
color: #0d6efd;
text-decoration: underline;
}
a:hover {
color: #0a58ca;
}
a:not([href]):not([class]), a:not([href]):not([class]):hover {
color: inherit;
text-decoration: none;
}
pre,
code,
kbd,
samp {
font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 1em;
direction: ltr ;
unicode-bidi: bidi-override;
}
pre {
display: block;
margin-top: 0;
margin-bottom: 1rem;
overflow: auto;
font-size: 0.875em;
}
pre code {
font-size: inherit;
color: inherit;
word-break: normal;
}
code {
font-size: 0.875em;
color: #d63384;
word-wrap: break-word;
}
a > code {
color: inherit;
}
kbd {
padding: 0.2rem 0.4rem;
font-size: 0.875em;
color: #fff;
background-color: #212529;
border-radius: 0.2rem;
}
kbd kbd {
padding: 0;
font-size: 1em;
font-weight: 700;
}
figure {
margin: 0 0 1rem;
}
img,
svg {
vertical-align: middle;
}
table {
caption-side: bottom;
border-collapse: collapse;
}
caption {
padding-top: 0.5rem;
padding-bottom: 0.5rem;
color: #6c757d;
text-align: right;
}
th {
text-align: inherit;
text-align: -webkit-match-parent;
}
thead,
tbody,
tfoot,
tr,
td,
th {
border-color: inherit;
border-style: solid;
border-width: 0;
}
label {
display: inline-block;
}
button {
border-radius: 0;
}
button:focus {
outline: dotted 1px;
outline: -webkit-focus-ring-color auto 5px;
}
input,
button,
select,
optgroup,
textarea {
margin: 0;
font-family: inherit;
font-size: inherit;
line-height: inherit;
}
button,
select {
text-transform: none;
}
[role=button] {
cursor: pointer;
}
select {
word-wrap: normal;
}
[list]::-webkit-calendar-picker-indicator {
display: none;
}
button,
[type=button],
[type=reset],
[type=submit] {
-webkit-appearance: button;
}
button:not(:disabled),
[type=button]:not(:disabled),
[type=reset]:not(:disabled),
[type=submit]:not(:disabled) {
cursor: pointer;
}
::-moz-focus-inner {
padding: 0;
border-style: none;
}
textarea {
resize: vertical;
}
fieldset {
min-width: 0;
padding: 0;
margin: 0;
border: 0;
}
legend {
float: right;
width: 100%;
padding: 0;
margin-bottom: 0.5rem;
font-size: calc(1.275rem + 0.3vw);
line-height: inherit;
}
@media (min-width: 1200px) {
legend {
font-size: 1.5rem;
}
}
legend + * {
clear: right;
}
::-webkit-datetime-edit-fields-wrapper,
::-webkit-datetime-edit-text,
::-webkit-datetime-edit-minute,
::-webkit-datetime-edit-hour-field,
::-webkit-datetime-edit-day-field,
::-webkit-datetime-edit-month-field,
::-webkit-datetime-edit-year-field {
padding: 0;
}
::-webkit-inner-spin-button {
height: auto;
}
[type=search] {
outline-offset: -2px;
-webkit-appearance: textfield;
}
[type="tel"],
[type="url"],
[type="email"],
[type="number"] {
direction: ltr;
}
::-webkit-search-decoration {
-webkit-appearance: none;
}
::-webkit-color-swatch-wrapper {
padding: 0;
}
::file-selector-button {
font: inherit;
}
::-webkit-file-upload-button {
font: inherit;
-webkit-appearance: button;
}
output {
display: inline-block;
}
iframe {
border: 0;
}
summary {
display: list-item;
cursor: pointer;
}
progress {
vertical-align: baseline;
}
[hidden] {
display: none !important;
}
/*# sourceMappingURL=bootstrap-reboot.rtl.css.map */

File diff suppressed because one or more lines are too long

View file

@ -1,8 +0,0 @@
/*!
* Bootstrap Reboot v5.0.0-beta1 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors
* Copyright 2011-2020 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* Forked from Normalize.css, licensed MIT (https://github.com/necolas/normalize.css/blob/master/LICENSE.md)
*/*,::after,::before{box-sizing:border-box}@media (prefers-reduced-motion:no-preference){:root{scroll-behavior:smooth}}body{margin:0;font-family:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans","Liberation Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";font-size:1rem;font-weight:400;line-height:1.5;color:#212529;background-color:#fff;-webkit-text-size-adjust:100%;-webkit-tap-highlight-color:transparent}[tabindex="-1"]:focus:not(:focus-visible){outline:0!important}hr{margin:1rem 0;color:inherit;background-color:currentColor;border:0;opacity:.25}hr:not([size]){height:1px}h1,h2,h3,h4,h5,h6{margin-top:0;margin-bottom:.5rem;font-weight:500;line-height:1.2}h1{font-size:calc(1.375rem + 1.5vw)}@media (min-width:1200px){h1{font-size:2.5rem}}h2{font-size:calc(1.325rem + .9vw)}@media (min-width:1200px){h2{font-size:2rem}}h3{font-size:calc(1.3rem + .6vw)}@media (min-width:1200px){h3{font-size:1.75rem}}h4{font-size:calc(1.275rem + .3vw)}@media (min-width:1200px){h4{font-size:1.5rem}}h5{font-size:1.25rem}h6{font-size:1rem}p{margin-top:0;margin-bottom:1rem}abbr[data-bs-original-title],abbr[title]{text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;cursor:help;-webkit-text-decoration-skip-ink:none;text-decoration-skip-ink:none}address{margin-bottom:1rem;font-style:normal;line-height:inherit}ol,ul{padding-right:2rem}dl,ol,ul{margin-top:0;margin-bottom:1rem}ol ol,ol ul,ul ol,ul ul{margin-bottom:0}dt{font-weight:700}dd{margin-bottom:.5rem;margin-right:0}blockquote{margin:0 0 1rem}b,strong{font-weight:bolder}small{font-size:.875em}mark{padding:.2em;background-color:#fcf8e3}sub,sup{position:relative;font-size:.75em;line-height:0;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}a{color:#0d6efd;text-decoration:underline}a:hover{color:#0a58ca}a:not([href]):not([class]),a:not([href]):not([class]):hover{color:inherit;text-decoration:none}code,kbd,pre,samp{font-family:SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;font-size:1em;direction:ltr;unicode-bidi:bidi-override}pre{display:block;margin-top:0;margin-bottom:1rem;overflow:auto;font-size:.875em}pre code{font-size:inherit;color:inherit;word-break:normal}code{font-size:.875em;color:#d63384;word-wrap:break-word}a>code{color:inherit}kbd{padding:.2rem .4rem;font-size:.875em;color:#fff;background-color:#212529;border-radius:.2rem}kbd kbd{padding:0;font-size:1em;font-weight:700}figure{margin:0 0 1rem}img,svg{vertical-align:middle}table{caption-side:bottom;border-collapse:collapse}caption{padding-top:.5rem;padding-bottom:.5rem;color:#6c757d;text-align:right}th{text-align:inherit;text-align:-webkit-match-parent}tbody,td,tfoot,th,thead,tr{border-color:inherit;border-style:solid;border-width:0}label{display:inline-block}button{border-radius:0}button:focus{outline:dotted 1px;outline:-webkit-focus-ring-color auto 5px}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:inherit;line-height:inherit}button,select{text-transform:none}[role=button]{cursor:pointer}select{word-wrap:normal}[list]::-webkit-calendar-picker-indicator{display:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button}[type=button]:not(:disabled),[type=reset]:not(:disabled),[type=submit]:not(:disabled),button:not(:disabled){cursor:pointer}::-moz-focus-inner{padding:0;border-style:none}textarea{resize:vertical}fieldset{min-width:0;padding:0;margin:0;border:0}legend{float:right;width:100%;padding:0;margin-bottom:.5rem;font-size:calc(1.275rem + .3vw);line-height:inherit}@media (min-width:1200px){legend{font-size:1.5rem}}legend+*{clear:right}::-webkit-datetime-edit-day-field,::-webkit-datetime-edit-fields-wrapper,::-webkit-datetime-edit-hour-field,::-webkit-datetime-edit-minute,::-webkit-datetime-edit-month-field,::-webkit-datetime-edit-text,::-webkit-datetime-edit-year-field{padding:0}::-webkit-inner-spin-button{height:auto}[type=search]{outline-offset:-2px;-webkit-appearance:textfield}[type=email],[type=number],[type=tel],[type=url]{direction:ltr}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-color-swatch-wrapper{padding:0}::file-selector-button{font:inherit}::-webkit-file-upload-button{font:inherit;-webkit-appearance:button}output{display:inline-block}iframe{border:0}summary{display:list-item;cursor:pointer}progress{vertical-align:baseline}[hidden]{display:none!important}
/*# sourceMappingURL=bootstrap-reboot.rtl.min.css.map */

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

4961
dist/js/bootstrap.esm.js vendored

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

261
js/dist/alert.js vendored
View file

@ -1,109 +1,16 @@
/*! /*!
* Bootstrap alert.js v5.0.0-beta1 (https://getbootstrap.com/) * Bootstrap alert.js v4.5.2 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) * Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
(function (global, factory) { (function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('./dom/data.js'), require('./dom/event-handler.js')) : typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('jquery'), require('./util.js')) :
typeof define === 'function' && define.amd ? define(['./dom/data', './dom/event-handler'], factory) : typeof define === 'function' && define.amd ? define(['jquery', './util.js'], factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Alert = factory(global.Data, global.EventHandler)); (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Alert = factory(global.jQuery, global.Util));
}(this, (function (Data, EventHandler) { 'use strict'; }(this, (function ($, Util) { 'use strict';
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; } $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;
Util = Util && Object.prototype.hasOwnProperty.call(Util, 'default') ? Util['default'] : Util;
var Data__default = /*#__PURE__*/_interopDefaultLegacy(Data);
var EventHandler__default = /*#__PURE__*/_interopDefaultLegacy(EventHandler);
/**
* --------------------------------------------------------------------------
* Bootstrap (v5.0.0-beta1): util/index.js
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* --------------------------------------------------------------------------
*/
var MILLISECONDS_MULTIPLIER = 1000;
var TRANSITION_END = 'transitionend'; // Shoutout AngusCroll (https://goo.gl/pxwQGp)
var getSelector = function getSelector(element) {
var selector = element.getAttribute('data-bs-target');
if (!selector || selector === '#') {
var hrefAttr = element.getAttribute('href');
selector = hrefAttr && hrefAttr !== '#' ? hrefAttr.trim() : null;
}
return selector;
};
var getElementFromSelector = function getElementFromSelector(element) {
var selector = getSelector(element);
return selector ? document.querySelector(selector) : null;
};
var getTransitionDurationFromElement = function getTransitionDurationFromElement(element) {
if (!element) {
return 0;
} // Get transition-duration of the element
var _window$getComputedSt = window.getComputedStyle(element),
transitionDuration = _window$getComputedSt.transitionDuration,
transitionDelay = _window$getComputedSt.transitionDelay;
var floatTransitionDuration = Number.parseFloat(transitionDuration);
var floatTransitionDelay = Number.parseFloat(transitionDelay); // Return 0 if element or transition duration is not found
if (!floatTransitionDuration && !floatTransitionDelay) {
return 0;
} // If multiple durations are defined, take the first
transitionDuration = transitionDuration.split(',')[0];
transitionDelay = transitionDelay.split(',')[0];
return (Number.parseFloat(transitionDuration) + Number.parseFloat(transitionDelay)) * MILLISECONDS_MULTIPLIER;
};
var triggerTransitionEnd = function triggerTransitionEnd(element) {
element.dispatchEvent(new Event(TRANSITION_END));
};
var emulateTransitionEnd = function emulateTransitionEnd(element, duration) {
var called = false;
var durationPadding = 5;
var emulatedDuration = duration + durationPadding;
function listener() {
called = true;
element.removeEventListener(TRANSITION_END, listener);
}
element.addEventListener(TRANSITION_END, listener);
setTimeout(function () {
if (!called) {
triggerTransitionEnd(element);
}
}, emulatedDuration);
};
var getjQuery = function getjQuery() {
var _window = window,
jQuery = _window.jQuery;
if (jQuery && !document.body.hasAttribute('data-bs-no-jquery')) {
return jQuery;
}
return null;
};
var onDOMContentLoaded = function onDOMContentLoaded(callback) {
if (document.readyState === 'loading') {
document.addEventListener('DOMContentLoaded', callback);
} else {
callback();
}
};
var isRTL = document.documentElement.dir === 'rtl';
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
@ -114,133 +21,107 @@
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
*/ */
var VERSION = '5.0.0-beta1';
var BaseComponent = /*#__PURE__*/function () {
function BaseComponent(element) {
if (!element) {
return;
}
this._element = element;
Data__default['default'].setData(element, this.constructor.DATA_KEY, this);
}
var _proto = BaseComponent.prototype;
_proto.dispose = function dispose() {
Data__default['default'].removeData(this._element, this.constructor.DATA_KEY);
this._element = null;
}
/** Static */
;
BaseComponent.getInstance = function getInstance(element) {
return Data__default['default'].getData(element, this.DATA_KEY);
};
_createClass(BaseComponent, null, [{
key: "VERSION",
get: function get() {
return VERSION;
}
}]);
return BaseComponent;
}();
function _defineProperties$1(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
function _createClass$1(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$1(Constructor.prototype, protoProps); if (staticProps) _defineProperties$1(Constructor, staticProps); return Constructor; }
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
/**
* ------------------------------------------------------------------------
* Constants
* ------------------------------------------------------------------------
*/
var NAME = 'alert'; var NAME = 'alert';
var VERSION = '4.5.2';
var DATA_KEY = 'bs.alert'; var DATA_KEY = 'bs.alert';
var EVENT_KEY = "." + DATA_KEY; var EVENT_KEY = "." + DATA_KEY;
var DATA_API_KEY = '.data-api'; var DATA_API_KEY = '.data-api';
var SELECTOR_DISMISS = '[data-bs-dismiss="alert"]'; var JQUERY_NO_CONFLICT = $.fn[NAME];
var SELECTOR_DISMISS = '[data-dismiss="alert"]';
var EVENT_CLOSE = "close" + EVENT_KEY; var EVENT_CLOSE = "close" + EVENT_KEY;
var EVENT_CLOSED = "closed" + EVENT_KEY; var EVENT_CLOSED = "closed" + EVENT_KEY;
var EVENT_CLICK_DATA_API = "click" + EVENT_KEY + DATA_API_KEY; var EVENT_CLICK_DATA_API = "click" + EVENT_KEY + DATA_API_KEY;
var CLASSNAME_ALERT = 'alert'; var CLASS_NAME_ALERT = 'alert';
var CLASSNAME_FADE = 'fade'; var CLASS_NAME_FADE = 'fade';
var CLASSNAME_SHOW = 'show'; var CLASS_NAME_SHOW = 'show';
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* Class Definition * Class Definition
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
*/ */
var Alert = /*#__PURE__*/function (_BaseComponent) { var Alert = /*#__PURE__*/function () {
_inheritsLoose(Alert, _BaseComponent); function Alert(element) {
this._element = element;
} // Getters
function Alert() {
return _BaseComponent.apply(this, arguments) || this;
}
var _proto = Alert.prototype; var _proto = Alert.prototype;
// Public // Public
_proto.close = function close(element) { _proto.close = function close(element) {
var rootElement = element ? this._getRootElement(element) : this._element; var rootElement = this._element;
if (element) {
rootElement = this._getRootElement(element);
}
var customEvent = this._triggerCloseEvent(rootElement); var customEvent = this._triggerCloseEvent(rootElement);
if (customEvent === null || customEvent.defaultPrevented) { if (customEvent.isDefaultPrevented()) {
return; return;
} }
this._removeElement(rootElement); this._removeElement(rootElement);
};
_proto.dispose = function dispose() {
$.removeData(this._element, DATA_KEY);
this._element = null;
} // Private } // Private
; ;
_proto._getRootElement = function _getRootElement(element) { _proto._getRootElement = function _getRootElement(element) {
return getElementFromSelector(element) || element.closest("." + CLASSNAME_ALERT); var selector = Util.getSelectorFromElement(element);
var parent = false;
if (selector) {
parent = document.querySelector(selector);
}
if (!parent) {
parent = $(element).closest("." + CLASS_NAME_ALERT)[0];
}
return parent;
}; };
_proto._triggerCloseEvent = function _triggerCloseEvent(element) { _proto._triggerCloseEvent = function _triggerCloseEvent(element) {
return EventHandler__default['default'].trigger(element, EVENT_CLOSE); var closeEvent = $.Event(EVENT_CLOSE);
$(element).trigger(closeEvent);
return closeEvent;
}; };
_proto._removeElement = function _removeElement(element) { _proto._removeElement = function _removeElement(element) {
var _this = this; var _this = this;
element.classList.remove(CLASSNAME_SHOW); $(element).removeClass(CLASS_NAME_SHOW);
if (!element.classList.contains(CLASSNAME_FADE)) { if (!$(element).hasClass(CLASS_NAME_FADE)) {
this._destroyElement(element); this._destroyElement(element);
return; return;
} }
var transitionDuration = getTransitionDurationFromElement(element); var transitionDuration = Util.getTransitionDurationFromElement(element);
EventHandler__default['default'].one(element, TRANSITION_END, function () { $(element).one(Util.TRANSITION_END, function (event) {
return _this._destroyElement(element); return _this._destroyElement(element, event);
}); }).emulateTransitionEnd(transitionDuration);
emulateTransitionEnd(element, transitionDuration);
}; };
_proto._destroyElement = function _destroyElement(element) { _proto._destroyElement = function _destroyElement(element) {
if (element.parentNode) { $(element).detach().trigger(EVENT_CLOSED).remove();
element.parentNode.removeChild(element);
}
EventHandler__default['default'].trigger(element, EVENT_CLOSED);
} // Static } // Static
; ;
Alert.jQueryInterface = function jQueryInterface(config) { Alert._jQueryInterface = function _jQueryInterface(config) {
return this.each(function () { return this.each(function () {
var data = Data__default['default'].getData(this, DATA_KEY); var $element = $(this);
var data = $element.data(DATA_KEY);
if (!data) { if (!data) {
data = new Alert(this); data = new Alert(this);
$element.data(DATA_KEY, data);
} }
if (config === 'close') { if (config === 'close') {
@ -249,7 +130,7 @@
}); });
}; };
Alert.handleDismiss = function handleDismiss(alertInstance) { Alert._handleDismiss = function _handleDismiss(alertInstance) {
return function (event) { return function (event) {
if (event) { if (event) {
event.preventDefault(); event.preventDefault();
@ -259,16 +140,15 @@
}; };
}; };
_createClass$1(Alert, null, [{ _createClass(Alert, null, [{
key: "DATA_KEY", key: "VERSION",
// Getters
get: function get() { get: function get() {
return DATA_KEY; return VERSION;
} }
}]); }]);
return Alert; return Alert;
}(BaseComponent); }();
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* Data Api implementation * Data Api implementation
@ -276,29 +156,20 @@
*/ */
EventHandler__default['default'].on(document, EVENT_CLICK_DATA_API, SELECTOR_DISMISS, Alert.handleDismiss(new Alert())); $(document).on(EVENT_CLICK_DATA_API, SELECTOR_DISMISS, Alert._handleDismiss(new Alert()));
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* jQuery * jQuery
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* add .Alert to jQuery only if jQuery is present
*/ */
onDOMContentLoaded(function () { $.fn[NAME] = Alert._jQueryInterface;
var $ = getjQuery(); $.fn[NAME].Constructor = Alert;
/* istanbul ignore if */
if ($) { $.fn[NAME].noConflict = function () {
var JQUERY_NO_CONFLICT = $.fn[NAME]; $.fn[NAME] = JQUERY_NO_CONFLICT;
$.fn[NAME] = Alert.jQueryInterface; return Alert._jQueryInterface;
$.fn[NAME].Constructor = Alert; };
$.fn[NAME].noConflict = function () {
$.fn[NAME] = JQUERY_NO_CONFLICT;
return Alert.jQueryInterface;
};
}
});
return Alert; return Alert;

File diff suppressed because one or more lines are too long

256
js/dist/button.js vendored
View file

@ -1,46 +1,15 @@
/*! /*!
* Bootstrap button.js v5.0.0-beta1 (https://getbootstrap.com/) * Bootstrap button.js v4.5.2 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) * Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
(function (global, factory) { (function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('./dom/data.js'), require('./dom/event-handler.js')) : typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('jquery')) :
typeof define === 'function' && define.amd ? define(['./dom/data', './dom/event-handler'], factory) : typeof define === 'function' && define.amd ? define(['jquery'], factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Button = factory(global.Data, global.EventHandler)); (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Button = factory(global.jQuery));
}(this, (function (Data, EventHandler) { 'use strict'; }(this, (function ($) { 'use strict';
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; } $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;
var Data__default = /*#__PURE__*/_interopDefaultLegacy(Data);
var EventHandler__default = /*#__PURE__*/_interopDefaultLegacy(EventHandler);
/**
* --------------------------------------------------------------------------
* Bootstrap (v5.0.0-beta1): util/index.js
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* --------------------------------------------------------------------------
*/
var getjQuery = function getjQuery() {
var _window = window,
jQuery = _window.jQuery;
if (jQuery && !document.body.hasAttribute('data-bs-no-jquery')) {
return jQuery;
}
return null;
};
var onDOMContentLoaded = function onDOMContentLoaded(callback) {
if (document.readyState === 'loading') {
document.addEventListener('DOMContentLoaded', callback);
} else {
callback();
}
};
var isRTL = document.documentElement.dir === 'rtl';
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
@ -51,87 +20,99 @@
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
*/ */
var VERSION = '5.0.0-beta1';
var BaseComponent = /*#__PURE__*/function () {
function BaseComponent(element) {
if (!element) {
return;
}
this._element = element;
Data__default['default'].setData(element, this.constructor.DATA_KEY, this);
}
var _proto = BaseComponent.prototype;
_proto.dispose = function dispose() {
Data__default['default'].removeData(this._element, this.constructor.DATA_KEY);
this._element = null;
}
/** Static */
;
BaseComponent.getInstance = function getInstance(element) {
return Data__default['default'].getData(element, this.DATA_KEY);
};
_createClass(BaseComponent, null, [{
key: "VERSION",
get: function get() {
return VERSION;
}
}]);
return BaseComponent;
}();
function _defineProperties$1(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
function _createClass$1(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$1(Constructor.prototype, protoProps); if (staticProps) _defineProperties$1(Constructor, staticProps); return Constructor; }
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
/**
* ------------------------------------------------------------------------
* Constants
* ------------------------------------------------------------------------
*/
var NAME = 'button'; var NAME = 'button';
var VERSION = '4.5.2';
var DATA_KEY = 'bs.button'; var DATA_KEY = 'bs.button';
var EVENT_KEY = "." + DATA_KEY; var EVENT_KEY = "." + DATA_KEY;
var DATA_API_KEY = '.data-api'; var DATA_API_KEY = '.data-api';
var JQUERY_NO_CONFLICT = $.fn[NAME];
var CLASS_NAME_ACTIVE = 'active'; var CLASS_NAME_ACTIVE = 'active';
var SELECTOR_DATA_TOGGLE = '[data-bs-toggle="button"]'; var CLASS_NAME_BUTTON = 'btn';
var CLASS_NAME_FOCUS = 'focus';
var SELECTOR_DATA_TOGGLE_CARROT = '[data-toggle^="button"]';
var SELECTOR_DATA_TOGGLES = '[data-toggle="buttons"]';
var SELECTOR_DATA_TOGGLE = '[data-toggle="button"]';
var SELECTOR_DATA_TOGGLES_BUTTONS = '[data-toggle="buttons"] .btn';
var SELECTOR_INPUT = 'input:not([type="hidden"])';
var SELECTOR_ACTIVE = '.active';
var SELECTOR_BUTTON = '.btn';
var EVENT_CLICK_DATA_API = "click" + EVENT_KEY + DATA_API_KEY; var EVENT_CLICK_DATA_API = "click" + EVENT_KEY + DATA_API_KEY;
var EVENT_FOCUS_BLUR_DATA_API = "focus" + EVENT_KEY + DATA_API_KEY + " " + ("blur" + EVENT_KEY + DATA_API_KEY);
var EVENT_LOAD_DATA_API = "load" + EVENT_KEY + DATA_API_KEY;
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* Class Definition * Class Definition
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
*/ */
var Button = /*#__PURE__*/function (_BaseComponent) { var Button = /*#__PURE__*/function () {
_inheritsLoose(Button, _BaseComponent); function Button(element) {
this._element = element;
} // Getters
function Button() {
return _BaseComponent.apply(this, arguments) || this;
}
var _proto = Button.prototype; var _proto = Button.prototype;
// Public // Public
_proto.toggle = function toggle() { _proto.toggle = function toggle() {
// Toggle class and sync the `aria-pressed` attribute with the return value of the `.toggle()` method var triggerChangeEvent = true;
this._element.setAttribute('aria-pressed', this._element.classList.toggle(CLASS_NAME_ACTIVE)); var addAriaPressed = true;
var rootElement = $(this._element).closest(SELECTOR_DATA_TOGGLES)[0];
if (rootElement) {
var input = this._element.querySelector(SELECTOR_INPUT);
if (input) {
if (input.type === 'radio') {
if (input.checked && this._element.classList.contains(CLASS_NAME_ACTIVE)) {
triggerChangeEvent = false;
} else {
var activeElement = rootElement.querySelector(SELECTOR_ACTIVE);
if (activeElement) {
$(activeElement).removeClass(CLASS_NAME_ACTIVE);
}
}
}
if (triggerChangeEvent) {
// if it's not a radio button or checkbox don't add a pointless/invalid checked property to the input
if (input.type === 'checkbox' || input.type === 'radio') {
input.checked = !this._element.classList.contains(CLASS_NAME_ACTIVE);
}
$(input).trigger('change');
}
input.focus();
addAriaPressed = false;
}
}
if (!(this._element.hasAttribute('disabled') || this._element.classList.contains('disabled'))) {
if (addAriaPressed) {
this._element.setAttribute('aria-pressed', !this._element.classList.contains(CLASS_NAME_ACTIVE));
}
if (triggerChangeEvent) {
$(this._element).toggleClass(CLASS_NAME_ACTIVE);
}
}
};
_proto.dispose = function dispose() {
$.removeData(this._element, DATA_KEY);
this._element = null;
} // Static } // Static
; ;
Button.jQueryInterface = function jQueryInterface(config) { Button._jQueryInterface = function _jQueryInterface(config) {
return this.each(function () { return this.each(function () {
var data = Data__default['default'].getData(this, DATA_KEY); var data = $(this).data(DATA_KEY);
if (!data) { if (!data) {
data = new Button(this); data = new Button(this);
$(this).data(DATA_KEY, data);
} }
if (config === 'toggle') { if (config === 'toggle') {
@ -140,16 +121,15 @@
}); });
}; };
_createClass$1(Button, null, [{ _createClass(Button, null, [{
key: "DATA_KEY", key: "VERSION",
// Getters
get: function get() { get: function get() {
return DATA_KEY; return VERSION;
} }
}]); }]);
return Button; return Button;
}(BaseComponent); }();
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* Data Api implementation * Data Api implementation
@ -157,39 +137,75 @@
*/ */
EventHandler__default['default'].on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, function (event) { $(document).on(EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE_CARROT, function (event) {
event.preventDefault(); var button = event.target;
var button = event.target.closest(SELECTOR_DATA_TOGGLE); var initialButton = button;
var data = Data__default['default'].getData(button, DATA_KEY);
if (!data) { if (!$(button).hasClass(CLASS_NAME_BUTTON)) {
data = new Button(button); button = $(button).closest(SELECTOR_BUTTON)[0];
} }
data.toggle(); if (!button || button.hasAttribute('disabled') || button.classList.contains('disabled')) {
event.preventDefault(); // work around Firefox bug #1540995
} else {
var inputBtn = button.querySelector(SELECTOR_INPUT);
if (inputBtn && (inputBtn.hasAttribute('disabled') || inputBtn.classList.contains('disabled'))) {
event.preventDefault(); // work around Firefox bug #1540995
return;
}
if (initialButton.tagName !== 'LABEL' || inputBtn && inputBtn.type !== 'checkbox') {
Button._jQueryInterface.call($(button), 'toggle');
}
}
}).on(EVENT_FOCUS_BLUR_DATA_API, SELECTOR_DATA_TOGGLE_CARROT, function (event) {
var button = $(event.target).closest(SELECTOR_BUTTON)[0];
$(button).toggleClass(CLASS_NAME_FOCUS, /^focus(in)?$/.test(event.type));
});
$(window).on(EVENT_LOAD_DATA_API, function () {
// ensure correct active class is set to match the controls' actual values/states
// find all checkboxes/readio buttons inside data-toggle groups
var buttons = [].slice.call(document.querySelectorAll(SELECTOR_DATA_TOGGLES_BUTTONS));
for (var i = 0, len = buttons.length; i < len; i++) {
var button = buttons[i];
var input = button.querySelector(SELECTOR_INPUT);
if (input.checked || input.hasAttribute('checked')) {
button.classList.add(CLASS_NAME_ACTIVE);
} else {
button.classList.remove(CLASS_NAME_ACTIVE);
}
} // find all button toggles
buttons = [].slice.call(document.querySelectorAll(SELECTOR_DATA_TOGGLE));
for (var _i = 0, _len = buttons.length; _i < _len; _i++) {
var _button = buttons[_i];
if (_button.getAttribute('aria-pressed') === 'true') {
_button.classList.add(CLASS_NAME_ACTIVE);
} else {
_button.classList.remove(CLASS_NAME_ACTIVE);
}
}
}); });
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* jQuery * jQuery
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* add .Button to jQuery only if jQuery is present
*/ */
onDOMContentLoaded(function () { $.fn[NAME] = Button._jQueryInterface;
var $ = getjQuery(); $.fn[NAME].Constructor = Button;
/* istanbul ignore if */
if ($) { $.fn[NAME].noConflict = function () {
var JQUERY_NO_CONFLICT = $.fn[NAME]; $.fn[NAME] = JQUERY_NO_CONFLICT;
$.fn[NAME] = Button.jQueryInterface; return Button._jQueryInterface;
$.fn[NAME].Constructor = Button; };
$.fn[NAME].noConflict = function () {
$.fn[NAME] = JQUERY_NO_CONFLICT;
return Button.jQueryInterface;
};
}
});
return Button; return Button;

File diff suppressed because one or more lines are too long

576
js/dist/carousel.js vendored
View file

@ -1,153 +1,18 @@
/*! /*!
* Bootstrap carousel.js v5.0.0-beta1 (https://getbootstrap.com/) * Bootstrap carousel.js v4.5.2 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) * Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
(function (global, factory) { (function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('./dom/data.js'), require('./dom/event-handler.js'), require('./dom/manipulator.js'), require('./dom/selector-engine.js')) : typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('jquery'), require('./util.js')) :
typeof define === 'function' && define.amd ? define(['./dom/data', './dom/event-handler', './dom/manipulator', './dom/selector-engine'], factory) : typeof define === 'function' && define.amd ? define(['jquery', './util.js'], factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Carousel = factory(global.Data, global.EventHandler, global.Manipulator, global.SelectorEngine)); (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Carousel = factory(global.jQuery, global.Util));
}(this, (function (Data, EventHandler, Manipulator, SelectorEngine) { 'use strict'; }(this, (function ($, Util) { 'use strict';
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; } $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;
Util = Util && Object.prototype.hasOwnProperty.call(Util, 'default') ? Util['default'] : Util;
var Data__default = /*#__PURE__*/_interopDefaultLegacy(Data); function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
var EventHandler__default = /*#__PURE__*/_interopDefaultLegacy(EventHandler);
var Manipulator__default = /*#__PURE__*/_interopDefaultLegacy(Manipulator);
var SelectorEngine__default = /*#__PURE__*/_interopDefaultLegacy(SelectorEngine);
/**
* --------------------------------------------------------------------------
* Bootstrap (v5.0.0-beta1): util/index.js
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* --------------------------------------------------------------------------
*/
var MILLISECONDS_MULTIPLIER = 1000;
var TRANSITION_END = 'transitionend'; // Shoutout AngusCroll (https://goo.gl/pxwQGp)
var toType = function toType(obj) {
if (obj === null || obj === undefined) {
return "" + obj;
}
return {}.toString.call(obj).match(/\s([a-z]+)/i)[1].toLowerCase();
};
var getSelector = function getSelector(element) {
var selector = element.getAttribute('data-bs-target');
if (!selector || selector === '#') {
var hrefAttr = element.getAttribute('href');
selector = hrefAttr && hrefAttr !== '#' ? hrefAttr.trim() : null;
}
return selector;
};
var getElementFromSelector = function getElementFromSelector(element) {
var selector = getSelector(element);
return selector ? document.querySelector(selector) : null;
};
var getTransitionDurationFromElement = function getTransitionDurationFromElement(element) {
if (!element) {
return 0;
} // Get transition-duration of the element
var _window$getComputedSt = window.getComputedStyle(element),
transitionDuration = _window$getComputedSt.transitionDuration,
transitionDelay = _window$getComputedSt.transitionDelay;
var floatTransitionDuration = Number.parseFloat(transitionDuration);
var floatTransitionDelay = Number.parseFloat(transitionDelay); // Return 0 if element or transition duration is not found
if (!floatTransitionDuration && !floatTransitionDelay) {
return 0;
} // If multiple durations are defined, take the first
transitionDuration = transitionDuration.split(',')[0];
transitionDelay = transitionDelay.split(',')[0];
return (Number.parseFloat(transitionDuration) + Number.parseFloat(transitionDelay)) * MILLISECONDS_MULTIPLIER;
};
var triggerTransitionEnd = function triggerTransitionEnd(element) {
element.dispatchEvent(new Event(TRANSITION_END));
};
var isElement = function isElement(obj) {
return (obj[0] || obj).nodeType;
};
var emulateTransitionEnd = function emulateTransitionEnd(element, duration) {
var called = false;
var durationPadding = 5;
var emulatedDuration = duration + durationPadding;
function listener() {
called = true;
element.removeEventListener(TRANSITION_END, listener);
}
element.addEventListener(TRANSITION_END, listener);
setTimeout(function () {
if (!called) {
triggerTransitionEnd(element);
}
}, emulatedDuration);
};
var typeCheckConfig = function typeCheckConfig(componentName, config, configTypes) {
Object.keys(configTypes).forEach(function (property) {
var expectedTypes = configTypes[property];
var value = config[property];
var valueType = value && isElement(value) ? 'element' : toType(value);
if (!new RegExp(expectedTypes).test(valueType)) {
throw new Error(componentName.toUpperCase() + ": " + ("Option \"" + property + "\" provided type \"" + valueType + "\" ") + ("but expected type \"" + expectedTypes + "\"."));
}
});
};
var isVisible = function isVisible(element) {
if (!element) {
return false;
}
if (element.style && element.parentNode && element.parentNode.style) {
var elementStyle = getComputedStyle(element);
var parentNodeStyle = getComputedStyle(element.parentNode);
return elementStyle.display !== 'none' && parentNodeStyle.display !== 'none' && elementStyle.visibility !== 'hidden';
}
return false;
};
var reflow = function reflow(element) {
return element.offsetHeight;
};
var getjQuery = function getjQuery() {
var _window = window,
jQuery = _window.jQuery;
if (jQuery && !document.body.hasAttribute('data-bs-no-jquery')) {
return jQuery;
}
return null;
};
var onDOMContentLoaded = function onDOMContentLoaded(callback) {
if (document.readyState === 'loading') {
document.addEventListener('DOMContentLoaded', callback);
} else {
callback();
}
};
var isRTL = document.documentElement.dir === 'rtl';
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
@ -158,60 +23,16 @@
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
*/ */
var VERSION = '5.0.0-beta1';
var BaseComponent = /*#__PURE__*/function () {
function BaseComponent(element) {
if (!element) {
return;
}
this._element = element;
Data__default['default'].setData(element, this.constructor.DATA_KEY, this);
}
var _proto = BaseComponent.prototype;
_proto.dispose = function dispose() {
Data__default['default'].removeData(this._element, this.constructor.DATA_KEY);
this._element = null;
}
/** Static */
;
BaseComponent.getInstance = function getInstance(element) {
return Data__default['default'].getData(element, this.DATA_KEY);
};
_createClass(BaseComponent, null, [{
key: "VERSION",
get: function get() {
return VERSION;
}
}]);
return BaseComponent;
}();
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
function _defineProperties$1(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
function _createClass$1(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$1(Constructor.prototype, protoProps); if (staticProps) _defineProperties$1(Constructor, staticProps); return Constructor; }
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
/**
* ------------------------------------------------------------------------
* Constants
* ------------------------------------------------------------------------
*/
var NAME = 'carousel'; var NAME = 'carousel';
var VERSION = '4.5.2';
var DATA_KEY = 'bs.carousel'; var DATA_KEY = 'bs.carousel';
var EVENT_KEY = "." + DATA_KEY; var EVENT_KEY = "." + DATA_KEY;
var DATA_API_KEY = '.data-api'; var DATA_API_KEY = '.data-api';
var ARROW_LEFT_KEY = 'ArrowLeft'; var JQUERY_NO_CONFLICT = $.fn[NAME];
var ARROW_RIGHT_KEY = 'ArrowRight'; var ARROW_LEFT_KEYCODE = 37; // KeyboardEvent.which value for left arrow key
var ARROW_RIGHT_KEYCODE = 39; // KeyboardEvent.which value for right arrow key
var TOUCHEVENT_COMPAT_WAIT = 500; // Time for mouse compat events to fire after touch var TOUCHEVENT_COMPAT_WAIT = 500; // Time for mouse compat events to fire after touch
var SWIPE_THRESHOLD = 40; var SWIPE_THRESHOLD = 40;
@ -251,8 +72,8 @@
var CLASS_NAME_CAROUSEL = 'carousel'; var CLASS_NAME_CAROUSEL = 'carousel';
var CLASS_NAME_ACTIVE = 'active'; var CLASS_NAME_ACTIVE = 'active';
var CLASS_NAME_SLIDE = 'slide'; var CLASS_NAME_SLIDE = 'slide';
var CLASS_NAME_END = 'carousel-item-end'; var CLASS_NAME_RIGHT = 'carousel-item-right';
var CLASS_NAME_START = 'carousel-item-start'; var CLASS_NAME_LEFT = 'carousel-item-left';
var CLASS_NAME_NEXT = 'carousel-item-next'; var CLASS_NAME_NEXT = 'carousel-item-next';
var CLASS_NAME_PREV = 'carousel-item-prev'; var CLASS_NAME_PREV = 'carousel-item-prev';
var CLASS_NAME_POINTER_EVENT = 'pointer-event'; var CLASS_NAME_POINTER_EVENT = 'pointer-event';
@ -262,8 +83,8 @@
var SELECTOR_ITEM_IMG = '.carousel-item img'; var SELECTOR_ITEM_IMG = '.carousel-item img';
var SELECTOR_NEXT_PREV = '.carousel-item-next, .carousel-item-prev'; var SELECTOR_NEXT_PREV = '.carousel-item-next, .carousel-item-prev';
var SELECTOR_INDICATORS = '.carousel-indicators'; var SELECTOR_INDICATORS = '.carousel-indicators';
var SELECTOR_DATA_SLIDE = '[data-bs-slide], [data-bs-slide-to]'; var SELECTOR_DATA_SLIDE = '[data-slide], [data-slide-to]';
var SELECTOR_DATA_RIDE = '[data-bs-ride="carousel"]'; var SELECTOR_DATA_RIDE = '[data-ride="carousel"]';
var PointerType = { var PointerType = {
TOUCH: 'touch', TOUCH: 'touch',
PEN: 'pen' PEN: 'pen'
@ -274,29 +95,23 @@
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
*/ */
var Carousel = /*#__PURE__*/function (_BaseComponent) { var Carousel = /*#__PURE__*/function () {
_inheritsLoose(Carousel, _BaseComponent);
function Carousel(element, config) { function Carousel(element, config) {
var _this; this._items = null;
this._interval = null;
this._activeElement = null;
this._isPaused = false;
this._isSliding = false;
this.touchTimeout = null;
this.touchStartX = 0;
this.touchDeltaX = 0;
this._config = this._getConfig(config);
this._element = element;
this._indicatorsElement = this._element.querySelector(SELECTOR_INDICATORS);
this._touchSupported = 'ontouchstart' in document.documentElement || navigator.maxTouchPoints > 0;
this._pointerEvent = Boolean(window.PointerEvent || window.MSPointerEvent);
_this = _BaseComponent.call(this, element) || this; this._addEventListeners();
_this._items = null;
_this._interval = null;
_this._activeElement = null;
_this._isPaused = false;
_this._isSliding = false;
_this.touchTimeout = null;
_this.touchStartX = 0;
_this.touchDeltaX = 0;
_this._config = _this._getConfig(config);
_this._indicatorsElement = SelectorEngine__default['default'].findOne(SELECTOR_INDICATORS, _this._element);
_this._touchSupported = 'ontouchstart' in document.documentElement || navigator.maxTouchPoints > 0;
_this._pointerEvent = Boolean(window.PointerEvent);
_this._addEventListeners();
return _this;
} // Getters } // Getters
@ -312,7 +127,7 @@
_proto.nextWhenVisible = function nextWhenVisible() { _proto.nextWhenVisible = function nextWhenVisible() {
// Don't call next when the page isn't visible // Don't call next when the page isn't visible
// or the carousel or its parent isn't visible // or the carousel or its parent isn't visible
if (!document.hidden && isVisible(this._element)) { if (!document.hidden && $(this._element).is(':visible') && $(this._element).css('visibility') !== 'hidden') {
this.next(); this.next();
} }
}; };
@ -328,8 +143,8 @@
this._isPaused = true; this._isPaused = true;
} }
if (SelectorEngine__default['default'].findOne(SELECTOR_NEXT_PREV, this._element)) { if (this._element.querySelector(SELECTOR_NEXT_PREV)) {
triggerTransitionEnd(this._element); Util.triggerTransitionEnd(this._element);
this.cycle(true); this.cycle(true);
} }
@ -347,17 +162,15 @@
this._interval = null; this._interval = null;
} }
if (this._config && this._config.interval && !this._isPaused) { if (this._config.interval && !this._isPaused) {
this._updateInterval();
this._interval = setInterval((document.visibilityState ? this.nextWhenVisible : this.next).bind(this), this._config.interval); this._interval = setInterval((document.visibilityState ? this.nextWhenVisible : this.next).bind(this), this._config.interval);
} }
}; };
_proto.to = function to(index) { _proto.to = function to(index) {
var _this2 = this; var _this = this;
this._activeElement = SelectorEngine__default['default'].findOne(SELECTOR_ACTIVE_ITEM, this._element); this._activeElement = this._element.querySelector(SELECTOR_ACTIVE_ITEM);
var activeIndex = this._getItemIndex(this._activeElement); var activeIndex = this._getItemIndex(this._activeElement);
@ -366,8 +179,8 @@
} }
if (this._isSliding) { if (this._isSliding) {
EventHandler__default['default'].one(this._element, EVENT_SLID, function () { $(this._element).one(EVENT_SLID, function () {
return _this2.to(index); return _this.to(index);
}); });
return; return;
} }
@ -384,11 +197,11 @@
}; };
_proto.dispose = function dispose() { _proto.dispose = function dispose() {
_BaseComponent.prototype.dispose.call(this); $(this._element).off(EVENT_KEY);
$.removeData(this._element, DATA_KEY);
EventHandler__default['default'].off(this._element, EVENT_KEY);
this._items = null; this._items = null;
this._config = null; this._config = null;
this._element = null;
this._interval = null; this._interval = null;
this._isPaused = null; this._isPaused = null;
this._isSliding = null; this._isSliding = null;
@ -399,7 +212,7 @@
_proto._getConfig = function _getConfig(config) { _proto._getConfig = function _getConfig(config) {
config = _extends({}, Default, config); config = _extends({}, Default, config);
typeCheckConfig(NAME, config, DefaultType); Util.typeCheckConfig(NAME, config, DefaultType);
return config; return config;
}; };
@ -424,56 +237,59 @@
}; };
_proto._addEventListeners = function _addEventListeners() { _proto._addEventListeners = function _addEventListeners() {
var _this3 = this; var _this2 = this;
if (this._config.keyboard) { if (this._config.keyboard) {
EventHandler__default['default'].on(this._element, EVENT_KEYDOWN, function (event) { $(this._element).on(EVENT_KEYDOWN, function (event) {
return _this3._keydown(event); return _this2._keydown(event);
}); });
} }
if (this._config.pause === 'hover') { if (this._config.pause === 'hover') {
EventHandler__default['default'].on(this._element, EVENT_MOUSEENTER, function (event) { $(this._element).on(EVENT_MOUSEENTER, function (event) {
return _this3.pause(event); return _this2.pause(event);
}); }).on(EVENT_MOUSELEAVE, function (event) {
EventHandler__default['default'].on(this._element, EVENT_MOUSELEAVE, function (event) { return _this2.cycle(event);
return _this3.cycle(event);
}); });
} }
if (this._config.touch && this._touchSupported) { if (this._config.touch) {
this._addTouchEventListeners(); this._addTouchEventListeners();
} }
}; };
_proto._addTouchEventListeners = function _addTouchEventListeners() { _proto._addTouchEventListeners = function _addTouchEventListeners() {
var _this4 = this; var _this3 = this;
if (!this._touchSupported) {
return;
}
var start = function start(event) { var start = function start(event) {
if (_this4._pointerEvent && PointerType[event.pointerType.toUpperCase()]) { if (_this3._pointerEvent && PointerType[event.originalEvent.pointerType.toUpperCase()]) {
_this4.touchStartX = event.clientX; _this3.touchStartX = event.originalEvent.clientX;
} else if (!_this4._pointerEvent) { } else if (!_this3._pointerEvent) {
_this4.touchStartX = event.touches[0].clientX; _this3.touchStartX = event.originalEvent.touches[0].clientX;
} }
}; };
var move = function move(event) { var move = function move(event) {
// ensure swiping with one touch and not pinching // ensure swiping with one touch and not pinching
if (event.touches && event.touches.length > 1) { if (event.originalEvent.touches && event.originalEvent.touches.length > 1) {
_this4.touchDeltaX = 0; _this3.touchDeltaX = 0;
} else { } else {
_this4.touchDeltaX = event.touches[0].clientX - _this4.touchStartX; _this3.touchDeltaX = event.originalEvent.touches[0].clientX - _this3.touchStartX;
} }
}; };
var end = function end(event) { var end = function end(event) {
if (_this4._pointerEvent && PointerType[event.pointerType.toUpperCase()]) { if (_this3._pointerEvent && PointerType[event.originalEvent.pointerType.toUpperCase()]) {
_this4.touchDeltaX = event.clientX - _this4.touchStartX; _this3.touchDeltaX = event.originalEvent.clientX - _this3.touchStartX;
} }
_this4._handleSwipe(); _this3._handleSwipe();
if (_this4._config.pause === 'hover') { if (_this3._config.pause === 'hover') {
// If it's a touch-enabled device, mouseenter/leave are fired as // If it's a touch-enabled device, mouseenter/leave are fired as
// part of the mouse compatibility events on first tap - the carousel // part of the mouse compatibility events on first tap - the carousel
// would stop cycling until user tapped out of it; // would stop cycling until user tapped out of it;
@ -481,41 +297,39 @@
// (as if it's the second time we tap on it, mouseenter compat event // (as if it's the second time we tap on it, mouseenter compat event
// is NOT fired) and after a timeout (to allow for mouse compatibility // is NOT fired) and after a timeout (to allow for mouse compatibility
// events to fire) we explicitly restart cycling // events to fire) we explicitly restart cycling
_this4.pause(); _this3.pause();
if (_this4.touchTimeout) { if (_this3.touchTimeout) {
clearTimeout(_this4.touchTimeout); clearTimeout(_this3.touchTimeout);
} }
_this4.touchTimeout = setTimeout(function (event) { _this3.touchTimeout = setTimeout(function (event) {
return _this4.cycle(event); return _this3.cycle(event);
}, TOUCHEVENT_COMPAT_WAIT + _this4._config.interval); }, TOUCHEVENT_COMPAT_WAIT + _this3._config.interval);
} }
}; };
SelectorEngine__default['default'].find(SELECTOR_ITEM_IMG, this._element).forEach(function (itemImg) { $(this._element.querySelectorAll(SELECTOR_ITEM_IMG)).on(EVENT_DRAG_START, function (e) {
EventHandler__default['default'].on(itemImg, EVENT_DRAG_START, function (e) { return e.preventDefault();
return e.preventDefault();
});
}); });
if (this._pointerEvent) { if (this._pointerEvent) {
EventHandler__default['default'].on(this._element, EVENT_POINTERDOWN, function (event) { $(this._element).on(EVENT_POINTERDOWN, function (event) {
return start(event); return start(event);
}); });
EventHandler__default['default'].on(this._element, EVENT_POINTERUP, function (event) { $(this._element).on(EVENT_POINTERUP, function (event) {
return end(event); return end(event);
}); });
this._element.classList.add(CLASS_NAME_POINTER_EVENT); this._element.classList.add(CLASS_NAME_POINTER_EVENT);
} else { } else {
EventHandler__default['default'].on(this._element, EVENT_TOUCHSTART, function (event) { $(this._element).on(EVENT_TOUCHSTART, function (event) {
return start(event); return start(event);
}); });
EventHandler__default['default'].on(this._element, EVENT_TOUCHMOVE, function (event) { $(this._element).on(EVENT_TOUCHMOVE, function (event) {
return move(event); return move(event);
}); });
EventHandler__default['default'].on(this._element, EVENT_TOUCHEND, function (event) { $(this._element).on(EVENT_TOUCHEND, function (event) {
return end(event); return end(event);
}); });
} }
@ -526,13 +340,13 @@
return; return;
} }
switch (event.key) { switch (event.which) {
case ARROW_LEFT_KEY: case ARROW_LEFT_KEYCODE:
event.preventDefault(); event.preventDefault();
this.prev(); this.prev();
break; break;
case ARROW_RIGHT_KEY: case ARROW_RIGHT_KEYCODE:
event.preventDefault(); event.preventDefault();
this.next(); this.next();
break; break;
@ -540,7 +354,7 @@
}; };
_proto._getItemIndex = function _getItemIndex(element) { _proto._getItemIndex = function _getItemIndex(element) {
this._items = element && element.parentNode ? SelectorEngine__default['default'].find(SELECTOR_ITEM, element.parentNode) : []; this._items = element && element.parentNode ? [].slice.call(element.parentNode.querySelectorAll(SELECTOR_ITEM)) : [];
return this._items.indexOf(element); return this._items.indexOf(element);
}; };
@ -565,53 +379,35 @@
_proto._triggerSlideEvent = function _triggerSlideEvent(relatedTarget, eventDirectionName) { _proto._triggerSlideEvent = function _triggerSlideEvent(relatedTarget, eventDirectionName) {
var targetIndex = this._getItemIndex(relatedTarget); var targetIndex = this._getItemIndex(relatedTarget);
var fromIndex = this._getItemIndex(SelectorEngine__default['default'].findOne(SELECTOR_ACTIVE_ITEM, this._element)); var fromIndex = this._getItemIndex(this._element.querySelector(SELECTOR_ACTIVE_ITEM));
return EventHandler__default['default'].trigger(this._element, EVENT_SLIDE, { var slideEvent = $.Event(EVENT_SLIDE, {
relatedTarget: relatedTarget, relatedTarget: relatedTarget,
direction: eventDirectionName, direction: eventDirectionName,
from: fromIndex, from: fromIndex,
to: targetIndex to: targetIndex
}); });
$(this._element).trigger(slideEvent);
return slideEvent;
}; };
_proto._setActiveIndicatorElement = function _setActiveIndicatorElement(element) { _proto._setActiveIndicatorElement = function _setActiveIndicatorElement(element) {
if (this._indicatorsElement) { if (this._indicatorsElement) {
var indicators = SelectorEngine__default['default'].find(SELECTOR_ACTIVE, this._indicatorsElement); var indicators = [].slice.call(this._indicatorsElement.querySelectorAll(SELECTOR_ACTIVE));
$(indicators).removeClass(CLASS_NAME_ACTIVE);
for (var i = 0; i < indicators.length; i++) {
indicators[i].classList.remove(CLASS_NAME_ACTIVE);
}
var nextIndicator = this._indicatorsElement.children[this._getItemIndex(element)]; var nextIndicator = this._indicatorsElement.children[this._getItemIndex(element)];
if (nextIndicator) { if (nextIndicator) {
nextIndicator.classList.add(CLASS_NAME_ACTIVE); $(nextIndicator).addClass(CLASS_NAME_ACTIVE);
} }
} }
}; };
_proto._updateInterval = function _updateInterval() {
var element = this._activeElement || SelectorEngine__default['default'].findOne(SELECTOR_ACTIVE_ITEM, this._element);
if (!element) {
return;
}
var elementInterval = Number.parseInt(element.getAttribute('data-bs-interval'), 10);
if (elementInterval) {
this._config.defaultInterval = this._config.defaultInterval || this._config.interval;
this._config.interval = elementInterval;
} else {
this._config.interval = this._config.defaultInterval || this._config.interval;
}
};
_proto._slide = function _slide(direction, element) { _proto._slide = function _slide(direction, element) {
var _this5 = this; var _this4 = this;
var activeElement = SelectorEngine__default['default'].findOne(SELECTOR_ACTIVE_ITEM, this._element); var activeElement = this._element.querySelector(SELECTOR_ACTIVE_ITEM);
var activeElementIndex = this._getItemIndex(activeElement); var activeElementIndex = this._getItemIndex(activeElement);
@ -625,23 +421,23 @@
var eventDirectionName; var eventDirectionName;
if (direction === DIRECTION_NEXT) { if (direction === DIRECTION_NEXT) {
directionalClassName = CLASS_NAME_START; directionalClassName = CLASS_NAME_LEFT;
orderClassName = CLASS_NAME_NEXT; orderClassName = CLASS_NAME_NEXT;
eventDirectionName = DIRECTION_LEFT; eventDirectionName = DIRECTION_LEFT;
} else { } else {
directionalClassName = CLASS_NAME_END; directionalClassName = CLASS_NAME_RIGHT;
orderClassName = CLASS_NAME_PREV; orderClassName = CLASS_NAME_PREV;
eventDirectionName = DIRECTION_RIGHT; eventDirectionName = DIRECTION_RIGHT;
} }
if (nextElement && nextElement.classList.contains(CLASS_NAME_ACTIVE)) { if (nextElement && $(nextElement).hasClass(CLASS_NAME_ACTIVE)) {
this._isSliding = false; this._isSliding = false;
return; return;
} }
var slideEvent = this._triggerSlideEvent(nextElement, eventDirectionName); var slideEvent = this._triggerSlideEvent(nextElement, eventDirectionName);
if (slideEvent.defaultPrevented) { if (slideEvent.isDefaultPrevented()) {
return; return;
} }
@ -658,39 +454,41 @@
this._setActiveIndicatorElement(nextElement); this._setActiveIndicatorElement(nextElement);
this._activeElement = nextElement; var slidEvent = $.Event(EVENT_SLID, {
relatedTarget: nextElement,
direction: eventDirectionName,
from: activeElementIndex,
to: nextElementIndex
});
if (this._element.classList.contains(CLASS_NAME_SLIDE)) { if ($(this._element).hasClass(CLASS_NAME_SLIDE)) {
nextElement.classList.add(orderClassName); $(nextElement).addClass(orderClassName);
reflow(nextElement); Util.reflow(nextElement);
activeElement.classList.add(directionalClassName); $(activeElement).addClass(directionalClassName);
nextElement.classList.add(directionalClassName); $(nextElement).addClass(directionalClassName);
var transitionDuration = getTransitionDurationFromElement(activeElement); var nextElementInterval = parseInt(nextElement.getAttribute('data-interval'), 10);
EventHandler__default['default'].one(activeElement, TRANSITION_END, function () {
nextElement.classList.remove(directionalClassName, orderClassName); if (nextElementInterval) {
nextElement.classList.add(CLASS_NAME_ACTIVE); this._config.defaultInterval = this._config.defaultInterval || this._config.interval;
activeElement.classList.remove(CLASS_NAME_ACTIVE, orderClassName, directionalClassName); this._config.interval = nextElementInterval;
_this5._isSliding = false; } else {
this._config.interval = this._config.defaultInterval || this._config.interval;
}
var transitionDuration = Util.getTransitionDurationFromElement(activeElement);
$(activeElement).one(Util.TRANSITION_END, function () {
$(nextElement).removeClass(directionalClassName + " " + orderClassName).addClass(CLASS_NAME_ACTIVE);
$(activeElement).removeClass(CLASS_NAME_ACTIVE + " " + orderClassName + " " + directionalClassName);
_this4._isSliding = false;
setTimeout(function () { setTimeout(function () {
EventHandler__default['default'].trigger(_this5._element, EVENT_SLID, { return $(_this4._element).trigger(slidEvent);
relatedTarget: nextElement,
direction: eventDirectionName,
from: activeElementIndex,
to: nextElementIndex
});
}, 0); }, 0);
}); }).emulateTransitionEnd(transitionDuration);
emulateTransitionEnd(activeElement, transitionDuration);
} else { } else {
activeElement.classList.remove(CLASS_NAME_ACTIVE); $(activeElement).removeClass(CLASS_NAME_ACTIVE);
nextElement.classList.add(CLASS_NAME_ACTIVE); $(nextElement).addClass(CLASS_NAME_ACTIVE);
this._isSliding = false; this._isSliding = false;
EventHandler__default['default'].trigger(this._element, EVENT_SLID, { $(this._element).trigger(slidEvent);
relatedTarget: nextElement,
direction: eventDirectionName,
from: activeElementIndex,
to: nextElementIndex
});
} }
if (isCycling) { if (isCycling) {
@ -699,79 +497,82 @@
} // Static } // Static
; ;
Carousel.carouselInterface = function carouselInterface(element, config) { Carousel._jQueryInterface = function _jQueryInterface(config) {
var data = Data__default['default'].getData(element, DATA_KEY); return this.each(function () {
var data = $(this).data(DATA_KEY);
var _config = _extends({}, Default, Manipulator__default['default'].getDataAttributes(element)); var _config = _extends({}, Default, $(this).data());
if (typeof config === 'object') { if (typeof config === 'object') {
_config = _extends({}, _config, config); _config = _extends({}, _config, config);
}
var action = typeof config === 'string' ? config : _config.slide;
if (!data) {
data = new Carousel(element, _config);
}
if (typeof config === 'number') {
data.to(config);
} else if (typeof action === 'string') {
if (typeof data[action] === 'undefined') {
throw new TypeError("No method named \"" + action + "\"");
} }
data[action](); var action = typeof config === 'string' ? config : _config.slide;
} else if (_config.interval && _config.ride) {
data.pause();
data.cycle();
}
};
Carousel.jQueryInterface = function jQueryInterface(config) { if (!data) {
return this.each(function () { data = new Carousel(this, _config);
Carousel.carouselInterface(this, config); $(this).data(DATA_KEY, data);
}
if (typeof config === 'number') {
data.to(config);
} else if (typeof action === 'string') {
if (typeof data[action] === 'undefined') {
throw new TypeError("No method named \"" + action + "\"");
}
data[action]();
} else if (_config.interval && _config.ride) {
data.pause();
data.cycle();
}
}); });
}; };
Carousel.dataApiClickHandler = function dataApiClickHandler(event) { Carousel._dataApiClickHandler = function _dataApiClickHandler(event) {
var target = getElementFromSelector(this); var selector = Util.getSelectorFromElement(this);
if (!target || !target.classList.contains(CLASS_NAME_CAROUSEL)) { if (!selector) {
return; return;
} }
var config = _extends({}, Manipulator__default['default'].getDataAttributes(target), Manipulator__default['default'].getDataAttributes(this)); var target = $(selector)[0];
var slideIndex = this.getAttribute('data-bs-slide-to'); if (!target || !$(target).hasClass(CLASS_NAME_CAROUSEL)) {
return;
}
var config = _extends({}, $(target).data(), $(this).data());
var slideIndex = this.getAttribute('data-slide-to');
if (slideIndex) { if (slideIndex) {
config.interval = false; config.interval = false;
} }
Carousel.carouselInterface(target, config); Carousel._jQueryInterface.call($(target), config);
if (slideIndex) { if (slideIndex) {
Data__default['default'].getData(target, DATA_KEY).to(slideIndex); $(target).data(DATA_KEY).to(slideIndex);
} }
event.preventDefault(); event.preventDefault();
}; };
_createClass$1(Carousel, null, [{ _createClass(Carousel, null, [{
key: "VERSION",
get: function get() {
return VERSION;
}
}, {
key: "Default", key: "Default",
get: function get() { get: function get() {
return Default; return Default;
} }
}, {
key: "DATA_KEY",
get: function get() {
return DATA_KEY;
}
}]); }]);
return Carousel; return Carousel;
}(BaseComponent); }();
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* Data Api implementation * Data Api implementation
@ -779,36 +580,29 @@
*/ */
EventHandler__default['default'].on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_SLIDE, Carousel.dataApiClickHandler); $(document).on(EVENT_CLICK_DATA_API, SELECTOR_DATA_SLIDE, Carousel._dataApiClickHandler);
EventHandler__default['default'].on(window, EVENT_LOAD_DATA_API, function () { $(window).on(EVENT_LOAD_DATA_API, function () {
var carousels = SelectorEngine__default['default'].find(SELECTOR_DATA_RIDE); var carousels = [].slice.call(document.querySelectorAll(SELECTOR_DATA_RIDE));
for (var i = 0, len = carousels.length; i < len; i++) { for (var i = 0, len = carousels.length; i < len; i++) {
Carousel.carouselInterface(carousels[i], Data__default['default'].getData(carousels[i], DATA_KEY)); var $carousel = $(carousels[i]);
Carousel._jQueryInterface.call($carousel, $carousel.data());
} }
}); });
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* jQuery * jQuery
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* add .Carousel to jQuery only if jQuery is present
*/ */
onDOMContentLoaded(function () { $.fn[NAME] = Carousel._jQueryInterface;
var $ = getjQuery(); $.fn[NAME].Constructor = Carousel;
/* istanbul ignore if */
if ($) { $.fn[NAME].noConflict = function () {
var JQUERY_NO_CONFLICT = $.fn[NAME]; $.fn[NAME] = JQUERY_NO_CONFLICT;
$.fn[NAME] = Carousel.jQueryInterface; return Carousel._jQueryInterface;
$.fn[NAME].Constructor = Carousel; };
$.fn[NAME].noConflict = function () {
$.fn[NAME] = JQUERY_NO_CONFLICT;
return Carousel.jQueryInterface;
};
}
});
return Carousel; return Carousel;

File diff suppressed because one or more lines are too long

507
js/dist/collapse.js vendored
View file

@ -1,149 +1,18 @@
/*! /*!
* Bootstrap collapse.js v5.0.0-beta1 (https://getbootstrap.com/) * Bootstrap collapse.js v4.5.2 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) * Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/ */
(function (global, factory) { (function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('./dom/data.js'), require('./dom/event-handler.js'), require('./dom/manipulator.js'), require('./dom/selector-engine.js')) : typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('jquery'), require('./util.js')) :
typeof define === 'function' && define.amd ? define(['./dom/data', './dom/event-handler', './dom/manipulator', './dom/selector-engine'], factory) : typeof define === 'function' && define.amd ? define(['jquery', './util.js'], factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Collapse = factory(global.Data, global.EventHandler, global.Manipulator, global.SelectorEngine)); (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Collapse = factory(global.jQuery, global.Util));
}(this, (function (Data, EventHandler, Manipulator, SelectorEngine) { 'use strict'; }(this, (function ($, Util) { 'use strict';
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; } $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $;
Util = Util && Object.prototype.hasOwnProperty.call(Util, 'default') ? Util['default'] : Util;
var Data__default = /*#__PURE__*/_interopDefaultLegacy(Data); function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
var EventHandler__default = /*#__PURE__*/_interopDefaultLegacy(EventHandler);
var Manipulator__default = /*#__PURE__*/_interopDefaultLegacy(Manipulator);
var SelectorEngine__default = /*#__PURE__*/_interopDefaultLegacy(SelectorEngine);
/**
* --------------------------------------------------------------------------
* Bootstrap (v5.0.0-beta1): util/index.js
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* --------------------------------------------------------------------------
*/
var MILLISECONDS_MULTIPLIER = 1000;
var TRANSITION_END = 'transitionend'; // Shoutout AngusCroll (https://goo.gl/pxwQGp)
var toType = function toType(obj) {
if (obj === null || obj === undefined) {
return "" + obj;
}
return {}.toString.call(obj).match(/\s([a-z]+)/i)[1].toLowerCase();
};
var getSelector = function getSelector(element) {
var selector = element.getAttribute('data-bs-target');
if (!selector || selector === '#') {
var hrefAttr = element.getAttribute('href');
selector = hrefAttr && hrefAttr !== '#' ? hrefAttr.trim() : null;
}
return selector;
};
var getSelectorFromElement = function getSelectorFromElement(element) {
var selector = getSelector(element);
if (selector) {
return document.querySelector(selector) ? selector : null;
}
return null;
};
var getElementFromSelector = function getElementFromSelector(element) {
var selector = getSelector(element);
return selector ? document.querySelector(selector) : null;
};
var getTransitionDurationFromElement = function getTransitionDurationFromElement(element) {
if (!element) {
return 0;
} // Get transition-duration of the element
var _window$getComputedSt = window.getComputedStyle(element),
transitionDuration = _window$getComputedSt.transitionDuration,
transitionDelay = _window$getComputedSt.transitionDelay;
var floatTransitionDuration = Number.parseFloat(transitionDuration);
var floatTransitionDelay = Number.parseFloat(transitionDelay); // Return 0 if element or transition duration is not found
if (!floatTransitionDuration && !floatTransitionDelay) {
return 0;
} // If multiple durations are defined, take the first
transitionDuration = transitionDuration.split(',')[0];
transitionDelay = transitionDelay.split(',')[0];
return (Number.parseFloat(transitionDuration) + Number.parseFloat(transitionDelay)) * MILLISECONDS_MULTIPLIER;
};
var triggerTransitionEnd = function triggerTransitionEnd(element) {
element.dispatchEvent(new Event(TRANSITION_END));
};
var isElement = function isElement(obj) {
return (obj[0] || obj).nodeType;
};
var emulateTransitionEnd = function emulateTransitionEnd(element, duration) {
var called = false;
var durationPadding = 5;
var emulatedDuration = duration + durationPadding;
function listener() {
called = true;
element.removeEventListener(TRANSITION_END, listener);
}
element.addEventListener(TRANSITION_END, listener);
setTimeout(function () {
if (!called) {
triggerTransitionEnd(element);
}
}, emulatedDuration);
};
var typeCheckConfig = function typeCheckConfig(componentName, config, configTypes) {
Object.keys(configTypes).forEach(function (property) {
var expectedTypes = configTypes[property];
var value = config[property];
var valueType = value && isElement(value) ? 'element' : toType(value);
if (!new RegExp(expectedTypes).test(valueType)) {
throw new Error(componentName.toUpperCase() + ": " + ("Option \"" + property + "\" provided type \"" + valueType + "\" ") + ("but expected type \"" + expectedTypes + "\"."));
}
});
};
var reflow = function reflow(element) {
return element.offsetHeight;
};
var getjQuery = function getjQuery() {
var _window = window,
jQuery = _window.jQuery;
if (jQuery && !document.body.hasAttribute('data-bs-no-jquery')) {
return jQuery;
}
return null;
};
var onDOMContentLoaded = function onDOMContentLoaded(callback) {
if (document.readyState === 'loading') {
document.addEventListener('DOMContentLoaded', callback);
} else {
callback();
}
};
var isRTL = document.documentElement.dir === 'rtl';
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
@ -154,58 +23,12 @@
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
*/ */
var VERSION = '5.0.0-beta1';
var BaseComponent = /*#__PURE__*/function () {
function BaseComponent(element) {
if (!element) {
return;
}
this._element = element;
Data__default['default'].setData(element, this.constructor.DATA_KEY, this);
}
var _proto = BaseComponent.prototype;
_proto.dispose = function dispose() {
Data__default['default'].removeData(this._element, this.constructor.DATA_KEY);
this._element = null;
}
/** Static */
;
BaseComponent.getInstance = function getInstance(element) {
return Data__default['default'].getData(element, this.DATA_KEY);
};
_createClass(BaseComponent, null, [{
key: "VERSION",
get: function get() {
return VERSION;
}
}]);
return BaseComponent;
}();
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
function _defineProperties$1(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
function _createClass$1(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$1(Constructor.prototype, protoProps); if (staticProps) _defineProperties$1(Constructor, staticProps); return Constructor; }
function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype); subClass.prototype.constructor = subClass; subClass.__proto__ = superClass; }
/**
* ------------------------------------------------------------------------
* Constants
* ------------------------------------------------------------------------
*/
var NAME = 'collapse'; var NAME = 'collapse';
var VERSION = '4.5.2';
var DATA_KEY = 'bs.collapse'; var DATA_KEY = 'bs.collapse';
var EVENT_KEY = "." + DATA_KEY; var EVENT_KEY = "." + DATA_KEY;
var DATA_API_KEY = '.data-api'; var DATA_API_KEY = '.data-api';
var JQUERY_NO_CONFLICT = $.fn[NAME];
var Default = { var Default = {
toggle: true, toggle: true,
parent: '' parent: ''
@ -223,53 +46,47 @@
var CLASS_NAME_COLLAPSE = 'collapse'; var CLASS_NAME_COLLAPSE = 'collapse';
var CLASS_NAME_COLLAPSING = 'collapsing'; var CLASS_NAME_COLLAPSING = 'collapsing';
var CLASS_NAME_COLLAPSED = 'collapsed'; var CLASS_NAME_COLLAPSED = 'collapsed';
var WIDTH = 'width'; var DIMENSION_WIDTH = 'width';
var HEIGHT = 'height'; var DIMENSION_HEIGHT = 'height';
var SELECTOR_ACTIVES = '.show, .collapsing'; var SELECTOR_ACTIVES = '.show, .collapsing';
var SELECTOR_DATA_TOGGLE = '[data-bs-toggle="collapse"]'; var SELECTOR_DATA_TOGGLE = '[data-toggle="collapse"]';
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* Class Definition * Class Definition
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
*/ */
var Collapse = /*#__PURE__*/function (_BaseComponent) { var Collapse = /*#__PURE__*/function () {
_inheritsLoose(Collapse, _BaseComponent);
function Collapse(element, config) { function Collapse(element, config) {
var _this; this._isTransitioning = false;
this._element = element;
_this = _BaseComponent.call(this, element) || this; this._config = this._getConfig(config);
_this._isTransitioning = false; this._triggerArray = [].slice.call(document.querySelectorAll("[data-toggle=\"collapse\"][href=\"#" + element.id + "\"]," + ("[data-toggle=\"collapse\"][data-target=\"#" + element.id + "\"]")));
_this._config = _this._getConfig(config); var toggleList = [].slice.call(document.querySelectorAll(SELECTOR_DATA_TOGGLE));
_this._triggerArray = SelectorEngine__default['default'].find(SELECTOR_DATA_TOGGLE + "[href=\"#" + element.id + "\"]," + (SELECTOR_DATA_TOGGLE + "[data-bs-target=\"#" + element.id + "\"]"));
var toggleList = SelectorEngine__default['default'].find(SELECTOR_DATA_TOGGLE);
for (var i = 0, len = toggleList.length; i < len; i++) { for (var i = 0, len = toggleList.length; i < len; i++) {
var elem = toggleList[i]; var elem = toggleList[i];
var selector = getSelectorFromElement(elem); var selector = Util.getSelectorFromElement(elem);
var filterElement = SelectorEngine__default['default'].find(selector).filter(function (foundElem) { var filterElement = [].slice.call(document.querySelectorAll(selector)).filter(function (foundElem) {
return foundElem === element; return foundElem === element;
}); });
if (selector !== null && filterElement.length) { if (selector !== null && filterElement.length > 0) {
_this._selector = selector; this._selector = selector;
_this._triggerArray.push(elem); this._triggerArray.push(elem);
} }
} }
_this._parent = _this._config.parent ? _this._getParent() : null; this._parent = this._config.parent ? this._getParent() : null;
if (!_this._config.parent) { if (!this._config.parent) {
_this._addAriaAndCollapsedClass(_this._element, _this._triggerArray); this._addAriaAndCollapsedClass(this._element, this._triggerArray);
} }
if (_this._config.toggle) { if (this._config.toggle) {
_this.toggle(); this.toggle();
} }
return _this;
} // Getters } // Getters
@ -277,7 +94,7 @@
// Public // Public
_proto.toggle = function toggle() { _proto.toggle = function toggle() {
if (this._element.classList.contains(CLASS_NAME_SHOW)) { if ($(this._element).hasClass(CLASS_NAME_SHOW)) {
this.hide(); this.hide();
} else { } else {
this.show(); this.show();
@ -285,9 +102,9 @@
}; };
_proto.show = function show() { _proto.show = function show() {
var _this2 = this; var _this = this;
if (this._isTransitioning || this._element.classList.contains(CLASS_NAME_SHOW)) { if (this._isTransitioning || $(this._element).hasClass(CLASS_NAME_SHOW)) {
return; return;
} }
@ -295,9 +112,9 @@
var activesData; var activesData;
if (this._parent) { if (this._parent) {
actives = SelectorEngine__default['default'].find(SELECTOR_ACTIVES, this._parent).filter(function (elem) { actives = [].slice.call(this._parent.querySelectorAll(SELECTOR_ACTIVES)).filter(function (elem) {
if (typeof _this2._config.parent === 'string') { if (typeof _this._config.parent === 'string') {
return elem.getAttribute('data-bs-parent') === _this2._config.parent; return elem.getAttribute('data-parent') === _this._config.parent;
} }
return elem.classList.contains(CLASS_NAME_COLLAPSE); return elem.classList.contains(CLASS_NAME_COLLAPSE);
@ -308,106 +125,88 @@
} }
} }
var container = SelectorEngine__default['default'].findOne(this._selector);
if (actives) { if (actives) {
var tempActiveData = actives.find(function (elem) { activesData = $(actives).not(this._selector).data(DATA_KEY);
return container !== elem;
});
activesData = tempActiveData ? Data__default['default'].getData(tempActiveData, DATA_KEY) : null;
if (activesData && activesData._isTransitioning) { if (activesData && activesData._isTransitioning) {
return; return;
} }
} }
var startEvent = EventHandler__default['default'].trigger(this._element, EVENT_SHOW); var startEvent = $.Event(EVENT_SHOW);
$(this._element).trigger(startEvent);
if (startEvent.defaultPrevented) { if (startEvent.isDefaultPrevented()) {
return; return;
} }
if (actives) { if (actives) {
actives.forEach(function (elemActive) { Collapse._jQueryInterface.call($(actives).not(this._selector), 'hide');
if (container !== elemActive) {
Collapse.collapseInterface(elemActive, 'hide');
}
if (!activesData) { if (!activesData) {
Data__default['default'].setData(elemActive, DATA_KEY, null); $(actives).data(DATA_KEY, null);
} }
});
} }
var dimension = this._getDimension(); var dimension = this._getDimension();
this._element.classList.remove(CLASS_NAME_COLLAPSE); $(this._element).removeClass(CLASS_NAME_COLLAPSE).addClass(CLASS_NAME_COLLAPSING);
this._element.classList.add(CLASS_NAME_COLLAPSING);
this._element.style[dimension] = 0; this._element.style[dimension] = 0;
if (this._triggerArray.length) { if (this._triggerArray.length) {
this._triggerArray.forEach(function (element) { $(this._triggerArray).removeClass(CLASS_NAME_COLLAPSED).attr('aria-expanded', true);
element.classList.remove(CLASS_NAME_COLLAPSED);
element.setAttribute('aria-expanded', true);
});
} }
this.setTransitioning(true); this.setTransitioning(true);
var complete = function complete() { var complete = function complete() {
_this2._element.classList.remove(CLASS_NAME_COLLAPSING); $(_this._element).removeClass(CLASS_NAME_COLLAPSING).addClass(CLASS_NAME_COLLAPSE + " " + CLASS_NAME_SHOW);
_this._element.style[dimension] = '';
_this2._element.classList.add(CLASS_NAME_COLLAPSE, CLASS_NAME_SHOW); _this.setTransitioning(false);
_this2._element.style[dimension] = ''; $(_this._element).trigger(EVENT_SHOWN);
_this2.setTransitioning(false);
EventHandler__default['default'].trigger(_this2._element, EVENT_SHOWN);
}; };
var capitalizedDimension = dimension[0].toUpperCase() + dimension.slice(1); var capitalizedDimension = dimension[0].toUpperCase() + dimension.slice(1);
var scrollSize = "scroll" + capitalizedDimension; var scrollSize = "scroll" + capitalizedDimension;
var transitionDuration = getTransitionDurationFromElement(this._element); var transitionDuration = Util.getTransitionDurationFromElement(this._element);
EventHandler__default['default'].one(this._element, TRANSITION_END, complete); $(this._element).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
emulateTransitionEnd(this._element, transitionDuration);
this._element.style[dimension] = this._element[scrollSize] + "px"; this._element.style[dimension] = this._element[scrollSize] + "px";
}; };
_proto.hide = function hide() { _proto.hide = function hide() {
var _this3 = this; var _this2 = this;
if (this._isTransitioning || !this._element.classList.contains(CLASS_NAME_SHOW)) { if (this._isTransitioning || !$(this._element).hasClass(CLASS_NAME_SHOW)) {
return; return;
} }
var startEvent = EventHandler__default['default'].trigger(this._element, EVENT_HIDE); var startEvent = $.Event(EVENT_HIDE);
$(this._element).trigger(startEvent);
if (startEvent.defaultPrevented) { if (startEvent.isDefaultPrevented()) {
return; return;
} }
var dimension = this._getDimension(); var dimension = this._getDimension();
this._element.style[dimension] = this._element.getBoundingClientRect()[dimension] + "px"; this._element.style[dimension] = this._element.getBoundingClientRect()[dimension] + "px";
reflow(this._element); Util.reflow(this._element);
$(this._element).addClass(CLASS_NAME_COLLAPSING).removeClass(CLASS_NAME_COLLAPSE + " " + CLASS_NAME_SHOW);
this._element.classList.add(CLASS_NAME_COLLAPSING);
this._element.classList.remove(CLASS_NAME_COLLAPSE, CLASS_NAME_SHOW);
var triggerArrayLength = this._triggerArray.length; var triggerArrayLength = this._triggerArray.length;
if (triggerArrayLength > 0) { if (triggerArrayLength > 0) {
for (var i = 0; i < triggerArrayLength; i++) { for (var i = 0; i < triggerArrayLength; i++) {
var trigger = this._triggerArray[i]; var trigger = this._triggerArray[i];
var elem = getElementFromSelector(trigger); var selector = Util.getSelectorFromElement(trigger);
if (elem && !elem.classList.contains(CLASS_NAME_SHOW)) { if (selector !== null) {
trigger.classList.add(CLASS_NAME_COLLAPSED); var $elem = $([].slice.call(document.querySelectorAll(selector)));
trigger.setAttribute('aria-expanded', false);
if (!$elem.hasClass(CLASS_NAME_SHOW)) {
$(trigger).addClass(CLASS_NAME_COLLAPSED).attr('aria-expanded', false);
}
} }
} }
} }
@ -415,19 +214,14 @@
this.setTransitioning(true); this.setTransitioning(true);
var complete = function complete() { var complete = function complete() {
_this3.setTransitioning(false); _this2.setTransitioning(false);
_this3._element.classList.remove(CLASS_NAME_COLLAPSING); $(_this2._element).removeClass(CLASS_NAME_COLLAPSING).addClass(CLASS_NAME_COLLAPSE).trigger(EVENT_HIDDEN);
_this3._element.classList.add(CLASS_NAME_COLLAPSE);
EventHandler__default['default'].trigger(_this3._element, EVENT_HIDDEN);
}; };
this._element.style[dimension] = ''; this._element.style[dimension] = '';
var transitionDuration = getTransitionDurationFromElement(this._element); var transitionDuration = Util.getTransitionDurationFromElement(this._element);
EventHandler__default['default'].one(this._element, TRANSITION_END, complete); $(this._element).one(Util.TRANSITION_END, complete).emulateTransitionEnd(transitionDuration);
emulateTransitionEnd(this._element, transitionDuration);
}; };
_proto.setTransitioning = function setTransitioning(isTransitioning) { _proto.setTransitioning = function setTransitioning(isTransitioning) {
@ -435,10 +229,10 @@
}; };
_proto.dispose = function dispose() { _proto.dispose = function dispose() {
_BaseComponent.prototype.dispose.call(this); $.removeData(this._element, DATA_KEY);
this._config = null; this._config = null;
this._parent = null; this._parent = null;
this._element = null;
this._triggerArray = null; this._triggerArray = null;
this._isTransitioning = null; this._isTransitioning = null;
} // Private } // Private
@ -448,97 +242,92 @@
config = _extends({}, Default, config); config = _extends({}, Default, config);
config.toggle = Boolean(config.toggle); // Coerce string values config.toggle = Boolean(config.toggle); // Coerce string values
typeCheckConfig(NAME, config, DefaultType); Util.typeCheckConfig(NAME, config, DefaultType);
return config; return config;
}; };
_proto._getDimension = function _getDimension() { _proto._getDimension = function _getDimension() {
return this._element.classList.contains(WIDTH) ? WIDTH : HEIGHT; var hasWidth = $(this._element).hasClass(DIMENSION_WIDTH);
return hasWidth ? DIMENSION_WIDTH : DIMENSION_HEIGHT;
}; };
_proto._getParent = function _getParent() { _proto._getParent = function _getParent() {
var _this4 = this; var _this3 = this;
var parent = this._config.parent; var parent;
if (isElement(parent)) { if (Util.isElement(this._config.parent)) {
// it's a jQuery object parent = this._config.parent; // It's a jQuery object
if (typeof parent.jquery !== 'undefined' || typeof parent[0] !== 'undefined') {
parent = parent[0]; if (typeof this._config.parent.jquery !== 'undefined') {
parent = this._config.parent[0];
} }
} else { } else {
parent = SelectorEngine__default['default'].findOne(parent); parent = document.querySelector(this._config.parent);
} }
var selector = SELECTOR_DATA_TOGGLE + "[data-bs-parent=\"" + parent + "\"]"; var selector = "[data-toggle=\"collapse\"][data-parent=\"" + this._config.parent + "\"]";
SelectorEngine__default['default'].find(selector, parent).forEach(function (element) { var children = [].slice.call(parent.querySelectorAll(selector));
var selected = getElementFromSelector(element); $(children).each(function (i, element) {
_this3._addAriaAndCollapsedClass(Collapse._getTargetFromElement(element), [element]);
_this4._addAriaAndCollapsedClass(selected, [element]);
}); });
return parent; return parent;
}; };
_proto._addAriaAndCollapsedClass = function _addAriaAndCollapsedClass(element, triggerArray) { _proto._addAriaAndCollapsedClass = function _addAriaAndCollapsedClass(element, triggerArray) {
if (!element || !triggerArray.length) { var isOpen = $(element).hasClass(CLASS_NAME_SHOW);
return;
if (triggerArray.length) {
$(triggerArray).toggleClass(CLASS_NAME_COLLAPSED, !isOpen).attr('aria-expanded', isOpen);
} }
var isOpen = element.classList.contains(CLASS_NAME_SHOW);
triggerArray.forEach(function (elem) {
if (isOpen) {
elem.classList.remove(CLASS_NAME_COLLAPSED);
} else {
elem.classList.add(CLASS_NAME_COLLAPSED);
}
elem.setAttribute('aria-expanded', isOpen);
});
} // Static } // Static
; ;
Collapse.collapseInterface = function collapseInterface(element, config) { Collapse._getTargetFromElement = function _getTargetFromElement(element) {
var data = Data__default['default'].getData(element, DATA_KEY); var selector = Util.getSelectorFromElement(element);
return selector ? document.querySelector(selector) : null;
var _config = _extends({}, Default, Manipulator__default['default'].getDataAttributes(element), typeof config === 'object' && config ? config : {});
if (!data && _config.toggle && typeof config === 'string' && /show|hide/.test(config)) {
_config.toggle = false;
}
if (!data) {
data = new Collapse(element, _config);
}
if (typeof config === 'string') {
if (typeof data[config] === 'undefined') {
throw new TypeError("No method named \"" + config + "\"");
}
data[config]();
}
}; };
Collapse.jQueryInterface = function jQueryInterface(config) { Collapse._jQueryInterface = function _jQueryInterface(config) {
return this.each(function () { return this.each(function () {
Collapse.collapseInterface(this, config); var $this = $(this);
var data = $this.data(DATA_KEY);
var _config = _extends({}, Default, $this.data(), typeof config === 'object' && config ? config : {});
if (!data && _config.toggle && typeof config === 'string' && /show|hide/.test(config)) {
_config.toggle = false;
}
if (!data) {
data = new Collapse(this, _config);
$this.data(DATA_KEY, data);
}
if (typeof config === 'string') {
if (typeof data[config] === 'undefined') {
throw new TypeError("No method named \"" + config + "\"");
}
data[config]();
}
}); });
}; };
_createClass$1(Collapse, null, [{ _createClass(Collapse, null, [{
key: "VERSION",
get: function get() {
return VERSION;
}
}, {
key: "Default", key: "Default",
get: function get() { get: function get() {
return Default; return Default;
} }
}, {
key: "DATA_KEY",
get: function get() {
return DATA_KEY;
}
}]); }]);
return Collapse; return Collapse;
}(BaseComponent); }();
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* Data Api implementation * Data Api implementation
@ -546,56 +335,36 @@
*/ */
EventHandler__default['default'].on(document, EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, function (event) { $(document).on(EVENT_CLICK_DATA_API, SELECTOR_DATA_TOGGLE, function (event) {
// preventDefault only for <a> elements (which change the URL) not inside the collapsible element // preventDefault only for <a> elements (which change the URL) not inside the collapsible element
if (event.target.tagName === 'A') { if (event.currentTarget.tagName === 'A') {
event.preventDefault(); event.preventDefault();
} }
var triggerData = Manipulator__default['default'].getDataAttributes(this); var $trigger = $(this);
var selector = getSelectorFromElement(this); var selector = Util.getSelectorFromElement(this);
var selectorElements = SelectorEngine__default['default'].find(selector); var selectors = [].slice.call(document.querySelectorAll(selector));
selectorElements.forEach(function (element) { $(selectors).each(function () {
var data = Data__default['default'].getData(element, DATA_KEY); var $target = $(this);
var config; var data = $target.data(DATA_KEY);
var config = data ? 'toggle' : $trigger.data();
if (data) { Collapse._jQueryInterface.call($target, config);
// update parent attribute
if (data._parent === null && typeof triggerData.parent === 'string') {
data._config.parent = triggerData.parent;
data._parent = data._getParent();
}
config = 'toggle';
} else {
config = triggerData;
}
Collapse.collapseInterface(element, config);
}); });
}); });
/** /**
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* jQuery * jQuery
* ------------------------------------------------------------------------ * ------------------------------------------------------------------------
* add .Collapse to jQuery only if jQuery is present
*/ */
onDOMContentLoaded(function () { $.fn[NAME] = Collapse._jQueryInterface;
var $ = getjQuery(); $.fn[NAME].Constructor = Collapse;
/* istanbul ignore if */
if ($) { $.fn[NAME].noConflict = function () {
var JQUERY_NO_CONFLICT = $.fn[NAME]; $.fn[NAME] = JQUERY_NO_CONFLICT;
$.fn[NAME] = Collapse.jQueryInterface; return Collapse._jQueryInterface;
$.fn[NAME].Constructor = Collapse; };
$.fn[NAME].noConflict = function () {
$.fn[NAME] = JQUERY_NO_CONFLICT;
return Collapse.jQueryInterface;
};
}
});
return Collapse; return Collapse;

File diff suppressed because one or more lines are too long

82
js/dist/dom/data.js vendored
View file

@ -1,82 +0,0 @@
/*!
* Bootstrap data.js v5.0.0-beta1 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Data = factory());
}(this, (function () { 'use strict';
/**
* --------------------------------------------------------------------------
* Bootstrap (v5.0.0-beta1): dom/data.js
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* --------------------------------------------------------------------------
*/
/**
* ------------------------------------------------------------------------
* Constants
* ------------------------------------------------------------------------
*/
var mapData = function () {
var storeData = {};
var id = 1;
return {
set: function set(element, key, data) {
if (typeof element.bsKey === 'undefined') {
element.bsKey = {
key: key,
id: id
};
id++;
}
storeData[element.bsKey.id] = data;
},
get: function get(element, key) {
if (!element || typeof element.bsKey === 'undefined') {
return null;
}
var keyProperties = element.bsKey;
if (keyProperties.key === key) {
return storeData[keyProperties.id];
}
return null;
},
delete: function _delete(element, key) {
if (typeof element.bsKey === 'undefined') {
return;
}
var keyProperties = element.bsKey;
if (keyProperties.key === key) {
delete storeData[keyProperties.id];
delete element.bsKey;
}
}
};
}();
var Data = {
setData: function setData(instance, key, data) {
mapData.set(instance, key, data);
},
getData: function getData(instance, key) {
return mapData.get(instance, key);
},
removeData: function removeData(instance, key) {
mapData.delete(instance, key);
}
};
return Data;
})));
//# sourceMappingURL=data.js.map

View file

@ -1 +0,0 @@
{"version":3,"file":"data.js","sources":["../../src/dom/data.js"],"sourcesContent":["/**\n * --------------------------------------------------------------------------\n * Bootstrap (v5.0.0-beta1): dom/data.js\n * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)\n * --------------------------------------------------------------------------\n */\n\n/**\n * ------------------------------------------------------------------------\n * Constants\n * ------------------------------------------------------------------------\n */\n\nconst mapData = (() => {\n const storeData = {}\n let id = 1\n return {\n set(element, key, data) {\n if (typeof element.bsKey === 'undefined') {\n element.bsKey = {\n key,\n id\n }\n id++\n }\n\n storeData[element.bsKey.id] = data\n },\n get(element, key) {\n if (!element || typeof element.bsKey === 'undefined') {\n return null\n }\n\n const keyProperties = element.bsKey\n if (keyProperties.key === key) {\n return storeData[keyProperties.id]\n }\n\n return null\n },\n delete(element, key) {\n if (typeof element.bsKey === 'undefined') {\n return\n }\n\n const keyProperties = element.bsKey\n if (keyProperties.key === key) {\n delete storeData[keyProperties.id]\n delete element.bsKey\n }\n }\n }\n})()\n\nconst Data = {\n setData(instance, key, data) {\n mapData.set(instance, key, data)\n },\n getData(instance, key) {\n return mapData.get(instance, key)\n },\n removeData(instance, key) {\n mapData.delete(instance, key)\n }\n}\n\nexport default Data\n"],"names":["mapData","storeData","id","set","element","key","data","bsKey","get","keyProperties","delete","Data","setData","instance","getData","removeData"],"mappings":";;;;;;;;;;;EAAA;EACA;EACA;EACA;EACA;EACA;;EAEA;EACA;EACA;EACA;EACA;EAEA,IAAMA,OAAO,GAAI,YAAM;EACrB,MAAMC,SAAS,GAAG,EAAlB;EACA,MAAIC,EAAE,GAAG,CAAT;EACA,SAAO;EACLC,IAAAA,GADK,eACDC,OADC,EACQC,GADR,EACaC,IADb,EACmB;EACtB,UAAI,OAAOF,OAAO,CAACG,KAAf,KAAyB,WAA7B,EAA0C;EACxCH,QAAAA,OAAO,CAACG,KAAR,GAAgB;EACdF,UAAAA,GAAG,EAAHA,GADc;EAEdH,UAAAA,EAAE,EAAFA;EAFc,SAAhB;EAIAA,QAAAA,EAAE;EACH;;EAEDD,MAAAA,SAAS,CAACG,OAAO,CAACG,KAAR,CAAcL,EAAf,CAAT,GAA8BI,IAA9B;EACD,KAXI;EAYLE,IAAAA,GAZK,eAYDJ,OAZC,EAYQC,GAZR,EAYa;EAChB,UAAI,CAACD,OAAD,IAAY,OAAOA,OAAO,CAACG,KAAf,KAAyB,WAAzC,EAAsD;EACpD,eAAO,IAAP;EACD;;EAED,UAAME,aAAa,GAAGL,OAAO,CAACG,KAA9B;;EACA,UAAIE,aAAa,CAACJ,GAAd,KAAsBA,GAA1B,EAA+B;EAC7B,eAAOJ,SAAS,CAACQ,aAAa,CAACP,EAAf,CAAhB;EACD;;EAED,aAAO,IAAP;EACD,KAvBI;EAwBLQ,IAAAA,MAxBK,mBAwBEN,OAxBF,EAwBWC,GAxBX,EAwBgB;EACnB,UAAI,OAAOD,OAAO,CAACG,KAAf,KAAyB,WAA7B,EAA0C;EACxC;EACD;;EAED,UAAME,aAAa,GAAGL,OAAO,CAACG,KAA9B;;EACA,UAAIE,aAAa,CAACJ,GAAd,KAAsBA,GAA1B,EAA+B;EAC7B,eAAOJ,SAAS,CAACQ,aAAa,CAACP,EAAf,CAAhB;EACA,eAAOE,OAAO,CAACG,KAAf;EACD;EACF;EAlCI,GAAP;EAoCD,CAvCe,EAAhB;;MAyCMI,IAAI,GAAG;EACXC,EAAAA,OADW,mBACHC,QADG,EACOR,GADP,EACYC,IADZ,EACkB;EAC3BN,IAAAA,OAAO,CAACG,GAAR,CAAYU,QAAZ,EAAsBR,GAAtB,EAA2BC,IAA3B;EACD,GAHU;EAIXQ,EAAAA,OAJW,mBAIHD,QAJG,EAIOR,GAJP,EAIY;EACrB,WAAOL,OAAO,CAACQ,GAAR,CAAYK,QAAZ,EAAsBR,GAAtB,CAAP;EACD,GANU;EAOXU,EAAAA,UAPW,sBAOAF,QAPA,EAOUR,GAPV,EAOe;EACxBL,IAAAA,OAAO,CAACU,MAAR,CAAeG,QAAf,EAAyBR,GAAzB;EACD;EATU;;;;;;;;"}

View file

@ -1,310 +0,0 @@
/*!
* Bootstrap event-handler.js v5.0.0-beta1 (https://getbootstrap.com/)
* Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.EventHandler = factory());
}(this, (function () { 'use strict';
/**
* --------------------------------------------------------------------------
* Bootstrap (v5.0.0-beta1): util/index.js
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* --------------------------------------------------------------------------
*/
var getjQuery = function getjQuery() {
var _window = window,
jQuery = _window.jQuery;
if (jQuery && !document.body.hasAttribute('data-bs-no-jquery')) {
return jQuery;
}
return null;
};
var isRTL = document.documentElement.dir === 'rtl';
/**
* --------------------------------------------------------------------------
* Bootstrap (v5.0.0-beta1): dom/event-handler.js
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
* --------------------------------------------------------------------------
*/
/**
* ------------------------------------------------------------------------
* Constants
* ------------------------------------------------------------------------
*/
var namespaceRegex = /[^.]*(?=\..*)\.|.*/;
var stripNameRegex = /\..*/;
var stripUidRegex = /::\d+$/;
var eventRegistry = {}; // Events storage
var uidEvent = 1;
var customEvents = {
mouseenter: 'mouseover',
mouseleave: 'mouseout'
};
var nativeEvents = new Set(['click', 'dblclick', 'mouseup', 'mousedown', 'contextmenu', 'mousewheel', 'DOMMouseScroll', 'mouseover', 'mouseout', 'mousemove', 'selectstart', 'selectend', 'keydown', 'keypress', 'keyup', 'orientationchange', 'touchstart', 'touchmove', 'touchend', 'touchcancel', 'pointerdown', 'pointermove', 'pointerup', 'pointerleave', 'pointercancel', 'gesturestart', 'gesturechange', 'gestureend', 'focus', 'blur', 'change', 'reset', 'select', 'submit', 'focusin', 'focusout', 'load', 'unload', 'beforeunload', 'resize', 'move', 'DOMContentLoaded', 'readystatechange', 'error', 'abort', 'scroll']);
/**
* ------------------------------------------------------------------------
* Private methods
* ------------------------------------------------------------------------
*/
function getUidEvent(element, uid) {
return uid && uid + "::" + uidEvent++ || element.uidEvent || uidEvent++;
}
function getEvent(element) {
var uid = getUidEvent(element);
element.uidEvent = uid;
eventRegistry[uid] = eventRegistry[uid] || {};
return eventRegistry[uid];
}
function bootstrapHandler(element, fn) {
return function handler(event) {
event.delegateTarget = element;
if (handler.oneOff) {
EventHandler.off(element, event.type, fn);
}
return fn.apply(element, [event]);
};
}
function bootstrapDelegationHandler(element, selector, fn) {
return function handler(event) {
var domElements = element.querySelectorAll(selector);
for (var target = event.target; target && target !== this; target = target.parentNode) {
for (var i = domElements.length; i--;) {
if (domElements[i] === target) {
event.delegateTarget = target;
if (handler.oneOff) {
EventHandler.off(element, event.type, fn);
}
return fn.apply(target, [event]);
}
}
} // To please ESLint
return null;
};
}
function findHandler(events, handler, delegationSelector) {
if (delegationSelector === void 0) {
delegationSelector = null;
}
var uidEventList = Object.keys(events);
for (var i = 0, len = uidEventList.length; i < len; i++) {
var event = events[uidEventList[i]];
if (event.originalHandler === handler && event.delegationSelector === delegationSelector) {
return event;
}
}
return null;
}
function normalizeParams(originalTypeEvent, handler, delegationFn) {
var delegation = typeof handler === 'string';
var originalHandler = delegation ? delegationFn : handler; // allow to get the native events from namespaced events ('click.bs.button' --> 'click')
var typeEvent = originalTypeEvent.replace(stripNameRegex, '');
var custom = customEvents[typeEvent];
if (custom) {
typeEvent = custom;
}
var isNative = nativeEvents.has(typeEvent);
if (!isNative) {
typeEvent = originalTypeEvent;
}
return [delegation, originalHandler, typeEvent];
}
function addHandler(element, originalTypeEvent, handler, delegationFn, oneOff) {
if (typeof originalTypeEvent !== 'string' || !element) {
return;
}
if (!handler) {
handler = delegationFn;
delegationFn = null;
}
var _normalizeParams = normalizeParams(originalTypeEvent, handler, delegationFn),
delegation = _normalizeParams[0],
originalHandler = _normalizeParams[1],
typeEvent = _normalizeParams[2];
var events = getEvent(element);
var handlers = events[typeEvent] || (events[typeEvent] = {});
var previousFn = findHandler(handlers, originalHandler, delegation ? handler : null);
if (previousFn) {
previousFn.oneOff = previousFn.oneOff && oneOff;
return;
}
var uid = getUidEvent(originalHandler, originalTypeEvent.replace(namespaceRegex, ''));
var fn = delegation ? bootstrapDelegationHandler(element, handler, delegationFn) : bootstrapHandler(element, handler);
fn.delegationSelector = delegation ? handler : null;
fn.originalHandler = originalHandler;
fn.oneOff = oneOff;
fn.uidEvent = uid;
handlers[uid] = fn;
element.addEventListener(typeEvent, fn, delegation);
}
function removeHandler(element, events, typeEvent, handler, delegationSelector) {
var fn = findHandler(events[typeEvent], handler, delegationSelector);
if (!fn) {
return;
}
element.removeEventListener(typeEvent, fn, Boolean(delegationSelector));
delete events[typeEvent][fn.uidEvent];
}
function removeNamespacedHandlers(element, events, typeEvent, namespace) {
var storeElementEvent = events[typeEvent] || {};
Object.keys(storeElementEvent).forEach(function (handlerKey) {
if (handlerKey.includes(namespace)) {
var event = storeElementEvent[handlerKey];
removeHandler(element, events, typeEvent, event.originalHandler, event.delegationSelector);
}
});
}
var EventHandler = {
on: function on(element, event, handler, delegationFn) {
addHandler(element, event, handler, delegationFn, false);
},
one: function one(element, event, handler, delegationFn) {
addHandler(element, event, handler, delegationFn, true);
},
off: function off(element, originalTypeEvent, handler, delegationFn) {
if (typeof originalTypeEvent !== 'string' || !element) {
return;
}
var _normalizeParams2 = normalizeParams(originalTypeEvent, handler, delegationFn),
delegation = _normalizeParams2[0],
originalHandler = _normalizeParams2[1],
typeEvent = _normalizeParams2[2];
var inNamespace = typeEvent !== originalTypeEvent;
var events = getEvent(element);
var isNamespace = originalTypeEvent.startsWith('.');
if (typeof originalHandler !== 'undefined') {
// Simplest case: handler is passed, remove that listener ONLY.
if (!events || !events[typeEvent]) {
return;
}
removeHandler(element, events, typeEvent, originalHandler, delegation ? handler : null);
return;
}
if (isNamespace) {
Object.keys(events).forEach(function (elementEvent) {
removeNamespacedHandlers(element, events, elementEvent, originalTypeEvent.slice(1));
});
}
var storeElementEvent = events[typeEvent] || {};
Object.keys(storeElementEvent).forEach(function (keyHandlers) {
var handlerKey = keyHandlers.replace(stripUidRegex, '');
if (!inNamespace || originalTypeEvent.includes(handlerKey)) {
var event = storeElementEvent[keyHandlers];
removeHandler(element, events, typeEvent, event.originalHandler, event.delegationSelector);
}
});
},
trigger: function trigger(element, event, args) {
if (typeof event !== 'string' || !element) {
return null;
}
var $ = getjQuery();
var typeEvent = event.replace(stripNameRegex, '');
var inNamespace = event !== typeEvent;
var isNative = nativeEvents.has(typeEvent);
var jQueryEvent;
var bubbles = true;
var nativeDispatch = true;
var defaultPrevented = false;
var evt = null;
if (inNamespace && $) {
jQueryEvent = $.Event(event, args);
$(element).trigger(jQueryEvent);
bubbles = !jQueryEvent.isPropagationStopped();
nativeDispatch = !jQueryEvent.isImmediatePropagationStopped();
defaultPrevented = jQueryEvent.isDefaultPrevented();
}
if (isNative) {
evt = document.createEvent('HTMLEvents');
evt.initEvent(typeEvent, bubbles, true);
} else {
evt = new CustomEvent(event, {
bubbles: bubbles,
cancelable: true
});
} // merge custom information in our event
if (typeof args !== 'undefined') {
Object.keys(args).forEach(function (key) {
Object.defineProperty(evt, key, {
get: function get() {
return args[key];
}
});
});
}
if (defaultPrevented) {
evt.preventDefault();
}
if (nativeDispatch) {
element.dispatchEvent(evt);
}
if (evt.defaultPrevented && typeof jQueryEvent !== 'undefined') {
jQueryEvent.preventDefault();
}
return evt;
}
};
return EventHandler;
})));
//# sourceMappingURL=event-handler.js.map

Some files were not shown because too many files have changed in this diff Show more