@uoguelph/react-components 1.3.13 → 1.4.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/accordion-button.js +22 -22
- package/dist/accordion-content.js +5 -5
- package/dist/accordion.js +3 -3
- package/dist/alert-footer.js +6 -6
- package/dist/alert-message.js +7 -10
- package/dist/alert-subtitle.js +7 -7
- package/dist/alert-title.js +23 -23
- package/dist/alert.js +7 -7
- package/dist/blockquote-author-name.js +1 -1
- package/dist/blockquote-author-title.js +2 -2
- package/dist/blockquote-author.js +11 -11
- package/dist/blockquote-content.js +16 -16
- package/dist/breadcrumb-home.js +2 -2
- package/dist/breadcrumb.js +15 -15
- package/dist/breadcrumbs.js +9 -9
- package/dist/button.js +44 -44
- package/dist/card-content.js +10 -10
- package/dist/card-footer.js +11 -11
- package/dist/card-image.js +15 -15
- package/dist/card-title.js +5 -5
- package/dist/card.js +11 -11
- package/dist/carousel.js +51 -51
- package/dist/checkbox.js +44 -44
- package/dist/contact-email.js +7 -7
- package/dist/contact-name.js +1 -1
- package/dist/contact-phone.js +11 -11
- package/dist/contact-title.js +1 -1
- package/dist/contact.js +11 -14
- package/dist/container.js +10 -10
- package/dist/dismissible-alert.js +2 -2
- package/dist/divider.js +18 -18
- package/dist/embedded-video-modal-button.js +16 -16
- package/dist/embedded-video.js +29 -29
- package/dist/hero-caption.js +1 -1
- package/dist/hero-content.js +23 -23
- package/dist/hero-link.js +1 -1
- package/dist/hero-title.js +11 -11
- package/dist/hero-video.js +9 -9
- package/dist/hero.js +19 -19
- package/dist/image-overlay.js +48 -48
- package/dist/index.css +1 -1
- package/dist/info.js +16 -16
- package/dist/layout-content.js +3 -3
- package/dist/layout.js +44 -44
- package/dist/link-carousel-content.js +11 -11
- package/dist/link-carousel-item.js +15 -15
- package/dist/link-carousel-link.js +22 -22
- package/dist/link-carousel-links.js +14 -14
- package/dist/link-carousel.js +21 -21
- package/dist/link.js +10 -10
- package/dist/list-item.js +6 -6
- package/dist/list.js +21 -21
- package/dist/loading-indicator.js +29 -29
- package/dist/media-caption.js +34 -34
- package/dist/modal.js +25 -25
- package/dist/navigation-link.js +25 -25
- package/dist/navigation.js +8 -11
- package/dist/number-input.js +46 -46
- package/dist/pagination.js +62 -62
- package/dist/radio-group.js +8 -8
- package/dist/radio.js +19 -19
- package/dist/select-button.js +32 -32
- package/dist/select-option.js +29 -29
- package/dist/select-options.js +27 -27
- package/dist/select.js +7 -7
- package/dist/statistics-item-image.js +9 -9
- package/dist/statistics-item-represents.js +7 -7
- package/dist/statistics-item-value.js +7 -7
- package/dist/statistics-item.js +35 -35
- package/dist/statistics.js +25 -25
- package/dist/story-background-image.js +12 -12
- package/dist/story-background.js +7 -7
- package/dist/story-body.js +5 -8
- package/dist/story-footer.js +12 -12
- package/dist/story-foreground-content.js +4 -4
- package/dist/story-foreground-image.js +15 -15
- package/dist/story-foreground.js +7 -10
- package/dist/story.js +5 -5
- package/dist/tab-list.js +3 -6
- package/dist/tab-panel.js +3 -3
- package/dist/tab.js +26 -26
- package/dist/text-input.js +32 -32
- package/dist/typography.js +22 -22
- package/package.json +2 -2
package/dist/checkbox.js
CHANGED
|
@@ -1,85 +1,85 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
2
|
+
import { jsxs as l, jsx as e } from "react/jsx-runtime";
|
|
3
3
|
import { d as p } from "./regular-DmWV6rTj.js";
|
|
4
4
|
import { FontAwesomeIcon as y } from "@fortawesome/react-fontawesome";
|
|
5
5
|
import { Field as w, Checkbox as v, Label as N, Description as $ } from "@headlessui/react";
|
|
6
6
|
import { useState as C } from "react";
|
|
7
7
|
import { tv as j } from "tailwind-variants";
|
|
8
8
|
function F({
|
|
9
|
-
checked:
|
|
10
|
-
label:
|
|
11
|
-
description:
|
|
12
|
-
color:
|
|
13
|
-
disabled:
|
|
14
|
-
onChange:
|
|
15
|
-
...
|
|
9
|
+
checked: r = !1,
|
|
10
|
+
label: o,
|
|
11
|
+
description: i,
|
|
12
|
+
color: a = "yellow",
|
|
13
|
+
disabled: t = !1,
|
|
14
|
+
onChange: c,
|
|
15
|
+
...n
|
|
16
16
|
}) {
|
|
17
|
-
const [
|
|
17
|
+
const [b, u] = C(r), h = j({
|
|
18
18
|
slots: {
|
|
19
|
-
base: "
|
|
20
|
-
container: "
|
|
21
|
-
box: "
|
|
22
|
-
check: "
|
|
23
|
-
label: "
|
|
24
|
-
description: "
|
|
19
|
+
base: "flex cursor-pointer flex-col gap-0.5",
|
|
20
|
+
container: "flex items-center gap-2",
|
|
21
|
+
box: "group flex size-4 items-center justify-center rounded border bg-white p-3 transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none",
|
|
22
|
+
check: "group-ui-checked:opacity-100 user-select-none h-5 w-5 opacity-0 transition-opacity",
|
|
23
|
+
label: "text-body-copy",
|
|
24
|
+
description: "text-sm text-grey-dark"
|
|
25
25
|
},
|
|
26
26
|
variants: {
|
|
27
27
|
color: {
|
|
28
28
|
yellow: {
|
|
29
|
-
box: "
|
|
30
|
-
check: "
|
|
29
|
+
box: "ui-checked:bg-yellow focus-visible:ring-yellow",
|
|
30
|
+
check: "text-yellow-contrast"
|
|
31
31
|
},
|
|
32
32
|
blue: {
|
|
33
|
-
box: "
|
|
34
|
-
check: "
|
|
33
|
+
box: "ui-checked:bg-blue focus-visible:ring-blue",
|
|
34
|
+
check: "text-blue-contrast"
|
|
35
35
|
},
|
|
36
36
|
green: {
|
|
37
|
-
box: "
|
|
38
|
-
check: "
|
|
37
|
+
box: "ui-checked:bg-green focus-visible:ring-green",
|
|
38
|
+
check: "text-green-contrast"
|
|
39
39
|
},
|
|
40
40
|
black: {
|
|
41
|
-
box: "
|
|
42
|
-
check: "
|
|
41
|
+
box: "ui-checked:bg-black focus-visible:ring-black",
|
|
42
|
+
check: "text-black-contrast"
|
|
43
43
|
},
|
|
44
44
|
white: {
|
|
45
|
-
box: "
|
|
46
|
-
check: "
|
|
45
|
+
box: "ui-checked:bg-white focus-visible:ring-white",
|
|
46
|
+
check: "text-white-contrast"
|
|
47
47
|
}
|
|
48
48
|
},
|
|
49
49
|
disabled: {
|
|
50
50
|
true: {
|
|
51
|
-
base: "
|
|
52
|
-
label: "
|
|
51
|
+
base: "opacity-60",
|
|
52
|
+
label: "text-grey-dark"
|
|
53
53
|
},
|
|
54
54
|
false: {}
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
57
|
}), {
|
|
58
|
-
base:
|
|
59
|
-
container:
|
|
60
|
-
box:
|
|
61
|
-
check:
|
|
62
|
-
label:
|
|
58
|
+
base: x,
|
|
59
|
+
container: f,
|
|
60
|
+
box: k,
|
|
61
|
+
check: d,
|
|
62
|
+
label: g,
|
|
63
63
|
description: m
|
|
64
|
-
} =
|
|
65
|
-
return /* @__PURE__ */
|
|
66
|
-
/* @__PURE__ */
|
|
64
|
+
} = h({ color: a, disabled: t });
|
|
65
|
+
return /* @__PURE__ */ l(w, { className: `uofg-checkbox-field ${x()}`, children: [
|
|
66
|
+
/* @__PURE__ */ l("div", { className: `uofg-checkbox-container ${f()}`, children: [
|
|
67
67
|
/* @__PURE__ */ e(
|
|
68
68
|
v,
|
|
69
69
|
{
|
|
70
|
-
checked:
|
|
71
|
-
onChange: (
|
|
72
|
-
|
|
70
|
+
checked: b,
|
|
71
|
+
onChange: (s) => {
|
|
72
|
+
u(s), c == null || c(s);
|
|
73
73
|
},
|
|
74
|
-
disabled:
|
|
75
|
-
className: `uofg-checkbox ${
|
|
76
|
-
...
|
|
77
|
-
children: /* @__PURE__ */ e(y, { className: `uofg-checkbox-icon ${
|
|
74
|
+
disabled: t,
|
|
75
|
+
className: `uofg-checkbox ${k()}`,
|
|
76
|
+
...n,
|
|
77
|
+
children: /* @__PURE__ */ e(y, { className: `uofg-checkbox-icon ${d()}`, icon: p })
|
|
78
78
|
}
|
|
79
79
|
),
|
|
80
|
-
|
|
80
|
+
o && /* @__PURE__ */ e(N, { className: `uofg-checkbox-label ${g()}`, children: o })
|
|
81
81
|
] }),
|
|
82
|
-
|
|
82
|
+
i && /* @__PURE__ */ e($, { className: `uofg-checkbox-description ${m()}`, children: i })
|
|
83
83
|
] });
|
|
84
84
|
}
|
|
85
85
|
F.displayName = "Checkbox";
|
package/dist/contact-email.js
CHANGED
|
@@ -2,12 +2,12 @@ import { jsxs as a, jsx as t } from "react/jsx-runtime";
|
|
|
2
2
|
import { g as r } from "./regular-DmWV6rTj.js";
|
|
3
3
|
import { FontAwesomeIcon as s } from "@fortawesome/react-fontawesome";
|
|
4
4
|
import { twMerge as l } from "tailwind-merge";
|
|
5
|
-
import { tv as
|
|
6
|
-
function
|
|
7
|
-
const i =
|
|
5
|
+
import { tv as m } from "tailwind-variants";
|
|
6
|
+
function f({ email: o, className: n }) {
|
|
7
|
+
const i = m({
|
|
8
8
|
slots: {
|
|
9
|
-
container: "
|
|
10
|
-
link: "
|
|
9
|
+
container: "flex items-center gap-1",
|
|
10
|
+
link: "text-body-copy-link-on-light underline decoration-current transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none hocus-visible:decoration-transparent"
|
|
11
11
|
}
|
|
12
12
|
}), { container: e, link: c } = i();
|
|
13
13
|
return /* @__PURE__ */ a("div", { className: `uofg-contact-email-container ${l(e(), n)}`, children: [
|
|
@@ -15,7 +15,7 @@ function m({ email: o, className: n }) {
|
|
|
15
15
|
/* @__PURE__ */ t("a", { className: `uofg-contact-email ${c()}`, href: `mailto:${o}`, children: o })
|
|
16
16
|
] });
|
|
17
17
|
}
|
|
18
|
-
|
|
18
|
+
f.displayName = "ContactEmail";
|
|
19
19
|
export {
|
|
20
|
-
|
|
20
|
+
f as ContactEmail
|
|
21
21
|
};
|
package/dist/contact-name.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as n } from "react/jsx-runtime";
|
|
2
2
|
import { twMerge as e } from "tailwind-merge";
|
|
3
3
|
function m({ children: o, className: t }) {
|
|
4
|
-
const a = e("
|
|
4
|
+
const a = e("font-bold text-body-copy-bold-on-light", t);
|
|
5
5
|
return /* @__PURE__ */ n("span", { className: `uofg-contact-name ${a}`, children: o });
|
|
6
6
|
}
|
|
7
7
|
m.displayName = "ContactName";
|
package/dist/contact-phone.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { jsxs as t, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import { d as a } from "./solid-D19hAF5t.js";
|
|
3
|
-
import { FontAwesomeIcon as
|
|
4
|
-
import { twMerge as
|
|
5
|
-
import { tv as
|
|
6
|
-
function
|
|
7
|
-
const c =
|
|
3
|
+
import { FontAwesomeIcon as l } from "@fortawesome/react-fontawesome";
|
|
4
|
+
import { twMerge as f } from "tailwind-merge";
|
|
5
|
+
import { tv as m } from "tailwind-variants";
|
|
6
|
+
function p({ number: o, extension: n, className: i }) {
|
|
7
|
+
const c = m({
|
|
8
8
|
slots: {
|
|
9
|
-
container: "
|
|
10
|
-
link: "
|
|
9
|
+
container: "flex items-center gap-1",
|
|
10
|
+
link: "text-body-copy-link-on-light underline decoration-current transition-colors focus-visible:ring-2 focus-visible:ring-offset-2 focus-visible:outline-none hocus-visible:decoration-transparent"
|
|
11
11
|
}
|
|
12
12
|
}), { container: r, link: s } = c();
|
|
13
|
-
return /* @__PURE__ */ t("div", { className: `uofg-contact-phone-container ${
|
|
14
|
-
/* @__PURE__ */ e(
|
|
13
|
+
return /* @__PURE__ */ t("div", { className: `uofg-contact-phone-container ${f(r(), i)}`, children: [
|
|
14
|
+
/* @__PURE__ */ e(l, { icon: a, className: "uofg-contact-phone-icon" }),
|
|
15
15
|
/* @__PURE__ */ e("a", { className: `uofg-contact-phone ${s()}`, href: `tel:${o}`, children: o }),
|
|
16
16
|
n && /* @__PURE__ */ t("span", { className: "uofg-contact-phone-extension", children: [
|
|
17
17
|
" - Ext. ",
|
|
@@ -19,7 +19,7 @@ function f({ number: o, extension: n, className: i }) {
|
|
|
19
19
|
] })
|
|
20
20
|
] });
|
|
21
21
|
}
|
|
22
|
-
|
|
22
|
+
p.displayName = "ContactPhone";
|
|
23
23
|
export {
|
|
24
|
-
|
|
24
|
+
p as ContactPhone
|
|
25
25
|
};
|
package/dist/contact-title.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as i } from "react/jsx-runtime";
|
|
2
2
|
import { twMerge as n } from "tailwind-merge";
|
|
3
3
|
function a({ children: t, className: o }) {
|
|
4
|
-
const e = n("
|
|
4
|
+
const e = n("text-body-copy-on-light", o);
|
|
5
5
|
return /* @__PURE__ */ i("span", { className: `uofg-contact-title ${e}`, children: t });
|
|
6
6
|
}
|
|
7
7
|
a.displayName = "ContactTitle";
|
package/dist/contact.js
CHANGED
|
@@ -1,21 +1,18 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { twMerge as c } from "tailwind-merge";
|
|
3
|
-
import { ContactEmail as
|
|
4
|
-
import { ContactName as
|
|
5
|
-
import { ContactPhone as
|
|
6
|
-
import { ContactTitle as
|
|
7
|
-
function a({ children:
|
|
8
|
-
const e = c(
|
|
9
|
-
|
|
10
|
-
t
|
|
11
|
-
);
|
|
12
|
-
return /* @__PURE__ */ r("div", { className: `uofg-contact ${e}`, children: o });
|
|
3
|
+
import { ContactEmail as i } from "./contact-email.js";
|
|
4
|
+
import { ContactName as x } from "./contact-name.js";
|
|
5
|
+
import { ContactPhone as C } from "./contact-phone.js";
|
|
6
|
+
import { ContactTitle as b } from "./contact-title.js";
|
|
7
|
+
function a({ children: t, className: o }) {
|
|
8
|
+
const e = c("mb-2 flex flex-col bg-grey-light-bg p-4 text-body-copy-on-light", o);
|
|
9
|
+
return /* @__PURE__ */ r("div", { className: `uofg-contact ${e}`, children: t });
|
|
13
10
|
}
|
|
14
11
|
a.displayName = "Contact";
|
|
15
12
|
export {
|
|
16
13
|
a as Contact,
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
14
|
+
i as ContactEmail,
|
|
15
|
+
x as ContactName,
|
|
16
|
+
C as ContactPhone,
|
|
17
|
+
b as ContactTitle
|
|
21
18
|
};
|
package/dist/container.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { twMerge as
|
|
3
|
-
const
|
|
4
|
-
function
|
|
5
|
-
as:
|
|
6
|
-
children:
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import { twMerge as s } from "tailwind-merge";
|
|
3
|
+
const i = "div";
|
|
4
|
+
function p({
|
|
5
|
+
as: t,
|
|
6
|
+
children: o,
|
|
7
7
|
className: e,
|
|
8
8
|
...n
|
|
9
9
|
}) {
|
|
10
|
-
const r =
|
|
11
|
-
return /* @__PURE__ */
|
|
10
|
+
const r = t ?? i, a = s("mx-auto w-full max-w-[137rem] px-4 pt-2 pb-4", e);
|
|
11
|
+
return /* @__PURE__ */ m(r, { ...n, className: `uofg-container ${a}`, children: o });
|
|
12
12
|
}
|
|
13
|
-
|
|
13
|
+
p.displayName = "Container";
|
|
14
14
|
export {
|
|
15
|
-
|
|
15
|
+
p as Container
|
|
16
16
|
};
|
|
@@ -797,13 +797,13 @@ var xr = Br();
|
|
|
797
797
|
const Lr = /* @__PURE__ */ Ar(xr);
|
|
798
798
|
function Or({ alert: O }) {
|
|
799
799
|
const [sr, _] = hr(!0), C = pr(() => O ? Lr(O) : void 0, [O]), { dismissed: U, dismiss: S } = gr("app-armor-alert", C, "session");
|
|
800
|
-
return O && !U ? /* @__PURE__ */ Z(br, { open: sr, onClose: () => _(!1), children: /* @__PURE__ */ Z(wr, { className: "
|
|
800
|
+
return O && !U ? /* @__PURE__ */ Z(br, { open: sr, onClose: () => _(!1), children: /* @__PURE__ */ Z(wr, { className: "max-w-[80rem]! p-0", children: /* @__PURE__ */ tr(yr, { children: [
|
|
801
801
|
/* @__PURE__ */ Z(vr, { children: "University of Guelph Alert" }),
|
|
802
802
|
/* @__PURE__ */ tr(_r, { children: [
|
|
803
803
|
/* @__PURE__ */ Z(Er, { children: O.title }),
|
|
804
804
|
O.description
|
|
805
805
|
] }),
|
|
806
|
-
/* @__PURE__ */ tr(Ir, { className: "
|
|
806
|
+
/* @__PURE__ */ tr(Ir, { className: "flex flex-col gap-4", children: [
|
|
807
807
|
/* @__PURE__ */ tr("span", { children: [
|
|
808
808
|
"Last Updated: ",
|
|
809
809
|
O.timestamp
|
package/dist/divider.js
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { tv as
|
|
3
|
-
const
|
|
4
|
-
const
|
|
1
|
+
import { jsxs as l, Fragment as i, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { tv as m } from "tailwind-variants";
|
|
3
|
+
const n = () => {
|
|
4
|
+
const s = m({
|
|
5
5
|
slots: {
|
|
6
|
-
base: "
|
|
7
|
-
red: "
|
|
8
|
-
yellow: "
|
|
9
|
-
black: "
|
|
10
|
-
hr: "
|
|
6
|
+
base: "mx-auto my-7 flex h-1 w-3/4 border-0",
|
|
7
|
+
red: "bg-red",
|
|
8
|
+
yellow: "bg-yellow",
|
|
9
|
+
black: "bg-black",
|
|
10
|
+
hr: "border-0"
|
|
11
11
|
},
|
|
12
12
|
compoundSlots: [
|
|
13
13
|
{
|
|
14
14
|
slots: ["red", "yellow", "black"],
|
|
15
|
-
class: "
|
|
15
|
+
class: "h-full flex-1"
|
|
16
16
|
}
|
|
17
17
|
]
|
|
18
|
-
}), { base:
|
|
19
|
-
return /* @__PURE__ */
|
|
20
|
-
/* @__PURE__ */
|
|
21
|
-
/* @__PURE__ */
|
|
22
|
-
/* @__PURE__ */
|
|
23
|
-
/* @__PURE__ */
|
|
18
|
+
}), { base: r, red: o, yellow: a, black: d, hr: c } = s();
|
|
19
|
+
return /* @__PURE__ */ l(i, { children: [
|
|
20
|
+
/* @__PURE__ */ l("div", { className: `uofg-divider ${r()}`, children: [
|
|
21
|
+
/* @__PURE__ */ e("div", { className: o() }),
|
|
22
|
+
/* @__PURE__ */ e("div", { className: a() }),
|
|
23
|
+
/* @__PURE__ */ e("div", { className: d() })
|
|
24
24
|
] }),
|
|
25
|
-
/* @__PURE__ */
|
|
25
|
+
/* @__PURE__ */ e("hr", { className: c() })
|
|
26
26
|
] });
|
|
27
27
|
};
|
|
28
28
|
export {
|
|
29
|
-
|
|
29
|
+
n as Divider
|
|
30
30
|
};
|
|
@@ -1,26 +1,26 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
3
|
-
import { g as
|
|
4
|
-
import { FontAwesomeIcon as
|
|
2
|
+
import { jsxs as i, jsx as e } from "react/jsx-runtime";
|
|
3
|
+
import { g as s } from "./solid-D19hAF5t.js";
|
|
4
|
+
import { FontAwesomeIcon as u } from "@fortawesome/react-fontawesome";
|
|
5
5
|
import { useContext as m } from "react";
|
|
6
6
|
import { twMerge as l } from "tailwind-merge";
|
|
7
7
|
import { Button as a } from "./button.js";
|
|
8
|
-
import { EmbeddedVideoContext as
|
|
9
|
-
function
|
|
10
|
-
const o = m(
|
|
8
|
+
import { EmbeddedVideoContext as f } from "./embedded-video-context.js";
|
|
9
|
+
function c({ type: t, children: d, className: r }) {
|
|
10
|
+
const o = m(f);
|
|
11
11
|
if (t === "play-button") {
|
|
12
|
-
const
|
|
13
|
-
"
|
|
14
|
-
|
|
12
|
+
const n = l(
|
|
13
|
+
"flex aspect-square w-24 items-center justify-center rounded-full bg-red text-4xl text-white transition-colors hover:bg-red-focus focus:bg-red-focus",
|
|
14
|
+
r
|
|
15
15
|
);
|
|
16
|
-
return /* @__PURE__ */
|
|
16
|
+
return /* @__PURE__ */ i(
|
|
17
17
|
"button",
|
|
18
18
|
{
|
|
19
19
|
type: "button",
|
|
20
|
-
className: `uofg-embedded-video-play-button ${
|
|
20
|
+
className: `uofg-embedded-video-play-button ${n}`,
|
|
21
21
|
onClick: () => o == null ? void 0 : o.setModalOpen(!0),
|
|
22
22
|
children: [
|
|
23
|
-
/* @__PURE__ */ e(
|
|
23
|
+
/* @__PURE__ */ e(u, { icon: s }),
|
|
24
24
|
/* @__PURE__ */ e("span", { className: "sr-only", children: "Show Video" })
|
|
25
25
|
]
|
|
26
26
|
}
|
|
@@ -31,13 +31,13 @@ function f({ type: t, children: r, className: u }) {
|
|
|
31
31
|
{
|
|
32
32
|
type: "button",
|
|
33
33
|
color: t,
|
|
34
|
-
className: `uofg-embedded-video-play-button ${
|
|
34
|
+
className: `uofg-embedded-video-play-button ${r}`,
|
|
35
35
|
onClick: () => o == null ? void 0 : o.setModalOpen(!0),
|
|
36
|
-
children:
|
|
36
|
+
children: d
|
|
37
37
|
}
|
|
38
38
|
);
|
|
39
39
|
}
|
|
40
|
-
|
|
40
|
+
c.displayName = "EmbeddedVideoModalButton";
|
|
41
41
|
export {
|
|
42
|
-
|
|
42
|
+
c as EmbeddedVideoModalButton
|
|
43
43
|
};
|
package/dist/embedded-video.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
3
|
-
import { useState as
|
|
2
|
+
import { jsxs as m, Fragment as w, jsx as n } from "react/jsx-runtime";
|
|
3
|
+
import { useState as g } from "react";
|
|
4
4
|
import { twMerge as f } from "tailwind-merge";
|
|
5
|
-
import { tv as
|
|
5
|
+
import { tv as b } from "tailwind-variants";
|
|
6
6
|
import { Button as h } from "./button.js";
|
|
7
7
|
import { Modal as x } from "./modal.js";
|
|
8
8
|
import { EmbeddedVideoContext as y } from "./embedded-video-context.js";
|
|
9
9
|
import { EmbeddedVideoModalButton as D } from "./embedded-video-modal-button.js";
|
|
10
|
-
function
|
|
10
|
+
function v(l) {
|
|
11
11
|
var t;
|
|
12
12
|
if (!(l instanceof URL))
|
|
13
13
|
return null;
|
|
@@ -23,7 +23,7 @@ function b(l) {
|
|
|
23
23
|
case "live":
|
|
24
24
|
return (e == null ? void 0 : e[1]) ?? null;
|
|
25
25
|
case "oembed":
|
|
26
|
-
return
|
|
26
|
+
return v(new URL(decodeURIComponent(l.searchParams.get("url") ?? "")));
|
|
27
27
|
case "attribution_link":
|
|
28
28
|
return null;
|
|
29
29
|
default:
|
|
@@ -39,24 +39,24 @@ function N(l) {
|
|
|
39
39
|
let e = null, t = null;
|
|
40
40
|
try {
|
|
41
41
|
const o = new URL(l);
|
|
42
|
-
o != null && o.hostname.includes("youtube") || o != null && o.hostname.includes("youtu.be") ? (e = "youtube", t =
|
|
42
|
+
o != null && o.hostname.includes("youtube") || o != null && o.hostname.includes("youtu.be") ? (e = "youtube", t = v(o)) : o != null && o.hostname.includes("vimeo") && (e = "vimeo", t = V(o));
|
|
43
43
|
} catch {
|
|
44
44
|
}
|
|
45
45
|
return { type: e, id: t };
|
|
46
46
|
}
|
|
47
|
-
function
|
|
48
|
-
const { id: i, type: d } = N(l),
|
|
47
|
+
function u({ src: l, title: e, transcript: t, className: o }) {
|
|
48
|
+
const { id: i, type: d } = N(l), r = b({
|
|
49
49
|
slots: {
|
|
50
|
-
base: f("
|
|
51
|
-
iframe: "
|
|
52
|
-
transcriptButton: "
|
|
50
|
+
base: f("flex flex-col", o),
|
|
51
|
+
iframe: "aspect-video h-full w-full",
|
|
52
|
+
transcriptButton: "w-full p-3"
|
|
53
53
|
}
|
|
54
|
-
}), { base:
|
|
55
|
-
return /* @__PURE__ */
|
|
54
|
+
}), { base: a, iframe: s, transcriptButton: c } = r();
|
|
55
|
+
return /* @__PURE__ */ m("div", { className: a(), children: [
|
|
56
56
|
d === "youtube" && i && /* @__PURE__ */ n(
|
|
57
57
|
"iframe",
|
|
58
58
|
{
|
|
59
|
-
className:
|
|
59
|
+
className: s(),
|
|
60
60
|
allowFullScreen: !0,
|
|
61
61
|
src: `https://www.youtube.com/embed/${i}`,
|
|
62
62
|
title: e ?? "YouTube Embedded Video Player"
|
|
@@ -65,42 +65,42 @@ function m({ src: l, title: e, transcript: t, className: o }) {
|
|
|
65
65
|
d === "vimeo" && i && /* @__PURE__ */ n(
|
|
66
66
|
"iframe",
|
|
67
67
|
{
|
|
68
|
-
className:
|
|
68
|
+
className: s(),
|
|
69
69
|
allowFullScreen: !0,
|
|
70
70
|
src: `https://player.vimeo.com/video/${i}`,
|
|
71
71
|
title: e ?? "Vimeo Embedded Video Player"
|
|
72
72
|
}
|
|
73
73
|
),
|
|
74
|
-
t && /* @__PURE__ */ n(h, { as: "a", color: "black", className:
|
|
74
|
+
t && /* @__PURE__ */ n(h, { as: "a", color: "black", className: c(), href: t, download: !0, children: "Download Transcript" })
|
|
75
75
|
] });
|
|
76
76
|
}
|
|
77
77
|
function E({ src: l, title: e, transcript: t, className: o, children: i }) {
|
|
78
|
-
const [d,
|
|
78
|
+
const [d, r] = g(!1);
|
|
79
79
|
if (i) {
|
|
80
|
-
const
|
|
80
|
+
const a = b({
|
|
81
81
|
slots: {
|
|
82
|
-
container: "
|
|
83
|
-
video: "
|
|
84
|
-
title: "
|
|
82
|
+
container: "flex w-screen max-w-6xl flex-col gap-4 bg-grey-dark-bg p-4 text-grey-dark-contrast lg:max-w-7xl",
|
|
83
|
+
video: "w-full",
|
|
84
|
+
title: "text-xl font-bold"
|
|
85
85
|
}
|
|
86
|
-
}), { container:
|
|
87
|
-
return /* @__PURE__ */
|
|
88
|
-
/* @__PURE__ */ n(y.Provider, { value: { modalOpen: d, setModalOpen:
|
|
89
|
-
/* @__PURE__ */ n(x, { open: d, onClose: () =>
|
|
90
|
-
/* @__PURE__ */ n("span", { className: `uofg-embedded-video-title ${
|
|
86
|
+
}), { container: s, video: c, title: p } = a();
|
|
87
|
+
return /* @__PURE__ */ m(w, { children: [
|
|
88
|
+
/* @__PURE__ */ n(y.Provider, { value: { modalOpen: d, setModalOpen: r }, children: i }),
|
|
89
|
+
/* @__PURE__ */ n(x, { open: d, onClose: () => r(!1), children: /* @__PURE__ */ m("div", { className: `uofg-embedded-video-container ${s()}`, children: [
|
|
90
|
+
/* @__PURE__ */ n("span", { className: `uofg-embedded-video-title ${p()}`, children: e }),
|
|
91
91
|
/* @__PURE__ */ n(
|
|
92
|
-
|
|
92
|
+
u,
|
|
93
93
|
{
|
|
94
94
|
src: l,
|
|
95
95
|
title: e,
|
|
96
96
|
transcript: t,
|
|
97
|
-
className: `uofg-embedded-video ${f(
|
|
97
|
+
className: `uofg-embedded-video ${f(c(), o)}`
|
|
98
98
|
}
|
|
99
99
|
)
|
|
100
100
|
] }) })
|
|
101
101
|
] });
|
|
102
102
|
}
|
|
103
|
-
return /* @__PURE__ */ n(
|
|
103
|
+
return /* @__PURE__ */ n(u, { src: l, title: e, transcript: t, className: `uofg-embedded-video ${o}` });
|
|
104
104
|
}
|
|
105
105
|
E.displayName = "EmbeddedVideo";
|
|
106
106
|
export {
|
package/dist/hero-caption.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx as t } from "react/jsx-runtime";
|
|
3
3
|
function r({ children: o, className: e }) {
|
|
4
|
-
return /* @__PURE__ */ t("p", { className: `uofg-hero-caption
|
|
4
|
+
return /* @__PURE__ */ t("p", { className: `uofg-hero-caption text-xl ${e}`, children: o });
|
|
5
5
|
}
|
|
6
6
|
r.displayName = "HeroCaption";
|
|
7
7
|
export {
|
package/dist/hero-content.js
CHANGED
|
@@ -1,48 +1,48 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx as
|
|
3
|
-
import { useContext as
|
|
4
|
-
import { tv as
|
|
5
|
-
import { Container as
|
|
6
|
-
import { HeroContext as
|
|
7
|
-
function
|
|
8
|
-
const
|
|
2
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
3
|
+
import { useContext as m } from "react";
|
|
4
|
+
import { tv as s } from "tailwind-variants";
|
|
5
|
+
import { Container as g } from "./container.js";
|
|
6
|
+
import { HeroContext as p } from "./hero-context.js";
|
|
7
|
+
function c({ children: r, alignment: l = "left" }) {
|
|
8
|
+
const t = m(p), o = s({
|
|
9
9
|
slots: {
|
|
10
10
|
base: "",
|
|
11
|
-
wrapper: "
|
|
12
|
-
container: "
|
|
11
|
+
wrapper: "flex w-full bg-black p-7 text-white lg:bg-black/80 lg:backdrop-blur",
|
|
12
|
+
container: "mx-auto flex flex-col gap-5"
|
|
13
13
|
},
|
|
14
14
|
variants: {
|
|
15
15
|
variant: {
|
|
16
16
|
spotlight: {
|
|
17
|
-
base: "
|
|
17
|
+
base: "flex w-full items-center lg:absolute lg:bottom-0 lg:left-1/2 lg:max-w-[137rem] lg:-translate-x-1/2 lg:p-4"
|
|
18
18
|
},
|
|
19
19
|
basic: {
|
|
20
|
-
base: "
|
|
20
|
+
base: "absolute bottom-0 left-1/2 flex h-full w-full -translate-x-1/2 items-end p-0"
|
|
21
21
|
}
|
|
22
22
|
},
|
|
23
23
|
alignment: {
|
|
24
24
|
left: {
|
|
25
|
-
wrapper: "
|
|
25
|
+
wrapper: "mr-auto lg:max-w-[50%]"
|
|
26
26
|
},
|
|
27
27
|
center: {
|
|
28
|
-
wrapper: "
|
|
29
|
-
container: "
|
|
30
|
-
link: "
|
|
28
|
+
wrapper: "mx-auto lg:max-w-[50%]",
|
|
29
|
+
container: "lg:items-center lg:text-center",
|
|
30
|
+
link: "lg:mx-auto"
|
|
31
31
|
},
|
|
32
32
|
right: {
|
|
33
|
-
wrapper: "
|
|
34
|
-
container: "
|
|
35
|
-
link: "
|
|
33
|
+
wrapper: "ml-auto lg:max-w-[50%]",
|
|
34
|
+
container: "lg:items-end lg:text-right",
|
|
35
|
+
link: "lg:ml-auto"
|
|
36
36
|
},
|
|
37
37
|
fullWidth: {
|
|
38
|
-
wrapper: "
|
|
38
|
+
wrapper: "mx-auto"
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
|
-
}), { base:
|
|
43
|
-
return (
|
|
42
|
+
}), { base: a, wrapper: n, container: i } = o({ alignment: l, variant: t == null ? void 0 : t.variant });
|
|
43
|
+
return (t == null ? void 0 : t.variant) === "spotlight" ? /* @__PURE__ */ e("div", { className: `uofg-hero-content ${a()}`, children: /* @__PURE__ */ e("div", { className: `uofg-hero-content-wrapper ${n()}`, children: /* @__PURE__ */ e("div", { className: `uofg-hero-content-container ${i()}`, children: r }) }) }) : /* @__PURE__ */ e(g, { className: `uofg-hero-content ${a()}`, children: r });
|
|
44
44
|
}
|
|
45
|
-
|
|
45
|
+
c.displayName = "HeroContent";
|
|
46
46
|
export {
|
|
47
|
-
|
|
47
|
+
c as HeroContent
|
|
48
48
|
};
|