You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
svelte/test/js/samples/inline-style-optimized-url/expected.js

54 lines
1002 B

5 years ago
/* generated by Svelte vX.Y.Z */
6 years ago
import {
SvelteComponent,
6 years ago
detach,
element,
init,
insert,
noop,
safe_not_equal,
set_style
} from "svelte/internal";
function create_fragment(ctx) {
let div;
return {
7 years ago
c() {
6 years ago
div = element("div");
set_style(div, "background", "url(data:image/png;base64," + /*data*/ ctx[0] + ")");
},
7 years ago
m(target, anchor) {
insert(target, div, anchor);
},
p(ctx, [dirty]) {
if (dirty & /*data*/ 1) {
set_style(div, "background", "url(data:image/png;base64," + /*data*/ ctx[0] + ")");
}
},
i: noop,
o: noop,
6 years ago
d(detaching) {
if (detaching) detach(div);
7 years ago
}
};
}
function instance($$self, $$props, $$invalidate) {
let { data } = $$props;
$$self.$$set = $$props => {
if ("data" in $$props) $$invalidate(0, data = $$props.data);
};
return [data];
}
class Component extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance, create_fragment, safe_not_equal, { data: 0 });
}
}
export default Component;