Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: twbs/bootstrap
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v4.6.0
Choose a base ref
...
head repository: twbs/bootstrap
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v5.0.0
Choose a head ref

Commits on Feb 13, 2019

  1. Copy the full SHA
    ff29c12 View commit details

Commits on Feb 15, 2019

  1. Copy the full SHA
    9baf853 View commit details
  2. Copy the full SHA
    f0f846f View commit details
  3. Copy the full SHA
    974193a View commit details
  4. Copy the full SHA
    25ce91a View commit details
  5. Copy the full SHA
    28a7abf View commit details

Commits on Feb 19, 2019

  1. Copy the full SHA
    abec77a View commit details
  2. Copy the full SHA
    e04f393 View commit details
  3. Update link to CONTRIBUTING.md in README.md (#28297)

    since the former is not contained in the `.github` subdirectory
    patrickhlauke authored and XhmikosR committed Feb 19, 2019
    Copy the full SHA
    68a8af4 View commit details
  4. Remove incorrect aria-haspopup from dropdown toggles (#28299)

    `aria-haspopup` use requires the use of an ARIA `menu`, `listbox`, `tree`, `grid` or `dialog` (see https://www.w3.org/TR/wai-aria-1.1/#aria-haspopup)
    
    in our use (as generic disclosure widgets), it's incorrect and sets up the wrong assumption/behavior from assistive technologies.
    
    in future, we likely want to change our dropdowns to essentially be like a `dialog` - move focus to it when opened, possibly make it modal so focus is maintained inside it and the rest of the page
    is hidden/inert.
    
    but for now, removing the incorrect attribute is probably the quickest, most immediate fix.
    patrickhlauke authored and XhmikosR committed Feb 19, 2019
    Copy the full SHA
    4b00aa6 View commit details
  5. Replace broken-link-checker with linkinator. (#28291)

    Much lighter, more modern and cleaner codebase.
    XhmikosR authored Feb 19, 2019
    Copy the full SHA
    be38057 View commit details
  6. Remove --save option from npm i as it isn't required anymore (#28302

    )
    
    As of npm 5.0.0, installed modules are added as a dependency by default, so the --save option is no longer needed. The other save options still exist and are listed in the documentation for npm install.
    stevemoser authored and XhmikosR committed Feb 19, 2019
    Copy the full SHA
    3731f0d View commit details
  7. Drop Node.js < 8 support.

    Node.js 6 goes EOL on April 2019.
    XhmikosR committed Feb 19, 2019
    Copy the full SHA
    a4f260d View commit details
  8. Update karma to ^4.0.0.

    XhmikosR committed Feb 19, 2019
    Copy the full SHA
    4c87843 View commit details
  9. Use npm-run-all for the release script. (#28307)

    It's shorter.
    XhmikosR authored Feb 19, 2019
    Copy the full SHA
    e4ec9df View commit details
  10. Copy the full SHA
    3a61df5 View commit details
  11. Copy the full SHA
    ececf64 View commit details

Commits on Feb 20, 2019

  1. Remove jQuery from Util.js

    s
    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    fb465c4 View commit details
  2. Copy the full SHA
    8d34bc1 View commit details
  3. alert without jquery

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    0b16c8c View commit details
  4. Copy the full SHA
    d6560bb View commit details
  5. Copy the full SHA
    7440710 View commit details
  6. Add namespaced events

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    00ca781 View commit details
  7. Copy the full SHA
    a3398ff View commit details
  8. Copy the full SHA
    2970d14 View commit details
  9. Copy the full SHA
    4aef395 View commit details
  10. Copy the full SHA
    3664d14 View commit details
  11. Extend SelectorEngine.find() to include an element first arg.

    If not supplied, it'll just use `document`.
    XhmikosR committed Feb 20, 2019
    Copy the full SHA
    3e8bc9d View commit details
  12. Copy the full SHA
    79144ad View commit details
  13. Add findOne to our SelectorEngine

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    f2f6997 View commit details
  14. Fix our data storage

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    b69fa9d View commit details
  15. Copy the full SHA
    6b58502 View commit details
  16. Copy the full SHA
    7d7873b View commit details
  17. Fix delegation events

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    47242cd View commit details
  18. button without jquery

    XhmikosR committed Feb 20, 2019
    Copy the full SHA
    aba8727 View commit details
  19. Add polyfill for focusin and focusout

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    c5595e5 View commit details
  20. Rewrite carousel without jquery

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    44f38e4 View commit details
  21. Copy the full SHA
    9f9712b View commit details
  22. Rewritten modal without jquery (#23955)

    * Trigger jquery events if available in event handler
    
    * Rewritten modal without jquery
    alekitto authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    33211ee View commit details
  23. Workaround for M$ Edge resetting defaultPrevented flag upon dispatchE…

    …vent
    Alessandro Chitolina authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    53ca76e View commit details
  24. Rewrite Collapse without jQuery

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    69e4d4f View commit details
  25. fix unit test modal

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    bcbea02 View commit details
  26. Wrap our objects into IIFE

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    7c1d0a1 View commit details
  27. tooltip without jquery

    alekitto authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    cc6e130 View commit details
  28. fix weird case with jQuery

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    2929bf9 View commit details
  29. Copy the full SHA
    b5077a1 View commit details
  30. Return a new function with Util.noop

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    99c3119 View commit details
  31. Copy the full SHA
    ec69de4 View commit details
  32. Fix new unit test in popover

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    2ff8ed5 View commit details
  33. fix chores karma

    Johann-S authored and XhmikosR committed Feb 20, 2019
    Copy the full SHA
    330a297 View commit details
Showing 868 changed files with 112,919 additions and 62,015 deletions.
16 changes: 4 additions & 12 deletions .babelrc.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,12 @@
module.exports = {
presets: [
[
'@babel/env',
'@babel/preset-env',
{
loose: true,
modules: false,
exclude: ['transform-typeof-symbol']
bugfixes: true,
modules: false
}
]
],
plugins: [
'@babel/plugin-proposal-object-rest-spread'
],
env: {
test: {
plugins: [ 'istanbul' ]
}
}
]
};
18 changes: 8 additions & 10 deletions .browserslistrc
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
# https://github.com/browserslist/browserslist#readme

>= 1%
last 1 major version
>= 0.5%
last 2 major versions
not dead
Chrome >= 45
Firefox >= 38
Edge >= 12
Explorer >= 10
iOS >= 9
Safari >= 9
Android >= 4.4
Opera >= 30
Chrome >= 60
Firefox >= 60
Firefox ESR
iOS >= 12
Safari >= 12
not Explorer <= 11
66 changes: 66 additions & 0 deletions .bundlewatch.config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
{
"files": [
{
"path": "./dist/css/bootstrap-grid.css",
"maxSize": "7 kB"
},
{
"path": "./dist/css/bootstrap-grid.min.css",
"maxSize": "6 kB"
},
{
"path": "./dist/css/bootstrap-reboot.css",
"maxSize": "2.25 kB"
},
{
"path": "./dist/css/bootstrap-reboot.min.css",
"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",
"maxSize": "24.25 kB"
},
{
"path": "./dist/css/bootstrap.min.css",
"maxSize": "22.25 kB"
},
{
"path": "./dist/js/bootstrap.bundle.js",
"maxSize": "41.25 kB"
},
{
"path": "./dist/js/bootstrap.bundle.min.js",
"maxSize": "22.25 kB"
},
{
"path": "./dist/js/bootstrap.esm.js",
"maxSize": "27 kB"
},
{
"path": "./dist/js/bootstrap.esm.min.js",
"maxSize": "18.25 kB"
},
{
"path": "./dist/js/bootstrap.js",
"maxSize": "27.25 kB"
},
{
"path": "./dist/js/bootstrap.min.js",
"maxSize": "15.75 kB"
}
],
"ci": {
"trackBranches": [
"main",
"v4-dev"
]
}
}
3 changes: 0 additions & 3 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -9,6 +9,3 @@ indent_size = 2
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
trim_trailing_whitespace = false
4 changes: 2 additions & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
**/*.min.js
**/dist/
**/vendor/
/_gh_pages/
/_site/
/js/coverage/
/package.js
/site/static/sw.js
274 changes: 50 additions & 224 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,233 +1,59 @@
{
"root": true,
"parser": "babel-eslint",
"env": {
"browser": true,
"es6": true
},
"extends": ["eslint:recommended"],
"extends": [
"plugin:import/errors",
"plugin:import/warnings",
"plugin:unicorn/recommended",
"xo",
"xo/browser"
],
"rules": {
// Possible Errors
"no-await-in-loop": "error",
"no-extra-parens": "error",
"no-prototype-builtins": "error",
"no-template-curly-in-string": "error",
"valid-jsdoc": "error",

// Best Practices
"accessor-pairs": "error",
"array-callback-return": "error",
"block-scoped-var": "error",
"class-methods-use-this": "off",
"complexity": "error",
"consistent-return": "error",
"curly": "error",
"default-case": "error",
"dot-location": ["error", "property"],
"dot-notation": "error",
"eqeqeq": "error",
"guard-for-in": "error",
"no-alert": "error",
"no-caller": "error",
"no-div-regex": "error",
"no-else-return": "error",
"no-empty-function": "error",
"no-eq-null": "error",
"no-eval": "error",
"no-extend-native": "error",
"no-extra-bind": "error",
"no-extra-label": "error",
"no-floating-decimal": "error",
"no-implicit-coercion": "error",
"no-implicit-globals": "error",
"no-implied-eval": "error",
"no-invalid-this": "off",
"no-iterator": "error",
"no-labels": "error",
"no-lone-blocks": "error",
"no-loop-func": "error",
"no-magic-numbers": ["error", {
"ignore": [-1, 0, 1],
"ignoreArrayIndexes": true
"capitalized-comments": "off",
"indent": [
"error",
2,
{
"MemberExpression": "off",
"SwitchCase": 1
}
],
"no-multi-spaces": ["error", {
"ignoreEOLComments": true,
"exceptions": {
"AssignmentExpression": true,
"ArrowFunctionExpression": true,
"CallExpression": true,
"VariableDeclarator": true
}
"max-params": [
"warn",
5
],
"multiline-ternary": [
"error",
"always-multiline"
],
"new-cap": [
"error",
{
"properties": false
}
],
"no-multi-str": "error",
"no-new": "error",
"no-new-func": "error",
"no-new-wrappers": "error",
"no-octal-escape": "error",
"no-param-reassign": "off",
"no-proto": "error",
"no-restricted-properties": "error",
"no-return-assign": "error",
"no-return-await": "error",
"no-script-url": "error",
"no-self-compare": "error",
"no-sequences": "error",
"no-throw-literal": "error",
"no-unmodified-loop-condition": "error",
"no-unused-expressions": "error",
"no-useless-call": "error",
"no-useless-concat": "error",
"no-useless-return": "error",
"no-void": "error",
"no-warning-comments": "off",
"no-with": "error",
"prefer-promise-reject-errors": "error",
"radix": "error",
"require-await": "error",
"vars-on-top": "error",
"wrap-iife": "error",
"yoda": "error",

// Strict Mode
"strict": "error",

// Variables
"init-declarations": "off",
"no-catch-shadow": "error",
"no-label-var": "error",
"no-restricted-globals": "error",
"no-shadow": "off",
"no-shadow-restricted-names": "error",
"no-undef-init": "error",
"no-undefined": "error",
"no-use-before-define": "off",

// Node.js and CommonJS
"callback-return": "off",
"global-require": "error",
"handle-callback-err": "error",
"no-mixed-requires": "error",
"no-new-require": "error",
"no-path-concat": "error",
"no-process-env": "error",
"no-process-exit": "error",
"no-restricted-modules": "error",
"no-sync": "error",

// Stylistic Issues
"array-bracket-spacing": "error",
"block-spacing": "error",
"brace-style": "error",
"camelcase": "error",
"capitalized-comments": "off",
"comma-dangle": "error",
"comma-spacing": "error",
"comma-style": "error",
"computed-property-spacing": "error",
"consistent-this": "error",
"eol-last": "error",
"func-call-spacing": "error",
"func-name-matching": "error",
"func-names": "off",
"func-style": ["error", "declaration"],
"id-blacklist": "error",
"id-length": "off",
"id-match": "error",
"indent": ["error", 2, { "SwitchCase": 1 }],
"jsx-quotes": "error",
"key-spacing": "off",
"keyword-spacing": "error",
"linebreak-style": ["error", "unix"],
"line-comment-position": "off",
"lines-around-comment": "off",
"lines-around-directive": "error",
"max-depth": ["error", 10],
"max-len": "off",
"max-lines": "off",
"max-nested-callbacks": "error",
"max-params": "off",
"max-statements": "off",
"max-statements-per-line": "error",
"multiline-ternary": "off",
"new-cap": ["error", { "capIsNewExceptionPattern": "$.*" }],
"newline-after-var": "off",
"newline-per-chained-call": ["error", { "ignoreChainWithDepth": 5 }],
"new-parens": "error",
"no-array-constructor": "error",
"no-bitwise": "error",
"no-continue": "off",
"no-inline-comments": "off",
"no-lonely-if": "error",
"no-mixed-operators": "off",
"no-multi-assign": "error",
"no-multiple-empty-lines": "error",
"nonblock-statement-body-position": "error",
"no-negated-condition": "off",
"no-nested-ternary": "error",
"no-new-object": "error",
"no-plusplus": "off",
"no-restricted-syntax": "error",
"no-tabs": "error",
"no-ternary": "off",
"no-trailing-spaces": "error",
"no-underscore-dangle": "off",
"no-unneeded-ternary": "error",
"no-whitespace-before-property": "error",
"object-curly-newline": ["error", { "minProperties": 1 }],
"object-curly-spacing": ["error", "always"],
"object-property-newline": "error",
"one-var": ["error", "never"],
"one-var-declaration-per-line": "error",
"operator-assignment": "error",
"operator-linebreak": "error",
"padded-blocks": ["error", "never"],
"padding-line-between-statements": "off",
"quote-props": ["error", "as-needed"],
"quotes": ["error", "single"],
"require-jsdoc": "off",
"semi": ["error", "never"],
"semi-spacing": "error",
"sort-keys": "off",
"sort-vars": "error",
"space-before-blocks": "error",
"space-before-function-paren": ["error", {
"anonymous": "always",
"named": "never"
}],
"space-in-parens": "error",
"space-infix-ops": "error",
"space-unary-ops": "error",
"spaced-comment": "error",
"template-tag-spacing": "error",
"unicode-bom": "error",
"wrap-regex": "off",

// ECMAScript 6
"arrow-body-style": ["error", "as-needed"],
"arrow-parens": "error",
"arrow-spacing": "error",
"generator-star-spacing": "error",
"no-confusing-arrow": "error",
"no-duplicate-imports": "error",
"no-restricted-imports": "error",
"no-useless-computed-key": "error",
"no-useless-constructor": "error",
"no-useless-rename": "error",
"no-var": "error",
"object-shorthand": "error",
"prefer-arrow-callback": "error",
"prefer-const": "error",
"prefer-destructuring": "off",
"prefer-numeric-literals": "error",
"prefer-rest-params": "error",
"prefer-spread": "error",
"prefer-template": "error",
"rest-spread-spacing": "error",
"sort-imports": "error",
"symbol-description": "error",
"template-curly-spacing": "error",
"yield-star-spacing": "error"
"no-console": "error",
"object-curly-spacing": [
"error",
"always"
],
"semi": [
"error",
"never"
],
"unicorn/consistent-function-scoping": "off",
"unicorn/explicit-length-check": "off",
"unicorn/no-array-callback-reference": "off",
"unicorn/no-array-for-each": "off",
"unicorn/no-for-loop": "off",
"unicorn/no-null": "off",
"unicorn/no-unused-properties": "error",
"unicorn/no-useless-undefined": "off",
"unicorn/prefer-dom-node-append": "off",
"unicorn/prefer-dom-node-dataset": "off",
"unicorn/prefer-dom-node-remove": "off",
"unicorn/prefer-module": "off",
"unicorn/prefer-query-selector": "off",
"unicorn/prefer-spread": "off",
"unicorn/prevent-abbreviations": "off"
}
}
14 changes: 2 additions & 12 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,18 +1,8 @@
# Enforce Unix newlines
*.css text eol=lf
*.html text eol=lf
*.js text eol=lf
*.json text eol=lf
*.md text eol=lf
*.rb text eol=lf
*.scss text eol=lf
*.svg text eol=lf
*.txt text eol=lf
*.xml text eol=lf
*.yml text eol=lf
* text=auto eol=lf

# Don't diff or textually merge source maps
*.map binary
*.map binary

bootstrap.css linguist-vendored=false
bootstrap.js linguist-vendored=false
64 changes: 30 additions & 34 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -19,7 +19,8 @@ and [submitting pull requests](#pull-requests), but please respect the following
restrictions:

* Please **do not** use the issue tracker for personal support requests. Stack
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.
Overflow ([`bootstrap-5`](https://stackoverflow.com/questions/tagged/bootstrap-5) tag),
[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
respect the opinions of others.
@@ -57,15 +58,14 @@ Good bug reports are extremely helpful, so thanks!

Guidelines for bug reports:

0. **Validate and lint your code** &mdash; [validate your HTML](https://html5.validator.nu/)
and [lint your HTML](https://github.com/twbs/bootlint) 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.

1. **Use the GitHub issue search** &mdash; check if the issue has already been
reported.

2. **Check if the issue has been fixed** &mdash; try to reproduce it using the
latest `master` or development branch in the repository.
latest `main` (or `v4-dev` branch if the issue is about v4) in the repository.

3. **Isolate the problem** &mdash; ideally create a [reduced test
case](https://css-tricks.com/reduced-test-cases/) and a live example.
@@ -100,18 +100,13 @@ Example:
### 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.
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 |
| ------------- | ---------------------------- | ---------------- | ------------------------------------------------------------------------------------- | -------------------------------------------------------- |
| 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 <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. |
| Microsoft | Edge | EdgeHTML | https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/ | |

### Issues bots

[@twbs-lmvtfy](https://github.com/twbs-lmvtfy) is a Bootstrap bot that hangs out in our GitHub issue tracker and automatically checks for HTML validation errors in live examples (e.g. jsFiddles, JS Bins, Bootplys, Plunks, CodePens, etc.) posted in issue comments. If it finds any errors, it will post a follow-up comment on the issue and point out the errors. If this happens with an example you've posted, please fix the errors and post an updated live example. If you opened a bug report, please check whether the bug still occurs with your revised, valid live example. If the bug no longer occurs, it was probably due to your invalid HTML rather than something in Bootstrap and we'd appreciate it if you could close out the GitHub issue.
| 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. |
| Apple | Safari | WebKit | https://bugs.webkit.org/enter_bug.cgi?product=WebKit | 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. |
| Microsoft | Edge | Blink | https://developer.microsoft.com/en-us/microsoft-edge/ | Go to "Help > Send Feedback" from the browser |


## Feature requests
@@ -128,23 +123,25 @@ Good pull requests—patches, improvements, new features—are a fantastic
help. They should remain focused in scope and avoid containing unrelated
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),
otherwise you risk spending a lot of time working on something that the
project's developers might not want to merge into the project.
project's developers might not want to merge into the project. For trivial
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
project (indentation, accurate comments, etc.) and any other requirements
(such as test coverage).

**Do not edit `bootstrap.css`, or `bootstrap.js`
directly!** Those files are automatically generated. You should edit the
source files in [`/bootstrap/scss/`](https://github.com/twbs/bootstrap/tree/master/scss)
and/or [`/bootstrap/js/`](https://github.com/twbs/bootstrap/tree/master/js) instead.
**Do not edit `bootstrap.css` or `bootstrap.js`, and do not commit
any dist files (`dist/` or `js/dist`).** Those files are automatically generated by our build tools. You should
edit the source files in [`/bootstrap/scss/`](https://github.com/twbs/bootstrap/tree/main/scss)
and/or [`/bootstrap/js/src/`](https://github.com/twbs/bootstrap/tree/main/js/src) instead.

Similarly, when contributing to Bootstrap's documentation, you should edit the
documentation source files in
[the `/bootstrap/docs/` directory of the `master` branch](https://github.com/twbs/bootstrap/tree/master/docs).
[the `/bootstrap/site/content/docs/` directory of the `main` branch](https://github.com/twbs/bootstrap/tree/main/site/content/docs).
**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.

@@ -166,8 +163,8 @@ included in the project:
2. If you cloned a while ago, get the latest changes from upstream:

```bash
git checkout master
git pull upstream master
git checkout main
git pull upstream main
```

3. Create a new topic branch (off the main project development branch) to
@@ -186,7 +183,7 @@ included in the project:
5. Locally merge (or rebase) the upstream development branch into your topic branch:

```bash
git pull [--rebase] upstream master
git pull [--rebase] upstream main
```

6. Push your topic branch up to your fork:
@@ -196,39 +193,38 @@ included in the project:
```

7. [Open a Pull Request](https://help.github.com/articles/about-pull-requests/)
with a clear title and description against the `master` branch.
with a clear title and description against the `main` branch.

**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
includes code changes) and under the terms of the
[Creative Commons Attribution 3.0 Unported License](docs/LICENSE)
[Creative Commons Attribution 3.0 Unported License](https://creativecommons.org/licenses/by/3.0/)
(if it includes documentation changes).


## Code guidelines

### HTML

[Adhere to the Code Guide.](http://codeguide.co/#html)
[Adhere to the Code Guide.](https://codeguide.co/#html)

- Use tags and elements appropriate for an HTML5 doctype (e.g., self-closing tags).
- Use CDNs and HTTPS for third-party JS when possible. We don't use protocol-relative URLs in this case because they break when viewing the page locally via `file://`.
- Use [WAI-ARIA](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA) attributes in documentation examples to promote accessibility.

### CSS

[Adhere to the Code Guide.](http://codeguide.co/#css)
[Adhere to the Code Guide.](https://codeguide.co/#css)

- When feasible, default color palettes should comply with [WCAG color contrast guidelines](https://www.w3.org/TR/WCAG20/#visual-audio-contrast).
- Except in rare cases, don't remove default `:focus` styles (via e.g. `outline: none;`) without providing alternative styles. See [this A11Y Project post](https://a11yproject.com/posts/never-remove-css-outlines/) for more details.
- Except in rare cases, don't remove default `:focus` styles (via e.g. `outline: none;`) without providing alternative styles. See [this A11Y Project post](https://www.a11yproject.com/posts/2013-01-25-never-remove-css-outlines/) for more details.

### JS

- No semicolons (in client-side JS)
- 2 spaces (no tabs)
- strict mode
- "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

@@ -237,7 +233,7 @@ Run `npm run test` before committing to ensure your changes follow our coding st

## License

By contributing your code, you agree to license your contribution under the [MIT License](LICENSE).
By contributing to the documentation, you agree to license your contribution under the [Creative Commons Attribution 3.0 Unported License](docs/LICENSE).
By contributing your code, you agree to license your contribution under the [MIT License](../LICENSE).
By contributing to the documentation, you agree to license your contribution under the [Creative Commons Attribution 3.0 Unported License](https://creativecommons.org/licenses/by/3.0/).

Prior to v3.1.0, Bootstrap's code was released under the Apache License v2.0.
3 changes: 3 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# These are supported funding model platforms

open_collective: bootstrap
11 changes: 0 additions & 11 deletions .github/ISSUE_TEMPLATE/bug.md

This file was deleted.

13 changes: 8 additions & 5 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,20 @@
---
name: Bug report
about: Tell us about a bug you may have identified in Bootstrap.
title: ''
labels: ''
assignees: ''

---

Before opening:

- [Search for duplicate or closed issues](https://github.com/twbs/bootstrap/issues?utf8=%E2%9C%93&q=is%3Aissue)
- [Validate](https://html5.validator.nu/) and [lint](https://github.com/twbs/bootlint#in-the-browser) any HTML to avoid common problems
- Read the [contributing guidelines](https://github.com/twbs/bootstrap/blob/master/CONTRIBUTING.md)
- [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)

Bug reports must include:

- Operating system and version (Windows, macOS, Android, iOS, Win10 Mobile)
- Browser and version (Chrome, Firefox, Safari, IE, MS Edge, Opera 15+, Android Browser)
- [Reduced test case](https://css-tricks.com/reduced-test-cases/) and suggested fix using [CodePen](https://codepen.io/) or [JS Bin](https://jsbin.com/)
- Operating system and version (Windows, macOS, Android, iOS)
- Browser and version (Chrome, Firefox, Safari, 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/)
4 changes: 4 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
contact_links:
- name: Ask a question
url: https://github.com/twbs/bootstrap/discussions/new
about: Ask and discuss questions with other Bootstrap community members
9 changes: 0 additions & 9 deletions .github/ISSUE_TEMPLATE/feature.md

This file was deleted.

5 changes: 4 additions & 1 deletion .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
---
name: Feature request
about: Suggest an idea for a new feature in Bootstrap.
title: ''
labels: feature
assignees: ''

---

Before opening:

- [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/master/CONTRIBUTING.md)
- Read the [contributing guidelines](https://github.com/twbs/bootstrap/blob/main/.github/CONTRIBUTING.md)

Feature requests must include:

2 changes: 1 addition & 1 deletion .github/SUPPORT.md
Original file line number Diff line number Diff line change
@@ -8,4 +8,4 @@ For general troubleshooting or help getting started:

- 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.
- Ask and explore Stack Overflow with the [`bootstrap-4`](https://stackoverflow.com/questions/tagged/bootstrap-4) tag.
- Ask and explore Stack Overflow with the [`bootstrap-5`](https://stackoverflow.com/questions/tagged/bootstrap-5) tag.
24 changes: 24 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
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
54 changes: 54 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
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
43 changes: 43 additions & 0 deletions .github/workflows/browserstack.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: BrowserStack

on:
push:

env:
FORCE_COLOR: 2
NODE: 14

jobs:
browserstack:
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]'))
timeout-minutes: 30

steps:
- name: Clone repository
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: "${{ env.NODE }}"

- name: Set up npm cache
uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
- name: Install npm dependencies
run: npm ci

- name: Run dist
run: npm run dist

- name: Run BrowserStack tests
run: npm run js-test-cloud
env:
BROWSER_STACK_ACCESS_KEY: "${{ secrets.BROWSER_STACK_ACCESS_KEY }}"
BROWSER_STACK_USERNAME: "${{ secrets.BROWSER_STACK_USERNAME }}"
42 changes: 42 additions & 0 deletions .github/workflows/bundlewatch.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Bundlewatch

on:
push:
pull_request:

env:
FORCE_COLOR: 2
NODE: 14

jobs:
bundlewatch:
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: Set up npm cache
uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
- name: Install npm dependencies
run: npm ci

- name: Run dist
run: npm run dist

- name: Run bundlewatch
run: npm run bundlewatch
env:
BUNDLEWATCH_GITHUB_TOKEN: "${{ secrets.BUNDLEWATCH_GITHUB_TOKEN }}"
CI_BRANCH_BASE: main
37 changes: 37 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: "CodeQL"

on:
push:
branches:
- main
- v4-dev
- "!dependabot/**"
pull_request:
# The branches below must be a subset of the branches above
branches:
- main
- v4-dev
- "!dependabot/**"
schedule:
- cron: "0 2 * * 5"

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: "javascript"

- name: Autobuild
uses: github/codeql-action/autobuild@v1

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
38 changes: 38 additions & 0 deletions .github/workflows/css.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: CSS

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: Set up npm cache
uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
- name: Install npm dependencies
run: npm ci

- name: Build CSS
run: npm run css
40 changes: 40 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Docs

on:
push:
branches-ignore:
- "dependabot/**"
pull_request:

env:
FORCE_COLOR: 2
NODE: 14

jobs:
docs:
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 }}"

- run: java -version

- name: Set up npm cache
uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
- name: Install npm dependencies
run: npm ci

- name: Test docs
run: npm run docs
53 changes: 53 additions & 0 deletions .github/workflows/js.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: JS Tests

on:
push:
branches-ignore:
- "dependabot/**"
pull_request:

env:
FORCE_COLOR: 2

jobs:
run:
name: Node ${{ matrix.node }}
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
node: [10, 12, 14, 16]

steps:
- name: Clone repository
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}

- name: Set up npm cache
uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ matrix.node }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-${{ matrix.node }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
- name: Install npm dependencies
run: npm ci

- name: Run dist
run: npm run js

- name: Run JS tests
run: npm run js-test

- name: Run Coveralls
uses: coverallsapp/github-action@v1.1.2
if: matrix.node == 14
with:
github-token: "${{ secrets.GITHUB_TOKEN }}"
path-to-lcov: "./js/coverage/lcov.info"
38 changes: 38 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Lint

on:
push:
branches-ignore:
- "dependabot/**"
pull_request:

env:
FORCE_COLOR: 2
NODE: 14

jobs:
lint:
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: Set up npm cache
uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-${{ env.NODE }}-${{ hashFiles('package.json') }}-${{ hashFiles('package-lock.json') }}
- name: Install npm dependencies
run: npm ci

- name: Lint
run: npm run lint
30 changes: 30 additions & 0 deletions .github/workflows/node-sass.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
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
15 changes: 15 additions & 0 deletions .github/workflows/release-notes.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Release notes

on:
push:
branches:
- main

jobs:
update_release_draft:
runs-on: ubuntu-latest
if: github.repository == 'twbs/bootstrap'
steps:
- uses: release-drafter/release-drafter@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
14 changes: 6 additions & 8 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
# Ignore docs files
/_gh_pages/
/site/.jekyll-metadata
/site/docs/**/dist/

# Ignore ruby/bundler files
/.bundle/
/vendor/
/.ruby-version
/_site/
# Hugo resources folder
/resources/

# Numerous always-ignore extensions
*.diff
@@ -33,6 +28,9 @@
*.sublime-workspace
nbproject
Thumbs.db
/.vscode/
# Local Netlify folder
.netlify

# Komodo
.komodotools
3 changes: 2 additions & 1 deletion .stylelintignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
**/*.min.css
**/dist/
**/vendor/
/_gh_pages/
/_site/
/js/coverage/
20 changes: 18 additions & 2 deletions .stylelintrc
Original file line number Diff line number Diff line change
@@ -3,13 +3,29 @@
"stylelint-config-twbs-bootstrap/scss"
],
"rules": {
"property-blacklist": [
"declaration-property-value-disallowed-list": {
"border": "none",
"outline": "none"
},
"function-disallowed-list": [
"calc",
"lighten",
"darken"
],
"property-disallowed-list": [
"border-radius",
"border-top-left-radius",
"border-top-right-radius",
"border-bottom-right-radius",
"border-bottom-left-radius",
"transition"
]
],
"scss/dollar-variable-default": [
true,
{
"ignore": "local"
}
],
"scss/selector-no-union-class-name": true
}
}
25 changes: 0 additions & 25 deletions .travis.yml

This file was deleted.

25 changes: 11 additions & 14 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -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:

* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
- Using welcoming and inclusive language
- Being respectful of differing viewpoints and experiences
- Gracefully accepting constructive criticism
- Focusing on what is best for the community
- Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* 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
- The use of sexualized language or imagery and unwelcome sexual attention or advances
- Trolling, insulting/derogatory comments, and personal or political attacks
- Public or private harassment
- 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

## Our Responsibilities

@@ -40,7 +40,4 @@ Project maintainers who do not follow or enforce the Code of Conduct in good fai

## Attribution

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
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/>
9 changes: 0 additions & 9 deletions Gemfile

This file was deleted.

82 changes: 0 additions & 82 deletions Gemfile.lock

This file was deleted.

4 changes: 2 additions & 2 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
The MIT License (MIT)

Copyright (c) 2011-2019 Twitter, Inc.
Copyright (c) 2011-2019 The Bootstrap Authors
Copyright (c) 2011-2021 Twitter, Inc.
Copyright (c) 2011-2021 The Bootstrap Authors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
183 changes: 104 additions & 79 deletions README.md

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Reporting Security Issues

The Bootstrap team and community take security issues in Bootstrap seriously. We appreciate your efforts to responsibly disclose your findings, and will make every effort to acknowledge your contributions.

To report a security issue, email [security@getbootstrap.com](mailto:security@getbootstrap.com) and include the word "SECURITY" in the subject line.

We'll endeavor to respond quickly, and will keep you updated throughout the process.
68 changes: 0 additions & 68 deletions _config.yml

This file was deleted.

8 changes: 1 addition & 7 deletions build/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -8,13 +8,7 @@
},
"extends": "../.eslintrc.json",
"rules": {
"consistent-return": "off",
"func-style": "off",
"no-console": "off",
"no-magic-numbers": "off",
"no-process-env": "off",
"no-process-exit": "off",
"no-sync": "off",
"spaced-comment": "off"
"strict": "error"
}
}
2 changes: 1 addition & 1 deletion build/banner.js
Original file line number Diff line number Diff line change
@@ -7,7 +7,7 @@ function getBanner(pluginFilename) {
return `/*!
* Bootstrap${pluginFilename ? ` ${pluginFilename}` : ''} v${pkg.version} (${pkg.homepage})
* Copyright 2011-${year} ${pkg.author}
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/`
}

200 changes: 153 additions & 47 deletions build/build-plugins.js
Original file line number Diff line number Diff line change
@@ -1,85 +1,191 @@
#!/usr/bin/env node

/*!
* Script to build our plugins to use them separately.
* Copyright 2019 The Bootstrap Authors
* Copyright 2019 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* Copyright 2020-2021 The Bootstrap Authors
* Copyright 2020-2021 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/

'use strict'

const path = require('path')
const rollup = require('rollup')
const babel = require('rollup-plugin-babel')
const banner = require('./banner.js')
const path = require('path')
const rollup = require('rollup')
const { babel } = require('@rollup/plugin-babel')
const banner = require('./banner.js')

const TEST = process.env.NODE_ENV === 'test'
const rootPath = path.resolve(__dirname, '../js/dist/')
const plugins = [
babel({
exclude: 'node_modules/**', // Only transpile our source code
externalHelpersWhitelist: [ // Include only required helpers
'defineProperties',
'createClass',
'inheritsLoose',
'defineProperty',
'objectSpread'
]
// Only transpile our source code
exclude: 'node_modules/**',
// Include the helpers in each file, at most one copy of each
babelHelpers: 'bundled'
})
]
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'),
Base: path.resolve(__dirname, '../js/src/base-component.js'),
Button: path.resolve(__dirname, '../js/src/button.js'),
Carousel: path.resolve(__dirname, '../js/src/carousel.js'),
Collapse: path.resolve(__dirname, '../js/src/collapse.js'),
Dropdown: path.resolve(__dirname, '../js/src/dropdown.js'),
Modal: path.resolve(__dirname, '../js/src/modal.js'),
Offcanvas: path.resolve(__dirname, '../js/src/offcanvas.js'),
Popover: path.resolve(__dirname, '../js/src/popover.js'),
ScrollSpy: path.resolve(__dirname, '../js/src/scrollspy.js'),
Tab: path.resolve(__dirname, '../js/src/tab.js'),
Toast: path.resolve(__dirname, '../js/src/toast.js'),
Tooltip: path.resolve(__dirname, '../js/src/tooltip.js'),
Util: path.resolve(__dirname, '../js/src/util.js')
Tooltip: path.resolve(__dirname, '../js/src/tooltip.js')
}
const rootPath = TEST ? '../js/coverage/dist/' : '../js/dist/'

function build(plugin) {
console.log(`Building ${plugin} plugin...`)
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 external = ['jquery', 'popper.js']
const globals = {
jquery: 'jQuery', // Ensure we use jQuery which is always available even in noConflict mode
'popper.js': 'Popper'
const getConfigByPluginKey = pluginKey => {
if (
pluginKey === 'Data' ||
pluginKey === 'Manipulator' ||
pluginKey === 'EventHandler' ||
pluginKey === 'SelectorEngine' ||
pluginKey === 'Util' ||
pluginKey === 'Sanitizer' ||
pluginKey === 'Backdrop'
) {
return {
external: []
}
}

// Do not bundle Util in plugins
if (plugin !== 'Util') {
external.push(bsPlugins.Util)
globals[bsPlugins.Util] = 'Util'
if (pluginKey === 'Alert' || pluginKey === 'Tab' || pluginKey === 'Offcanvas') {
return defaultPluginConfig
}

// Do not bundle Tooltip in Popover
if (plugin === 'Popover') {
external.push(bsPlugins.Tooltip)
globals[bsPlugins.Tooltip] = 'Tooltip'
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',
'Backdrop'
])

const domObjects = new Set([
'Data',
'EventHandler',
'Manipulator',
'SelectorEngine'
])

const build = async plugin => {
console.log(`Building ${plugin} plugin...`)

const { external, globals } = getConfigByPluginKey(plugin)
const pluginFilename = path.basename(bsPlugins[plugin])
let pluginPath = rootPath

if (utilObjects.has(plugin)) {
pluginPath = `${rootPath}/util/`
}

const pluginFilename = `${plugin.toLowerCase()}.js`
if (domObjects.has(plugin)) {
pluginPath = `${rootPath}/dom/`
}

rollup.rollup({
const bundle = await rollup.rollup({
input: bsPlugins[plugin],
plugins,
external
}).then((bundle) => {
bundle.write({
banner: banner(pluginFilename),
format: 'umd',
name: plugin,
sourcemap: true,
globals,
file: path.resolve(__dirname, `${rootPath}${pluginFilename}`)
})
.then(() => console.log(`Building ${plugin} plugin... Done!`))
.catch((err) => console.error(`${plugin}: ${err}`))
})

await bundle.write({
banner: banner(pluginFilename),
format: 'umd',
name: plugin,
sourcemap: true,
globals,
file: path.resolve(__dirname, `${pluginPath}/${pluginFilename}`)
})

console.log(`Building ${plugin} plugin... Done!`)
}

const main = async () => {
try {
await Promise.all(Object.keys(bsPlugins).map(plugin => build(plugin)))
} catch (error) {
console.error(error)

process.exit(1)
}
}

Object.keys(bsPlugins).forEach((plugin) => build(plugin))
main()
123 changes: 50 additions & 73 deletions build/change-version.js
100755 → 100644
Original file line number Diff line number Diff line change
@@ -2,103 +2,80 @@

/*!
* Script to update version number references in the project.
* Copyright 2017-2019 The Bootstrap Authors
* Copyright 2017-2019 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* Copyright 2017-2021 The Bootstrap Authors
* Copyright 2017-2021 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/

'use strict'

const fs = require('fs')
const fs = require('fs').promises
const path = require('path')
const sh = require('shelljs')
const globby = require('globby')

sh.config.fatal = true
const VERBOSE = process.argv.includes('--verbose')
const DRY_RUN = process.argv.includes('--dry') || process.argv.includes('--dry-run')

// These are the filetypes we only care about replacing the version
const GLOB = [
'**/*.{css,html,js,json,md,scss,txt,yml}'
]
const GLOBBY_OPTIONS = {
cwd: path.join(__dirname, '..'),
gitignore: true
}

// Blame TC39... https://github.com/benjamingr/RegExp.escape/issues/37
function regExpQuote(string) {
return string.replace(/[-\\^$*+?.()|[\]{}]/g, '\\$&')
return string.replace(/[$()*+-.?[\\\]^{|}]/g, '\\$&')
}

function regExpQuoteReplacement(string) {
return string.replace(/[$]/g, '$$')
return string.replace(/\$/g, '$$')
}

const DRY_RUN = false
async function replaceRecursively(file, oldVersion, newVersion) {
const originalString = await fs.readFile(file, 'utf8')
const newString = originalString.replace(
new RegExp(regExpQuote(oldVersion), 'g'), regExpQuoteReplacement(newVersion)
)

function walkAsync(directory, excludedDirectories, fileCallback, errback) {
if (excludedDirectories.has(path.parse(directory).base)) {
// No need to move any further if the strings are identical
if (originalString === newString) {
return
}
fs.readdir(directory, (err, names) => {
if (err) {
errback(err)
return
}
names.forEach((name) => {
const filepath = path.join(directory, name)
fs.lstat(filepath, (err, stats) => {
if (err) {
process.nextTick(errback, err)
return
}
if (stats.isDirectory()) {
process.nextTick(walkAsync, filepath, excludedDirectories, fileCallback, errback)
} else if (stats.isFile()) {
process.nextTick(fileCallback, filepath)
}
})
})
})
}

function replaceRecursively(directory, excludedDirectories, allowedExtensions, original, replacement) {
original = new RegExp(regExpQuote(original), 'g')
replacement = regExpQuoteReplacement(replacement)
const updateFile = DRY_RUN ? (filepath) => {
if (allowedExtensions.has(path.parse(filepath).ext)) {
console.log(`FILE: ${filepath}`)
} else {
console.log(`EXCLUDED:${filepath}`)
}
} : (filepath) => {
if (allowedExtensions.has(path.parse(filepath).ext)) {
sh.sed('-i', original, replacement, filepath)
}
if (VERBOSE) {
console.log(`FILE: ${file}`)
}
walkAsync(directory, excludedDirectories, updateFile, (err) => {
console.error('ERROR while traversing directory!:')
console.error(err)
process.exit(1)
})

if (DRY_RUN) {
return
}

await fs.writeFile(file, newString, 'utf8')
}

function main(args) {
if (args.length !== 2) {
console.error('USAGE: change-version old_version new_version')
async function main(args) {
const [oldVersion, newVersion] = args

if (!oldVersion || !newVersion) {
console.error('USAGE: change-version old_version new_version [--verbose] [--dry[-run]]')
console.error('Got arguments:', args)
process.exit(1)
}
const oldVersion = args[0]
const newVersion = args[1]
const EXCLUDED_DIRS = new Set([
'.git',
'node_modules',
'vendor'
])
const INCLUDED_EXTENSIONS = new Set([
// This extension whitelist is how we avoid modifying binary files
'',
'.css',
'.html',
'.js',
'.json',
'.md',
'.scss',
'.txt',
'.yml'
])
replaceRecursively('.', EXCLUDED_DIRS, INCLUDED_EXTENSIONS, oldVersion, newVersion)

// Strip any leading `v` from arguments because otherwise we will end up with duplicate `v`s
[oldVersion, newVersion].map(arg => arg.startsWith('v') ? arg.slice(1) : arg)

try {
const files = await globby(GLOB, GLOBBY_OPTIONS)

await Promise.all(files.map(file => replaceRecursively(file, oldVersion, newVersion)))
} catch (error) {
console.error(error)
process.exit(1)
}
}

main(process.argv.slice(2))
26 changes: 12 additions & 14 deletions build/generate-sri.js
Original file line number Diff line number Diff line change
@@ -5,9 +5,9 @@
* Remember to use the same vendor files as the CDN ones,
* otherwise the hashes won't match!
*
* Copyright 2017-2019 The Bootstrap Authors
* Copyright 2017-2019 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* Copyright 2017-2021 The Bootstrap Authors
* Copyright 2017-2021 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/

'use strict'
@@ -17,20 +17,22 @@ const fs = require('fs')
const path = require('path')
const sh = require('shelljs')

const pkg = require('../package.json')

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.
// `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 = [
{
file: 'dist/css/bootstrap.min.css',
configPropertyName: 'css_hash'
},
{
file: 'dist/css/bootstrap.rtl.min.css',
configPropertyName: 'css_rtl_hash'
},
{
file: 'dist/js/bootstrap.min.js',
configPropertyName: 'js_hash'
@@ -40,16 +42,12 @@ const files = [
configPropertyName: 'js_bundle_hash'
},
{
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',
file: 'node_modules/@popperjs/core/dist/umd/popper.min.js',
configPropertyName: 'popper_hash'
}
]

files.forEach((file) => {
files.forEach(file => {
fs.readFile(file.file, 'utf8', (err, data) => {
if (err) {
throw err
@@ -61,6 +59,6 @@ files.forEach((file) => {

console.log(`${file.configPropertyName}: ${integrity}`)

sh.sed('-i', new RegExp(`(\\s${file.configPropertyName}:\\s+"|')(\\S+)("|')`), `$1${integrity}$3`, configFile)
sh.sed('-i', new RegExp(`^(\\s+${file.configPropertyName}:\\s+["'])\\S*(["'])`), `$1${integrity}$2`, configFile)
})
})
25 changes: 15 additions & 10 deletions build/postcss.config.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,19 @@
'use strict'

module.exports = (ctx) => ({
map: ctx.file.dirname.includes('examples') ? false : {
inline: false,
annotation: true,
sourcesContent: true
},
plugins: {
autoprefixer: {
cascade: false
module.exports = ctx => {
return {
map: ctx.file.dirname.includes('examples') ?
false :
{
inline: false,
annotation: true,
sourcesContent: true
},
plugins: {
autoprefixer: {
cascade: false
},
rtlcss: ctx.env === 'RTL' ? {} : false
}
}
})
}
60 changes: 34 additions & 26 deletions build/rollup.config.js
Original file line number Diff line number Diff line change
@@ -1,48 +1,56 @@
'use strict'

const path = require('path')
const babel = require('rollup-plugin-babel')
const resolve = require('rollup-plugin-node-resolve')
const banner = require('./banner.js')
const path = require('path')
const { babel } = require('@rollup/plugin-babel')
const { nodeResolve } = require('@rollup/plugin-node-resolve')
const replace = require('@rollup/plugin-replace')
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.js'
const external = ['jquery', 'popper.js']
let fileDest = `bootstrap${ESM ? '.esm' : ''}`
const external = ['@popperjs/core']
const plugins = [
babel({
exclude: 'node_modules/**', // Only transpile our source code
externalHelpersWhitelist: [ // Include only required helpers
'defineProperties',
'createClass',
'inheritsLoose',
'defineProperty',
'objectSpread'
]
// Only transpile our source code
exclude: 'node_modules/**',
// Include the helpers in the bundle, at most one copy of each
babelHelpers: 'bundled'
})
]
const globals = {
jquery: 'jQuery', // Ensure we use jQuery which is always available even in noConflict mode
'popper.js': 'Popper'
'@popperjs/core': 'Popper'
}

if (BUNDLE) {
fileDest = 'bootstrap.bundle.js'
fileDest += '.bundle'
// Remove last entry in external array to bundle Popper
external.pop()
delete globals['popper.js']
plugins.push(resolve())
delete globals['@popperjs/core']
plugins.push(
replace({
'process.env.NODE_ENV': '"production"',
preventAssignment: true
}),
nodeResolve()
)
}

module.exports = {
input: path.resolve(__dirname, '../js/src/index.js'),
const rollupConfig = {
input: path.resolve(__dirname, `../js/index.${ESM ? 'esm' : 'umd'}.js`),
output: {
banner,
file: path.resolve(__dirname, `../dist/js/${fileDest}`),
format: 'umd',
globals,
name: 'bootstrap'
file: path.resolve(__dirname, `../dist/js/${fileDest}.js`),
format: ESM ? 'esm' : 'umd',
globals
},
external,
plugins
}

if (!ESM) {
rollupConfig.output.name = 'bootstrap'
}

module.exports = rollupConfig
52 changes: 0 additions & 52 deletions build/ship.sh

This file was deleted.

10 changes: 6 additions & 4 deletions build/svgo.yml
Original file line number Diff line number Diff line change
@@ -15,10 +15,9 @@ js2svg:
indent: 2

plugins:
# remove this with IE 11 is no longer supported
- addAttributesToSVGElement:
attributes:
- focusable: false
# - addAttributesToSVGElement:
# attributes:
# - focusable: false
- cleanupAttrs: true
- cleanupEnableBackground: true
- cleanupIDs: true
@@ -35,6 +34,9 @@ plugins:
- minifyStyles: true
- moveElemsAttrsToGroup: true
- moveGroupAttrsToElems: true
- removeAttrs:
attrs:
- "data-name"
- removeComments: true
- removeDesc: true
- removeDoctype: true
25 changes: 13 additions & 12 deletions build/vnu-jar.js
Original file line number Diff line number Diff line change
@@ -2,9 +2,9 @@

/*!
* Script to run vnu-jar if Java is available.
* Copyright 2017-2019 The Bootstrap Authors
* Copyright 2017-2019 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
* Copyright 2017-2021 The Bootstrap Authors
* Copyright 2017-2021 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/

'use strict'
@@ -18,7 +18,7 @@ childProcess.exec('java -version', (error, stdout, stderr) => {
return
}

const is32bitJava = !stderr.match(/64-Bit/)
const is32bitJava = !/64-Bit/.test(stderr)

// vnu-jar accepts multiple ignores joined with a `|`.
// Also note that the ignores are regular expressions.
@@ -33,22 +33,23 @@ childProcess.exec('java -version', (error, stdout, stderr) => {
// Content → Reboot uses various date/time inputs as a visual example.
// Documentation does not rely on them being usable.
'The “date” input type is not supported in all browsers.*',
'The “time” input type is not supported in all browsers.*',
// IE11 doesn't recognise <main> / give the element an implicit "main" landmark.
// Explicit role="main" is redundant for other modern browsers, but still valid.
'The “main” role is unnecessary for element “main”.',
// Ignore the wrong lanuage code warnings for now; they happen randomly.
'This document appears to be written in.*'
'The “week” input type is not supported in all browsers.*',
'The “month” input type is not supported in all browsers.*',
'The “color” input type is not supported in all browsers.*',
'The “datetime-local” input type is not supported in all browsers.*',
'The “time” input type is not supported in all browsers.*'
].join('|')

const args = [
'-jar',
vnu,
`"${vnu}"`,
'--asciiquotes',
'--skip-non-html',
// Ignore the language code warnings
'--no-langdetect',
'--Werror',
`--filterpattern "${ignores}"`,
'_gh_pages/',
'_site/',
'js/tests/'
]

90 changes: 90 additions & 0 deletions build/zip-examples.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
#!/usr/bin/env node

/*!
* Script to create the built examples zip archive;
* requires the `zip` command to be present!
* Copyright 2020-2021 The Bootstrap Authors
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/

'use strict'

const path = require('path')
const sh = require('shelljs')

const pkg = require('../package.json')

const versionShort = pkg.config.version_short
const distFolder = `bootstrap-${pkg.version}-examples`
const rootDocsDir = '_site'
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

if (!sh.test('-d', rootDocsDir)) {
throw new Error(`The "${rootDocsDir}" folder does not exist, did you forget building the docs?`)
}

// switch to the root dir
sh.cd(path.join(__dirname, '..'))

// remove any previously created folder/zip with the same name
sh.rm('-rf', [distFolder, `${distFolder}.zip`])

// create any folders so that `cp` works
sh.mkdir('-p', [
distFolder,
`${distFolder}/assets/brand/`,
`${distFolder}/assets/dist/css/`,
`${distFolder}/assets/dist/js/`
])

sh.cp('-Rf', `${docsDir}/examples/*`, distFolder)

cssFiles.forEach(file => {
sh.cp('-f', `${docsDir}/dist/css/${file}`, `${distFolder}/assets/dist/css/`)
})

jsFiles.forEach(file => {
sh.cp('-f', `${docsDir}/dist/js/${file}`, `${distFolder}/assets/dist/js/`)
})

imgFiles.forEach(file => {
sh.cp('-f', `${docsDir}/assets/brand/${file}`, `${distFolder}/assets/brand/`)
})

sh.rm(`${distFolder}/index.html`)

// get all examples' HTML files
sh.find(`${distFolder}/**/*.html`).forEach(file => {
const fileContents = sh.cat(file)
.toString()
.replace(new RegExp(`"/docs/${versionShort}/`, 'g'), '"../')
.replace(/"..\/dist\//g, '"../assets/dist/')
.replace(/(<link href="\.\.\/.*) integrity=".*>/g, '$1>')
.replace(/(<script src="\.\.\/.*) integrity=".*>/g, '$1></script>')
.replace(/( +)<!-- favicons(.|\n)+<style>/i, ' <style>')
new sh.ShellString(fileContents).to(file)
})

// create the zip file
sh.exec(`zip -r9 "${distFolder}.zip" "${distFolder}"`)

// remove the folder we created
sh.rm('-rf', distFolder)
5 changes: 0 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
@@ -26,11 +26,6 @@
"issues": "https://github.com/twbs/bootstrap/issues"
},
"license": "MIT",
"extra": {
"branch-alias": {
"dev-master": "3.3.x-dev"
}
},
"replace": {
"twitter/bootstrap": "self.version"
}
79 changes: 79 additions & 0 deletions config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
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: "_site"

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"
current_ruby_version: "5.0.0"
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.zip"
dist: "https://github.com/twbs/bootstrap/releases/download/v5.0.0/bootstrap-5.0.0-dist.zip"
dist_examples: "https://github.com/twbs/bootstrap/releases/download/v5.0.0/bootstrap-5.0.0-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/dist/css/bootstrap.min.css"
css_hash: "sha384-wEmeIV1mKuiNpC+IOBjI7aAzPcEZeedi5yW5f2yOq55WWLwNGmvvx4Um1vskeMj0"
css_rtl: "https://cdn.jsdelivr.net/npm/bootstrap@5.0.0/dist/css/bootstrap.rtl.min.css"
css_rtl_hash: "sha384-jHiSqEim4+W1UCvv8kTcMbtCZlRF8MxbgKdfpvncia8gdN1UImBnhTpKtufREzv7"
js: "https://cdn.jsdelivr.net/npm/bootstrap@5.0.0/dist/js/bootstrap.min.js"
js_hash: "sha384-lpyLfhYuitXl2zRZ5Bn2fqnhNAKOAaM/0Kr9laMspuaMiZfGmfwRNFh8HlMy49eQ"
js_bundle: "https://cdn.jsdelivr.net/npm/bootstrap@5.0.0/dist/js/bootstrap.bundle.min.js"
js_bundle_hash: "sha384-p34f1UUtsS3wqzfto5wAAmdvj+osOnFyQFpp4Ua3gs/ZVWx6oOypYoCJhGGScy+8"
popper: "https://cdn.jsdelivr.net/npm/@popperjs/core@2.9.2/dist/umd/popper.min.js"
popper_hash: "sha384-IQsoLXl5PILFhosVNubq5LC7Qb9DXgDA9i+tQ8Zj3iwWAwPtgFTxbJ8NT4GN1R8p"
6,614 changes: 3,946 additions & 2,668 deletions dist/css/bootstrap-grid.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/css/bootstrap-grid.css.map

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions dist/css/bootstrap-grid.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/css/bootstrap-grid.min.css.map

Large diffs are not rendered by default.

4,996 changes: 4,996 additions & 0 deletions dist/css/bootstrap-grid.rtl.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap-grid.rtl.css.map

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions dist/css/bootstrap-grid.rtl.min.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap-grid.rtl.min.css.map

Large diffs are not rendered by default.

303 changes: 199 additions & 104 deletions dist/css/bootstrap-reboot.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/css/bootstrap-reboot.css.map

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions dist/css/bootstrap-reboot.min.css
2 changes: 1 addition & 1 deletion dist/css/bootstrap-reboot.min.css.map

Large diffs are not rendered by default.

423 changes: 423 additions & 0 deletions dist/css/bootstrap-reboot.rtl.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap-reboot.rtl.css.map

Large diffs are not rendered by default.

8 changes: 8 additions & 0 deletions dist/css/bootstrap-reboot.rtl.min.css
1 change: 1 addition & 0 deletions dist/css/bootstrap-reboot.rtl.min.css.map

Large diffs are not rendered by default.

4,752 changes: 4,752 additions & 0 deletions dist/css/bootstrap-utilities.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap-utilities.css.map

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions dist/css/bootstrap-utilities.min.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap-utilities.min.css.map

Large diffs are not rendered by default.

4,743 changes: 4,743 additions & 0 deletions dist/css/bootstrap-utilities.rtl.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap-utilities.rtl.css.map

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions dist/css/bootstrap-utilities.rtl.min.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap-utilities.rtl.min.css.map

Large diffs are not rendered by default.

14,361 changes: 7,576 additions & 6,785 deletions dist/css/bootstrap.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/css/bootstrap.css.map

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions dist/css/bootstrap.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/css/bootstrap.min.css.map

Large diffs are not rendered by default.

10,805 changes: 10,805 additions & 0 deletions dist/css/bootstrap.rtl.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap.rtl.css.map

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions dist/css/bootstrap.rtl.min.css

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/css/bootstrap.rtl.min.css.map

Large diffs are not rendered by default.

9,810 changes: 4,786 additions & 5,024 deletions dist/js/bootstrap.bundle.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/js/bootstrap.bundle.js.map

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions dist/js/bootstrap.bundle.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/js/bootstrap.bundle.min.js.map

Large diffs are not rendered by default.

4,994 changes: 4,994 additions & 0 deletions dist/js/bootstrap.esm.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/js/bootstrap.esm.js.map

Large diffs are not rendered by default.

7 changes: 7 additions & 0 deletions dist/js/bootstrap.esm.min.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions dist/js/bootstrap.esm.min.js.map

Large diffs are not rendered by default.

5,978 changes: 3,293 additions & 2,685 deletions dist/js/bootstrap.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/js/bootstrap.js.map

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions dist/js/bootstrap.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/js/bootstrap.min.js.map

Large diffs are not rendered by default.

313 changes: 189 additions & 124 deletions js/dist/alert.js
Loading