diff --git a/.editorconfig b/.editorconfig index 854167bbed..ed2a319d58 100644 --- a/.editorconfig +++ b/.editorconfig @@ -8,6 +8,9 @@ indent_size = 2 charset = utf-8 trim_trailing_whitespace = true +[test/**/expected.css] +insert_final_newline = false + [{package.json,.travis.yml,.eslintrc.json}] indent_style = space indent_size = 2 diff --git a/CHANGELOG.md b/CHANGELOG.md index dd5a52c0ae..d3e7b5a137 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,43 @@ # Svelte changelog +## 2.8.1 + +* Fix prefixed animation name replacement ([#1556](https://github.com/sveltejs/svelte/pull/1556)) + +## 2.8.0 + +* Correctly set store on nested components (to parent store, not root store) ([#1538](https://github.com/sveltejs/svelte/issues/1538)) + +## 2.7.2 + +* Prevent unnecessary remounts ([#1527](https://github.com/sveltejs/svelte/issues/1527)) +* Allow `refs.*` as callee ([#1526](https://github.com/sveltejs/svelte/pull/1526)) +* Handle empty lists when outroing ([#1532](https://github.com/sveltejs/svelte/issues/1532)) + +## 2.7.1 + +* Fix spread props with multiple dependencies ([#1515](https://github.com/sveltejs/svelte/issues/1515)) + +## 2.7.0 + +* Add `__svelte_meta` object to elements in dev mode, containing source info ([#1499](https://github.com/sveltejs/svelte/issues/1499)) +* Fix `bind:online` in dev mode ([#1502](https://github.com/sveltejs/svelte/issues/1502)) +* Update v1 warnings/errors ([#1508](https://github.com/sveltejs/svelte/pull/1508)) +* Transform prefixed keyframes ([#1504](https://github.com/sveltejs/svelte/issues/1504)) + +## 2.6.6 + +* Fix nested transition bug ([#1497](https://github.com/sveltejs/svelte/issues/1497)) + +## 2.6.5 + +* Handle cases where only some `if` block branches have outros ([#1492](https://github.com/sveltejs/svelte/issues/1492)) + +## 2.6.4 + +* Web worker support ([#1487](https://github.com/sveltejs/svelte/issues/1487)) +* Update dynamic component bindings when component changes ([#1489](https://github.com/sveltejs/svelte/issues/1489)) + ## 2.6.3 * Nested transitions respect `skipIntroByDefault` ([#1460](https://github.com/sveltejs/svelte/issues/1460)) diff --git a/package.json b/package.json index 0e8cfe1880..16f3142e90 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "svelte", - "version": "2.6.3", + "version": "2.8.1", "description": "The magical disappearing UI framework", "main": "compiler/svelte.js", "bin": { @@ -82,6 +82,7 @@ "rollup-watch": "^4.3.1", "sade": "^1.4.0", "sander": "^0.6.0", + "shelljs": "^0.8.2", "source-map": "0.6", "source-map-support": "^0.5.4", "tiny-glob": "^0.2.1", diff --git a/src/Stats.ts b/src/Stats.ts index 6faca18e75..613064f987 100644 --- a/src/Stats.ts +++ b/src/Stats.ts @@ -6,7 +6,7 @@ const now = (typeof process !== 'undefined' && process.hrtime) const t = process.hrtime(); return t[0] * 1e3 + t[1] / 1e6; } - : () => window.performance.now(); + : () => self.performance.now(); type Timing = { label: string; diff --git a/src/compile/Compiler.ts b/src/compile/Compiler.ts index 4a0371da2a..a9c8d69a4f 100644 --- a/src/compile/Compiler.ts +++ b/src/compile/Compiler.ts @@ -117,6 +117,8 @@ export default class Compiler { expectedProperties: Set; usesRefs: boolean; + file: string; + fileVar: string; locate: (c: number) => { line: number, column: number }; stylesheet: Stylesheet; @@ -159,6 +161,9 @@ export default class Compiler { this.bindingGroups = []; this.indirectDependencies = new Map(); + this.file = options.filename && ( + typeof process !== 'undefined' ? options.filename.replace(process.cwd(), '').replace(/^[\/\\]/, '') : options.filename + ); this.locate = getLocator(this.source); // track which properties are needed, so we can provide useful info @@ -178,6 +183,8 @@ export default class Compiler { this.aliases = new Map(); this.usedNames = new Set(); + this.fileVar = options.dev && this.getUniqueName('file'); + this.computations = []; this.templateProperties = {}; diff --git a/src/compile/dom/Block.ts b/src/compile/dom/Block.ts index 62349bbcd6..2eae42d905 100644 --- a/src/compile/dom/Block.ts +++ b/src/compile/dom/Block.ts @@ -44,7 +44,9 @@ export default class Block { maintainContext: boolean; hasAnimation: boolean; - hasIntroMethod: boolean; + hasIntros: boolean; + hasOutros: boolean; + hasIntroMethod: boolean; // could have the method without the transition, due to siblings hasOutroMethod: boolean; outros: number; @@ -132,11 +134,11 @@ export default class Block { } addIntro() { - this.hasIntroMethod = this.compiler.target.hasIntroTransitions = true; + this.hasIntros = this.hasIntroMethod = this.compiler.target.hasIntroTransitions = true; } addOutro() { - this.hasOutroMethod = this.compiler.target.hasOutroTransitions = true; + this.hasOutros = this.hasOutroMethod = this.compiler.target.hasOutroTransitions = true; this.outros += 1; } @@ -145,6 +147,10 @@ export default class Block { } addVariable(name: string, init?: string) { + if (name[0] === '#') { + name = this.alias(name.slice(1)); + } + if (this.variables.has(name) && this.variables.get(name) !== init) { throw new Error( `Variable '${name}' already initialised with a different value` @@ -169,18 +175,16 @@ export default class Block { toString() { const { dev } = this.compiler.options; - let introing; - const hasIntros = !this.builders.intro.isEmpty(); - if (hasIntros) { - introing = this.getUniqueName('introing'); - this.addVariable(introing); - } + if (this.hasIntroMethod || this.hasOutroMethod) { + this.addVariable('#current'); - let outroing; - const hasOutros = !this.builders.outro.isEmpty(); - if (hasOutros) { - outroing = this.alias('outroing'); - this.addVariable(outroing); + if (!this.builders.mount.isEmpty()) { + this.builders.mount.addLine(`#current = true;`); + } + + if (!this.builders.outro.isEmpty()) { + this.builders.outro.addLine(`#current = false;`); + } } if (this.autofocus) { @@ -278,46 +282,30 @@ export default class Block { } if (this.hasIntroMethod || this.hasOutroMethod) { - if (hasIntros) { + if (this.builders.mount.isEmpty()) { + properties.addBlock(`i: @noop,`); + } else { properties.addBlock(deindent` ${dev ? 'i: function intro' : 'i'}(#target, anchor) { - if (${introing}) return; - ${introing} = true; - ${hasOutros && `${outroing} = false;`} - + if (#current) return; ${this.builders.intro} - this.m(#target, anchor); }, `); - } else { - if (this.builders.mount.isEmpty()) { - properties.addBlock(`i: @noop,`); - } else { - properties.addBlock(deindent` - ${dev ? 'i: function intro' : 'i'}(#target, anchor) { - this.m(#target, anchor); - }, - `); - } } - if (hasOutros) { + if (this.builders.outro.isEmpty()) { + properties.addBlock(`o: @run,`); + } else { properties.addBlock(deindent` ${dev ? 'o: function outro' : 'o'}(#outrocallback) { - if (${outroing}) return; - ${outroing} = true; - ${hasIntros && `${introing} = false;`} + if (!#current) return; ${this.outros > 1 && `#outrocallback = @callAfter(#outrocallback, ${this.outros});`} ${this.builders.outro} }, `); - } else { - properties.addBlock(deindent` - o: @run, - `); } } diff --git a/src/compile/dom/index.ts b/src/compile/dom/index.ts index 0d8746b5bb..1cceb896a5 100644 --- a/src/compile/dom/index.ts +++ b/src/compile/dom/index.ts @@ -100,6 +100,10 @@ export default function dom( builder.addBlock(compiler.javascript); } + if (compiler.options.dev) { + builder.addLine(`const ${compiler.fileVar} = ${JSON.stringify(compiler.file)};`); + } + const css = compiler.stylesheet.render(options.filename, !compiler.customElement); const styles = compiler.stylesheet.hasStyles && stringify(options.dev ? `${css.code}\n/*# sourceMappingURL=${css.map.toUrl()} */` : @@ -360,12 +364,8 @@ export default function dom( let result = builder.toString(); - const filename = options.filename && ( - typeof process !== 'undefined' ? options.filename.replace(process.cwd(), '').replace(/^[\/\\]/, '') : options.filename - ); - return compiler.generate(result, options, { - banner: `/* ${filename ? `${filename} ` : ``}generated by Svelte v${"__VERSION__"} */`, + banner: `/* ${compiler.file ? `${compiler.file} ` : ``}generated by Svelte v${"__VERSION__"} */`, sharedPath, name, format, diff --git a/src/compile/nodes/Attribute.ts b/src/compile/nodes/Attribute.ts index b933ca2e7c..53996469e9 100644 --- a/src/compile/nodes/Attribute.ts +++ b/src/compile/nodes/Attribute.ts @@ -232,7 +232,7 @@ export default class Attribute extends Node { if (this.dependencies.size || isSelectValueAttribute) { const dependencies = Array.from(this.dependencies); const changedCheck = ( - ( block.hasOutroMethod ? `#outroing || ` : '' ) + + (block.hasOutros ? `!#current || ` : '') + dependencies.map(dependency => `changed.${dependency}`).join(' || ') ); @@ -308,7 +308,7 @@ export default class Attribute extends Node { if (propDependencies.size) { const dependencies = Array.from(propDependencies); const condition = ( - (block.hasOutroMethod ? `#outroing || ` : '') + + (block.hasOutros ? `!#current || ` : '') + dependencies.map(dependency => `changed.${dependency}`).join(' || ') ); diff --git a/src/compile/nodes/AwaitBlock.ts b/src/compile/nodes/AwaitBlock.ts index 9a8aa51020..4897adcd59 100644 --- a/src/compile/nodes/AwaitBlock.ts +++ b/src/compile/nodes/AwaitBlock.ts @@ -61,8 +61,8 @@ export default class AwaitBlock extends Node { block.addDependencies(child.block.dependencies); } - if (child.block.hasIntroMethod) hasIntros = true; - if (child.block.hasOutroMethod) hasOutros = true; + if (child.block.hasIntros) hasIntros = true; + if (child.block.hasOutros) hasOutros = true; }); this.pending.block.hasUpdateMethod = isDynamic; @@ -172,12 +172,13 @@ export default class AwaitBlock extends Node { } if (this.pending.block.hasOutroMethod && this.compiler.options.nestedTransitions) { + const countdown = block.getUniqueName('countdown'); block.builders.outro.addBlock(deindent` - #outrocallback = @callAfter(#outrocallback, 3); + const ${countdown} = @callAfter(#outrocallback, 3); for (let #i = 0; #i < 3; #i += 1) { const block = ${info}.blocks[#i]; - if (block) block.o(#outrocallback); - else #outrocallback(); + if (block) block.o(${countdown}); + else ${countdown}(); } `); } diff --git a/src/compile/nodes/Component.ts b/src/compile/nodes/Component.ts index a782ca34db..736b2306ea 100644 --- a/src/compile/nodes/Component.ts +++ b/src/compile/nodes/Component.ts @@ -123,7 +123,7 @@ export default class Component extends Node { const name = this.var; - const componentInitProperties = [`root: #component.root`]; + const componentInitProperties = [`root: #component.root`, `store: #component.store`]; if (this.children.length > 0) { const slots = Array.from(this._slots).map(name => `${quoteNameIfNecessary(name)}: @createFragment()`); @@ -176,7 +176,7 @@ export default class Component extends Node { const { name, dependencies } = attr; const condition = dependencies.size > 0 && (dependencies.size !== allDependencies.size) - ? [...dependencies].map(d => `changed.${d}`).join(' || ') + ? `(${[...dependencies].map(d => `changed.${d}`).join(' || ')})` : null; if (attr.isSpread) { @@ -290,7 +290,7 @@ export default class Component extends Node { } statements.push(deindent` - if (${binding.prop} in ${binding.obj}) { + if (${binding.value.snippet} !== void 0) { ${name_initial_data}.${binding.name} = ${binding.value.snippet}; ${name_updating}.${binding.name} = true; }` @@ -304,7 +304,7 @@ export default class Component extends Node { updates.push(deindent` if (!${name_updating}.${binding.name} && ${[...binding.value.dependencies].map((dependency: string) => `changed.${dependency}`).join(' || ')}) { ${name_changes}.${binding.name} = ${binding.value.snippet}; - ${name_updating}.${binding.name} = true; + ${name_updating}.${binding.name} = ${binding.value.snippet} !== void 0; } `); }); @@ -318,7 +318,7 @@ export default class Component extends Node { // TODO use component.on('state', ...) instead of _bind componentInitProperties.push(deindent` - _bind: function(changed, childState) { + _bind(changed, childState) { var ${initialisers}; ${builder} ${hasStoreBindings && `#component.store.set(newStoreState);`} @@ -328,7 +328,7 @@ export default class Component extends Node { `); beforecreate = deindent` - #component.root._beforecreate.push(function() { + #component.root._beforecreate.push(() => { ${name}._bind({ ${this.bindings.map(b => `${b.name}: 1`).join(', ')} }, ${name}.get()); }); `; @@ -406,6 +406,14 @@ export default class Component extends Node { if (${switch_value}) { ${name} = new ${switch_value}(${switch_props}(ctx)); + + ${this.bindings.length > 0 && deindent` + #component.root._beforecreate.push(() => { + const changed = {}; + ${this.bindings.map(binding => deindent` + if (${binding.value.snippet} === void 0) changed.${binding.name} = 1;`)} + ${name}._bind(changed, ${name}.get()); + });`} ${name}._fragment.c(); ${this.children.map(child => child.remount(name))} @@ -554,8 +562,8 @@ export default class Component extends Node { const expression = ( this.name === 'svelte:self' ? this.compiler.name : - isDynamicComponent ? `((${this.expression.snippet}) || @missingComponent)` : - `%components-${this.name}` + (isDynamicComponent ? `((${this.expression.snippet}) || @missingComponent)` : + `%components-${this.name}`) ); this.bindings.forEach(binding => { diff --git a/src/compile/nodes/EachBlock.ts b/src/compile/nodes/EachBlock.ts index 70ce3ab218..adf23d85c9 100644 --- a/src/compile/nodes/EachBlock.ts +++ b/src/compile/nodes/EachBlock.ts @@ -119,7 +119,7 @@ export default class EachBlock extends Node { this.else.block.hasUpdateMethod = this.else.block.dependencies.size > 0; } - if (this.block.hasOutroMethod || (this.else && this.else.block.hasOutroMethod)) { + if (this.block.hasOutros || (this.else && this.else.block.hasOutros)) { block.addOutro(); } } @@ -317,23 +317,24 @@ export default class EachBlock extends Node { const rects = block.getUniqueName('rects'); const destroy = this.block.hasAnimation ? `@fixAndOutroAndDestroyBlock` - : this.block.hasOutroMethod + : this.block.hasOutros ? `@outroAndDestroyBlock` : `@destroyBlock`; block.builders.update.addBlock(deindent` const ${this.each_block_value} = ${snippet}; - ${this.block.hasOutroMethod && `@transitionManager.groupOutros();`} + ${this.block.hasOutros && `@transitionManager.groupOutros();`} ${this.block.hasAnimation && `for (let #i = 0; #i < ${blocks}.length; #i += 1) ${blocks}[#i].r();`} ${blocks} = @updateKeyedEach(${blocks}, #component, changed, ${get_key}, ${dynamic ? '1' : '0'}, ctx, ${this.each_block_value}, ${lookup}, ${updateMountNode}, ${destroy}, ${create_each_block}, "${mountOrIntro}", ${anchor}, ${this.get_each_context}); ${this.block.hasAnimation && `for (let #i = 0; #i < ${blocks}.length; #i += 1) ${blocks}[#i].a();`} `); if (this.compiler.options.nestedTransitions) { + const countdown = block.getUniqueName('countdown'); block.builders.outro.addBlock(deindent` - #outrocallback = @callAfter(#outrocallback, ${blocks}.length); - for (#i = 0; #i < ${blocks}.length; #i += 1) ${blocks}[#i].o(#outrocallback); + const ${countdown} = @callAfter(#outrocallback, ${blocks}.length); + for (#i = 0; #i < ${blocks}.length; #i += 1) ${blocks}[#i].o(${countdown}); `); } @@ -393,14 +394,16 @@ export default class EachBlock extends Node { allDependencies.add(dependency); }); - const outro = this.block.hasOutroMethod && block.getUniqueName('outro') - if (outro) { + const outroBlock = this.block.hasOutros && block.getUniqueName('outroBlock') + if (outroBlock) { block.builders.init.addBlock(deindent` - function ${outro}(i, detach, fn) { + function ${outroBlock}(i, detach, fn) { if (${iterations}[i]) { ${iterations}[i].o(() => { - ${iterations}[i].d(detach); - if (detach) ${iterations}[i] = null; + if (detach) { + ${iterations}[i].d(detach); + ${iterations}[i] = null; + } if (fn) fn(); }); } @@ -415,7 +418,7 @@ export default class EachBlock extends Node { if (condition !== '') { const forLoopBody = this.block.hasUpdateMethod - ? (this.block.hasIntroMethod || this.block.hasOutroMethod) + ? (this.block.hasIntros || this.block.hasOutros) ? deindent` if (${iterations}[#i]) { ${iterations}[#i].p(changed, child_ctx); @@ -444,10 +447,10 @@ export default class EachBlock extends Node { let destroy; - if (this.block.hasOutroMethod) { + if (this.block.hasOutros) { destroy = deindent` @transitionManager.groupOutros(); - for (; #i < ${iterations}.length; #i += 1) ${outro}(#i, 1); + for (; #i < ${iterations}.length; #i += 1) ${outroBlock}(#i, 1); `; } else { destroy = deindent` @@ -473,10 +476,11 @@ export default class EachBlock extends Node { `); } - if (outro && this.compiler.options.nestedTransitions) { + if (outroBlock && this.compiler.options.nestedTransitions) { + const countdown = block.getUniqueName('countdown'); block.builders.outro.addBlock(deindent` - #outrocallback = @callAfter(#outrocallback, #i); - for (let #i = 0; #i < ${iterations}.length; #i += 1) ${outro}(#i, 0, #outrocallback);` + const ${countdown} = @callAfter(#outrocallback, ${iterations}.length); + for (let #i = 0; #i < ${iterations}.length; #i += 1) ${outroBlock}(#i, 0, ${countdown});` ); } diff --git a/src/compile/nodes/Element.ts b/src/compile/nodes/Element.ts index 34203d5c63..6c174f0272 100644 --- a/src/compile/nodes/Element.ts +++ b/src/compile/nodes/Element.ts @@ -143,7 +143,7 @@ export default class Element extends Node { stripWhitespace: boolean, nextSibling: Node ) { - if (this.name === 'slot' || this.name === 'option') { + if (this.name === 'slot' || this.name === 'option' || this.compiler.options.dev) { this.cannotUseInnerHTML(); } @@ -300,13 +300,6 @@ export default class Element extends Node { block.builders.destroy.addConditional('detach', `@detachNode(${name});`); } - // TODO move this into a class as well? - if (this._cssRefAttribute) { - block.builders.hydrate.addLine( - `@setAttribute(${name}, "svelte-ref-${this._cssRefAttribute}", "");` - ) - } - // insert static children with textContent or innerHTML if (!this.namespace && this.canUseInnerHTML && this.children.length > 0) { if (this.children.length === 1 && this.children[0].type === 'Text') { @@ -394,10 +387,6 @@ export default class Element extends Node { let open = `<${node.name}`; - if (node._cssRefAttribute) { - open += ` svelte-ref-${node._cssRefAttribute}`; - } - node.attributes.forEach((attr: Node) => { open += ` ${fixAttributeCasing(attr.name)}${stringifyAttributeValue(attr.chunks)}` }); @@ -406,6 +395,13 @@ export default class Element extends Node { return `${open}>${node.children.map(toHTML).join('')}`; } + + if (this.compiler.options.dev) { + const loc = this.compiler.locate(this.start); + block.builders.hydrate.addLine( + `@addLoc(${this.var}, ${this.compiler.fileVar}, ${loc.line}, ${loc.column}, ${this.start});` + ); + } } addBindings( @@ -563,7 +559,7 @@ export default class Element extends Node { .filter(attr => attr.type === 'Attribute' || attr.type === 'Spread') .forEach(attr => { const condition = attr.dependencies.size > 0 - ? [...attr.dependencies].map(d => `changed.${d}`).join(' || ') + ? `(${[...attr.dependencies].map(d => `changed.${d}`).join(' || ')})` : null; if (attr.isSpread) { @@ -858,19 +854,17 @@ export default class Element extends Node { return `@appendNode(${this.var}, ${name}._slotted.default);`; } - addCssClass() { + addCssClass(className = this.compiler.stylesheet.id) { const classAttribute = this.attributes.find(a => a.name === 'class'); if (classAttribute && !classAttribute.isTrue) { if (classAttribute.chunks.length === 1 && classAttribute.chunks[0].type === 'Text') { - (classAttribute.chunks[0]).data += ` ${this.compiler.stylesheet.id}`; + (classAttribute.chunks[0]).data += ` ${className}`; } else { (classAttribute.chunks).push( new Text(this.compiler, this, this.scope, { type: 'Text', - data: ` ${this.compiler.stylesheet.id}` + data: ` ${className}` }) - - // new Text({ type: 'Text', data: ` ${this.compiler.stylesheet.id}` }) ); } } else { @@ -878,7 +872,7 @@ export default class Element extends Node { new Attribute(this.compiler, this, this.scope, { type: 'Attribute', name: 'class', - value: [{ type: 'Text', data: `${this.compiler.stylesheet.id}` }] + value: [{ type: 'Text', data: className }] }) ); } @@ -945,10 +939,6 @@ export default class Element extends Node { }); } - if (this._cssRefAttribute) { - openingTag += ` svelte-ref-${this._cssRefAttribute}`; - } - openingTag += '>'; compiler.target.append(openingTag); diff --git a/src/compile/nodes/IfBlock.ts b/src/compile/nodes/IfBlock.ts index 87727e5b9e..ee5cb41a83 100644 --- a/src/compile/nodes/IfBlock.ts +++ b/src/compile/nodes/IfBlock.ts @@ -68,8 +68,8 @@ export default class IfBlock extends Node { block.addDependencies(node.block.dependencies); } - if (node.block.hasIntroMethod) hasIntros = true; - if (node.block.hasOutroMethod) hasOutros = true; + if (node.block.hasIntros) hasIntros = true; + if (node.block.hasOutros) hasOutros = true; if (isElseIf(node.else)) { attachBlocks(node.else.children[0]); @@ -147,9 +147,10 @@ export default class IfBlock extends Node { this.buildSimple(block, parentNode, parentNodes, branches[0], dynamic, vars); if (hasOutros && this.compiler.options.nestedTransitions) { - block.builders.outro.addLine( - `if (${name}) ${name}.o(#outrocallback);` - ); + block.builders.outro.addBlock(deindent` + if (${name}) ${name}.o(#outrocallback); + else #outrocallback(); + `); } } @@ -302,8 +303,8 @@ export default class IfBlock extends Node { const destroyOldBlock = deindent` @transitionManager.groupOutros(); ${name}.o(function() { - ${if_blocks}[ ${previous_block_index} ].d(1); - ${if_blocks}[ ${previous_block_index} ] = null; + ${if_blocks}[${previous_block_index}].d(1); + ${if_blocks}[${previous_block_index}] = null; }); `; @@ -355,9 +356,7 @@ export default class IfBlock extends Node { } block.builders.destroy.addLine(deindent` - ${if_current_block_type_index}{ - ${if_blocks}[${current_block_type_index}].d(${parentNode ? '' : 'detach'}); - } + ${if_current_block_type_index}${if_blocks}[${current_block_type_index}].d(${parentNode ? '' : 'detach'}); `); } diff --git a/src/compile/nodes/Title.ts b/src/compile/nodes/Title.ts index f2c8eb2a62..080d122535 100644 --- a/src/compile/nodes/Title.ts +++ b/src/compile/nodes/Title.ts @@ -35,7 +35,7 @@ export default class Title extends Node { // TODO some of this code is repeated in Tag.ts — would be good to // DRY it out if that's possible without introducing crazy indirection if (this.children.length === 1) { - // single {{tag}} — may be a non-string + // single {tag} — may be a non-string const { expression } = this.children[0]; const { dependencies, snippet } = this.children[0].expression; @@ -81,7 +81,7 @@ export default class Title extends Node { if (allDependencies.size) { const dependencies = Array.from(allDependencies); const changedCheck = ( - ( block.hasOutroMethod ? `#outroing || ` : '' ) + + ( block.hasOutros ? `!#current || ` : '' ) + dependencies.map(dependency => `changed.${dependency}`).join(' || ') ); diff --git a/src/compile/nodes/Window.ts b/src/compile/nodes/Window.ts index 6651fce854..6a7988738e 100644 --- a/src/compile/nodes/Window.ts +++ b/src/compile/nodes/Window.ts @@ -200,7 +200,9 @@ export default class Window extends Node { const handlerName = block.getUniqueName(`onlinestatuschanged`); block.builders.init.addBlock(deindent` function ${handlerName}(event) { + ${compiler.options.dev && `component._updatingReadonlyProperty = true;`} #component.set({ ${bindings.online}: navigator.onLine }); + ${compiler.options.dev && `component._updatingReadonlyProperty = false;`} } window.addEventListener("online", ${handlerName}); window.addEventListener("offline", ${handlerName}); diff --git a/src/compile/nodes/shared/Tag.ts b/src/compile/nodes/shared/Tag.ts index b3cc7cb0df..df17a1f9c0 100644 --- a/src/compile/nodes/shared/Tag.ts +++ b/src/compile/nodes/shared/Tag.ts @@ -35,7 +35,7 @@ export default class Tag extends Node { if (dependencies.size) { const changedCheck = ( - (block.hasOutroMethod ? `#outroing || ` : '') + + (block.hasOutros ? `!#current || ` : '') + [...dependencies].map((dependency: string) => `changed.${dependency}`).join(' || ') ); diff --git a/src/css/Selector.ts b/src/css/Selector.ts index 71e127edb3..8abb4353cd 100644 --- a/src/css/Selector.ts +++ b/src/css/Selector.ts @@ -30,7 +30,7 @@ export default class Selector { apply(node: Node, stack: Node[]) { const toEncapsulate: Node[] = []; - applySelector(this.localBlocks.slice(), node, stack.slice(), toEncapsulate); + applySelector(this.stylesheet, this.localBlocks.slice(), node, stack.slice(), toEncapsulate); if (toEncapsulate.length > 0) { toEncapsulate.filter((_, i) => i === 0 || i === toEncapsulate.length - 1).forEach(({ node, block }) => { @@ -76,7 +76,7 @@ export default class Selector { const selector = block.selectors[i]; if (selector.type === 'RefSelector') { - code.overwrite(selector.start, selector.end, `[svelte-ref-${selector.name}]`, { + code.overwrite(selector.start, selector.end, `.svelte-ref-${selector.name}`, { contentOnly: true, storeName: false }); @@ -136,7 +136,7 @@ function isDescendantSelector(selector: Node) { return selector.type === 'WhiteSpace' || selector.type === 'Combinator'; } -function applySelector(blocks: Block[], node: Node, stack: Node[], toEncapsulate: any[]): boolean { +function applySelector(stylesheet: Stylesheet, blocks: Block[], node: Node, stack: Node[], toEncapsulate: any[]): boolean { const block = blocks.pop(); if (!block) return false; @@ -179,7 +179,7 @@ function applySelector(blocks: Block[], node: Node, stack: Node[], toEncapsulate else if (selector.type === 'RefSelector') { if (node.ref === selector.name) { - node._cssRefAttribute = selector.name; + stylesheet.nodesWithRefCssClass.set(selector.name, node); toEncapsulate.push({ node, block }); return true; } @@ -196,7 +196,7 @@ function applySelector(blocks: Block[], node: Node, stack: Node[], toEncapsulate if (block.combinator) { if (block.combinator.type === 'WhiteSpace') { while (stack.length) { - if (applySelector(blocks.slice(), stack.pop(), stack, toEncapsulate)) { + if (applySelector(stylesheet, blocks.slice(), stack.pop(), stack, toEncapsulate)) { toEncapsulate.push({ node, block }); return true; } @@ -204,7 +204,7 @@ function applySelector(blocks: Block[], node: Node, stack: Node[], toEncapsulate return false; } else if (block.combinator.name === '>') { - if (applySelector(blocks, stack.pop(), stack, toEncapsulate)) { + if (applySelector(stylesheet, blocks, stack.pop(), stack, toEncapsulate)) { toEncapsulate.push({ node, block }); return true; } diff --git a/src/css/Stylesheet.ts b/src/css/Stylesheet.ts index 586599021b..32052f50d5 100644 --- a/src/css/Stylesheet.ts +++ b/src/css/Stylesheet.ts @@ -4,10 +4,13 @@ import { getLocator } from 'locate-character'; import Selector from './Selector'; import getCodeFrame from '../utils/getCodeFrame'; import hash from '../utils/hash'; +import removeCSSPrefix from '../utils/removeCSSPrefix'; import Element from '../compile/nodes/Element'; import { Validator } from '../validate/index'; import { Node, Ast, Warning } from '../interfaces'; +const isKeyframesNode = (node: Node) => removeCSSPrefix(node.name) === 'keyframes' + class Rule { selectors: Selector[]; declarations: Declaration[]; @@ -26,7 +29,7 @@ class Rule { } isUsed(dev: boolean) { - if (this.parent && this.parent.node.type === 'Atrule' && this.parent.node.name === 'keyframes') return true; + if (this.parent && this.parent.node.type === 'Atrule' && isKeyframesNode(this.parent.node)) return true; if (this.declarations.length === 0) return dev; return this.selectors.some(s => s.used); } @@ -67,7 +70,7 @@ class Rule { } transform(code: MagicString, id: string, keyframes: Map) { - if (this.parent && this.parent.node.type === 'Atrule' && this.parent.node.name === 'keyframes') return true; + if (this.parent && this.parent.node.type === 'Atrule' && isKeyframesNode(this.parent.node)) return true; const attr = `.${id}`; @@ -96,7 +99,7 @@ class Declaration { } transform(code: MagicString, keyframes: Map) { - const property = this.node.property && this.node.property.toLowerCase(); + const property = this.node.property && removeCSSPrefix(this.node.property.toLowerCase()); if (property === 'animation' || property === 'animation-name') { this.node.value.children.forEach((block: Node) => { if (block.type === 'Identifier') { @@ -142,7 +145,7 @@ class Atrule { }); } - else if (this.node.name === 'keyframes') { + else if (isKeyframesNode(this.node)) { this.children.forEach((rule: Rule) => { rule.selectors.forEach(selector => { selector.used = true; @@ -167,8 +170,8 @@ class Atrule { }); code.remove(c, this.node.block.start); - } else if (this.node.name === 'keyframes') { - let c = this.node.start + 10; + } else if (isKeyframesNode(this.node)) { + let c = this.node.start + this.node.name.length + 1; if (this.node.expression.start - c > 1) code.overwrite(c, this.node.expression.start, ' '); c = this.node.expression.end; if (this.node.block.start - c > 0) code.remove(c, this.node.block.start); @@ -200,7 +203,7 @@ class Atrule { } transform(code: MagicString, id: string, keyframes: Map) { - if (this.node.name === 'keyframes') { + if (isKeyframesNode(this.node)) { this.node.expression.children.forEach(({ type, name, start, end }: Node) => { if (type === 'Identifier') { if (name.startsWith('-global-')) { @@ -247,6 +250,7 @@ export default class Stylesheet { keyframes: Map; nodesWithCssClass: Set; + nodesWithRefCssClass: Map; constructor(source: string, ast: Ast, filename: string, dev: boolean) { this.source = source; @@ -258,6 +262,7 @@ export default class Stylesheet { this.keyframes = new Map(); this.nodesWithCssClass = new Set(); + this.nodesWithRefCssClass = new Map(); if (ast.css && ast.css.children.length) { this.id = `svelte-${hash(ast.css.content.styles)}`; @@ -285,7 +290,7 @@ export default class Stylesheet { this.children.push(atrule); } - if (node.name === 'keyframes') { + if (isKeyframesNode(node)) { node.expression.children.forEach((expression: Node) => { if (expression.type === 'Identifier' && !expression.name.startsWith('-global-')) { this.keyframes.set(expression.name, `${this.id}-${expression.name}`); @@ -337,6 +342,9 @@ export default class Stylesheet { this.nodesWithCssClass.forEach((node: Node) => { node.addCssClass(); }); + this.nodesWithRefCssClass.forEach((node: Node, name: String) => { + node.addCssClass(`svelte-ref-${name}`); + }) } render(cssOutputFilename: string, shouldTransformSelectors: boolean) { diff --git a/src/parse/read/directives.ts b/src/parse/read/directives.ts index feb668d25f..62a249a158 100644 --- a/src/parse/read/directives.ts +++ b/src/parse/read/directives.ts @@ -77,7 +77,7 @@ const DIRECTIVES: Record { if (!--i) fn(); }; +} + +export function addLoc(element, file, line, column, char) { + element.__svelte_meta = { + loc: { file, line, column, char } + }; } \ No newline at end of file diff --git a/src/utils/removeCSSPrefix.ts b/src/utils/removeCSSPrefix.ts new file mode 100644 index 0000000000..df1849f119 --- /dev/null +++ b/src/utils/removeCSSPrefix.ts @@ -0,0 +1,3 @@ +export default function(name: string): string { + return name.replace(/^-((webkit)|(moz)|(o)|(ms))-/, ''); +} diff --git a/src/validate/html/validateElement.ts b/src/validate/html/validateElement.ts index 4a700c4bc2..002120e721 100644 --- a/src/validate/html/validateElement.ts +++ b/src/validate/html/validateElement.ts @@ -69,7 +69,7 @@ export default function validateElement( if (child.type !== 'Text' && child.type !== 'MustacheTag') { validator.error(child, { code: 'illegal-structure', - message: ` can only contain text and {{tags}}` + message: `<title> can only contain text and {tags}` }); } }); diff --git a/src/validate/html/validateEventHandler.ts b/src/validate/html/validateEventHandler.ts index 1b33b3e786..df499a9fd5 100644 --- a/src/validate/html/validateEventHandler.ts +++ b/src/validate/html/validateEventHandler.ts @@ -43,7 +43,7 @@ export default function validateEventHandlerCallee( return; } - const validCallees = ['this.*', 'event.*', 'options.*', 'console.*'].concat( + const validCallees = ['this.*', 'refs.*', 'event.*', 'options.*', 'console.*'].concat( Array.from(validBuiltins), Array.from(validator.methods.keys()) ); diff --git a/src/validate/html/validateHead.ts b/src/validate/html/validateHead.ts index 1fcfd050fc..b6dd6d0fc0 100644 --- a/src/validate/html/validateHead.ts +++ b/src/validate/html/validateHead.ts @@ -13,7 +13,7 @@ export default function validateHead(validator: Validator, node: Node, refs: Map // TODO ensure only valid elements are included here node.children.forEach(node => { - if (node.type !== 'Element' && node.type !== 'Title') return; // TODO handle {{#if}} and friends? + if (node.type !== 'Element' && node.type !== 'Title') return; // TODO handle {#if} and friends? validateElement(validator, node, refs, refCallees, [], []); }); } diff --git a/test/cli/index.js b/test/cli/index.js index 816bc3301e..bb17ec50c4 100644 --- a/test/cli/index.js +++ b/test/cli/index.js @@ -1,15 +1,18 @@ const fs = require('fs'); const path = require('path'); -const child_process = require('child_process'); const assert = require('assert'); const glob = require('tiny-glob/sync.js'); +const shell = require("shelljs"); -const bin = path.resolve(`svelte`); +const cli = path.resolve(__dirname, "../../cli/index.ts.js"); function normalize(str) { return str .replace(/^\s+$/gm, '') - .replace(/generated by Svelte v[.\d]+/, `generated by Svelte vx.y.z`) + .replace( + /\/\*(.*?)generated by Svelte v[.\d]+/, + (_, path) => `/*${path.replace(/\\/g, '/')}generated by Svelte vx.y.z` + ) .trim(); } @@ -31,49 +34,48 @@ describe('cli', () => { const command = fs.readFileSync('command.sh', 'utf-8'); - child_process.exec(` - alias svelte=${bin} - mkdir -p actual - rm -rf actual/* - ${command} - `, (err, stdout, stderr) => { - if (err) { - done(err); - return; - } + shell.mkdir("-p", "actual"); + shell.rm("-rf", "actual/*"); + const { commandErr } = shell.exec( + command.replace(/^svelte /, `node ${cli} `) + ); + + if (commandErr) { + done(commandErr); + return; + } + + const actual = glob('**', { cwd: 'actual', filesOnly: true }) + .map(file => { + return { + file, + contents: normalize(fs.readFileSync(`actual/${file}`, 'utf-8')) + }; + }); - const actual = glob('**', { cwd: 'actual', filesOnly: true }) - .map(file => { - return { - file, - contents: normalize(fs.readFileSync(`actual/${file}`, 'utf-8')) - }; - }); - - const expected = glob('**', { cwd: 'expected', filesOnly: true }) - .map(file => { - return { - file, - contents: normalize( - fs.readFileSync(`expected/${file}`, 'utf-8') - ) - }; - }); - - actual.forEach((a, i) => { - const e = expected[i]; - - assert.equal(a.file, e.file, 'File list mismatch'); - - if (/\.map$/.test(a.file)) { - assert.deepEqual(JSON.parse(a.contents), JSON.parse(e.contents)); - } else { - assert.equal(a.contents, e.contents); - } + const expected = glob('**', { cwd: 'expected', filesOnly: true }) + .map(file => { + return { + file, + contents: normalize( + fs.readFileSync(`expected/${file}`, 'utf-8') + ) + }; }); - done(); + actual.forEach((a, i) => { + const e = expected[i]; + + assert.equal(a.file, e.file, 'File list mismatch'); + + if (/\.map$/.test(a.file)) { + assert.deepEqual(JSON.parse(a.contents), JSON.parse(e.contents)); + } else { + assert.equal(a.contents, e.contents); + } }); + + done(); }); }); }); diff --git a/test/cli/samples/basic/expected/Main.js b/test/cli/samples/basic/expected/Main.js index 7407ee4be3..19de3981da 100644 --- a/test/cli/samples/basic/expected/Main.js +++ b/test/cli/samples/basic/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ function create_main_fragment(component, ctx) { var p; @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/custom-element/expected/Main.js b/test/cli/samples/custom-element/expected/Main.js index 4fef083d78..64981ea826 100644 --- a/test/cli/samples/custom-element/expected/Main.js +++ b/test/cli/samples/custom-element/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ function create_main_fragment(component, ctx) { var p; @@ -90,7 +90,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/dev/expected/Main.js b/test/cli/samples/dev/expected/Main.js index 9cfeb5ba58..3808927235 100644 --- a/test/cli/samples/dev/expected/Main.js +++ b/test/cli/samples/dev/expected/Main.js @@ -1,16 +1,20 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ + +const file = "src/Main.html"; function create_main_fragment(component, ctx) { - var p; + var p, text; return { c: function create() { p = createElement("p"); - p.textContent = "Hello world!"; + text = createText("Hello world!"); + addLoc(p, file, 0, 0, 0); }, m: function mount(target, anchor) { insertNode(p, target, anchor); + appendNode(text, p); }, p: noop, @@ -59,10 +63,24 @@ function createElement(name) { return document.createElement(name); } +function createText(data) { + return document.createTextNode(data); +} + +function addLoc(element, file, line, column, char) { + element.__svelte_meta = { + loc: { file, line, column, char } + }; +} + function insertNode(node, target, anchor) { target.insertBefore(node, anchor); } +function appendNode(node, target) { + target.appendChild(node); +} + function noop() {} function detachNode(node) { @@ -75,7 +93,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/dir-sourcemap/expected/Main.js b/test/cli/samples/dir-sourcemap/expected/Main.js index 2169df3ed8..85e8e85480 100644 --- a/test/cli/samples/dir-sourcemap/expected/Main.js +++ b/test/cli/samples/dir-sourcemap/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte v2.7.2 */ import Widget from './Widget.html'; @@ -6,7 +6,8 @@ import Widget from './Widget.html'; function create_main_fragment(component, ctx) { var widget = new Widget({ - root: component.root + root: component.root, + store: component.store }); return { @@ -72,7 +73,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/dir-sourcemap/expected/Main.js.map b/test/cli/samples/dir-sourcemap/expected/Main.js.map index e164b7b845..3177f8b8be 100644 --- a/test/cli/samples/dir-sourcemap/expected/Main.js.map +++ b/test/cli/samples/dir-sourcemap/expected/Main.js.map @@ -1 +1 @@ -{"version":3,"file":"Main.js","sources":["../src/Main.html"],"sourcesContent":["<Widget/>\n\n<script>\n\timport Widget from './Widget.html';\n\n\texport default {\n\t\tcomponents: {\n\t\t\tWidget\n\t\t}\n\t};\n</script>"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"} \ No newline at end of file +{"version":3,"file":"Main.js","sources":["../src/Main.html"],"sourcesContent":["<Widget/>\n\n<script>\n\timport Widget from './Widget.html';\n\n\texport default {\n\t\tcomponents: {\n\t\t\tWidget\n\t\t}\n\t};\n</script>"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"} \ No newline at end of file diff --git a/test/cli/samples/dir-sourcemap/expected/Widget.js b/test/cli/samples/dir-sourcemap/expected/Widget.js index 8c63eca928..47794ea409 100644 --- a/test/cli/samples/dir-sourcemap/expected/Widget.js +++ b/test/cli/samples/dir-sourcemap/expected/Widget.js @@ -1,4 +1,4 @@ -/* src/Widget.html generated by Svelte v2.5.1 */ +/* src/Widget.html generated by Svelte v2.7.2 */ function create_main_fragment(component, ctx) { var p; @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/dir-subdir/expected/Main.js b/test/cli/samples/dir-subdir/expected/Main.js index 7a5e0e65f4..a80bf2f976 100644 --- a/test/cli/samples/dir-subdir/expected/Main.js +++ b/test/cli/samples/dir-subdir/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ import Widget from './widget/Widget.html'; @@ -6,7 +6,8 @@ import Widget from './widget/Widget.html'; function create_main_fragment(component, ctx) { var widget = new Widget({ - root: component.root + root: component.root, + store: component.store }); return { @@ -72,7 +73,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/dir-subdir/expected/widget/Widget.js b/test/cli/samples/dir-subdir/expected/widget/Widget.js index e4bf9ce919..974326ad95 100644 --- a/test/cli/samples/dir-subdir/expected/widget/Widget.js +++ b/test/cli/samples/dir-subdir/expected/widget/Widget.js @@ -1,4 +1,4 @@ -/* src/widget/Widget.html generated by Svelte v2.5.1 */ +/* src/widget/Widget.html generated by Svelte vx.y.z */ function create_main_fragment(component, ctx) { var p; @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/dir/expected/Main.js b/test/cli/samples/dir/expected/Main.js index 0ab0b9a372..edfbe3c67f 100644 --- a/test/cli/samples/dir/expected/Main.js +++ b/test/cli/samples/dir/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ import Widget from './Widget.html'; @@ -6,7 +6,8 @@ import Widget from './Widget.html'; function create_main_fragment(component, ctx) { var widget = new Widget({ - root: component.root + root: component.root, + store: component.store }); return { @@ -72,7 +73,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/dir/expected/Widget.js b/test/cli/samples/dir/expected/Widget.js index e9ca0c6056..7bec9ae438 100644 --- a/test/cli/samples/dir/expected/Widget.js +++ b/test/cli/samples/dir/expected/Widget.js @@ -1,4 +1,4 @@ -/* src/Widget.html generated by Svelte v2.5.1 */ +/* src/Widget.html generated by Svelte vx.y.z */ function create_main_fragment(component, ctx) { var p; @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/globals/expected/Main.js b/test/cli/samples/globals/expected/Main.js index e317e7e689..1a79813b58 100644 --- a/test/cli/samples/globals/expected/Main.js +++ b/test/cli/samples/globals/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ var Main = (function(answer) { "use strict"; answer = (answer && answer.__esModule) ? answer["default"] : answer; @@ -90,7 +90,7 @@ var Main = (function(answer) { "use strict"; component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/sourcemap-inline/expected/Main.js b/test/cli/samples/sourcemap-inline/expected/Main.js index b52eed5b1e..de6a8894ce 100644 --- a/test/cli/samples/sourcemap-inline/expected/Main.js +++ b/test/cli/samples/sourcemap-inline/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ function create_main_fragment(component, ctx) { var p; @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/sourcemap/expected/Main.js b/test/cli/samples/sourcemap/expected/Main.js index 9e025d21f9..e136e16f48 100644 --- a/test/cli/samples/sourcemap/expected/Main.js +++ b/test/cli/samples/sourcemap/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ function create_main_fragment(component, ctx) { var p; @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/samples/store/expected/Main.js b/test/cli/samples/store/expected/Main.js index 00d4ead864..3f97badad4 100644 --- a/test/cli/samples/store/expected/Main.js +++ b/test/cli/samples/store/expected/Main.js @@ -1,4 +1,4 @@ -/* src/Main.html generated by Svelte v2.5.1 */ +/* src/Main.html generated by Svelte vx.y.z */ function create_main_fragment(component, ctx) { var h1, text, text_1; @@ -85,7 +85,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function assign(tar, src) { diff --git a/test/cli/update.js b/test/cli/update.js index bc87c18bff..468fe51f15 100644 --- a/test/cli/update.js +++ b/test/cli/update.js @@ -1,4 +1,5 @@ const sander = require('sander'); +const glob = require('tiny-glob/sync'); process.chdir(__dirname); @@ -6,5 +7,14 @@ sander.readdirSync('samples').forEach(dir => { if (dir[0] === '.') return; sander.rimrafSync(`samples/${dir}/expected`); - sander.copydirSync(`samples/${dir}/actual`).to(`samples/${dir}/expected`); + + const files = glob(`**`, { cwd: `samples/${dir}/actual`, filesOnly: true }); + files.forEach(file => { + const source = sander.readFileSync(`samples/${dir}/actual/${file}`, { encoding: 'utf-8' }); + + sander.writeFileSync( + `samples/${dir}/expected/${file}`, + source.replace(/generated by Svelte v(\d+\.\d+\.\d+)/, 'generated by Svelte vx.y.z') + ); + }); }); \ No newline at end of file diff --git a/test/css/samples/keyframes-autoprefixed/expected.css b/test/css/samples/keyframes-autoprefixed/expected.css new file mode 100644 index 0000000000..d9866778a9 --- /dev/null +++ b/test/css/samples/keyframes-autoprefixed/expected.css @@ -0,0 +1 @@ +@keyframes svelte-xyz-why{0%{color:red}100%{color:blue}}@-webkit-keyframes svelte-xyz-why{0%{color:red}100%{color:blue}}@-moz-keyframes svelte-xyz-why{0%{color:red}100%{color:blue}}@-o-keyframes svelte-xyz-why{0%{color:red}100%{color:blue}}.animated.svelte-xyz{-webkit-animation:svelte-xyz-why 2s;animation:svelte-xyz-why 2s}.also-animated.svelte-xyz{-webkit-animation:not-defined-here 2s;animation:not-defined-here 2s} \ No newline at end of file diff --git a/test/css/samples/keyframes-autoprefixed/input.html b/test/css/samples/keyframes-autoprefixed/input.html new file mode 100644 index 0000000000..1c0e1bc630 --- /dev/null +++ b/test/css/samples/keyframes-autoprefixed/input.html @@ -0,0 +1,34 @@ +<div class='animated'>animated</div> +<div class='also-animated'>also animated</div> + +<style> + @keyframes why { + 0% { color: red; } + 100% { color: blue; } + } + + @-webkit-keyframes why { + 0% { color: red; } + 100% { color: blue; } + } + + @-moz-keyframes why { + 0% { color: red; } + 100% { color: blue; } + } + + @-o-keyframes why { + 0% { color: red; } + 100% { color: blue; } + } + + .animated { + -webkit-animation: why 2s; + animation: why 2s; + } + + .also-animated { + -webkit-animation: not-defined-here 2s; + animation: not-defined-here 2s; + } +</style> diff --git a/test/css/samples/refs-qualified/expected.css b/test/css/samples/refs-qualified/expected.css index 90e58e2a80..9872b67fed 100644 --- a/test/css/samples/refs-qualified/expected.css +++ b/test/css/samples/refs-qualified/expected.css @@ -1 +1 @@ -[svelte-ref-button].active.svelte-xyz{color:red} \ No newline at end of file +.svelte-ref-button.active.svelte-xyz{color:red} \ No newline at end of file diff --git a/test/css/samples/refs-qualified/expected.html b/test/css/samples/refs-qualified/expected.html index 536bae83f8..06ddcc43ef 100644 --- a/test/css/samples/refs-qualified/expected.html +++ b/test/css/samples/refs-qualified/expected.html @@ -1 +1 @@ -<button svelte-ref-button="" class="active svelte-xyz">deactivate</button> \ No newline at end of file +<button class="active svelte-xyz svelte-ref-button">deactivate</button> \ No newline at end of file diff --git a/test/css/samples/refs/expected.css b/test/css/samples/refs/expected.css index c0018c9593..2ab337cd2c 100644 --- a/test/css/samples/refs/expected.css +++ b/test/css/samples/refs/expected.css @@ -1 +1 @@ -[svelte-ref-a].svelte-xyz{color:red}[svelte-ref-b].svelte-xyz{color:green} \ No newline at end of file +.svelte-ref-a.svelte-xyz{color:red}.svelte-ref-b.svelte-xyz{color:green} \ No newline at end of file diff --git a/test/css/samples/refs/expected.html b/test/css/samples/refs/expected.html index 2b504628c3..bc892a94e1 100644 --- a/test/css/samples/refs/expected.html +++ b/test/css/samples/refs/expected.html @@ -1,3 +1,3 @@ -<div class="svelte-xyz" svelte-ref-a=''></div> -<div class="svelte-xyz" svelte-ref-b=''></div> +<div class="svelte-xyz svelte-ref-a"></div> +<div class="svelte-xyz svelte-ref-b"></div> <div></div> \ No newline at end of file diff --git a/test/js/samples/action/expected-bundle.js b/test/js/samples/action/expected-bundle.js index fe61c32b09..e1b3e6ce18 100644 --- a/test/js/samples/action/expected-bundle.js +++ b/test/js/samples/action/expected-bundle.js @@ -61,7 +61,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/bind-width-height/expected-bundle.js b/test/js/samples/bind-width-height/expected-bundle.js index e66cc47aaf..8a441a8d3f 100644 --- a/test/js/samples/bind-width-height/expected-bundle.js +++ b/test/js/samples/bind-width-height/expected-bundle.js @@ -93,7 +93,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/collapses-text-around-comments/expected-bundle.js b/test/js/samples/collapses-text-around-comments/expected-bundle.js index 49c9c75813..87f65ba860 100644 --- a/test/js/samples/collapses-text-around-comments/expected-bundle.js +++ b/test/js/samples/collapses-text-around-comments/expected-bundle.js @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/component-static-array/expected-bundle.js b/test/js/samples/component-static-array/expected-bundle.js index 1fd894e093..5f85c7487a 100644 --- a/test/js/samples/component-static-array/expected-bundle.js +++ b/test/js/samples/component-static-array/expected-bundle.js @@ -49,7 +49,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { @@ -124,6 +124,7 @@ function create_main_fragment(component, ctx) { var nested_initial_data = { foo: [1, 2, 3] }; var nested = new Nested({ root: component.root, + store: component.store, data: nested_initial_data }); diff --git a/test/js/samples/component-static-array/expected.js b/test/js/samples/component-static-array/expected.js index c1dcfea4a7..bae0c850f7 100644 --- a/test/js/samples/component-static-array/expected.js +++ b/test/js/samples/component-static-array/expected.js @@ -8,6 +8,7 @@ function create_main_fragment(component, ctx) { var nested_initial_data = { foo: [1, 2, 3] }; var nested = new Nested({ root: component.root, + store: component.store, data: nested_initial_data }); diff --git a/test/js/samples/component-static-immutable/expected-bundle.js b/test/js/samples/component-static-immutable/expected-bundle.js index dc6d94a1f2..3ebd360b2a 100644 --- a/test/js/samples/component-static-immutable/expected-bundle.js +++ b/test/js/samples/component-static-immutable/expected-bundle.js @@ -53,7 +53,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { @@ -128,6 +128,7 @@ function create_main_fragment(component, ctx) { var nested_initial_data = { foo: "bar" }; var nested = new Nested({ root: component.root, + store: component.store, data: nested_initial_data }); diff --git a/test/js/samples/component-static-immutable/expected.js b/test/js/samples/component-static-immutable/expected.js index 41fe5a349b..f40f060325 100644 --- a/test/js/samples/component-static-immutable/expected.js +++ b/test/js/samples/component-static-immutable/expected.js @@ -8,6 +8,7 @@ function create_main_fragment(component, ctx) { var nested_initial_data = { foo: "bar" }; var nested = new Nested({ root: component.root, + store: component.store, data: nested_initial_data }); diff --git a/test/js/samples/component-static-immutable2/expected-bundle.js b/test/js/samples/component-static-immutable2/expected-bundle.js index dc6d94a1f2..3ebd360b2a 100644 --- a/test/js/samples/component-static-immutable2/expected-bundle.js +++ b/test/js/samples/component-static-immutable2/expected-bundle.js @@ -53,7 +53,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { @@ -128,6 +128,7 @@ function create_main_fragment(component, ctx) { var nested_initial_data = { foo: "bar" }; var nested = new Nested({ root: component.root, + store: component.store, data: nested_initial_data }); diff --git a/test/js/samples/component-static-immutable2/expected.js b/test/js/samples/component-static-immutable2/expected.js index 41fe5a349b..f40f060325 100644 --- a/test/js/samples/component-static-immutable2/expected.js +++ b/test/js/samples/component-static-immutable2/expected.js @@ -8,6 +8,7 @@ function create_main_fragment(component, ctx) { var nested_initial_data = { foo: "bar" }; var nested = new Nested({ root: component.root, + store: component.store, data: nested_initial_data }); diff --git a/test/js/samples/component-static/expected-bundle.js b/test/js/samples/component-static/expected-bundle.js index 21c70ae9a7..d2c8280062 100644 --- a/test/js/samples/component-static/expected-bundle.js +++ b/test/js/samples/component-static/expected-bundle.js @@ -49,7 +49,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { @@ -124,6 +124,7 @@ function create_main_fragment(component, ctx) { var nested_initial_data = { foo: "bar" }; var nested = new Nested({ root: component.root, + store: component.store, data: nested_initial_data }); diff --git a/test/js/samples/component-static/expected.js b/test/js/samples/component-static/expected.js index 2318521cf4..1a5631fc58 100644 --- a/test/js/samples/component-static/expected.js +++ b/test/js/samples/component-static/expected.js @@ -8,6 +8,7 @@ function create_main_fragment(component, ctx) { var nested_initial_data = { foo: "bar" }; var nested = new Nested({ root: component.root, + store: component.store, data: nested_initial_data }); diff --git a/test/js/samples/computed-collapsed-if/expected-bundle.js b/test/js/samples/computed-collapsed-if/expected-bundle.js index 0e967c7a67..73830ee233 100644 --- a/test/js/samples/computed-collapsed-if/expected-bundle.js +++ b/test/js/samples/computed-collapsed-if/expected-bundle.js @@ -49,7 +49,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/css-media-query/expected-bundle.js b/test/js/samples/css-media-query/expected-bundle.js index b481784118..ff7bdcfcc1 100644 --- a/test/js/samples/css-media-query/expected-bundle.js +++ b/test/js/samples/css-media-query/expected-bundle.js @@ -65,7 +65,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/css-shadow-dom-keyframes/expected-bundle.js b/test/js/samples/css-shadow-dom-keyframes/expected-bundle.js index c34d69215b..8d9d31dff2 100644 --- a/test/js/samples/css-shadow-dom-keyframes/expected-bundle.js +++ b/test/js/samples/css-shadow-dom-keyframes/expected-bundle.js @@ -61,7 +61,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/deconflict-builtins/expected-bundle.js b/test/js/samples/deconflict-builtins/expected-bundle.js index 976c71face..c3d9d762b9 100644 --- a/test/js/samples/deconflict-builtins/expected-bundle.js +++ b/test/js/samples/deconflict-builtins/expected-bundle.js @@ -79,7 +79,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/deconflict-globals/expected-bundle.js b/test/js/samples/deconflict-globals/expected-bundle.js index 524d379e88..0d2226d5cb 100644 --- a/test/js/samples/deconflict-globals/expected-bundle.js +++ b/test/js/samples/deconflict-globals/expected-bundle.js @@ -54,7 +54,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/dev-warning-missing-data-computed/expected-bundle.js b/test/js/samples/dev-warning-missing-data-computed/expected-bundle.js index cc3446f88b..3b9a92c90e 100644 --- a/test/js/samples/dev-warning-missing-data-computed/expected-bundle.js +++ b/test/js/samples/dev-warning-missing-data-computed/expected-bundle.js @@ -5,6 +5,12 @@ function assign(tar, src) { return tar; } +function addLoc(element, file, line, column, char) { + element.__svelte_meta = { + loc: { file, line, column, char } + }; +} + function appendNode(node, target) { target.appendChild(node); } @@ -76,7 +82,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { @@ -159,6 +165,8 @@ function bar({ foo }) { return foo * 2; } +const file = undefined; + function create_main_fragment(component, ctx) { var p, text_value = ctx.Math.max(0, ctx.foo), text, text_1, text_2; @@ -168,6 +176,7 @@ function create_main_fragment(component, ctx) { text = createText(text_value); text_1 = createText("\n\t"); text_2 = createText(ctx.bar); + addLoc(p, file, 0, 0, 0); }, m: function mount(target, anchor) { diff --git a/test/js/samples/dev-warning-missing-data-computed/expected.js b/test/js/samples/dev-warning-missing-data-computed/expected.js index b9d70d63ac..834da725e7 100644 --- a/test/js/samples/dev-warning-missing-data-computed/expected.js +++ b/test/js/samples/dev-warning-missing-data-computed/expected.js @@ -1,10 +1,12 @@ /* generated by Svelte vX.Y.Z */ -import { appendNode, assign, createElement, createText, detachNode, init, insertNode, protoDev } from "svelte/shared.js"; +import { addLoc, appendNode, assign, createElement, createText, detachNode, init, insertNode, protoDev } from "svelte/shared.js"; function bar({ foo }) { return foo * 2; } +const file = undefined; + function create_main_fragment(component, ctx) { var p, text_value = ctx.Math.max(0, ctx.foo), text, text_1, text_2; @@ -14,6 +16,7 @@ function create_main_fragment(component, ctx) { text = createText(text_value); text_1 = createText("\n\t"); text_2 = createText(ctx.bar); + addLoc(p, file, 0, 0, 0); }, m: function mount(target, anchor) { diff --git a/test/js/samples/do-use-dataset/expected-bundle.js b/test/js/samples/do-use-dataset/expected-bundle.js index 7eac008dbe..10c7600975 100644 --- a/test/js/samples/do-use-dataset/expected-bundle.js +++ b/test/js/samples/do-use-dataset/expected-bundle.js @@ -65,7 +65,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/dont-use-dataset-in-legacy/expected-bundle.js b/test/js/samples/dont-use-dataset-in-legacy/expected-bundle.js index 93fbd587cf..4a963e3300 100644 --- a/test/js/samples/dont-use-dataset-in-legacy/expected-bundle.js +++ b/test/js/samples/dont-use-dataset-in-legacy/expected-bundle.js @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/dont-use-dataset-in-svg/expected-bundle.js b/test/js/samples/dont-use-dataset-in-svg/expected-bundle.js index 349eff3f4d..5b1827344d 100644 --- a/test/js/samples/dont-use-dataset-in-svg/expected-bundle.js +++ b/test/js/samples/dont-use-dataset-in-svg/expected-bundle.js @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/each-block-changed-check/expected-bundle.js b/test/js/samples/each-block-changed-check/expected-bundle.js index b06f8662f9..02db1ce829 100644 --- a/test/js/samples/each-block-changed-check/expected-bundle.js +++ b/test/js/samples/each-block-changed-check/expected-bundle.js @@ -81,7 +81,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/each-block-keyed-animated/expected-bundle.js b/test/js/samples/each-block-keyed-animated/expected-bundle.js index 54876c6152..9989c77978 100644 --- a/test/js/samples/each-block-keyed-animated/expected-bundle.js +++ b/test/js/samples/each-block-keyed-animated/expected-bundle.js @@ -391,7 +391,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/each-block-keyed/expected-bundle.js b/test/js/samples/each-block-keyed/expected-bundle.js index 89f1655008..09f61a6d3e 100644 --- a/test/js/samples/each-block-keyed/expected-bundle.js +++ b/test/js/samples/each-block-keyed/expected-bundle.js @@ -164,7 +164,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/event-handlers-custom/expected-bundle.js b/test/js/samples/event-handlers-custom/expected-bundle.js index 5e04f88939..78d5d1a005 100644 --- a/test/js/samples/event-handlers-custom/expected-bundle.js +++ b/test/js/samples/event-handlers-custom/expected-bundle.js @@ -61,7 +61,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/head-no-whitespace/expected-bundle.js b/test/js/samples/head-no-whitespace/expected-bundle.js index f7bbdcc431..d878a85cbf 100644 --- a/test/js/samples/head-no-whitespace/expected-bundle.js +++ b/test/js/samples/head-no-whitespace/expected-bundle.js @@ -61,7 +61,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/if-block-no-update/expected-bundle.js b/test/js/samples/if-block-no-update/expected-bundle.js index 358177436b..f07810c565 100644 --- a/test/js/samples/if-block-no-update/expected-bundle.js +++ b/test/js/samples/if-block-no-update/expected-bundle.js @@ -65,7 +65,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/if-block-simple/expected-bundle.js b/test/js/samples/if-block-simple/expected-bundle.js index 6028d9dfc1..88729b1159 100644 --- a/test/js/samples/if-block-simple/expected-bundle.js +++ b/test/js/samples/if-block-simple/expected-bundle.js @@ -65,7 +65,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/inline-style-optimized-multiple/expected-bundle.js b/test/js/samples/inline-style-optimized-multiple/expected-bundle.js index be92ba9730..37dd300b5d 100644 --- a/test/js/samples/inline-style-optimized-multiple/expected-bundle.js +++ b/test/js/samples/inline-style-optimized-multiple/expected-bundle.js @@ -65,7 +65,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/inline-style-optimized-url/expected-bundle.js b/test/js/samples/inline-style-optimized-url/expected-bundle.js index 439a9b8740..716dac771d 100644 --- a/test/js/samples/inline-style-optimized-url/expected-bundle.js +++ b/test/js/samples/inline-style-optimized-url/expected-bundle.js @@ -65,7 +65,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/inline-style-optimized/expected-bundle.js b/test/js/samples/inline-style-optimized/expected-bundle.js index a5a474d08f..817462d0bd 100644 --- a/test/js/samples/inline-style-optimized/expected-bundle.js +++ b/test/js/samples/inline-style-optimized/expected-bundle.js @@ -65,7 +65,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/inline-style-unoptimized/expected-bundle.js b/test/js/samples/inline-style-unoptimized/expected-bundle.js index f9611d370a..a378c2f4a6 100644 --- a/test/js/samples/inline-style-unoptimized/expected-bundle.js +++ b/test/js/samples/inline-style-unoptimized/expected-bundle.js @@ -65,7 +65,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/input-range/expected-bundle.js b/test/js/samples/input-range/expected-bundle.js index 61560074dc..108fc37a01 100644 --- a/test/js/samples/input-range/expected-bundle.js +++ b/test/js/samples/input-range/expected-bundle.js @@ -77,7 +77,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/input-without-blowback-guard/expected-bundle.js b/test/js/samples/input-without-blowback-guard/expected-bundle.js index 9a0998ed9a..e3fb0c60a4 100644 --- a/test/js/samples/input-without-blowback-guard/expected-bundle.js +++ b/test/js/samples/input-without-blowback-guard/expected-bundle.js @@ -73,7 +73,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/legacy-input-type/expected-bundle.js b/test/js/samples/legacy-input-type/expected-bundle.js index 41701a0b41..e1d6f84a8f 100644 --- a/test/js/samples/legacy-input-type/expected-bundle.js +++ b/test/js/samples/legacy-input-type/expected-bundle.js @@ -67,7 +67,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/media-bindings/expected-bundle.js b/test/js/samples/media-bindings/expected-bundle.js index 151a26f603..fd83ed3c68 100644 --- a/test/js/samples/media-bindings/expected-bundle.js +++ b/test/js/samples/media-bindings/expected-bundle.js @@ -77,7 +77,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/non-imported-component/expected-bundle.js b/test/js/samples/non-imported-component/expected-bundle.js index 0cfeadbd9d..345d98d16e 100644 --- a/test/js/samples/non-imported-component/expected-bundle.js +++ b/test/js/samples/non-imported-component/expected-bundle.js @@ -63,7 +63,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { @@ -137,11 +137,13 @@ function create_main_fragment(component, ctx) { var text; var imported = new Imported({ - root: component.root + root: component.root, + store: component.store }); var nonimported = new NonImported({ - root: component.root + root: component.root, + store: component.store }); return { diff --git a/test/js/samples/non-imported-component/expected.js b/test/js/samples/non-imported-component/expected.js index e384445105..b3e01289c3 100644 --- a/test/js/samples/non-imported-component/expected.js +++ b/test/js/samples/non-imported-component/expected.js @@ -8,11 +8,13 @@ function create_main_fragment(component, ctx) { var text; var imported = new Imported({ - root: component.root + root: component.root, + store: component.store }); var nonimported = new NonImported({ - root: component.root + root: component.root, + store: component.store }); return { diff --git a/test/js/samples/setup-method/expected-bundle.js b/test/js/samples/setup-method/expected-bundle.js index da8d02f4d6..df0ea63860 100644 --- a/test/js/samples/setup-method/expected-bundle.js +++ b/test/js/samples/setup-method/expected-bundle.js @@ -49,7 +49,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/svg-title/expected-bundle.js b/test/js/samples/svg-title/expected-bundle.js index 948fb03a4d..4073da0148 100644 --- a/test/js/samples/svg-title/expected-bundle.js +++ b/test/js/samples/svg-title/expected-bundle.js @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/title/expected-bundle.js b/test/js/samples/title/expected-bundle.js index 1060deab4c..109ec3276b 100644 --- a/test/js/samples/title/expected-bundle.js +++ b/test/js/samples/title/expected-bundle.js @@ -49,7 +49,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/use-elements-as-anchors/expected-bundle.js b/test/js/samples/use-elements-as-anchors/expected-bundle.js index 979a7ff3e7..2771ac3719 100644 --- a/test/js/samples/use-elements-as-anchors/expected-bundle.js +++ b/test/js/samples/use-elements-as-anchors/expected-bundle.js @@ -73,7 +73,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/js/samples/window-binding-scroll/expected-bundle.js b/test/js/samples/window-binding-scroll/expected-bundle.js index 7fdc38fc63..2d718e483f 100644 --- a/test/js/samples/window-binding-scroll/expected-bundle.js +++ b/test/js/samples/window-binding-scroll/expected-bundle.js @@ -69,7 +69,7 @@ function init(component, options) { component.options = options; component.root = options.root || component; - component.store = component.root.store || options.store; + component.store = options.store || component.root.store; } function on(eventName, handler) { diff --git a/test/runtime/samples/dynamic-component-bindings-recreated-b/Green.html b/test/runtime/samples/dynamic-component-bindings-recreated-b/Green.html new file mode 100644 index 0000000000..cb1506bfdb --- /dev/null +++ b/test/runtime/samples/dynamic-component-bindings-recreated-b/Green.html @@ -0,0 +1,11 @@ +<p>green {foo}</p> + +<script> + export default { + data() { + return { + foo: 'green' + }; + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/dynamic-component-bindings-recreated-b/Red.html b/test/runtime/samples/dynamic-component-bindings-recreated-b/Red.html new file mode 100644 index 0000000000..e86ea16182 --- /dev/null +++ b/test/runtime/samples/dynamic-component-bindings-recreated-b/Red.html @@ -0,0 +1,11 @@ +<p>red {foo}</p> + +<script> + export default { + data() { + return { + foo: 'red' + }; + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/dynamic-component-bindings-recreated-b/_config.js b/test/runtime/samples/dynamic-component-bindings-recreated-b/_config.js new file mode 100644 index 0000000000..050dff684f --- /dev/null +++ b/test/runtime/samples/dynamic-component-bindings-recreated-b/_config.js @@ -0,0 +1,36 @@ +export default { + data: { + x: true + }, + + html: ` + <p>parent green</p> + <p>green green</p> + `, + + test(assert, component, target) { + // TODO replace this with component.set({ foo: undefined }) post-#1488 + // component.set({ foo: undefined }); + // delete component._state.foo; + + component.set({ + x: false, + foo: undefined + }); + + assert.htmlEqual(target.innerHTML, ` + <p>parent red</p> + <p>red red</p> + `); + + component.set({ + x: true, + foo: undefined + }); + + assert.htmlEqual(target.innerHTML, ` + <p>parent green</p> + <p>green green</p> + `); + } +}; \ No newline at end of file diff --git a/test/runtime/samples/dynamic-component-bindings-recreated-b/main.html b/test/runtime/samples/dynamic-component-bindings-recreated-b/main.html new file mode 100644 index 0000000000..41a54e8ee9 --- /dev/null +++ b/test/runtime/samples/dynamic-component-bindings-recreated-b/main.html @@ -0,0 +1,16 @@ +<p>parent {foo}</p> +<svelte:component this="{x ? Green : Red}" bind:foo /> + +<script> + import Green from './Green.html'; + import Red from './Red.html'; + + export default { + data() { + return { + Green, + Red + }; + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/each-block-empty-outro/Thing.html b/test/runtime/samples/each-block-empty-outro/Thing.html new file mode 100644 index 0000000000..150c8fd252 --- /dev/null +++ b/test/runtime/samples/each-block-empty-outro/Thing.html @@ -0,0 +1 @@ +<p>{thing}</p> \ No newline at end of file diff --git a/test/runtime/samples/each-block-empty-outro/_config.js b/test/runtime/samples/each-block-empty-outro/_config.js new file mode 100644 index 0000000000..443371892b --- /dev/null +++ b/test/runtime/samples/each-block-empty-outro/_config.js @@ -0,0 +1,20 @@ +export default { + data: { + visible: true, + empty: [] + }, + + html: ` + <div> + <p>text</p> + </div> + `, + + nestedTransitions: true, + + test(assert, component, target) { + component.set({ visible: false }); + + assert.htmlEqual(target.innerHTML, ``); + } +}; \ No newline at end of file diff --git a/test/runtime/samples/each-block-empty-outro/main.html b/test/runtime/samples/each-block-empty-outro/main.html new file mode 100644 index 0000000000..b5d1b95260 --- /dev/null +++ b/test/runtime/samples/each-block-empty-outro/main.html @@ -0,0 +1,17 @@ +{#if visible} + <div> + {#each empty as thing} + <Thing {thing}/> + {/each} + + <p>text</p> + </div> +{/if} + +<script> + export default { + components: { + Thing: './Thing.html' + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/element-source-location/Foo.html b/test/runtime/samples/element-source-location/Foo.html new file mode 100644 index 0000000000..0bf81d7347 --- /dev/null +++ b/test/runtime/samples/element-source-location/Foo.html @@ -0,0 +1,3 @@ +<div> + <p>this is a paragraph</p> +</div> \ No newline at end of file diff --git a/test/runtime/samples/element-source-location/_config.js b/test/runtime/samples/element-source-location/_config.js new file mode 100644 index 0000000000..47ae986cbb --- /dev/null +++ b/test/runtime/samples/element-source-location/_config.js @@ -0,0 +1,24 @@ +import path from 'path'; + +export default { + dev: true, + + test(assert, component, target) { + const h1 = target.querySelector('h1'); + const p = target.querySelector('p'); + + assert.deepEqual(h1.__svelte_meta.loc, { + file: path.relative(process.cwd(), path.resolve(__dirname, 'main.html')), + line: 0, + column: 0, + char: 0 + }); + + assert.deepEqual(p.__svelte_meta.loc, { + file: path.relative(process.cwd(), path.resolve(__dirname, 'Foo.html')), + line: 1, + column: 1, + char: 7 + }); + } +}; \ No newline at end of file diff --git a/test/runtime/samples/element-source-location/main.html b/test/runtime/samples/element-source-location/main.html new file mode 100644 index 0000000000..2231e19439 --- /dev/null +++ b/test/runtime/samples/element-source-location/main.html @@ -0,0 +1,10 @@ +<h1>this is a header</h1> +<Foo/> + +<script> + export default { + components: { + Foo: './Foo.html' + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/if-block-else-partial-outro/Foo.html b/test/runtime/samples/if-block-else-partial-outro/Foo.html new file mode 100644 index 0000000000..1910281566 --- /dev/null +++ b/test/runtime/samples/if-block-else-partial-outro/Foo.html @@ -0,0 +1 @@ +foo \ No newline at end of file diff --git a/test/runtime/samples/if-block-else-partial-outro/_config.js b/test/runtime/samples/if-block-else-partial-outro/_config.js new file mode 100644 index 0000000000..228e9a45ef --- /dev/null +++ b/test/runtime/samples/if-block-else-partial-outro/_config.js @@ -0,0 +1,19 @@ +export default { + data: { + x: 1, + y: false, + }, + + html: ` + <span>1</span> + `, + + nestedTransitions: true, + + test(assert, component, target) { + component.set({ x: 2 }); + assert.htmlEqual(target.innerHTML, ` + <span>2</span> + `); + }, +}; diff --git a/test/runtime/samples/if-block-else-partial-outro/main.html b/test/runtime/samples/if-block-else-partial-outro/main.html new file mode 100644 index 0000000000..9cb4408b73 --- /dev/null +++ b/test/runtime/samples/if-block-else-partial-outro/main.html @@ -0,0 +1,20 @@ +{#if y} + <Foo/> +{:else} + <span>{x}</span> +{/if} + +<script> + export default { + components: { + Foo: './Foo.html' + }, + + data() { + return { + x: 'x', + y: false + }; + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/nested-transition-detach-each/_config.js b/test/runtime/samples/nested-transition-detach-each/_config.js new file mode 100644 index 0000000000..523be65e97 --- /dev/null +++ b/test/runtime/samples/nested-transition-detach-each/_config.js @@ -0,0 +1,41 @@ +export default { + data: { + visible: false, + rows: [1, 2, 3], + cols: ['a', 'b', 'c'] + }, + + html: ``, + + compileOptions: { + dev: true + }, + nestedTransitions: true, + skipIntroByDefault: true, + + test(assert, component, target, window, raf) { + component.set({ visible: true }); + assert.htmlEqual(target.innerHTML, ` + <div class="row"> + <div class="cell">1, a</div> + <div class="cell">1, b</div> + <div class="cell">1, c</div> + </div> + <div class="row"> + <div class="cell">2, a</div> + <div class="cell">2, b</div> + <div class="cell">2, c</div> + </div> + <div class="row"> + <div class="cell">3, a</div> + <div class="cell">3, b</div> + <div class="cell">3, c</div> + </div> + `); + + component.set({ visible: false }); + raf.tick(0); + raf.tick(100); + assert.htmlEqual(target.innerHTML, ``); + }, +}; diff --git a/test/runtime/samples/nested-transition-detach-each/main.html b/test/runtime/samples/nested-transition-detach-each/main.html new file mode 100644 index 0000000000..c81fc3eb78 --- /dev/null +++ b/test/runtime/samples/nested-transition-detach-each/main.html @@ -0,0 +1,22 @@ +{#if visible} + {#each rows as row} + <div out:foo class="row"> + {#each cols as col} + <div out:foo class="cell">{row}, {col}</div> + {/each} + </div> + {/each} +{/if} + +<script> + export default { + transitions: { + foo(node) { + return { + duration: 100, + tick: t => node.foo = t + }; + } + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/nested-transition-detach-if-false/Folder.html b/test/runtime/samples/nested-transition-detach-if-false/Folder.html new file mode 100644 index 0000000000..cd3448a3f2 --- /dev/null +++ b/test/runtime/samples/nested-transition-detach-if-false/Folder.html @@ -0,0 +1,44 @@ +<li> + <span>{dir}</span> + + {#if open} + <ul> + {#each items as item (item.filename)} + {#if item.isDir} + <svelte:self dir={item.filename}/> + {:else} + <li>{item.filename}</li> + {/if} + {/each} + </ul> + {/if} +</li> + +<script> + export default { + data() { + return { + items: [], + open: true + }; + }, + + computed: { + items: ({ dir }) => { + return dir === 'a' + ? [ + { + filename: 'a/b', + isDir: true + } + ] + : [ + { + filename: 'a/b/c', + isDir: false + } + ]; + } + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/nested-transition-detach-if-false/_config.js b/test/runtime/samples/nested-transition-detach-if-false/_config.js new file mode 100644 index 0000000000..1e26a54787 --- /dev/null +++ b/test/runtime/samples/nested-transition-detach-if-false/_config.js @@ -0,0 +1,26 @@ +export default { + html: ` + <li> + <span>a</span> + <ul> + <li> + <span>a/b</span> + <ul> + <li>a/b/c</li> + </ul> + </li> + </ul> + </li> + `, + + nestedTransitions: true, + + test(assert, component, target, window, raf) { + component.refs.folder.set({ open: false }); + assert.htmlEqual(target.innerHTML, ` + <li> + <span>a</span> + </li> + `); + }, +}; diff --git a/test/runtime/samples/nested-transition-detach-if-false/main.html b/test/runtime/samples/nested-transition-detach-if-false/main.html new file mode 100644 index 0000000000..cf14773c9c --- /dev/null +++ b/test/runtime/samples/nested-transition-detach-if-false/main.html @@ -0,0 +1,9 @@ +<Folder ref:folder dir="a"/> + +<script> + export default { + components: { + Folder: './Folder.html' + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/nested-transition-if-block-not-remounted/Span.html b/test/runtime/samples/nested-transition-if-block-not-remounted/Span.html new file mode 100644 index 0000000000..b16b370950 --- /dev/null +++ b/test/runtime/samples/nested-transition-if-block-not-remounted/Span.html @@ -0,0 +1 @@ +<span><slot></slot></span> \ No newline at end of file diff --git a/test/runtime/samples/nested-transition-if-block-not-remounted/_config.js b/test/runtime/samples/nested-transition-if-block-not-remounted/_config.js new file mode 100644 index 0000000000..128a518134 --- /dev/null +++ b/test/runtime/samples/nested-transition-if-block-not-remounted/_config.js @@ -0,0 +1,26 @@ +export default { + data: { + x: true, + value: 'one' + }, + + html: ` + <div> + <input> + <span>x</span> + </div> + `, + + nestedTransitions: true, + + test(assert, component, target, window, raf) { + const div = target.querySelector('div'); + const { appendChild, insertBefore } = div; + + div.appendChild = div.insertBefore = () => { + throw new Error('DOM was mutated'); + }; + + component.set({ value: 'two' }); + }, +}; diff --git a/test/runtime/samples/nested-transition-if-block-not-remounted/main.html b/test/runtime/samples/nested-transition-if-block-not-remounted/main.html new file mode 100644 index 0000000000..ad8b2454a8 --- /dev/null +++ b/test/runtime/samples/nested-transition-if-block-not-remounted/main.html @@ -0,0 +1,14 @@ +<div> + {#if x} + <input on:input="set({ value: this.value })"> + <Span>x</Span> + {/if} +</div> + +<script> + export default { + components: { + Span: './Span.html' + } + }; +</script> \ No newline at end of file diff --git a/test/runtime/samples/spread-component-multiple-dependencies/Widget.html b/test/runtime/samples/spread-component-multiple-dependencies/Widget.html new file mode 100644 index 0000000000..ab2d2d0242 --- /dev/null +++ b/test/runtime/samples/spread-component-multiple-dependencies/Widget.html @@ -0,0 +1 @@ +{foo} {baz} diff --git a/test/runtime/samples/spread-component-multiple-dependencies/_config.js b/test/runtime/samples/spread-component-multiple-dependencies/_config.js new file mode 100644 index 0000000000..42b0c5693f --- /dev/null +++ b/test/runtime/samples/spread-component-multiple-dependencies/_config.js @@ -0,0 +1,10 @@ +export default { + html: `b baz`, + test(assert, component, target) { + component.set({ foo: true }); + assert.htmlEqual( + target.innerHTML, + `a baz` + ); + }, +}; diff --git a/test/runtime/samples/spread-component-multiple-dependencies/main.html b/test/runtime/samples/spread-component-multiple-dependencies/main.html new file mode 100644 index 0000000000..dedfa27477 --- /dev/null +++ b/test/runtime/samples/spread-component-multiple-dependencies/main.html @@ -0,0 +1,13 @@ +<Widget foo={foo ? a : b} {...bar}/> + +<script> + export default { + components: { Widget: './Widget.html' }, + data: () => ({ + foo: false, + a: 'a', + b: 'b', + bar: { baz: 'baz' }, + }), + }; +</script> diff --git a/test/runtime/samples/spread-element-multiple-dependencies/_config.js b/test/runtime/samples/spread-element-multiple-dependencies/_config.js new file mode 100644 index 0000000000..e8f3d68e32 --- /dev/null +++ b/test/runtime/samples/spread-element-multiple-dependencies/_config.js @@ -0,0 +1,10 @@ +export default { + html: `<div class='b' title='baz'></div>`, + test(assert, component, target) { + component.set({ foo: true }); + assert.htmlEqual( + target.innerHTML, + `<div class='a' title='baz'></div>` + ); + }, +}; diff --git a/test/runtime/samples/spread-element-multiple-dependencies/main.html b/test/runtime/samples/spread-element-multiple-dependencies/main.html new file mode 100644 index 0000000000..f6f436714d --- /dev/null +++ b/test/runtime/samples/spread-element-multiple-dependencies/main.html @@ -0,0 +1,12 @@ +<div class={foo ? a : b} {...bar}></div> + +<script> + export default { + data: () => ({ + foo: false, + a: 'a', + b: 'b', + bar: { title: 'baz' }, + }), + }; +</script> diff --git a/test/server-side-rendering/samples/styles-nested/One.html b/test/server-side-rendering/samples/styles-nested/One.html index 8906363014..0e68dd3c28 100644 --- a/test/server-side-rendering/samples/styles-nested/One.html +++ b/test/server-side-rendering/samples/styles-nested/One.html @@ -1,7 +1,7 @@ <div>green: {message}</div> <!-- Two styles should *not* be included --> -<!-- <Two message='{{message}}'/> --> +<!-- <Two {message}/> --> <style> div { diff --git a/test/validator/samples/method-nonexistent-helper/warnings.json b/test/validator/samples/method-nonexistent-helper/warnings.json index b463045538..d1999de882 100644 --- a/test/validator/samples/method-nonexistent-helper/warnings.json +++ b/test/validator/samples/method-nonexistent-helper/warnings.json @@ -1,6 +1,6 @@ [{ "code": "invalid-callee", - "message": "'foo' is an invalid callee (should be one of this.*, event.*, options.*, console.*, set, fire, destroy or bar). 'foo' exists on 'helpers', did you put it in the wrong place?", + "message": "'foo' is an invalid callee (should be one of this.*, refs.*, event.*, options.*, console.*, set, fire, destroy or bar). 'foo' exists on 'helpers', did you put it in the wrong place?", "pos": 18, "start": { "line": 1, diff --git a/test/validator/samples/method-nonexistent/warnings.json b/test/validator/samples/method-nonexistent/warnings.json index 3ad9ee8734..d0a30ab928 100644 --- a/test/validator/samples/method-nonexistent/warnings.json +++ b/test/validator/samples/method-nonexistent/warnings.json @@ -1,6 +1,6 @@ [{ "code": "invalid-callee", - "message": "'foo' is an invalid callee (should be one of this.*, event.*, options.*, console.*, set, fire, destroy or bar)", + "message": "'foo' is an invalid callee (should be one of this.*, refs.*, event.*, options.*, console.*, set, fire, destroy or bar)", "pos": 18, "start": { "line": 1, diff --git a/test/validator/samples/title-no-children/errors.json b/test/validator/samples/title-no-children/errors.json index 9b10d700eb..37179189d2 100644 --- a/test/validator/samples/title-no-children/errors.json +++ b/test/validator/samples/title-no-children/errors.json @@ -1,6 +1,6 @@ [{ "code": "illegal-structure", - "message": "<title> can only contain text and {{tags}}", + "message": "<title> can only contain text and {tags}", "start": { "line": 2, "column": 11, diff --git a/test/validator/samples/window-event-invalid/warnings.json b/test/validator/samples/window-event-invalid/warnings.json index 1d20c8fac9..2e403fe27b 100644 --- a/test/validator/samples/window-event-invalid/warnings.json +++ b/test/validator/samples/window-event-invalid/warnings.json @@ -1,6 +1,6 @@ [{ "code": "invalid-callee", - "message": "'resize' is an invalid callee (should be one of this.*, event.*, options.*, console.*, set, fire or destroy)", + "message": "'resize' is an invalid callee (should be one of this.*, refs.*, event.*, options.*, console.*, set, fire or destroy)", "start": { "line": 1, "column": 26, diff --git a/yarn.lock b/yarn.lock index 77ac332dfc..540332563f 100644 --- a/yarn.lock +++ b/yarn.lock @@ -10,13 +10,17 @@ version "5.2.0" resolved "https://registry.yarnpkg.com/@types/mocha/-/mocha-5.2.0.tgz#b3c8e69f038835db1a7fdc0b3d879fc50506e29e" -"@types/node@*", "@types/node@^9.6.6": - version "9.6.6" - resolved "https://registry.yarnpkg.com/@types/node/-/node-9.6.6.tgz#439b91f9caf3983cad2eef1e11f6bedcbf9431d2" +"@types/node@*": + version "10.1.2" + resolved "https://registry.yarnpkg.com/@types/node/-/node-10.1.2.tgz#1b928a0baa408fc8ae3ac012cc81375addc147c6" "@types/node@^8.0.24": - version "8.10.9" - resolved "https://registry.yarnpkg.com/@types/node/-/node-8.10.9.tgz#b507a74a7d3eddc74a17dc35fd40d8f45dde0d6c" + version "8.10.17" + resolved "https://registry.yarnpkg.com/@types/node/-/node-8.10.17.tgz#d48cf10f0dc6dcf59f827f5a3fc7a4a6004318d3" + +"@types/node@^9.6.6": + version "9.6.18" + resolved "https://registry.yarnpkg.com/@types/node/-/node-9.6.18.tgz#092e13ef64c47e986802c9c45a61c1454813b31d" abab@^1.0.4: version "1.0.4" @@ -62,13 +66,6 @@ ajv-keywords@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-2.1.1.tgz#617997fc5f60576894c435f940d819e135b80762" -ajv@^4.9.1: - version "4.11.8" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-4.11.8.tgz#82ffb02b29e662ae53bdc20af15947706739c536" - dependencies: - co "^4.6.0" - json-stable-stringify "^1.0.1" - ajv@^5.1.0, ajv@^5.2.3, ajv@^5.3.0: version "5.5.2" resolved "https://registry.yarnpkg.com/ajv/-/ajv-5.5.2.tgz#73b5eeca3fab653e3d3f9422b341ad42205dc965" @@ -134,8 +131,8 @@ archy@^1.0.0: resolved "https://registry.yarnpkg.com/archy/-/archy-1.0.0.tgz#f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40" are-we-there-yet@~1.1.2: - version "1.1.4" - resolved "https://registry.yarnpkg.com/are-we-there-yet/-/are-we-there-yet-1.1.4.tgz#bb5dca382bb94f05e15194373d16fd3ba1ca110d" + version "1.1.5" + resolved "https://registry.yarnpkg.com/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz#4b35c2944f062a8bfcda66410760350fe9ddfc21" dependencies: delegates "^1.0.0" readable-stream "^2.0.6" @@ -206,10 +203,6 @@ assert-plus@1.0.0, assert-plus@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" -assert-plus@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-0.2.0.tgz#d74e1b87e7affc0db8aadb7021f3fe48101ab234" - assign-symbols@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/assign-symbols/-/assign-symbols-1.0.0.tgz#59667f41fadd4f20ccbc2bb96b8d4f7f78ec0367" @@ -230,19 +223,15 @@ asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" -atob@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.0.tgz#ab2b150e51d7b122b9efc8d7340c06b6c41076bc" - -aws-sign2@~0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.6.0.tgz#14342dd38dbcc94d0e5b87d763cd63612c0e794f" +atob@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.1.tgz#ae2d5a729477f289d60dd7f96a6314a22dd6c22a" aws-sign2@~0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" -aws4@^1.2.1, aws4@^1.6.0: +aws4@^1.6.0: version "1.7.0" resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.7.0.tgz#d4d0e9b9dbfca77bf08eeb0a8a471550fe39e289" @@ -343,24 +332,6 @@ binary-extensions@^1.0.0: version "1.11.0" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.11.0.tgz#46aa1751fb6a2f93ee5e689bb1087d4b14c6c205" -boom@2.x.x: - version "2.10.1" - resolved "https://registry.yarnpkg.com/boom/-/boom-2.10.1.tgz#39c8918ceff5799f83f9492a848f625add0c766f" - dependencies: - hoek "2.x.x" - -boom@4.x.x: - version "4.3.1" - resolved "https://registry.yarnpkg.com/boom/-/boom-4.3.1.tgz#4f8a3005cb4a7e3889f749030fd25b96e01d2e31" - dependencies: - hoek "4.x.x" - -boom@5.x.x: - version "5.2.0" - resolved "https://registry.yarnpkg.com/boom/-/boom-5.2.0.tgz#5dd9da6ee3a5f302077436290cb717d3f4a54e02" - dependencies: - hoek "4.x.x" - brace-expansion@^1.1.7: version "1.1.11" resolved "https://registry.yarnpkg.com/brace-expansion/-/brace-expansion-1.1.11.tgz#3c7fcbf529d87226f3d2f52b966ff5271eb441dd" @@ -497,8 +468,8 @@ chalk@^1.1.3: supports-color "^2.0.0" chalk@^2.0.0, chalk@^2.1.0, chalk@^2.3.0, chalk@^2.3.1, chalk@^2.4.0: - version "2.4.0" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.0.tgz#a060a297a6b57e15b61ca63ce84995daa0fe6e52" + version "2.4.1" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e" dependencies: ansi-styles "^3.2.1" escape-string-regexp "^1.0.5" @@ -559,8 +530,8 @@ cliui@^2.1.0: wordwrap "0.0.2" cliui@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/cliui/-/cliui-4.0.0.tgz#743d4650e05f36d1ed2575b59638d87322bfbbcc" + version "4.1.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-4.1.0.tgz#348422dbe82d800b3022eef4f6ac10bf2e4d1b49" dependencies: string-width "^2.1.1" strip-ansi "^4.0.0" @@ -583,11 +554,11 @@ code-point-at@^1.0.0: resolved "https://registry.yarnpkg.com/code-point-at/-/code-point-at-1.1.0.tgz#0d070b4d043a5bea33a2f1a40e2edb3d9a4ccf77" codecov@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/codecov/-/codecov-3.0.0.tgz#c273b8c4f12945723e8dc9d25803d89343e5f28e" + version "3.0.2" + resolved "https://registry.yarnpkg.com/codecov/-/codecov-3.0.2.tgz#aea43843a5cd2fb6b7e488b2eff25d367ab70b12" dependencies: argv "0.0.2" - request "2.81.0" + request "^2.81.0" urlgrey "0.4.4" collection-visit@^1.0.0: @@ -607,7 +578,7 @@ color-name@^1.1.1: version "1.1.3" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" -combined-stream@1.0.6, combined-stream@^1.0.5, combined-stream@~1.0.5: +combined-stream@1.0.6, combined-stream@~1.0.5: version "1.0.6" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.6.tgz#723e7df6e801ac5613113a7e445a9b69cb632818" dependencies: @@ -641,15 +612,7 @@ concat-map@0.0.1: version "0.0.1" resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" -concat-stream@1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.0.tgz#0aac662fd52be78964d5532f694784e70110acf7" - dependencies: - inherits "^2.0.3" - readable-stream "^2.2.2" - typedarray "^0.0.6" - -concat-stream@^1.6.0: +concat-stream@1.6.2, concat-stream@^1.6.0: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" dependencies: @@ -679,8 +642,8 @@ copy-descriptor@^0.1.0: resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" core-js@^2.4.0: - version "2.5.5" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.5.tgz#b14dde936c640c0579a6b50cabcc132dd6127e3b" + version "2.5.7" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.5.7.tgz#f972608ff0cead68b841a16a932d0b183791814e" core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" @@ -701,18 +664,6 @@ cross-spawn@^5.0.1, cross-spawn@^5.1.0: shebang-command "^1.2.0" which "^1.2.9" -cryptiles@2.x.x: - version "2.0.5" - resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-2.0.5.tgz#3bdfecdc608147c1c67202fa291e7dca59eaa3b8" - dependencies: - boom "2.x.x" - -cryptiles@3.x.x: - version "3.1.2" - resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-3.1.2.tgz#a89fbb220f5ce25ec56e8c4aa8a4fd7b5b0d29fe" - dependencies: - boom "5.x.x" - css-tree@1.0.0-alpha22: version "1.0.0-alpha22" resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.0.0-alpha22.tgz#338a006e331c7b4f9dab7b6af539ece56ff78af2" @@ -724,9 +675,9 @@ cssom@0.3.x, "cssom@>= 0.3.2 < 0.4.0": version "0.3.2" resolved "https://registry.yarnpkg.com/cssom/-/cssom-0.3.2.tgz#b8036170c79f07a90ff2f16e22284027a243848b" -"cssstyle@>= 0.2.37 < 0.3.0": - version "0.2.37" - resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-0.2.37.tgz#541097234cb2513c83ceed3acddc27ff27987d54" +"cssstyle@>= 0.3.1 < 0.4.0": + version "0.3.1" + resolved "https://registry.yarnpkg.com/cssstyle/-/cssstyle-0.3.1.tgz#6da9b4cff1bc5d716e6e5fe8e04fcb1b50a49adf" dependencies: cssom "0.3.x" @@ -786,9 +737,9 @@ deep-defaults@^1.0.3: dependencies: lodash "3.0.x" -deep-extend@~0.4.0: - version "0.4.2" - resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.4.2.tgz#48b699c27e334bf89f10892be432f6e4c7d34a7f" +deep-extend@^0.5.1: + version "0.5.1" + resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.5.1.tgz#b894a9dd90d3023fbf1c55a394fb858eb2066f1f" deep-is@~0.1.3: version "0.1.3" @@ -898,8 +849,8 @@ domexception@^1.0.0: webidl-conversions "^4.0.2" domhandler@^2.3.0: - version "2.4.1" - resolved "https://registry.yarnpkg.com/domhandler/-/domhandler-2.4.1.tgz#892e47000a99be55bbf3774ffea0561d8879c259" + version "2.4.2" + resolved "https://registry.yarnpkg.com/domhandler/-/domhandler-2.4.2.tgz#8805097e933d65e85546f726d60f5eb88b44f803" dependencies: domelementtype "1" @@ -931,8 +882,8 @@ electron-download@^3.0.1: sumchecker "^1.2.0" electron@^1.8.4: - version "1.8.4" - resolved "https://registry.yarnpkg.com/electron/-/electron-1.8.4.tgz#cca8d0e6889f238f55b414ad224f03e03b226a38" + version "1.8.7" + resolved "https://registry.yarnpkg.com/electron/-/electron-1.8.7.tgz#373c1dc4589d7ab4acd49aff8db4a1c0a6c3bcc1" dependencies: "@types/node" "^8.0.24" electron-download "^3.0.1" @@ -994,8 +945,8 @@ eslint-plugin-html@^4.0.3: htmlparser2 "^3.8.2" eslint-plugin-import@^2.11.0: - version "2.11.0" - resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-2.11.0.tgz#15aeea37a67499d848e8e981806d4627b5503816" + version "2.12.0" + resolved "https://registry.yarnpkg.com/eslint-plugin-import/-/eslint-plugin-import-2.12.0.tgz#dad31781292d6664b25317fd049d2e2b2f02205d" dependencies: contains-path "^0.1.0" debug "^2.6.8" @@ -1097,13 +1048,9 @@ estree-walker@^0.2.1: version "0.2.1" resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-0.2.1.tgz#bdafe8095383d8414d5dc2ecf4c9173b6db9412e" -estree-walker@^0.3.0: - version "0.3.1" - resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-0.3.1.tgz#e6b1a51cf7292524e7237c312e5fe6660c1ce1aa" - -estree-walker@^0.5.1: - version "0.5.1" - resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-0.5.1.tgz#64fc375053abc6f57d73e9bd2f004644ad3c5854" +estree-walker@^0.5.1, estree-walker@^0.5.2: + version "0.5.2" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-0.5.2.tgz#d3850be7529c9580d815600b53126515e146dd39" esutils@^2.0.2: version "2.0.2" @@ -1158,7 +1105,7 @@ extend-shallow@^3.0.0, extend-shallow@^3.0.2: assign-symbols "^1.0.0" is-extendable "^1.0.1" -extend@~3.0.0, extend@~3.0.1: +extend@~3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444" @@ -1190,12 +1137,12 @@ extglob@^2.0.4: to-regex "^3.0.1" extract-zip@^1.0.3: - version "1.6.6" - resolved "https://registry.yarnpkg.com/extract-zip/-/extract-zip-1.6.6.tgz#1290ede8d20d0872b429fd3f351ca128ec5ef85c" + version "1.6.7" + resolved "https://registry.yarnpkg.com/extract-zip/-/extract-zip-1.6.7.tgz#a840b4b8af6403264c8db57f4f1a74333ef81fe9" dependencies: - concat-stream "1.6.0" + concat-stream "1.6.2" debug "2.6.9" - mkdirp "0.5.0" + mkdirp "0.5.1" yauzl "2.4.1" extsprintf@1.3.0: @@ -1242,12 +1189,12 @@ filename-regex@^2.0.0: resolved "https://registry.yarnpkg.com/filename-regex/-/filename-regex-2.0.1.tgz#c1c4b9bee3e09725ddb106b75c1e301fe2f18b26" fill-range@^2.1.0: - version "2.2.3" - resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-2.2.3.tgz#50b77dfd7e469bc7492470963699fe7a8485a723" + version "2.2.4" + resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-2.2.4.tgz#eb1e773abb056dcd8df2bfdf6af59b8b3a936565" dependencies: is-number "^2.1.0" isobject "^2.0.0" - randomatic "^1.1.3" + randomatic "^3.0.0" repeat-element "^1.1.2" repeat-string "^1.5.2" @@ -1311,14 +1258,6 @@ forever-agent@~0.6.1: version "0.6.1" resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" -form-data@~2.1.1: - version "2.1.4" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.1.4.tgz#33c183acf193276ecaa98143a69e94bfee1750d1" - dependencies: - asynckit "^0.4.0" - combined-stream "^1.0.5" - mime-types "^2.1.12" - form-data@~2.3.1: version "2.3.2" resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.2.tgz#4970498be604c20c005d4f5c23aecd21d6b49099" @@ -1354,11 +1293,11 @@ fs.realpath@^1.0.0: resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f" fsevents@^1.0.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.0.tgz#e11a5ff285471e4cc43ab9cd09bb7986c565dcdc" + version "1.2.4" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.4.tgz#f41dcb1af2582af3692da36fc55cbd8e1041c426" dependencies: nan "^2.9.2" - node-pre-gyp "^0.9.0" + node-pre-gyp "^0.10.0" function-bind@^1.0.2: version "1.1.1" @@ -1431,7 +1370,7 @@ glob@7.1.1: once "^1.3.0" path-is-absolute "^1.0.0" -glob@^7.0.3, glob@^7.0.5, glob@^7.0.6, glob@^7.1.2: +glob@^7.0.0, glob@^7.0.3, glob@^7.0.5, glob@^7.0.6, glob@^7.1.2: version "7.1.2" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.2.tgz#c19c9df9a028702d678612384a6552404c636d15" dependencies: @@ -1443,8 +1382,8 @@ glob@^7.0.3, glob@^7.0.5, glob@^7.0.6, glob@^7.1.2: path-is-absolute "^1.0.0" globals@^11.0.1: - version "11.4.0" - resolved "https://registry.yarnpkg.com/globals/-/globals-11.4.0.tgz#b85c793349561c16076a3c13549238a27945f1bc" + version "11.5.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-11.5.0.tgz#6bc840de6771173b191f13d3a9c94d441ee92642" globals@^9.18.0: version "9.18.0" @@ -1491,21 +1430,10 @@ handlebars@^4.0.3: optionalDependencies: uglify-js "^2.6" -har-schema@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-1.0.5.tgz#d263135f43307c02c602afc8fe95970c0151369e" - har-schema@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" -har-validator@~4.2.1: - version "4.2.1" - resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-4.2.1.tgz#33481d0f1bbff600dd203d75812a6a5fba002e2a" - dependencies: - ajv "^4.9.1" - har-schema "^1.0.5" - har-validator@~5.0.3: version "5.0.3" resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.0.3.tgz#ba402c266194f15956ef15e0fcf242993f6a7dfd" @@ -1564,39 +1492,13 @@ has@^1.0.1: dependencies: function-bind "^1.0.2" -hawk@~3.1.3: - version "3.1.3" - resolved "https://registry.yarnpkg.com/hawk/-/hawk-3.1.3.tgz#078444bd7c1640b0fe540d2c9b73d59678e8e1c4" - dependencies: - boom "2.x.x" - cryptiles "2.x.x" - hoek "2.x.x" - sntp "1.x.x" - -hawk@~6.0.2: - version "6.0.2" - resolved "https://registry.yarnpkg.com/hawk/-/hawk-6.0.2.tgz#af4d914eb065f9b5ce4d9d11c1cb2126eecc3038" - dependencies: - boom "4.x.x" - cryptiles "3.x.x" - hoek "4.x.x" - sntp "2.x.x" - he@1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/he/-/he-1.1.1.tgz#93410fd21b009735151f8868c2f271f3427e23fd" -hoek@2.x.x: - version "2.16.3" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-2.16.3.tgz#20bb7403d3cea398e91dc4710a8ff1b8274a25ed" - -hoek@4.x.x: - version "4.2.1" - resolved "https://registry.yarnpkg.com/hoek/-/hoek-4.2.1.tgz#9634502aa12c445dd5a7c5734b572bb8738aacbb" - home-path@^1.0.1: - version "1.0.5" - resolved "https://registry.yarnpkg.com/home-path/-/home-path-1.0.5.tgz#788b29815b12d53bacf575648476e6f9041d133f" + version "1.0.6" + resolved "https://registry.yarnpkg.com/home-path/-/home-path-1.0.6.tgz#d549dc2465388a7f8667242c5b31588d29af29fc" hosted-git-info@^2.1.4: version "2.6.0" @@ -1619,14 +1521,6 @@ htmlparser2@^3.8.2: inherits "^2.0.1" readable-stream "^2.0.2" -http-signature@~1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.1.1.tgz#df72e267066cd0ac67fb76adf8e134a8fbcf91bf" - dependencies: - assert-plus "^0.2.0" - jsprim "^1.2.2" - sshpk "^1.7.0" - http-signature@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" @@ -1640,10 +1534,10 @@ iconv-lite@0.4.19: resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.19.tgz#f7468f60135f5e5dad3399c0a81be9a1603a082b" iconv-lite@^0.4.17, iconv-lite@^0.4.4: - version "0.4.21" - resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.21.tgz#c47f8733d02171189ebc4a400f3218d348094798" + version "0.4.23" + resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.23.tgz#297871f63be507adcfbfca715d0cd0eed84e9a63" dependencies: - safer-buffer "^2.1.0" + safer-buffer ">= 2.1.2 < 3" ignore-walk@^3.0.1: version "3.0.1" @@ -1652,8 +1546,8 @@ ignore-walk@^3.0.1: minimatch "^3.0.4" ignore@^3.3.3: - version "3.3.7" - resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.7.tgz#612289bfb3c220e186a58118618d5be8c1bab021" + version "3.3.8" + resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.8.tgz#3f8e9c35d38708a3a7e0e9abb6c73e7ee7707b2b" imurmurhash@^0.1.4: version "0.1.4" @@ -1699,6 +1593,10 @@ inquirer@^3.0.6: strip-ansi "^4.0.0" through "^2.3.6" +interpret@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.1.0.tgz#7ed1b1410c6a0e0f78cf95d3b8440c63f78b8614" + invariant@^2.2.2: version "2.2.4" resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6" @@ -1990,21 +1888,21 @@ jsbn@~0.1.0: resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" jsdom@^11.8.0: - version "11.8.0" - resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-11.8.0.tgz#a52e9a7d2b931284f62c80dad5f17d7390499d8b" + version "11.11.0" + resolved "https://registry.yarnpkg.com/jsdom/-/jsdom-11.11.0.tgz#df486efad41aee96c59ad7a190e2449c7eb1110e" dependencies: abab "^1.0.4" acorn "^5.3.0" acorn-globals "^4.1.0" array-equal "^1.0.0" cssom ">= 0.3.2 < 0.4.0" - cssstyle ">= 0.2.37 < 0.3.0" + cssstyle ">= 0.3.1 < 0.4.0" data-urls "^1.0.0" domexception "^1.0.0" escodegen "^1.9.0" html-encoding-sniffer "^1.0.2" left-pad "^1.2.0" - nwmatcher "^1.4.3" + nwsapi "^2.0.0" parse5 "4.0.0" pn "^1.1.0" request "^2.83.0" @@ -2016,7 +1914,7 @@ jsdom@^11.8.0: webidl-conversions "^4.0.2" whatwg-encoding "^1.0.3" whatwg-mimetype "^2.1.0" - whatwg-url "^6.4.0" + whatwg-url "^6.4.1" ws "^4.0.0" xml-name-validator "^3.0.0" @@ -2040,12 +1938,6 @@ json-stable-stringify-without-jsonify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" -json-stable-stringify@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz#9a759d39c5f2ff503fd5300646ed445f88c4f9af" - dependencies: - jsonify "~0.0.0" - json-stringify-safe@~5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" @@ -2060,10 +1952,6 @@ jsonfile@^2.1.0: optionalDependencies: graceful-fs "^4.1.6" -jsonify@~0.0.0: - version "0.0.0" - resolved "https://registry.yarnpkg.com/jsonify/-/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" - jsprim@^1.2.2: version "1.4.1" resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.1.tgz#313e66bc1e5cc06e438bc1b7499c2e5c56acb6a2" @@ -2210,8 +2098,8 @@ lodash@3.0.x: resolved "https://registry.yarnpkg.com/lodash/-/lodash-3.0.1.tgz#14d49028a38bc740241d11e2ecd57ec06d73c19a" lodash@^4.13.1, lodash@^4.17.4, lodash@^4.3.0: - version "4.17.5" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.5.tgz#99a92d65c0272debe8c96b6057bc8fbfa3bed511" + version "4.17.10" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.10.tgz#1b7793cf7259ea38fb3661d4d38b3260af8ae4e7" longest@^1.0.1: version "1.0.1" @@ -2231,8 +2119,8 @@ loud-rejection@^1.0.0: signal-exit "^3.0.0" lru-cache@^4.0.1: - version "4.1.2" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.2.tgz#45234b2e6e2f2b33da125624c4664929a0224c3f" + version "4.1.3" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-4.1.3.tgz#a1175cf3496dfc8436c156c334b4955992bce69c" dependencies: pseudomap "^1.0.2" yallist "^2.1.2" @@ -2244,8 +2132,8 @@ magic-string@^0.22.4: vlq "^0.2.2" magic-string@^0.24.0: - version "0.24.0" - resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.24.0.tgz#1b396d26406188f1fa3730a68229562d36a1c2f2" + version "0.24.1" + resolved "https://registry.yarnpkg.com/magic-string/-/magic-string-0.24.1.tgz#7e38e5f126cae9f15e71f0cf8e450818ca7d5a8f" dependencies: sourcemap-codec "^1.4.1" @@ -2267,6 +2155,10 @@ map-visit@^1.0.0: dependencies: object-visit "^1.0.0" +math-random@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/math-random/-/math-random-1.0.1.tgz#8b3aac588b8a66e4975e3cdea67f7bb329601fac" + md5-hex@^1.2.0: version "1.3.0" resolved "https://registry.yarnpkg.com/md5-hex/-/md5-hex-1.3.0.tgz#d2c4afe983c4370662179b8cad145219135046c4" @@ -2278,8 +2170,8 @@ md5-o-matic@^0.1.1: resolved "https://registry.yarnpkg.com/md5-o-matic/-/md5-o-matic-0.1.1.tgz#822bccd65e117c514fab176b25945d54100a03c3" mdn-data@^1.0.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-1.1.1.tgz#79586c90321787e5a2e51eb6823bb448949bc1ab" + version "1.1.3" + resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-1.1.3.tgz#d0929cdf73db32b0afd6d3ab8ef3da2b29b6f76b" mem@^1.1.0: version "1.1.0" @@ -2302,7 +2194,7 @@ meow@^3.1.0: redent "^1.0.0" trim-newlines "^1.0.0" -merge-source-map@^1.0.2: +merge-source-map@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/merge-source-map/-/merge-source-map-1.1.0.tgz#2fdde7e6020939f70906a68f2d7ae685e4c8c646" dependencies: @@ -2326,7 +2218,7 @@ micromatch@^2.1.5, micromatch@^2.3.11: parse-glob "^3.0.4" regex-cache "^0.4.2" -micromatch@^3.1.8: +micromatch@^3.1.10, micromatch@^3.1.8: version "3.1.10" resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-3.1.10.tgz#70859bc95c9840952f359a068a3fc49f9ecfac23" dependencies: @@ -2348,7 +2240,7 @@ mime-db@~1.33.0: version "1.33.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.33.0.tgz#a3492050a5cb9b63450541e39d9788d2272783db" -mime-types@^2.1.12, mime-types@~2.1.17, mime-types@~2.1.7: +mime-types@^2.1.12, mime-types@~2.1.17: version "2.1.18" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.18.tgz#6f323f60a83d11146f831ff11fd66e2fe5503bb8" dependencies: @@ -2376,11 +2268,11 @@ minimist@~0.0.1: version "0.0.10" resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf" -minipass@^2.2.1, minipass@^2.2.4: - version "2.2.4" - resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.2.4.tgz#03c824d84551ec38a8d1bb5bc350a5a30a354a40" +minipass@^2.2.1, minipass@^2.3.3: + version "2.3.3" + resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.3.3.tgz#a7dcc8b7b833f5d368759cce544dccb55f50f233" dependencies: - safe-buffer "^5.1.1" + safe-buffer "^5.1.2" yallist "^3.0.0" minizlib@^1.1.0: @@ -2402,12 +2294,6 @@ mixin-deep@^1.2.0: for-in "^1.0.2" is-extendable "^1.0.1" -mkdirp@0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.0.tgz#1d73076a6df986cd9344e15e71fcc05a4c9abf12" - dependencies: - minimist "0.0.8" - mkdirp@0.5.1, mkdirp@^0.5.0, mkdirp@^0.5.1: version "0.5.1" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" @@ -2432,8 +2318,8 @@ mocha@3: supports-color "3.1.2" mri@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/mri/-/mri-1.1.0.tgz#5c0a3f29c8ccffbbb1ec941dcec09d71fa32f36a" + version "1.1.1" + resolved "https://registry.yarnpkg.com/mri/-/mri-1.1.1.tgz#85aa26d3daeeeedf80dc5984af95cc5ca5cad9f1" ms@2.0.0: version "2.0.0" @@ -2475,8 +2361,8 @@ natural-compare@^1.4.0: resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" needle@^2.2.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/needle/-/needle-2.2.0.tgz#f14efc69cee1024b72c8b21c7bdf94a731dc12fa" + version "2.2.1" + resolved "https://registry.yarnpkg.com/needle/-/needle-2.2.1.tgz#b5e325bd3aae8c2678902fa296f729455d1d3a7d" dependencies: debug "^2.1.2" iconv-lite "^0.4.4" @@ -2501,9 +2387,9 @@ nightmare@^3.0.1: sliced "1.0.1" split2 "^2.0.1" -node-pre-gyp@^0.9.0: - version "0.9.1" - resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.9.1.tgz#f11c07516dd92f87199dbc7e1838eab7cd56c9e0" +node-pre-gyp@^0.10.0: + version "0.10.0" + resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.10.0.tgz#6e4ef5bb5c5203c6552448828c852c40111aac46" dependencies: detect-libc "^1.0.2" mkdirp "^0.5.1" @@ -2587,13 +2473,13 @@ number-is-nan@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/number-is-nan/-/number-is-nan-1.0.1.tgz#097b602b53422a522c1afb8790318336941a011d" -nwmatcher@^1.4.3: - version "1.4.4" - resolved "https://registry.yarnpkg.com/nwmatcher/-/nwmatcher-1.4.4.tgz#2285631f34a95f0d0395cd900c96ed39b58f346e" +nwsapi@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.0.0.tgz#7c8faf4ad501e1d17a651ebc5547f966b547c5c7" nyc@^11.7.1: - version "11.7.1" - resolved "https://registry.yarnpkg.com/nyc/-/nyc-11.7.1.tgz#7cb0a422e501b88ff2c1634341dec2560299d67b" + version "11.8.0" + resolved "https://registry.yarnpkg.com/nyc/-/nyc-11.8.0.tgz#1e8453b0644f8fea4d829b1a6636663157cd3b00" dependencies: archy "^1.0.0" arrify "^1.0.1" @@ -2612,18 +2498,18 @@ nyc@^11.7.1: istanbul-lib-source-maps "^1.2.3" istanbul-reports "^1.4.0" md5-hex "^1.2.0" - merge-source-map "^1.0.2" - micromatch "^2.3.11" + merge-source-map "^1.1.0" + micromatch "^3.1.10" mkdirp "^0.5.0" resolve-from "^2.0.0" - rimraf "^2.5.4" + rimraf "^2.6.2" signal-exit "^3.0.1" spawn-wrap "^1.4.2" test-exclude "^4.2.0" yargs "11.1.0" yargs-parser "^8.0.0" -oauth-sign@~0.8.1, oauth-sign@~0.8.2: +oauth-sign@~0.8.2: version "0.8.2" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43" @@ -2808,10 +2694,6 @@ pend@~1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/pend/-/pend-1.2.0.tgz#7a57eb550a6783f9115331fcf4663d5c8e007a50" -performance-now@^0.2.0: - version "0.2.0" - resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-0.2.0.tgz#33ef30c5c77d4ea21c5a53869d91b56d8f2555e5" - performance-now@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" @@ -2891,29 +2773,26 @@ punycode@^1.4.1: resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" punycode@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.0.tgz#5f863edc89b96db09074bad7947bf09056ca4e7d" - -qs@~6.4.0: - version "6.4.0" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.4.0.tgz#13e26d28ad6b0ffaa91312cd3bf708ed351e7233" + version "2.1.1" + resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" qs@~6.5.1: - version "6.5.1" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.1.tgz#349cdf6eef89ec45c12d7d5eb3fc0c870343a6d8" + version "6.5.2" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.2.tgz#cb3ae806e8740444584ef154ce8ee98d403f3e36" -randomatic@^1.1.3: - version "1.1.7" - resolved "https://registry.yarnpkg.com/randomatic/-/randomatic-1.1.7.tgz#c7abe9cc8b87c0baa876b19fde83fd464797e38c" +randomatic@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/randomatic/-/randomatic-3.0.0.tgz#d35490030eb4f7578de292ce6dfb04a91a128923" dependencies: - is-number "^3.0.0" - kind-of "^4.0.0" + is-number "^4.0.0" + kind-of "^6.0.0" + math-random "^1.0.1" rc@^1.1.2, rc@^1.1.7: - version "1.2.6" - resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.6.tgz#eb18989c6d4f4f162c399f79ddd29f3835568092" + version "1.2.7" + resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.7.tgz#8a10ca30d588d00464360372b890d06dacd02297" dependencies: - deep-extend "~0.4.0" + deep-extend "^0.5.1" ini "~1.3.0" minimist "^1.2.0" strip-json-comments "~2.0.1" @@ -2978,6 +2857,12 @@ readdirp@^2.0.0: readable-stream "^2.0.2" set-immediate-shim "^1.0.1" +rechoir@^0.6.2: + version "0.6.2" + resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" + dependencies: + resolve "^1.1.6" + redent@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/redent/-/redent-1.0.0.tgz#cf916ab1fd5f1f16dfb20822dd6ec7f730c2afde" @@ -3045,36 +2930,9 @@ request-promise-native@^1.0.5: stealthy-require "^1.1.0" tough-cookie ">=2.3.3" -request@2.81.0: - version "2.81.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.81.0.tgz#c6928946a0e06c5f8d6f8a9333469ffda46298a0" - dependencies: - aws-sign2 "~0.6.0" - aws4 "^1.2.1" - caseless "~0.12.0" - combined-stream "~1.0.5" - extend "~3.0.0" - forever-agent "~0.6.1" - form-data "~2.1.1" - har-validator "~4.2.1" - hawk "~3.1.3" - http-signature "~1.1.0" - is-typedarray "~1.0.0" - isstream "~0.1.2" - json-stringify-safe "~5.0.1" - mime-types "~2.1.7" - oauth-sign "~0.8.1" - performance-now "^0.2.0" - qs "~6.4.0" - safe-buffer "^5.0.1" - stringstream "~0.0.4" - tough-cookie "~2.3.0" - tunnel-agent "^0.6.0" - uuid "^3.0.0" - -request@^2.45.0, request@^2.83.0: - version "2.85.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.85.0.tgz#5a03615a47c61420b3eb99b7dba204f83603e1fa" +request@^2.45.0, request@^2.81.0, request@^2.83.0: + version "2.87.0" + resolved "https://registry.yarnpkg.com/request/-/request-2.87.0.tgz#32f00235cd08d482b4d0d68db93a829c0ed5756e" dependencies: aws-sign2 "~0.7.0" aws4 "^1.6.0" @@ -3084,7 +2942,6 @@ request@^2.45.0, request@^2.83.0: forever-agent "~0.6.1" form-data "~2.3.1" har-validator "~5.0.3" - hawk "~6.0.2" http-signature "~1.2.0" is-typedarray "~1.0.0" isstream "~0.1.2" @@ -3094,7 +2951,6 @@ request@^2.45.0, request@^2.83.0: performance-now "^2.1.0" qs "~6.5.1" safe-buffer "^5.1.1" - stringstream "~0.0.5" tough-cookie "~2.3.3" tunnel-agent "^0.6.0" uuid "^3.1.0" @@ -3153,7 +3009,7 @@ right-align@^0.1.1: dependencies: align-text "^0.1.1" -rimraf@^2.2.8, rimraf@^2.4.3, rimraf@^2.5.2, rimraf@^2.5.4, rimraf@^2.6.1, rimraf@^2.6.2: +rimraf@^2.2.8, rimraf@^2.4.3, rimraf@^2.5.2, rimraf@^2.6.1, rimraf@^2.6.2: version "2.6.2" resolved "https://registry.yarnpkg.com/rimraf/-/rimraf-2.6.2.tgz#2ed8150d24a16ea8651e6d6ef0f47c4158ce7a36" dependencies: @@ -3167,8 +3023,8 @@ rollup-plugin-buble@^0.19.2: rollup-pluginutils "^2.0.1" rollup-plugin-commonjs@^9.1.0: - version "9.1.0" - resolved "https://registry.yarnpkg.com/rollup-plugin-commonjs/-/rollup-plugin-commonjs-9.1.0.tgz#468341aab32499123ee9a04b22f51d9bf26fdd94" + version "9.1.3" + resolved "https://registry.yarnpkg.com/rollup-plugin-commonjs/-/rollup-plugin-commonjs-9.1.3.tgz#37bfbf341292ea14f512438a56df8f9ca3ba4d67" dependencies: estree-walker "^0.5.1" magic-string "^0.22.4" @@ -3176,8 +3032,8 @@ rollup-plugin-commonjs@^9.1.0: rollup-pluginutils "^2.0.1" rollup-plugin-json@^2.1.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/rollup-plugin-json/-/rollup-plugin-json-2.3.0.tgz#3c07a452c1b5391be28006fbfff3644056ce0add" + version "2.3.1" + resolved "https://registry.yarnpkg.com/rollup-plugin-json/-/rollup-plugin-json-2.3.1.tgz#9759d27f33dcd2c896de18b6235df162b88edd77" dependencies: rollup-pluginutils "^2.0.1" @@ -3219,10 +3075,10 @@ rollup-pluginutils@^1.3.1: minimatch "^3.0.2" rollup-pluginutils@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/rollup-pluginutils/-/rollup-pluginutils-2.0.1.tgz#7ec95b3573f6543a46a6461bd9a7c544525d0fc0" + version "2.3.0" + resolved "https://registry.yarnpkg.com/rollup-pluginutils/-/rollup-pluginutils-2.3.0.tgz#478ace04bd7f6da2e724356ca798214884738fc4" dependencies: - estree-walker "^0.3.0" + estree-walker "^0.5.2" micromatch "^2.3.11" rollup-watch@^4.3.1: @@ -3234,8 +3090,8 @@ rollup-watch@^4.3.1: rollup-pluginutils "^2.0.1" rollup@^0.58.1: - version "0.58.1" - resolved "https://registry.yarnpkg.com/rollup/-/rollup-0.58.1.tgz#5e2e05ceb103f770868b12c4048c22d3903fa2dd" + version "0.58.2" + resolved "https://registry.yarnpkg.com/rollup/-/rollup-0.58.2.tgz#2feddea8c0c022f3e74b35c48e3c21b3433803ce" dependencies: "@types/estree" "0.0.38" "@types/node" "*" @@ -3257,15 +3113,15 @@ rx-lite@*, rx-lite@^4.0.8: resolved "https://registry.yarnpkg.com/rx-lite/-/rx-lite-4.0.8.tgz#0b1e11af8bc44836f04a6407e92da42467b79444" sade@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/sade/-/sade-1.4.0.tgz#51874eb18600aa54ee39c8f566c2f4c999a7cd47" + version "1.4.1" + resolved "https://registry.yarnpkg.com/sade/-/sade-1.4.1.tgz#80c6dfd3c03db1fbcd6bc10c0eb52f71e7cadc01" dependencies: mri "^1.1.0" pad-right "^0.2.2" -safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@~5.1.0, safe-buffer@~5.1.1: - version "5.1.1" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.1.tgz#893312af69b2123def71f57889001671eeb2c853" +safe-buffer@^5.0.1, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: + version "5.1.2" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" safe-regex@^1.1.0: version "1.1.0" @@ -3273,7 +3129,7 @@ safe-regex@^1.1.0: dependencies: ret "~0.1.10" -safer-buffer@^2.1.0: +"safer-buffer@>= 2.1.2 < 3": version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" @@ -3329,6 +3185,14 @@ shebang-regex@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3" +shelljs@^0.8.2: + version "0.8.2" + resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.8.2.tgz#345b7df7763f4c2340d584abb532c5f752ca9e35" + dependencies: + glob "^7.0.0" + interpret "^1.0.0" + rechoir "^0.6.2" + signal-exit@^3.0.0, signal-exit@^3.0.1, signal-exit@^3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" @@ -3384,32 +3248,21 @@ snapdragon@^0.8.1: source-map-resolve "^0.5.0" use "^3.1.0" -sntp@1.x.x: - version "1.0.9" - resolved "https://registry.yarnpkg.com/sntp/-/sntp-1.0.9.tgz#6541184cc90aeea6c6e7b35e2659082443c66198" - dependencies: - hoek "2.x.x" - -sntp@2.x.x: - version "2.1.0" - resolved "https://registry.yarnpkg.com/sntp/-/sntp-2.1.0.tgz#2c6cec14fedc2222739caf9b5c3d85d1cc5a2cc8" - dependencies: - hoek "4.x.x" - source-map-resolve@^0.5.0: - version "0.5.1" - resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.1.tgz#7ad0f593f2281598e854df80f19aae4b92d7a11a" + version "0.5.2" + resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.2.tgz#72e2cc34095543e43b2c62b2c4c10d4a9054f259" dependencies: - atob "^2.0.0" + atob "^2.1.1" decode-uri-component "^0.2.0" resolve-url "^0.2.1" source-map-url "^0.4.0" urix "^0.1.0" source-map-support@^0.5.3, source-map-support@^0.5.4: - version "0.5.4" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.4.tgz#54456efa89caa9270af7cd624cc2f123e51fbae8" + version "0.5.6" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.6.tgz#4435cee46b1aab62b8e8610ce60f788091c51c13" dependencies: + buffer-from "^1.0.0" source-map "^0.6.0" source-map-url@^0.4.0: @@ -3512,7 +3365,7 @@ stealthy-require@^1.1.0: version "1.1.1" resolved "https://registry.yarnpkg.com/stealthy-require/-/stealthy-require-1.1.1.tgz#35b09875b4ff49f26a777e509b3090a3226bf24b" -string-width@^1.0.1, string-width@^1.0.2: +string-width@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" dependencies: @@ -3520,7 +3373,7 @@ string-width@^1.0.1, string-width@^1.0.2: is-fullwidth-code-point "^1.0.0" strip-ansi "^3.0.0" -string-width@^2.0.0, string-width@^2.1.0, string-width@^2.1.1: +"string-width@^1.0.2 || 2", string-width@^2.0.0, string-width@^2.1.0, string-width@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/string-width/-/string-width-2.1.1.tgz#ab93f27a8dc13d28cac815c462143a6d9012ae9e" dependencies: @@ -3537,10 +3390,6 @@ string_decoder@~1.1.1: dependencies: safe-buffer "~5.1.0" -stringstream@~0.0.4, stringstream@~0.0.5: - version "0.0.5" - resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.5.tgz#4e484cd4de5a0bbbee18e46307710a8a81621878" - strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf" @@ -3622,15 +3471,15 @@ table@4.0.2: string-width "^2.1.1" tar@^4: - version "4.4.1" - resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.1.tgz#b25d5a8470c976fd7a9a8a350f42c59e9fa81749" + version "4.4.4" + resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.4.tgz#ec8409fae9f665a4355cc3b4087d0820232bb8cd" dependencies: chownr "^1.0.1" fs-minipass "^1.2.5" - minipass "^2.2.4" + minipass "^2.3.3" minizlib "^1.1.0" mkdirp "^0.5.0" - safe-buffer "^5.1.1" + safe-buffer "^5.1.2" yallist "^3.0.2" test-exclude@^4.2.0: @@ -3712,13 +3561,13 @@ to-regex@^3.0.1, to-regex@^3.0.2: regex-not "^1.0.2" safe-regex "^1.1.0" -tough-cookie@>=2.3.3, tough-cookie@^2.3.3, tough-cookie@~2.3.0, tough-cookie@~2.3.3: +tough-cookie@>=2.3.3, tough-cookie@^2.3.3, tough-cookie@~2.3.3: version "2.3.4" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.4.tgz#ec60cee38ac675063ffc97a5c18970578ee83655" dependencies: punycode "^1.4.1" -tr46@^1.0.0: +tr46@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/tr46/-/tr46-1.0.1.tgz#a8b13fd6bfd2489519674ccde55ba3693b706d09" dependencies: @@ -3733,8 +3582,8 @@ trim-right@^1.0.1: resolved "https://registry.yarnpkg.com/trim-right/-/trim-right-1.0.1.tgz#cb2e1203067e0c8de1f614094b9fe45704ea6003" ts-node@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-6.0.0.tgz#46c25f8498593a9248eeea16906f1598fa098140" + version "6.0.5" + resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-6.0.5.tgz#977c1c931da7a2b09ae2930101f0104a5c2271e9" dependencies: arrify "^1.0.0" chalk "^2.3.0" @@ -3746,8 +3595,8 @@ ts-node@^6.0.0: yn "^2.0.0" tslib@^1.8.0: - version "1.9.0" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.0.tgz#e37a86fda8cbbaf23a057f473c9f4dc64e5fc2e8" + version "1.9.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.1.tgz#a5d1f0532a49221c87755cfcc89ca37197242ba7" tunnel-agent@^0.6.0: version "0.6.0" @@ -3824,7 +3673,7 @@ util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" -uuid@^3.0.0, uuid@^3.1.0: +uuid@^3.1.0: version "3.2.1" resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.2.1.tgz#12c528bb9d58d0b9265d9a2f6f0fe8be17ff1f14" @@ -3857,7 +3706,7 @@ w3c-hr-time@^1.0.1: dependencies: browser-process-hrtime "^0.1.2" -webidl-conversions@^4.0.1, webidl-conversions@^4.0.2: +webidl-conversions@^4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" @@ -3871,29 +3720,29 @@ whatwg-mimetype@^2.0.0, whatwg-mimetype@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/whatwg-mimetype/-/whatwg-mimetype-2.1.0.tgz#f0f21d76cbba72362eb609dbed2a30cd17fcc7d4" -whatwg-url@^6.4.0: - version "6.4.0" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.4.0.tgz#08fdf2b9e872783a7a1f6216260a1d66cc722e08" +whatwg-url@^6.4.0, whatwg-url@^6.4.1: + version "6.4.1" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-6.4.1.tgz#fdb94b440fd4ad836202c16e9737d511f012fd67" dependencies: lodash.sortby "^4.7.0" - tr46 "^1.0.0" - webidl-conversions "^4.0.1" + tr46 "^1.0.1" + webidl-conversions "^4.0.2" which-module@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz#d9ef07dce77b9902b8a3a8fa4b31c3e3f7e6e87a" which@^1.2.9, which@^1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/which/-/which-1.3.0.tgz#ff04bdfc010ee547d780bec38e1ac1c2777d253a" + version "1.3.1" + resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a" dependencies: isexe "^2.0.0" wide-align@^1.1.0: - version "1.1.2" - resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.2.tgz#571e0f1b0604636ebc0dfc21b0339bbe31341710" + version "1.1.3" + resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.3.tgz#ae074e6bdc0c14a431e804e624549c633b000457" dependencies: - string-width "^1.0.2" + string-width "^1.0.2 || 2" window-size@0.1.0: version "0.1.0"