update tests

pull/1899/head
Rich Harris 7 years ago
parent 1c4e60f38e
commit fda9147cca

@ -43,32 +43,32 @@ function foo(node, callback) {
// code goes here
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { bar } = $$props;
function foo_function() {
return handleFoo(bar);
}
$$self.$$.get = () => ({ bar, foo_function });
$$self.$$.set = $$props => {
if ('bar' in $$props) bar = $$props.bar;
};
return { bar, foo_function };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get bar() {
return this.$$.get().bar;
return this.$$.ctx.bar;
}
set bar(value) {
this.$set({ bar: value });
set bar(bar) {
this.$set({ bar });
flush();
}
}

@ -54,7 +54,7 @@ function link(node) {
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -36,45 +36,45 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let { w, h } = $$props;
function div_resize_handler() {
w = this.offsetWidth;
h = this.offsetHeight;
$$make_dirty('w');
$$make_dirty('h');
$$invalidate('w', w);
$$invalidate('h', h);
}
$$self.$$.get = () => ({ w, h, div_resize_handler });
$$self.$$.set = $$props => {
if ('w' in $$props) w = $$props.w;
if ('h' in $$props) h = $$props.h;
};
return { w, h, div_resize_handler };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get w() {
return this.$$.get().w;
return this.$$.ctx.w;
}
set w(value) {
this.$set({ w: value });
set w(w) {
this.$set({ w });
flush();
}
get h() {
return this.$$.get().h;
return this.$$.ctx.h;
}
set h(value) {
this.$set({ h: value });
set h(h) {
this.$set({ h });
flush();
}
}

@ -45,29 +45,29 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { foo = 42 } = $$props;
$$self.$$.get = () => ({ foo });
$$self.$$.set = $$props => {
if ('foo' in $$props) foo = $$props.foo;
};
return { foo };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
if (!document.getElementById("svelte-1a7i8ec-style")) add_css();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
}

@ -36,16 +36,16 @@ function create_fragment(component, ctx) {
};
}
function define($$self) {
function instance($$self) {
const Nested = window.Nested;
$$self.$$.get = () => ({ Nested });
return { Nested };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
}

@ -36,16 +36,16 @@ function create_fragment(component, ctx) {
};
}
function define($$self) {
function instance($$self) {
const Nested = window.Nested;
$$self.$$.get = () => ({ Nested });
return { Nested };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, not_equal);
init(this, options, instance, create_fragment, not_equal);
}
}

@ -36,16 +36,16 @@ function create_fragment(component, ctx) {
};
}
function define($$self) {
function instance($$self) {
const Nested = window.Nested;
$$self.$$.get = () => ({ Nested });
return { Nested };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, not_equal);
init(this, options, instance, create_fragment, not_equal);
}
}

@ -36,16 +36,16 @@ function create_fragment(component, ctx) {
};
}
function define($$self) {
function instance($$self) {
const Nested = window.Nested;
$$self.$$.get = () => ({ Nested });
return { Nested };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
}

@ -14,7 +14,7 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { x } = $$props;
function a() {
@ -25,34 +25,34 @@ function define($$self, $$props) {
return x * 3;
}
$$self.$$.get = () => ({ x, a, b });
$$self.$$.set = $$props => {
if ('x' in $$props) x = $$props.x;
};
return { x, a, b };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get x() {
return this.$$.get().x;
return this.$$.ctx.x;
}
set x(value) {
this.$set({ x: value });
set x(x) {
this.$set({ x });
flush();
}
get a() {
return this.$$.get().a;
return this.$$.ctx.a;
}
get b() {
return this.$$.get().b;
return this.$$.ctx.b;
}
}

@ -43,7 +43,7 @@ class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
if (!document.getElementById("svelte-1slhpfn-style")) add_css();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -39,7 +39,7 @@ class SvelteComponent extends SvelteElement {
this.shadowRoot.innerHTML = `<style>div{animation:foo 1s}@keyframes foo{0%{opacity:0}100%{opacity:1}}</style>`;
init(this, { target: this.shadowRoot }, noop, create_fragment, safe_not_equal);
init(this, { target: this.shadowRoot }, props => props, create_fragment, safe_not_equal);
if (options) {
if (options.target) {

@ -54,33 +54,33 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { name } = $$props;
$$self.$$.get = () => ({ name });
$$self.$$.set = $$props => {
if ('name' in $$props) name = $$props.name;
};
return { name };
}
class SvelteComponent extends SvelteComponentDev {
constructor(options) {
super(options);
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
const state = this.$$.get();
if (state.name === undefined) {
const { ctx } = this.$$;
if (ctx.name === undefined) {
console.warn("<SvelteComponent> was created without expected data property 'name'");
}
}
get name() {
return this.$$.get().name;
return this.$$.ctx.name;
}
set name(value) {
this.$set({ name: value });
set name(name) {
this.$set({ name });
flush();
}
}

@ -139,72 +139,72 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { things, foo, bar, baz } = $$props;
$$self.$$.get = () => ({ things, foo, bar, baz });
$$self.$$.set = $$props => {
if ('things' in $$props) things = $$props.things;
if ('foo' in $$props) foo = $$props.foo;
if ('bar' in $$props) bar = $$props.bar;
if ('baz' in $$props) baz = $$props.baz;
};
return { things, foo, bar, baz };
}
class SvelteComponent extends SvelteComponentDev {
constructor(options) {
super(options);
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
const state = this.$$.get();
if (state.things === undefined) {
const { ctx } = this.$$;
if (ctx.things === undefined) {
console.warn("<SvelteComponent> was created without expected data property 'things'");
}
if (state.foo === undefined) {
if (ctx.foo === undefined) {
console.warn("<SvelteComponent> was created without expected data property 'foo'");
}
if (state.bar === undefined) {
if (ctx.bar === undefined) {
console.warn("<SvelteComponent> was created without expected data property 'bar'");
}
if (state.baz === undefined) {
if (ctx.baz === undefined) {
console.warn("<SvelteComponent> was created without expected data property 'baz'");
}
}
get things() {
return this.$$.get().things;
return this.$$.ctx.things;
}
set things(value) {
this.$set({ things: value });
set things(things) {
this.$set({ things });
flush();
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
get bar() {
return this.$$.get().bar;
return this.$$.ctx.bar;
}
set bar(value) {
this.$set({ bar: value });
set bar(bar) {
this.$set({ bar });
flush();
}
get baz() {
return this.$$.get().baz;
return this.$$.ctx.baz;
}
set baz(value) {
this.$set({ baz: value });
set baz(baz) {
this.$set({ baz });
flush();
}
}

@ -139,46 +139,46 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { things, foo } = $$props;
$$self.$$.get = () => ({ things, foo });
$$self.$$.set = $$props => {
if ('things' in $$props) things = $$props.things;
if ('foo' in $$props) foo = $$props.foo;
};
return { things, foo };
}
class SvelteComponent extends SvelteComponentDev {
constructor(options) {
super(options);
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
const state = this.$$.get();
if (state.things === undefined) {
const { ctx } = this.$$;
if (ctx.things === undefined) {
console.warn("<SvelteComponent> was created without expected data property 'things'");
}
if (state.foo === undefined) {
if (ctx.foo === undefined) {
console.warn("<SvelteComponent> was created without expected data property 'foo'");
}
}
get things() {
return this.$$.get().things;
return this.$$.ctx.things;
}
set things(value) {
this.$set({ things: value });
set things(things) {
this.$set({ things });
flush();
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
}

@ -105,28 +105,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { createElement } = $$props;
$$self.$$.get = () => ({ createElement });
$$self.$$.set = $$props => {
if ('createElement' in $$props) createElement = $$props.createElement;
};
return { createElement };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get createElement() {
return this.$$.get().createElement;
return this.$$.ctx.createElement;
}
set createElement(value) {
this.$set({ createElement: value });
set createElement(createElement) {
this.$set({ createElement });
flush();
}
}

@ -15,32 +15,32 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { foo = 'bar' } = $$props;
onMount(() => {
alert(JSON.stringify(data()));
});
$$self.$$.get = () => ({ foo });
$$self.$$.set = $$props => {
if ('foo' in $$props) foo = $$props.foo;
};
return { foo };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
}

@ -52,41 +52,41 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let { foo } = $$props;
let bar;
$$self.$$.get = () => ({ foo, bar });
$$self.$$.set = $$props => {
if ('foo' in $$props) foo = $$props.foo;
};
$$self.$$.update = ($$dirty = { foo: 1 }) => {
if ($$dirty.foo) {
bar = foo * 2; $$make_dirty('bar');
bar = foo * 2; $$invalidate('bar', bar);
}
};
return { foo, bar };
}
class SvelteComponent extends SvelteComponentDev {
constructor(options) {
super(options);
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
const state = this.$$.get();
if (state.foo === undefined) {
const { ctx } = this.$$;
if (ctx.foo === undefined) {
console.warn("<SvelteComponent> was created without expected data property 'foo'");
}
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
}

@ -43,28 +43,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { bar } = $$props;
$$self.$$.get = () => ({ bar });
$$self.$$.set = $$props => {
if ('bar' in $$props) bar = $$props.bar;
};
return { bar };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get bar() {
return this.$$.get().bar;
return this.$$.ctx.bar;
}
set bar(value) {
this.$set({ bar: value });
set bar(bar) {
this.$set({ bar });
flush();
}
}

@ -43,28 +43,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { bar } = $$props;
$$self.$$.get = () => ({ bar });
$$self.$$.set = $$props => {
if ('bar' in $$props) bar = $$props.bar;
};
return { bar };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get bar() {
return this.$$.get().bar;
return this.$$.ctx.bar;
}
set bar(value) {
this.$set({ bar: value });
set bar(bar) {
this.$set({ bar });
flush();
}
}

@ -41,28 +41,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { bar } = $$props;
$$self.$$.get = () => ({ bar });
$$self.$$.set = $$props => {
if ('bar' in $$props) bar = $$props.bar;
};
return { bar };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get bar() {
return this.$$.get().bar;
return this.$$.ctx.bar;
}
set bar(value) {
this.$set({ bar: value });
set bar(bar) {
this.$set({ bar });
flush();
}
}

@ -44,7 +44,7 @@ function func() {
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -145,58 +145,58 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { comments, elapsed, time, foo } = $$props;
$$self.$$.get = () => ({ comments, elapsed, time, foo });
$$self.$$.set = $$props => {
if ('comments' in $$props) comments = $$props.comments;
if ('elapsed' in $$props) elapsed = $$props.elapsed;
if ('time' in $$props) time = $$props.time;
if ('foo' in $$props) foo = $$props.foo;
};
return { comments, elapsed, time, foo };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get comments() {
return this.$$.get().comments;
return this.$$.ctx.comments;
}
set comments(value) {
this.$set({ comments: value });
set comments(comments) {
this.$set({ comments });
flush();
}
get elapsed() {
return this.$$.get().elapsed;
return this.$$.ctx.elapsed;
}
set elapsed(value) {
this.$set({ elapsed: value });
set elapsed(elapsed) {
this.$set({ elapsed });
flush();
}
get time() {
return this.$$.get().time;
return this.$$.ctx.time;
}
set time(value) {
this.$set({ time: value });
set time(time) {
this.$set({ time });
flush();
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
}

@ -120,28 +120,28 @@ function foo(node, animation, params) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { things } = $$props;
$$self.$$.get = () => ({ things });
$$self.$$.set = $$props => {
if ('things' in $$props) things = $$props.things;
};
return { things };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get things() {
return this.$$.get().things;
return this.$$.ctx.things;
}
set things(value) {
this.$set({ things: value });
set things(things) {
this.$set({ things });
flush();
}
}

@ -90,28 +90,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { things } = $$props;
$$self.$$.get = () => ({ things });
$$self.$$.set = $$props => {
if ('things' in $$props) things = $$props.things;
};
return { things };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get things() {
return this.$$.get().things;
return this.$$.ctx.things;
}
set things(value) {
this.$set({ things: value });
set things(things) {
this.$set({ things });
flush();
}
}

@ -63,7 +63,7 @@ function handleClick() {
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -39,7 +39,7 @@ function create_fragment(component, ctx) {
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -40,7 +40,7 @@ function get_answer() { return ANSWER; }
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -93,28 +93,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { foo } = $$props;
$$self.$$.get = () => ({ foo });
$$self.$$.set = $$props => {
if ('foo' in $$props) foo = $$props.foo;
};
return { foo };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
}

@ -69,28 +69,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { foo } = $$props;
$$self.$$.get = () => ({ foo });
$$self.$$.set = $$props => {
if ('foo' in $$props) foo = $$props.foo;
};
return { foo };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
}

@ -41,48 +41,48 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { color, x, y } = $$props;
$$self.$$.get = () => ({ color, x, y });
$$self.$$.set = $$props => {
if ('color' in $$props) color = $$props.color;
if ('x' in $$props) x = $$props.x;
if ('y' in $$props) y = $$props.y;
};
return { color, x, y };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get color() {
return this.$$.get().color;
return this.$$.ctx.color;
}
set color(value) {
this.$set({ color: value });
set color(color) {
this.$set({ color });
flush();
}
get x() {
return this.$$.get().x;
return this.$$.ctx.x;
}
set x(value) {
this.$set({ x: value });
set x(x) {
this.$set({ x });
flush();
}
get y() {
return this.$$.get().y;
return this.$$.ctx.y;
}
set y(value) {
this.$set({ y: value });
set y(y) {
this.$set({ y });
flush();
}
}

@ -36,28 +36,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { data } = $$props;
$$self.$$.get = () => ({ data });
$$self.$$.set = $$props => {
if ('data' in $$props) data = $$props.data;
};
return { data };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get data() {
return this.$$.get().data;
return this.$$.ctx.data;
}
set data(value) {
this.$set({ data: value });
set data(data) {
this.$set({ data });
flush();
}
}

@ -36,28 +36,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { color } = $$props;
$$self.$$.get = () => ({ color });
$$self.$$.set = $$props => {
if ('color' in $$props) color = $$props.color;
};
return { color };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get color() {
return this.$$.get().color;
return this.$$.ctx.color;
}
set color(value) {
this.$set({ color: value });
set color(color) {
this.$set({ color });
flush();
}
}

@ -47,48 +47,48 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { style, key, value } = $$props;
$$self.$$.get = () => ({ style, key, value });
$$self.$$.set = $$props => {
if ('style' in $$props) style = $$props.style;
if ('key' in $$props) key = $$props.key;
if ('value' in $$props) value = $$props.value;
};
return { style, key, value };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get style() {
return this.$$.get().style;
return this.$$.ctx.style;
}
set style(value) {
this.$set({ style: value });
set style(style) {
this.$set({ style });
flush();
}
get key() {
return this.$$.get().key;
return this.$$.ctx.key;
}
set key(value) {
this.$set({ key: value });
set key(key) {
this.$set({ key });
flush();
}
get value() {
return this.$$.get().value;
return this.$$.ctx.value;
}
set value(value) {
this.$set({ value: value });
this.$set({ value });
flush();
}
}

@ -41,33 +41,33 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let { files } = $$props;
function input_input_handler() {
files = this.files;
$$make_dirty('files');
$$invalidate('files', files);
}
$$self.$$.get = () => ({ files, input_input_handler });
$$self.$$.set = $$props => {
if ('files' in $$props) files = $$props.files;
};
return { files, input_input_handler };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get files() {
return this.$$.get().files;
return this.$$.ctx.files;
}
set files(value) {
this.$set({ files: value });
set files(files) {
this.$set({ files });
flush();
}
}

@ -44,33 +44,33 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let { value } = $$props;
function input_change_input_handler() {
value = toNumber(this.value);
$$make_dirty('value');
$$invalidate('value', value);
}
$$self.$$.get = () => ({ value, input_change_input_handler });
$$self.$$.set = $$props => {
if ('value' in $$props) value = $$props.value;
};
return { value, input_change_input_handler };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get value() {
return this.$$.get().value;
return this.$$.ctx.value;
}
set value(value) {
this.$set({ value: value });
this.$set({ value });
flush();
}
}

@ -40,33 +40,33 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let { foo } = $$props;
function input_change_handler() {
foo = this.checked;
$$make_dirty('foo');
$$invalidate('foo', foo);
}
$$self.$$.get = () => ({ foo, input_change_handler });
$$self.$$.set = $$props => {
if ('foo' in $$props) foo = $$props.foo;
};
return { foo, input_change_handler };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get foo() {
return this.$$.get().foo;
return this.$$.ctx.foo;
}
set foo(value) {
this.$set({ foo: value });
set foo(foo) {
this.$set({ foo });
flush();
}
}

@ -49,20 +49,20 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let x = 0;
function foo() {
if (true) { x += 1; $$make_dirty('x'); }
if (true) { x += 1; $$invalidate('x', x); }
}
$$self.$$.get = () => ({ x, foo });
return { x, foo };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
}

@ -49,21 +49,21 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let things = [];
function foo() {
things.push(1);
$$make_dirty('things');
$$invalidate('things', things);
}
$$self.$$.get = () => ({ things, foo });
return { things, foo };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
}

@ -49,20 +49,20 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let x = 0;
function click_handler() {
if (true) { x += 1; $$make_dirty('x'); }
if (true) { x += 1; $$invalidate('x', x); }
}
$$self.$$.get = () => ({ x, click_handler });
return { x, click_handler };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
}

@ -49,18 +49,18 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let things = [];
function click_handler() { things.push(1); $$make_dirty('things') }
function click_handler() { things.push(1); $$invalidate('things', things) }
$$self.$$.get = () => ({ things, click_handler });
return { things, click_handler };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
}

@ -35,7 +35,7 @@ function create_fragment(component, ctx) {
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -54,7 +54,7 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let { buffered, seekable, played, currentTime, duration, paused, volume } = $$props;
function audio_timeupdate_handler() {
@ -62,38 +62,48 @@ function define($$self, $$props, $$make_dirty) {
if (!audio.paused) audio_animationframe = requestAnimationFrame(audio_timeupdate_handler);
played = timeRangesToArray(this.played);
currentTime = this.currentTime;
$$make_dirty('played');
$$make_dirty('currentTime');
$$invalidate('played', played);
$$invalidate('currentTime', currentTime);
}
function audio_durationchange_handler() {
duration = this.duration;
$$make_dirty('duration');
$$invalidate('duration', duration);
}
function audio_play_pause_handler() {
paused = this.paused;
$$make_dirty('paused');
$$invalidate('paused', paused);
}
function audio_progress_handler() {
buffered = timeRangesToArray(this.buffered);
$$make_dirty('buffered');
$$invalidate('buffered', buffered);
}
function audio_loadedmetadata_handler() {
buffered = timeRangesToArray(this.buffered);
seekable = timeRangesToArray(this.seekable);
$$make_dirty('buffered');
$$make_dirty('seekable');
$$invalidate('buffered', buffered);
$$invalidate('seekable', seekable);
}
function audio_volumechange_handler() {
volume = this.volume;
$$make_dirty('volume');
$$invalidate('volume', volume);
}
$$self.$$.get = () => ({
$$self.$$.set = $$props => {
if ('buffered' in $$props) buffered = $$props.buffered;
if ('seekable' in $$props) seekable = $$props.seekable;
if ('played' in $$props) played = $$props.played;
if ('currentTime' in $$props) currentTime = $$props.currentTime;
if ('duration' in $$props) duration = $$props.duration;
if ('paused' in $$props) paused = $$props.paused;
if ('volume' in $$props) volume = $$props.volume;
};
return {
buffered,
seekable,
played,
@ -107,85 +117,75 @@ function define($$self, $$props, $$make_dirty) {
audio_progress_handler,
audio_loadedmetadata_handler,
audio_volumechange_handler
});
$$self.$$.set = $$props => {
if ('buffered' in $$props) buffered = $$props.buffered;
if ('seekable' in $$props) seekable = $$props.seekable;
if ('played' in $$props) played = $$props.played;
if ('currentTime' in $$props) currentTime = $$props.currentTime;
if ('duration' in $$props) duration = $$props.duration;
if ('paused' in $$props) paused = $$props.paused;
if ('volume' in $$props) volume = $$props.volume;
};
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get buffered() {
return this.$$.get().buffered;
return this.$$.ctx.buffered;
}
set buffered(value) {
this.$set({ buffered: value });
set buffered(buffered) {
this.$set({ buffered });
flush();
}
get seekable() {
return this.$$.get().seekable;
return this.$$.ctx.seekable;
}
set seekable(value) {
this.$set({ seekable: value });
set seekable(seekable) {
this.$set({ seekable });
flush();
}
get played() {
return this.$$.get().played;
return this.$$.ctx.played;
}
set played(value) {
this.$set({ played: value });
set played(played) {
this.$set({ played });
flush();
}
get currentTime() {
return this.$$.get().currentTime;
return this.$$.ctx.currentTime;
}
set currentTime(value) {
this.$set({ currentTime: value });
set currentTime(currentTime) {
this.$set({ currentTime });
flush();
}
get duration() {
return this.$$.get().duration;
return this.$$.ctx.duration;
}
set duration(value) {
this.$set({ duration: value });
set duration(duration) {
this.$set({ duration });
flush();
}
get paused() {
return this.$$.get().paused;
return this.$$.ctx.paused;
}
set paused(value) {
this.$set({ paused: value });
set paused(paused) {
this.$set({ paused });
flush();
}
get volume() {
return this.$$.get().volume;
return this.$$.ctx.volume;
}
set volume(value) {
this.$set({ volume: value });
set volume(volume) {
this.$set({ volume });
flush();
}
}

@ -55,7 +55,7 @@ function create_fragment(component, ctx) {
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -63,28 +63,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { current } = $$props;
$$self.$$.get = () => ({ current });
$$self.$$.set = $$props => {
if ('current' in $$props) current = $$props.current;
};
return { current };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get current() {
return this.$$.get().current;
return this.$$.ctx.current;
}
set current(value) {
this.$set({ current: value });
set current(current) {
this.$set({ current });
flush();
}
}

@ -23,7 +23,7 @@ function foo(bar) {
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
get foo() {

@ -38,7 +38,7 @@ function create_fragment(component, ctx) {
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, noop, create_fragment, safe_not_equal);
init(this, options, props => props, create_fragment, safe_not_equal);
}
}

@ -22,28 +22,28 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { custom } = $$props;
$$self.$$.get = () => ({ custom });
$$self.$$.set = $$props => {
if ('custom' in $$props) custom = $$props.custom;
};
return { custom };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get custom() {
return this.$$.get().custom;
return this.$$.ctx.custom;
}
set custom(value) {
this.$set({ custom: value });
set custom(custom) {
this.$set({ custom });
flush();
}
}

@ -249,11 +249,9 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props) {
function instance($$self, $$props) {
let { a, b, c, d, e } = $$props;
$$self.$$.get = () => ({ a, b, c, d, e });
$$self.$$.set = $$props => {
if ('a' in $$props) a = $$props.a;
if ('b' in $$props) b = $$props.b;
@ -261,56 +259,58 @@ function define($$self, $$props) {
if ('d' in $$props) d = $$props.d;
if ('e' in $$props) e = $$props.e;
};
return { a, b, c, d, e };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get a() {
return this.$$.get().a;
return this.$$.ctx.a;
}
set a(value) {
this.$set({ a: value });
set a(a) {
this.$set({ a });
flush();
}
get b() {
return this.$$.get().b;
return this.$$.ctx.b;
}
set b(value) {
this.$set({ b: value });
set b(b) {
this.$set({ b });
flush();
}
get c() {
return this.$$.get().c;
return this.$$.ctx.c;
}
set c(value) {
this.$set({ c: value });
set c(c) {
this.$set({ c });
flush();
}
get d() {
return this.$$.get().d;
return this.$$.ctx.d;
}
set d(value) {
this.$set({ d: value });
set d(d) {
this.$set({ d });
flush();
}
get e() {
return this.$$.get().e;
return this.$$.ctx.e;
}
set e(value) {
this.$set({ e: value });
set e(e) {
this.$set({ e });
flush();
}
}

@ -56,32 +56,32 @@ function create_fragment(component, ctx) {
};
}
function define($$self, $$props, $$make_dirty) {
function instance($$self, $$props, $$invalidate) {
let { y } = $$props;
function onwindowscroll() {
y = window.pageYOffset; $$make_dirty('y');
y = window.pageYOffset; $$invalidate('y', y);
}
$$self.$$.get = () => ({ y, onwindowscroll });
$$self.$$.set = $$props => {
if ('y' in $$props) y = $$props.y;
};
return { y, onwindowscroll };
}
class SvelteComponent extends SvelteComponent_1 {
constructor(options) {
super();
init(this, options, define, create_fragment, safe_not_equal);
init(this, options, instance, create_fragment, safe_not_equal);
}
get y() {
return this.$$.get().y;
return this.$$.ctx.y;
}
set y(value) {
this.$set({ y: value });
set y(y) {
this.$set({ y });
flush();
}
}

Loading…
Cancel
Save