Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies. #25840

Merged
merged 10 commits into from
Mar 21, 2018
Merged
Show file tree
Hide file tree
Changes from 9 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,8 @@ cdn:
js_hash: "sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl"
jquery: "https://code.jquery.com/jquery-3.3.1.slim.min.js"
jquery_hash: "sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo"
popper: "https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.12.9/umd/popper.min.js"
popper_hash: "sha384-ApNbgh9B+Y1QKtv3Rn7W3mgPxhU9K/ScQsAP7hUibX39j7fakFPskvXusvfa0b4Q"
popper: "https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js"
popper_hash: "sha384-cs/chFZiN24E4KMATLdqdvsezGxaGsi4hLGOzlXwp5UZB1LY//20VyM2taTB4QvJ"

toc:
min_level: 2
Expand Down
4 changes: 2 additions & 2 deletions assets/js/src/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* details, see https://creativecommons.org/licenses/by/3.0/.
*/

/* global Clipboard: false, anchors: false, Holder: false */
/* global ClipboardJS: false, anchors: false, Holder: false */

(function ($) {
'use strict'
Expand Down Expand Up @@ -66,7 +66,7 @@
})
})

var clipboard = new Clipboard('.btn-clipboard', {
var clipboard = new ClipboardJS('.btn-clipboard', {
target: function (trigger) {
return trigger.parentNode.nextElementSibling
}
Expand Down
6 changes: 3 additions & 3 deletions assets/js/vendor/clipboard.min.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions assets/js/vendor/popper.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion build/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const plugins = [
'defineProperties',
'createClass',
'inheritsLoose',
'extends'
'objectSpread'
]
})
]
Expand Down
27 changes: 19 additions & 8 deletions build/workbox.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,25 +16,36 @@ const workboxSWDestMapPath = `${workboxSWDestPath}.map`
fs.createReadStream(workboxSWSrcPath).pipe(fs.createWriteStream(workboxSWDestPath))
fs.createReadStream(workboxSWSrcMapPath).pipe(fs.createWriteStream(workboxSWDestMapPath))

const updateUrl = (manifestEntries) => manifestEntries.map((entry) => {
if (entry.url.startsWith(buildPrefix)) {
const regex = new RegExp(buildPrefix, 'g')
entry.url = entry.url.replace(regex, '')
const updateUrl = (manifestEntries) => {
const manifest = manifestEntries.map((entry) => {
if (entry.url.startsWith(buildPrefix)) {
const regex = new RegExp(buildPrefix, 'g')
entry.url = entry.url.replace(regex, '')
}
return entry
})
return {
manifest,
warnings: []
}
return entry
})
}

config.manifestTransforms = [updateUrl]

swBuild.injectManifest(config).then(() => {
swBuild.injectManifest(config).then(({
count,
size
}) => {
const wbSwRegex = /{fileName}/g
fs.readFile(config.swDest, 'utf8', (err, data) => {
if (err) {
throw err
}
const swFileContents = data.replace(wbSwRegex, wbFileName)
fs.writeFile(config.swDest, swFileContents, () => {
console.log('Pre-cache Manifest generated.')
console.log(`Pre-cache Manifest generated. Pre-cached ${count} files, totalling ${size} bytes.`)
})
})
}).catch((error) => {
console.error(`Something went wrong: ${error}`)
})
6 changes: 3 additions & 3 deletions js/tests/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@
<script src="../../assets/js/vendor/popper.min.js"></script>

<!-- QUnit -->
<link rel="stylesheet" href="vendor/qunit.css" media="screen">
<script src="vendor/qunit.js"></script>
<link rel="stylesheet" href="../../node_modules/qunitjs/qunit/qunit.css" media="screen">
<script src="../../node_modules/qunitjs/qunit/qunit.js"></script>

<!-- Sinon -->
<script src="vendor/sinon.min.js"></script>
<script src="../../node_modules/sinon/pkg/sinon-no-sourcemaps.js"></script>

<script>
// Disable jQuery event aliases to ensure we don't accidentally use any of them
Expand Down
Loading