w3ps1/_app/immutable/components/pages/_page.svelte-9e94ee1d.js
2023-02-12 17:45:00 +00:00

9092 lines
245 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { o as onMount, S as SvelteComponent, i as init, s as safe_not_equal, e as empty, b as insert_hydration, g as group_outros, t as transition_out, d as check_outros, f as transition_in, h as detach, O as compute_rest_props, P as assign, Q as exclude_internal_props, M as destroy_each, x as create_component, y as claim_component, z as mount_component, R as get_spread_update, T as get_spread_object, A as destroy_component, w as construct_svelte_component, a as space, c as claim_space, q as text, r as claim_text, u as set_data, C as noop, U as getContext, D as create_slot, k as element, l as claim_element, m as children, n as attr, J as update_slot_base, K as get_all_dirty_from_scope, L as get_slot_changes, G as src_url_equal, H as append_hydration, V as HtmlTagHydration, W as claim_html_tag, X as createEventDispatcher, Y as setContext, Z as head_selector } from "../../chunks/index-744c867d.js";
function supressWarnings() {
const origWarn = console.warn;
console.warn = (message) => {
if (message.includes("unknown prop"))
return;
if (message.includes("unexpected slot"))
return;
origWarn(message);
};
onMount(() => {
console.warn = origWarn;
});
}
function get_each_context_5(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[18] = list[i];
return child_ctx;
}
function get_each_context_4$1(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[18] = list[i];
return child_ctx;
}
function get_each_context_1$1(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[10] = list[i];
return child_ctx;
}
function get_each_context_2$1(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[13] = list[i];
child_ctx[15] = i;
return child_ctx;
}
function get_each_context_3$1(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[16] = list[i];
child_ctx[15] = i;
return child_ctx;
}
function get_each_context$2(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[7] = list[i];
return child_ctx;
}
function create_if_block_1$2(ctx) {
let current_block_type_index;
let if_block;
let if_block_anchor;
let current;
const if_block_creators = [create_if_block_2$1, create_if_block_3$1, create_else_block_1];
const if_blocks = [];
function select_block_type_1(ctx2, dirty) {
if (
/*type*/
ctx2[0] === "table"
)
return 0;
if (
/*type*/
ctx2[0] === "list"
)
return 1;
return 2;
}
current_block_type_index = select_block_type_1(ctx);
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx);
return {
c() {
if_block.c();
if_block_anchor = empty();
},
l(nodes) {
if_block.l(nodes);
if_block_anchor = empty();
},
m(target, anchor) {
if_blocks[current_block_type_index].m(target, anchor);
insert_hydration(target, if_block_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
let previous_block_index = current_block_type_index;
current_block_type_index = select_block_type_1(ctx2);
if (current_block_type_index === previous_block_index) {
if_blocks[current_block_type_index].p(ctx2, dirty);
} else {
group_outros();
transition_out(if_blocks[previous_block_index], 1, 1, () => {
if_blocks[previous_block_index] = null;
});
check_outros();
if_block = if_blocks[current_block_type_index];
if (!if_block) {
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx2);
if_block.c();
} else {
if_block.p(ctx2, dirty);
}
transition_in(if_block, 1);
if_block.m(if_block_anchor.parentNode, if_block_anchor);
}
},
i(local) {
if (current)
return;
transition_in(if_block);
current = true;
},
o(local) {
transition_out(if_block);
current = false;
},
d(detaching) {
if_blocks[current_block_type_index].d(detaching);
if (detaching)
detach(if_block_anchor);
}
};
}
function create_if_block$4(ctx) {
let each_1_anchor;
let current;
let each_value = (
/*tokens*/
ctx[1]
);
let each_blocks = [];
for (let i = 0; i < each_value.length; i += 1) {
each_blocks[i] = create_each_block$2(get_each_context$2(ctx, each_value, i));
}
const out = (i) => transition_out(each_blocks[i], 1, 1, () => {
each_blocks[i] = null;
});
return {
c() {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
each_1_anchor = empty();
},
l(nodes) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(nodes);
}
each_1_anchor = empty();
},
m(target, anchor) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(target, anchor);
}
insert_hydration(target, each_1_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
if (dirty & /*tokens, renderers*/
34) {
each_value = /*tokens*/
ctx2[1];
let i;
for (i = 0; i < each_value.length; i += 1) {
const child_ctx = get_each_context$2(ctx2, each_value, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
transition_in(each_blocks[i], 1);
} else {
each_blocks[i] = create_each_block$2(child_ctx);
each_blocks[i].c();
transition_in(each_blocks[i], 1);
each_blocks[i].m(each_1_anchor.parentNode, each_1_anchor);
}
}
group_outros();
for (i = each_value.length; i < each_blocks.length; i += 1) {
out(i);
}
check_outros();
}
},
i(local) {
if (current)
return;
for (let i = 0; i < each_value.length; i += 1) {
transition_in(each_blocks[i]);
}
current = true;
},
o(local) {
each_blocks = each_blocks.filter(Boolean);
for (let i = 0; i < each_blocks.length; i += 1) {
transition_out(each_blocks[i]);
}
current = false;
},
d(detaching) {
destroy_each(each_blocks, detaching);
if (detaching)
detach(each_1_anchor);
}
};
}
function create_else_block_1(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
const switch_instance_spread_levels = [
/*$$restProps*/
ctx[6]
];
var switch_value = (
/*renderers*/
ctx[5][
/*type*/
ctx[0]
]
);
function switch_props(ctx2) {
let switch_instance_props = {
$$slots: { default: [create_default_slot_11] },
$$scope: { ctx: ctx2 }
};
for (let i = 0; i < switch_instance_spread_levels.length; i += 1) {
switch_instance_props = assign(switch_instance_props, switch_instance_spread_levels[i]);
}
return { props: switch_instance_props };
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = dirty & /*$$restProps*/
64 ? get_spread_update(switch_instance_spread_levels, [get_spread_object(
/*$$restProps*/
ctx2[6]
)]) : {};
if (dirty & /*$$scope, tokens, renderers, $$restProps*/
8388706) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5][
/*type*/
ctx2[0]
])) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_if_block_3$1(ctx) {
let current_block_type_index;
let if_block;
let if_block_anchor;
let current;
const if_block_creators = [create_if_block_4$1, create_else_block$3];
const if_blocks = [];
function select_block_type_2(ctx2, dirty) {
if (
/*ordered*/
ctx2[4]
)
return 0;
return 1;
}
current_block_type_index = select_block_type_2(ctx);
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx);
return {
c() {
if_block.c();
if_block_anchor = empty();
},
l(nodes) {
if_block.l(nodes);
if_block_anchor = empty();
},
m(target, anchor) {
if_blocks[current_block_type_index].m(target, anchor);
insert_hydration(target, if_block_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
let previous_block_index = current_block_type_index;
current_block_type_index = select_block_type_2(ctx2);
if (current_block_type_index === previous_block_index) {
if_blocks[current_block_type_index].p(ctx2, dirty);
} else {
group_outros();
transition_out(if_blocks[previous_block_index], 1, 1, () => {
if_blocks[previous_block_index] = null;
});
check_outros();
if_block = if_blocks[current_block_type_index];
if (!if_block) {
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx2);
if_block.c();
} else {
if_block.p(ctx2, dirty);
}
transition_in(if_block, 1);
if_block.m(if_block_anchor.parentNode, if_block_anchor);
}
},
i(local) {
if (current)
return;
transition_in(if_block);
current = true;
},
o(local) {
transition_out(if_block);
current = false;
},
d(detaching) {
if_blocks[current_block_type_index].d(detaching);
if (detaching)
detach(if_block_anchor);
}
};
}
function create_if_block_2$1(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
var switch_value = (
/*renderers*/
ctx[5].table
);
function switch_props(ctx2) {
return {
props: {
$$slots: { default: [create_default_slot] },
$$scope: { ctx: ctx2 }
}
};
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = {};
if (dirty & /*$$scope, renderers, rows, $$restProps, header*/
8388716) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].table)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_else_block_2(ctx) {
let t_value = (
/*$$restProps*/
ctx[6].raw + ""
);
let t;
return {
c() {
t = text(t_value);
},
l(nodes) {
t = claim_text(nodes, t_value);
},
m(target, anchor) {
insert_hydration(target, t, anchor);
},
p(ctx2, dirty) {
if (dirty & /*$$restProps*/
64 && t_value !== (t_value = /*$$restProps*/
ctx2[6].raw + ""))
set_data(t, t_value);
},
i: noop,
o: noop,
d(detaching) {
if (detaching)
detach(t);
}
};
}
function create_if_block_5$1(ctx) {
let parser;
let current;
parser = new Parser$1({
props: {
tokens: (
/*tokens*/
ctx[1]
),
renderers: (
/*renderers*/
ctx[5]
)
}
});
return {
c() {
create_component(parser.$$.fragment);
},
l(nodes) {
claim_component(parser.$$.fragment, nodes);
},
m(target, anchor) {
mount_component(parser, target, anchor);
current = true;
},
p(ctx2, dirty) {
const parser_changes = {};
if (dirty & /*tokens*/
2)
parser_changes.tokens = /*tokens*/
ctx2[1];
if (dirty & /*renderers*/
32)
parser_changes.renderers = /*renderers*/
ctx2[5];
parser.$set(parser_changes);
},
i(local) {
if (current)
return;
transition_in(parser.$$.fragment, local);
current = true;
},
o(local) {
transition_out(parser.$$.fragment, local);
current = false;
},
d(detaching) {
destroy_component(parser, detaching);
}
};
}
function create_default_slot_11(ctx) {
let current_block_type_index;
let if_block;
let if_block_anchor;
let current;
const if_block_creators = [create_if_block_5$1, create_else_block_2];
const if_blocks = [];
function select_block_type_3(ctx2, dirty) {
if (
/*tokens*/
ctx2[1]
)
return 0;
return 1;
}
current_block_type_index = select_block_type_3(ctx);
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx);
return {
c() {
if_block.c();
if_block_anchor = empty();
},
l(nodes) {
if_block.l(nodes);
if_block_anchor = empty();
},
m(target, anchor) {
if_blocks[current_block_type_index].m(target, anchor);
insert_hydration(target, if_block_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
let previous_block_index = current_block_type_index;
current_block_type_index = select_block_type_3(ctx2);
if (current_block_type_index === previous_block_index) {
if_blocks[current_block_type_index].p(ctx2, dirty);
} else {
group_outros();
transition_out(if_blocks[previous_block_index], 1, 1, () => {
if_blocks[previous_block_index] = null;
});
check_outros();
if_block = if_blocks[current_block_type_index];
if (!if_block) {
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx2);
if_block.c();
} else {
if_block.p(ctx2, dirty);
}
transition_in(if_block, 1);
if_block.m(if_block_anchor.parentNode, if_block_anchor);
}
},
i(local) {
if (current)
return;
transition_in(if_block);
current = true;
},
o(local) {
transition_out(if_block);
current = false;
},
d(detaching) {
if_blocks[current_block_type_index].d(detaching);
if (detaching)
detach(if_block_anchor);
}
};
}
function create_else_block$3(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
const switch_instance_spread_levels = [
{ ordered: (
/*ordered*/
ctx[4]
) },
/*$$restProps*/
ctx[6]
];
var switch_value = (
/*renderers*/
ctx[5].list
);
function switch_props(ctx2) {
let switch_instance_props = {
$$slots: { default: [create_default_slot_9] },
$$scope: { ctx: ctx2 }
};
for (let i = 0; i < switch_instance_spread_levels.length; i += 1) {
switch_instance_props = assign(switch_instance_props, switch_instance_spread_levels[i]);
}
return { props: switch_instance_props };
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = dirty & /*ordered, $$restProps*/
80 ? get_spread_update(switch_instance_spread_levels, [
dirty & /*ordered*/
16 && { ordered: (
/*ordered*/
ctx2[4]
) },
dirty & /*$$restProps*/
64 && get_spread_object(
/*$$restProps*/
ctx2[6]
)
]) : {};
if (dirty & /*$$scope, $$restProps, renderers*/
8388704) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].list)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_if_block_4$1(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
const switch_instance_spread_levels = [
{ ordered: (
/*ordered*/
ctx[4]
) },
/*$$restProps*/
ctx[6]
];
var switch_value = (
/*renderers*/
ctx[5].list
);
function switch_props(ctx2) {
let switch_instance_props = {
$$slots: { default: [create_default_slot_7] },
$$scope: { ctx: ctx2 }
};
for (let i = 0; i < switch_instance_spread_levels.length; i += 1) {
switch_instance_props = assign(switch_instance_props, switch_instance_spread_levels[i]);
}
return { props: switch_instance_props };
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = dirty & /*ordered, $$restProps*/
80 ? get_spread_update(switch_instance_spread_levels, [
dirty & /*ordered*/
16 && { ordered: (
/*ordered*/
ctx2[4]
) },
dirty & /*$$restProps*/
64 && get_spread_object(
/*$$restProps*/
ctx2[6]
)
]) : {};
if (dirty & /*$$scope, $$restProps, renderers*/
8388704) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].list)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_default_slot_10(ctx) {
let parser;
let t;
let current;
parser = new Parser$1({
props: {
tokens: (
/*item*/
ctx[18].tokens
),
renderers: (
/*renderers*/
ctx[5]
)
}
});
return {
c() {
create_component(parser.$$.fragment);
t = space();
},
l(nodes) {
claim_component(parser.$$.fragment, nodes);
t = claim_space(nodes);
},
m(target, anchor) {
mount_component(parser, target, anchor);
insert_hydration(target, t, anchor);
current = true;
},
p(ctx2, dirty) {
const parser_changes = {};
if (dirty & /*$$restProps*/
64)
parser_changes.tokens = /*item*/
ctx2[18].tokens;
if (dirty & /*renderers*/
32)
parser_changes.renderers = /*renderers*/
ctx2[5];
parser.$set(parser_changes);
},
i(local) {
if (current)
return;
transition_in(parser.$$.fragment, local);
current = true;
},
o(local) {
transition_out(parser.$$.fragment, local);
current = false;
},
d(detaching) {
destroy_component(parser, detaching);
if (detaching)
detach(t);
}
};
}
function create_each_block_5(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
const switch_instance_spread_levels = [
/*item*/
ctx[18]
];
var switch_value = (
/*renderers*/
ctx[5].unorderedlistitem || /*renderers*/
ctx[5].listitem
);
function switch_props(ctx2) {
let switch_instance_props = {
$$slots: { default: [create_default_slot_10] },
$$scope: { ctx: ctx2 }
};
for (let i = 0; i < switch_instance_spread_levels.length; i += 1) {
switch_instance_props = assign(switch_instance_props, switch_instance_spread_levels[i]);
}
return { props: switch_instance_props };
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = dirty & /*$$restProps*/
64 ? get_spread_update(switch_instance_spread_levels, [get_spread_object(
/*item*/
ctx2[18]
)]) : {};
if (dirty & /*$$scope, $$restProps, renderers*/
8388704) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].unorderedlistitem || /*renderers*/
ctx2[5].listitem)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_default_slot_9(ctx) {
let each_1_anchor;
let current;
let each_value_5 = (
/*$$restProps*/
ctx[6].items
);
let each_blocks = [];
for (let i = 0; i < each_value_5.length; i += 1) {
each_blocks[i] = create_each_block_5(get_each_context_5(ctx, each_value_5, i));
}
const out = (i) => transition_out(each_blocks[i], 1, 1, () => {
each_blocks[i] = null;
});
return {
c() {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
each_1_anchor = empty();
},
l(nodes) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(nodes);
}
each_1_anchor = empty();
},
m(target, anchor) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(target, anchor);
}
insert_hydration(target, each_1_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
if (dirty & /*renderers, $$restProps*/
96) {
each_value_5 = /*$$restProps*/
ctx2[6].items;
let i;
for (i = 0; i < each_value_5.length; i += 1) {
const child_ctx = get_each_context_5(ctx2, each_value_5, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
transition_in(each_blocks[i], 1);
} else {
each_blocks[i] = create_each_block_5(child_ctx);
each_blocks[i].c();
transition_in(each_blocks[i], 1);
each_blocks[i].m(each_1_anchor.parentNode, each_1_anchor);
}
}
group_outros();
for (i = each_value_5.length; i < each_blocks.length; i += 1) {
out(i);
}
check_outros();
}
},
i(local) {
if (current)
return;
for (let i = 0; i < each_value_5.length; i += 1) {
transition_in(each_blocks[i]);
}
current = true;
},
o(local) {
each_blocks = each_blocks.filter(Boolean);
for (let i = 0; i < each_blocks.length; i += 1) {
transition_out(each_blocks[i]);
}
current = false;
},
d(detaching) {
destroy_each(each_blocks, detaching);
if (detaching)
detach(each_1_anchor);
}
};
}
function create_default_slot_8(ctx) {
let parser;
let t;
let current;
parser = new Parser$1({
props: {
tokens: (
/*item*/
ctx[18].tokens
),
renderers: (
/*renderers*/
ctx[5]
)
}
});
return {
c() {
create_component(parser.$$.fragment);
t = space();
},
l(nodes) {
claim_component(parser.$$.fragment, nodes);
t = claim_space(nodes);
},
m(target, anchor) {
mount_component(parser, target, anchor);
insert_hydration(target, t, anchor);
current = true;
},
p(ctx2, dirty) {
const parser_changes = {};
if (dirty & /*$$restProps*/
64)
parser_changes.tokens = /*item*/
ctx2[18].tokens;
if (dirty & /*renderers*/
32)
parser_changes.renderers = /*renderers*/
ctx2[5];
parser.$set(parser_changes);
},
i(local) {
if (current)
return;
transition_in(parser.$$.fragment, local);
current = true;
},
o(local) {
transition_out(parser.$$.fragment, local);
current = false;
},
d(detaching) {
destroy_component(parser, detaching);
if (detaching)
detach(t);
}
};
}
function create_each_block_4$1(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
const switch_instance_spread_levels = [
/*item*/
ctx[18]
];
var switch_value = (
/*renderers*/
ctx[5].orderedlistitem || /*renderers*/
ctx[5].listitem
);
function switch_props(ctx2) {
let switch_instance_props = {
$$slots: { default: [create_default_slot_8] },
$$scope: { ctx: ctx2 }
};
for (let i = 0; i < switch_instance_spread_levels.length; i += 1) {
switch_instance_props = assign(switch_instance_props, switch_instance_spread_levels[i]);
}
return { props: switch_instance_props };
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = dirty & /*$$restProps*/
64 ? get_spread_update(switch_instance_spread_levels, [get_spread_object(
/*item*/
ctx2[18]
)]) : {};
if (dirty & /*$$scope, $$restProps, renderers*/
8388704) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].orderedlistitem || /*renderers*/
ctx2[5].listitem)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_default_slot_7(ctx) {
let each_1_anchor;
let current;
let each_value_4 = (
/*$$restProps*/
ctx[6].items
);
let each_blocks = [];
for (let i = 0; i < each_value_4.length; i += 1) {
each_blocks[i] = create_each_block_4$1(get_each_context_4$1(ctx, each_value_4, i));
}
const out = (i) => transition_out(each_blocks[i], 1, 1, () => {
each_blocks[i] = null;
});
return {
c() {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
each_1_anchor = empty();
},
l(nodes) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(nodes);
}
each_1_anchor = empty();
},
m(target, anchor) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(target, anchor);
}
insert_hydration(target, each_1_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
if (dirty & /*renderers, $$restProps*/
96) {
each_value_4 = /*$$restProps*/
ctx2[6].items;
let i;
for (i = 0; i < each_value_4.length; i += 1) {
const child_ctx = get_each_context_4$1(ctx2, each_value_4, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
transition_in(each_blocks[i], 1);
} else {
each_blocks[i] = create_each_block_4$1(child_ctx);
each_blocks[i].c();
transition_in(each_blocks[i], 1);
each_blocks[i].m(each_1_anchor.parentNode, each_1_anchor);
}
}
group_outros();
for (i = each_value_4.length; i < each_blocks.length; i += 1) {
out(i);
}
check_outros();
}
},
i(local) {
if (current)
return;
for (let i = 0; i < each_value_4.length; i += 1) {
transition_in(each_blocks[i]);
}
current = true;
},
o(local) {
each_blocks = each_blocks.filter(Boolean);
for (let i = 0; i < each_blocks.length; i += 1) {
transition_out(each_blocks[i]);
}
current = false;
},
d(detaching) {
destroy_each(each_blocks, detaching);
if (detaching)
detach(each_1_anchor);
}
};
}
function create_default_slot_6(ctx) {
let parser;
let t;
let current;
parser = new Parser$1({
props: {
tokens: (
/*headerItem*/
ctx[16].tokens
),
renderers: (
/*renderers*/
ctx[5]
)
}
});
return {
c() {
create_component(parser.$$.fragment);
t = space();
},
l(nodes) {
claim_component(parser.$$.fragment, nodes);
t = claim_space(nodes);
},
m(target, anchor) {
mount_component(parser, target, anchor);
insert_hydration(target, t, anchor);
current = true;
},
p(ctx2, dirty) {
const parser_changes = {};
if (dirty & /*header*/
4)
parser_changes.tokens = /*headerItem*/
ctx2[16].tokens;
if (dirty & /*renderers*/
32)
parser_changes.renderers = /*renderers*/
ctx2[5];
parser.$set(parser_changes);
},
i(local) {
if (current)
return;
transition_in(parser.$$.fragment, local);
current = true;
},
o(local) {
transition_out(parser.$$.fragment, local);
current = false;
},
d(detaching) {
destroy_component(parser, detaching);
if (detaching)
detach(t);
}
};
}
function create_each_block_3$1(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
var switch_value = (
/*renderers*/
ctx[5].tablecell
);
function switch_props(ctx2) {
return {
props: {
header: true,
align: (
/*$$restProps*/
ctx2[6].align[
/*i*/
ctx2[15]
] || "center"
),
$$slots: { default: [create_default_slot_6] },
$$scope: { ctx: ctx2 }
}
};
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = {};
if (dirty & /*$$restProps*/
64)
switch_instance_changes.align = /*$$restProps*/
ctx2[6].align[
/*i*/
ctx2[15]
] || "center";
if (dirty & /*$$scope, header, renderers*/
8388644) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].tablecell)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_default_slot_5(ctx) {
let each_1_anchor;
let current;
let each_value_3 = (
/*header*/
ctx[2]
);
let each_blocks = [];
for (let i = 0; i < each_value_3.length; i += 1) {
each_blocks[i] = create_each_block_3$1(get_each_context_3$1(ctx, each_value_3, i));
}
const out = (i) => transition_out(each_blocks[i], 1, 1, () => {
each_blocks[i] = null;
});
return {
c() {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
each_1_anchor = empty();
},
l(nodes) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(nodes);
}
each_1_anchor = empty();
},
m(target, anchor) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(target, anchor);
}
insert_hydration(target, each_1_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
if (dirty & /*renderers, $$restProps, header*/
100) {
each_value_3 = /*header*/
ctx2[2];
let i;
for (i = 0; i < each_value_3.length; i += 1) {
const child_ctx = get_each_context_3$1(ctx2, each_value_3, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
transition_in(each_blocks[i], 1);
} else {
each_blocks[i] = create_each_block_3$1(child_ctx);
each_blocks[i].c();
transition_in(each_blocks[i], 1);
each_blocks[i].m(each_1_anchor.parentNode, each_1_anchor);
}
}
group_outros();
for (i = each_value_3.length; i < each_blocks.length; i += 1) {
out(i);
}
check_outros();
}
},
i(local) {
if (current)
return;
for (let i = 0; i < each_value_3.length; i += 1) {
transition_in(each_blocks[i]);
}
current = true;
},
o(local) {
each_blocks = each_blocks.filter(Boolean);
for (let i = 0; i < each_blocks.length; i += 1) {
transition_out(each_blocks[i]);
}
current = false;
},
d(detaching) {
destroy_each(each_blocks, detaching);
if (detaching)
detach(each_1_anchor);
}
};
}
function create_default_slot_4(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
var switch_value = (
/*renderers*/
ctx[5].tablerow
);
function switch_props(ctx2) {
return {
props: {
$$slots: { default: [create_default_slot_5] },
$$scope: { ctx: ctx2 }
}
};
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = {};
if (dirty & /*$$scope, header, renderers, $$restProps*/
8388708) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].tablerow)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_default_slot_3(ctx) {
let parser;
let current;
parser = new Parser$1({
props: {
tokens: (
/*cells*/
ctx[13].tokens
),
renderers: (
/*renderers*/
ctx[5]
)
}
});
return {
c() {
create_component(parser.$$.fragment);
},
l(nodes) {
claim_component(parser.$$.fragment, nodes);
},
m(target, anchor) {
mount_component(parser, target, anchor);
current = true;
},
p(ctx2, dirty) {
const parser_changes = {};
if (dirty & /*rows*/
8)
parser_changes.tokens = /*cells*/
ctx2[13].tokens;
if (dirty & /*renderers*/
32)
parser_changes.renderers = /*renderers*/
ctx2[5];
parser.$set(parser_changes);
},
i(local) {
if (current)
return;
transition_in(parser.$$.fragment, local);
current = true;
},
o(local) {
transition_out(parser.$$.fragment, local);
current = false;
},
d(detaching) {
destroy_component(parser, detaching);
}
};
}
function create_each_block_2$1(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
var switch_value = (
/*renderers*/
ctx[5].tablecell
);
function switch_props(ctx2) {
return {
props: {
header: false,
align: (
/*$$restProps*/
ctx2[6].align[
/*i*/
ctx2[15]
] || "center"
),
$$slots: { default: [create_default_slot_3] },
$$scope: { ctx: ctx2 }
}
};
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = {};
if (dirty & /*$$restProps*/
64)
switch_instance_changes.align = /*$$restProps*/
ctx2[6].align[
/*i*/
ctx2[15]
] || "center";
if (dirty & /*$$scope, rows, renderers*/
8388648) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].tablecell)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_default_slot_2(ctx) {
let t;
let current;
let each_value_2 = (
/*row*/
ctx[10]
);
let each_blocks = [];
for (let i = 0; i < each_value_2.length; i += 1) {
each_blocks[i] = create_each_block_2$1(get_each_context_2$1(ctx, each_value_2, i));
}
const out = (i) => transition_out(each_blocks[i], 1, 1, () => {
each_blocks[i] = null;
});
return {
c() {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
t = space();
},
l(nodes) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(nodes);
}
t = claim_space(nodes);
},
m(target, anchor) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(target, anchor);
}
insert_hydration(target, t, anchor);
current = true;
},
p(ctx2, dirty) {
if (dirty & /*renderers, $$restProps, rows*/
104) {
each_value_2 = /*row*/
ctx2[10];
let i;
for (i = 0; i < each_value_2.length; i += 1) {
const child_ctx = get_each_context_2$1(ctx2, each_value_2, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
transition_in(each_blocks[i], 1);
} else {
each_blocks[i] = create_each_block_2$1(child_ctx);
each_blocks[i].c();
transition_in(each_blocks[i], 1);
each_blocks[i].m(t.parentNode, t);
}
}
group_outros();
for (i = each_value_2.length; i < each_blocks.length; i += 1) {
out(i);
}
check_outros();
}
},
i(local) {
if (current)
return;
for (let i = 0; i < each_value_2.length; i += 1) {
transition_in(each_blocks[i]);
}
current = true;
},
o(local) {
each_blocks = each_blocks.filter(Boolean);
for (let i = 0; i < each_blocks.length; i += 1) {
transition_out(each_blocks[i]);
}
current = false;
},
d(detaching) {
destroy_each(each_blocks, detaching);
if (detaching)
detach(t);
}
};
}
function create_each_block_1$1(ctx) {
let switch_instance;
let switch_instance_anchor;
let current;
var switch_value = (
/*renderers*/
ctx[5].tablerow
);
function switch_props(ctx2) {
return {
props: {
$$slots: { default: [create_default_slot_2] },
$$scope: { ctx: ctx2 }
}
};
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx));
}
return {
c() {
if (switch_instance)
create_component(switch_instance.$$.fragment);
switch_instance_anchor = empty();
},
l(nodes) {
if (switch_instance)
claim_component(switch_instance.$$.fragment, nodes);
switch_instance_anchor = empty();
},
m(target, anchor) {
if (switch_instance)
mount_component(switch_instance, target, anchor);
insert_hydration(target, switch_instance_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance_changes = {};
if (dirty & /*$$scope, rows, renderers, $$restProps*/
8388712) {
switch_instance_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].tablerow)) {
if (switch_instance) {
group_outros();
const old_component = switch_instance;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance.$$.fragment);
transition_in(switch_instance.$$.fragment, 1);
mount_component(switch_instance, switch_instance_anchor.parentNode, switch_instance_anchor);
} else {
switch_instance = null;
}
} else if (switch_value) {
switch_instance.$set(switch_instance_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance)
transition_in(switch_instance.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance)
transition_out(switch_instance.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(switch_instance_anchor);
if (switch_instance)
destroy_component(switch_instance, detaching);
}
};
}
function create_default_slot_1(ctx) {
let each_1_anchor;
let current;
let each_value_1 = (
/*rows*/
ctx[3]
);
let each_blocks = [];
for (let i = 0; i < each_value_1.length; i += 1) {
each_blocks[i] = create_each_block_1$1(get_each_context_1$1(ctx, each_value_1, i));
}
const out = (i) => transition_out(each_blocks[i], 1, 1, () => {
each_blocks[i] = null;
});
return {
c() {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
each_1_anchor = empty();
},
l(nodes) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(nodes);
}
each_1_anchor = empty();
},
m(target, anchor) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(target, anchor);
}
insert_hydration(target, each_1_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
if (dirty & /*renderers, rows, $$restProps*/
104) {
each_value_1 = /*rows*/
ctx2[3];
let i;
for (i = 0; i < each_value_1.length; i += 1) {
const child_ctx = get_each_context_1$1(ctx2, each_value_1, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
transition_in(each_blocks[i], 1);
} else {
each_blocks[i] = create_each_block_1$1(child_ctx);
each_blocks[i].c();
transition_in(each_blocks[i], 1);
each_blocks[i].m(each_1_anchor.parentNode, each_1_anchor);
}
}
group_outros();
for (i = each_value_1.length; i < each_blocks.length; i += 1) {
out(i);
}
check_outros();
}
},
i(local) {
if (current)
return;
for (let i = 0; i < each_value_1.length; i += 1) {
transition_in(each_blocks[i]);
}
current = true;
},
o(local) {
each_blocks = each_blocks.filter(Boolean);
for (let i = 0; i < each_blocks.length; i += 1) {
transition_out(each_blocks[i]);
}
current = false;
},
d(detaching) {
destroy_each(each_blocks, detaching);
if (detaching)
detach(each_1_anchor);
}
};
}
function create_default_slot(ctx) {
let switch_instance0;
let t;
let switch_instance1;
let switch_instance1_anchor;
let current;
var switch_value = (
/*renderers*/
ctx[5].tablehead
);
function switch_props(ctx2) {
return {
props: {
$$slots: { default: [create_default_slot_4] },
$$scope: { ctx: ctx2 }
}
};
}
if (switch_value) {
switch_instance0 = construct_svelte_component(switch_value, switch_props(ctx));
}
var switch_value_1 = (
/*renderers*/
ctx[5].tablebody
);
function switch_props_1(ctx2) {
return {
props: {
$$slots: { default: [create_default_slot_1] },
$$scope: { ctx: ctx2 }
}
};
}
if (switch_value_1) {
switch_instance1 = construct_svelte_component(switch_value_1, switch_props_1(ctx));
}
return {
c() {
if (switch_instance0)
create_component(switch_instance0.$$.fragment);
t = space();
if (switch_instance1)
create_component(switch_instance1.$$.fragment);
switch_instance1_anchor = empty();
},
l(nodes) {
if (switch_instance0)
claim_component(switch_instance0.$$.fragment, nodes);
t = claim_space(nodes);
if (switch_instance1)
claim_component(switch_instance1.$$.fragment, nodes);
switch_instance1_anchor = empty();
},
m(target, anchor) {
if (switch_instance0)
mount_component(switch_instance0, target, anchor);
insert_hydration(target, t, anchor);
if (switch_instance1)
mount_component(switch_instance1, target, anchor);
insert_hydration(target, switch_instance1_anchor, anchor);
current = true;
},
p(ctx2, dirty) {
const switch_instance0_changes = {};
if (dirty & /*$$scope, renderers, header, $$restProps*/
8388708) {
switch_instance0_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value !== (switch_value = /*renderers*/
ctx2[5].tablehead)) {
if (switch_instance0) {
group_outros();
const old_component = switch_instance0;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value) {
switch_instance0 = construct_svelte_component(switch_value, switch_props(ctx2));
create_component(switch_instance0.$$.fragment);
transition_in(switch_instance0.$$.fragment, 1);
mount_component(switch_instance0, t.parentNode, t);
} else {
switch_instance0 = null;
}
} else if (switch_value) {
switch_instance0.$set(switch_instance0_changes);
}
const switch_instance1_changes = {};
if (dirty & /*$$scope, rows, renderers, $$restProps*/
8388712) {
switch_instance1_changes.$$scope = { dirty, ctx: ctx2 };
}
if (switch_value_1 !== (switch_value_1 = /*renderers*/
ctx2[5].tablebody)) {
if (switch_instance1) {
group_outros();
const old_component = switch_instance1;
transition_out(old_component.$$.fragment, 1, 0, () => {
destroy_component(old_component, 1);
});
check_outros();
}
if (switch_value_1) {
switch_instance1 = construct_svelte_component(switch_value_1, switch_props_1(ctx2));
create_component(switch_instance1.$$.fragment);
transition_in(switch_instance1.$$.fragment, 1);
mount_component(switch_instance1, switch_instance1_anchor.parentNode, switch_instance1_anchor);
} else {
switch_instance1 = null;
}
} else if (switch_value_1) {
switch_instance1.$set(switch_instance1_changes);
}
},
i(local) {
if (current)
return;
if (switch_instance0)
transition_in(switch_instance0.$$.fragment, local);
if (switch_instance1)
transition_in(switch_instance1.$$.fragment, local);
current = true;
},
o(local) {
if (switch_instance0)
transition_out(switch_instance0.$$.fragment, local);
if (switch_instance1)
transition_out(switch_instance1.$$.fragment, local);
current = false;
},
d(detaching) {
if (switch_instance0)
destroy_component(switch_instance0, detaching);
if (detaching)
detach(t);
if (detaching)
detach(switch_instance1_anchor);
if (switch_instance1)
destroy_component(switch_instance1, detaching);
}
};
}
function create_each_block$2(ctx) {
let parser;
let current;
const parser_spread_levels = [
/*token*/
ctx[7],
{ renderers: (
/*renderers*/
ctx[5]
) }
];
let parser_props = {};
for (let i = 0; i < parser_spread_levels.length; i += 1) {
parser_props = assign(parser_props, parser_spread_levels[i]);
}
parser = new Parser$1({ props: parser_props });
return {
c() {
create_component(parser.$$.fragment);
},
l(nodes) {
claim_component(parser.$$.fragment, nodes);
},
m(target, anchor) {
mount_component(parser, target, anchor);
current = true;
},
p(ctx2, dirty) {
const parser_changes = dirty & /*tokens, renderers*/
34 ? get_spread_update(parser_spread_levels, [
dirty & /*tokens*/
2 && get_spread_object(
/*token*/
ctx2[7]
),
dirty & /*renderers*/
32 && { renderers: (
/*renderers*/
ctx2[5]
) }
]) : {};
parser.$set(parser_changes);
},
i(local) {
if (current)
return;
transition_in(parser.$$.fragment, local);
current = true;
},
o(local) {
transition_out(parser.$$.fragment, local);
current = false;
},
d(detaching) {
destroy_component(parser, detaching);
}
};
}
function create_fragment$o(ctx) {
let current_block_type_index;
let if_block;
let if_block_anchor;
let current;
const if_block_creators = [create_if_block$4, create_if_block_1$2];
const if_blocks = [];
function select_block_type(ctx2, dirty) {
if (!/*type*/
ctx2[0])
return 0;
if (
/*renderers*/
ctx2[5][
/*type*/
ctx2[0]
]
)
return 1;
return -1;
}
if (~(current_block_type_index = select_block_type(ctx))) {
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx);
}
return {
c() {
if (if_block)
if_block.c();
if_block_anchor = empty();
},
l(nodes) {
if (if_block)
if_block.l(nodes);
if_block_anchor = empty();
},
m(target, anchor) {
if (~current_block_type_index) {
if_blocks[current_block_type_index].m(target, anchor);
}
insert_hydration(target, if_block_anchor, anchor);
current = true;
},
p(ctx2, [dirty]) {
let previous_block_index = current_block_type_index;
current_block_type_index = select_block_type(ctx2);
if (current_block_type_index === previous_block_index) {
if (~current_block_type_index) {
if_blocks[current_block_type_index].p(ctx2, dirty);
}
} else {
if (if_block) {
group_outros();
transition_out(if_blocks[previous_block_index], 1, 1, () => {
if_blocks[previous_block_index] = null;
});
check_outros();
}
if (~current_block_type_index) {
if_block = if_blocks[current_block_type_index];
if (!if_block) {
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx2);
if_block.c();
} else {
if_block.p(ctx2, dirty);
}
transition_in(if_block, 1);
if_block.m(if_block_anchor.parentNode, if_block_anchor);
} else {
if_block = null;
}
}
},
i(local) {
if (current)
return;
transition_in(if_block);
current = true;
},
o(local) {
transition_out(if_block);
current = false;
},
d(detaching) {
if (~current_block_type_index) {
if_blocks[current_block_type_index].d(detaching);
}
if (detaching)
detach(if_block_anchor);
}
};
}
function instance$n($$self, $$props, $$invalidate) {
const omit_props_names = ["type", "tokens", "header", "rows", "ordered", "renderers"];
let $$restProps = compute_rest_props($$props, omit_props_names);
let { type = void 0 } = $$props;
let { tokens = void 0 } = $$props;
let { header = void 0 } = $$props;
let { rows = void 0 } = $$props;
let { ordered = false } = $$props;
let { renderers } = $$props;
supressWarnings();
$$self.$$set = ($$new_props) => {
$$props = assign(assign({}, $$props), exclude_internal_props($$new_props));
$$invalidate(6, $$restProps = compute_rest_props($$props, omit_props_names));
if ("type" in $$new_props)
$$invalidate(0, type = $$new_props.type);
if ("tokens" in $$new_props)
$$invalidate(1, tokens = $$new_props.tokens);
if ("header" in $$new_props)
$$invalidate(2, header = $$new_props.header);
if ("rows" in $$new_props)
$$invalidate(3, rows = $$new_props.rows);
if ("ordered" in $$new_props)
$$invalidate(4, ordered = $$new_props.ordered);
if ("renderers" in $$new_props)
$$invalidate(5, renderers = $$new_props.renderers);
};
return [type, tokens, header, rows, ordered, renderers, $$restProps];
}
let Parser$1 = class Parser extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$n, create_fragment$o, safe_not_equal, {
type: 0,
tokens: 1,
header: 2,
rows: 3,
ordered: 4,
renderers: 5
});
}
};
function getDefaults() {
return {
async: false,
baseUrl: null,
breaks: false,
extensions: null,
gfm: true,
headerIds: true,
headerPrefix: "",
highlight: null,
langPrefix: "language-",
mangle: true,
pedantic: false,
renderer: null,
sanitize: false,
sanitizer: null,
silent: false,
smartypants: false,
tokenizer: null,
walkTokens: null,
xhtml: false
};
}
let defaults = getDefaults();
function changeDefaults(newDefaults) {
defaults = newDefaults;
}
const escapeTest = /[&<>"']/;
const escapeReplace = new RegExp(escapeTest.source, "g");
const escapeTestNoEncode = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/;
const escapeReplaceNoEncode = new RegExp(escapeTestNoEncode.source, "g");
const escapeReplacements = {
"&": "&amp;",
"<": "&lt;",
">": "&gt;",
'"': "&quot;",
"'": "&#39;"
};
const getEscapeReplacement = (ch) => escapeReplacements[ch];
function escape(html, encode) {
if (encode) {
if (escapeTest.test(html)) {
return html.replace(escapeReplace, getEscapeReplacement);
}
} else {
if (escapeTestNoEncode.test(html)) {
return html.replace(escapeReplaceNoEncode, getEscapeReplacement);
}
}
return html;
}
const unescapeTest = /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;
function unescape(html) {
return html.replace(unescapeTest, (_, n) => {
n = n.toLowerCase();
if (n === "colon")
return ":";
if (n.charAt(0) === "#") {
return n.charAt(1) === "x" ? String.fromCharCode(parseInt(n.substring(2), 16)) : String.fromCharCode(+n.substring(1));
}
return "";
});
}
const caret = /(^|[^\[])\^/g;
function edit(regex, opt) {
regex = typeof regex === "string" ? regex : regex.source;
opt = opt || "";
const obj = {
replace: (name, val) => {
val = val.source || val;
val = val.replace(caret, "$1");
regex = regex.replace(name, val);
return obj;
},
getRegex: () => {
return new RegExp(regex, opt);
}
};
return obj;
}
const nonWordAndColonTest = /[^\w:]/g;
const originIndependentUrl = /^$|^[a-z][a-z0-9+.-]*:|^[?#]/i;
function cleanUrl(sanitize, base, href) {
if (sanitize) {
let prot;
try {
prot = decodeURIComponent(unescape(href)).replace(nonWordAndColonTest, "").toLowerCase();
} catch (e) {
return null;
}
if (prot.indexOf("javascript:") === 0 || prot.indexOf("vbscript:") === 0 || prot.indexOf("data:") === 0) {
return null;
}
}
if (base && !originIndependentUrl.test(href)) {
href = resolveUrl(base, href);
}
try {
href = encodeURI(href).replace(/%25/g, "%");
} catch (e) {
return null;
}
return href;
}
const baseUrls = {};
const justDomain = /^[^:]+:\/*[^/]*$/;
const protocol = /^([^:]+:)[\s\S]*$/;
const domain = /^([^:]+:\/*[^/]*)[\s\S]*$/;
function resolveUrl(base, href) {
if (!baseUrls[" " + base]) {
if (justDomain.test(base)) {
baseUrls[" " + base] = base + "/";
} else {
baseUrls[" " + base] = rtrim(base, "/", true);
}
}
base = baseUrls[" " + base];
const relativeBase = base.indexOf(":") === -1;
if (href.substring(0, 2) === "//") {
if (relativeBase) {
return href;
}
return base.replace(protocol, "$1") + href;
} else if (href.charAt(0) === "/") {
if (relativeBase) {
return href;
}
return base.replace(domain, "$1") + href;
} else {
return base + href;
}
}
const noopTest = { exec: function noopTest2() {
} };
function merge(obj) {
let i = 1, target, key2;
for (; i < arguments.length; i++) {
target = arguments[i];
for (key2 in target) {
if (Object.prototype.hasOwnProperty.call(target, key2)) {
obj[key2] = target[key2];
}
}
}
return obj;
}
function splitCells(tableRow, count) {
const row = tableRow.replace(/\|/g, (match, offset, str) => {
let escaped = false, curr = offset;
while (--curr >= 0 && str[curr] === "\\")
escaped = !escaped;
if (escaped) {
return "|";
} else {
return " |";
}
}), cells = row.split(/ \|/);
let i = 0;
if (!cells[0].trim()) {
cells.shift();
}
if (cells.length > 0 && !cells[cells.length - 1].trim()) {
cells.pop();
}
if (cells.length > count) {
cells.splice(count);
} else {
while (cells.length < count)
cells.push("");
}
for (; i < cells.length; i++) {
cells[i] = cells[i].trim().replace(/\\\|/g, "|");
}
return cells;
}
function rtrim(str, c, invert) {
const l = str.length;
if (l === 0) {
return "";
}
let suffLen = 0;
while (suffLen < l) {
const currChar = str.charAt(l - suffLen - 1);
if (currChar === c && !invert) {
suffLen++;
} else if (currChar !== c && invert) {
suffLen++;
} else {
break;
}
}
return str.slice(0, l - suffLen);
}
function findClosingBracket(str, b) {
if (str.indexOf(b[1]) === -1) {
return -1;
}
const l = str.length;
let level = 0, i = 0;
for (; i < l; i++) {
if (str[i] === "\\") {
i++;
} else if (str[i] === b[0]) {
level++;
} else if (str[i] === b[1]) {
level--;
if (level < 0) {
return i;
}
}
}
return -1;
}
function checkSanitizeDeprecation(opt) {
if (opt && opt.sanitize && !opt.silent) {
console.warn("marked(): sanitize and sanitizer parameters are deprecated since version 0.7.0, should not be used and will be removed in the future. Read more here: https://marked.js.org/#/USING_ADVANCED.md#options");
}
}
function repeatString(pattern, count) {
if (count < 1) {
return "";
}
let result = "";
while (count > 1) {
if (count & 1) {
result += pattern;
}
count >>= 1;
pattern += pattern;
}
return result + pattern;
}
function outputLink(cap, link, raw, lexer) {
const href = link.href;
const title = link.title ? escape(link.title) : null;
const text2 = cap[1].replace(/\\([\[\]])/g, "$1");
if (cap[0].charAt(0) !== "!") {
lexer.state.inLink = true;
const token = {
type: "link",
raw,
href,
title,
text: text2,
tokens: lexer.inlineTokens(text2)
};
lexer.state.inLink = false;
return token;
}
return {
type: "image",
raw,
href,
title,
text: escape(text2)
};
}
function indentCodeCompensation(raw, text2) {
const matchIndentToCode = raw.match(/^(\s+)(?:```)/);
if (matchIndentToCode === null) {
return text2;
}
const indentToCode = matchIndentToCode[1];
return text2.split("\n").map((node) => {
const matchIndentInNode = node.match(/^\s+/);
if (matchIndentInNode === null) {
return node;
}
const [indentInNode] = matchIndentInNode;
if (indentInNode.length >= indentToCode.length) {
return node.slice(indentToCode.length);
}
return node;
}).join("\n");
}
class Tokenizer {
constructor(options) {
this.options = options || defaults;
}
space(src) {
const cap = this.rules.block.newline.exec(src);
if (cap && cap[0].length > 0) {
return {
type: "space",
raw: cap[0]
};
}
}
code(src) {
const cap = this.rules.block.code.exec(src);
if (cap) {
const text2 = cap[0].replace(/^ {1,4}/gm, "");
return {
type: "code",
raw: cap[0],
codeBlockStyle: "indented",
text: !this.options.pedantic ? rtrim(text2, "\n") : text2
};
}
}
fences(src) {
const cap = this.rules.block.fences.exec(src);
if (cap) {
const raw = cap[0];
const text2 = indentCodeCompensation(raw, cap[3] || "");
return {
type: "code",
raw,
lang: cap[2] ? cap[2].trim().replace(this.rules.inline._escapes, "$1") : cap[2],
text: text2
};
}
}
heading(src) {
const cap = this.rules.block.heading.exec(src);
if (cap) {
let text2 = cap[2].trim();
if (/#$/.test(text2)) {
const trimmed = rtrim(text2, "#");
if (this.options.pedantic) {
text2 = trimmed.trim();
} else if (!trimmed || / $/.test(trimmed)) {
text2 = trimmed.trim();
}
}
return {
type: "heading",
raw: cap[0],
depth: cap[1].length,
text: text2,
tokens: this.lexer.inline(text2)
};
}
}
hr(src) {
const cap = this.rules.block.hr.exec(src);
if (cap) {
return {
type: "hr",
raw: cap[0]
};
}
}
blockquote(src) {
const cap = this.rules.block.blockquote.exec(src);
if (cap) {
const text2 = cap[0].replace(/^ *>[ \t]?/gm, "");
const top = this.lexer.state.top;
this.lexer.state.top = true;
const tokens = this.lexer.blockTokens(text2);
this.lexer.state.top = top;
return {
type: "blockquote",
raw: cap[0],
tokens,
text: text2
};
}
}
list(src) {
let cap = this.rules.block.list.exec(src);
if (cap) {
let raw, istask, ischecked, indent, i, blankLine, endsWithBlankLine, line, nextLine, rawLine, itemContents, endEarly;
let bull = cap[1].trim();
const isordered = bull.length > 1;
const list = {
type: "list",
raw: "",
ordered: isordered,
start: isordered ? +bull.slice(0, -1) : "",
loose: false,
items: []
};
bull = isordered ? `\\d{1,9}\\${bull.slice(-1)}` : `\\${bull}`;
if (this.options.pedantic) {
bull = isordered ? bull : "[*+-]";
}
const itemRegex = new RegExp(`^( {0,3}${bull})((?:[ ][^\\n]*)?(?:\\n|$))`);
while (src) {
endEarly = false;
if (!(cap = itemRegex.exec(src))) {
break;
}
if (this.rules.block.hr.test(src)) {
break;
}
raw = cap[0];
src = src.substring(raw.length);
line = cap[2].split("\n", 1)[0].replace(/^\t+/, (t) => " ".repeat(3 * t.length));
nextLine = src.split("\n", 1)[0];
if (this.options.pedantic) {
indent = 2;
itemContents = line.trimLeft();
} else {
indent = cap[2].search(/[^ ]/);
indent = indent > 4 ? 1 : indent;
itemContents = line.slice(indent);
indent += cap[1].length;
}
blankLine = false;
if (!line && /^ *$/.test(nextLine)) {
raw += nextLine + "\n";
src = src.substring(nextLine.length + 1);
endEarly = true;
}
if (!endEarly) {
const nextBulletRegex = new RegExp(`^ {0,${Math.min(3, indent - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`);
const hrRegex = new RegExp(`^ {0,${Math.min(3, indent - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`);
const fencesBeginRegex = new RegExp(`^ {0,${Math.min(3, indent - 1)}}(?:\`\`\`|~~~)`);
const headingBeginRegex = new RegExp(`^ {0,${Math.min(3, indent - 1)}}#`);
while (src) {
rawLine = src.split("\n", 1)[0];
nextLine = rawLine;
if (this.options.pedantic) {
nextLine = nextLine.replace(/^ {1,4}(?=( {4})*[^ ])/g, " ");
}
if (fencesBeginRegex.test(nextLine)) {
break;
}
if (headingBeginRegex.test(nextLine)) {
break;
}
if (nextBulletRegex.test(nextLine)) {
break;
}
if (hrRegex.test(src)) {
break;
}
if (nextLine.search(/[^ ]/) >= indent || !nextLine.trim()) {
itemContents += "\n" + nextLine.slice(indent);
} else {
if (blankLine) {
break;
}
if (line.search(/[^ ]/) >= 4) {
break;
}
if (fencesBeginRegex.test(line)) {
break;
}
if (headingBeginRegex.test(line)) {
break;
}
if (hrRegex.test(line)) {
break;
}
itemContents += "\n" + nextLine;
}
if (!blankLine && !nextLine.trim()) {
blankLine = true;
}
raw += rawLine + "\n";
src = src.substring(rawLine.length + 1);
line = nextLine.slice(indent);
}
}
if (!list.loose) {
if (endsWithBlankLine) {
list.loose = true;
} else if (/\n *\n *$/.test(raw)) {
endsWithBlankLine = true;
}
}
if (this.options.gfm) {
istask = /^\[[ xX]\] /.exec(itemContents);
if (istask) {
ischecked = istask[0] !== "[ ] ";
itemContents = itemContents.replace(/^\[[ xX]\] +/, "");
}
}
list.items.push({
type: "list_item",
raw,
task: !!istask,
checked: ischecked,
loose: false,
text: itemContents
});
list.raw += raw;
}
list.items[list.items.length - 1].raw = raw.trimRight();
list.items[list.items.length - 1].text = itemContents.trimRight();
list.raw = list.raw.trimRight();
const l = list.items.length;
for (i = 0; i < l; i++) {
this.lexer.state.top = false;
list.items[i].tokens = this.lexer.blockTokens(list.items[i].text, []);
if (!list.loose) {
const spacers = list.items[i].tokens.filter((t) => t.type === "space");
const hasMultipleLineBreaks = spacers.length > 0 && spacers.some((t) => /\n.*\n/.test(t.raw));
list.loose = hasMultipleLineBreaks;
}
}
if (list.loose) {
for (i = 0; i < l; i++) {
list.items[i].loose = true;
}
}
return list;
}
}
html(src) {
const cap = this.rules.block.html.exec(src);
if (cap) {
const token = {
type: "html",
raw: cap[0],
pre: !this.options.sanitizer && (cap[1] === "pre" || cap[1] === "script" || cap[1] === "style"),
text: cap[0]
};
if (this.options.sanitize) {
const text2 = this.options.sanitizer ? this.options.sanitizer(cap[0]) : escape(cap[0]);
token.type = "paragraph";
token.text = text2;
token.tokens = this.lexer.inline(text2);
}
return token;
}
}
def(src) {
const cap = this.rules.block.def.exec(src);
if (cap) {
const tag = cap[1].toLowerCase().replace(/\s+/g, " ");
const href = cap[2] ? cap[2].replace(/^<(.*)>$/, "$1").replace(this.rules.inline._escapes, "$1") : "";
const title = cap[3] ? cap[3].substring(1, cap[3].length - 1).replace(this.rules.inline._escapes, "$1") : cap[3];
return {
type: "def",
tag,
raw: cap[0],
href,
title
};
}
}
table(src) {
const cap = this.rules.block.table.exec(src);
if (cap) {
const item = {
type: "table",
header: splitCells(cap[1]).map((c) => {
return { text: c };
}),
align: cap[2].replace(/^ *|\| *$/g, "").split(/ *\| */),
rows: cap[3] && cap[3].trim() ? cap[3].replace(/\n[ \t]*$/, "").split("\n") : []
};
if (item.header.length === item.align.length) {
item.raw = cap[0];
let l = item.align.length;
let i, j, k, row;
for (i = 0; i < l; i++) {
if (/^ *-+: *$/.test(item.align[i])) {
item.align[i] = "right";
} else if (/^ *:-+: *$/.test(item.align[i])) {
item.align[i] = "center";
} else if (/^ *:-+ *$/.test(item.align[i])) {
item.align[i] = "left";
} else {
item.align[i] = null;
}
}
l = item.rows.length;
for (i = 0; i < l; i++) {
item.rows[i] = splitCells(item.rows[i], item.header.length).map((c) => {
return { text: c };
});
}
l = item.header.length;
for (j = 0; j < l; j++) {
item.header[j].tokens = this.lexer.inline(item.header[j].text);
}
l = item.rows.length;
for (j = 0; j < l; j++) {
row = item.rows[j];
for (k = 0; k < row.length; k++) {
row[k].tokens = this.lexer.inline(row[k].text);
}
}
return item;
}
}
}
lheading(src) {
const cap = this.rules.block.lheading.exec(src);
if (cap) {
return {
type: "heading",
raw: cap[0],
depth: cap[2].charAt(0) === "=" ? 1 : 2,
text: cap[1],
tokens: this.lexer.inline(cap[1])
};
}
}
paragraph(src) {
const cap = this.rules.block.paragraph.exec(src);
if (cap) {
const text2 = cap[1].charAt(cap[1].length - 1) === "\n" ? cap[1].slice(0, -1) : cap[1];
return {
type: "paragraph",
raw: cap[0],
text: text2,
tokens: this.lexer.inline(text2)
};
}
}
text(src) {
const cap = this.rules.block.text.exec(src);
if (cap) {
return {
type: "text",
raw: cap[0],
text: cap[0],
tokens: this.lexer.inline(cap[0])
};
}
}
escape(src) {
const cap = this.rules.inline.escape.exec(src);
if (cap) {
return {
type: "escape",
raw: cap[0],
text: escape(cap[1])
};
}
}
tag(src) {
const cap = this.rules.inline.tag.exec(src);
if (cap) {
if (!this.lexer.state.inLink && /^<a /i.test(cap[0])) {
this.lexer.state.inLink = true;
} else if (this.lexer.state.inLink && /^<\/a>/i.test(cap[0])) {
this.lexer.state.inLink = false;
}
if (!this.lexer.state.inRawBlock && /^<(pre|code|kbd|script)(\s|>)/i.test(cap[0])) {
this.lexer.state.inRawBlock = true;
} else if (this.lexer.state.inRawBlock && /^<\/(pre|code|kbd|script)(\s|>)/i.test(cap[0])) {
this.lexer.state.inRawBlock = false;
}
return {
type: this.options.sanitize ? "text" : "html",
raw: cap[0],
inLink: this.lexer.state.inLink,
inRawBlock: this.lexer.state.inRawBlock,
text: this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(cap[0]) : escape(cap[0]) : cap[0]
};
}
}
link(src) {
const cap = this.rules.inline.link.exec(src);
if (cap) {
const trimmedUrl = cap[2].trim();
if (!this.options.pedantic && /^</.test(trimmedUrl)) {
if (!/>$/.test(trimmedUrl)) {
return;
}
const rtrimSlash = rtrim(trimmedUrl.slice(0, -1), "\\");
if ((trimmedUrl.length - rtrimSlash.length) % 2 === 0) {
return;
}
} else {
const lastParenIndex = findClosingBracket(cap[2], "()");
if (lastParenIndex > -1) {
const start = cap[0].indexOf("!") === 0 ? 5 : 4;
const linkLen = start + cap[1].length + lastParenIndex;
cap[2] = cap[2].substring(0, lastParenIndex);
cap[0] = cap[0].substring(0, linkLen).trim();
cap[3] = "";
}
}
let href = cap[2];
let title = "";
if (this.options.pedantic) {
const link = /^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(href);
if (link) {
href = link[1];
title = link[3];
}
} else {
title = cap[3] ? cap[3].slice(1, -1) : "";
}
href = href.trim();
if (/^</.test(href)) {
if (this.options.pedantic && !/>$/.test(trimmedUrl)) {
href = href.slice(1);
} else {
href = href.slice(1, -1);
}
}
return outputLink(cap, {
href: href ? href.replace(this.rules.inline._escapes, "$1") : href,
title: title ? title.replace(this.rules.inline._escapes, "$1") : title
}, cap[0], this.lexer);
}
}
reflink(src, links) {
let cap;
if ((cap = this.rules.inline.reflink.exec(src)) || (cap = this.rules.inline.nolink.exec(src))) {
let link = (cap[2] || cap[1]).replace(/\s+/g, " ");
link = links[link.toLowerCase()];
if (!link) {
const text2 = cap[0].charAt(0);
return {
type: "text",
raw: text2,
text: text2
};
}
return outputLink(cap, link, cap[0], this.lexer);
}
}
emStrong(src, maskedSrc, prevChar = "") {
let match = this.rules.inline.emStrong.lDelim.exec(src);
if (!match)
return;
if (match[3] && prevChar.match(/[\p{L}\p{N}]/u))
return;
const nextChar = match[1] || match[2] || "";
if (!nextChar || nextChar && (prevChar === "" || this.rules.inline.punctuation.exec(prevChar))) {
const lLength = match[0].length - 1;
let rDelim, rLength, delimTotal = lLength, midDelimTotal = 0;
const endReg = match[0][0] === "*" ? this.rules.inline.emStrong.rDelimAst : this.rules.inline.emStrong.rDelimUnd;
endReg.lastIndex = 0;
maskedSrc = maskedSrc.slice(-1 * src.length + lLength);
while ((match = endReg.exec(maskedSrc)) != null) {
rDelim = match[1] || match[2] || match[3] || match[4] || match[5] || match[6];
if (!rDelim)
continue;
rLength = rDelim.length;
if (match[3] || match[4]) {
delimTotal += rLength;
continue;
} else if (match[5] || match[6]) {
if (lLength % 3 && !((lLength + rLength) % 3)) {
midDelimTotal += rLength;
continue;
}
}
delimTotal -= rLength;
if (delimTotal > 0)
continue;
rLength = Math.min(rLength, rLength + delimTotal + midDelimTotal);
const raw = src.slice(0, lLength + match.index + (match[0].length - rDelim.length) + rLength);
if (Math.min(lLength, rLength) % 2) {
const text3 = raw.slice(1, -1);
return {
type: "em",
raw,
text: text3,
tokens: this.lexer.inlineTokens(text3)
};
}
const text2 = raw.slice(2, -2);
return {
type: "strong",
raw,
text: text2,
tokens: this.lexer.inlineTokens(text2)
};
}
}
}
codespan(src) {
const cap = this.rules.inline.code.exec(src);
if (cap) {
let text2 = cap[2].replace(/\n/g, " ");
const hasNonSpaceChars = /[^ ]/.test(text2);
const hasSpaceCharsOnBothEnds = /^ /.test(text2) && / $/.test(text2);
if (hasNonSpaceChars && hasSpaceCharsOnBothEnds) {
text2 = text2.substring(1, text2.length - 1);
}
text2 = escape(text2, true);
return {
type: "codespan",
raw: cap[0],
text: text2
};
}
}
br(src) {
const cap = this.rules.inline.br.exec(src);
if (cap) {
return {
type: "br",
raw: cap[0]
};
}
}
del(src) {
const cap = this.rules.inline.del.exec(src);
if (cap) {
return {
type: "del",
raw: cap[0],
text: cap[2],
tokens: this.lexer.inlineTokens(cap[2])
};
}
}
autolink(src, mangle2) {
const cap = this.rules.inline.autolink.exec(src);
if (cap) {
let text2, href;
if (cap[2] === "@") {
text2 = escape(this.options.mangle ? mangle2(cap[1]) : cap[1]);
href = "mailto:" + text2;
} else {
text2 = escape(cap[1]);
href = text2;
}
return {
type: "link",
raw: cap[0],
text: text2,
href,
tokens: [
{
type: "text",
raw: text2,
text: text2
}
]
};
}
}
url(src, mangle2) {
let cap;
if (cap = this.rules.inline.url.exec(src)) {
let text2, href;
if (cap[2] === "@") {
text2 = escape(this.options.mangle ? mangle2(cap[0]) : cap[0]);
href = "mailto:" + text2;
} else {
let prevCapZero;
do {
prevCapZero = cap[0];
cap[0] = this.rules.inline._backpedal.exec(cap[0])[0];
} while (prevCapZero !== cap[0]);
text2 = escape(cap[0]);
if (cap[1] === "www.") {
href = "http://" + cap[0];
} else {
href = cap[0];
}
}
return {
type: "link",
raw: cap[0],
text: text2,
href,
tokens: [
{
type: "text",
raw: text2,
text: text2
}
]
};
}
}
inlineText(src, smartypants2) {
const cap = this.rules.inline.text.exec(src);
if (cap) {
let text2;
if (this.lexer.state.inRawBlock) {
text2 = this.options.sanitize ? this.options.sanitizer ? this.options.sanitizer(cap[0]) : escape(cap[0]) : cap[0];
} else {
text2 = escape(this.options.smartypants ? smartypants2(cap[0]) : cap[0]);
}
return {
type: "text",
raw: cap[0],
text: text2
};
}
}
}
const block = {
newline: /^(?: *(?:\n|$))+/,
code: /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,
fences: /^ {0,3}(`{3,}(?=[^`\n]*\n)|~{3,})([^\n]*)\n(?:|([\s\S]*?)\n)(?: {0,3}\1[~`]* *(?=\n|$)|$)/,
hr: /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,
heading: /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,
blockquote: /^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/,
list: /^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/,
html: "^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))",
def: /^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/,
table: noopTest,
lheading: /^((?:.|\n(?!\n))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
// regex template, placeholders will be replaced according to different paragraph
// interruption rules of commonmark and the original markdown spec:
_paragraph: /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,
text: /^[^\n]+/
};
block._label = /(?!\s*\])(?:\\.|[^\[\]\\])+/;
block._title = /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/;
block.def = edit(block.def).replace("label", block._label).replace("title", block._title).getRegex();
block.bullet = /(?:[*+-]|\d{1,9}[.)])/;
block.listItemStart = edit(/^( *)(bull) */).replace("bull", block.bullet).getRegex();
block.list = edit(block.list).replace(/bull/g, block.bullet).replace("hr", "\\n+(?=\\1?(?:(?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$))").replace("def", "\\n+(?=" + block.def.source + ")").getRegex();
block._tag = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";
block._comment = /<!--(?!-?>)[\s\S]*?(?:-->|$)/;
block.html = edit(block.html, "i").replace("comment", block._comment).replace("tag", block._tag).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();
block.paragraph = edit(block._paragraph).replace("hr", block.hr).replace("heading", " {0,3}#{1,6} ").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", block._tag).getRegex();
block.blockquote = edit(block.blockquote).replace("paragraph", block.paragraph).getRegex();
block.normal = merge({}, block);
block.gfm = merge({}, block.normal, {
table: "^ *([^\\n ].*\\|.*)\\n {0,3}(?:\\| *)?(:?-+:? *(?:\\| *:?-+:? *)*)(?:\\| *)?(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)"
// Cells
});
block.gfm.table = edit(block.gfm.table).replace("hr", block.hr).replace("heading", " {0,3}#{1,6} ").replace("blockquote", " {0,3}>").replace("code", " {4}[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", block._tag).getRegex();
block.gfm.paragraph = edit(block._paragraph).replace("hr", block.hr).replace("heading", " {0,3}#{1,6} ").replace("|lheading", "").replace("table", block.gfm.table).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", block._tag).getRegex();
block.pedantic = merge({}, block.normal, {
html: edit(
`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`
).replace("comment", block._comment).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
heading: /^(#{1,6})(.*)(?:\n+|$)/,
fences: noopTest,
// fences not supported
lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
paragraph: edit(block.normal._paragraph).replace("hr", block.hr).replace("heading", " *#{1,6} *[^\n]").replace("lheading", block.lheading).replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").getRegex()
});
const inline = {
escape: /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,
autolink: /^<(scheme:[^\s\x00-\x1f<>]*|email)>/,
url: noopTest,
tag: "^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>",
// CDATA section
link: /^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/,
reflink: /^!?\[(label)\]\[(ref)\]/,
nolink: /^!?\[(ref)\](?:\[\])?/,
reflinkSearch: "reflink|nolink(?!\\()",
emStrong: {
lDelim: /^(?:\*+(?:([punct_])|[^\s*]))|^_+(?:([punct*])|([^\s_]))/,
// (1) and (2) can only be a Right Delimiter. (3) and (4) can only be Left. (5) and (6) can be either Left or Right.
// () Skip orphan inside strong () Consume to delim (1) #*** (2) a***#, a*** (3) #***a, ***a (4) ***# (5) #***# (6) a***a
rDelimAst: /^(?:[^_*\\]|\\.)*?\_\_(?:[^_*\\]|\\.)*?\*(?:[^_*\\]|\\.)*?(?=\_\_)|(?:[^*\\]|\\.)+(?=[^*])|[punct_](\*+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\*+)(?=[punct_\s]|$)|[punct_\s](\*+)(?=[^punct*_\s])|[\s](\*+)(?=[punct_])|[punct_](\*+)(?=[punct_])|(?:[^punct*_\s\\]|\\.)(\*+)(?=[^punct*_\s])/,
rDelimUnd: /^(?:[^_*\\]|\\.)*?\*\*(?:[^_*\\]|\\.)*?\_(?:[^_*\\]|\\.)*?(?=\*\*)|(?:[^_\\]|\\.)+(?=[^_])|[punct*](\_+)(?=[\s]|$)|(?:[^punct*_\s\\]|\\.)(\_+)(?=[punct*\s]|$)|[punct*\s](\_+)(?=[^punct*_\s])|[\s](\_+)(?=[punct*])|[punct*](\_+)(?=[punct*])/
// ^- Not allowed for _
},
code: /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,
br: /^( {2,}|\\)\n(?!\s*$)/,
del: noopTest,
text: /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,
punctuation: /^([\spunctuation])/
};
inline._punctuation = "!\"#$%&'()+\\-.,/:;<=>?@\\[\\]`^{|}~";
inline.punctuation = edit(inline.punctuation).replace(/punctuation/g, inline._punctuation).getRegex();
inline.blockSkip = /\[[^\]]*?\]\([^\)]*?\)|`[^`]*?`|<[^>]*?>/g;
inline.escapedEmSt = /(?:^|[^\\])(?:\\\\)*\\[*_]/g;
inline._comment = edit(block._comment).replace("(?:-->|$)", "-->").getRegex();
inline.emStrong.lDelim = edit(inline.emStrong.lDelim).replace(/punct/g, inline._punctuation).getRegex();
inline.emStrong.rDelimAst = edit(inline.emStrong.rDelimAst, "g").replace(/punct/g, inline._punctuation).getRegex();
inline.emStrong.rDelimUnd = edit(inline.emStrong.rDelimUnd, "g").replace(/punct/g, inline._punctuation).getRegex();
inline._escapes = /\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/g;
inline._scheme = /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/;
inline._email = /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/;
inline.autolink = edit(inline.autolink).replace("scheme", inline._scheme).replace("email", inline._email).getRegex();
inline._attribute = /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/;
inline.tag = edit(inline.tag).replace("comment", inline._comment).replace("attribute", inline._attribute).getRegex();
inline._label = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;
inline._href = /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/;
inline._title = /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/;
inline.link = edit(inline.link).replace("label", inline._label).replace("href", inline._href).replace("title", inline._title).getRegex();
inline.reflink = edit(inline.reflink).replace("label", inline._label).replace("ref", block._label).getRegex();
inline.nolink = edit(inline.nolink).replace("ref", block._label).getRegex();
inline.reflinkSearch = edit(inline.reflinkSearch, "g").replace("reflink", inline.reflink).replace("nolink", inline.nolink).getRegex();
inline.normal = merge({}, inline);
inline.pedantic = merge({}, inline.normal, {
strong: {
start: /^__|\*\*/,
middle: /^__(?=\S)([\s\S]*?\S)__(?!_)|^\*\*(?=\S)([\s\S]*?\S)\*\*(?!\*)/,
endAst: /\*\*(?!\*)/g,
endUnd: /__(?!_)/g
},
em: {
start: /^_|\*/,
middle: /^()\*(?=\S)([\s\S]*?\S)\*(?!\*)|^_(?=\S)([\s\S]*?\S)_(?!_)/,
endAst: /\*(?!\*)/g,
endUnd: /_(?!_)/g
},
link: edit(/^!?\[(label)\]\((.*?)\)/).replace("label", inline._label).getRegex(),
reflink: edit(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", inline._label).getRegex()
});
inline.gfm = merge({}, inline.normal, {
escape: edit(inline.escape).replace("])", "~|])").getRegex(),
_extended_email: /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/,
url: /^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,
_backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
del: /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,
text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
});
inline.gfm.url = edit(inline.gfm.url, "i").replace("email", inline.gfm._extended_email).getRegex();
inline.breaks = merge({}, inline.gfm, {
br: edit(inline.br).replace("{2,}", "*").getRegex(),
text: edit(inline.gfm.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
});
function smartypants(text2) {
return text2.replace(/---/g, "—").replace(/--/g, "").replace(/(^|[-\u2014/(\[{"\s])'/g, "$1").replace(/'/g, "").replace(/(^|[-\u2014/(\[{\u2018\s])"/g, "$1“").replace(/"/g, "”").replace(/\.{3}/g, "…");
}
function mangle(text2) {
let out = "", i, ch;
const l = text2.length;
for (i = 0; i < l; i++) {
ch = text2.charCodeAt(i);
if (Math.random() > 0.5) {
ch = "x" + ch.toString(16);
}
out += "&#" + ch + ";";
}
return out;
}
class Lexer {
constructor(options) {
this.tokens = [];
this.tokens.links = /* @__PURE__ */ Object.create(null);
this.options = options || defaults;
this.options.tokenizer = this.options.tokenizer || new Tokenizer();
this.tokenizer = this.options.tokenizer;
this.tokenizer.options = this.options;
this.tokenizer.lexer = this;
this.inlineQueue = [];
this.state = {
inLink: false,
inRawBlock: false,
top: true
};
const rules = {
block: block.normal,
inline: inline.normal
};
if (this.options.pedantic) {
rules.block = block.pedantic;
rules.inline = inline.pedantic;
} else if (this.options.gfm) {
rules.block = block.gfm;
if (this.options.breaks) {
rules.inline = inline.breaks;
} else {
rules.inline = inline.gfm;
}
}
this.tokenizer.rules = rules;
}
/**
* Expose Rules
*/
static get rules() {
return {
block,
inline
};
}
/**
* Static Lex Method
*/
static lex(src, options) {
const lexer = new Lexer(options);
return lexer.lex(src);
}
/**
* Static Lex Inline Method
*/
static lexInline(src, options) {
const lexer = new Lexer(options);
return lexer.inlineTokens(src);
}
/**
* Preprocessing
*/
lex(src) {
src = src.replace(/\r\n|\r/g, "\n");
this.blockTokens(src, this.tokens);
let next;
while (next = this.inlineQueue.shift()) {
this.inlineTokens(next.src, next.tokens);
}
return this.tokens;
}
/**
* Lexing
*/
blockTokens(src, tokens = []) {
if (this.options.pedantic) {
src = src.replace(/\t/g, " ").replace(/^ +$/gm, "");
} else {
src = src.replace(/^( *)(\t+)/gm, (_, leading, tabs) => {
return leading + " ".repeat(tabs.length);
});
}
let token, lastToken, cutSrc, lastParagraphClipped;
while (src) {
if (this.options.extensions && this.options.extensions.block && this.options.extensions.block.some((extTokenizer) => {
if (token = extTokenizer.call({ lexer: this }, src, tokens)) {
src = src.substring(token.raw.length);
tokens.push(token);
return true;
}
return false;
})) {
continue;
}
if (token = this.tokenizer.space(src)) {
src = src.substring(token.raw.length);
if (token.raw.length === 1 && tokens.length > 0) {
tokens[tokens.length - 1].raw += "\n";
} else {
tokens.push(token);
}
continue;
}
if (token = this.tokenizer.code(src)) {
src = src.substring(token.raw.length);
lastToken = tokens[tokens.length - 1];
if (lastToken && (lastToken.type === "paragraph" || lastToken.type === "text")) {
lastToken.raw += "\n" + token.raw;
lastToken.text += "\n" + token.text;
this.inlineQueue[this.inlineQueue.length - 1].src = lastToken.text;
} else {
tokens.push(token);
}
continue;
}
if (token = this.tokenizer.fences(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.heading(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.hr(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.blockquote(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.list(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.html(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.def(src)) {
src = src.substring(token.raw.length);
lastToken = tokens[tokens.length - 1];
if (lastToken && (lastToken.type === "paragraph" || lastToken.type === "text")) {
lastToken.raw += "\n" + token.raw;
lastToken.text += "\n" + token.raw;
this.inlineQueue[this.inlineQueue.length - 1].src = lastToken.text;
} else if (!this.tokens.links[token.tag]) {
this.tokens.links[token.tag] = {
href: token.href,
title: token.title
};
}
continue;
}
if (token = this.tokenizer.table(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.lheading(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
cutSrc = src;
if (this.options.extensions && this.options.extensions.startBlock) {
let startIndex = Infinity;
const tempSrc = src.slice(1);
let tempStart;
this.options.extensions.startBlock.forEach(function(getStartIndex) {
tempStart = getStartIndex.call({ lexer: this }, tempSrc);
if (typeof tempStart === "number" && tempStart >= 0) {
startIndex = Math.min(startIndex, tempStart);
}
});
if (startIndex < Infinity && startIndex >= 0) {
cutSrc = src.substring(0, startIndex + 1);
}
}
if (this.state.top && (token = this.tokenizer.paragraph(cutSrc))) {
lastToken = tokens[tokens.length - 1];
if (lastParagraphClipped && lastToken.type === "paragraph") {
lastToken.raw += "\n" + token.raw;
lastToken.text += "\n" + token.text;
this.inlineQueue.pop();
this.inlineQueue[this.inlineQueue.length - 1].src = lastToken.text;
} else {
tokens.push(token);
}
lastParagraphClipped = cutSrc.length !== src.length;
src = src.substring(token.raw.length);
continue;
}
if (token = this.tokenizer.text(src)) {
src = src.substring(token.raw.length);
lastToken = tokens[tokens.length - 1];
if (lastToken && lastToken.type === "text") {
lastToken.raw += "\n" + token.raw;
lastToken.text += "\n" + token.text;
this.inlineQueue.pop();
this.inlineQueue[this.inlineQueue.length - 1].src = lastToken.text;
} else {
tokens.push(token);
}
continue;
}
if (src) {
const errMsg = "Infinite loop on byte: " + src.charCodeAt(0);
if (this.options.silent) {
console.error(errMsg);
break;
} else {
throw new Error(errMsg);
}
}
}
this.state.top = true;
return tokens;
}
inline(src, tokens = []) {
this.inlineQueue.push({ src, tokens });
return tokens;
}
/**
* Lexing/Compiling
*/
inlineTokens(src, tokens = []) {
let token, lastToken, cutSrc;
let maskedSrc = src;
let match;
let keepPrevChar, prevChar;
if (this.tokens.links) {
const links = Object.keys(this.tokens.links);
if (links.length > 0) {
while ((match = this.tokenizer.rules.inline.reflinkSearch.exec(maskedSrc)) != null) {
if (links.includes(match[0].slice(match[0].lastIndexOf("[") + 1, -1))) {
maskedSrc = maskedSrc.slice(0, match.index) + "[" + repeatString("a", match[0].length - 2) + "]" + maskedSrc.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex);
}
}
}
}
while ((match = this.tokenizer.rules.inline.blockSkip.exec(maskedSrc)) != null) {
maskedSrc = maskedSrc.slice(0, match.index) + "[" + repeatString("a", match[0].length - 2) + "]" + maskedSrc.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
}
while ((match = this.tokenizer.rules.inline.escapedEmSt.exec(maskedSrc)) != null) {
maskedSrc = maskedSrc.slice(0, match.index + match[0].length - 2) + "++" + maskedSrc.slice(this.tokenizer.rules.inline.escapedEmSt.lastIndex);
this.tokenizer.rules.inline.escapedEmSt.lastIndex--;
}
while (src) {
if (!keepPrevChar) {
prevChar = "";
}
keepPrevChar = false;
if (this.options.extensions && this.options.extensions.inline && this.options.extensions.inline.some((extTokenizer) => {
if (token = extTokenizer.call({ lexer: this }, src, tokens)) {
src = src.substring(token.raw.length);
tokens.push(token);
return true;
}
return false;
})) {
continue;
}
if (token = this.tokenizer.escape(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.tag(src)) {
src = src.substring(token.raw.length);
lastToken = tokens[tokens.length - 1];
if (lastToken && token.type === "text" && lastToken.type === "text") {
lastToken.raw += token.raw;
lastToken.text += token.text;
} else {
tokens.push(token);
}
continue;
}
if (token = this.tokenizer.link(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.reflink(src, this.tokens.links)) {
src = src.substring(token.raw.length);
lastToken = tokens[tokens.length - 1];
if (lastToken && token.type === "text" && lastToken.type === "text") {
lastToken.raw += token.raw;
lastToken.text += token.text;
} else {
tokens.push(token);
}
continue;
}
if (token = this.tokenizer.emStrong(src, maskedSrc, prevChar)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.codespan(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.br(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.del(src)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (token = this.tokenizer.autolink(src, mangle)) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
if (!this.state.inLink && (token = this.tokenizer.url(src, mangle))) {
src = src.substring(token.raw.length);
tokens.push(token);
continue;
}
cutSrc = src;
if (this.options.extensions && this.options.extensions.startInline) {
let startIndex = Infinity;
const tempSrc = src.slice(1);
let tempStart;
this.options.extensions.startInline.forEach(function(getStartIndex) {
tempStart = getStartIndex.call({ lexer: this }, tempSrc);
if (typeof tempStart === "number" && tempStart >= 0) {
startIndex = Math.min(startIndex, tempStart);
}
});
if (startIndex < Infinity && startIndex >= 0) {
cutSrc = src.substring(0, startIndex + 1);
}
}
if (token = this.tokenizer.inlineText(cutSrc, smartypants)) {
src = src.substring(token.raw.length);
if (token.raw.slice(-1) !== "_") {
prevChar = token.raw.slice(-1);
}
keepPrevChar = true;
lastToken = tokens[tokens.length - 1];
if (lastToken && lastToken.type === "text") {
lastToken.raw += token.raw;
lastToken.text += token.text;
} else {
tokens.push(token);
}
continue;
}
if (src) {
const errMsg = "Infinite loop on byte: " + src.charCodeAt(0);
if (this.options.silent) {
console.error(errMsg);
break;
} else {
throw new Error(errMsg);
}
}
}
return tokens;
}
}
class Renderer {
constructor(options) {
this.options = options || defaults;
}
code(code, infostring, escaped) {
const lang = (infostring || "").match(/\S*/)[0];
if (this.options.highlight) {
const out = this.options.highlight(code, lang);
if (out != null && out !== code) {
escaped = true;
code = out;
}
}
code = code.replace(/\n$/, "") + "\n";
if (!lang) {
return "<pre><code>" + (escaped ? code : escape(code, true)) + "</code></pre>\n";
}
return '<pre><code class="' + this.options.langPrefix + escape(lang) + '">' + (escaped ? code : escape(code, true)) + "</code></pre>\n";
}
/**
* @param {string} quote
*/
blockquote(quote) {
return `<blockquote>
${quote}</blockquote>
`;
}
html(html) {
return html;
}
/**
* @param {string} text
* @param {string} level
* @param {string} raw
* @param {any} slugger
*/
heading(text2, level, raw, slugger) {
if (this.options.headerIds) {
const id = this.options.headerPrefix + slugger.slug(raw);
return `<h${level} id="${id}">${text2}</h${level}>
`;
}
return `<h${level}>${text2}</h${level}>
`;
}
hr() {
return this.options.xhtml ? "<hr/>\n" : "<hr>\n";
}
list(body, ordered, start) {
const type = ordered ? "ol" : "ul", startatt = ordered && start !== 1 ? ' start="' + start + '"' : "";
return "<" + type + startatt + ">\n" + body + "</" + type + ">\n";
}
/**
* @param {string} text
*/
listitem(text2) {
return `<li>${text2}</li>
`;
}
checkbox(checked) {
return "<input " + (checked ? 'checked="" ' : "") + 'disabled="" type="checkbox"' + (this.options.xhtml ? " /" : "") + "> ";
}
/**
* @param {string} text
*/
paragraph(text2) {
return `<p>${text2}</p>
`;
}
/**
* @param {string} header
* @param {string} body
*/
table(header, body) {
if (body)
body = `<tbody>${body}</tbody>`;
return "<table>\n<thead>\n" + header + "</thead>\n" + body + "</table>\n";
}
/**
* @param {string} content
*/
tablerow(content) {
return `<tr>
${content}</tr>
`;
}
tablecell(content, flags) {
const type = flags.header ? "th" : "td";
const tag = flags.align ? `<${type} align="${flags.align}">` : `<${type}>`;
return tag + content + `</${type}>
`;
}
/**
* span level renderer
* @param {string} text
*/
strong(text2) {
return `<strong>${text2}</strong>`;
}
/**
* @param {string} text
*/
em(text2) {
return `<em>${text2}</em>`;
}
/**
* @param {string} text
*/
codespan(text2) {
return `<code>${text2}</code>`;
}
br() {
return this.options.xhtml ? "<br/>" : "<br>";
}
/**
* @param {string} text
*/
del(text2) {
return `<del>${text2}</del>`;
}
/**
* @param {string} href
* @param {string} title
* @param {string} text
*/
link(href, title, text2) {
href = cleanUrl(this.options.sanitize, this.options.baseUrl, href);
if (href === null) {
return text2;
}
let out = '<a href="' + href + '"';
if (title) {
out += ' title="' + title + '"';
}
out += ">" + text2 + "</a>";
return out;
}
/**
* @param {string} href
* @param {string} title
* @param {string} text
*/
image(href, title, text2) {
href = cleanUrl(this.options.sanitize, this.options.baseUrl, href);
if (href === null) {
return text2;
}
let out = `<img src="${href}" alt="${text2}"`;
if (title) {
out += ` title="${title}"`;
}
out += this.options.xhtml ? "/>" : ">";
return out;
}
text(text2) {
return text2;
}
}
class TextRenderer {
// no need for block level renderers
strong(text2) {
return text2;
}
em(text2) {
return text2;
}
codespan(text2) {
return text2;
}
del(text2) {
return text2;
}
html(text2) {
return text2;
}
text(text2) {
return text2;
}
link(href, title, text2) {
return "" + text2;
}
image(href, title, text2) {
return "" + text2;
}
br() {
return "";
}
}
class Slugger {
constructor() {
this.seen = {};
}
/**
* @param {string} value
*/
serialize(value) {
return value.toLowerCase().trim().replace(/<[!\/a-z].*?>/ig, "").replace(/[\u2000-\u206F\u2E00-\u2E7F\\'!"#$%&()*+,./:;<=>?@[\]^`{|}~]/g, "").replace(/\s/g, "-");
}
/**
* Finds the next safe (unique) slug to use
* @param {string} originalSlug
* @param {boolean} isDryRun
*/
getNextSafeSlug(originalSlug, isDryRun) {
let slug = originalSlug;
let occurenceAccumulator = 0;
if (this.seen.hasOwnProperty(slug)) {
occurenceAccumulator = this.seen[originalSlug];
do {
occurenceAccumulator++;
slug = originalSlug + "-" + occurenceAccumulator;
} while (this.seen.hasOwnProperty(slug));
}
if (!isDryRun) {
this.seen[originalSlug] = occurenceAccumulator;
this.seen[slug] = 0;
}
return slug;
}
/**
* Convert string to unique id
* @param {object} [options]
* @param {boolean} [options.dryrun] Generates the next unique slug without
* updating the internal accumulator.
*/
slug(value, options = {}) {
const slug = this.serialize(value);
return this.getNextSafeSlug(slug, options.dryrun);
}
}
class Parser2 {
constructor(options) {
this.options = options || defaults;
this.options.renderer = this.options.renderer || new Renderer();
this.renderer = this.options.renderer;
this.renderer.options = this.options;
this.textRenderer = new TextRenderer();
this.slugger = new Slugger();
}
/**
* Static Parse Method
*/
static parse(tokens, options) {
const parser = new Parser2(options);
return parser.parse(tokens);
}
/**
* Static Parse Inline Method
*/
static parseInline(tokens, options) {
const parser = new Parser2(options);
return parser.parseInline(tokens);
}
/**
* Parse Loop
*/
parse(tokens, top = true) {
let out = "", i, j, k, l2, l3, row, cell, header, body, token, ordered, start, loose, itemBody, item, checked, task, checkbox, ret;
const l = tokens.length;
for (i = 0; i < l; i++) {
token = tokens[i];
if (this.options.extensions && this.options.extensions.renderers && this.options.extensions.renderers[token.type]) {
ret = this.options.extensions.renderers[token.type].call({ parser: this }, token);
if (ret !== false || !["space", "hr", "heading", "code", "table", "blockquote", "list", "html", "paragraph", "text"].includes(token.type)) {
out += ret || "";
continue;
}
}
switch (token.type) {
case "space": {
continue;
}
case "hr": {
out += this.renderer.hr();
continue;
}
case "heading": {
out += this.renderer.heading(
this.parseInline(token.tokens),
token.depth,
unescape(this.parseInline(token.tokens, this.textRenderer)),
this.slugger
);
continue;
}
case "code": {
out += this.renderer.code(
token.text,
token.lang,
token.escaped
);
continue;
}
case "table": {
header = "";
cell = "";
l2 = token.header.length;
for (j = 0; j < l2; j++) {
cell += this.renderer.tablecell(
this.parseInline(token.header[j].tokens),
{ header: true, align: token.align[j] }
);
}
header += this.renderer.tablerow(cell);
body = "";
l2 = token.rows.length;
for (j = 0; j < l2; j++) {
row = token.rows[j];
cell = "";
l3 = row.length;
for (k = 0; k < l3; k++) {
cell += this.renderer.tablecell(
this.parseInline(row[k].tokens),
{ header: false, align: token.align[k] }
);
}
body += this.renderer.tablerow(cell);
}
out += this.renderer.table(header, body);
continue;
}
case "blockquote": {
body = this.parse(token.tokens);
out += this.renderer.blockquote(body);
continue;
}
case "list": {
ordered = token.ordered;
start = token.start;
loose = token.loose;
l2 = token.items.length;
body = "";
for (j = 0; j < l2; j++) {
item = token.items[j];
checked = item.checked;
task = item.task;
itemBody = "";
if (item.task) {
checkbox = this.renderer.checkbox(checked);
if (loose) {
if (item.tokens.length > 0 && item.tokens[0].type === "paragraph") {
item.tokens[0].text = checkbox + " " + item.tokens[0].text;
if (item.tokens[0].tokens && item.tokens[0].tokens.length > 0 && item.tokens[0].tokens[0].type === "text") {
item.tokens[0].tokens[0].text = checkbox + " " + item.tokens[0].tokens[0].text;
}
} else {
item.tokens.unshift({
type: "text",
text: checkbox
});
}
} else {
itemBody += checkbox;
}
}
itemBody += this.parse(item.tokens, loose);
body += this.renderer.listitem(itemBody, task, checked);
}
out += this.renderer.list(body, ordered, start);
continue;
}
case "html": {
out += this.renderer.html(token.text);
continue;
}
case "paragraph": {
out += this.renderer.paragraph(this.parseInline(token.tokens));
continue;
}
case "text": {
body = token.tokens ? this.parseInline(token.tokens) : token.text;
while (i + 1 < l && tokens[i + 1].type === "text") {
token = tokens[++i];
body += "\n" + (token.tokens ? this.parseInline(token.tokens) : token.text);
}
out += top ? this.renderer.paragraph(body) : body;
continue;
}
default: {
const errMsg = 'Token with "' + token.type + '" type was not found.';
if (this.options.silent) {
console.error(errMsg);
return;
} else {
throw new Error(errMsg);
}
}
}
}
return out;
}
/**
* Parse Inline Tokens
*/
parseInline(tokens, renderer) {
renderer = renderer || this.renderer;
let out = "", i, token, ret;
const l = tokens.length;
for (i = 0; i < l; i++) {
token = tokens[i];
if (this.options.extensions && this.options.extensions.renderers && this.options.extensions.renderers[token.type]) {
ret = this.options.extensions.renderers[token.type].call({ parser: this }, token);
if (ret !== false || !["escape", "html", "link", "image", "strong", "em", "codespan", "br", "del", "text"].includes(token.type)) {
out += ret || "";
continue;
}
}
switch (token.type) {
case "escape": {
out += renderer.text(token.text);
break;
}
case "html": {
out += renderer.html(token.text);
break;
}
case "link": {
out += renderer.link(token.href, token.title, this.parseInline(token.tokens, renderer));
break;
}
case "image": {
out += renderer.image(token.href, token.title, token.text);
break;
}
case "strong": {
out += renderer.strong(this.parseInline(token.tokens, renderer));
break;
}
case "em": {
out += renderer.em(this.parseInline(token.tokens, renderer));
break;
}
case "codespan": {
out += renderer.codespan(token.text);
break;
}
case "br": {
out += renderer.br();
break;
}
case "del": {
out += renderer.del(this.parseInline(token.tokens, renderer));
break;
}
case "text": {
out += renderer.text(token.text);
break;
}
default: {
const errMsg = 'Token with "' + token.type + '" type was not found.';
if (this.options.silent) {
console.error(errMsg);
return;
} else {
throw new Error(errMsg);
}
}
}
}
return out;
}
}
function marked(src, opt, callback) {
if (typeof src === "undefined" || src === null) {
throw new Error("marked(): input parameter is undefined or null");
}
if (typeof src !== "string") {
throw new Error("marked(): input parameter is of type " + Object.prototype.toString.call(src) + ", string expected");
}
if (typeof opt === "function") {
callback = opt;
opt = null;
}
opt = merge({}, marked.defaults, opt || {});
checkSanitizeDeprecation(opt);
if (callback) {
const highlight = opt.highlight;
let tokens;
try {
tokens = Lexer.lex(src, opt);
} catch (e) {
return callback(e);
}
const done = function(err) {
let out;
if (!err) {
try {
if (opt.walkTokens) {
marked.walkTokens(tokens, opt.walkTokens);
}
out = Parser2.parse(tokens, opt);
} catch (e) {
err = e;
}
}
opt.highlight = highlight;
return err ? callback(err) : callback(null, out);
};
if (!highlight || highlight.length < 3) {
return done();
}
delete opt.highlight;
if (!tokens.length)
return done();
let pending = 0;
marked.walkTokens(tokens, function(token) {
if (token.type === "code") {
pending++;
setTimeout(() => {
highlight(token.text, token.lang, function(err, code) {
if (err) {
return done(err);
}
if (code != null && code !== token.text) {
token.text = code;
token.escaped = true;
}
pending--;
if (pending === 0) {
done();
}
});
}, 0);
}
});
if (pending === 0) {
done();
}
return;
}
function onError(e) {
e.message += "\nPlease report this to https://github.com/markedjs/marked.";
if (opt.silent) {
return "<p>An error occurred:</p><pre>" + escape(e.message + "", true) + "</pre>";
}
throw e;
}
try {
const tokens = Lexer.lex(src, opt);
if (opt.walkTokens) {
if (opt.async) {
return Promise.all(marked.walkTokens(tokens, opt.walkTokens)).then(() => {
return Parser2.parse(tokens, opt);
}).catch(onError);
}
marked.walkTokens(tokens, opt.walkTokens);
}
return Parser2.parse(tokens, opt);
} catch (e) {
onError(e);
}
}
marked.options = marked.setOptions = function(opt) {
merge(marked.defaults, opt);
changeDefaults(marked.defaults);
return marked;
};
marked.getDefaults = getDefaults;
marked.defaults = defaults;
marked.use = function(...args) {
const extensions = marked.defaults.extensions || { renderers: {}, childTokens: {} };
args.forEach((pack) => {
const opts = merge({}, pack);
opts.async = marked.defaults.async || opts.async;
if (pack.extensions) {
pack.extensions.forEach((ext) => {
if (!ext.name) {
throw new Error("extension name required");
}
if (ext.renderer) {
const prevRenderer = extensions.renderers[ext.name];
if (prevRenderer) {
extensions.renderers[ext.name] = function(...args2) {
let ret = ext.renderer.apply(this, args2);
if (ret === false) {
ret = prevRenderer.apply(this, args2);
}
return ret;
};
} else {
extensions.renderers[ext.name] = ext.renderer;
}
}
if (ext.tokenizer) {
if (!ext.level || ext.level !== "block" && ext.level !== "inline") {
throw new Error("extension level must be 'block' or 'inline'");
}
if (extensions[ext.level]) {
extensions[ext.level].unshift(ext.tokenizer);
} else {
extensions[ext.level] = [ext.tokenizer];
}
if (ext.start) {
if (ext.level === "block") {
if (extensions.startBlock) {
extensions.startBlock.push(ext.start);
} else {
extensions.startBlock = [ext.start];
}
} else if (ext.level === "inline") {
if (extensions.startInline) {
extensions.startInline.push(ext.start);
} else {
extensions.startInline = [ext.start];
}
}
}
}
if (ext.childTokens) {
extensions.childTokens[ext.name] = ext.childTokens;
}
});
opts.extensions = extensions;
}
if (pack.renderer) {
const renderer = marked.defaults.renderer || new Renderer();
for (const prop in pack.renderer) {
const prevRenderer = renderer[prop];
renderer[prop] = (...args2) => {
let ret = pack.renderer[prop].apply(renderer, args2);
if (ret === false) {
ret = prevRenderer.apply(renderer, args2);
}
return ret;
};
}
opts.renderer = renderer;
}
if (pack.tokenizer) {
const tokenizer = marked.defaults.tokenizer || new Tokenizer();
for (const prop in pack.tokenizer) {
const prevTokenizer = tokenizer[prop];
tokenizer[prop] = (...args2) => {
let ret = pack.tokenizer[prop].apply(tokenizer, args2);
if (ret === false) {
ret = prevTokenizer.apply(tokenizer, args2);
}
return ret;
};
}
opts.tokenizer = tokenizer;
}
if (pack.walkTokens) {
const walkTokens = marked.defaults.walkTokens;
opts.walkTokens = function(token) {
let values = [];
values.push(pack.walkTokens.call(this, token));
if (walkTokens) {
values = values.concat(walkTokens.call(this, token));
}
return values;
};
}
marked.setOptions(opts);
});
};
marked.walkTokens = function(tokens, callback) {
let values = [];
for (const token of tokens) {
values = values.concat(callback.call(marked, token));
switch (token.type) {
case "table": {
for (const cell of token.header) {
values = values.concat(marked.walkTokens(cell.tokens, callback));
}
for (const row of token.rows) {
for (const cell of row) {
values = values.concat(marked.walkTokens(cell.tokens, callback));
}
}
break;
}
case "list": {
values = values.concat(marked.walkTokens(token.items, callback));
break;
}
default: {
if (marked.defaults.extensions && marked.defaults.extensions.childTokens && marked.defaults.extensions.childTokens[token.type]) {
marked.defaults.extensions.childTokens[token.type].forEach(function(childTokens) {
values = values.concat(marked.walkTokens(token[childTokens], callback));
});
} else if (token.tokens) {
values = values.concat(marked.walkTokens(token.tokens, callback));
}
}
}
}
return values;
};
marked.parseInline = function(src, opt) {
if (typeof src === "undefined" || src === null) {
throw new Error("marked.parseInline(): input parameter is undefined or null");
}
if (typeof src !== "string") {
throw new Error("marked.parseInline(): input parameter is of type " + Object.prototype.toString.call(src) + ", string expected");
}
opt = merge({}, marked.defaults, opt || {});
checkSanitizeDeprecation(opt);
try {
const tokens = Lexer.lexInline(src, opt);
if (opt.walkTokens) {
marked.walkTokens(tokens, opt.walkTokens);
}
return Parser2.parseInline(tokens, opt);
} catch (e) {
e.message += "\nPlease report this to https://github.com/markedjs/marked.";
if (opt.silent) {
return "<p>An error occurred:</p><pre>" + escape(e.message + "", true) + "</pre>";
}
throw e;
}
};
marked.Parser = Parser2;
marked.parser = Parser2.parse;
marked.Renderer = Renderer;
marked.TextRenderer = TextRenderer;
marked.Lexer = Lexer;
marked.lexer = Lexer.lex;
marked.Tokenizer = Tokenizer;
marked.Slugger = Slugger;
marked.parse = marked;
marked.options;
marked.setOptions;
marked.use;
marked.walkTokens;
marked.parseInline;
Parser2.parse;
Lexer.lex;
const key = {};
function create_else_block$2(ctx) {
let t;
return {
c() {
t = text(
/*raw*/
ctx[1]
);
},
l(nodes) {
t = claim_text(
nodes,
/*raw*/
ctx[1]
);
},
m(target, anchor) {
insert_hydration(target, t, anchor);
},
p(ctx2, dirty) {
if (dirty & /*raw*/
2)
set_data(
t,
/*raw*/
ctx2[1]
);
},
i: noop,
o: noop,
d(detaching) {
if (detaching)
detach(t);
}
};
}
function create_if_block_5(ctx) {
let h6;
let current;
const default_slot_template = (
/*#slots*/
ctx[5].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[4],
null
);
return {
c() {
h6 = element("h6");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
h6 = claim_element(nodes, "H6", { id: true });
var h6_nodes = children(h6);
if (default_slot)
default_slot.l(h6_nodes);
h6_nodes.forEach(detach);
this.h();
},
h() {
attr(
h6,
"id",
/*id*/
ctx[2]
);
},
m(target, anchor) {
insert_hydration(target, h6, anchor);
if (default_slot) {
default_slot.m(h6, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
16)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[4],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[4]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[4],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*id*/
4) {
attr(
h6,
"id",
/*id*/
ctx2[2]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(h6);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_if_block_4(ctx) {
let h5;
let current;
const default_slot_template = (
/*#slots*/
ctx[5].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[4],
null
);
return {
c() {
h5 = element("h5");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
h5 = claim_element(nodes, "H5", { id: true });
var h5_nodes = children(h5);
if (default_slot)
default_slot.l(h5_nodes);
h5_nodes.forEach(detach);
this.h();
},
h() {
attr(
h5,
"id",
/*id*/
ctx[2]
);
},
m(target, anchor) {
insert_hydration(target, h5, anchor);
if (default_slot) {
default_slot.m(h5, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
16)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[4],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[4]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[4],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*id*/
4) {
attr(
h5,
"id",
/*id*/
ctx2[2]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(h5);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_if_block_3(ctx) {
let h4;
let current;
const default_slot_template = (
/*#slots*/
ctx[5].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[4],
null
);
return {
c() {
h4 = element("h4");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
h4 = claim_element(nodes, "H4", { id: true });
var h4_nodes = children(h4);
if (default_slot)
default_slot.l(h4_nodes);
h4_nodes.forEach(detach);
this.h();
},
h() {
attr(
h4,
"id",
/*id*/
ctx[2]
);
},
m(target, anchor) {
insert_hydration(target, h4, anchor);
if (default_slot) {
default_slot.m(h4, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
16)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[4],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[4]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[4],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*id*/
4) {
attr(
h4,
"id",
/*id*/
ctx2[2]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(h4);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_if_block_2(ctx) {
let h3;
let current;
const default_slot_template = (
/*#slots*/
ctx[5].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[4],
null
);
return {
c() {
h3 = element("h3");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
h3 = claim_element(nodes, "H3", { id: true });
var h3_nodes = children(h3);
if (default_slot)
default_slot.l(h3_nodes);
h3_nodes.forEach(detach);
this.h();
},
h() {
attr(
h3,
"id",
/*id*/
ctx[2]
);
},
m(target, anchor) {
insert_hydration(target, h3, anchor);
if (default_slot) {
default_slot.m(h3, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
16)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[4],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[4]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[4],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*id*/
4) {
attr(
h3,
"id",
/*id*/
ctx2[2]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(h3);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_if_block_1$1(ctx) {
let h2;
let current;
const default_slot_template = (
/*#slots*/
ctx[5].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[4],
null
);
return {
c() {
h2 = element("h2");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
h2 = claim_element(nodes, "H2", { id: true });
var h2_nodes = children(h2);
if (default_slot)
default_slot.l(h2_nodes);
h2_nodes.forEach(detach);
this.h();
},
h() {
attr(
h2,
"id",
/*id*/
ctx[2]
);
},
m(target, anchor) {
insert_hydration(target, h2, anchor);
if (default_slot) {
default_slot.m(h2, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
16)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[4],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[4]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[4],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*id*/
4) {
attr(
h2,
"id",
/*id*/
ctx2[2]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(h2);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_if_block$3(ctx) {
let h1;
let current;
const default_slot_template = (
/*#slots*/
ctx[5].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[4],
null
);
return {
c() {
h1 = element("h1");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
h1 = claim_element(nodes, "H1", { id: true });
var h1_nodes = children(h1);
if (default_slot)
default_slot.l(h1_nodes);
h1_nodes.forEach(detach);
this.h();
},
h() {
attr(
h1,
"id",
/*id*/
ctx[2]
);
},
m(target, anchor) {
insert_hydration(target, h1, anchor);
if (default_slot) {
default_slot.m(h1, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
16)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[4],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[4]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[4],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*id*/
4) {
attr(
h1,
"id",
/*id*/
ctx2[2]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(h1);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_fragment$n(ctx) {
let current_block_type_index;
let if_block;
let if_block_anchor;
let current;
const if_block_creators = [
create_if_block$3,
create_if_block_1$1,
create_if_block_2,
create_if_block_3,
create_if_block_4,
create_if_block_5,
create_else_block$2
];
const if_blocks = [];
function select_block_type(ctx2, dirty) {
if (
/*depth*/
ctx2[0] === 1
)
return 0;
if (
/*depth*/
ctx2[0] === 2
)
return 1;
if (
/*depth*/
ctx2[0] === 3
)
return 2;
if (
/*depth*/
ctx2[0] === 4
)
return 3;
if (
/*depth*/
ctx2[0] === 5
)
return 4;
if (
/*depth*/
ctx2[0] === 6
)
return 5;
return 6;
}
current_block_type_index = select_block_type(ctx);
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx);
return {
c() {
if_block.c();
if_block_anchor = empty();
},
l(nodes) {
if_block.l(nodes);
if_block_anchor = empty();
},
m(target, anchor) {
if_blocks[current_block_type_index].m(target, anchor);
insert_hydration(target, if_block_anchor, anchor);
current = true;
},
p(ctx2, [dirty]) {
let previous_block_index = current_block_type_index;
current_block_type_index = select_block_type(ctx2);
if (current_block_type_index === previous_block_index) {
if_blocks[current_block_type_index].p(ctx2, dirty);
} else {
group_outros();
transition_out(if_blocks[previous_block_index], 1, 1, () => {
if_blocks[previous_block_index] = null;
});
check_outros();
if_block = if_blocks[current_block_type_index];
if (!if_block) {
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx2);
if_block.c();
} else {
if_block.p(ctx2, dirty);
}
transition_in(if_block, 1);
if_block.m(if_block_anchor.parentNode, if_block_anchor);
}
},
i(local) {
if (current)
return;
transition_in(if_block);
current = true;
},
o(local) {
transition_out(if_block);
current = false;
},
d(detaching) {
if_blocks[current_block_type_index].d(detaching);
if (detaching)
detach(if_block_anchor);
}
};
}
function instance$m($$self, $$props, $$invalidate) {
let id;
let { $$slots: slots = {}, $$scope } = $$props;
let { depth } = $$props;
let { raw } = $$props;
let { text: text2 } = $$props;
const { slug, getOptions } = getContext(key);
const options = getOptions();
$$self.$$set = ($$props2) => {
if ("depth" in $$props2)
$$invalidate(0, depth = $$props2.depth);
if ("raw" in $$props2)
$$invalidate(1, raw = $$props2.raw);
if ("text" in $$props2)
$$invalidate(3, text2 = $$props2.text);
if ("$$scope" in $$props2)
$$invalidate(4, $$scope = $$props2.$$scope);
};
$$self.$$.update = () => {
if ($$self.$$.dirty & /*text*/
8) {
$$invalidate(2, id = options.headerIds ? options.headerPrefix + slug(text2) : void 0);
}
};
return [depth, raw, id, text2, $$scope, slots];
}
class Heading extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$m, create_fragment$n, safe_not_equal, { depth: 0, raw: 1, text: 3 });
}
}
function create_fragment$m(ctx) {
let p;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
p = element("p");
if (default_slot)
default_slot.c();
},
l(nodes) {
p = claim_element(nodes, "P", {});
var p_nodes = children(p);
if (default_slot)
default_slot.l(p_nodes);
p_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, p, anchor);
if (default_slot) {
default_slot.m(p, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(p);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$l($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class Paragraph extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$l, create_fragment$m, safe_not_equal, {});
}
}
function create_fragment$l(ctx) {
let current;
const default_slot_template = (
/*#slots*/
ctx[3].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[2],
null
);
return {
c() {
if (default_slot)
default_slot.c();
},
l(nodes) {
if (default_slot)
default_slot.l(nodes);
},
m(target, anchor) {
if (default_slot) {
default_slot.m(target, anchor);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
4)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[2],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[2]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[2],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$k($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
let { text: text2 } = $$props;
let { raw } = $$props;
$$self.$$set = ($$props2) => {
if ("text" in $$props2)
$$invalidate(0, text2 = $$props2.text);
if ("raw" in $$props2)
$$invalidate(1, raw = $$props2.raw);
if ("$$scope" in $$props2)
$$invalidate(2, $$scope = $$props2.$$scope);
};
return [text2, raw, $$scope, slots];
}
class Text extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$k, create_fragment$l, safe_not_equal, { text: 0, raw: 1 });
}
}
function create_fragment$k(ctx) {
let img;
let img_src_value;
return {
c() {
img = element("img");
this.h();
},
l(nodes) {
img = claim_element(nodes, "IMG", { src: true, title: true, alt: true });
this.h();
},
h() {
if (!src_url_equal(img.src, img_src_value = /*href*/
ctx[0]))
attr(img, "src", img_src_value);
attr(
img,
"title",
/*title*/
ctx[1]
);
attr(
img,
"alt",
/*text*/
ctx[2]
);
},
m(target, anchor) {
insert_hydration(target, img, anchor);
},
p(ctx2, [dirty]) {
if (dirty & /*href*/
1 && !src_url_equal(img.src, img_src_value = /*href*/
ctx2[0])) {
attr(img, "src", img_src_value);
}
if (dirty & /*title*/
2) {
attr(
img,
"title",
/*title*/
ctx2[1]
);
}
if (dirty & /*text*/
4) {
attr(
img,
"alt",
/*text*/
ctx2[2]
);
}
},
i: noop,
o: noop,
d(detaching) {
if (detaching)
detach(img);
}
};
}
function instance$j($$self, $$props, $$invalidate) {
let { href = "" } = $$props;
let { title = void 0 } = $$props;
let { text: text2 = "" } = $$props;
$$self.$$set = ($$props2) => {
if ("href" in $$props2)
$$invalidate(0, href = $$props2.href);
if ("title" in $$props2)
$$invalidate(1, title = $$props2.title);
if ("text" in $$props2)
$$invalidate(2, text2 = $$props2.text);
};
return [href, title, text2];
}
class Image extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$j, create_fragment$k, safe_not_equal, { href: 0, title: 1, text: 2 });
}
}
function create_fragment$j(ctx) {
let a;
let current;
const default_slot_template = (
/*#slots*/
ctx[3].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[2],
null
);
return {
c() {
a = element("a");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
a = claim_element(nodes, "A", { href: true, title: true });
var a_nodes = children(a);
if (default_slot)
default_slot.l(a_nodes);
a_nodes.forEach(detach);
this.h();
},
h() {
attr(
a,
"href",
/*href*/
ctx[0]
);
attr(
a,
"title",
/*title*/
ctx[1]
);
},
m(target, anchor) {
insert_hydration(target, a, anchor);
if (default_slot) {
default_slot.m(a, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
4)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[2],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[2]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[2],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*href*/
1) {
attr(
a,
"href",
/*href*/
ctx2[0]
);
}
if (!current || dirty & /*title*/
2) {
attr(
a,
"title",
/*title*/
ctx2[1]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(a);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$i($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
let { href = "" } = $$props;
let { title = void 0 } = $$props;
$$self.$$set = ($$props2) => {
if ("href" in $$props2)
$$invalidate(0, href = $$props2.href);
if ("title" in $$props2)
$$invalidate(1, title = $$props2.title);
if ("$$scope" in $$props2)
$$invalidate(2, $$scope = $$props2.$$scope);
};
return [href, title, $$scope, slots];
}
class Link extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$i, create_fragment$j, safe_not_equal, { href: 0, title: 1 });
}
}
function create_fragment$i(ctx) {
let em;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
em = element("em");
if (default_slot)
default_slot.c();
},
l(nodes) {
em = claim_element(nodes, "EM", {});
var em_nodes = children(em);
if (default_slot)
default_slot.l(em_nodes);
em_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, em, anchor);
if (default_slot) {
default_slot.m(em, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(em);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$h($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class Em extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$h, create_fragment$i, safe_not_equal, {});
}
}
function create_fragment$h(ctx) {
let del;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
del = element("del");
if (default_slot)
default_slot.c();
},
l(nodes) {
del = claim_element(nodes, "DEL", {});
var del_nodes = children(del);
if (default_slot)
default_slot.l(del_nodes);
del_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, del, anchor);
if (default_slot) {
default_slot.m(del, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(del);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$g($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class Del extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$g, create_fragment$h, safe_not_equal, {});
}
}
function create_fragment$g(ctx) {
let code;
let t_value = (
/*raw*/
ctx[0].replace(/`/g, "") + ""
);
let t;
return {
c() {
code = element("code");
t = text(t_value);
},
l(nodes) {
code = claim_element(nodes, "CODE", {});
var code_nodes = children(code);
t = claim_text(code_nodes, t_value);
code_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, code, anchor);
append_hydration(code, t);
},
p(ctx2, [dirty]) {
if (dirty & /*raw*/
1 && t_value !== (t_value = /*raw*/
ctx2[0].replace(/`/g, "") + ""))
set_data(t, t_value);
},
i: noop,
o: noop,
d(detaching) {
if (detaching)
detach(code);
}
};
}
function instance$f($$self, $$props, $$invalidate) {
let { raw } = $$props;
$$self.$$set = ($$props2) => {
if ("raw" in $$props2)
$$invalidate(0, raw = $$props2.raw);
};
return [raw];
}
class Codespan extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$f, create_fragment$g, safe_not_equal, { raw: 0 });
}
}
function create_fragment$f(ctx) {
let strong;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
strong = element("strong");
if (default_slot)
default_slot.c();
},
l(nodes) {
strong = claim_element(nodes, "STRONG", {});
var strong_nodes = children(strong);
if (default_slot)
default_slot.l(strong_nodes);
strong_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, strong, anchor);
if (default_slot) {
default_slot.m(strong, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(strong);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$e($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class Strong extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$e, create_fragment$f, safe_not_equal, {});
}
}
function create_fragment$e(ctx) {
let table;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
table = element("table");
if (default_slot)
default_slot.c();
},
l(nodes) {
table = claim_element(nodes, "TABLE", {});
var table_nodes = children(table);
if (default_slot)
default_slot.l(table_nodes);
table_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, table, anchor);
if (default_slot) {
default_slot.m(table, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(table);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$d($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class Table extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$d, create_fragment$e, safe_not_equal, {});
}
}
function create_fragment$d(ctx) {
let thead;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
thead = element("thead");
if (default_slot)
default_slot.c();
},
l(nodes) {
thead = claim_element(nodes, "THEAD", {});
var thead_nodes = children(thead);
if (default_slot)
default_slot.l(thead_nodes);
thead_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, thead, anchor);
if (default_slot) {
default_slot.m(thead, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(thead);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$c($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class TableHead extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$c, create_fragment$d, safe_not_equal, {});
}
}
function create_fragment$c(ctx) {
let tbody;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
tbody = element("tbody");
if (default_slot)
default_slot.c();
},
l(nodes) {
tbody = claim_element(nodes, "TBODY", {});
var tbody_nodes = children(tbody);
if (default_slot)
default_slot.l(tbody_nodes);
tbody_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, tbody, anchor);
if (default_slot) {
default_slot.m(tbody, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(tbody);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$b($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class TableBody extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$b, create_fragment$c, safe_not_equal, {});
}
}
function create_fragment$b(ctx) {
let tr;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
tr = element("tr");
if (default_slot)
default_slot.c();
},
l(nodes) {
tr = claim_element(nodes, "TR", {});
var tr_nodes = children(tr);
if (default_slot)
default_slot.l(tr_nodes);
tr_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, tr, anchor);
if (default_slot) {
default_slot.m(tr, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(tr);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$a($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class TableRow extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$a, create_fragment$b, safe_not_equal, {});
}
}
function create_else_block$1(ctx) {
let td;
let current;
const default_slot_template = (
/*#slots*/
ctx[3].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[2],
null
);
return {
c() {
td = element("td");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
td = claim_element(nodes, "TD", { align: true });
var td_nodes = children(td);
if (default_slot)
default_slot.l(td_nodes);
td_nodes.forEach(detach);
this.h();
},
h() {
attr(
td,
"align",
/*align*/
ctx[1]
);
},
m(target, anchor) {
insert_hydration(target, td, anchor);
if (default_slot) {
default_slot.m(td, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
4)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[2],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[2]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[2],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*align*/
2) {
attr(
td,
"align",
/*align*/
ctx2[1]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(td);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_if_block$2(ctx) {
let th;
let current;
const default_slot_template = (
/*#slots*/
ctx[3].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[2],
null
);
return {
c() {
th = element("th");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
th = claim_element(nodes, "TH", { align: true });
var th_nodes = children(th);
if (default_slot)
default_slot.l(th_nodes);
th_nodes.forEach(detach);
this.h();
},
h() {
attr(
th,
"align",
/*align*/
ctx[1]
);
},
m(target, anchor) {
insert_hydration(target, th, anchor);
if (default_slot) {
default_slot.m(th, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
4)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[2],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[2]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[2],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*align*/
2) {
attr(
th,
"align",
/*align*/
ctx2[1]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(th);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_fragment$a(ctx) {
let current_block_type_index;
let if_block;
let if_block_anchor;
let current;
const if_block_creators = [create_if_block$2, create_else_block$1];
const if_blocks = [];
function select_block_type(ctx2, dirty) {
if (
/*header*/
ctx2[0]
)
return 0;
return 1;
}
current_block_type_index = select_block_type(ctx);
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx);
return {
c() {
if_block.c();
if_block_anchor = empty();
},
l(nodes) {
if_block.l(nodes);
if_block_anchor = empty();
},
m(target, anchor) {
if_blocks[current_block_type_index].m(target, anchor);
insert_hydration(target, if_block_anchor, anchor);
current = true;
},
p(ctx2, [dirty]) {
let previous_block_index = current_block_type_index;
current_block_type_index = select_block_type(ctx2);
if (current_block_type_index === previous_block_index) {
if_blocks[current_block_type_index].p(ctx2, dirty);
} else {
group_outros();
transition_out(if_blocks[previous_block_index], 1, 1, () => {
if_blocks[previous_block_index] = null;
});
check_outros();
if_block = if_blocks[current_block_type_index];
if (!if_block) {
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx2);
if_block.c();
} else {
if_block.p(ctx2, dirty);
}
transition_in(if_block, 1);
if_block.m(if_block_anchor.parentNode, if_block_anchor);
}
},
i(local) {
if (current)
return;
transition_in(if_block);
current = true;
},
o(local) {
transition_out(if_block);
current = false;
},
d(detaching) {
if_blocks[current_block_type_index].d(detaching);
if (detaching)
detach(if_block_anchor);
}
};
}
function instance$9($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
let { header } = $$props;
let { align } = $$props;
$$self.$$set = ($$props2) => {
if ("header" in $$props2)
$$invalidate(0, header = $$props2.header);
if ("align" in $$props2)
$$invalidate(1, align = $$props2.align);
if ("$$scope" in $$props2)
$$invalidate(2, $$scope = $$props2.$$scope);
};
return [header, align, $$scope, slots];
}
class TableCell extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$9, create_fragment$a, safe_not_equal, { header: 0, align: 1 });
}
}
function create_else_block(ctx) {
let ul;
let current;
const default_slot_template = (
/*#slots*/
ctx[3].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[2],
null
);
return {
c() {
ul = element("ul");
if (default_slot)
default_slot.c();
},
l(nodes) {
ul = claim_element(nodes, "UL", {});
var ul_nodes = children(ul);
if (default_slot)
default_slot.l(ul_nodes);
ul_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, ul, anchor);
if (default_slot) {
default_slot.m(ul, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
4)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[2],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[2]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[2],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(ul);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_if_block$1(ctx) {
let ol;
let current;
const default_slot_template = (
/*#slots*/
ctx[3].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[2],
null
);
return {
c() {
ol = element("ol");
if (default_slot)
default_slot.c();
this.h();
},
l(nodes) {
ol = claim_element(nodes, "OL", { start: true });
var ol_nodes = children(ol);
if (default_slot)
default_slot.l(ol_nodes);
ol_nodes.forEach(detach);
this.h();
},
h() {
attr(
ol,
"start",
/*start*/
ctx[1]
);
},
m(target, anchor) {
insert_hydration(target, ol, anchor);
if (default_slot) {
default_slot.m(ol, null);
}
current = true;
},
p(ctx2, dirty) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
4)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[2],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[2]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[2],
dirty,
null
),
null
);
}
}
if (!current || dirty & /*start*/
2) {
attr(
ol,
"start",
/*start*/
ctx2[1]
);
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(ol);
if (default_slot)
default_slot.d(detaching);
}
};
}
function create_fragment$9(ctx) {
let current_block_type_index;
let if_block;
let if_block_anchor;
let current;
const if_block_creators = [create_if_block$1, create_else_block];
const if_blocks = [];
function select_block_type(ctx2, dirty) {
if (
/*ordered*/
ctx2[0]
)
return 0;
return 1;
}
current_block_type_index = select_block_type(ctx);
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx);
return {
c() {
if_block.c();
if_block_anchor = empty();
},
l(nodes) {
if_block.l(nodes);
if_block_anchor = empty();
},
m(target, anchor) {
if_blocks[current_block_type_index].m(target, anchor);
insert_hydration(target, if_block_anchor, anchor);
current = true;
},
p(ctx2, [dirty]) {
let previous_block_index = current_block_type_index;
current_block_type_index = select_block_type(ctx2);
if (current_block_type_index === previous_block_index) {
if_blocks[current_block_type_index].p(ctx2, dirty);
} else {
group_outros();
transition_out(if_blocks[previous_block_index], 1, 1, () => {
if_blocks[previous_block_index] = null;
});
check_outros();
if_block = if_blocks[current_block_type_index];
if (!if_block) {
if_block = if_blocks[current_block_type_index] = if_block_creators[current_block_type_index](ctx2);
if_block.c();
} else {
if_block.p(ctx2, dirty);
}
transition_in(if_block, 1);
if_block.m(if_block_anchor.parentNode, if_block_anchor);
}
},
i(local) {
if (current)
return;
transition_in(if_block);
current = true;
},
o(local) {
transition_out(if_block);
current = false;
},
d(detaching) {
if_blocks[current_block_type_index].d(detaching);
if (detaching)
detach(if_block_anchor);
}
};
}
function instance$8($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
let { ordered } = $$props;
let { start } = $$props;
$$self.$$set = ($$props2) => {
if ("ordered" in $$props2)
$$invalidate(0, ordered = $$props2.ordered);
if ("start" in $$props2)
$$invalidate(1, start = $$props2.start);
if ("$$scope" in $$props2)
$$invalidate(2, $$scope = $$props2.$$scope);
};
return [ordered, start, $$scope, slots];
}
class List extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$8, create_fragment$9, safe_not_equal, { ordered: 0, start: 1 });
}
}
function create_fragment$8(ctx) {
let li;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
li = element("li");
if (default_slot)
default_slot.c();
},
l(nodes) {
li = claim_element(nodes, "LI", {});
var li_nodes = children(li);
if (default_slot)
default_slot.l(li_nodes);
li_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, li, anchor);
if (default_slot) {
default_slot.m(li, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(li);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$7($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class ListItem extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$7, create_fragment$8, safe_not_equal, {});
}
}
function create_fragment$7(ctx) {
let hr;
return {
c() {
hr = element("hr");
},
l(nodes) {
hr = claim_element(nodes, "HR", {});
},
m(target, anchor) {
insert_hydration(target, hr, anchor);
},
p: noop,
i: noop,
o: noop,
d(detaching) {
if (detaching)
detach(hr);
}
};
}
class Hr extends SvelteComponent {
constructor(options) {
super();
init(this, options, null, create_fragment$7, safe_not_equal, {});
}
}
function create_fragment$6(ctx) {
let html_tag;
let html_anchor;
return {
c() {
html_tag = new HtmlTagHydration(false);
html_anchor = empty();
this.h();
},
l(nodes) {
html_tag = claim_html_tag(nodes, false);
html_anchor = empty();
this.h();
},
h() {
html_tag.a = html_anchor;
},
m(target, anchor) {
html_tag.m(
/*text*/
ctx[0],
target,
anchor
);
insert_hydration(target, html_anchor, anchor);
},
p(ctx2, [dirty]) {
if (dirty & /*text*/
1)
html_tag.p(
/*text*/
ctx2[0]
);
},
i: noop,
o: noop,
d(detaching) {
if (detaching)
detach(html_anchor);
if (detaching)
html_tag.d();
}
};
}
function instance$6($$self, $$props, $$invalidate) {
let { text: text2 } = $$props;
$$self.$$set = ($$props2) => {
if ("text" in $$props2)
$$invalidate(0, text2 = $$props2.text);
};
return [text2];
}
class Html extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$6, create_fragment$6, safe_not_equal, { text: 0 });
}
}
function create_fragment$5(ctx) {
let blockquote;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
blockquote = element("blockquote");
if (default_slot)
default_slot.c();
},
l(nodes) {
blockquote = claim_element(nodes, "BLOCKQUOTE", {});
var blockquote_nodes = children(blockquote);
if (default_slot)
default_slot.l(blockquote_nodes);
blockquote_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, blockquote, anchor);
if (default_slot) {
default_slot.m(blockquote, null);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(blockquote);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$5($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class Blockquote extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$5, create_fragment$5, safe_not_equal, {});
}
}
function create_fragment$4(ctx) {
let pre;
let code;
let t;
return {
c() {
pre = element("pre");
code = element("code");
t = text(
/*text*/
ctx[1]
);
this.h();
},
l(nodes) {
pre = claim_element(nodes, "PRE", { class: true });
var pre_nodes = children(pre);
code = claim_element(pre_nodes, "CODE", {});
var code_nodes = children(code);
t = claim_text(
code_nodes,
/*text*/
ctx[1]
);
code_nodes.forEach(detach);
pre_nodes.forEach(detach);
this.h();
},
h() {
attr(
pre,
"class",
/*lang*/
ctx[0]
);
},
m(target, anchor) {
insert_hydration(target, pre, anchor);
append_hydration(pre, code);
append_hydration(code, t);
},
p(ctx2, [dirty]) {
if (dirty & /*text*/
2)
set_data(
t,
/*text*/
ctx2[1]
);
if (dirty & /*lang*/
1) {
attr(
pre,
"class",
/*lang*/
ctx2[0]
);
}
},
i: noop,
o: noop,
d(detaching) {
if (detaching)
detach(pre);
}
};
}
function instance$4($$self, $$props, $$invalidate) {
let { lang } = $$props;
let { text: text2 } = $$props;
$$self.$$set = ($$props2) => {
if ("lang" in $$props2)
$$invalidate(0, lang = $$props2.lang);
if ("text" in $$props2)
$$invalidate(1, text2 = $$props2.text);
};
return [lang, text2];
}
class Code extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$4, create_fragment$4, safe_not_equal, { lang: 0, text: 1 });
}
}
function create_fragment$3(ctx) {
let br;
let current;
const default_slot_template = (
/*#slots*/
ctx[1].default
);
const default_slot = create_slot(
default_slot_template,
ctx,
/*$$scope*/
ctx[0],
null
);
return {
c() {
br = element("br");
if (default_slot)
default_slot.c();
},
l(nodes) {
br = claim_element(nodes, "BR", {});
if (default_slot)
default_slot.l(nodes);
},
m(target, anchor) {
insert_hydration(target, br, anchor);
if (default_slot) {
default_slot.m(target, anchor);
}
current = true;
},
p(ctx2, [dirty]) {
if (default_slot) {
if (default_slot.p && (!current || dirty & /*$$scope*/
1)) {
update_slot_base(
default_slot,
default_slot_template,
ctx2,
/*$$scope*/
ctx2[0],
!current ? get_all_dirty_from_scope(
/*$$scope*/
ctx2[0]
) : get_slot_changes(
default_slot_template,
/*$$scope*/
ctx2[0],
dirty,
null
),
null
);
}
}
},
i(local) {
if (current)
return;
transition_in(default_slot, local);
current = true;
},
o(local) {
transition_out(default_slot, local);
current = false;
},
d(detaching) {
if (detaching)
detach(br);
if (default_slot)
default_slot.d(detaching);
}
};
}
function instance$3($$self, $$props, $$invalidate) {
let { $$slots: slots = {}, $$scope } = $$props;
$$self.$$set = ($$props2) => {
if ("$$scope" in $$props2)
$$invalidate(0, $$scope = $$props2.$$scope);
};
return [$$scope, slots];
}
class Br extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$3, create_fragment$3, safe_not_equal, {});
}
}
const defaultRenderers = {
heading: Heading,
paragraph: Paragraph,
text: Text,
image: Image,
link: Link,
em: Em,
strong: Strong,
codespan: Codespan,
del: Del,
table: Table,
tablehead: TableHead,
tablebody: TableBody,
tablerow: TableRow,
tablecell: TableCell,
list: List,
orderedlistitem: null,
unorderedlistitem: null,
listitem: ListItem,
hr: Hr,
html: Html,
blockquote: Blockquote,
code: Code,
br: Br
};
const defaultOptions = {
baseUrl: null,
breaks: false,
gfm: true,
headerIds: true,
headerPrefix: "",
highlight: null,
langPrefix: "language-",
mangle: true,
pedantic: false,
renderer: null,
sanitize: false,
sanitizer: null,
silent: false,
smartLists: false,
smartypants: false,
tokenizer: null,
xhtml: false
};
function create_fragment$2(ctx) {
let parser;
let current;
parser = new Parser$1({
props: {
tokens: (
/*tokens*/
ctx[0]
),
renderers: (
/*combinedRenderers*/
ctx[1]
)
}
});
return {
c() {
create_component(parser.$$.fragment);
},
l(nodes) {
claim_component(parser.$$.fragment, nodes);
},
m(target, anchor) {
mount_component(parser, target, anchor);
current = true;
},
p(ctx2, [dirty]) {
const parser_changes = {};
if (dirty & /*tokens*/
1)
parser_changes.tokens = /*tokens*/
ctx2[0];
if (dirty & /*combinedRenderers*/
2)
parser_changes.renderers = /*combinedRenderers*/
ctx2[1];
parser.$set(parser_changes);
},
i(local) {
if (current)
return;
transition_in(parser.$$.fragment, local);
current = true;
},
o(local) {
transition_out(parser.$$.fragment, local);
current = false;
},
d(detaching) {
destroy_component(parser, detaching);
}
};
}
function instance$2($$self, $$props, $$invalidate) {
let preprocessed;
let slugger;
let combinedOptions;
let combinedRenderers;
let { source = [] } = $$props;
let { renderers = {} } = $$props;
let { options = {} } = $$props;
let { isInline = false } = $$props;
const dispatch = createEventDispatcher();
let tokens;
let lexer;
let mounted;
setContext(key, {
slug: (val) => slugger ? slugger.slug(val) : "",
getOptions: () => combinedOptions
});
onMount(() => {
$$invalidate(7, mounted = true);
});
$$self.$$set = ($$props2) => {
if ("source" in $$props2)
$$invalidate(2, source = $$props2.source);
if ("renderers" in $$props2)
$$invalidate(3, renderers = $$props2.renderers);
if ("options" in $$props2)
$$invalidate(4, options = $$props2.options);
if ("isInline" in $$props2)
$$invalidate(5, isInline = $$props2.isInline);
};
$$self.$$.update = () => {
if ($$self.$$.dirty & /*source*/
4) {
$$invalidate(8, preprocessed = Array.isArray(source));
}
if ($$self.$$.dirty & /*source*/
4) {
slugger = source ? new Slugger() : void 0;
}
if ($$self.$$.dirty & /*options*/
16) {
$$invalidate(9, combinedOptions = { ...defaultOptions, ...options });
}
if ($$self.$$.dirty & /*preprocessed, source, combinedOptions, isInline, lexer, tokens*/
869) {
if (preprocessed) {
$$invalidate(0, tokens = source);
} else {
$$invalidate(6, lexer = new Lexer(combinedOptions));
$$invalidate(0, tokens = isInline ? lexer.inlineTokens(source) : lexer.lex(source));
dispatch("parsed", { tokens });
}
}
if ($$self.$$.dirty & /*renderers*/
8) {
$$invalidate(1, combinedRenderers = { ...defaultRenderers, ...renderers });
}
if ($$self.$$.dirty & /*mounted, preprocessed, tokens*/
385) {
mounted && !preprocessed && dispatch("parsed", { tokens });
}
};
return [
tokens,
combinedRenderers,
source,
renderers,
options,
isInline,
lexer,
mounted,
preprocessed,
combinedOptions
];
}
class SvelteMarkdown extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$2, create_fragment$2, safe_not_equal, {
source: 2,
renderers: 3,
options: 4,
isInline: 5
});
}
}
function get_each_context$1(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[4] = list[i];
return child_ctx;
}
function create_each_block$1(ctx) {
let div3;
let div0;
let a0;
let img;
let img_src_value;
let a0_href_value;
let t0;
let div1;
let t1_value = (
/*item*/
ctx[4].name + ""
);
let t1;
let t2;
let div2;
let a1;
let t3;
let t4_value = (
/*item*/
ctx[4].twitter + ""
);
let t4;
let a1_href_value;
let t5;
let div3_class_value;
return {
c() {
div3 = element("div");
div0 = element("div");
a0 = element("a");
img = element("img");
t0 = space();
div1 = element("div");
t1 = text(t1_value);
t2 = space();
div2 = element("div");
a1 = element("a");
t3 = text("@");
t4 = text(t4_value);
t5 = space();
this.h();
},
l(nodes) {
div3 = claim_element(nodes, "DIV", { class: true });
var div3_nodes = children(div3);
div0 = claim_element(div3_nodes, "DIV", {});
var div0_nodes = children(div0);
a0 = claim_element(div0_nodes, "A", { href: true, target: true });
var a0_nodes = children(a0);
img = claim_element(a0_nodes, "IMG", { src: true, class: true });
a0_nodes.forEach(detach);
div0_nodes.forEach(detach);
t0 = claim_space(div3_nodes);
div1 = claim_element(div3_nodes, "DIV", { class: true });
var div1_nodes = children(div1);
t1 = claim_text(div1_nodes, t1_value);
div1_nodes.forEach(detach);
t2 = claim_space(div3_nodes);
div2 = claim_element(div3_nodes, "DIV", { class: true });
var div2_nodes = children(div2);
a1 = claim_element(div2_nodes, "A", { href: true, class: true });
var a1_nodes = children(a1);
t3 = claim_text(a1_nodes, "@");
t4 = claim_text(a1_nodes, t4_value);
a1_nodes.forEach(detach);
div2_nodes.forEach(detach);
t5 = claim_space(div3_nodes);
div3_nodes.forEach(detach);
this.h();
},
h() {
if (!src_url_equal(img.src, img_src_value = "/people/" + /*item*/
ctx[4].img))
attr(img, "src", img_src_value);
attr(img, "class", "grayscale invert aspect-square object-cover");
attr(a0, "href", a0_href_value = twitterLink(
/*item*/
ctx[4].twitter
));
attr(a0, "target", "_blank");
attr(div1, "class", "mt-4");
attr(a1, "href", a1_href_value = twitterLink(
/*item*/
ctx[4].twitter
));
attr(a1, "class", "hover:underline");
attr(div2, "class", "text-base text-mild");
attr(div3, "class", div3_class_value = "hover:bg-white hover:text-black p-2 " + /*size*/
(ctx[1] === "small" ? "w-48" : "w-64") + " person-item");
},
m(target, anchor) {
insert_hydration(target, div3, anchor);
append_hydration(div3, div0);
append_hydration(div0, a0);
append_hydration(a0, img);
append_hydration(div3, t0);
append_hydration(div3, div1);
append_hydration(div1, t1);
append_hydration(div3, t2);
append_hydration(div3, div2);
append_hydration(div2, a1);
append_hydration(a1, t3);
append_hydration(a1, t4);
append_hydration(div3, t5);
},
p(ctx2, dirty) {
if (dirty & /*items*/
1 && !src_url_equal(img.src, img_src_value = "/people/" + /*item*/
ctx2[4].img)) {
attr(img, "src", img_src_value);
}
if (dirty & /*items*/
1 && a0_href_value !== (a0_href_value = twitterLink(
/*item*/
ctx2[4].twitter
))) {
attr(a0, "href", a0_href_value);
}
if (dirty & /*items*/
1 && t1_value !== (t1_value = /*item*/
ctx2[4].name + ""))
set_data(t1, t1_value);
if (dirty & /*items*/
1 && t4_value !== (t4_value = /*item*/
ctx2[4].twitter + ""))
set_data(t4, t4_value);
if (dirty & /*items*/
1 && a1_href_value !== (a1_href_value = twitterLink(
/*item*/
ctx2[4].twitter
))) {
attr(a1, "href", a1_href_value);
}
if (dirty & /*size*/
2 && div3_class_value !== (div3_class_value = "hover:bg-white hover:text-black p-2 " + /*size*/
(ctx2[1] === "small" ? "w-48" : "w-64") + " person-item")) {
attr(div3, "class", div3_class_value);
}
},
d(detaching) {
if (detaching)
detach(div3);
}
};
}
function create_fragment$1(ctx) {
let each_1_anchor;
let each_value = (
/*items*/
ctx[0].map(
/*getPerson*/
ctx[2]
)
);
let each_blocks = [];
for (let i = 0; i < each_value.length; i += 1) {
each_blocks[i] = create_each_block$1(get_each_context$1(ctx, each_value, i));
}
return {
c() {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
each_1_anchor = empty();
},
l(nodes) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(nodes);
}
each_1_anchor = empty();
},
m(target, anchor) {
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(target, anchor);
}
insert_hydration(target, each_1_anchor, anchor);
},
p(ctx2, [dirty]) {
if (dirty & /*size, twitterLink, items, getPerson*/
7) {
each_value = /*items*/
ctx2[0].map(
/*getPerson*/
ctx2[2]
);
let i;
for (i = 0; i < each_value.length; i += 1) {
const child_ctx = get_each_context$1(ctx2, each_value, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
} else {
each_blocks[i] = create_each_block$1(child_ctx);
each_blocks[i].c();
each_blocks[i].m(each_1_anchor.parentNode, each_1_anchor);
}
}
for (; i < each_blocks.length; i += 1) {
each_blocks[i].d(1);
}
each_blocks.length = each_value.length;
}
},
i: noop,
o: noop,
d(detaching) {
destroy_each(each_blocks, detaching);
if (detaching)
detach(each_1_anchor);
}
};
}
function twitterLink(handle) {
return `https://twitter.com/${handle}`;
}
function instance$1($$self, $$props, $$invalidate) {
let { items } = $$props;
let { people } = $$props;
let { size = "normal" } = $$props;
function getPerson(id) {
return people.find((p) => p.id === id);
}
$$self.$$set = ($$props2) => {
if ("items" in $$props2)
$$invalidate(0, items = $$props2.items);
if ("people" in $$props2)
$$invalidate(3, people = $$props2.people);
if ("size" in $$props2)
$$invalidate(1, size = $$props2.size);
};
return [items, size, getPerson, people];
}
class PeopleList extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance$1, create_fragment$1, safe_not_equal, { items: 0, people: 3, size: 1 });
}
}
function get_each_context(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[1] = list[i];
return child_ctx;
}
function get_each_context_1(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[4] = list[i];
return child_ctx;
}
function get_each_context_2(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[7] = list[i];
return child_ctx;
}
function get_each_context_3(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[10] = list[i];
return child_ctx;
}
function get_each_context_4(ctx, list, i) {
const child_ctx = ctx.slice();
child_ctx[7] = list[i];
return child_ctx;
}
function create_each_block_4(ctx) {
let div2;
let div0;
let t0_value = (
/*ti*/
ctx[7].title + ""
);
let t0;
let t1;
let div1;
let sveltemarkdown;
let t2;
let current;
sveltemarkdown = new SvelteMarkdown({ props: { source: (
/*ti*/
ctx[7].desc
) } });
return {
c() {
div2 = element("div");
div0 = element("div");
t0 = text(t0_value);
t1 = space();
div1 = element("div");
create_component(sveltemarkdown.$$.fragment);
t2 = space();
this.h();
},
l(nodes) {
div2 = claim_element(nodes, "DIV", { class: true });
var div2_nodes = children(div2);
div0 = claim_element(div2_nodes, "DIV", { class: true });
var div0_nodes = children(div0);
t0 = claim_text(div0_nodes, t0_value);
div0_nodes.forEach(detach);
t1 = claim_space(div2_nodes);
div1 = claim_element(div2_nodes, "DIV", { class: true });
var div1_nodes = children(div1);
claim_component(sveltemarkdown.$$.fragment, div1_nodes);
div1_nodes.forEach(detach);
t2 = claim_space(div2_nodes);
div2_nodes.forEach(detach);
this.h();
},
h() {
attr(div0, "class", "text-2xl uppercase");
attr(div1, "class", "mt-4 text-lg markdown");
attr(div2, "class", "bg-[#0d1117] hover:text-black hover:bg-white px-4 py-6");
},
m(target, anchor) {
insert_hydration(target, div2, anchor);
append_hydration(div2, div0);
append_hydration(div0, t0);
append_hydration(div2, t1);
append_hydration(div2, div1);
mount_component(sveltemarkdown, div1, null);
append_hydration(div2, t2);
current = true;
},
p(ctx2, dirty) {
if ((!current || dirty & /*data*/
1) && t0_value !== (t0_value = /*ti*/
ctx2[7].title + ""))
set_data(t0, t0_value);
const sveltemarkdown_changes = {};
if (dirty & /*data*/
1)
sveltemarkdown_changes.source = /*ti*/
ctx2[7].desc;
sveltemarkdown.$set(sveltemarkdown_changes);
},
i(local) {
if (current)
return;
transition_in(sveltemarkdown.$$.fragment, local);
current = true;
},
o(local) {
transition_out(sveltemarkdown.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(div2);
destroy_component(sveltemarkdown);
}
};
}
function create_if_block_1(ctx) {
let div;
let sveltemarkdown;
let current;
sveltemarkdown = new SvelteMarkdown({ props: { source: (
/*pi*/
ctx[10].desc
) } });
return {
c() {
div = element("div");
create_component(sveltemarkdown.$$.fragment);
this.h();
},
l(nodes) {
div = claim_element(nodes, "DIV", { class: true });
var div_nodes = children(div);
claim_component(sveltemarkdown.$$.fragment, div_nodes);
div_nodes.forEach(detach);
this.h();
},
h() {
attr(div, "class", "mt-2 text-base description text-mild markdown");
},
m(target, anchor) {
insert_hydration(target, div, anchor);
mount_component(sveltemarkdown, div, null);
current = true;
},
p(ctx2, dirty) {
const sveltemarkdown_changes = {};
if (dirty & /*data*/
1)
sveltemarkdown_changes.source = /*pi*/
ctx2[10].desc;
sveltemarkdown.$set(sveltemarkdown_changes);
},
i(local) {
if (current)
return;
transition_in(sveltemarkdown.$$.fragment, local);
current = true;
},
o(local) {
transition_out(sveltemarkdown.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(div);
destroy_component(sveltemarkdown);
}
};
}
function create_each_block_3(ctx) {
var _a;
let tr;
let td0;
let raw_value = (
/*pi*/
ctx[10].time.split("-").map(func).join('<div class="xl:inline-block hidden mx-1">-</div>') + ""
);
let t0;
let td1;
let div;
let t1_value = (
/*pi*/
ctx[10].title + ""
);
let t1;
let t2;
let t3_value = (
/*pi*/
ctx[10].speakers ? "― " + /*pi*/
((_a = ctx[10].speakers[0]) == null ? void 0 : _a.name) : ""
);
let t3;
let t4;
let t5;
let current;
let if_block = (
/*pi*/
ctx[10].desc && create_if_block_1(ctx)
);
return {
c() {
tr = element("tr");
td0 = element("td");
t0 = space();
td1 = element("td");
div = element("div");
t1 = text(t1_value);
t2 = space();
t3 = text(t3_value);
t4 = space();
if (if_block)
if_block.c();
t5 = space();
this.h();
},
l(nodes) {
tr = claim_element(nodes, "TR", { class: true });
var tr_nodes = children(tr);
td0 = claim_element(tr_nodes, "TD", { class: true });
var td0_nodes = children(td0);
td0_nodes.forEach(detach);
t0 = claim_space(tr_nodes);
td1 = claim_element(tr_nodes, "TD", { class: true });
var td1_nodes = children(td1);
div = claim_element(td1_nodes, "DIV", { class: true });
var div_nodes = children(div);
t1 = claim_text(div_nodes, t1_value);
t2 = claim_space(div_nodes);
t3 = claim_text(div_nodes, t3_value);
div_nodes.forEach(detach);
t4 = claim_space(td1_nodes);
if (if_block)
if_block.l(td1_nodes);
td1_nodes.forEach(detach);
t5 = claim_space(tr_nodes);
tr_nodes.forEach(detach);
this.h();
},
h() {
attr(td0, "class", "text-right time xl:whitespace-nowrap sm:w-16 xl:w-36");
attr(div, "class", "text-xl");
attr(td1, "class", "text-left");
attr(tr, "class", "");
},
m(target, anchor) {
insert_hydration(target, tr, anchor);
append_hydration(tr, td0);
td0.innerHTML = raw_value;
append_hydration(tr, t0);
append_hydration(tr, td1);
append_hydration(td1, div);
append_hydration(div, t1);
append_hydration(div, t2);
append_hydration(div, t3);
append_hydration(td1, t4);
if (if_block)
if_block.m(td1, null);
append_hydration(tr, t5);
current = true;
},
p(ctx2, dirty) {
var _a2;
if ((!current || dirty & /*data*/
1) && raw_value !== (raw_value = /*pi*/
ctx2[10].time.split("-").map(func).join('<div class="xl:inline-block hidden mx-1">-</div>') + ""))
td0.innerHTML = raw_value;
if ((!current || dirty & /*data*/
1) && t1_value !== (t1_value = /*pi*/
ctx2[10].title + ""))
set_data(t1, t1_value);
if ((!current || dirty & /*data*/
1) && t3_value !== (t3_value = /*pi*/
ctx2[10].speakers ? "― " + /*pi*/
((_a2 = ctx2[10].speakers[0]) == null ? void 0 : _a2.name) : ""))
set_data(t3, t3_value);
if (
/*pi*/
ctx2[10].desc
) {
if (if_block) {
if_block.p(ctx2, dirty);
if (dirty & /*data*/
1) {
transition_in(if_block, 1);
}
} else {
if_block = create_if_block_1(ctx2);
if_block.c();
transition_in(if_block, 1);
if_block.m(td1, null);
}
} else if (if_block) {
group_outros();
transition_out(if_block, 1, 1, () => {
if_block = null;
});
check_outros();
}
},
i(local) {
if (current)
return;
transition_in(if_block);
current = true;
},
o(local) {
transition_out(if_block);
current = false;
},
d(detaching) {
if (detaching)
detach(tr);
if (if_block)
if_block.d();
}
};
}
function create_each_block_2(ctx) {
let li;
let t_value = (
/*ti*/
ctx[7] + ""
);
let t;
return {
c() {
li = element("li");
t = text(t_value);
},
l(nodes) {
li = claim_element(nodes, "LI", {});
var li_nodes = children(li);
t = claim_text(li_nodes, t_value);
li_nodes.forEach(detach);
},
m(target, anchor) {
insert_hydration(target, li, anchor);
append_hydration(li, t);
},
p(ctx2, dirty) {
if (dirty & /*data*/
1 && t_value !== (t_value = /*ti*/
ctx2[7] + ""))
set_data(t, t_value);
},
d(detaching) {
if (detaching)
detach(li);
}
};
}
function create_if_block(ctx) {
let div;
let t_value = (
/*tt*/
ctx[4].note + ""
);
let t;
return {
c() {
div = element("div");
t = text(t_value);
this.h();
},
l(nodes) {
div = claim_element(nodes, "DIV", { class: true });
var div_nodes = children(div);
t = claim_text(div_nodes, t_value);
div_nodes.forEach(detach);
this.h();
},
h() {
attr(div, "class", "mt-10 text-base");
},
m(target, anchor) {
insert_hydration(target, div, anchor);
append_hydration(div, t);
},
p(ctx2, dirty) {
if (dirty & /*data*/
1 && t_value !== (t_value = /*tt*/
ctx2[4].note + ""))
set_data(t, t_value);
},
d(detaching) {
if (detaching)
detach(div);
}
};
}
function create_each_block_1(ctx) {
let div2;
let div0;
let t0_value = (
/*tt*/
ctx[4].title + ""
);
let t0;
let t1;
let div1;
let t2_value = (
/*tt*/
ctx[4].price + ""
);
let t2;
let t3;
let ul;
let t4;
let t5;
let each_value_2 = (
/*tt*/
ctx[4].includes
);
let each_blocks = [];
for (let i = 0; i < each_value_2.length; i += 1) {
each_blocks[i] = create_each_block_2(get_each_context_2(ctx, each_value_2, i));
}
let if_block = (
/*tt*/
ctx[4].note && create_if_block(ctx)
);
return {
c() {
div2 = element("div");
div0 = element("div");
t0 = text(t0_value);
t1 = space();
div1 = element("div");
t2 = text(t2_value);
t3 = space();
ul = element("ul");
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
t4 = space();
if (if_block)
if_block.c();
t5 = space();
this.h();
},
l(nodes) {
div2 = claim_element(nodes, "DIV", { class: true });
var div2_nodes = children(div2);
div0 = claim_element(div2_nodes, "DIV", { class: true });
var div0_nodes = children(div0);
t0 = claim_text(div0_nodes, t0_value);
div0_nodes.forEach(detach);
t1 = claim_space(div2_nodes);
div1 = claim_element(div2_nodes, "DIV", { class: true });
var div1_nodes = children(div1);
t2 = claim_text(div1_nodes, t2_value);
div1_nodes.forEach(detach);
t3 = claim_space(div2_nodes);
ul = claim_element(div2_nodes, "UL", { class: true });
var ul_nodes = children(ul);
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(ul_nodes);
}
ul_nodes.forEach(detach);
t4 = claim_space(div2_nodes);
if (if_block)
if_block.l(div2_nodes);
t5 = claim_space(div2_nodes);
div2_nodes.forEach(detach);
this.h();
},
h() {
attr(div0, "class", "text-3xl uppercase");
attr(div1, "class", "text-xl mt-6");
attr(ul, "class", "mt-6 text-lg text-left list-disc px-6");
attr(div2, "class", "bg-[#0d1117] hover:border-0 py-10 px-10 ");
},
m(target, anchor) {
insert_hydration(target, div2, anchor);
append_hydration(div2, div0);
append_hydration(div0, t0);
append_hydration(div2, t1);
append_hydration(div2, div1);
append_hydration(div1, t2);
append_hydration(div2, t3);
append_hydration(div2, ul);
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(ul, null);
}
append_hydration(div2, t4);
if (if_block)
if_block.m(div2, null);
append_hydration(div2, t5);
},
p(ctx2, dirty) {
if (dirty & /*data*/
1 && t0_value !== (t0_value = /*tt*/
ctx2[4].title + ""))
set_data(t0, t0_value);
if (dirty & /*data*/
1 && t2_value !== (t2_value = /*tt*/
ctx2[4].price + ""))
set_data(t2, t2_value);
if (dirty & /*data*/
1) {
each_value_2 = /*tt*/
ctx2[4].includes;
let i;
for (i = 0; i < each_value_2.length; i += 1) {
const child_ctx = get_each_context_2(ctx2, each_value_2, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
} else {
each_blocks[i] = create_each_block_2(child_ctx);
each_blocks[i].c();
each_blocks[i].m(ul, null);
}
}
for (; i < each_blocks.length; i += 1) {
each_blocks[i].d(1);
}
each_blocks.length = each_value_2.length;
}
if (
/*tt*/
ctx2[4].note
) {
if (if_block) {
if_block.p(ctx2, dirty);
} else {
if_block = create_if_block(ctx2);
if_block.c();
if_block.m(div2, t5);
}
} else if (if_block) {
if_block.d(1);
if_block = null;
}
},
d(detaching) {
if (detaching)
detach(div2);
destroy_each(each_blocks, detaching);
if (if_block)
if_block.d();
}
};
}
function create_each_block(ctx) {
let div2;
let div0;
let t0_value = (
/*fi*/
ctx[1].title + ""
);
let t0;
let t1;
let div1;
let sveltemarkdown;
let t2;
let current;
sveltemarkdown = new SvelteMarkdown({ props: { source: (
/*fi*/
ctx[1].text
) } });
return {
c() {
div2 = element("div");
div0 = element("div");
t0 = text(t0_value);
t1 = space();
div1 = element("div");
create_component(sveltemarkdown.$$.fragment);
t2 = space();
this.h();
},
l(nodes) {
div2 = claim_element(nodes, "DIV", { class: true });
var div2_nodes = children(div2);
div0 = claim_element(div2_nodes, "DIV", { class: true });
var div0_nodes = children(div0);
t0 = claim_text(div0_nodes, t0_value);
div0_nodes.forEach(detach);
t1 = claim_space(div2_nodes);
div1 = claim_element(div2_nodes, "DIV", { class: true });
var div1_nodes = children(div1);
claim_component(sveltemarkdown.$$.fragment, div1_nodes);
div1_nodes.forEach(detach);
t2 = claim_space(div2_nodes);
div2_nodes.forEach(detach);
this.h();
},
h() {
attr(div0, "class", "text-2xl font-bold mb-6");
attr(div1, "class", "text-lg markdown");
attr(div2, "class", "py-10 px-4 hover:bg-white hover:text-black");
},
m(target, anchor) {
insert_hydration(target, div2, anchor);
append_hydration(div2, div0);
append_hydration(div0, t0);
append_hydration(div2, t1);
append_hydration(div2, div1);
mount_component(sveltemarkdown, div1, null);
append_hydration(div2, t2);
current = true;
},
p(ctx2, dirty) {
if ((!current || dirty & /*data*/
1) && t0_value !== (t0_value = /*fi*/
ctx2[1].title + ""))
set_data(t0, t0_value);
const sveltemarkdown_changes = {};
if (dirty & /*data*/
1)
sveltemarkdown_changes.source = /*fi*/
ctx2[1].text;
sveltemarkdown.$set(sveltemarkdown_changes);
},
i(local) {
if (current)
return;
transition_in(sveltemarkdown.$$.fragment, local);
current = true;
},
o(local) {
transition_out(sveltemarkdown.$$.fragment, local);
current = false;
},
d(detaching) {
if (detaching)
detach(div2);
destroy_component(sveltemarkdown);
}
};
}
function create_fragment(ctx) {
let title_value;
let t0;
let div4;
let div3;
let div0;
let sveltemarkdown;
let t1;
let div1;
let t2;
let t3;
let div2;
let t4;
let div9;
let div8;
let div5;
let t5;
let t6;
let div7;
let div6;
let peoplelist0;
let t7;
let div14;
let div13;
let div10;
let t8;
let t9;
let div12;
let div11;
let peoplelist1;
let t10;
let div17;
let div16;
let div15;
let t11;
let t12;
let table;
let thead;
let tr;
let th0;
let t13;
let t14;
let th1;
let t15;
let t16;
let tbody;
let t17;
let div21;
let div20;
let div18;
let t18;
let t19;
let div19;
let a;
let button;
let t20;
let t21;
let div27;
let div26;
let div22;
let t22;
let t23;
let div23;
let t24;
let t25;
let div24;
let t26;
let div25;
let t27;
let t28;
let div31;
let div30;
let div28;
let t29;
let t30;
let div29;
let current;
document.title = title_value = /*data*/
ctx[0].config.title + " | " + /*data*/
ctx[0].config.date;
sveltemarkdown = new SvelteMarkdown({
props: { source: (
/*data*/
ctx[0].config.slogan
) }
});
let each_value_4 = (
/*data*/
ctx[0].config.themes
);
let each_blocks_3 = [];
for (let i = 0; i < each_value_4.length; i += 1) {
each_blocks_3[i] = create_each_block_4(get_each_context_4(ctx, each_value_4, i));
}
const out = (i) => transition_out(each_blocks_3[i], 1, 1, () => {
each_blocks_3[i] = null;
});
peoplelist0 = new PeopleList({
props: {
items: (
/*data*/
ctx[0].config.speakers
),
people: (
/*data*/
ctx[0].config.people
)
}
});
peoplelist1 = new PeopleList({
props: {
items: (
/*data*/
ctx[0].config.hosts
),
people: (
/*data*/
ctx[0].config.people
),
size: "small"
}
});
let each_value_3 = (
/*data*/
ctx[0].config.program
);
let each_blocks_2 = [];
for (let i = 0; i < each_value_3.length; i += 1) {
each_blocks_2[i] = create_each_block_3(get_each_context_3(ctx, each_value_3, i));
}
const out_1 = (i) => transition_out(each_blocks_2[i], 1, 1, () => {
each_blocks_2[i] = null;
});
let each_value_1 = (
/*data*/
ctx[0].config.tickets
);
let each_blocks_1 = [];
for (let i = 0; i < each_value_1.length; i += 1) {
each_blocks_1[i] = create_each_block_1(get_each_context_1(ctx, each_value_1, i));
}
let each_value = (
/*data*/
ctx[0].config.faq
);
let each_blocks = [];
for (let i = 0; i < each_value.length; i += 1) {
each_blocks[i] = create_each_block(get_each_context(ctx, each_value, i));
}
const out_2 = (i) => transition_out(each_blocks[i], 1, 1, () => {
each_blocks[i] = null;
});
return {
c() {
t0 = space();
div4 = element("div");
div3 = element("div");
div0 = element("div");
create_component(sveltemarkdown.$$.fragment);
t1 = space();
div1 = element("div");
t2 = text("Key themes");
t3 = space();
div2 = element("div");
for (let i = 0; i < each_blocks_3.length; i += 1) {
each_blocks_3[i].c();
}
t4 = space();
div9 = element("div");
div8 = element("div");
div5 = element("div");
t5 = text("Speakers");
t6 = space();
div7 = element("div");
div6 = element("div");
create_component(peoplelist0.$$.fragment);
t7 = space();
div14 = element("div");
div13 = element("div");
div10 = element("div");
t8 = text("Hosts");
t9 = space();
div12 = element("div");
div11 = element("div");
create_component(peoplelist1.$$.fragment);
t10 = space();
div17 = element("div");
div16 = element("div");
div15 = element("div");
t11 = text("Program");
t12 = space();
table = element("table");
thead = element("thead");
tr = element("tr");
th0 = element("th");
t13 = text("time");
t14 = space();
th1 = element("th");
t15 = text("topic");
t16 = space();
tbody = element("tbody");
for (let i = 0; i < each_blocks_2.length; i += 1) {
each_blocks_2[i].c();
}
t17 = space();
div21 = element("div");
div20 = element("div");
div18 = element("div");
t18 = text("Sponsors");
t19 = space();
div19 = element("div");
a = element("a");
button = element("button");
t20 = text("Become a Sponsor");
t21 = space();
div27 = element("div");
div26 = element("div");
div22 = element("div");
t22 = text("Ticket");
t23 = space();
div23 = element("div");
t24 = text("Be a part of the first Web3Privacy Summit experience…");
t25 = space();
div24 = element("div");
for (let i = 0; i < each_blocks_1.length; i += 1) {
each_blocks_1[i].c();
}
t26 = space();
div25 = element("div");
t27 = text("Tickets will go on sale in early March 2023.");
t28 = space();
div31 = element("div");
div30 = element("div");
div28 = element("div");
t29 = text("FAQ");
t30 = space();
div29 = element("div");
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].c();
}
this.h();
},
l(nodes) {
const head_nodes = head_selector("svelte-17f38t8", document.head);
head_nodes.forEach(detach);
t0 = claim_space(nodes);
div4 = claim_element(nodes, "DIV", { class: true, id: true });
var div4_nodes = children(div4);
div3 = claim_element(div4_nodes, "DIV", { class: true });
var div3_nodes = children(div3);
div0 = claim_element(div3_nodes, "DIV", { class: true });
var div0_nodes = children(div0);
claim_component(sveltemarkdown.$$.fragment, div0_nodes);
div0_nodes.forEach(detach);
t1 = claim_space(div3_nodes);
div1 = claim_element(div3_nodes, "DIV", { class: true });
var div1_nodes = children(div1);
t2 = claim_text(div1_nodes, "Key themes");
div1_nodes.forEach(detach);
t3 = claim_space(div3_nodes);
div2 = claim_element(div3_nodes, "DIV", { class: true });
var div2_nodes = children(div2);
for (let i = 0; i < each_blocks_3.length; i += 1) {
each_blocks_3[i].l(div2_nodes);
}
div2_nodes.forEach(detach);
div3_nodes.forEach(detach);
div4_nodes.forEach(detach);
t4 = claim_space(nodes);
div9 = claim_element(nodes, "DIV", { class: true, id: true });
var div9_nodes = children(div9);
div8 = claim_element(div9_nodes, "DIV", { class: true });
var div8_nodes = children(div8);
div5 = claim_element(div8_nodes, "DIV", { class: true });
var div5_nodes = children(div5);
t5 = claim_text(div5_nodes, "Speakers");
div5_nodes.forEach(detach);
t6 = claim_space(div8_nodes);
div7 = claim_element(div8_nodes, "DIV", { class: true });
var div7_nodes = children(div7);
div6 = claim_element(div7_nodes, "DIV", { class: true });
var div6_nodes = children(div6);
claim_component(peoplelist0.$$.fragment, div6_nodes);
div6_nodes.forEach(detach);
div7_nodes.forEach(detach);
div8_nodes.forEach(detach);
div9_nodes.forEach(detach);
t7 = claim_space(nodes);
div14 = claim_element(nodes, "DIV", { id: true });
var div14_nodes = children(div14);
div13 = claim_element(div14_nodes, "DIV", { class: true });
var div13_nodes = children(div13);
div10 = claim_element(div13_nodes, "DIV", { class: true });
var div10_nodes = children(div10);
t8 = claim_text(div10_nodes, "Hosts");
div10_nodes.forEach(detach);
t9 = claim_space(div13_nodes);
div12 = claim_element(div13_nodes, "DIV", { class: true });
var div12_nodes = children(div12);
div11 = claim_element(div12_nodes, "DIV", { class: true });
var div11_nodes = children(div11);
claim_component(peoplelist1.$$.fragment, div11_nodes);
div11_nodes.forEach(detach);
div12_nodes.forEach(detach);
div13_nodes.forEach(detach);
div14_nodes.forEach(detach);
t10 = claim_space(nodes);
div17 = claim_element(nodes, "DIV", { class: true, id: true });
var div17_nodes = children(div17);
div16 = claim_element(div17_nodes, "DIV", { class: true });
var div16_nodes = children(div16);
div15 = claim_element(div16_nodes, "DIV", { class: true });
var div15_nodes = children(div15);
t11 = claim_text(div15_nodes, "Program");
div15_nodes.forEach(detach);
t12 = claim_space(div16_nodes);
table = claim_element(div16_nodes, "TABLE", { class: true });
var table_nodes = children(table);
thead = claim_element(table_nodes, "THEAD", {});
var thead_nodes = children(thead);
tr = claim_element(thead_nodes, "TR", {});
var tr_nodes = children(tr);
th0 = claim_element(tr_nodes, "TH", { class: true });
var th0_nodes = children(th0);
t13 = claim_text(th0_nodes, "time");
th0_nodes.forEach(detach);
t14 = claim_space(tr_nodes);
th1 = claim_element(tr_nodes, "TH", { class: true });
var th1_nodes = children(th1);
t15 = claim_text(th1_nodes, "topic");
th1_nodes.forEach(detach);
tr_nodes.forEach(detach);
thead_nodes.forEach(detach);
t16 = claim_space(table_nodes);
tbody = claim_element(table_nodes, "TBODY", {});
var tbody_nodes = children(tbody);
for (let i = 0; i < each_blocks_2.length; i += 1) {
each_blocks_2[i].l(tbody_nodes);
}
tbody_nodes.forEach(detach);
table_nodes.forEach(detach);
div16_nodes.forEach(detach);
div17_nodes.forEach(detach);
t17 = claim_space(nodes);
div21 = claim_element(nodes, "DIV", { class: true, id: true });
var div21_nodes = children(div21);
div20 = claim_element(div21_nodes, "DIV", { class: true });
var div20_nodes = children(div20);
div18 = claim_element(div20_nodes, "DIV", { class: true });
var div18_nodes = children(div18);
t18 = claim_text(div18_nodes, "Sponsors");
div18_nodes.forEach(detach);
t19 = claim_space(div20_nodes);
div19 = claim_element(div20_nodes, "DIV", {});
var div19_nodes = children(div19);
a = claim_element(div19_nodes, "A", { href: true, target: true });
var a_nodes = children(a);
button = claim_element(a_nodes, "BUTTON", { class: true });
var button_nodes = children(button);
t20 = claim_text(button_nodes, "Become a Sponsor");
button_nodes.forEach(detach);
a_nodes.forEach(detach);
div19_nodes.forEach(detach);
div20_nodes.forEach(detach);
div21_nodes.forEach(detach);
t21 = claim_space(nodes);
div27 = claim_element(nodes, "DIV", { class: true, id: true });
var div27_nodes = children(div27);
div26 = claim_element(div27_nodes, "DIV", { class: true });
var div26_nodes = children(div26);
div22 = claim_element(div26_nodes, "DIV", { class: true });
var div22_nodes = children(div22);
t22 = claim_text(div22_nodes, "Ticket");
div22_nodes.forEach(detach);
t23 = claim_space(div26_nodes);
div23 = claim_element(div26_nodes, "DIV", { class: true });
var div23_nodes = children(div23);
t24 = claim_text(div23_nodes, "Be a part of the first Web3Privacy Summit experience…");
div23_nodes.forEach(detach);
t25 = claim_space(div26_nodes);
div24 = claim_element(div26_nodes, "DIV", { class: true });
var div24_nodes = children(div24);
for (let i = 0; i < each_blocks_1.length; i += 1) {
each_blocks_1[i].l(div24_nodes);
}
div24_nodes.forEach(detach);
t26 = claim_space(div26_nodes);
div25 = claim_element(div26_nodes, "DIV", { class: true });
var div25_nodes = children(div25);
t27 = claim_text(div25_nodes, "Tickets will go on sale in early March 2023.");
div25_nodes.forEach(detach);
div26_nodes.forEach(detach);
div27_nodes.forEach(detach);
t28 = claim_space(nodes);
div31 = claim_element(nodes, "DIV", { class: true, id: true });
var div31_nodes = children(div31);
div30 = claim_element(div31_nodes, "DIV", { class: true });
var div30_nodes = children(div30);
div28 = claim_element(div30_nodes, "DIV", { class: true });
var div28_nodes = children(div28);
t29 = claim_text(div28_nodes, "FAQ");
div28_nodes.forEach(detach);
t30 = claim_space(div30_nodes);
div29 = claim_element(div30_nodes, "DIV", { class: true });
var div29_nodes = children(div29);
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].l(div29_nodes);
}
div29_nodes.forEach(detach);
div30_nodes.forEach(detach);
div31_nodes.forEach(detach);
this.h();
},
h() {
attr(div0, "class", "py-16 md:py-32 md:w-2/3 mx-auto markdown");
attr(div1, "class", "section-header");
attr(div2, "class", "grid md:grid-cols-3 gap-4 md:gap-10");
attr(div3, "class", "middle-pane-medium pb-16 text-xl text-center mx-auto");
attr(div4, "class", "bg-black");
attr(div4, "id", "about");
attr(div5, "class", "section-header");
attr(div6, "class", "pb-16 flex justify-center sm:gap-6");
attr(div7, "class", "mx-auto");
attr(div8, "class", "middle-pane-medium pt-16 text-xl text-center mx-auto");
attr(div9, "class", "");
attr(div9, "id", "speakers");
attr(div10, "class", "section-header");
attr(div11, "class", "pb-16 flex justify-center sm:gap-6");
attr(div12, "class", "mx-auto");
attr(div13, "class", "middle-pane-medium pt-0 text-xl text-center mx-auto");
attr(div14, "id", "hosts");
attr(div15, "class", "section-header");
attr(th0, "class", "text-right");
attr(th1, "class", "text-left");
attr(table, "class", "table-auto table-custom w-full mx-0 lg:mx-8");
attr(div16, "class", "middle-pane-medium pt-16 text-xl text-center mx-auto pb-32");
attr(div17, "class", "bg-black");
attr(div17, "id", "program");
attr(div18, "class", "section-header");
attr(button, "class", "py-2 px-5 bg-white text-black hover:bg-black border border-bg-white hover:text-white");
attr(a, "href", "https://matrix.to/#/@tree:gwei.cz");
attr(a, "target", "_blank");
attr(div20, "class", "middle-pane-medium pt-16 text-xl text-center mx-auto pb-32");
attr(div21, "class", "");
attr(div21, "id", "sponsors");
attr(div22, "class", "section-header");
attr(div23, "class", "mb-8 text-lg text-mild");
attr(div24, "class", "grid lg:grid-cols-2 gap-10 md:w-2/3 mx-auto");
attr(div25, "class", "mt-8 text-xl");
attr(div26, "class", "middle-pane-medium pt-16 text-xl text-center mx-auto pb-32");
attr(div27, "class", "bg-black");
attr(div27, "id", "ticket");
attr(div28, "class", "section-header");
attr(div29, "class", "grid md:grid-cols-2 gap-2 md:gap-10");
attr(div30, "class", "middle-pane-medium pt-20 text-xl text-center mx-auto");
attr(div31, "class", "mb-36");
attr(div31, "id", "faq");
},
m(target, anchor) {
insert_hydration(target, t0, anchor);
insert_hydration(target, div4, anchor);
append_hydration(div4, div3);
append_hydration(div3, div0);
mount_component(sveltemarkdown, div0, null);
append_hydration(div3, t1);
append_hydration(div3, div1);
append_hydration(div1, t2);
append_hydration(div3, t3);
append_hydration(div3, div2);
for (let i = 0; i < each_blocks_3.length; i += 1) {
each_blocks_3[i].m(div2, null);
}
insert_hydration(target, t4, anchor);
insert_hydration(target, div9, anchor);
append_hydration(div9, div8);
append_hydration(div8, div5);
append_hydration(div5, t5);
append_hydration(div8, t6);
append_hydration(div8, div7);
append_hydration(div7, div6);
mount_component(peoplelist0, div6, null);
insert_hydration(target, t7, anchor);
insert_hydration(target, div14, anchor);
append_hydration(div14, div13);
append_hydration(div13, div10);
append_hydration(div10, t8);
append_hydration(div13, t9);
append_hydration(div13, div12);
append_hydration(div12, div11);
mount_component(peoplelist1, div11, null);
insert_hydration(target, t10, anchor);
insert_hydration(target, div17, anchor);
append_hydration(div17, div16);
append_hydration(div16, div15);
append_hydration(div15, t11);
append_hydration(div16, t12);
append_hydration(div16, table);
append_hydration(table, thead);
append_hydration(thead, tr);
append_hydration(tr, th0);
append_hydration(th0, t13);
append_hydration(tr, t14);
append_hydration(tr, th1);
append_hydration(th1, t15);
append_hydration(table, t16);
append_hydration(table, tbody);
for (let i = 0; i < each_blocks_2.length; i += 1) {
each_blocks_2[i].m(tbody, null);
}
insert_hydration(target, t17, anchor);
insert_hydration(target, div21, anchor);
append_hydration(div21, div20);
append_hydration(div20, div18);
append_hydration(div18, t18);
append_hydration(div20, t19);
append_hydration(div20, div19);
append_hydration(div19, a);
append_hydration(a, button);
append_hydration(button, t20);
insert_hydration(target, t21, anchor);
insert_hydration(target, div27, anchor);
append_hydration(div27, div26);
append_hydration(div26, div22);
append_hydration(div22, t22);
append_hydration(div26, t23);
append_hydration(div26, div23);
append_hydration(div23, t24);
append_hydration(div26, t25);
append_hydration(div26, div24);
for (let i = 0; i < each_blocks_1.length; i += 1) {
each_blocks_1[i].m(div24, null);
}
append_hydration(div26, t26);
append_hydration(div26, div25);
append_hydration(div25, t27);
insert_hydration(target, t28, anchor);
insert_hydration(target, div31, anchor);
append_hydration(div31, div30);
append_hydration(div30, div28);
append_hydration(div28, t29);
append_hydration(div30, t30);
append_hydration(div30, div29);
for (let i = 0; i < each_blocks.length; i += 1) {
each_blocks[i].m(div29, null);
}
current = true;
},
p(ctx2, [dirty]) {
if ((!current || dirty & /*data*/
1) && title_value !== (title_value = /*data*/
ctx2[0].config.title + " | " + /*data*/
ctx2[0].config.date)) {
document.title = title_value;
}
const sveltemarkdown_changes = {};
if (dirty & /*data*/
1)
sveltemarkdown_changes.source = /*data*/
ctx2[0].config.slogan;
sveltemarkdown.$set(sveltemarkdown_changes);
if (dirty & /*data*/
1) {
each_value_4 = /*data*/
ctx2[0].config.themes;
let i;
for (i = 0; i < each_value_4.length; i += 1) {
const child_ctx = get_each_context_4(ctx2, each_value_4, i);
if (each_blocks_3[i]) {
each_blocks_3[i].p(child_ctx, dirty);
transition_in(each_blocks_3[i], 1);
} else {
each_blocks_3[i] = create_each_block_4(child_ctx);
each_blocks_3[i].c();
transition_in(each_blocks_3[i], 1);
each_blocks_3[i].m(div2, null);
}
}
group_outros();
for (i = each_value_4.length; i < each_blocks_3.length; i += 1) {
out(i);
}
check_outros();
}
const peoplelist0_changes = {};
if (dirty & /*data*/
1)
peoplelist0_changes.items = /*data*/
ctx2[0].config.speakers;
if (dirty & /*data*/
1)
peoplelist0_changes.people = /*data*/
ctx2[0].config.people;
peoplelist0.$set(peoplelist0_changes);
const peoplelist1_changes = {};
if (dirty & /*data*/
1)
peoplelist1_changes.items = /*data*/
ctx2[0].config.hosts;
if (dirty & /*data*/
1)
peoplelist1_changes.people = /*data*/
ctx2[0].config.people;
peoplelist1.$set(peoplelist1_changes);
if (dirty & /*data*/
1) {
each_value_3 = /*data*/
ctx2[0].config.program;
let i;
for (i = 0; i < each_value_3.length; i += 1) {
const child_ctx = get_each_context_3(ctx2, each_value_3, i);
if (each_blocks_2[i]) {
each_blocks_2[i].p(child_ctx, dirty);
transition_in(each_blocks_2[i], 1);
} else {
each_blocks_2[i] = create_each_block_3(child_ctx);
each_blocks_2[i].c();
transition_in(each_blocks_2[i], 1);
each_blocks_2[i].m(tbody, null);
}
}
group_outros();
for (i = each_value_3.length; i < each_blocks_2.length; i += 1) {
out_1(i);
}
check_outros();
}
if (dirty & /*data*/
1) {
each_value_1 = /*data*/
ctx2[0].config.tickets;
let i;
for (i = 0; i < each_value_1.length; i += 1) {
const child_ctx = get_each_context_1(ctx2, each_value_1, i);
if (each_blocks_1[i]) {
each_blocks_1[i].p(child_ctx, dirty);
} else {
each_blocks_1[i] = create_each_block_1(child_ctx);
each_blocks_1[i].c();
each_blocks_1[i].m(div24, null);
}
}
for (; i < each_blocks_1.length; i += 1) {
each_blocks_1[i].d(1);
}
each_blocks_1.length = each_value_1.length;
}
if (dirty & /*data*/
1) {
each_value = /*data*/
ctx2[0].config.faq;
let i;
for (i = 0; i < each_value.length; i += 1) {
const child_ctx = get_each_context(ctx2, each_value, i);
if (each_blocks[i]) {
each_blocks[i].p(child_ctx, dirty);
transition_in(each_blocks[i], 1);
} else {
each_blocks[i] = create_each_block(child_ctx);
each_blocks[i].c();
transition_in(each_blocks[i], 1);
each_blocks[i].m(div29, null);
}
}
group_outros();
for (i = each_value.length; i < each_blocks.length; i += 1) {
out_2(i);
}
check_outros();
}
},
i(local) {
if (current)
return;
transition_in(sveltemarkdown.$$.fragment, local);
for (let i = 0; i < each_value_4.length; i += 1) {
transition_in(each_blocks_3[i]);
}
transition_in(peoplelist0.$$.fragment, local);
transition_in(peoplelist1.$$.fragment, local);
for (let i = 0; i < each_value_3.length; i += 1) {
transition_in(each_blocks_2[i]);
}
for (let i = 0; i < each_value.length; i += 1) {
transition_in(each_blocks[i]);
}
current = true;
},
o(local) {
transition_out(sveltemarkdown.$$.fragment, local);
each_blocks_3 = each_blocks_3.filter(Boolean);
for (let i = 0; i < each_blocks_3.length; i += 1) {
transition_out(each_blocks_3[i]);
}
transition_out(peoplelist0.$$.fragment, local);
transition_out(peoplelist1.$$.fragment, local);
each_blocks_2 = each_blocks_2.filter(Boolean);
for (let i = 0; i < each_blocks_2.length; i += 1) {
transition_out(each_blocks_2[i]);
}
each_blocks = each_blocks.filter(Boolean);
for (let i = 0; i < each_blocks.length; i += 1) {
transition_out(each_blocks[i]);
}
current = false;
},
d(detaching) {
if (detaching)
detach(t0);
if (detaching)
detach(div4);
destroy_component(sveltemarkdown);
destroy_each(each_blocks_3, detaching);
if (detaching)
detach(t4);
if (detaching)
detach(div9);
destroy_component(peoplelist0);
if (detaching)
detach(t7);
if (detaching)
detach(div14);
destroy_component(peoplelist1);
if (detaching)
detach(t10);
if (detaching)
detach(div17);
destroy_each(each_blocks_2, detaching);
if (detaching)
detach(t17);
if (detaching)
detach(div21);
if (detaching)
detach(t21);
if (detaching)
detach(div27);
destroy_each(each_blocks_1, detaching);
if (detaching)
detach(t28);
if (detaching)
detach(div31);
destroy_each(each_blocks, detaching);
}
};
}
const func = (x) => x;
function instance($$self, $$props, $$invalidate) {
let { data } = $$props;
$$self.$$set = ($$props2) => {
if ("data" in $$props2)
$$invalidate(0, data = $$props2.data);
};
return [data];
}
class Page extends SvelteComponent {
constructor(options) {
super();
init(this, options, instance, create_fragment, safe_not_equal, { data: 0 });
}
}
export {
Page as default
};