diff options
| author | Mark Otto <[email protected]> | 2017-08-15 10:43:45 -0700 |
|---|---|---|
| committer | Mark Otto <[email protected]> | 2017-08-15 10:43:45 -0700 |
| commit | e82d541836f063fc2ee4eb0111fdc9591015711f (patch) | |
| tree | 092e93d6eb0b963656fbee550e0f73eab2221111 | |
| parent | 62a3e9c1f061525973ff30e75996e79b3413c1b2 (diff) | |
| parent | b15041066089a6b533457468c2927f1c02d85ca9 (diff) | |
| download | bootstrap-e82d541836f063fc2ee4eb0111fdc9591015711f.tar.xz bootstrap-e82d541836f063fc2ee4eb0111fdc9591015711f.zip | |
Merge branch 'v4-dev' of https://github.com/twbs/bootstrap into v4-dev
28 files changed, 169 insertions, 78 deletions
@@ -1,6 +1,6 @@ <p align="center"> <a href="https://getbootstrap.com"> - <img src="http://getbootstrap.com/assets/brand/bootstrap-solid.svg" width=72 height=72> + <img src="https://getbootstrap.com/assets/brand/bootstrap-solid.svg" width=72 height=72> </a> <h3 align="center">Bootstrap</h3> diff --git a/_config.yml b/_config.yml index 92725a901..c40fc8841 100644 --- a/_config.yml +++ b/_config.yml @@ -1,21 +1,39 @@ # Dependencies -markdown: kramdown -highlighter: rouge +markdown: kramdown +highlighter: rouge kramdown: - auto_ids: true + auto_ids: true # Permalinks -permalink: pretty +permalink: pretty # Server -source: . -destination: ./_gh_pages -port: 9001 -baseurl: "" -url: https://getbootstrap.com -encoding: UTF-8 -exclude: [.git, .github, assets/scss/, build, js, node_modules, nuget, scss, vendor, bower.json, composer.json, Gemfile, Gemfile.lock, Gruntfile.js, package.js, package.json, package-lock.json, sache.json] +source: "." +destination: ./_gh_pages +port: 9001 +baseurl: "" +url: "https://getbootstrap.com" +encoding: UTF-8 +exclude: + - .git + - .github + - assets/scss/ + - build + - js + - node_modules + - nuget + - scss + - vendor + - bower.json + - composer.json + - Gemfile + - Gemfile.lock + - Gruntfile.js + - package.js + - package.json + - package-lock.json + - sache.json plugins: - jekyll-redirect-from @@ -23,35 +41,34 @@ plugins: - jekyll-toc # 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_logo_path: /assets/brand/bootstrap-social-logo.png -social_image_path: /assets/brand/bootstrap-social.png - -# Custom vars -current_version: 4.0.0-beta -docs_version: 4.0 -repo: https://github.com/twbs/bootstrap -slack: https://bootstrap-slack.herokuapp.com +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: /assets/brand/bootstrap-social.png +social_logo_path: /assets/brand/bootstrap-social-logo.png +# Custom variables +current_version: 4.0.0-beta +docs_version: 4.0 +repo: "https://github.com/twbs/bootstrap" +slack: "https://bootstrap-slack.herokuapp.com" download: - source: https://github.com/twbs/bootstrap/archive/v4.0.0-beta.zip - dist: https://github.com/twbs/bootstrap/releases/download/v4.0.0-beta/bootstrap-4.0.0-beta-dist.zip + source: "https://github.com/twbs/bootstrap/archive/v4.0.0-beta.zip" + dist: "https://github.com/twbs/bootstrap/releases/download/v4.0.0-beta/bootstrap-4.0.0-beta-dist.zip" -blog: https://blog.getbootstrap.com -expo: https://expo.getbootstrap.com -themes: https://themes.getbootstrap.com -jobs: https://jobs.getbootstrap.com +blog: "https://blog.getbootstrap.com" +expo: "https://expo.getbootstrap.com" +jobs: "https://jobs.getbootstrap.com" +themes: "https://themes.getbootstrap.com" cdn: # See https://www.srihash.org for info on how to generate the hashes - css: https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css - css_hash: "sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzALeQsN6M" - js: https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js - js_hash: "sha384-h0AbiXch4ZDo7tp9hKZ4TsHbi047NrKGLO3SEJAg45jXxnGIfYzk4Si90RDIqNm1" - jquery: https://code.jquery.com/jquery-3.2.1.slim.min.js - jquery_hash: "sha384-KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN" - popper: https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js - popper_hash: "sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKaMNFNmj4" + css: "https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css" + css_hash: "sha384-/Y6pD6FV/Vv2HJnA6t+vslU6fwYXjCFtcEpHbNJ0lyAFsXTsjBbfaDjzALeQsN6M" + js: "https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js" + js_hash: "sha384-h0AbiXch4ZDo7tp9hKZ4TsHbi047NrKGLO3SEJAg45jXxnGIfYzk4Si90RDIqNm1" + jquery: "https://code.jquery.com/jquery-3.2.1.slim.min.js" + jquery_hash: "sha384-KJ3o2DKtIkvYIK3UENzmM7KCkRr/rE9/Qpg6aAZGJwFDMVNA/GpGFF93hXpG5KkN" + popper: "https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js" + popper_hash: "sha384-b/U6ypiBEHpOf/4+1nzFpr53nxSS+GLCkfwBdFNTxtclqqenISfwAzpKaMNFNmj4" diff --git a/_data/nav.yml b/_data/nav.yml index c4c342dd2..784ec9a73 100644 --- a/_data/nav.yml +++ b/_data/nav.yml @@ -75,6 +75,8 @@ # - title: Approach - title: Icons +- title: Migration + - title: About pages: - title: History @@ -82,5 +84,3 @@ - title: Brand - title: License - title: Translations - -- title: Migration diff --git a/_includes/callout-danger-async-methods.md b/_includes/callout-danger-async-methods.md index c354d9c11..89d2e2cab 100644 --- a/_includes/callout-danger-async-methods.md +++ b/_includes/callout-danger-async-methods.md @@ -1,7 +1,7 @@ {% callout danger %} #### Asynchronous methods and transitions -All API methods are **asynchronous** and start a **transition**. They returns to the caller as soon as the transition is started but **before it ends**. In addition, a method call on a **transitioning component will be ignored**. +All API methods are **asynchronous** and start a **transition**. They return to the caller as soon as the transition is started but **before it ends**. In addition, a method call on a **transitioning component will be ignored**. [See our JavaScript documentation for more information.]({{ site.baseurl }}/docs/{{ site.docs_version }}/getting-started/javascript/) {% endcallout %} diff --git a/_includes/callout-warning-color-assistive-technologies.md b/_includes/callout-warning-color-assistive-technologies.md index b92a1c341..0b929e16d 100644 --- a/_includes/callout-warning-color-assistive-technologies.md +++ b/_includes/callout-warning-color-assistive-technologies.md @@ -2,4 +2,4 @@ #### Conveying meaning to assistive technologies Using color to add meaning only provides a visual indication, which will not be conveyed to users of assistive technologies – such as screen readers. Ensure that information denoted by the color is either obvious from the content itself (e.g. the visible text), or is included through alternative means, such as additional text hidden with the `.sr-only` class. -{% endcallout %}
\ No newline at end of file +{% endcallout %} diff --git a/_includes/docs-sidebar.html b/_includes/docs-sidebar.html index 71ea14f7d..00eaf47a6 100644 --- a/_includes/docs-sidebar.html +++ b/_includes/docs-sidebar.html @@ -1,37 +1,37 @@ <form class="bd-search d-flex align-items-center"> <input type="search" class="form-control" id="search-input" placeholder="Search..." aria-label="Search for..." autocomplete="off"> - <button class="btn-link bd-search-docs-toggle d-md-none p-0 ml-3" type="button" data-toggle="collapse" data-target="#bd-docs-nav" aria-controls="bd-docs-nav" aria-expanded="false" aria-label="Toggle docs avigation"> + <button class="btn-link bd-search-docs-toggle d-md-none p-0 ml-3" type="button" data-toggle="collapse" data-target="#bd-docs-nav" aria-controls="bd-docs-nav" aria-expanded="false" aria-label="Toggle docs navigation"> {% include icons/menu.svg class="" width="30" height="30" %} </button> </form> <nav class="collapse bd-links" id="bd-docs-nav"> - {% assign page_slug = page.url | split: '/' | last %} - {% for group in site.data.nav %} - {% assign link = group.pages | first %} - {% assign link_slug = link.title | slugify %} - {% assign group_slug = group.title | slugify %} - {% assign active = nil %} + {%- assign page_slug = page.url | split: '/' | last -%} + {%- for group in site.data.nav -%} + {%- assign link = group.pages | first -%} + {%- assign link_slug = link.title | slugify -%} + {%- assign group_slug = group.title | slugify -%} + {%- assign active = nil -%} - {% if page.group == group_slug %} - {% assign active = 'active' %} - {% endif %} + {%- if page.group == group_slug -%} + {%- assign active = 'active' -%} + {%- endif -%} - <div class="bd-toc-item {{ active }}"> + <div class="bd-toc-item{% unless active == nil %} {{ active }}{% endunless %}"> <a class="bd-toc-link" href="{{ site.baseurl }}/docs/{{ site.docs_version }}/{{ group_slug }}/{{ link_slug }}{% if link_slug %}/{% endif %}"> {{ group.title }} </a> <ul class="nav bd-sidenav"> - {% for doc in group.pages %} - {% assign doc_slug = doc.title | slugify %} - {% assign active = nil %} + {%- for doc in group.pages -%} + {%- assign doc_slug = doc.title | slugify -%} + {%- assign active = nil -%} - {% if page.group == group_slug and page_slug == doc_slug %} - {% assign active = 'active bd-sidenav-active' %} - {% endif %} + {%- if page.group == group_slug and page_slug == doc_slug -%} + {%- assign active = 'active bd-sidenav-active' -%} + {%- endif -%} - <li class="{{ active }}"> + <li{% unless active == nil %} class="{{ active }}"{% endunless %}> <a href="{{ site.baseurl }}/docs/{{ site.docs_version }}/{{ group_slug }}/{{ doc_slug }}/"> {{ doc.title }} </a> @@ -50,8 +50,8 @@ {% endunless %} {% endcomment %} </li> - {% endfor %} + {%- endfor -%} </ul> </div> - {% endfor %} + {%- endfor -%} </nav> diff --git a/_includes/favicons.html b/_includes/favicons.html new file mode 100644 index 000000000..97dab4ba8 --- /dev/null +++ b/_includes/favicons.html @@ -0,0 +1,9 @@ +<!-- Favicons --> +<link rel="apple-touch-icon" href="{{ site.baseurl }}/assets/img/favicons/apple-touch-icon.png" sizes="180x180"> +<link rel="icon" href="{{ site.baseurl }}/assets/img/favicons/favicon-32x32.png" sizes="32x32" type="image/png"> +<link rel="icon" href="{{ site.baseurl }}/assets/img/favicons/favicon-16x16.png" sizes="16x16" type="image/png"> +<link rel="manifest" href="{{ site.baseurl }}/assets/img/favicons/manifest.json"> +<link rel="mask-icon" href="{{ site.baseurl }}/assets/img/favicons/safari-pinned-tab.svg" color="#563d7c"> +<link rel="icon" href="{{ site.baseurl }}/favicon.ico"> +<meta name="msapplication-config" content="{{ site.baseurl }}/assets/img/favicons/browserconfig.xml"> +<meta name="theme-color" content="#563d7c"> diff --git a/_includes/header.html b/_includes/header.html index d9eac3db3..b6fad53e9 100644 --- a/_includes/header.html +++ b/_includes/header.html @@ -3,15 +3,13 @@ <meta name="generator" content="Jekyll v{{ jekyll.version }}"> <title> - {% if page.title %} + {%- if page.title -%} {{ page.title }} · {{ site.title }} - {% else %} + {%- else -%} {{ site.title }} · {{ site.description }} - {% endif %} + {%- endif -%} </title> -{% include social.html %} - <!-- Bootstrap core CSS --> {% if site.github %} <link href="{{ site.baseurl }}/dist/css/bootstrap.min.css" rel="stylesheet"> @@ -21,13 +19,11 @@ <!-- Documentation extras --> {% if page.layout == "docs" %} -<link rel="stylesheet" href="https://cdn.jsdelivr.net/docsearch.js/2/docsearch.min.css" /> +<link href="https://cdn.jsdelivr.net/docsearch.js/2/docsearch.min.css" rel="stylesheet"> {% endif %} <link href="{{ site.baseurl }}/assets/css/docs.min.css" rel="stylesheet"> -<!-- Favicons --> -<link rel="apple-touch-icon" href="{{ site.baseurl }}/apple-touch-icon.png"> -<link rel="icon" href="{{ site.baseurl }}/favicon.ico"> +{% include social.html %} <script> (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ diff --git a/_includes/scripts.html b/_includes/scripts.html index 058ba1b33..f457828ad 100644 --- a/_includes/scripts.html +++ b/_includes/scripts.html @@ -16,6 +16,7 @@ <script src="{{ site.baseurl }}/assets/js/vendor/clipboard.min.js"></script> <script src="{{ site.baseurl }}/assets/js/vendor/holder.min.js"></script> <script src="{{ site.baseurl }}/assets/js/src/application.js"></script> + <script src="{{ site.baseurl }}/assets/js/src/pwa.js"></script> {% endif %} <script src="{{ site.baseurl }}/assets/js/ie-emulation-modes-warning.js"></script> @@ -50,5 +51,5 @@ Holder.addTheme('gray', { fg: 'rgba(255,255,255,.75)', font: 'Helvetica', fontweight: 'normal' -}) +}); </script> diff --git a/_includes/social.html b/_includes/social.html index 35bd9fde3..977142b19 100644 --- a/_includes/social.html +++ b/_includes/social.html @@ -1,3 +1,7 @@ +<!-- Meta --> +<meta name="description" content="{{ site.description }}"> +<meta name="author" content="{{ site.authors }}"> + <!-- Twitter --> <meta name="twitter:site" content="@{{ site.twitter }}"> <meta name="twitter:creator" content="@{{ site.twitter }}"> @@ -30,7 +34,3 @@ <meta property="og:image:type" content="image/png"> <meta property="og:image:width" content="1200"> <meta property="og:image:height" content="630"> - -<!-- Meta --> -<meta name="description" content="{{ site.description }}"> -<meta name="author" content="{{ site.authors }}"> diff --git a/apple-touch-icon.png b/apple-touch-icon.png Binary files differdeleted file mode 100644 index b6b1e843b..000000000 --- a/apple-touch-icon.png +++ /dev/null diff --git a/assets/img/favicons/android-chrome-192x192.png b/assets/img/favicons/android-chrome-192x192.png Binary files differnew file mode 100644 index 000000000..547386f37 --- /dev/null +++ b/assets/img/favicons/android-chrome-192x192.png diff --git a/assets/img/favicons/android-chrome-512x512.png b/assets/img/favicons/android-chrome-512x512.png Binary files differnew file mode 100644 index 000000000..ebafe360f --- /dev/null +++ b/assets/img/favicons/android-chrome-512x512.png diff --git a/assets/img/favicons/apple-touch-icon.png b/assets/img/favicons/apple-touch-icon.png Binary files differnew file mode 100644 index 000000000..447cec2c4 --- /dev/null +++ b/assets/img/favicons/apple-touch-icon.png diff --git a/assets/img/favicons/browserconfig.xml b/assets/img/favicons/browserconfig.xml new file mode 100644 index 000000000..8b193171a --- /dev/null +++ b/assets/img/favicons/browserconfig.xml @@ -0,0 +1,11 @@ +--- +--- +<?xml version="1.0" encoding="utf-8"?> +<browserconfig> + <msapplication> + <tile> + <square150x150logo src="{{ site.baseurl }}/assets/img/favicons/mstile-150x150.png"/> + <TileColor>#563d7c</TileColor> + </tile> + </msapplication> +</browserconfig> diff --git a/assets/img/favicons/favicon-16x16.png b/assets/img/favicons/favicon-16x16.png Binary files differnew file mode 100644 index 000000000..5f7d11880 --- /dev/null +++ b/assets/img/favicons/favicon-16x16.png diff --git a/assets/img/favicons/favicon-32x32.png b/assets/img/favicons/favicon-32x32.png Binary files differnew file mode 100644 index 000000000..d752fd5d7 --- /dev/null +++ b/assets/img/favicons/favicon-32x32.png diff --git a/assets/img/favicons/manifest.json b/assets/img/favicons/manifest.json new file mode 100644 index 000000000..14cd52412 --- /dev/null +++ b/assets/img/favicons/manifest.json @@ -0,0 +1,22 @@ +--- +--- +{ + "name": "Bootstrap", + "short_name": "Bootstrap", + "icons": [ + { + "src": "{{ site.baseurl }}/assets/img/favicons/android-chrome-192x192.png", + "sizes": "192x192", + "type": "image/png" + }, + { + "src": "{{ site.baseurl }}/assets/img/favicons/android-chrome-512x512.png", + "sizes": "512x512", + "type": "image/png" + } + ], + "start_url": "/", + "theme_color": "#563d7c", + "background_color": "#563d7c", + "display": "standalone" +} diff --git a/assets/img/favicons/mstile-144x144.png b/assets/img/favicons/mstile-144x144.png Binary files differnew file mode 100644 index 000000000..262a3c2e1 --- /dev/null +++ b/assets/img/favicons/mstile-144x144.png diff --git a/assets/img/favicons/mstile-150x150.png b/assets/img/favicons/mstile-150x150.png Binary files differnew file mode 100644 index 000000000..bb87faf74 --- /dev/null +++ b/assets/img/favicons/mstile-150x150.png diff --git a/assets/img/favicons/mstile-310x150.png b/assets/img/favicons/mstile-310x150.png Binary files differnew file mode 100644 index 000000000..2fc36a726 --- /dev/null +++ b/assets/img/favicons/mstile-310x150.png diff --git a/assets/img/favicons/mstile-310x310.png b/assets/img/favicons/mstile-310x310.png Binary files differnew file mode 100644 index 000000000..7f00d0c66 --- /dev/null +++ b/assets/img/favicons/mstile-310x310.png diff --git a/assets/img/favicons/mstile-70x70.png b/assets/img/favicons/mstile-70x70.png Binary files differnew file mode 100644 index 000000000..4da2de9e3 --- /dev/null +++ b/assets/img/favicons/mstile-70x70.png diff --git a/assets/img/favicons/safari-pinned-tab.svg b/assets/img/favicons/safari-pinned-tab.svg new file mode 100644 index 000000000..086866a17 --- /dev/null +++ b/assets/img/favicons/safari-pinned-tab.svg @@ -0,0 +1,20 @@ +<?xml version="1.0" standalone="no"?> +<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 20010904//EN" + "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd"> +<svg version="1.0" xmlns="http://www.w3.org/2000/svg" + width="700.000000pt" height="700.000000pt" viewBox="0 0 700.000000 700.000000" + preserveAspectRatio="xMidYMid meet"> +<metadata> +Created by potrace 1.11, written by Peter Selinger 2001-2013 +</metadata> +<g transform="translate(0.000000,700.000000) scale(0.100000,-0.100000)" +fill="#000000" stroke="none"> +<path d="M975 6983 c-494 -88 -870 -467 -959 -965 -13 -72 -15 -404 -14 -2513 +0 -1970 3 -2446 13 -2515 46 -295 206 -564 445 -747 60 -46 164 -113 175 -113 +3 0 31 -13 62 -28 73 -35 146 -58 260 -82 84 -17 196 -18 2563 -16 2334 1 +2479 3 2545 19 39 10 77 20 85 22 74 18 226 87 310 139 92 58 255 209 298 276 +9 14 28 41 43 60 36 48 111 200 138 280 12 36 30 106 40 155 18 86 19 188 17 +2570 l-1 2480 -27 95 c-52 188 -106 300 -207 434 -170 225 -400 372 -691 442 +-71 17 -200 18 -2545 20 -2111 2 -2482 0 -2550 -13z"/> +</g> +</svg> diff --git a/assets/js/src/pwa.js b/assets/js/src/pwa.js new file mode 100644 index 000000000..95ee33948 --- /dev/null +++ b/assets/js/src/pwa.js @@ -0,0 +1,15 @@ +/* eslint no-console:off */ + +(function setupSW() { + 'use strict' + + if ('serviceWorker' in navigator) { + window.addEventListener('load', function () { + navigator.serviceWorker.register('/sw.js').then(function (registration) { + console.log('ServiceWorker registration successful with scope: ', registration.scope) + }).catch(function (err) { + console.log('ServiceWorker registration failed: ', err) + }) + }) + } +}()) diff --git a/docs/4.0/layout/overview.md b/docs/4.0/layout/overview.md index 459191719..c86a432d3 100644 --- a/docs/4.0/layout/overview.md +++ b/docs/4.0/layout/overview.md @@ -162,7 +162,6 @@ Several Bootstrap components utilize `z-index`, the CSS property that helps cont We don't encourage customization of these values; should you change one, you likely need to change them all. ```scss -$zindex-dropdown-backdrop: 990 !default; $zindex-dropdown: 1000 !default; $zindex-fixed: 1030 !default; $zindex-sticky: 1030 !default; diff --git a/package.json b/package.json index 0f0618284..a88d0498b 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,7 @@ "js-compile-bundle": "shx cat js/src/util.js js/src/alert.js js/src/button.js js/src/carousel.js js/src/collapse.js js/src/dropdown.js js/src/modal.js js/src/scrollspy.js js/src/tab.js js/src/tooltip.js js/src/popover.js | shx sed \"s/^(import|export).*//\" | babel --filename js/src/bootstrap.js | node build/stamp.js > dist/js/bootstrap.js", "js-compile-plugins": "babel js/src/ --out-dir js/dist/ --source-maps", "js-minify": "uglifyjs --config-file build/uglifyjs.config.json --output dist/js/bootstrap.min.js dist/js/bootstrap.js", - "js-minify-docs": "uglifyjs --config-file build/uglifyjs.config.json --output assets/js/docs.min.js assets/js/vendor/anchor.min.js assets/js/vendor/clipboard.min.js assets/js/vendor/holder.min.js assets/js/src/application.js", + "js-minify-docs": "uglifyjs --config-file build/uglifyjs.config.json --output assets/js/docs.min.js assets/js/vendor/anchor.min.js assets/js/vendor/clipboard.min.js assets/js/vendor/holder.min.js assets/js/src/application.js assets/js/src/pwa.js", "js-test": "phantomjs ./node_modules/qunit-phantomjs-runner/runner.js js/tests/index.html 60", "js-test-cloud": "ruby -r webrick -e \"s = WEBrick::HTTPServer.new(:Port => 3000, :DocumentRoot => Dir.pwd, :Logger => WEBrick::Log.new('/dev/null'), :AccessLog => []); trap('INT') { s.shutdown }; s.start\" & grunt saucelabs-qunit", "docs": "npm-run-all docs-compile docs-lint", @@ -0,0 +1 @@ +// empty for now |
