@pie-players/pie-assessment-toolkit 0.3.57 → 0.3.59
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/dist/components/ItemToolBar.custom-element.js +461 -1082
- package/dist/components/PieAssessmentToolkit.custom-element.js +10 -1
- package/dist/components/SectionToolBar.custom-element.js +459 -1080
- package/dist/context/assessment-toolkit-context.d.ts +7 -0
- package/dist/context/assessment-toolkit-context.js.map +1 -1
- package/dist/runtime/core/engine-resolver.d.ts +16 -0
- package/dist/runtime/core/engine-resolver.js.map +1 -1
- package/package.json +7 -7
- package/dist/components/vendor/nds/README.md +0 -110
- package/dist/components/vendor/nds/nds-icon-button.js +0 -826
|
@@ -4073,6 +4073,23 @@ function if_block(node, fn, elseif = false) {
|
|
|
4073
4073
|
}
|
|
4074
4074
|
// ../../node_modules/.bun/svelte@5.56.0/node_modules/svelte/src/internal/client/dom/blocks/key.js
|
|
4075
4075
|
var NAN = Symbol("NaN");
|
|
4076
|
+
function key(node, get_key, render_fn) {
|
|
4077
|
+
if (hydrating) {
|
|
4078
|
+
hydrate_next();
|
|
4079
|
+
}
|
|
4080
|
+
var branches = new BranchManager(node);
|
|
4081
|
+
var legacy = !is_runes();
|
|
4082
|
+
block(() => {
|
|
4083
|
+
var key2 = get_key();
|
|
4084
|
+
if (key2 !== key2) {
|
|
4085
|
+
key2 = NAN;
|
|
4086
|
+
}
|
|
4087
|
+
if (legacy && key2 !== null && typeof key2 === "object") {
|
|
4088
|
+
key2 = {};
|
|
4089
|
+
}
|
|
4090
|
+
branches.ensure(key2, render_fn);
|
|
4091
|
+
});
|
|
4092
|
+
}
|
|
4076
4093
|
// ../../node_modules/.bun/svelte@5.56.0/node_modules/svelte/src/internal/client/dom/blocks/each.js
|
|
4077
4094
|
function pause_effects(state2, to_destroy, controlled_anchor) {
|
|
4078
4095
|
var transitions = [];
|
|
@@ -4121,8 +4138,8 @@ function destroy_effects(state2, to_destroy, remove_dom = true) {
|
|
|
4121
4138
|
if (state2.pending.size > 0) {
|
|
4122
4139
|
preserved_effects = new Set;
|
|
4123
4140
|
for (const keys of state2.pending.values()) {
|
|
4124
|
-
for (const
|
|
4125
|
-
preserved_effects.add(state2.items.get(
|
|
4141
|
+
for (const key2 of keys) {
|
|
4142
|
+
preserved_effects.add(state2.items.get(key2).e);
|
|
4126
4143
|
}
|
|
4127
4144
|
}
|
|
4128
4145
|
}
|
|
@@ -4208,14 +4225,14 @@ function each(node, flags2, get_collection, get_key, render_fn, fallback_fn = nu
|
|
|
4208
4225
|
set_hydrating(false);
|
|
4209
4226
|
}
|
|
4210
4227
|
var value = array[index];
|
|
4211
|
-
var
|
|
4228
|
+
var key2 = get_key(value, index);
|
|
4212
4229
|
if (true_default) {
|
|
4213
4230
|
var key_again = get_key(value, index);
|
|
4214
|
-
if (
|
|
4215
|
-
each_key_volatile(String(index), String(
|
|
4231
|
+
if (key2 !== key_again) {
|
|
4232
|
+
each_key_volatile(String(index), String(key2), String(key_again));
|
|
4216
4233
|
}
|
|
4217
4234
|
}
|
|
4218
|
-
var item = first_run ? null : items.get(
|
|
4235
|
+
var item = first_run ? null : items.get(key2);
|
|
4219
4236
|
if (item) {
|
|
4220
4237
|
if (item.v)
|
|
4221
4238
|
internal_set(item.v, value);
|
|
@@ -4225,13 +4242,13 @@ function each(node, flags2, get_collection, get_key, render_fn, fallback_fn = nu
|
|
|
4225
4242
|
batch.unskip_effect(item.e);
|
|
4226
4243
|
}
|
|
4227
4244
|
} else {
|
|
4228
|
-
item = create_item(items, first_run ? anchor : offscreen_anchor ??= create_text(), value,
|
|
4245
|
+
item = create_item(items, first_run ? anchor : offscreen_anchor ??= create_text(), value, key2, index, render_fn, flags2, get_collection);
|
|
4229
4246
|
if (!first_run) {
|
|
4230
4247
|
item.e.f |= EFFECT_OFFSCREEN;
|
|
4231
4248
|
}
|
|
4232
|
-
items.set(
|
|
4249
|
+
items.set(key2, item);
|
|
4233
4250
|
}
|
|
4234
|
-
keys.add(
|
|
4251
|
+
keys.add(key2);
|
|
4235
4252
|
}
|
|
4236
4253
|
if (length === 0 && fallback_fn && !fallback) {
|
|
4237
4254
|
if (first_run) {
|
|
@@ -4254,8 +4271,8 @@ function each(node, flags2, get_collection, get_key, render_fn, fallback_fn = nu
|
|
|
4254
4271
|
if (!first_run) {
|
|
4255
4272
|
pending.set(batch, keys);
|
|
4256
4273
|
if (defer) {
|
|
4257
|
-
for (const [
|
|
4258
|
-
if (!keys.has(
|
|
4274
|
+
for (const [key3, item2] of items) {
|
|
4275
|
+
if (!keys.has(key3)) {
|
|
4259
4276
|
batch.skip_effect(item2.e);
|
|
4260
4277
|
}
|
|
4261
4278
|
}
|
|
@@ -4293,14 +4310,14 @@ function reconcile(state2, array, anchor, flags2, get_key) {
|
|
|
4293
4310
|
var matched = [];
|
|
4294
4311
|
var stashed = [];
|
|
4295
4312
|
var value;
|
|
4296
|
-
var
|
|
4313
|
+
var key2;
|
|
4297
4314
|
var effect2;
|
|
4298
4315
|
var i;
|
|
4299
4316
|
if (is_animated) {
|
|
4300
4317
|
for (i = 0;i < length; i += 1) {
|
|
4301
4318
|
value = array[i];
|
|
4302
|
-
|
|
4303
|
-
effect2 = items.get(
|
|
4319
|
+
key2 = get_key(value, i);
|
|
4320
|
+
effect2 = items.get(key2).e;
|
|
4304
4321
|
if ((effect2.f & EFFECT_OFFSCREEN) === 0) {
|
|
4305
4322
|
effect2.nodes?.a?.measure();
|
|
4306
4323
|
(to_animate ??= new Set).add(effect2);
|
|
@@ -4309,8 +4326,8 @@ function reconcile(state2, array, anchor, flags2, get_key) {
|
|
|
4309
4326
|
}
|
|
4310
4327
|
for (i = 0;i < length; i += 1) {
|
|
4311
4328
|
value = array[i];
|
|
4312
|
-
|
|
4313
|
-
effect2 = items.get(
|
|
4329
|
+
key2 = get_key(value, i);
|
|
4330
|
+
effect2 = items.get(key2).e;
|
|
4314
4331
|
if (state2.outrogroups !== null) {
|
|
4315
4332
|
for (const group of state2.outrogroups) {
|
|
4316
4333
|
group.pending.delete(effect2);
|
|
@@ -4446,7 +4463,7 @@ function reconcile(state2, array, anchor, flags2, get_key) {
|
|
|
4446
4463
|
});
|
|
4447
4464
|
}
|
|
4448
4465
|
}
|
|
4449
|
-
function create_item(items, anchor, value,
|
|
4466
|
+
function create_item(items, anchor, value, key2, index, render_fn, flags2, get_collection) {
|
|
4450
4467
|
var v = (flags2 & EACH_ITEM_REACTIVE) !== 0 ? (flags2 & EACH_ITEM_IMMUTABLE) === 0 ? mutable_source(value, false, false) : source(value) : null;
|
|
4451
4468
|
var i = (flags2 & EACH_INDEX_REACTIVE) !== 0 ? source(index) : null;
|
|
4452
4469
|
if (true_default && v) {
|
|
@@ -4460,7 +4477,7 @@ function create_item(items, anchor, value, key, index, render_fn, flags2, get_co
|
|
|
4460
4477
|
e: branch(() => {
|
|
4461
4478
|
render_fn(anchor, v ?? value, i ?? index, get_collection);
|
|
4462
4479
|
return () => {
|
|
4463
|
-
items.delete(
|
|
4480
|
+
items.delete(key2);
|
|
4464
4481
|
};
|
|
4465
4482
|
})
|
|
4466
4483
|
};
|
|
@@ -4496,16 +4513,16 @@ function validate_each_keys(array, key_fn) {
|
|
|
4496
4513
|
const keys = new Map;
|
|
4497
4514
|
const length = array.length;
|
|
4498
4515
|
for (let i = 0;i < length; i++) {
|
|
4499
|
-
const
|
|
4500
|
-
if (keys.has(
|
|
4501
|
-
const a = String(keys.get(
|
|
4516
|
+
const key2 = key_fn(array[i], i);
|
|
4517
|
+
if (keys.has(key2)) {
|
|
4518
|
+
const a = String(keys.get(key2));
|
|
4502
4519
|
const b = String(i);
|
|
4503
|
-
let k = String(
|
|
4520
|
+
let k = String(key2);
|
|
4504
4521
|
if (k.startsWith("[object "))
|
|
4505
4522
|
k = null;
|
|
4506
4523
|
each_key_duplicate(a, b, k);
|
|
4507
4524
|
}
|
|
4508
|
-
keys.set(
|
|
4525
|
+
keys.set(key2, i);
|
|
4509
4526
|
}
|
|
4510
4527
|
}
|
|
4511
4528
|
// ../../node_modules/.bun/svelte@5.56.0/node_modules/svelte/src/internal/client/dom/blocks/html.js
|
|
@@ -4644,13 +4661,13 @@ function to_class(value, hash2, directives) {
|
|
|
4644
4661
|
classname = classname ? classname + " " + hash2 : hash2;
|
|
4645
4662
|
}
|
|
4646
4663
|
if (directives) {
|
|
4647
|
-
for (var
|
|
4648
|
-
if (directives[
|
|
4649
|
-
classname = classname ? classname + " " +
|
|
4664
|
+
for (var key2 of Object.keys(directives)) {
|
|
4665
|
+
if (directives[key2]) {
|
|
4666
|
+
classname = classname ? classname + " " + key2 : key2;
|
|
4650
4667
|
} else if (classname.length) {
|
|
4651
|
-
var len =
|
|
4668
|
+
var len = key2.length;
|
|
4652
4669
|
var a = 0;
|
|
4653
|
-
while ((a = classname.indexOf(
|
|
4670
|
+
while ((a = classname.indexOf(key2, a)) >= 0) {
|
|
4654
4671
|
var b = a + len;
|
|
4655
4672
|
if ((a === 0 || whitespace.includes(classname[a - 1])) && (b === classname.length || whitespace.includes(classname[b]))) {
|
|
4656
4673
|
classname = (a === 0 ? "" : classname.substring(0, a)) + classname.substring(b + 1);
|
|
@@ -4663,6 +4680,99 @@ function to_class(value, hash2, directives) {
|
|
|
4663
4680
|
}
|
|
4664
4681
|
return classname === "" ? null : classname;
|
|
4665
4682
|
}
|
|
4683
|
+
function append_styles2(styles, important = false) {
|
|
4684
|
+
var separator = important ? " !important;" : ";";
|
|
4685
|
+
var css = "";
|
|
4686
|
+
for (var key2 of Object.keys(styles)) {
|
|
4687
|
+
var value = styles[key2];
|
|
4688
|
+
if (value != null && value !== "") {
|
|
4689
|
+
css += " " + key2 + ": " + value + separator;
|
|
4690
|
+
}
|
|
4691
|
+
}
|
|
4692
|
+
return css;
|
|
4693
|
+
}
|
|
4694
|
+
function to_css_name(name) {
|
|
4695
|
+
if (name[0] !== "-" || name[1] !== "-") {
|
|
4696
|
+
return name.toLowerCase();
|
|
4697
|
+
}
|
|
4698
|
+
return name;
|
|
4699
|
+
}
|
|
4700
|
+
function to_style(value, styles) {
|
|
4701
|
+
if (styles) {
|
|
4702
|
+
var new_style = "";
|
|
4703
|
+
var normal_styles;
|
|
4704
|
+
var important_styles;
|
|
4705
|
+
if (Array.isArray(styles)) {
|
|
4706
|
+
normal_styles = styles[0];
|
|
4707
|
+
important_styles = styles[1];
|
|
4708
|
+
} else {
|
|
4709
|
+
normal_styles = styles;
|
|
4710
|
+
}
|
|
4711
|
+
if (value) {
|
|
4712
|
+
value = String(value).replaceAll(/\s*\/\*.*?\*\/\s*/g, "").trim();
|
|
4713
|
+
var in_str = false;
|
|
4714
|
+
var in_apo = 0;
|
|
4715
|
+
var in_comment = false;
|
|
4716
|
+
var reserved_names = [];
|
|
4717
|
+
if (normal_styles) {
|
|
4718
|
+
reserved_names.push(...Object.keys(normal_styles).map(to_css_name));
|
|
4719
|
+
}
|
|
4720
|
+
if (important_styles) {
|
|
4721
|
+
reserved_names.push(...Object.keys(important_styles).map(to_css_name));
|
|
4722
|
+
}
|
|
4723
|
+
var start_index = 0;
|
|
4724
|
+
var name_index = -1;
|
|
4725
|
+
const len = value.length;
|
|
4726
|
+
for (var i = 0;i < len; i++) {
|
|
4727
|
+
var c = value[i];
|
|
4728
|
+
if (in_comment) {
|
|
4729
|
+
if (c === "/" && value[i - 1] === "*") {
|
|
4730
|
+
in_comment = false;
|
|
4731
|
+
}
|
|
4732
|
+
} else if (in_str) {
|
|
4733
|
+
if (in_str === c) {
|
|
4734
|
+
in_str = false;
|
|
4735
|
+
}
|
|
4736
|
+
} else if (c === "/" && value[i + 1] === "*") {
|
|
4737
|
+
in_comment = true;
|
|
4738
|
+
} else if (c === '"' || c === "'") {
|
|
4739
|
+
in_str = c;
|
|
4740
|
+
} else if (c === "(") {
|
|
4741
|
+
in_apo++;
|
|
4742
|
+
} else if (c === ")") {
|
|
4743
|
+
in_apo--;
|
|
4744
|
+
}
|
|
4745
|
+
if (!in_comment && in_str === false && in_apo === 0) {
|
|
4746
|
+
if (c === ":" && name_index === -1) {
|
|
4747
|
+
name_index = i;
|
|
4748
|
+
} else if (c === ";" || i === len - 1) {
|
|
4749
|
+
if (name_index !== -1) {
|
|
4750
|
+
var name = to_css_name(value.substring(start_index, name_index).trim());
|
|
4751
|
+
if (!reserved_names.includes(name)) {
|
|
4752
|
+
if (c !== ";") {
|
|
4753
|
+
i++;
|
|
4754
|
+
}
|
|
4755
|
+
var property = value.substring(start_index, i).trim();
|
|
4756
|
+
new_style += " " + property + ";";
|
|
4757
|
+
}
|
|
4758
|
+
}
|
|
4759
|
+
start_index = i + 1;
|
|
4760
|
+
name_index = -1;
|
|
4761
|
+
}
|
|
4762
|
+
}
|
|
4763
|
+
}
|
|
4764
|
+
}
|
|
4765
|
+
if (normal_styles) {
|
|
4766
|
+
new_style += append_styles2(normal_styles);
|
|
4767
|
+
}
|
|
4768
|
+
if (important_styles) {
|
|
4769
|
+
new_style += append_styles2(important_styles, true);
|
|
4770
|
+
}
|
|
4771
|
+
new_style = new_style.trim();
|
|
4772
|
+
return new_style === "" ? null : new_style;
|
|
4773
|
+
}
|
|
4774
|
+
return value == null ? null : String(value);
|
|
4775
|
+
}
|
|
4666
4776
|
|
|
4667
4777
|
// ../../node_modules/.bun/svelte@5.56.0/node_modules/svelte/src/internal/client/dom/elements/class.js
|
|
4668
4778
|
function set_class(dom, is_html, value, hash2, prev_classes, next_classes) {
|
|
@@ -4680,16 +4790,52 @@ function set_class(dom, is_html, value, hash2, prev_classes, next_classes) {
|
|
|
4680
4790
|
}
|
|
4681
4791
|
dom[CLASS_CACHE] = value;
|
|
4682
4792
|
} else if (next_classes && prev_classes !== next_classes) {
|
|
4683
|
-
for (var
|
|
4684
|
-
var is_present = !!next_classes[
|
|
4685
|
-
if (prev_classes == null || is_present !== !!prev_classes[
|
|
4686
|
-
dom.classList.toggle(
|
|
4793
|
+
for (var key2 in next_classes) {
|
|
4794
|
+
var is_present = !!next_classes[key2];
|
|
4795
|
+
if (prev_classes == null || is_present !== !!prev_classes[key2]) {
|
|
4796
|
+
dom.classList.toggle(key2, is_present);
|
|
4687
4797
|
}
|
|
4688
4798
|
}
|
|
4689
4799
|
}
|
|
4690
4800
|
return next_classes;
|
|
4691
4801
|
}
|
|
4692
4802
|
|
|
4803
|
+
// ../../node_modules/.bun/svelte@5.56.0/node_modules/svelte/src/internal/client/dom/elements/style.js
|
|
4804
|
+
function update_styles(dom, prev = {}, next2, priority) {
|
|
4805
|
+
for (var key2 in next2) {
|
|
4806
|
+
var value = next2[key2];
|
|
4807
|
+
if (prev[key2] !== value) {
|
|
4808
|
+
if (next2[key2] == null) {
|
|
4809
|
+
dom.style.removeProperty(key2);
|
|
4810
|
+
} else {
|
|
4811
|
+
dom.style.setProperty(key2, value, priority);
|
|
4812
|
+
}
|
|
4813
|
+
}
|
|
4814
|
+
}
|
|
4815
|
+
}
|
|
4816
|
+
function set_style(dom, value, prev_styles, next_styles) {
|
|
4817
|
+
var prev = dom[STYLE_CACHE];
|
|
4818
|
+
if (hydrating || prev !== value) {
|
|
4819
|
+
var next_style_attr = to_style(value, next_styles);
|
|
4820
|
+
if (!hydrating || next_style_attr !== dom.getAttribute("style")) {
|
|
4821
|
+
if (next_style_attr == null) {
|
|
4822
|
+
dom.removeAttribute("style");
|
|
4823
|
+
} else {
|
|
4824
|
+
dom.style.cssText = next_style_attr;
|
|
4825
|
+
}
|
|
4826
|
+
}
|
|
4827
|
+
dom[STYLE_CACHE] = value;
|
|
4828
|
+
} else if (next_styles) {
|
|
4829
|
+
if (Array.isArray(next_styles)) {
|
|
4830
|
+
update_styles(dom, prev_styles?.[0], next_styles[0]);
|
|
4831
|
+
update_styles(dom, prev_styles?.[1], next_styles[1], "important");
|
|
4832
|
+
} else {
|
|
4833
|
+
update_styles(dom, prev_styles, next_styles);
|
|
4834
|
+
}
|
|
4835
|
+
}
|
|
4836
|
+
return next_styles;
|
|
4837
|
+
}
|
|
4838
|
+
|
|
4693
4839
|
// ../../node_modules/.bun/svelte@5.56.0/node_modules/svelte/src/internal/client/dom/elements/attributes.js
|
|
4694
4840
|
var CLASS = Symbol("class");
|
|
4695
4841
|
var STYLE = Symbol("style");
|
|
@@ -4720,6 +4866,29 @@ function set_attribute2(element, attribute, value, skip_warning) {
|
|
|
4720
4866
|
element.setAttribute(attribute, value);
|
|
4721
4867
|
}
|
|
4722
4868
|
}
|
|
4869
|
+
function set_custom_element_data(node, prop, value) {
|
|
4870
|
+
var previous_reaction = active_reaction;
|
|
4871
|
+
var previous_effect = active_effect;
|
|
4872
|
+
let was_hydrating = hydrating;
|
|
4873
|
+
if (hydrating) {
|
|
4874
|
+
set_hydrating(false);
|
|
4875
|
+
}
|
|
4876
|
+
set_active_reaction(null);
|
|
4877
|
+
set_active_effect(null);
|
|
4878
|
+
try {
|
|
4879
|
+
if (prop !== "style" && (setters_cache.has(node.getAttribute("is") || node.nodeName) || !customElements || customElements.get(node.getAttribute("is") || node.nodeName.toLowerCase()) ? get_setters(node).includes(prop) : value && typeof value === "object")) {
|
|
4880
|
+
node[prop] = value;
|
|
4881
|
+
} else {
|
|
4882
|
+
set_attribute2(node, prop, value == null ? value : String(value));
|
|
4883
|
+
}
|
|
4884
|
+
} finally {
|
|
4885
|
+
set_active_reaction(previous_reaction);
|
|
4886
|
+
set_active_effect(previous_effect);
|
|
4887
|
+
if (was_hydrating) {
|
|
4888
|
+
set_hydrating(true);
|
|
4889
|
+
}
|
|
4890
|
+
}
|
|
4891
|
+
}
|
|
4723
4892
|
function get_attributes(element) {
|
|
4724
4893
|
return element[ATTRIBUTES_CACHE] ??= {
|
|
4725
4894
|
[IS_CUSTOM_ELEMENT]: element.nodeName.includes("-"),
|
|
@@ -4738,9 +4907,9 @@ function get_setters(element) {
|
|
|
4738
4907
|
var element_proto = Element.prototype;
|
|
4739
4908
|
while (element_proto !== proto) {
|
|
4740
4909
|
descriptors = get_descriptors(proto);
|
|
4741
|
-
for (var
|
|
4742
|
-
if (descriptors[
|
|
4743
|
-
setters.push(
|
|
4910
|
+
for (var key2 in descriptors) {
|
|
4911
|
+
if (descriptors[key2].set && key2 !== "innerHTML" && key2 !== "textContent" && key2 !== "innerText") {
|
|
4912
|
+
setters.push(key2);
|
|
4744
4913
|
}
|
|
4745
4914
|
}
|
|
4746
4915
|
proto = get_prototype_of(proto);
|
|
@@ -4847,7 +5016,7 @@ function bind_this(element_or_component = {}, update2, get_value, get_parts) {
|
|
|
4847
5016
|
return element_or_component;
|
|
4848
5017
|
}
|
|
4849
5018
|
// ../../node_modules/.bun/svelte@5.56.0/node_modules/svelte/src/internal/client/reactivity/props.js
|
|
4850
|
-
function prop(props,
|
|
5019
|
+
function prop(props, key2, flags2, fallback) {
|
|
4851
5020
|
var runes = !legacy_mode_flag || (flags2 & PROPS_IS_RUNES) !== 0;
|
|
4852
5021
|
var bindable = (flags2 & PROPS_IS_BINDABLE) !== 0;
|
|
4853
5022
|
var lazy = (flags2 & PROPS_IS_LAZY_INITIAL) !== 0;
|
|
@@ -4868,27 +5037,27 @@ function prop(props, key, flags2, fallback) {
|
|
|
4868
5037
|
let setter;
|
|
4869
5038
|
if (bindable) {
|
|
4870
5039
|
var is_entry_props = STATE_SYMBOL in props || LEGACY_PROPS in props;
|
|
4871
|
-
setter = get_descriptor(props,
|
|
5040
|
+
setter = get_descriptor(props, key2)?.set ?? (is_entry_props && key2 in props ? (v) => props[key2] = v : undefined);
|
|
4872
5041
|
}
|
|
4873
5042
|
var initial_value;
|
|
4874
5043
|
var is_store_sub = false;
|
|
4875
5044
|
if (bindable) {
|
|
4876
|
-
[initial_value, is_store_sub] = capture_store_binding(() => props[
|
|
5045
|
+
[initial_value, is_store_sub] = capture_store_binding(() => props[key2]);
|
|
4877
5046
|
} else {
|
|
4878
|
-
initial_value = props[
|
|
5047
|
+
initial_value = props[key2];
|
|
4879
5048
|
}
|
|
4880
5049
|
if (initial_value === undefined && fallback !== undefined) {
|
|
4881
5050
|
initial_value = get_fallback();
|
|
4882
5051
|
if (setter) {
|
|
4883
5052
|
if (runes)
|
|
4884
|
-
props_invalid_value(
|
|
5053
|
+
props_invalid_value(key2);
|
|
4885
5054
|
setter(initial_value);
|
|
4886
5055
|
}
|
|
4887
5056
|
}
|
|
4888
5057
|
var getter;
|
|
4889
5058
|
if (runes) {
|
|
4890
5059
|
getter = () => {
|
|
4891
|
-
var value = props[
|
|
5060
|
+
var value = props[key2];
|
|
4892
5061
|
if (value === undefined)
|
|
4893
5062
|
return get_fallback();
|
|
4894
5063
|
fallback_dirty = true;
|
|
@@ -4896,7 +5065,7 @@ function prop(props, key, flags2, fallback) {
|
|
|
4896
5065
|
};
|
|
4897
5066
|
} else {
|
|
4898
5067
|
getter = () => {
|
|
4899
|
-
var value = props[
|
|
5068
|
+
var value = props[key2];
|
|
4900
5069
|
if (value !== undefined) {
|
|
4901
5070
|
fallback_value = undefined;
|
|
4902
5071
|
}
|
|
@@ -4924,7 +5093,7 @@ function prop(props, key, flags2, fallback) {
|
|
|
4924
5093
|
return getter();
|
|
4925
5094
|
});
|
|
4926
5095
|
if (true_default) {
|
|
4927
|
-
d.label =
|
|
5096
|
+
d.label = key2;
|
|
4928
5097
|
}
|
|
4929
5098
|
if (bindable)
|
|
4930
5099
|
get2(d);
|
|
@@ -4954,9 +5123,9 @@ class Svelte4Component {
|
|
|
4954
5123
|
#instance;
|
|
4955
5124
|
constructor(options) {
|
|
4956
5125
|
var sources = new Map;
|
|
4957
|
-
var add_source = (
|
|
5126
|
+
var add_source = (key2, value) => {
|
|
4958
5127
|
var s = mutable_source(value, false, false);
|
|
4959
|
-
sources.set(
|
|
5128
|
+
sources.set(key2, s);
|
|
4960
5129
|
return s;
|
|
4961
5130
|
};
|
|
4962
5131
|
const props = new Proxy({ ...options.props || {}, $$events: {} }, {
|
|
@@ -4987,15 +5156,15 @@ class Svelte4Component {
|
|
|
4987
5156
|
flushSync();
|
|
4988
5157
|
}
|
|
4989
5158
|
this.#events = props.$$events;
|
|
4990
|
-
for (const
|
|
4991
|
-
if (
|
|
5159
|
+
for (const key2 of Object.keys(this.#instance)) {
|
|
5160
|
+
if (key2 === "$set" || key2 === "$destroy" || key2 === "$on")
|
|
4992
5161
|
continue;
|
|
4993
|
-
define_property(this,
|
|
5162
|
+
define_property(this, key2, {
|
|
4994
5163
|
get() {
|
|
4995
|
-
return this.#instance[
|
|
5164
|
+
return this.#instance[key2];
|
|
4996
5165
|
},
|
|
4997
5166
|
set(value) {
|
|
4998
|
-
this.#instance[
|
|
5167
|
+
this.#instance[key2] = value;
|
|
4999
5168
|
},
|
|
5000
5169
|
enumerable: true
|
|
5001
5170
|
});
|
|
@@ -5098,10 +5267,10 @@ if (typeof HTMLElement === "function") {
|
|
|
5098
5267
|
this.$$d[name] = get_custom_element_value(name, attribute.value, this.$$p_d, "toProp");
|
|
5099
5268
|
}
|
|
5100
5269
|
}
|
|
5101
|
-
for (const
|
|
5102
|
-
if (!(
|
|
5103
|
-
this.$$d[
|
|
5104
|
-
delete this[
|
|
5270
|
+
for (const key2 in this.$$p_d) {
|
|
5271
|
+
if (!(key2 in this.$$d) && this[key2] !== undefined) {
|
|
5272
|
+
this.$$d[key2] = this[key2];
|
|
5273
|
+
delete this[key2];
|
|
5105
5274
|
}
|
|
5106
5275
|
}
|
|
5107
5276
|
this.$$c = createClassComponent({
|
|
@@ -5116,15 +5285,15 @@ if (typeof HTMLElement === "function") {
|
|
|
5116
5285
|
this.$$me = effect_root(() => {
|
|
5117
5286
|
render_effect(() => {
|
|
5118
5287
|
this.$$r = true;
|
|
5119
|
-
for (const
|
|
5120
|
-
if (!this.$$p_d[
|
|
5288
|
+
for (const key2 of object_keys(this.$$c)) {
|
|
5289
|
+
if (!this.$$p_d[key2]?.reflect)
|
|
5121
5290
|
continue;
|
|
5122
|
-
this.$$d[
|
|
5123
|
-
const attribute_value = get_custom_element_value(
|
|
5291
|
+
this.$$d[key2] = this.$$c[key2];
|
|
5292
|
+
const attribute_value = get_custom_element_value(key2, this.$$d[key2], this.$$p_d, "toAttribute");
|
|
5124
5293
|
if (attribute_value == null) {
|
|
5125
|
-
this.removeAttribute(this.$$p_d[
|
|
5294
|
+
this.removeAttribute(this.$$p_d[key2].attribute || key2);
|
|
5126
5295
|
} else {
|
|
5127
|
-
this.setAttribute(this.$$p_d[
|
|
5296
|
+
this.setAttribute(this.$$p_d[key2].attribute || key2, attribute_value);
|
|
5128
5297
|
}
|
|
5129
5298
|
}
|
|
5130
5299
|
this.$$r = false;
|
|
@@ -5157,7 +5326,7 @@ if (typeof HTMLElement === "function") {
|
|
|
5157
5326
|
});
|
|
5158
5327
|
}
|
|
5159
5328
|
$$g_p(attribute_name) {
|
|
5160
|
-
return object_keys(this.$$p_d).find((
|
|
5329
|
+
return object_keys(this.$$p_d).find((key2) => this.$$p_d[key2].attribute === attribute_name || !this.$$p_d[key2].attribute && key2.toLowerCase() === attribute_name) || attribute_name;
|
|
5161
5330
|
}
|
|
5162
5331
|
};
|
|
5163
5332
|
}
|
|
@@ -5206,7 +5375,7 @@ function create_custom_element(Component, props_definition, slots, exports, shad
|
|
|
5206
5375
|
this.$$p_d = props_definition;
|
|
5207
5376
|
}
|
|
5208
5377
|
static get observedAttributes() {
|
|
5209
|
-
return object_keys(props_definition).map((
|
|
5378
|
+
return object_keys(props_definition).map((key2) => (props_definition[key2].attribute || key2).toLowerCase());
|
|
5210
5379
|
}
|
|
5211
5380
|
};
|
|
5212
5381
|
object_keys(props_definition).forEach((prop2) => {
|
|
@@ -5332,6 +5501,11 @@ function isExternalIconUrl(icon) {
|
|
|
5332
5501
|
|
|
5333
5502
|
// dist/components/.ItemToolBar.custom-element.unbundled.js
|
|
5334
5503
|
import { sanitizeSvgIcon } from "@pie-players/pie-players-shared/security";
|
|
5504
|
+
import {
|
|
5505
|
+
approximateZoomFromWidths,
|
|
5506
|
+
computeZoomCompensation,
|
|
5507
|
+
ICON_BUTTON_ZOOM_OPTIONS
|
|
5508
|
+
} from "@pie-players/pie-players-shared/ui/zoom-compensation";
|
|
5335
5509
|
import {
|
|
5336
5510
|
createFocusTrap,
|
|
5337
5511
|
FOCUSABLE_SELECTOR,
|
|
@@ -7805,880 +7979,8 @@ function createPackagedToolRegistry(options = {}) {
|
|
|
7805
7979
|
});
|
|
7806
7980
|
}
|
|
7807
7981
|
|
|
7808
|
-
// dist/components/vendor/nds/nds-icon-button.js
|
|
7809
|
-
var H = globalThis;
|
|
7810
|
-
var D = H.ShadowRoot && (H.ShadyCSS === undefined || H.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype;
|
|
7811
|
-
var tt = Symbol();
|
|
7812
|
-
var W = /* @__PURE__ */ new WeakMap;
|
|
7813
|
-
var nt = class {
|
|
7814
|
-
constructor(t, e, s) {
|
|
7815
|
-
if (this._$cssResult$ = true, s !== tt)
|
|
7816
|
-
throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
7817
|
-
this.cssText = t, this.t = e;
|
|
7818
|
-
}
|
|
7819
|
-
get styleSheet() {
|
|
7820
|
-
let t = this.o;
|
|
7821
|
-
const e = this.t;
|
|
7822
|
-
if (D && t === undefined) {
|
|
7823
|
-
const s = e !== undefined && e.length === 1;
|
|
7824
|
-
s && (t = W.get(e)), t === undefined && ((this.o = t = new CSSStyleSheet).replaceSync(this.cssText), s && W.set(e, t));
|
|
7825
|
-
}
|
|
7826
|
-
return t;
|
|
7827
|
-
}
|
|
7828
|
-
toString() {
|
|
7829
|
-
return this.cssText;
|
|
7830
|
-
}
|
|
7831
|
-
};
|
|
7832
|
-
var rt = (o) => new nt(typeof o == "string" ? o : o + "", undefined, tt);
|
|
7833
|
-
var at = (o, t) => {
|
|
7834
|
-
if (D)
|
|
7835
|
-
o.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet);
|
|
7836
|
-
else
|
|
7837
|
-
for (const e of t) {
|
|
7838
|
-
const s = document.createElement("style"), i = H.litNonce;
|
|
7839
|
-
i !== undefined && s.setAttribute("nonce", i), s.textContent = e.cssText, o.appendChild(s);
|
|
7840
|
-
}
|
|
7841
|
-
};
|
|
7842
|
-
var V = D ? (o) => o : (o) => o instanceof CSSStyleSheet ? ((t) => {
|
|
7843
|
-
let e = "";
|
|
7844
|
-
for (const s of t.cssRules)
|
|
7845
|
-
e += s.cssText;
|
|
7846
|
-
return rt(e);
|
|
7847
|
-
})(o) : o;
|
|
7848
|
-
var { is: ht, defineProperty: ct, getOwnPropertyDescriptor: lt, getOwnPropertyNames: dt, getOwnPropertySymbols: ut, getPrototypeOf: pt } = Object;
|
|
7849
|
-
var R = globalThis;
|
|
7850
|
-
var F = R.trustedTypes;
|
|
7851
|
-
var ft = F ? F.emptyScript : "";
|
|
7852
|
-
var bt = R.reactiveElementPolyfillSupport;
|
|
7853
|
-
var S = (o, t) => o;
|
|
7854
|
-
var N = { toAttribute(o, t) {
|
|
7855
|
-
switch (t) {
|
|
7856
|
-
case Boolean:
|
|
7857
|
-
o = o ? ft : null;
|
|
7858
|
-
break;
|
|
7859
|
-
case Object:
|
|
7860
|
-
case Array:
|
|
7861
|
-
o = o == null ? o : JSON.stringify(o);
|
|
7862
|
-
}
|
|
7863
|
-
return o;
|
|
7864
|
-
}, fromAttribute(o, t) {
|
|
7865
|
-
let e = o;
|
|
7866
|
-
switch (t) {
|
|
7867
|
-
case Boolean:
|
|
7868
|
-
e = o !== null;
|
|
7869
|
-
break;
|
|
7870
|
-
case Number:
|
|
7871
|
-
e = o === null ? null : Number(o);
|
|
7872
|
-
break;
|
|
7873
|
-
case Object:
|
|
7874
|
-
case Array:
|
|
7875
|
-
try {
|
|
7876
|
-
e = JSON.parse(o);
|
|
7877
|
-
} catch {
|
|
7878
|
-
e = null;
|
|
7879
|
-
}
|
|
7880
|
-
}
|
|
7881
|
-
return e;
|
|
7882
|
-
} };
|
|
7883
|
-
var L = (o, t) => !ht(o, t);
|
|
7884
|
-
var J = { attribute: true, type: String, converter: N, reflect: false, useDefault: false, hasChanged: L };
|
|
7885
|
-
Symbol.metadata ??= Symbol("metadata"), R.litPropertyMetadata ??= /* @__PURE__ */ new WeakMap;
|
|
7886
|
-
var A = class extends HTMLElement {
|
|
7887
|
-
static addInitializer(t) {
|
|
7888
|
-
this._$Ei(), (this.l ??= []).push(t);
|
|
7889
|
-
}
|
|
7890
|
-
static get observedAttributes() {
|
|
7891
|
-
return this.finalize(), this._$Eh && [...this._$Eh.keys()];
|
|
7892
|
-
}
|
|
7893
|
-
static createProperty(t, e = J) {
|
|
7894
|
-
if (e.state && (e.attribute = false), this._$Ei(), this.prototype.hasOwnProperty(t) && ((e = Object.create(e)).wrapped = true), this.elementProperties.set(t, e), !e.noAccessor) {
|
|
7895
|
-
const s = Symbol(), i = this.getPropertyDescriptor(t, s, e);
|
|
7896
|
-
i !== undefined && ct(this.prototype, t, i);
|
|
7897
|
-
}
|
|
7898
|
-
}
|
|
7899
|
-
static getPropertyDescriptor(t, e, s) {
|
|
7900
|
-
const { get: i, set: n } = lt(this.prototype, t) ?? { get() {
|
|
7901
|
-
return this[e];
|
|
7902
|
-
}, set(r) {
|
|
7903
|
-
this[e] = r;
|
|
7904
|
-
} };
|
|
7905
|
-
return { get: i, set(r) {
|
|
7906
|
-
const h = i?.call(this);
|
|
7907
|
-
n?.call(this, r), this.requestUpdate(t, h, s);
|
|
7908
|
-
}, configurable: true, enumerable: true };
|
|
7909
|
-
}
|
|
7910
|
-
static getPropertyOptions(t) {
|
|
7911
|
-
return this.elementProperties.get(t) ?? J;
|
|
7912
|
-
}
|
|
7913
|
-
static _$Ei() {
|
|
7914
|
-
if (this.hasOwnProperty(S("elementProperties")))
|
|
7915
|
-
return;
|
|
7916
|
-
const t = pt(this);
|
|
7917
|
-
t.finalize(), t.l !== undefined && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
|
|
7918
|
-
}
|
|
7919
|
-
static finalize() {
|
|
7920
|
-
if (this.hasOwnProperty(S("finalized")))
|
|
7921
|
-
return;
|
|
7922
|
-
if (this.finalized = true, this._$Ei(), this.hasOwnProperty(S("properties"))) {
|
|
7923
|
-
const e = this.properties, s = [...dt(e), ...ut(e)];
|
|
7924
|
-
for (const i of s)
|
|
7925
|
-
this.createProperty(i, e[i]);
|
|
7926
|
-
}
|
|
7927
|
-
const t = this[Symbol.metadata];
|
|
7928
|
-
if (t !== null) {
|
|
7929
|
-
const e = litPropertyMetadata.get(t);
|
|
7930
|
-
if (e !== undefined)
|
|
7931
|
-
for (const [s, i] of e)
|
|
7932
|
-
this.elementProperties.set(s, i);
|
|
7933
|
-
}
|
|
7934
|
-
this._$Eh = /* @__PURE__ */ new Map;
|
|
7935
|
-
for (const [e, s] of this.elementProperties) {
|
|
7936
|
-
const i = this._$Eu(e, s);
|
|
7937
|
-
i !== undefined && this._$Eh.set(i, e);
|
|
7938
|
-
}
|
|
7939
|
-
this.elementStyles = this.finalizeStyles(this.styles);
|
|
7940
|
-
}
|
|
7941
|
-
static finalizeStyles(t) {
|
|
7942
|
-
const e = [];
|
|
7943
|
-
if (Array.isArray(t)) {
|
|
7944
|
-
const s = new Set(t.flat(1 / 0).reverse());
|
|
7945
|
-
for (const i of s)
|
|
7946
|
-
e.unshift(V(i));
|
|
7947
|
-
} else
|
|
7948
|
-
t !== undefined && e.push(V(t));
|
|
7949
|
-
return e;
|
|
7950
|
-
}
|
|
7951
|
-
static _$Eu(t, e) {
|
|
7952
|
-
const s = e.attribute;
|
|
7953
|
-
return s === false ? undefined : typeof s == "string" ? s : typeof t == "string" ? t.toLowerCase() : undefined;
|
|
7954
|
-
}
|
|
7955
|
-
constructor() {
|
|
7956
|
-
super(), this._$Ep = undefined, this.isUpdatePending = false, this.hasUpdated = false, this._$Em = null, this._$Ev();
|
|
7957
|
-
}
|
|
7958
|
-
_$Ev() {
|
|
7959
|
-
this._$ES = new Promise((t) => this.enableUpdating = t), this._$AL = /* @__PURE__ */ new Map, this._$E_(), this.requestUpdate(), this.constructor.l?.forEach((t) => t(this));
|
|
7960
|
-
}
|
|
7961
|
-
addController(t) {
|
|
7962
|
-
(this._$EO ??= /* @__PURE__ */ new Set).add(t), this.renderRoot !== undefined && this.isConnected && t.hostConnected?.();
|
|
7963
|
-
}
|
|
7964
|
-
removeController(t) {
|
|
7965
|
-
this._$EO?.delete(t);
|
|
7966
|
-
}
|
|
7967
|
-
_$E_() {
|
|
7968
|
-
const t = /* @__PURE__ */ new Map, e = this.constructor.elementProperties;
|
|
7969
|
-
for (const s of e.keys())
|
|
7970
|
-
this.hasOwnProperty(s) && (t.set(s, this[s]), delete this[s]);
|
|
7971
|
-
t.size > 0 && (this._$Ep = t);
|
|
7972
|
-
}
|
|
7973
|
-
createRenderRoot() {
|
|
7974
|
-
const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
|
|
7975
|
-
return at(t, this.constructor.elementStyles), t;
|
|
7976
|
-
}
|
|
7977
|
-
connectedCallback() {
|
|
7978
|
-
this.renderRoot ??= this.createRenderRoot(), this.enableUpdating(true), this._$EO?.forEach((t) => t.hostConnected?.());
|
|
7979
|
-
}
|
|
7980
|
-
enableUpdating(t) {}
|
|
7981
|
-
disconnectedCallback() {
|
|
7982
|
-
this._$EO?.forEach((t) => t.hostDisconnected?.());
|
|
7983
|
-
}
|
|
7984
|
-
attributeChangedCallback(t, e, s) {
|
|
7985
|
-
this._$AK(t, s);
|
|
7986
|
-
}
|
|
7987
|
-
_$ET(t, e) {
|
|
7988
|
-
const s = this.constructor.elementProperties.get(t), i = this.constructor._$Eu(t, s);
|
|
7989
|
-
if (i !== undefined && s.reflect === true) {
|
|
7990
|
-
const n = (s.converter?.toAttribute !== undefined ? s.converter : N).toAttribute(e, s.type);
|
|
7991
|
-
this._$Em = t, n == null ? this.removeAttribute(i) : this.setAttribute(i, n), this._$Em = null;
|
|
7992
|
-
}
|
|
7993
|
-
}
|
|
7994
|
-
_$AK(t, e) {
|
|
7995
|
-
const s = this.constructor, i = s._$Eh.get(t);
|
|
7996
|
-
if (i !== undefined && this._$Em !== i) {
|
|
7997
|
-
const n = s.getPropertyOptions(i), r = typeof n.converter == "function" ? { fromAttribute: n.converter } : n.converter?.fromAttribute !== undefined ? n.converter : N;
|
|
7998
|
-
this._$Em = i;
|
|
7999
|
-
const h = r.fromAttribute(e, n.type);
|
|
8000
|
-
this[i] = h ?? this._$Ej?.get(i) ?? h, this._$Em = null;
|
|
8001
|
-
}
|
|
8002
|
-
}
|
|
8003
|
-
requestUpdate(t, e, s) {
|
|
8004
|
-
if (t !== undefined) {
|
|
8005
|
-
const i = this.constructor, n = this[t];
|
|
8006
|
-
if (s ??= i.getPropertyOptions(t), !((s.hasChanged ?? L)(n, e) || s.useDefault && s.reflect && n === this._$Ej?.get(t) && !this.hasAttribute(i._$Eu(t, s))))
|
|
8007
|
-
return;
|
|
8008
|
-
this.C(t, e, s);
|
|
8009
|
-
}
|
|
8010
|
-
this.isUpdatePending === false && (this._$ES = this._$EP());
|
|
8011
|
-
}
|
|
8012
|
-
C(t, e, { useDefault: s, reflect: i, wrapped: n }, r) {
|
|
8013
|
-
s && !(this._$Ej ??= /* @__PURE__ */ new Map).has(t) && (this._$Ej.set(t, r ?? e ?? this[t]), n !== true || r !== undefined) || (this._$AL.has(t) || (this.hasUpdated || s || (e = undefined), this._$AL.set(t, e)), i === true && this._$Em !== t && (this._$Eq ??= /* @__PURE__ */ new Set).add(t));
|
|
8014
|
-
}
|
|
8015
|
-
async _$EP() {
|
|
8016
|
-
this.isUpdatePending = true;
|
|
8017
|
-
try {
|
|
8018
|
-
await this._$ES;
|
|
8019
|
-
} catch (e) {
|
|
8020
|
-
Promise.reject(e);
|
|
8021
|
-
}
|
|
8022
|
-
const t = this.scheduleUpdate();
|
|
8023
|
-
return t != null && await t, !this.isUpdatePending;
|
|
8024
|
-
}
|
|
8025
|
-
scheduleUpdate() {
|
|
8026
|
-
return this.performUpdate();
|
|
8027
|
-
}
|
|
8028
|
-
performUpdate() {
|
|
8029
|
-
if (!this.isUpdatePending)
|
|
8030
|
-
return;
|
|
8031
|
-
if (!this.hasUpdated) {
|
|
8032
|
-
if (this.renderRoot ??= this.createRenderRoot(), this._$Ep) {
|
|
8033
|
-
for (const [i, n] of this._$Ep)
|
|
8034
|
-
this[i] = n;
|
|
8035
|
-
this._$Ep = undefined;
|
|
8036
|
-
}
|
|
8037
|
-
const s = this.constructor.elementProperties;
|
|
8038
|
-
if (s.size > 0)
|
|
8039
|
-
for (const [i, n] of s) {
|
|
8040
|
-
const { wrapped: r } = n, h = this[i];
|
|
8041
|
-
r !== true || this._$AL.has(i) || h === undefined || this.C(i, undefined, n, h);
|
|
8042
|
-
}
|
|
8043
|
-
}
|
|
8044
|
-
let t = false;
|
|
8045
|
-
const e = this._$AL;
|
|
8046
|
-
try {
|
|
8047
|
-
t = this.shouldUpdate(e), t ? (this.willUpdate(e), this._$EO?.forEach((s) => s.hostUpdate?.()), this.update(e)) : this._$EM();
|
|
8048
|
-
} catch (s) {
|
|
8049
|
-
throw t = false, this._$EM(), s;
|
|
8050
|
-
}
|
|
8051
|
-
t && this._$AE(e);
|
|
8052
|
-
}
|
|
8053
|
-
willUpdate(t) {}
|
|
8054
|
-
_$AE(t) {
|
|
8055
|
-
this._$EO?.forEach((e) => e.hostUpdated?.()), this.hasUpdated || (this.hasUpdated = true, this.firstUpdated(t)), this.updated(t);
|
|
8056
|
-
}
|
|
8057
|
-
_$EM() {
|
|
8058
|
-
this._$AL = /* @__PURE__ */ new Map, this.isUpdatePending = false;
|
|
8059
|
-
}
|
|
8060
|
-
get updateComplete() {
|
|
8061
|
-
return this.getUpdateComplete();
|
|
8062
|
-
}
|
|
8063
|
-
getUpdateComplete() {
|
|
8064
|
-
return this._$ES;
|
|
8065
|
-
}
|
|
8066
|
-
shouldUpdate(t) {
|
|
8067
|
-
return true;
|
|
8068
|
-
}
|
|
8069
|
-
update(t) {
|
|
8070
|
-
this._$Eq &&= this._$Eq.forEach((e) => this._$ET(e, this[e])), this._$EM();
|
|
8071
|
-
}
|
|
8072
|
-
updated(t) {}
|
|
8073
|
-
firstUpdated(t) {}
|
|
8074
|
-
};
|
|
8075
|
-
A.elementStyles = [], A.shadowRootOptions = { mode: "open" }, A[S("elementProperties")] = /* @__PURE__ */ new Map, A[S("finalized")] = /* @__PURE__ */ new Map, bt?.({ ReactiveElement: A }), (R.reactiveElementVersions ??= []).push("2.1.1");
|
|
8076
|
-
var I = globalThis;
|
|
8077
|
-
var T = I.trustedTypes;
|
|
8078
|
-
var K = T ? T.createPolicy("lit-html", { createHTML: (o) => o }) : undefined;
|
|
8079
|
-
var et = "$lit$";
|
|
8080
|
-
var v = `lit$${Math.random().toFixed(9).slice(2)}$`;
|
|
8081
|
-
var st = "?" + v;
|
|
8082
|
-
var $t = `<${st}>`;
|
|
8083
|
-
var g = document;
|
|
8084
|
-
var k = () => g.createComment("");
|
|
8085
|
-
var P = (o) => o === null || typeof o != "object" && typeof o != "function";
|
|
8086
|
-
var B = Array.isArray;
|
|
8087
|
-
var vt = (o) => B(o) || typeof o?.[Symbol.iterator] == "function";
|
|
8088
|
-
var j = `[
|
|
8089
|
-
\f\r]`;
|
|
8090
|
-
var x = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g;
|
|
8091
|
-
var Z = /-->/g;
|
|
8092
|
-
var G = />/g;
|
|
8093
|
-
var y = RegExp(`>|${j}(?:([^\\s"'>=/]+)(${j}*=${j}*(?:[^
|
|
8094
|
-
\f\r"'\`<>=]|("|')|))|$)`, "g");
|
|
8095
|
-
var Q = /'/g;
|
|
8096
|
-
var X = /"/g;
|
|
8097
|
-
var it = /^(?:script|style|textarea|title)$/i;
|
|
8098
|
-
var _t = (o) => (t, ...e) => ({ _$litType$: o, strings: t, values: e });
|
|
8099
|
-
var yt = _t(1);
|
|
8100
|
-
var w = Symbol.for("lit-noChange");
|
|
8101
|
-
var d = Symbol.for("lit-nothing");
|
|
8102
|
-
var Y = /* @__PURE__ */ new WeakMap;
|
|
8103
|
-
var m = g.createTreeWalker(g, 129);
|
|
8104
|
-
function ot(o, t) {
|
|
8105
|
-
if (!B(o) || !o.hasOwnProperty("raw"))
|
|
8106
|
-
throw Error("invalid template strings array");
|
|
8107
|
-
return K !== undefined ? K.createHTML(t) : t;
|
|
8108
|
-
}
|
|
8109
|
-
var mt = (o, t) => {
|
|
8110
|
-
const e = o.length - 1, s = [];
|
|
8111
|
-
let i, n = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", r = x;
|
|
8112
|
-
for (let h = 0;h < e; h++) {
|
|
8113
|
-
const a = o[h];
|
|
8114
|
-
let l, u, c = -1, f = 0;
|
|
8115
|
-
for (;f < a.length && (r.lastIndex = f, u = r.exec(a), u !== null); )
|
|
8116
|
-
f = r.lastIndex, r === x ? u[1] === "!--" ? r = Z : u[1] !== undefined ? r = G : u[2] !== undefined ? (it.test(u[2]) && (i = RegExp("</" + u[2], "g")), r = y) : u[3] !== undefined && (r = y) : r === y ? u[0] === ">" ? (r = i ?? x, c = -1) : u[1] === undefined ? c = -2 : (c = r.lastIndex - u[2].length, l = u[1], r = u[3] === undefined ? y : u[3] === '"' ? X : Q) : r === X || r === Q ? r = y : r === Z || r === G ? r = x : (r = y, i = undefined);
|
|
8117
|
-
const $ = r === y && o[h + 1].startsWith("/>") ? " " : "";
|
|
8118
|
-
n += r === x ? a + $t : c >= 0 ? (s.push(l), a.slice(0, c) + et + a.slice(c) + v + $) : a + v + (c === -2 ? h : $);
|
|
8119
|
-
}
|
|
8120
|
-
return [ot(o, n + (o[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), s];
|
|
8121
|
-
};
|
|
8122
|
-
|
|
8123
|
-
class O {
|
|
8124
|
-
constructor({ strings: t, _$litType$: e }, s) {
|
|
8125
|
-
let i;
|
|
8126
|
-
this.parts = [];
|
|
8127
|
-
let n = 0, r = 0;
|
|
8128
|
-
const h = t.length - 1, a = this.parts, [l, u] = mt(t, e);
|
|
8129
|
-
if (this.el = O.createElement(l, s), m.currentNode = this.el.content, e === 2 || e === 3) {
|
|
8130
|
-
const c = this.el.content.firstChild;
|
|
8131
|
-
c.replaceWith(...c.childNodes);
|
|
8132
|
-
}
|
|
8133
|
-
for (;(i = m.nextNode()) !== null && a.length < h; ) {
|
|
8134
|
-
if (i.nodeType === 1) {
|
|
8135
|
-
if (i.hasAttributes())
|
|
8136
|
-
for (const c of i.getAttributeNames())
|
|
8137
|
-
if (c.endsWith(et)) {
|
|
8138
|
-
const f = u[r++], $ = i.getAttribute(c).split(v), M = /([.?@])?(.*)/.exec(f);
|
|
8139
|
-
a.push({ type: 1, index: n, name: M[2], strings: $, ctor: M[1] === "." ? At : M[1] === "?" ? wt : M[1] === "@" ? Et : z }), i.removeAttribute(c);
|
|
8140
|
-
} else
|
|
8141
|
-
c.startsWith(v) && (a.push({ type: 6, index: n }), i.removeAttribute(c));
|
|
8142
|
-
if (it.test(i.tagName)) {
|
|
8143
|
-
const c = i.textContent.split(v), f = c.length - 1;
|
|
8144
|
-
if (f > 0) {
|
|
8145
|
-
i.textContent = T ? T.emptyScript : "";
|
|
8146
|
-
for (let $ = 0;$ < f; $++)
|
|
8147
|
-
i.append(c[$], k()), m.nextNode(), a.push({ type: 2, index: ++n });
|
|
8148
|
-
i.append(c[f], k());
|
|
8149
|
-
}
|
|
8150
|
-
}
|
|
8151
|
-
} else if (i.nodeType === 8)
|
|
8152
|
-
if (i.data === st)
|
|
8153
|
-
a.push({ type: 2, index: n });
|
|
8154
|
-
else {
|
|
8155
|
-
let c = -1;
|
|
8156
|
-
for (;(c = i.data.indexOf(v, c + 1)) !== -1; )
|
|
8157
|
-
a.push({ type: 7, index: n }), c += v.length - 1;
|
|
8158
|
-
}
|
|
8159
|
-
n++;
|
|
8160
|
-
}
|
|
8161
|
-
}
|
|
8162
|
-
static createElement(t, e) {
|
|
8163
|
-
const s = g.createElement("template");
|
|
8164
|
-
return s.innerHTML = t, s;
|
|
8165
|
-
}
|
|
8166
|
-
}
|
|
8167
|
-
function E(o, t, e = o, s) {
|
|
8168
|
-
if (t === w)
|
|
8169
|
-
return t;
|
|
8170
|
-
let i = s !== undefined ? e._$Co?.[s] : e._$Cl;
|
|
8171
|
-
const n = P(t) ? undefined : t._$litDirective$;
|
|
8172
|
-
return i?.constructor !== n && (i?._$AO?.(false), n === undefined ? i = undefined : (i = new n(o), i._$AT(o, e, s)), s !== undefined ? (e._$Co ??= [])[s] = i : e._$Cl = i), i !== undefined && (t = E(o, i._$AS(o, t.values), i, s)), t;
|
|
8173
|
-
}
|
|
8174
|
-
|
|
8175
|
-
class gt {
|
|
8176
|
-
constructor(t, e) {
|
|
8177
|
-
this._$AV = [], this._$AN = undefined, this._$AD = t, this._$AM = e;
|
|
8178
|
-
}
|
|
8179
|
-
get parentNode() {
|
|
8180
|
-
return this._$AM.parentNode;
|
|
8181
|
-
}
|
|
8182
|
-
get _$AU() {
|
|
8183
|
-
return this._$AM._$AU;
|
|
8184
|
-
}
|
|
8185
|
-
u(t) {
|
|
8186
|
-
const { el: { content: e }, parts: s } = this._$AD, i = (t?.creationScope ?? g).importNode(e, true);
|
|
8187
|
-
m.currentNode = i;
|
|
8188
|
-
let n = m.nextNode(), r = 0, h = 0, a = s[0];
|
|
8189
|
-
for (;a !== undefined; ) {
|
|
8190
|
-
if (r === a.index) {
|
|
8191
|
-
let l;
|
|
8192
|
-
a.type === 2 ? l = new U(n, n.nextSibling, this, t) : a.type === 1 ? l = new a.ctor(n, a.name, a.strings, this, t) : a.type === 6 && (l = new xt(n, this, t)), this._$AV.push(l), a = s[++h];
|
|
8193
|
-
}
|
|
8194
|
-
r !== a?.index && (n = m.nextNode(), r++);
|
|
8195
|
-
}
|
|
8196
|
-
return m.currentNode = g, i;
|
|
8197
|
-
}
|
|
8198
|
-
p(t) {
|
|
8199
|
-
let e = 0;
|
|
8200
|
-
for (const s of this._$AV)
|
|
8201
|
-
s !== undefined && (s.strings !== undefined ? (s._$AI(t, s, e), e += s.strings.length - 2) : s._$AI(t[e])), e++;
|
|
8202
|
-
}
|
|
8203
|
-
}
|
|
8204
|
-
|
|
8205
|
-
class U {
|
|
8206
|
-
get _$AU() {
|
|
8207
|
-
return this._$AM?._$AU ?? this._$Cv;
|
|
8208
|
-
}
|
|
8209
|
-
constructor(t, e, s, i) {
|
|
8210
|
-
this.type = 2, this._$AH = d, this._$AN = undefined, this._$AA = t, this._$AB = e, this._$AM = s, this.options = i, this._$Cv = i?.isConnected ?? true;
|
|
8211
|
-
}
|
|
8212
|
-
get parentNode() {
|
|
8213
|
-
let t = this._$AA.parentNode;
|
|
8214
|
-
const e = this._$AM;
|
|
8215
|
-
return e !== undefined && t?.nodeType === 11 && (t = e.parentNode), t;
|
|
8216
|
-
}
|
|
8217
|
-
get startNode() {
|
|
8218
|
-
return this._$AA;
|
|
8219
|
-
}
|
|
8220
|
-
get endNode() {
|
|
8221
|
-
return this._$AB;
|
|
8222
|
-
}
|
|
8223
|
-
_$AI(t, e = this) {
|
|
8224
|
-
t = E(this, t, e), P(t) ? t === d || t == null || t === "" ? (this._$AH !== d && this._$AR(), this._$AH = d) : t !== this._$AH && t !== w && this._(t) : t._$litType$ !== undefined ? this.$(t) : t.nodeType !== undefined ? this.T(t) : vt(t) ? this.k(t) : this._(t);
|
|
8225
|
-
}
|
|
8226
|
-
O(t) {
|
|
8227
|
-
return this._$AA.parentNode.insertBefore(t, this._$AB);
|
|
8228
|
-
}
|
|
8229
|
-
T(t) {
|
|
8230
|
-
this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
|
|
8231
|
-
}
|
|
8232
|
-
_(t) {
|
|
8233
|
-
this._$AH !== d && P(this._$AH) ? this._$AA.nextSibling.data = t : this.T(g.createTextNode(t)), this._$AH = t;
|
|
8234
|
-
}
|
|
8235
|
-
$(t) {
|
|
8236
|
-
const { values: e, _$litType$: s } = t, i = typeof s == "number" ? this._$AC(t) : (s.el === undefined && (s.el = O.createElement(ot(s.h, s.h[0]), this.options)), s);
|
|
8237
|
-
if (this._$AH?._$AD === i)
|
|
8238
|
-
this._$AH.p(e);
|
|
8239
|
-
else {
|
|
8240
|
-
const n = new gt(i, this), r = n.u(this.options);
|
|
8241
|
-
n.p(e), this.T(r), this._$AH = n;
|
|
8242
|
-
}
|
|
8243
|
-
}
|
|
8244
|
-
_$AC(t) {
|
|
8245
|
-
let e = Y.get(t.strings);
|
|
8246
|
-
return e === undefined && Y.set(t.strings, e = new O(t)), e;
|
|
8247
|
-
}
|
|
8248
|
-
k(t) {
|
|
8249
|
-
B(this._$AH) || (this._$AH = [], this._$AR());
|
|
8250
|
-
const e = this._$AH;
|
|
8251
|
-
let s, i = 0;
|
|
8252
|
-
for (const n of t)
|
|
8253
|
-
i === e.length ? e.push(s = new U(this.O(k()), this.O(k()), this, this.options)) : s = e[i], s._$AI(n), i++;
|
|
8254
|
-
i < e.length && (this._$AR(s && s._$AB.nextSibling, i), e.length = i);
|
|
8255
|
-
}
|
|
8256
|
-
_$AR(t = this._$AA.nextSibling, e) {
|
|
8257
|
-
for (this._$AP?.(false, true, e);t !== this._$AB; ) {
|
|
8258
|
-
const s = t.nextSibling;
|
|
8259
|
-
t.remove(), t = s;
|
|
8260
|
-
}
|
|
8261
|
-
}
|
|
8262
|
-
setConnected(t) {
|
|
8263
|
-
this._$AM === undefined && (this._$Cv = t, this._$AP?.(t));
|
|
8264
|
-
}
|
|
8265
|
-
}
|
|
8266
|
-
|
|
8267
|
-
class z {
|
|
8268
|
-
get tagName() {
|
|
8269
|
-
return this.element.tagName;
|
|
8270
|
-
}
|
|
8271
|
-
get _$AU() {
|
|
8272
|
-
return this._$AM._$AU;
|
|
8273
|
-
}
|
|
8274
|
-
constructor(t, e, s, i, n) {
|
|
8275
|
-
this.type = 1, this._$AH = d, this._$AN = undefined, this.element = t, this.name = e, this._$AM = i, this.options = n, s.length > 2 || s[0] !== "" || s[1] !== "" ? (this._$AH = Array(s.length - 1).fill(new String), this.strings = s) : this._$AH = d;
|
|
8276
|
-
}
|
|
8277
|
-
_$AI(t, e = this, s, i) {
|
|
8278
|
-
const n = this.strings;
|
|
8279
|
-
let r = false;
|
|
8280
|
-
if (n === undefined)
|
|
8281
|
-
t = E(this, t, e, 0), r = !P(t) || t !== this._$AH && t !== w, r && (this._$AH = t);
|
|
8282
|
-
else {
|
|
8283
|
-
const h = t;
|
|
8284
|
-
let a, l;
|
|
8285
|
-
for (t = n[0], a = 0;a < n.length - 1; a++)
|
|
8286
|
-
l = E(this, h[s + a], e, a), l === w && (l = this._$AH[a]), r ||= !P(l) || l !== this._$AH[a], l === d ? t = d : t !== d && (t += (l ?? "") + n[a + 1]), this._$AH[a] = l;
|
|
8287
|
-
}
|
|
8288
|
-
r && !i && this.j(t);
|
|
8289
|
-
}
|
|
8290
|
-
j(t) {
|
|
8291
|
-
t === d ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
|
|
8292
|
-
}
|
|
8293
|
-
}
|
|
8294
|
-
|
|
8295
|
-
class At extends z {
|
|
8296
|
-
constructor() {
|
|
8297
|
-
super(...arguments), this.type = 3;
|
|
8298
|
-
}
|
|
8299
|
-
j(t) {
|
|
8300
|
-
this.element[this.name] = t === d ? undefined : t;
|
|
8301
|
-
}
|
|
8302
|
-
}
|
|
8303
|
-
|
|
8304
|
-
class wt extends z {
|
|
8305
|
-
constructor() {
|
|
8306
|
-
super(...arguments), this.type = 4;
|
|
8307
|
-
}
|
|
8308
|
-
j(t) {
|
|
8309
|
-
this.element.toggleAttribute(this.name, !!t && t !== d);
|
|
8310
|
-
}
|
|
8311
|
-
}
|
|
8312
|
-
|
|
8313
|
-
class Et extends z {
|
|
8314
|
-
constructor(t, e, s, i, n) {
|
|
8315
|
-
super(t, e, s, i, n), this.type = 5;
|
|
8316
|
-
}
|
|
8317
|
-
_$AI(t, e = this) {
|
|
8318
|
-
if ((t = E(this, t, e, 0) ?? d) === w)
|
|
8319
|
-
return;
|
|
8320
|
-
const s = this._$AH, i = t === d && s !== d || t.capture !== s.capture || t.once !== s.once || t.passive !== s.passive, n = t !== d && (s === d || i);
|
|
8321
|
-
i && this.element.removeEventListener(this.name, this, s), n && this.element.addEventListener(this.name, this, t), this._$AH = t;
|
|
8322
|
-
}
|
|
8323
|
-
handleEvent(t) {
|
|
8324
|
-
typeof this._$AH == "function" ? this._$AH.call(this.options?.host ?? this.element, t) : this._$AH.handleEvent(t);
|
|
8325
|
-
}
|
|
8326
|
-
}
|
|
8327
|
-
|
|
8328
|
-
class xt {
|
|
8329
|
-
constructor(t, e, s) {
|
|
8330
|
-
this.element = t, this.type = 6, this._$AN = undefined, this._$AM = e, this.options = s;
|
|
8331
|
-
}
|
|
8332
|
-
get _$AU() {
|
|
8333
|
-
return this._$AM._$AU;
|
|
8334
|
-
}
|
|
8335
|
-
_$AI(t) {
|
|
8336
|
-
E(this, t);
|
|
8337
|
-
}
|
|
8338
|
-
}
|
|
8339
|
-
var St = I.litHtmlPolyfillSupport;
|
|
8340
|
-
St?.(O, U), (I.litHtmlVersions ??= []).push("3.3.1");
|
|
8341
|
-
var Ct = (o, t, e) => {
|
|
8342
|
-
const s = e?.renderBefore ?? t;
|
|
8343
|
-
let i = s._$litPart$;
|
|
8344
|
-
if (i === undefined) {
|
|
8345
|
-
const n = e?.renderBefore ?? null;
|
|
8346
|
-
s._$litPart$ = i = new U(t.insertBefore(k(), n), n, undefined, e ?? {});
|
|
8347
|
-
}
|
|
8348
|
-
return i._$AI(o), i;
|
|
8349
|
-
};
|
|
8350
|
-
var q = globalThis;
|
|
8351
|
-
|
|
8352
|
-
class C extends A {
|
|
8353
|
-
constructor() {
|
|
8354
|
-
super(...arguments), this.renderOptions = { host: this }, this._$Do = undefined;
|
|
8355
|
-
}
|
|
8356
|
-
createRenderRoot() {
|
|
8357
|
-
const t = super.createRenderRoot();
|
|
8358
|
-
return this.renderOptions.renderBefore ??= t.firstChild, t;
|
|
8359
|
-
}
|
|
8360
|
-
update(t) {
|
|
8361
|
-
const e = this.render();
|
|
8362
|
-
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this._$Do = Ct(e, this.renderRoot, this.renderOptions);
|
|
8363
|
-
}
|
|
8364
|
-
connectedCallback() {
|
|
8365
|
-
super.connectedCallback(), this._$Do?.setConnected(true);
|
|
8366
|
-
}
|
|
8367
|
-
disconnectedCallback() {
|
|
8368
|
-
super.disconnectedCallback(), this._$Do?.setConnected(false);
|
|
8369
|
-
}
|
|
8370
|
-
render() {
|
|
8371
|
-
return w;
|
|
8372
|
-
}
|
|
8373
|
-
}
|
|
8374
|
-
C._$litElement$ = true, C.finalized = true, q.litElementHydrateSupport?.({ LitElement: C });
|
|
8375
|
-
var kt = q.litElementPolyfillSupport;
|
|
8376
|
-
kt?.({ LitElement: C });
|
|
8377
|
-
(q.litElementVersions ??= []).push("4.2.1");
|
|
8378
|
-
var Pt = (o) => (t, e) => {
|
|
8379
|
-
e !== undefined ? e.addInitializer(() => {
|
|
8380
|
-
customElements.get(o) || customElements.define(o, t);
|
|
8381
|
-
}) : customElements.get(o) || customElements.define(o, t);
|
|
8382
|
-
};
|
|
8383
|
-
var Ot = { attribute: true, type: String, converter: N, reflect: false, hasChanged: L };
|
|
8384
|
-
var Ut = (o = Ot, t, e) => {
|
|
8385
|
-
const { kind: s, metadata: i } = e;
|
|
8386
|
-
let n = globalThis.litPropertyMetadata.get(i);
|
|
8387
|
-
if (n === undefined && globalThis.litPropertyMetadata.set(i, n = /* @__PURE__ */ new Map), s === "setter" && ((o = Object.create(o)).wrapped = true), n.set(e.name, o), s === "accessor") {
|
|
8388
|
-
const { name: r } = e;
|
|
8389
|
-
return { set(h) {
|
|
8390
|
-
const a = t.get.call(this);
|
|
8391
|
-
t.set.call(this, h), this.requestUpdate(r, a, o);
|
|
8392
|
-
}, init(h) {
|
|
8393
|
-
return h !== undefined && this.C(r, undefined, o, h), h;
|
|
8394
|
-
} };
|
|
8395
|
-
}
|
|
8396
|
-
if (s === "setter") {
|
|
8397
|
-
const { name: r } = e;
|
|
8398
|
-
return function(h) {
|
|
8399
|
-
const a = this[r];
|
|
8400
|
-
t.call(this, h), this.requestUpdate(r, a, o);
|
|
8401
|
-
};
|
|
8402
|
-
}
|
|
8403
|
-
throw Error("Unsupported decorator location: " + s);
|
|
8404
|
-
};
|
|
8405
|
-
function _(o) {
|
|
8406
|
-
return (t, e) => typeof e == "object" ? Ut(o, t, e) : ((s, i, n) => {
|
|
8407
|
-
const r = i.hasOwnProperty(n);
|
|
8408
|
-
return i.constructor.createProperty(n, s), r ? Object.getOwnPropertyDescriptor(i, n) : undefined;
|
|
8409
|
-
})(o, t, e);
|
|
8410
|
-
}
|
|
8411
|
-
var Mt = Object.defineProperty;
|
|
8412
|
-
var Ht = Object.getOwnPropertyDescriptor;
|
|
8413
|
-
var b = (o, t, e, s) => {
|
|
8414
|
-
for (var i = s > 1 ? undefined : s ? Ht(t, e) : t, n = o.length - 1, r;n >= 0; n--)
|
|
8415
|
-
(r = o[n]) && (i = (s ? r(t, e, i) : r(i)) || i);
|
|
8416
|
-
return s && i && Mt(t, e, i), i;
|
|
8417
|
-
};
|
|
8418
|
-
var p = class extends C {
|
|
8419
|
-
constructor() {
|
|
8420
|
-
super(...arguments), this.variant = "primary", this.size = "default", this.type = "circle", this.state = "default", this.iconName = "home", this.disabled = false, this.buttonAriaLabel = "Icon button";
|
|
8421
|
-
}
|
|
8422
|
-
createRenderRoot() {
|
|
8423
|
-
return this;
|
|
8424
|
-
}
|
|
8425
|
-
connectedCallback() {
|
|
8426
|
-
if (super.connectedCallback(), !document.querySelector('link[href*="Roboto"]')) {
|
|
8427
|
-
const o = document.createElement("link");
|
|
8428
|
-
o.rel = "stylesheet", o.href = "https://ui.renaissance.com/fonts/Roboto/style.css", document.head.appendChild(o);
|
|
8429
|
-
}
|
|
8430
|
-
}
|
|
8431
|
-
set shape(o) {
|
|
8432
|
-
this.type = o;
|
|
8433
|
-
}
|
|
8434
|
-
get shape() {
|
|
8435
|
-
return this.type;
|
|
8436
|
-
}
|
|
8437
|
-
get buttonClasses() {
|
|
8438
|
-
return [
|
|
8439
|
-
"nds-icon-button",
|
|
8440
|
-
`nds-icon-button--${this.variant}`,
|
|
8441
|
-
`nds-icon-button--${this.size}`,
|
|
8442
|
-
`nds-icon-button--${this.type}`,
|
|
8443
|
-
this.state !== "default" ? `nds-icon-button--${this.state}` : "",
|
|
8444
|
-
this.disabled ? "nds-icon-button--disabled" : ""
|
|
8445
|
-
].filter(Boolean).join(" ");
|
|
8446
|
-
}
|
|
8447
|
-
handleClick(o) {
|
|
8448
|
-
if (this.disabled) {
|
|
8449
|
-
o.preventDefault(), o.stopPropagation();
|
|
8450
|
-
return;
|
|
8451
|
-
}
|
|
8452
|
-
this.dispatchEvent(new CustomEvent("icon-button-click", {
|
|
8453
|
-
bubbles: true,
|
|
8454
|
-
composed: true,
|
|
8455
|
-
detail: { originalEvent: o }
|
|
8456
|
-
}));
|
|
8457
|
-
}
|
|
8458
|
-
render() {
|
|
8459
|
-
return yt`
|
|
8460
|
-
<style>
|
|
8461
|
-
nds-icon-button {
|
|
8462
|
-
display: inline-block;
|
|
8463
|
-
}
|
|
8464
|
-
|
|
8465
|
-
.nds-icon-button {
|
|
8466
|
-
display: inline-flex;
|
|
8467
|
-
align-items: center;
|
|
8468
|
-
justify-content: center;
|
|
8469
|
-
cursor: pointer;
|
|
8470
|
-
font-family: var(--font-family-roboto, "Roboto", sans-serif);
|
|
8471
|
-
font-weight: var(--font-weight-regular, 400);
|
|
8472
|
-
line-height: 1;
|
|
8473
|
-
text-decoration: none;
|
|
8474
|
-
background: none;
|
|
8475
|
-
position: relative;
|
|
8476
|
-
box-sizing: border-box;
|
|
8477
|
-
margin: 0;
|
|
8478
|
-
padding: 0;
|
|
8479
|
-
border: none;
|
|
8480
|
-
transition: background-color 0.2s ease-in-out,
|
|
8481
|
-
color 0.2s ease-in-out,
|
|
8482
|
-
box-shadow 0.2s ease-in-out;
|
|
8483
|
-
}
|
|
8484
|
-
|
|
8485
|
-
/* ── Sizes ── */
|
|
8486
|
-
.nds-icon-button--small {
|
|
8487
|
-
width: var(--height-32, 32px);
|
|
8488
|
-
height: var(--height-32, 32px);
|
|
8489
|
-
}
|
|
8490
|
-
|
|
8491
|
-
.nds-icon-button--medium {
|
|
8492
|
-
width: var(--height-36, 36px);
|
|
8493
|
-
height: var(--height-36, 36px);
|
|
8494
|
-
}
|
|
8495
|
-
|
|
8496
|
-
.nds-icon-button--default {
|
|
8497
|
-
width: var(--height-40, 40px);
|
|
8498
|
-
height: var(--height-40, 40px);
|
|
8499
|
-
}
|
|
8500
|
-
|
|
8501
|
-
.nds-icon-button--large {
|
|
8502
|
-
width: var(--height-48, 48px);
|
|
8503
|
-
height: var(--height-48, 48px);
|
|
8504
|
-
}
|
|
8505
|
-
|
|
8506
|
-
/* ── Shapes ── */
|
|
8507
|
-
.nds-icon-button--circle {
|
|
8508
|
-
border-radius: var(--radius-circle, 50%);
|
|
8509
|
-
}
|
|
8510
|
-
|
|
8511
|
-
.nds-icon-button--rounded {
|
|
8512
|
-
border-radius: var(--radius-8, 8px);
|
|
8513
|
-
}
|
|
8514
|
-
|
|
8515
|
-
/* ── Primary ── */
|
|
8516
|
-
.nds-icon-button--primary {
|
|
8517
|
-
background-color: var(--color-interactive-blue, #146eb3);
|
|
8518
|
-
color: var(--color-primary-white, #ffffff);
|
|
8519
|
-
}
|
|
8520
|
-
|
|
8521
|
-
.nds-icon-button--primary:hover:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8522
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-primary-black, #000000);
|
|
8523
|
-
}
|
|
8524
|
-
|
|
8525
|
-
.nds-icon-button--primary:active:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8526
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-primary-black, #000000);
|
|
8527
|
-
}
|
|
8528
|
-
|
|
8529
|
-
/* ── Secondary ── */
|
|
8530
|
-
.nds-icon-button--secondary {
|
|
8531
|
-
background-color: var(--color-primary-white, #ffffff);
|
|
8532
|
-
color: var(--color-interactive-blue, #146eb3);
|
|
8533
|
-
box-shadow: inset 0 0 0 var(--stroke-1, 1px) var(--color-interactive-blue, #146eb3);
|
|
8534
|
-
}
|
|
8535
|
-
|
|
8536
|
-
.nds-icon-button--secondary:hover:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8537
|
-
background-color: var(--color-interactive-blue, #146eb3);
|
|
8538
|
-
color: var(--color-primary-white, #ffffff);
|
|
8539
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-primary-black, #000000);
|
|
8540
|
-
}
|
|
8541
|
-
|
|
8542
|
-
.nds-icon-button--secondary:active:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8543
|
-
background-color: var(--color-interactive-blue, #146eb3);
|
|
8544
|
-
color: var(--color-primary-white, #ffffff);
|
|
8545
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-primary-black, #000000);
|
|
8546
|
-
}
|
|
8547
|
-
|
|
8548
|
-
/* ── Tertiary ── */
|
|
8549
|
-
.nds-icon-button--tertiary {
|
|
8550
|
-
background-color: var(--color-new-gray, #f3f5f7);
|
|
8551
|
-
color: var(--color-interactive-blue, #146eb3);
|
|
8552
|
-
}
|
|
8553
|
-
|
|
8554
|
-
.nds-icon-button--tertiary:hover:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8555
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-interactive-blue, #146eb3);
|
|
8556
|
-
}
|
|
8557
|
-
|
|
8558
|
-
.nds-icon-button--tertiary:active:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8559
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-primary-black, #000000);
|
|
8560
|
-
}
|
|
8561
|
-
|
|
8562
|
-
/* ── Ghost ── */
|
|
8563
|
-
.nds-icon-button--ghost {
|
|
8564
|
-
background-color: transparent;
|
|
8565
|
-
color: var(--color-interactive-blue, #146eb3);
|
|
8566
|
-
}
|
|
8567
|
-
|
|
8568
|
-
.nds-icon-button--ghost:hover:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8569
|
-
background-color: var(--color-new-gray, #f3f5f7);
|
|
8570
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-interactive-blue, #146eb3);
|
|
8571
|
-
}
|
|
8572
|
-
|
|
8573
|
-
.nds-icon-button--ghost:active:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8574
|
-
background-color: var(--color-new-gray, #f3f5f7);
|
|
8575
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-primary-black, #000000);
|
|
8576
|
-
}
|
|
8577
|
-
|
|
8578
|
-
/* ── Dark (for dark backgrounds) ── */
|
|
8579
|
-
.nds-icon-button--dark {
|
|
8580
|
-
background-color: transparent;
|
|
8581
|
-
color: var(--color-primary-white, #ffffff);
|
|
8582
|
-
box-shadow: inset 0 0 0 var(--stroke-1, 1px) var(--color-primary-white, #ffffff);
|
|
8583
|
-
}
|
|
8584
|
-
|
|
8585
|
-
.nds-icon-button--dark:hover:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8586
|
-
background-color: var(--color-interactive-blue, #146eb3);
|
|
8587
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-primary-white, #ffffff);
|
|
8588
|
-
}
|
|
8589
|
-
|
|
8590
|
-
.nds-icon-button--dark:active:not(:disabled):not(.nds-icon-button--disabled) {
|
|
8591
|
-
background-color: var(--color-interactive-blue, #146eb3);
|
|
8592
|
-
box-shadow: inset 0 0 0 var(--stroke-2, 2px) var(--color-primary-white, #ffffff);
|
|
8593
|
-
}
|
|
8594
|
-
|
|
8595
|
-
/* ── Disabled ── */
|
|
8596
|
-
.nds-icon-button--disabled,
|
|
8597
|
-
.nds-icon-button:disabled {
|
|
8598
|
-
opacity: 0.5;
|
|
8599
|
-
cursor: not-allowed;
|
|
8600
|
-
}
|
|
8601
|
-
|
|
8602
|
-
/* ── Icon sizing ── */
|
|
8603
|
-
.nds-icon-button__icon {
|
|
8604
|
-
line-height: 1;
|
|
8605
|
-
display: inline-flex;
|
|
8606
|
-
align-items: center;
|
|
8607
|
-
justify-content: center;
|
|
8608
|
-
color: inherit;
|
|
8609
|
-
}
|
|
8610
|
-
|
|
8611
|
-
.nds-icon-button--small .nds-icon-button__icon {
|
|
8612
|
-
font-size: var(--nds-icon-small, 12px);
|
|
8613
|
-
}
|
|
8614
|
-
|
|
8615
|
-
.nds-icon-button--medium .nds-icon-button__icon {
|
|
8616
|
-
font-size: var(--nds-icon-medium, 14px);
|
|
8617
|
-
}
|
|
8618
|
-
|
|
8619
|
-
.nds-icon-button--default .nds-icon-button__icon {
|
|
8620
|
-
font-size: var(--nds-icon-default, 16px);
|
|
8621
|
-
}
|
|
8622
|
-
|
|
8623
|
-
.nds-icon-button--large .nds-icon-button__icon {
|
|
8624
|
-
font-size: var(--nds-icon-large, 20px);
|
|
8625
|
-
}
|
|
8626
|
-
|
|
8627
|
-
/* ── Focus ── */
|
|
8628
|
-
.nds-icon-button:focus-visible {
|
|
8629
|
-
outline: 2px solid var(--color-focus-blue, #2b87ff);
|
|
8630
|
-
outline-offset: 2px;
|
|
8631
|
-
}
|
|
8632
|
-
|
|
8633
|
-
/* ── Reduced motion ── */
|
|
8634
|
-
@media (prefers-reduced-motion: reduce) {
|
|
8635
|
-
.nds-icon-button {
|
|
8636
|
-
transition: none;
|
|
8637
|
-
}
|
|
8638
|
-
}
|
|
8639
|
-
</style>
|
|
8640
|
-
<button
|
|
8641
|
-
type="button"
|
|
8642
|
-
class="${this.buttonClasses}"
|
|
8643
|
-
?disabled="${this.disabled}"
|
|
8644
|
-
aria-disabled="${this.disabled ? "true" : "false"}"
|
|
8645
|
-
aria-label="${this.buttonAriaLabel}"
|
|
8646
|
-
@click="${this.handleClick}"
|
|
8647
|
-
>
|
|
8648
|
-
<i class="fa-light fa-${this.iconName} nds-icon-button__icon" aria-hidden="true"></i>
|
|
8649
|
-
</button>
|
|
8650
|
-
`;
|
|
8651
|
-
}
|
|
8652
|
-
};
|
|
8653
|
-
b([
|
|
8654
|
-
_()
|
|
8655
|
-
], p.prototype, "variant", 2);
|
|
8656
|
-
b([
|
|
8657
|
-
_()
|
|
8658
|
-
], p.prototype, "size", 2);
|
|
8659
|
-
b([
|
|
8660
|
-
_()
|
|
8661
|
-
], p.prototype, "type", 2);
|
|
8662
|
-
b([
|
|
8663
|
-
_()
|
|
8664
|
-
], p.prototype, "state", 2);
|
|
8665
|
-
b([
|
|
8666
|
-
_({ attribute: "icon-name" })
|
|
8667
|
-
], p.prototype, "iconName", 2);
|
|
8668
|
-
b([
|
|
8669
|
-
_({ type: Boolean })
|
|
8670
|
-
], p.prototype, "disabled", 2);
|
|
8671
|
-
b([
|
|
8672
|
-
_({ attribute: "button-aria-label" })
|
|
8673
|
-
], p.prototype, "buttonAriaLabel", 2);
|
|
8674
|
-
b([
|
|
8675
|
-
_()
|
|
8676
|
-
], p.prototype, "shape", 1);
|
|
8677
|
-
p = b([
|
|
8678
|
-
Pt("nds-icon-button")
|
|
8679
|
-
], p);
|
|
8680
|
-
|
|
8681
7982
|
// dist/components/.ItemToolBar.custom-element.unbundled.js
|
|
7983
|
+
import"@pie-players/pie-players-shared/nds-icon-button";
|
|
8682
7984
|
var __pieDefineSafely = (tagName, ctor) => {
|
|
8683
7985
|
if (customElements.get(tagName))
|
|
8684
7986
|
return;
|
|
@@ -8692,7 +7994,7 @@ var __pieDefineSafely = (tagName, ctor) => {
|
|
|
8692
7994
|
}
|
|
8693
7995
|
};
|
|
8694
7996
|
var root_1 = from_html(`<span class="item-toolbar__element-host svelte-rnx3ie"></span>`);
|
|
8695
|
-
var root_2 = from_html(`<span class="item-
|
|
7997
|
+
var root_2 = from_html(`<span class="item-toolbar__nds-button-zoom svelte-rnx3ie"><nds-icon-button></nds-icon-button></span>`, 2);
|
|
8696
7998
|
var root_3 = from_html(`<span aria-hidden="true"></span>`);
|
|
8697
7999
|
var root_4 = from_html(`<img class="item-toolbar__icon-image svelte-rnx3ie" alt=""/>`);
|
|
8698
8000
|
var root_5 = from_html(`<i aria-hidden="true"></i>`);
|
|
@@ -8703,16 +8005,27 @@ var root_9 = from_html(`<div></div>`);
|
|
|
8703
8005
|
var root_10 = from_html(`<div><div class="item-toolbar__tools-row svelte-rnx3ie"><!> <!> <!></div> <!></div>`);
|
|
8704
8006
|
var $$css = {
|
|
8705
8007
|
hash: "svelte-rnx3ie",
|
|
8706
|
-
code: `.item-toolbar.svelte-rnx3ie {display:flex;flex-direction:column;align-items:flex-end;gap:0;--pie-toolbar-tools-row-height: 2rem;--pie-tts-controls-row-height: 2.875rem;}.item-toolbar__tools-row.svelte-rnx3ie {display:flex;align-items:center;justify-content:flex-end;flex-wrap:nowrap;
|
|
8008
|
+
code: `.item-toolbar.svelte-rnx3ie {display:flex;flex-direction:column;align-items:flex-end;gap:0;--pie-toolbar-tools-row-height: 2rem;--pie-tts-controls-row-height: 2.875rem;}.item-toolbar__tools-row.svelte-rnx3ie {display:flex;align-items:center;justify-content:flex-end;flex-wrap:nowrap;
|
|
8009
|
+
/* Cap the gap between toolbar items (e.g. TTS play ↔ calculator) at its
|
|
8010
|
+
200%-zoom size with the same factor the buttons use, so the spacing
|
|
8011
|
+
doesn't keep growing past 200% while the buttons themselves freeze. */gap:calc(0.5rem * var(--pie-toolbar-zoom-comp, 1));min-height:var(--pie-toolbar-tools-row-height);}.item-toolbar__controls-row.svelte-rnx3ie {display:flex;align-items:center;justify-content:flex-end;width:100%;min-height:0;height:auto;}.item-toolbar__controls-row--reserve.svelte-rnx3ie {min-height:var(--pie-tts-controls-row-height);height:var(--pie-tts-controls-row-height);}.item-toolbar__controls-row--active.svelte-rnx3ie {min-height:var(--pie-tts-controls-row-height);height:var(--pie-tts-controls-row-height);}.item-toolbar__controls-row--align-start.svelte-rnx3ie {justify-content:flex-start;}.item-toolbar__controls-host.svelte-rnx3ie {display:inline-flex;align-items:center;justify-content:flex-end;width:100%;}.item-toolbar--top.svelte-rnx3ie,
|
|
8707
8012
|
.item-toolbar--bottom.svelte-rnx3ie {align-items:flex-end;}.item-toolbar--left.svelte-rnx3ie,
|
|
8708
8013
|
.item-toolbar--right.svelte-rnx3ie {align-items:stretch;}.item-toolbar--left.svelte-rnx3ie .item-toolbar__tools-row:where(.svelte-rnx3ie),
|
|
8709
8014
|
.item-toolbar--right.svelte-rnx3ie .item-toolbar__tools-row:where(.svelte-rnx3ie) {flex-direction:column;align-items:center;justify-content:flex-start;flex-wrap:nowrap;}.item-toolbar--left.svelte-rnx3ie .item-toolbar__controls-row:where(.svelte-rnx3ie),
|
|
8710
|
-
.item-toolbar--right.svelte-rnx3ie .item-toolbar__controls-row:where(.svelte-rnx3ie) {justify-content:flex-start;width:auto;min-height:0;height:auto;}.item-toolbar__button.svelte-rnx3ie {display:flex;align-items:center;justify-content:center;width:2rem;height:2rem;padding:0.25rem;border:1px solid var(--pie-button-border, var(--pie-border, #ccc));border-radius:0.25rem;background-color:var(--pie-button-bg, var(--pie-background, white));color:var(--pie-button-color, var(--pie-text, #333));cursor:pointer;transition:all 0.15s ease;text-decoration:none;}
|
|
8711
|
-
|
|
8712
|
-
/* Decorative only — the outer link/button owns focus and aria semantics. */.item-toolbar__calculator-icon.svelte-rnx3ie {pointer-events:none;display:inline-flex;align-items:center;justify-content:center;width:100%;height:100%;}
|
|
8015
|
+
.item-toolbar--right.svelte-rnx3ie .item-toolbar__controls-row:where(.svelte-rnx3ie) {justify-content:flex-start;width:auto;min-height:0;height:auto;}.item-toolbar__button.svelte-rnx3ie {display:flex;align-items:center;justify-content:center;width:2rem;height:2rem;padding:0.25rem;border:1px solid var(--pie-button-border, var(--pie-border, #ccc));border-radius:0.25rem;background-color:var(--pie-button-bg, var(--pie-background, white));color:var(--pie-button-color, var(--pie-text, #333));cursor:pointer;transition:all 0.15s ease;text-decoration:none;}
|
|
8713
8016
|
|
|
8714
|
-
/*
|
|
8715
|
-
|
|
8017
|
+
/* Drive the vendored NDS icon button's outer size via its own \`--height-32\`
|
|
8018
|
+
custom property so its light-DOM inner button matches the toolbar's
|
|
8019
|
+
md/sm/lg dimensions (32 / 44 / 40 px) without a layout shift. The glyph
|
|
8020
|
+
keeps the NDS-native icon size (we render size="small"), so it isn't
|
|
8021
|
+
oversized. */
|
|
8022
|
+
/* Freeze the calculator's header open/close button at its 200%-zoom size
|
|
8023
|
+
(factor is 1 at zoom <= 200%). Zoom on this wrapper, not the host. */.item-toolbar__nds-button-zoom.svelte-rnx3ie {display:inline-flex;zoom:var(--pie-toolbar-zoom-comp, 1);}.item-toolbar.svelte-rnx3ie nds-icon-button:where(.svelte-rnx3ie) {
|
|
8024
|
+
/* Host-settable button size per toolbar size (drives the NDS outer button
|
|
8025
|
+
via its own --height-32). */--height-32: var(--pie-calculator-button-size, 2rem);
|
|
8026
|
+
/* Host-settable accent for the calculator button: the NDS tertiary glyph
|
|
8027
|
+
colour derives from --color-interactive-blue, remapped here to a
|
|
8028
|
+
themeable variable. */--color-interactive-blue: var(--pie-calculator-button-color, #146eb3);}.item-toolbar--sm.svelte-rnx3ie nds-icon-button:where(.svelte-rnx3ie) {--height-32: var(--pie-calculator-button-size-sm, 2.75rem);}.item-toolbar--lg.svelte-rnx3ie nds-icon-button:where(.svelte-rnx3ie) {--height-32: var(--pie-calculator-button-size-lg, 2.5rem);}.item-toolbar__element-host.svelte-rnx3ie {display:contents;}.item-toolbar--sm.svelte-rnx3ie .item-toolbar__button:where(.svelte-rnx3ie) {width:2.75rem;height:2.75rem;}.item-toolbar--sm.svelte-rnx3ie {--pie-toolbar-tools-row-height: 2.75rem;--pie-tts-controls-row-height: 3.625rem;}.item-toolbar--lg.svelte-rnx3ie .item-toolbar__button:where(.svelte-rnx3ie) {width:2.5rem;height:2.5rem;}.item-toolbar--lg.svelte-rnx3ie {--pie-toolbar-tools-row-height: 2.5rem;--pie-tts-controls-row-height: 3.375rem;}.item-toolbar__button.svelte-rnx3ie:hover:not(:disabled) {background-color:var(--pie-button-hover-bg, var(--pie-secondary-background, #f5f5f5));border-color:var(--pie-button-hover-border, var(--pie-button-border, var(--pie-border, #ccc)));color:var(--pie-button-hover-color, var(--pie-button-color, var(--pie-text, #333)));transform:translateY(-1px);box-shadow:0 2px 4px color-mix(in srgb, var(--pie-black, #000) 10%, transparent);}.item-toolbar__button.svelte-rnx3ie:active:not(:disabled) {transform:translateY(0);box-shadow:none;}.item-toolbar__button--active.svelte-rnx3ie {background-color:var(--pie-primary, #1976d2);color:var(--pie-white, #fff);border-color:var(--pie-primary, #1976d2);}.item-toolbar__button--active.svelte-rnx3ie:hover:not(:disabled) {background-color:var(--pie-primary-dark, #1565c0);}.item-toolbar__button.svelte-rnx3ie:focus-visible {outline:2px solid var(--pie-button-focus-outline, var(--pie-primary, #1976d2));outline-offset:2px;}.item-toolbar__button.svelte-rnx3ie:disabled {opacity:0.5;cursor:not-allowed;}.item-toolbar__button.svelte-rnx3ie svg {width:100%;height:100%;}.item-toolbar__icon-image.svelte-rnx3ie {width:100%;height:100%;object-fit:contain;}`
|
|
8716
8029
|
};
|
|
8717
8030
|
function ItemToolBar($$anchor, $$props) {
|
|
8718
8031
|
push($$props, true);
|
|
@@ -8779,11 +8092,50 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
8779
8092
|
installFaInToolbarShadow(node);
|
|
8780
8093
|
return {};
|
|
8781
8094
|
};
|
|
8095
|
+
const reflectToggleState = (node, pressed) => {
|
|
8096
|
+
let current = pressed;
|
|
8097
|
+
const apply2 = () => {
|
|
8098
|
+
const inner = node.querySelector("button");
|
|
8099
|
+
if (inner)
|
|
8100
|
+
inner.setAttribute("aria-pressed", current ? "true" : "false");
|
|
8101
|
+
};
|
|
8102
|
+
apply2();
|
|
8103
|
+
const observer = new MutationObserver(apply2);
|
|
8104
|
+
observer.observe(node, { childList: true, subtree: true });
|
|
8105
|
+
return {
|
|
8106
|
+
update(next2) {
|
|
8107
|
+
current = next2;
|
|
8108
|
+
apply2();
|
|
8109
|
+
},
|
|
8110
|
+
destroy() {
|
|
8111
|
+
observer.disconnect();
|
|
8112
|
+
}
|
|
8113
|
+
};
|
|
8114
|
+
};
|
|
8115
|
+
const TOOL_FA_ICON_BY_ID = { calculator: "calculator" };
|
|
8116
|
+
const resolveFaIconName = (item2) => TOOL_FA_ICON_BY_ID[item2.id] ?? null;
|
|
8782
8117
|
const fallbackToolRegistry = createPackagedToolRegistry();
|
|
8783
8118
|
let activeToolState = state(proxy({}));
|
|
8784
8119
|
let level = prop($$props, "level", 7, "item"), scopeId = prop($$props, "scopeId", 7, ""), itemId = prop($$props, "itemId", 7, ""), sectionId = prop($$props, "sectionId", 7, ""), catalogId = prop($$props, "catalogId", 7, ""), tools = prop($$props, "tools", 7, "calculator,textToSpeech,answerEliminator"), contentKind = prop($$props, "contentKind", 7, "assessment-item"), position = prop($$props, "position", 7, "bottom"), scopeElement = prop($$props, "scopeElement", 7, null), toolRegistry = prop($$props, "toolRegistry", 7, null), item = prop($$props, "item", 7, null), hostButtons = prop($$props, "hostButtons", 23, () => []), className = prop($$props, "class", 7, ""), size = prop($$props, "size", 7, "md"), language = prop($$props, "language", 7, "en-US");
|
|
8785
8120
|
let toolbarRootElement = state(null);
|
|
8121
|
+
function currentCalculatorZoomCompensation() {
|
|
8122
|
+
if (typeof window === "undefined")
|
|
8123
|
+
return 1;
|
|
8124
|
+
return computeZoomCompensation(approximateZoomFromWidths(window.outerWidth, window.innerWidth), ICON_BUTTON_ZOOM_OPTIONS.maxZoom, ICON_BUTTON_ZOOM_OPTIONS.minCompensation);
|
|
8125
|
+
}
|
|
8126
|
+
let calculatorButtonZoomComp = state(1);
|
|
8127
|
+
user_effect(() => {
|
|
8128
|
+
if (typeof window === "undefined")
|
|
8129
|
+
return;
|
|
8130
|
+
const update2 = () => {
|
|
8131
|
+
set(calculatorButtonZoomComp, currentCalculatorZoomCompensation(), true);
|
|
8132
|
+
};
|
|
8133
|
+
update2();
|
|
8134
|
+
window.addEventListener("resize", update2);
|
|
8135
|
+
return () => window.removeEventListener("resize", update2);
|
|
8136
|
+
});
|
|
8786
8137
|
let runtimeContext = state(null);
|
|
8138
|
+
const useNdsIcons = user_derived(() => get2(runtimeContext)?.ndsIcons === true);
|
|
8787
8139
|
let shellContext = state(null);
|
|
8788
8140
|
let moduleLoadVersion = state(0);
|
|
8789
8141
|
let policyChangeVersion = state(0);
|
|
@@ -9393,8 +8745,8 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9393
8745
|
let resizeStartShellY = 0;
|
|
9394
8746
|
let resizeCorner = null;
|
|
9395
8747
|
const resizeHandleEls = [];
|
|
9396
|
-
let
|
|
9397
|
-
let
|
|
8748
|
+
let x = 0;
|
|
8749
|
+
let y = 0;
|
|
9398
8750
|
let width = currentArgs.mounted.entry.shell?.initialWidth ?? 720;
|
|
9399
8751
|
let height = currentArgs.mounted.entry.shell?.initialHeight ?? 560;
|
|
9400
8752
|
let focusTrapCleanup = null;
|
|
@@ -9504,16 +8856,16 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9504
8856
|
const effectiveMinHeight = Math.min(minHeight, window.innerHeight);
|
|
9505
8857
|
width = clamp(width, effectiveMinWidth, Math.max(effectiveMinWidth, Math.min(maxWidth, window.innerWidth)));
|
|
9506
8858
|
height = clamp(height, effectiveMinHeight, Math.max(effectiveMinHeight, Math.min(maxHeight, window.innerHeight)));
|
|
9507
|
-
|
|
9508
|
-
|
|
8859
|
+
x = clamp(x, 0, Math.max(0, window.innerWidth - width));
|
|
8860
|
+
y = clamp(y, 0, Math.max(0, window.innerHeight - height));
|
|
9509
8861
|
applyShellStyle();
|
|
9510
8862
|
applyContentMinWidth();
|
|
9511
8863
|
applyContentLayout();
|
|
9512
8864
|
notifyHostedResize();
|
|
9513
8865
|
};
|
|
9514
8866
|
const moveBy = (dx, dy) => {
|
|
9515
|
-
|
|
9516
|
-
|
|
8867
|
+
x += dx;
|
|
8868
|
+
y += dy;
|
|
9517
8869
|
applyPositionAndSize();
|
|
9518
8870
|
};
|
|
9519
8871
|
const resizeBy = (dw, dh) => {
|
|
@@ -9594,11 +8946,12 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9594
8946
|
const applyShellStyle = () => {
|
|
9595
8947
|
if (!shellEl)
|
|
9596
8948
|
return;
|
|
9597
|
-
shellEl.style.left = `${
|
|
9598
|
-
shellEl.style.top = `${
|
|
8949
|
+
shellEl.style.left = `${x}px`;
|
|
8950
|
+
shellEl.style.top = `${y}px`;
|
|
9599
8951
|
shellEl.style.width = `${width}px`;
|
|
9600
8952
|
shellEl.style.height = `${height}px`;
|
|
9601
8953
|
shellEl.style.display = currentArgs.active ? "flex" : "none";
|
|
8954
|
+
shellEl.style.setProperty("--pie-tool-shell-zoom-comp", String(currentCalculatorZoomCompensation()));
|
|
9602
8955
|
};
|
|
9603
8956
|
const mountContent = () => {
|
|
9604
8957
|
if (!contentEl)
|
|
@@ -9641,24 +8994,24 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9641
8994
|
const verticalMargin = margin + 60;
|
|
9642
8995
|
switch (align) {
|
|
9643
8996
|
case "top-left":
|
|
9644
|
-
|
|
9645
|
-
|
|
8997
|
+
x = margin;
|
|
8998
|
+
y = verticalMargin;
|
|
9646
8999
|
break;
|
|
9647
9000
|
case "top-right":
|
|
9648
|
-
|
|
9649
|
-
|
|
9001
|
+
x = Math.max(0, viewportW - width - margin);
|
|
9002
|
+
y = verticalMargin;
|
|
9650
9003
|
break;
|
|
9651
9004
|
case "bottom-left":
|
|
9652
|
-
|
|
9653
|
-
|
|
9005
|
+
x = margin;
|
|
9006
|
+
y = Math.max(0, viewportH - height - verticalMargin);
|
|
9654
9007
|
break;
|
|
9655
9008
|
case "bottom-right":
|
|
9656
|
-
|
|
9657
|
-
|
|
9009
|
+
x = Math.max(0, viewportW - width - margin);
|
|
9010
|
+
y = Math.max(0, viewportH - height - verticalMargin);
|
|
9658
9011
|
break;
|
|
9659
9012
|
default:
|
|
9660
|
-
|
|
9661
|
-
|
|
9013
|
+
x = Math.max(0, Math.round((viewportW - width) / 2));
|
|
9014
|
+
y = Math.max(0, Math.round((viewportH - height) / 2));
|
|
9662
9015
|
}
|
|
9663
9016
|
applyPositionAndSize();
|
|
9664
9017
|
};
|
|
@@ -9823,8 +9176,8 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9823
9176
|
return;
|
|
9824
9177
|
event2.preventDefault();
|
|
9825
9178
|
dragPointerId = event2.pointerId;
|
|
9826
|
-
dragOffsetX = event2.clientX -
|
|
9827
|
-
dragOffsetY = event2.clientY -
|
|
9179
|
+
dragOffsetX = event2.clientX - x;
|
|
9180
|
+
dragOffsetY = event2.clientY - y;
|
|
9828
9181
|
shellEl.setPointerCapture(event2.pointerId);
|
|
9829
9182
|
bringToFront();
|
|
9830
9183
|
};
|
|
@@ -9839,8 +9192,8 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9839
9192
|
resizeStartHeight = height;
|
|
9840
9193
|
resizeStartX = event2.clientX;
|
|
9841
9194
|
resizeStartY = event2.clientY;
|
|
9842
|
-
resizeStartShellX =
|
|
9843
|
-
resizeStartShellY =
|
|
9195
|
+
resizeStartShellX = x;
|
|
9196
|
+
resizeStartShellY = y;
|
|
9844
9197
|
shellEl.setPointerCapture(event2.pointerId);
|
|
9845
9198
|
bringToFront();
|
|
9846
9199
|
};
|
|
@@ -9851,8 +9204,8 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9851
9204
|
event2.preventDefault();
|
|
9852
9205
|
const maxX = Math.max(0, window.innerWidth - width);
|
|
9853
9206
|
const maxY = Math.max(0, window.innerHeight - height);
|
|
9854
|
-
|
|
9855
|
-
|
|
9207
|
+
x = clamp(event2.clientX - dragOffsetX, 0, maxX);
|
|
9208
|
+
y = clamp(event2.clientY - dragOffsetY, 0, maxY);
|
|
9856
9209
|
applyShellStyle();
|
|
9857
9210
|
return;
|
|
9858
9211
|
}
|
|
@@ -9868,28 +9221,28 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9868
9221
|
const dx = event2.clientX - resizeStartX;
|
|
9869
9222
|
const dy = event2.clientY - resizeStartY;
|
|
9870
9223
|
if (resizeCorner === "se") {
|
|
9871
|
-
width = clamp(resizeStartWidth + dx, minWidth, Math.max(minWidth, Math.min(maxWidth, window.innerWidth -
|
|
9872
|
-
height = clamp(resizeStartHeight + dy, minHeight, Math.max(minHeight, Math.min(maxHeight, window.innerHeight -
|
|
9224
|
+
width = clamp(resizeStartWidth + dx, minWidth, Math.max(minWidth, Math.min(maxWidth, window.innerWidth - x)));
|
|
9225
|
+
height = clamp(resizeStartHeight + dy, minHeight, Math.max(minHeight, Math.min(maxHeight, window.innerHeight - y)));
|
|
9873
9226
|
} else if (resizeCorner === "sw") {
|
|
9874
9227
|
const rightEdge = resizeStartShellX + resizeStartWidth;
|
|
9875
9228
|
const newWidth = clamp(resizeStartWidth - dx, minWidth, Math.min(maxWidth, rightEdge));
|
|
9876
|
-
|
|
9229
|
+
x = rightEdge - newWidth;
|
|
9877
9230
|
width = newWidth;
|
|
9878
|
-
height = clamp(resizeStartHeight + dy, minHeight, Math.max(minHeight, Math.min(maxHeight, window.innerHeight -
|
|
9231
|
+
height = clamp(resizeStartHeight + dy, minHeight, Math.max(minHeight, Math.min(maxHeight, window.innerHeight - y)));
|
|
9879
9232
|
} else if (resizeCorner === "ne") {
|
|
9880
9233
|
const bottomEdge = resizeStartShellY + resizeStartHeight;
|
|
9881
|
-
width = clamp(resizeStartWidth + dx, minWidth, Math.max(minWidth, Math.min(maxWidth, window.innerWidth -
|
|
9234
|
+
width = clamp(resizeStartWidth + dx, minWidth, Math.max(minWidth, Math.min(maxWidth, window.innerWidth - x)));
|
|
9882
9235
|
const newHeight = clamp(resizeStartHeight - dy, minHeight, Math.min(maxHeight, bottomEdge));
|
|
9883
|
-
|
|
9236
|
+
y = bottomEdge - newHeight;
|
|
9884
9237
|
height = newHeight;
|
|
9885
9238
|
} else if (resizeCorner === "nw") {
|
|
9886
9239
|
const rightEdge = resizeStartShellX + resizeStartWidth;
|
|
9887
9240
|
const bottomEdge = resizeStartShellY + resizeStartHeight;
|
|
9888
9241
|
const newWidth = clamp(resizeStartWidth - dx, minWidth, Math.min(maxWidth, rightEdge));
|
|
9889
|
-
|
|
9242
|
+
x = rightEdge - newWidth;
|
|
9890
9243
|
width = newWidth;
|
|
9891
9244
|
const newHeight = clamp(resizeStartHeight - dy, minHeight, Math.min(maxHeight, bottomEdge));
|
|
9892
|
-
|
|
9245
|
+
y = bottomEdge - newHeight;
|
|
9893
9246
|
height = newHeight;
|
|
9894
9247
|
}
|
|
9895
9248
|
applyShellStyle();
|
|
@@ -9915,7 +9268,8 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9915
9268
|
};
|
|
9916
9269
|
if (isBrowser && currentArgs.mounted.entry.shell) {
|
|
9917
9270
|
const isCalculatorShell = currentArgs.mounted.toolId === "calculator";
|
|
9918
|
-
|
|
9271
|
+
const useNdsShellIcons = isCalculatorShell && get2(useNdsIcons);
|
|
9272
|
+
if (useNdsShellIcons)
|
|
9919
9273
|
ensureNdsAssets();
|
|
9920
9274
|
shellEl = document.createElement("div");
|
|
9921
9275
|
shellEl.className = "pie-tool-shell";
|
|
@@ -9974,7 +9328,7 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9974
9328
|
const appendControl = (label, glyph, iconName, onActivate, faVariant = "fa-regular") => {
|
|
9975
9329
|
if (!controlsEl)
|
|
9976
9330
|
return;
|
|
9977
|
-
controlsEl.appendChild(
|
|
9331
|
+
controlsEl.appendChild(useNdsShellIcons ? createShellIconButton(label, iconName, onActivate, faVariant) : createShellControlButton(label, glyph, onActivate));
|
|
9978
9332
|
};
|
|
9979
9333
|
if (shellConfig?.draggable !== false) {
|
|
9980
9334
|
appendControl("Move tool left", "←", "chevron-left", () => moveBy(-24, 0));
|
|
@@ -9996,12 +9350,13 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
9996
9350
|
rightClusterEl.style.display = "inline-flex";
|
|
9997
9351
|
rightClusterEl.style.alignItems = "center";
|
|
9998
9352
|
rightClusterEl.style.gap = "6px";
|
|
9353
|
+
rightClusterEl.style.setProperty("zoom", "var(--pie-tool-shell-zoom-comp, 1)");
|
|
9999
9354
|
rightClusterEl.appendChild(controlsEl);
|
|
10000
9355
|
headerEl.appendChild(rightClusterEl);
|
|
10001
9356
|
} else {
|
|
10002
9357
|
headerEl.appendChild(controlsEl);
|
|
10003
9358
|
}
|
|
10004
|
-
if (
|
|
9359
|
+
if (useNdsShellIcons) {
|
|
10005
9360
|
closeButtonEl = createShellIconButton("Close tool", "xmark", closeShell, "fa-regular");
|
|
10006
9361
|
closeButtonEl.style.display = currentArgs.mounted.entry.shell.closeable === false ? "none" : "inline-block";
|
|
10007
9362
|
} else {
|
|
@@ -10035,7 +9390,7 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10035
9390
|
closeButton.style.cursor = "pointer";
|
|
10036
9391
|
closeButton.style.display = "inline-flex";
|
|
10037
9392
|
closeButton.style.alignItems = "center";
|
|
10038
|
-
closeButton.style.
|
|
9393
|
+
closeButton.style.justifyItems = "center";
|
|
10039
9394
|
closeButton.style.width = "28px";
|
|
10040
9395
|
closeButton.style.height = "28px";
|
|
10041
9396
|
closeButton.style.padding = "0";
|
|
@@ -10382,7 +9737,7 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10382
9737
|
var fragment = comment();
|
|
10383
9738
|
var node_1 = first_child(fragment);
|
|
10384
9739
|
{
|
|
10385
|
-
var
|
|
9740
|
+
var consequent_14 = ($$anchor2) => {
|
|
10386
9741
|
var div = root_10();
|
|
10387
9742
|
let classes;
|
|
10388
9743
|
var div_1 = child(div);
|
|
@@ -10392,12 +9747,17 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10392
9747
|
var node_3 = first_child(fragment_1);
|
|
10393
9748
|
{
|
|
10394
9749
|
var consequent = ($$anchor4) => {
|
|
10395
|
-
var
|
|
10396
|
-
|
|
10397
|
-
|
|
10398
|
-
|
|
10399
|
-
|
|
10400
|
-
|
|
9750
|
+
var fragment_2 = comment();
|
|
9751
|
+
var node_4 = first_child(fragment_2);
|
|
9752
|
+
key(node_4, () => get2(useNdsIcons), ($$anchor5) => {
|
|
9753
|
+
var span = root_1();
|
|
9754
|
+
action(span, ($$node, $$action_arg) => mountElementWithShell?.($$node, $$action_arg), () => ({
|
|
9755
|
+
mounted: get2(mounted),
|
|
9756
|
+
active: get2(renderedToolActiveById)[get2(mounted).toolId] ?? false
|
|
9757
|
+
}));
|
|
9758
|
+
append($$anchor5, span);
|
|
9759
|
+
});
|
|
9760
|
+
append($$anchor4, fragment_2);
|
|
10401
9761
|
};
|
|
10402
9762
|
var alternate = ($$anchor4) => {
|
|
10403
9763
|
var span_1 = root_1();
|
|
@@ -10413,32 +9773,47 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10413
9773
|
}
|
|
10414
9774
|
append($$anchor3, fragment_1);
|
|
10415
9775
|
});
|
|
10416
|
-
var
|
|
10417
|
-
each(
|
|
10418
|
-
|
|
10419
|
-
var
|
|
9776
|
+
var node_5 = sibling(node_2, 2);
|
|
9777
|
+
each(node_5, 17, () => get2(toolbarItems), (item2) => item2.id, ($$anchor3, item2, $$index_1, $$array) => {
|
|
9778
|
+
const faIconName = user_derived(() => get2(useNdsIcons) && !isToolbarLinkItem(get2(item2)) ? resolveFaIconName(get2(item2)) : null);
|
|
9779
|
+
var fragment_3 = comment();
|
|
9780
|
+
var node_6 = first_child(fragment_3);
|
|
10420
9781
|
{
|
|
9782
|
+
var consequent_1 = ($$anchor4) => {
|
|
9783
|
+
var span_2 = root_2();
|
|
9784
|
+
var nds_icon_button = child(span_2);
|
|
9785
|
+
set_class(nds_icon_button, 1, "item-toolbar__nds-button svelte-rnx3ie");
|
|
9786
|
+
set_custom_element_data(nds_icon_button, "type", "circle");
|
|
9787
|
+
set_custom_element_data(nds_icon_button, "size", "small");
|
|
9788
|
+
set_custom_element_data(nds_icon_button, "variant", "tertiary");
|
|
9789
|
+
template_effect(() => set_custom_element_data(nds_icon_button, "icon-name", get2(faIconName)));
|
|
9790
|
+
template_effect(() => set_custom_element_data(nds_icon_button, "button-aria-label", get2(item2).ariaLabel || get2(item2).label));
|
|
9791
|
+
template_effect(() => set_custom_element_data(nds_icon_button, "title", get2(item2).tooltip || get2(item2).label));
|
|
9792
|
+
template_effect(() => set_custom_element_data(nds_icon_button, "disabled", get2(item2).disabled));
|
|
9793
|
+
action(nds_icon_button, ($$node) => ndsIconButtonAction?.($$node));
|
|
9794
|
+
action(nds_icon_button, ($$node, $$action_arg) => reflectToggleState?.($$node, $$action_arg), () => isToolbarItemActive(get2(item2)));
|
|
9795
|
+
reset(span_2);
|
|
9796
|
+
delegated("click", nds_icon_button, function(...$$args) {
|
|
9797
|
+
get2(item2).onClick?.apply(this, $$args);
|
|
9798
|
+
});
|
|
9799
|
+
append($$anchor4, span_2);
|
|
9800
|
+
};
|
|
10421
9801
|
var consequent_6 = ($$anchor4) => {
|
|
10422
9802
|
var a = root_6();
|
|
10423
9803
|
let classes_1;
|
|
10424
|
-
var
|
|
9804
|
+
var node_7 = child(a);
|
|
10425
9805
|
{
|
|
10426
9806
|
var consequent_5 = ($$anchor5) => {
|
|
10427
|
-
var
|
|
10428
|
-
var
|
|
9807
|
+
var fragment_4 = comment();
|
|
9808
|
+
var node_8 = first_child(fragment_4);
|
|
10429
9809
|
{
|
|
10430
|
-
var consequent_1 = ($$anchor6) => {
|
|
10431
|
-
var span_2 = root_2();
|
|
10432
|
-
action(span_2, ($$node) => ndsIconButtonAction?.($$node));
|
|
10433
|
-
append($$anchor6, span_2);
|
|
10434
|
-
};
|
|
10435
9810
|
var consequent_2 = ($$anchor6) => {
|
|
10436
9811
|
var span_3 = root_3();
|
|
10437
9812
|
html(span_3, () => sanitizeSvgIcon(get2(item2).icon), true);
|
|
10438
9813
|
reset(span_3);
|
|
10439
9814
|
append($$anchor6, span_3);
|
|
10440
9815
|
};
|
|
10441
|
-
var
|
|
9816
|
+
var d = user_derived(() => isInlineSvgIcon(get2(item2).icon));
|
|
10442
9817
|
var consequent_3 = ($$anchor6) => {
|
|
10443
9818
|
var img = root_4();
|
|
10444
9819
|
template_effect(() => set_attribute2(img, "src", get2(item2).icon));
|
|
@@ -10447,8 +9822,8 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10447
9822
|
var d_1 = user_derived(() => isExternalIconUrl(get2(item2).icon));
|
|
10448
9823
|
var alternate_2 = ($$anchor6) => {
|
|
10449
9824
|
const fallbackIcon = user_derived(() => getFallbackIconSvg(get2(item2).icon));
|
|
10450
|
-
var
|
|
10451
|
-
var
|
|
9825
|
+
var fragment_5 = comment();
|
|
9826
|
+
var node_9 = first_child(fragment_5);
|
|
10452
9827
|
{
|
|
10453
9828
|
var consequent_4 = ($$anchor7) => {
|
|
10454
9829
|
var span_4 = root_3();
|
|
@@ -10461,29 +9836,27 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10461
9836
|
template_effect(() => set_class(i_1, 1, `icon icon-${get2(item2).icon}`, "svelte-rnx3ie"));
|
|
10462
9837
|
append($$anchor7, i_1);
|
|
10463
9838
|
};
|
|
10464
|
-
if_block(
|
|
9839
|
+
if_block(node_9, ($$render) => {
|
|
10465
9840
|
if (get2(fallbackIcon))
|
|
10466
9841
|
$$render(consequent_4);
|
|
10467
9842
|
else
|
|
10468
9843
|
$$render(alternate_1, -1);
|
|
10469
9844
|
});
|
|
10470
9845
|
}
|
|
10471
|
-
append($$anchor6,
|
|
9846
|
+
append($$anchor6, fragment_5);
|
|
10472
9847
|
};
|
|
10473
|
-
if_block(
|
|
10474
|
-
if (get2(
|
|
10475
|
-
$$render(
|
|
10476
|
-
else if (get2(d2))
|
|
10477
|
-
$$render(consequent_2, 1);
|
|
9848
|
+
if_block(node_8, ($$render) => {
|
|
9849
|
+
if (get2(d))
|
|
9850
|
+
$$render(consequent_2);
|
|
10478
9851
|
else if (get2(d_1))
|
|
10479
|
-
$$render(consequent_3,
|
|
9852
|
+
$$render(consequent_3, 1);
|
|
10480
9853
|
else
|
|
10481
9854
|
$$render(alternate_2, -1);
|
|
10482
9855
|
});
|
|
10483
9856
|
}
|
|
10484
|
-
append($$anchor5,
|
|
9857
|
+
append($$anchor5, fragment_4);
|
|
10485
9858
|
};
|
|
10486
|
-
if_block(
|
|
9859
|
+
if_block(node_7, ($$render) => {
|
|
10487
9860
|
if (get2(item2).icon)
|
|
10488
9861
|
$$render(consequent_5);
|
|
10489
9862
|
});
|
|
@@ -10513,25 +9886,20 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10513
9886
|
var alternate_5 = ($$anchor4) => {
|
|
10514
9887
|
var button_1 = root_7();
|
|
10515
9888
|
let classes_2;
|
|
10516
|
-
var
|
|
9889
|
+
var node_10 = child(button_1);
|
|
10517
9890
|
{
|
|
10518
|
-
var
|
|
10519
|
-
var
|
|
10520
|
-
var
|
|
9891
|
+
var consequent_10 = ($$anchor5) => {
|
|
9892
|
+
var fragment_6 = comment();
|
|
9893
|
+
var node_11 = first_child(fragment_6);
|
|
10521
9894
|
{
|
|
10522
9895
|
var consequent_7 = ($$anchor6) => {
|
|
10523
|
-
var span_5 =
|
|
10524
|
-
|
|
9896
|
+
var span_5 = root_3();
|
|
9897
|
+
html(span_5, () => sanitizeSvgIcon(get2(item2).icon), true);
|
|
9898
|
+
reset(span_5);
|
|
10525
9899
|
append($$anchor6, span_5);
|
|
10526
9900
|
};
|
|
10527
|
-
var consequent_8 = ($$anchor6) => {
|
|
10528
|
-
var span_6 = root_3();
|
|
10529
|
-
html(span_6, () => sanitizeSvgIcon(get2(item2).icon), true);
|
|
10530
|
-
reset(span_6);
|
|
10531
|
-
append($$anchor6, span_6);
|
|
10532
|
-
};
|
|
10533
9901
|
var d_3 = user_derived(() => isInlineSvgIcon(get2(item2).icon));
|
|
10534
|
-
var
|
|
9902
|
+
var consequent_8 = ($$anchor6) => {
|
|
10535
9903
|
var img_1 = root_4();
|
|
10536
9904
|
template_effect(() => set_attribute2(img_1, "src", get2(item2).icon));
|
|
10537
9905
|
append($$anchor6, img_1);
|
|
@@ -10539,45 +9907,43 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10539
9907
|
var d_4 = user_derived(() => isExternalIconUrl(get2(item2).icon));
|
|
10540
9908
|
var alternate_4 = ($$anchor6) => {
|
|
10541
9909
|
const fallbackIcon = user_derived(() => getFallbackIconSvg(get2(item2).icon));
|
|
10542
|
-
var
|
|
10543
|
-
var
|
|
9910
|
+
var fragment_7 = comment();
|
|
9911
|
+
var node_12 = first_child(fragment_7);
|
|
10544
9912
|
{
|
|
10545
|
-
var
|
|
10546
|
-
var
|
|
10547
|
-
html(
|
|
10548
|
-
reset(
|
|
10549
|
-
append($$anchor7,
|
|
9913
|
+
var consequent_9 = ($$anchor7) => {
|
|
9914
|
+
var span_6 = root_3();
|
|
9915
|
+
html(span_6, () => sanitizeSvgIcon(get2(fallbackIcon)), true);
|
|
9916
|
+
reset(span_6);
|
|
9917
|
+
append($$anchor7, span_6);
|
|
10550
9918
|
};
|
|
10551
9919
|
var alternate_3 = ($$anchor7) => {
|
|
10552
9920
|
var i_2 = root_5();
|
|
10553
9921
|
template_effect(() => set_class(i_2, 1, `icon icon-${get2(item2).icon}`, "svelte-rnx3ie"));
|
|
10554
9922
|
append($$anchor7, i_2);
|
|
10555
9923
|
};
|
|
10556
|
-
if_block(
|
|
9924
|
+
if_block(node_12, ($$render) => {
|
|
10557
9925
|
if (get2(fallbackIcon))
|
|
10558
|
-
$$render(
|
|
9926
|
+
$$render(consequent_9);
|
|
10559
9927
|
else
|
|
10560
9928
|
$$render(alternate_3, -1);
|
|
10561
9929
|
});
|
|
10562
9930
|
}
|
|
10563
|
-
append($$anchor6,
|
|
9931
|
+
append($$anchor6, fragment_7);
|
|
10564
9932
|
};
|
|
10565
|
-
if_block(
|
|
10566
|
-
if (get2(
|
|
9933
|
+
if_block(node_11, ($$render) => {
|
|
9934
|
+
if (get2(d_3))
|
|
10567
9935
|
$$render(consequent_7);
|
|
10568
|
-
else if (get2(d_3))
|
|
10569
|
-
$$render(consequent_8, 1);
|
|
10570
9936
|
else if (get2(d_4))
|
|
10571
|
-
$$render(
|
|
9937
|
+
$$render(consequent_8, 1);
|
|
10572
9938
|
else
|
|
10573
9939
|
$$render(alternate_4, -1);
|
|
10574
9940
|
});
|
|
10575
9941
|
}
|
|
10576
|
-
append($$anchor5,
|
|
9942
|
+
append($$anchor5, fragment_6);
|
|
10577
9943
|
};
|
|
10578
|
-
if_block(
|
|
9944
|
+
if_block(node_10, ($$render) => {
|
|
10579
9945
|
if (get2(item2).icon)
|
|
10580
|
-
$$render(
|
|
9946
|
+
$$render(consequent_10);
|
|
10581
9947
|
});
|
|
10582
9948
|
}
|
|
10583
9949
|
reset(button_1);
|
|
@@ -10598,73 +9964,85 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10598
9964
|
});
|
|
10599
9965
|
append($$anchor4, button_1);
|
|
10600
9966
|
};
|
|
10601
|
-
if_block(
|
|
10602
|
-
if (get2(
|
|
10603
|
-
$$render(
|
|
9967
|
+
if_block(node_6, ($$render) => {
|
|
9968
|
+
if (get2(faIconName))
|
|
9969
|
+
$$render(consequent_1);
|
|
9970
|
+
else if (get2(d_2))
|
|
9971
|
+
$$render(consequent_6, 1);
|
|
10604
9972
|
else
|
|
10605
9973
|
$$render(alternate_5, -1);
|
|
10606
9974
|
});
|
|
10607
9975
|
}
|
|
10608
|
-
append($$anchor3,
|
|
9976
|
+
append($$anchor3, fragment_3);
|
|
10609
9977
|
});
|
|
10610
|
-
var
|
|
10611
|
-
each(
|
|
10612
|
-
var
|
|
10613
|
-
var
|
|
9978
|
+
var node_13 = sibling(node_5, 2);
|
|
9979
|
+
each(node_13, 17, () => get2(mountedElementsAfterButtons), (mounted) => mounted.key, ($$anchor3, mounted) => {
|
|
9980
|
+
var fragment_8 = comment();
|
|
9981
|
+
var node_14 = first_child(fragment_8);
|
|
10614
9982
|
{
|
|
10615
|
-
var
|
|
10616
|
-
var
|
|
10617
|
-
|
|
10618
|
-
|
|
10619
|
-
|
|
10620
|
-
|
|
10621
|
-
|
|
9983
|
+
var consequent_11 = ($$anchor4) => {
|
|
9984
|
+
var fragment_9 = comment();
|
|
9985
|
+
var node_15 = first_child(fragment_9);
|
|
9986
|
+
key(node_15, () => get2(useNdsIcons), ($$anchor5) => {
|
|
9987
|
+
var span_7 = root_1();
|
|
9988
|
+
action(span_7, ($$node, $$action_arg) => mountElementWithShell?.($$node, $$action_arg), () => ({
|
|
9989
|
+
mounted: get2(mounted),
|
|
9990
|
+
active: get2(renderedToolActiveById)[get2(mounted).toolId] ?? false
|
|
9991
|
+
}));
|
|
9992
|
+
append($$anchor5, span_7);
|
|
9993
|
+
});
|
|
9994
|
+
append($$anchor4, fragment_9);
|
|
10622
9995
|
};
|
|
10623
9996
|
var alternate_6 = ($$anchor4) => {
|
|
10624
|
-
var
|
|
10625
|
-
action(
|
|
10626
|
-
append($$anchor4,
|
|
9997
|
+
var span_8 = root_1();
|
|
9998
|
+
action(span_8, ($$node, $$action_arg) => mountElement?.($$node, $$action_arg), () => get2(mounted).entry.element);
|
|
9999
|
+
append($$anchor4, span_8);
|
|
10627
10000
|
};
|
|
10628
|
-
if_block(
|
|
10001
|
+
if_block(node_14, ($$render) => {
|
|
10629
10002
|
if (get2(mounted).entry.shell)
|
|
10630
|
-
$$render(
|
|
10003
|
+
$$render(consequent_11);
|
|
10631
10004
|
else
|
|
10632
10005
|
$$render(alternate_6, -1);
|
|
10633
10006
|
});
|
|
10634
10007
|
}
|
|
10635
|
-
append($$anchor3,
|
|
10008
|
+
append($$anchor3, fragment_8);
|
|
10636
10009
|
});
|
|
10637
10010
|
reset(div_1);
|
|
10638
|
-
var
|
|
10011
|
+
var node_16 = sibling(div_1, 2);
|
|
10639
10012
|
{
|
|
10640
|
-
var
|
|
10013
|
+
var consequent_13 = ($$anchor3) => {
|
|
10641
10014
|
var div_2 = root_9();
|
|
10642
10015
|
let classes_3;
|
|
10643
10016
|
each(div_2, 21, () => get2(mountedElementsControlsRow), (mounted) => mounted.key, ($$anchor4, mounted) => {
|
|
10644
|
-
var
|
|
10645
|
-
var
|
|
10017
|
+
var fragment_10 = comment();
|
|
10018
|
+
var node_17 = first_child(fragment_10);
|
|
10646
10019
|
{
|
|
10647
|
-
var
|
|
10648
|
-
var
|
|
10649
|
-
|
|
10650
|
-
|
|
10651
|
-
|
|
10652
|
-
|
|
10653
|
-
|
|
10020
|
+
var consequent_12 = ($$anchor5) => {
|
|
10021
|
+
var fragment_11 = comment();
|
|
10022
|
+
var node_18 = first_child(fragment_11);
|
|
10023
|
+
key(node_18, () => get2(useNdsIcons), ($$anchor6) => {
|
|
10024
|
+
var span_9 = root_8();
|
|
10025
|
+
action(span_9, ($$node, $$action_arg) => mountElementWithShell?.($$node, $$action_arg), () => ({
|
|
10026
|
+
mounted: get2(mounted),
|
|
10027
|
+
active: get2(renderedToolActiveById)[get2(mounted).toolId] ?? false
|
|
10028
|
+
}));
|
|
10029
|
+
append($$anchor6, span_9);
|
|
10030
|
+
});
|
|
10031
|
+
append($$anchor5, fragment_11);
|
|
10654
10032
|
};
|
|
10655
10033
|
var alternate_7 = ($$anchor5) => {
|
|
10656
|
-
var
|
|
10657
|
-
action(
|
|
10658
|
-
append($$anchor5,
|
|
10034
|
+
var span_10 = root_8();
|
|
10035
|
+
action(span_10, ($$node, $$action_arg) => mountElement?.($$node, $$action_arg), () => get2(mounted).entry.element);
|
|
10036
|
+
append($$anchor5, span_10);
|
|
10659
10037
|
};
|
|
10660
|
-
if_block(
|
|
10038
|
+
if_block(node_17, ($$render) => {
|
|
10661
10039
|
if (get2(mounted).entry.shell)
|
|
10662
|
-
$$render(
|
|
10040
|
+
$$render(consequent_12);
|
|
10663
10041
|
else
|
|
10664
10042
|
$$render(alternate_7, -1);
|
|
10665
10043
|
});
|
|
10666
10044
|
}
|
|
10667
|
-
append($$anchor4,
|
|
10045
|
+
append($$anchor4, fragment_10);
|
|
10668
10046
|
});
|
|
10669
10047
|
reset(div_2);
|
|
10670
10048
|
template_effect(() => classes_3 = set_class(div_2, 1, "item-toolbar__controls-row svelte-rnx3ie", null, classes_3, {
|
|
@@ -10674,9 +10052,9 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10674
10052
|
}));
|
|
10675
10053
|
append($$anchor3, div_2);
|
|
10676
10054
|
};
|
|
10677
|
-
if_block(
|
|
10055
|
+
if_block(node_16, ($$render) => {
|
|
10678
10056
|
if (get2(shouldRenderControlsRow))
|
|
10679
|
-
$$render(
|
|
10057
|
+
$$render(consequent_13);
|
|
10680
10058
|
});
|
|
10681
10059
|
}
|
|
10682
10060
|
reset(div);
|
|
@@ -10691,12 +10069,13 @@ function ItemToolBar($$anchor, $$props) {
|
|
|
10691
10069
|
});
|
|
10692
10070
|
set_attribute2(div, "data-content-kind", get2(effectiveContentKind));
|
|
10693
10071
|
set_attribute2(div, "data-level", get2(effectiveLevel));
|
|
10072
|
+
set_style(div, `--pie-toolbar-zoom-comp: ${get2(calculatorButtonZoomComp)};`);
|
|
10694
10073
|
});
|
|
10695
10074
|
append($$anchor2, div);
|
|
10696
10075
|
};
|
|
10697
10076
|
if_block(node_1, ($$render) => {
|
|
10698
10077
|
if (isBrowser)
|
|
10699
|
-
$$render(
|
|
10078
|
+
$$render(consequent_14);
|
|
10700
10079
|
});
|
|
10701
10080
|
}
|
|
10702
10081
|
append($$anchor, fragment);
|