PageSourceSearch

https://tanmayhadke-socratic-ml-tutor.hf.space/assets/Example-CwC21_Sq.js

js tanmayhadke-socratic-ml-tutor.hf.space collected 2026-10-03 17:28:07 UTC 2,292 bytes, 98 lines download raw bytes

1import { p as prop, i as if_block, b as set_class } from './i18n-CGlVUOvE.js';
2import { M as push, a3 as comment, N as first_child, a as append, O as pop, Q as child, $ as set, Z as get, T as reset, t as template_effect, R as from_html, ab as state, a2 as user_derived } from './index-Bq2njFOY.js';
3import { V as Video } from './Video-e9Pn2mbW.js';
4import './snippet-BG7qkY_1.js';
5import './actions-CgRQ2lHA.js';
6
7var root_2 = from_html(`<div><!></div>`);
8
9function Example($$anchor, $$props) {
10	push($$props, true);
11
12	let selected = prop($$props, 'selected', 3, false),
13		value = prop($$props, 'value', 3, null);
14
15	let video = state(void 0);
16
17	async function init() {
18		if (!get(video)) return;
19
20		get(video).muted = true;
21		get(video).playsInline = true;
22		get(video).controls = false;
23		get(video).setAttribute("muted", "");
24		await get(video).play();
25		get(video).pause();
26	}
27
28	var fragment = comment();
29	var node = first_child(fragment);
30
31	{
32		var consequent_1 = ($$anchor) => {
33			var fragment_1 = comment();
34			var node_1 = first_child(fragment_1);
35
36			{
37				var consequent = ($$anchor) => {
38					var div = root_2();
39					let classes;
40					var node_2 = child(div);
41
42					{
43						let $0 = user_derived(() => value()?.url);
44
45						Video(node_2, {
46							muted: true,
47							playsinline: true,
48							onloadeddata: init,
49							onmouseover: () => get(video)?.play(),
50							onmouseout: () => get(video)?.pause(),
51							get src() {
52								return get($0);
53							},
54							is_stream: false,
55							get loop() {
56								return $$props.loop;
57							},
58
59							get node() {
60								return get(video);
61							},
62
63							set node($$value) {
64								set(video, $$value, true);
65							}
66						});
67					}
68
69					reset(div);
70
71					template_effect(() => classes = set_class(div, 1, 'container svelte-1nl1glk', null, classes, {
72						table: $$props.type === "table",
73						gallery: $$props.type === "gallery",
74						selected: selected()
75					}));
76
77					append($$anchor, div);
78				};
79
80				if_block(node_1, ($$render) => {
81					$$render(consequent);
82				});
83			}
84
85			append($$anchor, fragment_1);
86		};
87
88		if_block(node, ($$render) => {
89			if (value()) $$render(consequent_1);
90		});
91	}
92
93	append($$anchor, fragment);
94	pop();
95}
96
97export { Example as default };
98//# sourceMappingURL=Example-CwC21_Sq.js.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.