@uoguelph/web-components 2.0.2-rc.2 → 2.0.3-rc.0

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.
@@ -0,0 +1,101 @@
1
+ import { aq as E, a2 as R, ar as k, a8 as w, as as A, D as u, at as p, t as T, E as h, a1 as C, au as D, av as F, aw as N, ax as H, ay as v, az as I, aA as O, aB as d, aC as $, aD as q, A as m, y as z, aE as B, aF as g, m as b, aG as G, aH as P, aI as S } from "./index-BC4Hvd0S.js";
2
+ function j(f, t, ...a) {
3
+ var n = f, r = w, e;
4
+ E(() => {
5
+ r !== (r = t()) && (e && (A(e), e = null), e = k(() => (
6
+ /** @type {SnippetFn} */
7
+ r(n, ...a)
8
+ )));
9
+ }, R), u && (n = p);
10
+ }
11
+ function J(f, t, a = !1, n = !1, r = !1) {
12
+ var e = f, _ = "";
13
+ T(() => {
14
+ var o = (
15
+ /** @type {Effect} */
16
+ C
17
+ );
18
+ if (_ === (_ = t() ?? "")) {
19
+ u && h();
20
+ return;
21
+ }
22
+ if (o.nodes_start !== null && (D(
23
+ o.nodes_start,
24
+ /** @type {TemplateNode} */
25
+ o.nodes_end
26
+ ), o.nodes_start = o.nodes_end = null), _ !== "") {
27
+ if (u) {
28
+ p.data;
29
+ for (var s = h(), i = s; s !== null && (s.nodeType !== 8 || /** @type {Comment} */
30
+ s.data !== ""); )
31
+ i = s, s = /** @type {TemplateNode} */
32
+ F(s);
33
+ if (s === null)
34
+ throw N(), H;
35
+ v(p, i), e = I(s);
36
+ return;
37
+ }
38
+ var c = _ + "";
39
+ a ? c = `<svg>${c}</svg>` : n && (c = `<math>${c}</math>`);
40
+ var l = O(c);
41
+ if ((a || n) && (l = /** @type {Element} */
42
+ d(l)), v(
43
+ /** @type {TemplateNode} */
44
+ d(l),
45
+ /** @type {TemplateNode} */
46
+ l.lastChild
47
+ ), a || n)
48
+ for (; d(l); )
49
+ e.before(
50
+ /** @type {Node} */
51
+ d(l)
52
+ );
53
+ else
54
+ e.before(l);
55
+ }
56
+ });
57
+ }
58
+ function K(f = !1) {
59
+ const t = (
60
+ /** @type {ComponentContextLegacy} */
61
+ $
62
+ ), a = t.l.u;
63
+ if (!a) return;
64
+ let n = () => G(t.s);
65
+ if (f) {
66
+ let r = 0, e = (
67
+ /** @type {Record<string, any>} */
68
+ {}
69
+ );
70
+ const _ = P(() => {
71
+ let o = !1;
72
+ const s = t.s;
73
+ for (const i in s)
74
+ s[i] !== e[i] && (e[i] = s[i], o = !0);
75
+ return o && r++, r;
76
+ });
77
+ n = () => b(_);
78
+ }
79
+ a.b.length && q(() => {
80
+ y(t, n), g(a.b);
81
+ }), m(() => {
82
+ const r = z(() => a.m.map(B));
83
+ return () => {
84
+ for (const e of r)
85
+ typeof e == "function" && e();
86
+ };
87
+ }), a.a.length && m(() => {
88
+ y(t, n), g(a.a);
89
+ });
90
+ }
91
+ function y(f, t) {
92
+ if (f.l.s)
93
+ for (const a of f.l.s) b(a);
94
+ t();
95
+ }
96
+ S();
97
+ export {
98
+ J as h,
99
+ K as i,
100
+ j as s
101
+ };
@@ -1,4 +1,4 @@
1
- import { E as r, G as l } from "./index-DRgQEdAt.js";
1
+ import { D as r, E as l } from "./index-BC4Hvd0S.js";
2
2
  function d(i, t, e, s, o) {
3
3
  var a;
4
4
  r && l();
@@ -1,13 +1,13 @@
1
- import { c as q, p as A, a as B, b as p, t as D, F as G, f as H, s as c, d as s, e as I, g as o, h as a, i as J, j as K, k as L, r as l } from "./index-DRgQEdAt.js";
2
- import { s as N, a as d } from "./slot-DcbTlwnX.js";
3
- import { o as O } from "./index-client-CgOvkiBi.js";
4
- import { c as P } from "./index-O5kp37c8.js";
1
+ import { c as q, p as A, a as B, b as p, f as D, F as G, d as H, s as c, e as o, t as I, g as s, h as a, i as J, j as K, k as L, r as l } from "./index-BC4Hvd0S.js";
2
+ import { o as N } from "./index-client-BZkvD-WT.js";
3
+ import { s as O, a as d } from "./slot-BUAAktv8.js";
4
+ import { c as P } from "./index-v9RZCFpF.js";
5
5
  var Q = D("<div><div><!> <!></div> <div><!> <span><!></span></div> <div><!></div></div>");
6
6
  function V(m, t) {
7
- const e = N(t);
7
+ const e = O(t);
8
8
  A(t, !0);
9
9
  let g = B(t, "color", 7, "red");
10
- O(() => {
10
+ N(() => {
11
11
  p(t.$$host.shadowRoot);
12
12
  });
13
13
  const y = P({
@@ -27,39 +27,43 @@ function V(m, t) {
27
27
  }
28
28
  }
29
29
  }), { base: w, title: E, content: F, message: R, footer: S } = y({ color: g() });
30
- var r = Q(), n = s(r), f = s(n);
31
- G(f, { icon: H });
32
- var j = c(f, 2);
30
+ var r = Q(), n = o(r), v = o(n);
31
+ G(v, {
32
+ get icon() {
33
+ return H;
34
+ }
35
+ });
36
+ var j = c(v, 2);
33
37
  d(j, t, "title", {}), l(n);
34
38
  var i = c(n, 2);
35
39
  let x;
36
- var h = s(i);
40
+ var h = o(i);
37
41
  d(h, t, "subtitle", {});
38
- var u = c(h, 2), k = s(u);
42
+ var u = c(h, 2), k = o(u);
39
43
  d(k, t, "message", {}), l(u), l(i);
40
44
  var b = c(i, 2);
41
45
  let _;
42
- var z = s(b);
46
+ var z = o(b);
43
47
  return d(z, t, "footer", {}), l(b), l(r), I(
44
- (v, C, M, T, U) => {
45
- a(r, 1, v), a(n, 1, C), x = a(i, 1, M, null, x, { "border-b": !(e != null && e.footer) }), a(u, 1, T), _ = a(b, 1, U, null, _, {
48
+ (f, C, M, T, U) => {
49
+ a(r, 1, f), a(n, 1, C), x = a(i, 1, M, null, x, { "border-b": !(e != null && e.footer) }), a(u, 1, T), _ = a(b, 1, U, null, _, {
46
50
  "px-4": e == null ? void 0 : e.footer,
47
51
  "py-2": e == null ? void 0 : e.footer
48
52
  });
49
53
  },
50
54
  [
51
- () => o(w()),
52
- () => o(E()),
53
- () => o(F()),
54
- () => o(R()),
55
- () => o(S())
55
+ () => s(w()),
56
+ () => s(E()),
57
+ () => s(F()),
58
+ () => s(R()),
59
+ () => s(S())
56
60
  ]
57
61
  ), J(m, r), K({
58
62
  get color() {
59
63
  return g();
60
64
  },
61
- set color(v = "red") {
62
- g(v), L();
65
+ set color(f = "red") {
66
+ g(f), L();
63
67
  }
64
68
  });
65
69
  }
@@ -1,14 +1,14 @@
1
- import { l as b, c as u, t as f, F as m, e as v, m as o, i as h, j as _, p as g, n as x, g as w, o as k, h as y, q as T, u as j, v as F, d as c, r as i, w as U, b as q } from "./index-DRgQEdAt.js";
2
- import { b as z } from "./window-CDUGRBpm.js";
3
- import { c as B } from "./index-O5kp37c8.js";
4
- const C = () => {
1
+ import { l as d, c as u, p as f, f as m, F as h, t as v, m as a, i as _, j as g, n as x, g as w, u as k, h as y, o as T, q as j, e as c, r as i, v as F, b as U } from "./index-BC4Hvd0S.js";
2
+ import { b as q } from "./window-b9wVA2Rv.js";
3
+ import { c as z } from "./index-v9RZCFpF.js";
4
+ const B = () => {
5
5
  window.scroll({ top: 0, left: 0, behavior: "smooth" });
6
6
  };
7
- var E = f('<button><span aria-hidden="true"><!></span> <span class="sr-only">Back to top of page</span></button>');
8
- function R(e, n) {
9
- g(n, !0);
10
- let s = F(0), l = k(() => o(s) > 50);
11
- const p = B({
7
+ var C = m('<button><span aria-hidden="true"><!></span> <span class="sr-only">Back to top of page</span></button>');
8
+ function E(e, n) {
9
+ f(n, !0);
10
+ let s = j(0), l = k(() => a(s) > 50);
11
+ const p = z({
12
12
  base: "fixed right-8 bottom-8 z-10 flex h-10 w-10 items-center justify-center border border-white bg-black text-lg text-black-contrast transition hover:bg-red hover:text-red-contrast focus:bg-red focus:text-red-contrast",
13
13
  variants: {
14
14
  visible: {
@@ -17,19 +17,23 @@ function R(e, n) {
17
17
  }
18
18
  }
19
19
  });
20
- var t = E();
21
- t.__click = [C];
22
- var r = c(t), d = c(r);
23
- m(d, { icon: x }), i(r), U(2), i(t), v((a) => y(t, 1, a), [
24
- () => w(p({ visible: o(l) }))
25
- ]), z("y", () => o(s), (a) => T(s, j(a))), h(e, t), _();
20
+ var t = C();
21
+ t.__click = [B];
22
+ var r = c(t), b = c(r);
23
+ h(b, {
24
+ get icon() {
25
+ return x;
26
+ }
27
+ }), i(r), F(2), i(t), v((o) => y(t, 1, o), [
28
+ () => w(p({ visible: a(l) }))
29
+ ]), q("y", () => a(s), (o) => T(s, o, !0)), _(e, t), g();
26
30
  }
27
- b(["click"]);
28
- customElements.define("uofg-back-to-top", u(R, {}, [], [], !0, (e) => class extends e {
31
+ d(["click"]);
32
+ customElements.define("uofg-back-to-top", u(E, {}, [], [], !0, (e) => class extends e {
29
33
  constructor() {
30
- super(), q(this.shadowRoot);
34
+ super(), U(this.shadowRoot);
31
35
  }
32
36
  }));
33
37
  export {
34
- R as default
38
+ E as default
35
39
  };