@uoguelph/web-components 1.3.0-rc.3 → 1.4.0-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.
- package/dist/uofg-web-components/globals-DnYjtinb.js +7 -0
- package/dist/uofg-web-components/{index-Bx5sKUFM.js → index-SbK7yJqm.js} +85 -80
- package/dist/uofg-web-components/uofg-alert.esm.js +1 -1
- package/dist/uofg-web-components/uofg-back-to-top.esm.js +95 -0
- package/dist/uofg-web-components/uofg-footer.esm.js +12 -12
- package/dist/uofg-web-components/uofg-header.esm.js +267 -270
- package/dist/uofg-web-components/uofg-modal.esm.js +12 -12
- package/dist/uofg-web-components/uofg-web-components.css +1 -1
- package/dist/uofg-web-components/uofg-web-components.esm.js +7 -54
- package/package.json +8 -14
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { c as z, S as j, i as R,
|
|
1
|
+
import { c as z, S as j, i as R, A as m, a as U, s as K, F as N, a6 as G, b as H, e as E, d as I, g as J, h as r, a2 as _, j as L, k as B, m as M, w as k, u as P, l as Q, n as V, t as v, o as A, p as W, q as X, x as Y, $ as C } from "./index-SbK7yJqm.js";
|
|
2
2
|
const Z = (n) => Array.from(n.querySelectorAll('a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), iframe, object, embed, [contenteditable], audio[controls], video[controls], details, summary, [tabindex]:not([tabindex="-1"])'));
|
|
3
3
|
function x(n) {
|
|
4
4
|
let e, i, c, b, u, p, g, w, l, y, h;
|
|
5
|
-
b = new N({ props: { icon:
|
|
5
|
+
b = new N({ props: { icon: G } });
|
|
6
6
|
const f = (
|
|
7
7
|
/*#slots*/
|
|
8
8
|
n[14].default
|
|
9
|
-
), a =
|
|
9
|
+
), a = H(
|
|
10
10
|
f,
|
|
11
11
|
n,
|
|
12
12
|
/*$$scope*/
|
|
@@ -15,7 +15,7 @@ function x(n) {
|
|
|
15
15
|
);
|
|
16
16
|
return {
|
|
17
17
|
c() {
|
|
18
|
-
e = E("div"), i = E("div"), c = E("button"),
|
|
18
|
+
e = E("div"), i = E("div"), c = E("button"), I(b.$$.fragment), u = J(), a && a.c(), r(c, "class", "absolute right-8 top-8 z-[2] flex h-12 w-12 items-center justify-center border-0 bg-transparent text-3xl p-2 text-[var(--uofg-modal-dismiss-color,white)]"), r(c, "part", "dismiss-button"), r(c, "aria-label", "Close modal"), r(i, "part", "content"), r(i, "class", p = `z-1 absolute left-1/2 h-fit max-h-full w-fit max-w-full -translate-x-1/2 overflow-auto p-8 transition-transform motion-reduce:transition-none ${/*isOpen*/
|
|
19
19
|
n[0] ? "visible opacity-100" : ""} ${/*isOpen*/
|
|
20
20
|
n[0] && /*centered*/
|
|
21
21
|
n[3] ? "translate-y-[calc(-50%_-_50px)]" : ""} ${!/*isOpen*/
|
|
@@ -44,7 +44,7 @@ function x(n) {
|
|
|
44
44
|
n[0]);
|
|
45
45
|
},
|
|
46
46
|
m(s, o) {
|
|
47
|
-
|
|
47
|
+
L(s, e, o), B(e, i), B(i, c), M(b, c, null), n[15](c), B(i, u), a && a.m(i, null), n[17](e), l = !0, y || (h = [
|
|
48
48
|
k(
|
|
49
49
|
c,
|
|
50
50
|
"click",
|
|
@@ -73,7 +73,7 @@ function x(n) {
|
|
|
73
73
|
},
|
|
74
74
|
p(s, [o]) {
|
|
75
75
|
a && a.p && (!l || o & /*$$scope*/
|
|
76
|
-
8192) &&
|
|
76
|
+
8192) && P(
|
|
77
77
|
a,
|
|
78
78
|
f,
|
|
79
79
|
s,
|
|
@@ -85,7 +85,7 @@ function x(n) {
|
|
|
85
85
|
s[13],
|
|
86
86
|
o,
|
|
87
87
|
null
|
|
88
|
-
) :
|
|
88
|
+
) : Q(
|
|
89
89
|
/*$$scope*/
|
|
90
90
|
s[13]
|
|
91
91
|
),
|
|
@@ -130,7 +130,7 @@ function x(n) {
|
|
|
130
130
|
l || (v(b.$$.fragment, s), v(a, s), l = !0);
|
|
131
131
|
},
|
|
132
132
|
o(s) {
|
|
133
|
-
|
|
133
|
+
A(b.$$.fragment, s), A(a, s), l = !1;
|
|
134
134
|
},
|
|
135
135
|
d(s) {
|
|
136
136
|
s && W(e), X(b), n[15](null), a && a.d(s), n[17](null), y = !1, Y(h);
|
|
@@ -141,7 +141,7 @@ function $(n, e, i) {
|
|
|
141
141
|
let { $$slots: c = {}, $$scope: b } = e, { isOpen: u } = e, { centered: p } = e, { autoOpen: g } = e, { label: w } = e, { alertDialog: l } = e, { staticBackdrop: y } = e, { dismissButton: h } = e, { container: f } = e, { el: a } = e, { inertElements: s } = e;
|
|
142
142
|
const o = (t) => {
|
|
143
143
|
y && t.target === t.currentTarget && i(0, u = !1);
|
|
144
|
-
},
|
|
144
|
+
}, q = (t) => {
|
|
145
145
|
t.key === "Escape" && i(0, u = !1);
|
|
146
146
|
}, D = (t) => {
|
|
147
147
|
var O;
|
|
@@ -153,13 +153,13 @@ function $(n, e, i) {
|
|
|
153
153
|
h.focus();
|
|
154
154
|
};
|
|
155
155
|
function S(t) {
|
|
156
|
-
|
|
156
|
+
C[t ? "unshift" : "push"](() => {
|
|
157
157
|
h = t, i(2, h);
|
|
158
158
|
});
|
|
159
159
|
}
|
|
160
160
|
const F = () => i(0, u = !1);
|
|
161
161
|
function T(t) {
|
|
162
|
-
|
|
162
|
+
C[t ? "unshift" : "push"](() => {
|
|
163
163
|
f = t, i(1, f);
|
|
164
164
|
});
|
|
165
165
|
}
|
|
@@ -207,7 +207,7 @@ function $(n, e, i) {
|
|
|
207
207
|
w,
|
|
208
208
|
l,
|
|
209
209
|
o,
|
|
210
|
-
|
|
210
|
+
q,
|
|
211
211
|
D,
|
|
212
212
|
s,
|
|
213
213
|
g,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
:root{font-size:62.5%}body{font-size:1.6rem;font-family:sans-serif;margin:0;padding:0}uofg-header{display:block;width:100%;height:5rem!important;background-color:#000}uofg-header *{display:none}uofg-header:has(*){height:10rem!important}@media screen and (min-width: 1024px){uofg-header{height:14rem!important}uofg-header:has(*){height:18rem!important}}uofg-footer{display:block}uofg-modal{display:block;position:fixed;visibility:hidden;z-index:1000}uofg-alert{display:block;max-width:100rem}
|
|
1
|
+
:root{font-size:62.5%}body{font-size:1.6rem;font-family:sans-serif;margin:0;padding:0}uofg-header{display:block;width:100%;height:5rem!important;background-color:#000}uofg-header *{display:none}uofg-header:has(*){height:10rem!important}@media screen and (min-width: 1024px){uofg-header{height:14rem!important}uofg-header:has(*){height:18rem!important}}uofg-menu{display:block}uofg-footer{display:block}uofg-modal{display:block;position:fixed;visibility:hidden;z-index:1000}uofg-alert{display:block;max-width:100rem}uofg-card{display:block}
|
|
@@ -1,56 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
};
|
|
7
|
-
let r = null;
|
|
8
|
-
function s(e) {
|
|
9
|
-
d(/* @__PURE__ */ Object.assign({ "./components/uofg-alert.svelte": () => import("./uofg-alert.esm.js"), "./components/uofg-footer.svelte": () => import("./uofg-footer.esm.js"), "./components/uofg-header.svelte": () => import("./uofg-header.esm.js"), "./components/uofg-modal.svelte": () => import("./uofg-modal.esm.js") }), `./components/${e}.svelte`).then(() => {
|
|
10
|
-
console.log(`Loaded UofG web component: ${e}`);
|
|
11
|
-
}).catch((n) => {
|
|
12
|
-
console.error(`Failed to load UofG web component: ${e}, ${n.message}`);
|
|
13
|
-
});
|
|
14
|
-
}
|
|
15
|
-
function f(e) {
|
|
16
|
-
typeof document < "u" && typeof MutationObserver == "function" && (r == null || r.observe(e ?? document.body, { subtree: !0, childList: !0 }));
|
|
17
|
-
}
|
|
18
|
-
function u() {
|
|
19
|
-
r == null || r.disconnect();
|
|
20
|
-
}
|
|
21
|
-
function a(e) {
|
|
22
|
-
var o, i;
|
|
23
|
-
const n = /* @__PURE__ */ new Set();
|
|
24
|
-
if (typeof window < "u") {
|
|
25
|
-
const t = document.createTreeWalker(e, NodeFilter.SHOW_ELEMENT, (c) => c.tagName.startsWith("UOFG-") ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP);
|
|
26
|
-
for (; t.nextNode(); ) {
|
|
27
|
-
const c = (i = (o = t == null ? void 0 : t.currentNode) == null ? void 0 : o.tagName) == null ? void 0 : i.toLowerCase();
|
|
28
|
-
n.add(c);
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
return n;
|
|
32
|
-
}
|
|
33
|
-
if (typeof window < "u") {
|
|
34
|
-
for (const e of a(document.body))
|
|
35
|
-
s(e);
|
|
36
|
-
typeof MutationObserver == "function" && (r = new MutationObserver((e) => {
|
|
37
|
-
for (const n of e)
|
|
38
|
-
for (const o of n.addedNodes) {
|
|
39
|
-
if (o.nodeType !== Node.ELEMENT_NODE)
|
|
40
|
-
return;
|
|
41
|
-
if (o.tagName.startsWith("UOFG-")) {
|
|
42
|
-
const t = o.tagName.toLowerCase();
|
|
43
|
-
s(t);
|
|
44
|
-
}
|
|
45
|
-
const i = a(o);
|
|
46
|
-
for (const t of i)
|
|
47
|
-
s(t);
|
|
48
|
-
}
|
|
49
|
-
})), f();
|
|
50
|
-
}
|
|
1
|
+
import o from "./uofg-header.esm.js";
|
|
2
|
+
import f from "./uofg-footer.esm.js";
|
|
3
|
+
import r from "./uofg-modal.esm.js";
|
|
4
|
+
import t from "./uofg-alert.esm.js";
|
|
5
|
+
import m from "./uofg-back-to-top.esm.js";
|
|
6
|
+
const i = { UofGHeader: o, UofGFooter: f, UofGModal: r, UofGAlert: t, UofGBackToTop: m };
|
|
51
7
|
export {
|
|
52
|
-
|
|
53
|
-
a as scan,
|
|
54
|
-
u as stopWatchingDOM,
|
|
55
|
-
f as watchDOM
|
|
8
|
+
i as default
|
|
56
9
|
};
|
package/package.json
CHANGED
|
@@ -1,15 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uoguelph/web-components",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.4.0-rc.0",
|
|
4
4
|
"description": "University of Guelph Web Components Library",
|
|
5
|
+
"module": "dist/uofg-web-components/uofg-web-components.esm.js",
|
|
5
6
|
"type": "module",
|
|
6
|
-
"
|
|
7
|
-
".": "./dist/uofg-web-components/uofg-web-components.esm.js",
|
|
8
|
-
"./*.js": "./dist/uofg-web-components/*.esm.js",
|
|
9
|
-
"./*": "./dist/uofg-web-components/*.esm.js",
|
|
10
|
-
"./stylesheet": "./dist/uofg-web-components/uofg-web-components.css",
|
|
11
|
-
"./package.json": "./package.json"
|
|
12
|
-
},
|
|
7
|
+
"unpkg": "dist/uofg-web-components/uofg-web-components.esm.js",
|
|
13
8
|
"files": [
|
|
14
9
|
"dist/"
|
|
15
10
|
],
|
|
@@ -19,23 +14,22 @@
|
|
|
19
14
|
"format": "npx prettier --write .",
|
|
20
15
|
"prepublishOnly": "npm run build && npmignore --auto"
|
|
21
16
|
},
|
|
22
|
-
"
|
|
17
|
+
"devDependencies": {
|
|
23
18
|
"@fortawesome/free-brands-svg-icons": "^6.4.0",
|
|
24
19
|
"@fortawesome/free-regular-svg-icons": "^6.4.0",
|
|
25
|
-
"@fortawesome/free-solid-svg-icons": "^6.4.0"
|
|
26
|
-
},
|
|
27
|
-
"devDependencies": {
|
|
20
|
+
"@fortawesome/free-solid-svg-icons": "^6.4.0",
|
|
28
21
|
"@sveltejs/vite-plugin-svelte": "^3.0.2",
|
|
29
22
|
"autoprefixer": "^10.4.18",
|
|
30
23
|
"eslint": "^8.57.0",
|
|
31
24
|
"eslint-plugin-svelte": "^2.35.1",
|
|
32
25
|
"npmignore": "^0.3.1",
|
|
33
26
|
"postcss": "^8.4.35",
|
|
34
|
-
"prettier": "^3.2
|
|
35
|
-
"prettier-plugin-svelte": "^3.2.
|
|
27
|
+
"prettier": "^3.3.2",
|
|
28
|
+
"prettier-plugin-svelte": "^3.2.4",
|
|
36
29
|
"prettier-plugin-tailwindcss": "^0.5.12",
|
|
37
30
|
"svelte": "^4.2.12",
|
|
38
31
|
"svelte-check": "^3.6.6",
|
|
32
|
+
"tailwind-merge": "^2.3.0",
|
|
39
33
|
"tailwindcss": "^3.4.1",
|
|
40
34
|
"vite": "^5.1.6",
|
|
41
35
|
"vite-plugin-full-reload": "^1.1.0"
|