quirk-ui 0.1.166 → 0.1.167
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/{HeroSubComponents-BeRgiITW.js → HeroSubComponents-3hFFfYfM.js} +22 -22
- package/dist/HeroSubComponents-CdkxyNka.cjs +6 -0
- package/dist/HeroSubComponents.css +1 -1
- package/dist/next/blocks/HeroBlock/HeroSubComponents.cjs +1 -1
- package/dist/next/blocks/HeroBlock/HeroSubComponents.mjs +1 -1
- package/dist/next/blocks/HeroBlock/HeroSubComponents.test.cjs +1 -1
- package/dist/next/blocks/HeroBlock/HeroSubComponents.test.mjs +1 -1
- package/dist/next/blocks/HeroBlock/index.cjs +1 -1
- package/dist/next/blocks/HeroBlock/index.mjs +1 -1
- package/package.json +1 -1
- package/dist/HeroSubComponents-6GQicmoV.cjs +0 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { jsx as t, jsxs as
|
|
2
|
-
import { memo as u, forwardRef as
|
|
3
|
-
import { buildEmbedSrc as
|
|
1
|
+
import { jsx as t, jsxs as p } from "react/jsx-runtime";
|
|
2
|
+
import { memo as u, forwardRef as v, useRef as y, useImperativeHandle as b, useEffect as g } from "react";
|
|
3
|
+
import { buildEmbedSrc as x, resolveImageUrl as w, resolveAltText as N } from "./next/utils/mediaUtils.mjs";
|
|
4
4
|
import { c as C } from "./createLucideIcon-C8GTh_Qx.js";
|
|
5
5
|
import { P as k } from "./play-DYgKiSaf.js";
|
|
6
6
|
import './HeroSubComponents.css';/**
|
|
@@ -12,7 +12,7 @@ import './HeroSubComponents.css';/**
|
|
|
12
12
|
const B = [
|
|
13
13
|
["rect", { x: "14", y: "4", width: "4", height: "16", rx: "1", key: "zuxfzm" }],
|
|
14
14
|
["rect", { x: "6", y: "4", width: "4", height: "16", rx: "1", key: "1okwgv" }]
|
|
15
|
-
], V = C("pause", B), I = "
|
|
15
|
+
], V = C("pause", B), I = "_hero_te1fh_1", E = "_container_te1fh_7", z = "_heading_te1fh_15", T = "_text_te1fh_22", j = "_eyebrow_te1fh_37", H = "_disclaimer_te1fh_41", P = "_articleDetails_te1fh_52", D = "_articleType_te1fh_65", F = "_articleCategories_te1fh_79", R = "_category_te1fh_85", A = "_number_te1fh_101", S = "_blog_te1fh_128", L = "_overlay_te1fh_154", U = "_tile_te1fh_213", Y = "_fullBleed_te1fh_322", q = "_media_te1fh_349", G = "_splitAlt_te1fh_437", J = "_split_te1fh_437", K = "_videoControl_te1fh_511", M = "_videoBackground_te1fh_559", O = "_iframe_te1fh_560", l = {
|
|
16
16
|
hero: I,
|
|
17
17
|
container: E,
|
|
18
18
|
heading: z,
|
|
@@ -24,7 +24,7 @@ const B = [
|
|
|
24
24
|
articleCategories: F,
|
|
25
25
|
category: R,
|
|
26
26
|
number: A,
|
|
27
|
-
default: "
|
|
27
|
+
default: "_default_te1fh_124",
|
|
28
28
|
blog: S,
|
|
29
29
|
overlay: L,
|
|
30
30
|
tile: U,
|
|
@@ -50,13 +50,13 @@ const B = [
|
|
|
50
50
|
children: e ? /* @__PURE__ */ t(V, { size: 18, "aria-hidden": !0 }) : /* @__PURE__ */ t(k, { size: 18, "aria-hidden": !0 })
|
|
51
51
|
}
|
|
52
52
|
);
|
|
53
|
-
}),
|
|
53
|
+
}), h = u(function({
|
|
54
54
|
url: e,
|
|
55
55
|
provider: i,
|
|
56
56
|
wrapperClassName: s,
|
|
57
57
|
iframeClassName: a
|
|
58
58
|
}) {
|
|
59
|
-
const r =
|
|
59
|
+
const r = x(e, i);
|
|
60
60
|
return /* @__PURE__ */ t("div", { className: s, children: /* @__PURE__ */ t(
|
|
61
61
|
"iframe",
|
|
62
62
|
{
|
|
@@ -68,8 +68,8 @@ const B = [
|
|
|
68
68
|
"aria-label": "Background video"
|
|
69
69
|
}
|
|
70
70
|
) });
|
|
71
|
-
}),
|
|
72
|
-
|
|
71
|
+
}), m = u(
|
|
72
|
+
v(function({
|
|
73
73
|
src: e,
|
|
74
74
|
autoPlay: i,
|
|
75
75
|
posterUrl: s,
|
|
@@ -77,9 +77,9 @@ const B = [
|
|
|
77
77
|
videoClassName: r,
|
|
78
78
|
isPlaying: c,
|
|
79
79
|
onToggle: d
|
|
80
|
-
},
|
|
81
|
-
const n =
|
|
82
|
-
return
|
|
80
|
+
}, f) {
|
|
81
|
+
const n = y(null);
|
|
82
|
+
return b(f, () => ({
|
|
83
83
|
play() {
|
|
84
84
|
var o;
|
|
85
85
|
(o = n.current) == null || o.play().catch(() => {
|
|
@@ -89,11 +89,11 @@ const B = [
|
|
|
89
89
|
var o;
|
|
90
90
|
(o = n.current) == null || o.pause();
|
|
91
91
|
}
|
|
92
|
-
})),
|
|
92
|
+
})), g(() => {
|
|
93
93
|
const o = n.current;
|
|
94
94
|
o && (c ? o.play().catch(() => {
|
|
95
95
|
}) : o.pause());
|
|
96
|
-
}, [c]), /* @__PURE__ */
|
|
96
|
+
}, [c]), /* @__PURE__ */ p("div", { className: a, children: [
|
|
97
97
|
/* @__PURE__ */ t(Q, { isPlaying: c, onToggle: d }),
|
|
98
98
|
/* @__PURE__ */ t(
|
|
99
99
|
"video",
|
|
@@ -120,16 +120,16 @@ const B = [
|
|
|
120
120
|
onToggle: r,
|
|
121
121
|
variant: c
|
|
122
122
|
}) {
|
|
123
|
-
const d = e.includes("vimeo.com"),
|
|
123
|
+
const d = e.includes("vimeo.com"), f = e.includes("youtube.com") || e.includes("youtu.be"), n = d || f, o = d ? "vimeo" : "youtube";
|
|
124
124
|
return c === "inline" ? n ? /* @__PURE__ */ t(
|
|
125
|
-
|
|
125
|
+
h,
|
|
126
126
|
{
|
|
127
127
|
url: e,
|
|
128
128
|
provider: o,
|
|
129
129
|
wrapperClassName: l.media
|
|
130
130
|
}
|
|
131
131
|
) : /* @__PURE__ */ t(
|
|
132
|
-
|
|
132
|
+
m,
|
|
133
133
|
{
|
|
134
134
|
src: e,
|
|
135
135
|
autoPlay: i,
|
|
@@ -139,7 +139,7 @@ const B = [
|
|
|
139
139
|
onToggle: r
|
|
140
140
|
}
|
|
141
141
|
) : n ? /* @__PURE__ */ t(
|
|
142
|
-
|
|
142
|
+
h,
|
|
143
143
|
{
|
|
144
144
|
url: e,
|
|
145
145
|
provider: o,
|
|
@@ -147,7 +147,7 @@ const B = [
|
|
|
147
147
|
iframeClassName: l.iframe
|
|
148
148
|
}
|
|
149
149
|
) : /* @__PURE__ */ t(
|
|
150
|
-
|
|
150
|
+
m,
|
|
151
151
|
{
|
|
152
152
|
src: e,
|
|
153
153
|
autoPlay: i,
|
|
@@ -163,7 +163,7 @@ const B = [
|
|
|
163
163
|
variant: s,
|
|
164
164
|
imageAdapter: a
|
|
165
165
|
}) {
|
|
166
|
-
const r =
|
|
166
|
+
const r = w(e, i, "medium");
|
|
167
167
|
if (!r) return null;
|
|
168
168
|
const c = N(e, i), d = /* @__PURE__ */ t(
|
|
169
169
|
"img",
|
|
@@ -195,9 +195,9 @@ const B = [
|
|
|
195
195
|
});
|
|
196
196
|
export {
|
|
197
197
|
oe as H,
|
|
198
|
-
|
|
198
|
+
m as N,
|
|
199
199
|
te as V,
|
|
200
200
|
Q as a,
|
|
201
|
-
|
|
201
|
+
h as b,
|
|
202
202
|
l as s
|
|
203
203
|
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use strict";require('./HeroSubComponents.css');const t=require("react/jsx-runtime"),l=require("react"),m=require("./next/utils/mediaUtils.cjs"),y=require("./createLucideIcon-DpotSgUx.cjs"),x=require("./play-CQBnZgNa.cjs");/**
|
|
2
|
+
* @license lucide-react v0.488.0 - ISC
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the ISC license.
|
|
5
|
+
* See the LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/const b=[["rect",{x:"14",y:"4",width:"4",height:"16",rx:"1",key:"zuxfzm"}],["rect",{x:"6",y:"4",width:"4",height:"16",rx:"1",key:"1okwgv"}]],g=y.createLucideIcon("pause",b),j="_hero_te1fh_1",w="_container_te1fh_7",C="_heading_te1fh_15",N="_text_te1fh_22",k="_eyebrow_te1fh_37",B="_disclaimer_te1fh_41",V="_articleDetails_te1fh_52",I="_articleType_te1fh_65",E="_articleCategories_te1fh_79",q="_category_te1fh_85",z="_number_te1fh_101",T="_blog_te1fh_128",H="_overlay_te1fh_154",R="_tile_te1fh_213",D="_fullBleed_te1fh_322",F="_media_te1fh_349",P="_splitAlt_te1fh_437",A="_split_te1fh_437",L="_videoControl_te1fh_511",S="_videoBackground_te1fh_559",U="_iframe_te1fh_560",n={hero:j,container:w,heading:C,text:N,eyebrow:k,disclaimer:B,articleDetails:V,articleType:I,articleCategories:E,category:q,number:z,default:"_default_te1fh_124",blog:T,overlay:H,tile:R,fullBleed:D,media:F,splitAlt:P,split:A,videoControl:L,videoBackground:S,iframe:U},p=l.memo(function({isPlaying:e,onToggle:i}){return t.jsx("button",{type:"button",title:e?"Pause the video":"Play the video","aria-label":e?"Pause video":"Play video",className:n.videoControl,onClick:i,children:e?t.jsx(g,{size:18,"aria-hidden":!0}):t.jsx(x.Play,{size:18,"aria-hidden":!0})})}),f=l.memo(function({url:e,provider:i,wrapperClassName:c,iframeClassName:s}){const r=m.buildEmbedSrc(e,i);return t.jsx("div",{className:c,children:t.jsx("iframe",{src:r,className:s,allow:"autoplay; fullscreen",allowFullScreen:!0,title:"Embedded video","aria-label":"Background video"})})}),v=l.memo(l.forwardRef(function({src:e,autoPlay:i,posterUrl:c,wrapperClassName:s,videoClassName:r,isPlaying:a,onToggle:u},h){const d=l.useRef(null);return l.useImperativeHandle(h,()=>({play(){var o;(o=d.current)==null||o.play().catch(()=>{})},pause(){var o;(o=d.current)==null||o.pause()}})),l.useEffect(()=>{const o=d.current;o&&(a?o.play().catch(()=>{}):o.pause())},[a]),t.jsxs("div",{className:s,children:[t.jsx(p,{isPlaying:a,onToggle:u}),t.jsx("video",{ref:d,src:e,autoPlay:i,loop:!0,muted:!0,playsInline:!0,poster:c,preload:"metadata",className:r,"aria-label":"Background video"})]})})),$=l.memo(function({url:e,autoPlay:i,posterUrl:c,isPlaying:s,onToggle:r,variant:a}){const u=e.includes("vimeo.com"),h=e.includes("youtube.com")||e.includes("youtu.be"),d=u||h,o=u?"vimeo":"youtube";return a==="inline"?d?t.jsx(f,{url:e,provider:o,wrapperClassName:n.media}):t.jsx(v,{src:e,autoPlay:i,posterUrl:c,wrapperClassName:n.media,isPlaying:s,onToggle:r}):d?t.jsx(f,{url:e,provider:o,wrapperClassName:n.videoBackground,iframeClassName:n.iframe}):t.jsx(v,{src:e,autoPlay:i,posterUrl:c,videoClassName:n.videoBackground,isPlaying:s,onToggle:r})}),Y=l.memo(function({image:e,mode:i,variant:c,imageAdapter:s}){const r=m.resolveImageUrl(e,i,"medium");if(!r)return null;const a=m.resolveAltText(e,i),u=t.jsx("img",{fetchPriority:"high",src:r,alt:a,draggable:!1,style:c==="fill"?{objectFit:"cover",width:"100%",height:"100%"}:{width:"100%",height:"100%"}});return s?t.jsx("div",{className:n.media,children:c==="fill"?s.render({src:r,alt:a,fill:!0,priority:!0,fetchPriority:"high",style:{objectFit:"cover"},draggable:!1,sizes:"(max-width: 767px) 600px, 1200px"}):s.render({src:r,alt:a,width:650,height:750,priority:!0,fetchPriority:"high"})}):t.jsx("div",{className:n.media,children:u})});exports.HeroImage=Y;exports.NativeVideo=v;exports.VideoBlock=$;exports.VideoControl=p;exports.VideoEmbed=f;exports.styles=n;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
._hero_1vxwy_1{width:100%;padding-top:var(--spacing-xl);padding-bottom:var(--spacing-xl)}._container_1vxwy_7{width:100%;max-width:var(--layout-width, 1300px);margin:0 auto;padding-left:var(--spacing-md);padding-right:var(--spacing-md)}._heading_1vxwy_15{display:flex;flex-direction:column;width:100%;flex:1;gap:var(--spacing-md)}._heading_1vxwy_15:not(:has(._text_1vxwy_22 .portableTextContainer)){gap:var(--spacing-lg)}._heading_1vxwy_15 h1,._heading_1vxwy_15 h2,._heading_1vxwy_15 h3,._heading_1vxwy_15 h4,._heading_1vxwy_15 h5,._heading_1vxwy_15 h6{width:100%;margin-block:0}._eyebrow_1vxwy_37{font-weight:var(--font-weight-bold)}._disclaimer_1vxwy_41{font-size:var(--font-size-sm)}._text_1vxwy_22{flex:1;display:flex;flex-direction:column;gap:var(--spacing-md)}._articleDetails_1vxwy_52{color:var(--color-secondary-75);display:flex;align-items:center;margin-bottom:var(--spacing-md);gap:var(--spacing-md)}@media (max-width: 767px){._articleDetails_1vxwy_52{flex-wrap:wrap;gap:var(--spacing-md)}}._articleType_1vxwy_65{display:flex;align-items:center;justify-content:center;background-color:var(--color-secondary-75);padding:0 var(--spacing-md);color:#fff;width:auto;height:36px;border-radius:var(--radius-full);text-transform:capitalize;text-decoration:none}._articleCategories_1vxwy_79{display:flex;flex-wrap:wrap;gap:var(--spacing-sm)}._category_1vxwy_85{border:1px solid var(--color-secondary-75);display:flex;align-items:center;justify-content:center;background-color:transparent;padding:0 var(--spacing-md);color:var(--color-secondary-75);width:auto;height:36px;border-radius:var(--radius-full);text-transform:capitalize;text-decoration:none}._number_1vxwy_101{display:inline-flex;align-items:center;justify-content:center;background-color:var(--color-secondary-75);color:#fff;width:25px;height:25px;border-radius:var(--radius-full);text-transform:capitalize;margin-right:var(--spacing-xs)}._pipe_1vxwy_114{margin:0 var(--spacing-sm)}@media (max-width: 767px){._pipe_1vxwy_114._hide_1vxwy_117{display:none}}._default_1vxwy_124{position:relative}._blog_1vxwy_128{position:relative;padding:0 var(--spacing-md)}._blog_1vxwy_128 ._container_1vxwy_7{max-width:var(--layout-width, 1300px);position:relative;display:flex;align-items:flex-end;width:100%;min-height:450px;height:100%;overflow:hidden;flex-grow:1;padding:0;border-radius:var(--radius-md)}._blog_1vxwy_128 ._container_1vxwy_7 img{z-index:1;transition:width .3s ease-in-out,height .3s ease-in-out}@media (max-width: 767px){._blog_1vxwy_128 ._overlay_1vxwy_154{width:100%;padding:4rem var(--spacing-md) var(--spacing-xl)}}._blog_1vxwy_128 ._text_1vxwy_22{z-index:3;position:relative;max-width:650px;background-color:var(--color-background);padding:var(--spacing-xl);border-radius:var(--radius-md)}@media (min-width: 768px){._blog_1vxwy_128 ._text_1vxwy_22{border-radius:var(--radius-md) var(--radius-md) 0 0}._blog_1vxwy_128 ._text_1vxwy_22:before{content:"";position:absolute;top:-25px;left:0;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:-20px 20px 0 20px var(--color-background)}._blog_1vxwy_128 ._text_1vxwy_22:after{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:0 10px 0 0 var(--color-background)}}._tile_1vxwy_213{position:relative;padding:0 var(--spacing-md)}._tile_1vxwy_213 ._container_1vxwy_7{max-width:var(--layout-width, 1300px);position:relative;display:flex;align-items:flex-end;width:100%;min-height:550px;height:100%;overflow:hidden;flex-grow:1;padding:var(--nav-height) 0 0;border-radius:var(--radius-md)}._tile_1vxwy_213 ._container_1vxwy_7 img{z-index:1;transition:width .3s ease-in-out,height .3s ease-in-out}@media (max-width: 767px){._tile_1vxwy_213 ._overlay_1vxwy_154{width:100%;padding:var(--spacing-md)}}@media (max-width: 767px){._tile_1vxwy_213:has(video) ._overlay_1vxwy_154{padding-bottom:3rem}}._tile_1vxwy_213 ._text_1vxwy_22{z-index:3;position:relative;max-width:650px;background-color:var(--color-background);padding:var(--spacing-xl);border-radius:var(--radius-md)}@media (min-width: 768px){._tile_1vxwy_213 ._text_1vxwy_22{border-radius:var(--radius-md) var(--radius-md) 0 0}._tile_1vxwy_213 ._text_1vxwy_22:before{content:"";position:absolute;top:-25px;left:0;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:-20px 20px 0 20px var(--color-background)}._tile_1vxwy_213 ._text_1vxwy_22:after{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:0 10px 0 0 var(--color-background)}}._fullBleed_1vxwy_322{position:relative;padding-top:0;padding-bottom:0}._fullBleed_1vxwy_322 ._container_1vxwy_7{max-width:var(--layout-width, 1300px);position:relative;display:flex;align-items:flex-end;width:100%;min-height:550px;height:100%;overflow:hidden;flex-grow:1;border-radius:0}._fullBleed_1vxwy_322 ._container_1vxwy_7 img{z-index:1;transition:width .3s ease-in-out,height .3s ease-in-out}._fullBleed_1vxwy_322 ._media_1vxwy_349{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;z-index:1;border-radius:0}._fullBleed_1vxwy_322 ._media_1vxwy_349 img,._fullBleed_1vxwy_322 ._media_1vxwy_349 video,._fullBleed_1vxwy_322 ._media_1vxwy_349 iframe{width:100%;height:100%;object-fit:cover;display:block}._fullBleed_1vxwy_322 ._overlay_1vxwy_154{position:relative;z-index:1;min-height:80vh;display:flex;align-items:flex-end;background:linear-gradient(to top,#000000a6,#0000004d,#0000)}@media (max-width: 767px){._fullBleed_1vxwy_322 ._overlay_1vxwy_154{min-height:60vh}}._fullBleed_1vxwy_322 ._text_1vxwy_22{max-width:700px;color:#fff;background-color:transparent;padding:0;border-radius:0;z-index:3;position:relative;max-width:650px;background-color:var(--color-background);padding:var(--spacing-xl);margin-top:var(--spacing-md);margin-bottom:var(--spacing-md);border-radius:var(--radius-md)}._fullBleed_1vxwy_322 ._text_1vxwy_22:before,._fullBleed_1vxwy_322 ._text_1vxwy_22:after{display:none}@media (max-width: 767px){._fullBleed_1vxwy_322:has(video) ._text_1vxwy_22{margin-bottom:3rem}}._default_1vxwy_124 ._media_1vxwy_349{position:relative;width:100%;height:480px;margin-bottom:var(--spacing-md);border-radius:var(--radius-md);overflow:hidden}@media (max-width: 767px){._default_1vxwy_124 ._media_1vxwy_349{height:280px}}._default_1vxwy_124 ._media_1vxwy_349 img{width:100%;height:100%;object-fit:cover;object-position:center;display:block}._splitAlt_1vxwy_437 ._media_1vxwy_349,._split_1vxwy_437 ._media_1vxwy_349{height:100%;padding-bottom:0;margin-bottom:0}._splitAlt_1vxwy_437 ._media_1vxwy_349 video,._splitAlt_1vxwy_437 ._media_1vxwy_349 iframe,._split_1vxwy_437 ._media_1vxwy_349 video,._split_1vxwy_437 ._media_1vxwy_349 iframe{position:relative;border-radius:var(--radius-md)}._splitAlt_1vxwy_437 ._media_1vxwy_349 img,._split_1vxwy_437 ._media_1vxwy_349 img{border-radius:var(--radius-md);width:100%;height:auto;max-height:500px;object-fit:contain}._splitAlt_1vxwy_437 ._container_1vxwy_7{display:flex;align-items:center;gap:3rem}@media (max-width: 767px){._splitAlt_1vxwy_437 ._container_1vxwy_7{flex-direction:column-reverse;gap:var(--spacing-xl)}._splitAlt_1vxwy_437 ._container_1vxwy_7 ._media_1vxwy_349{width:100%;max-width:500px}}._splitAlt_1vxwy_437 ._container_1vxwy_7 ._media_1vxwy_349{flex:.65}._splitAlt_1vxwy_437 ._container_1vxwy_7 ._heading_1vxwy_15{flex:.35}._split_1vxwy_437 ._container_1vxwy_7{display:flex;align-items:center;gap:3rem}._split_1vxwy_437 ._container_1vxwy_7 ._media_1vxwy_349{flex:1}._split_1vxwy_437 ._container_1vxwy_7 ._media_1vxwy_349 img{width:100%;height:auto;max-height:500px;object-fit:contain}@media (max-width: 767px){._split_1vxwy_437 ._container_1vxwy_7{flex-direction:column-reverse;gap:var(--spacing-xl)}._split_1vxwy_437 ._container_1vxwy_7 ._media_1vxwy_349{width:100%;max-width:500px}}._videoControl_1vxwy_511{position:absolute;bottom:var(--spacing-sm);right:var(--spacing-sm);z-index:5;background:#00000080;border:none;border-radius:50%;padding:var(--spacing-sm);cursor:pointer;color:#fff;display:flex;align-items:center;justify-content:center;transition:color .3s ease-in-out}._videoControl_1vxwy_511 svg{width:16px;height:16px}._videoControl_1vxwy_511:hover{color:var(--color-primary-25)}._media_1vxwy_349{position:relative;width:100%;height:0;overflow:hidden;border-radius:var(--radius-md);flex:1;margin-bottom:var(--spacing-md);line-height:0}._media_1vxwy_349 iframe,._media_1vxwy_349 video{position:absolute;top:0;left:0;width:100%;height:100%;object-fit:cover}._videoBackground_1vxwy_559,._iframe_1vxwy_560{position:absolute;top:0;left:0;width:100%;height:100%;object-fit:cover;z-index:0;pointer-events:none}._iframe_1vxwy_560{border:none}.splitAlt ._text_1vxwy_22{flex:.65}.vAlignmentTop._blog_1vxwy_128 ._overlay_1vxwy_154,.vAlignmentTop._tile_1vxwy_213 ._overlay_1vxwy_154{align-self:flex-start}.vAlignmentTop._blog_1vxwy_128 ._text_1vxwy_22,.vAlignmentTop._tile_1vxwy_213 ._text_1vxwy_22{border-radius:var(--radius-md) 0 0 var(--radius-md)}@media (min-width: 768px){.vAlignmentTop._blog_1vxwy_128 ._text_1vxwy_22,.vAlignmentTop._tile_1vxwy_213 ._text_1vxwy_22{border-radius:var(--radius-md) var(--radius-md) 0 0}.vAlignmentTop._blog_1vxwy_128 ._text_1vxwy_22:before,.vAlignmentTop._tile_1vxwy_213 ._text_1vxwy_22:before{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:-20px 20px 0 20px var(--color-background)}.vAlignmentTop._blog_1vxwy_128 ._text_1vxwy_22:after,.vAlignmentTop._tile_1vxwy_213 ._text_1vxwy_22:after{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:0 10px 0 0 var(--color-background)}}.vAlignmentTop._default_1vxwy_124 ._text_1vxwy_22,.vAlignmentTop._fullBleed_1vxwy_322 ._text_1vxwy_22{align-self:flex-start}.vAlignmentMiddle._blog_1vxwy_128 ._overlay_1vxwy_154,.vAlignmentMiddle._tile_1vxwy_213 ._overlay_1vxwy_154{align-self:center}.vAlignmentMiddle._blog_1vxwy_128 ._text_1vxwy_22,.vAlignmentMiddle._tile_1vxwy_213 ._text_1vxwy_22{border-radius:var(--radius-md) 0 0 var(--radius-md)}@media (min-width: 768px){.vAlignmentMiddle._blog_1vxwy_128 ._text_1vxwy_22,.vAlignmentMiddle._tile_1vxwy_213 ._text_1vxwy_22{border-radius:var(--radius-md) var(--radius-md) 0 0}.vAlignmentMiddle._blog_1vxwy_128 ._text_1vxwy_22:before,.vAlignmentMiddle._tile_1vxwy_213 ._text_1vxwy_22:before{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:-20px 20px 0 20px var(--color-background)}.vAlignmentMiddle._blog_1vxwy_128 ._text_1vxwy_22:after,.vAlignmentMiddle._tile_1vxwy_213 ._text_1vxwy_22:after{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:0 10px 0 0 var(--color-background)}}.vAlignmentMiddle._blog_1vxwy_128._default_1vxwy_124 ._text_1vxwy_22,.vAlignmentMiddle._blog_1vxwy_128._fullBleed_1vxwy_322 ._text_1vxwy_22,.vAlignmentMiddle._tile_1vxwy_213._default_1vxwy_124 ._text_1vxwy_22,.vAlignmentMiddle._tile_1vxwy_213._fullBleed_1vxwy_322 ._text_1vxwy_22{align-self:center}.vAlignmentMiddle .vAlignmentBottom._blog_1vxwy_128 ._overlay_1vxwy_154,.vAlignmentMiddle .vAlignmentBottom._tile_1vxwy_213 ._overlay_1vxwy_154,.vAlignmentMiddle .vAlignmentBottom._default_1vxwy_124 ._text_1vxwy_22,.vAlignmentMiddle .vAlignmentBottom._fullBleed_1vxwy_322 ._text_1vxwy_22{align-self:flex-end}.vAlignmentMiddle .hAlignmentLeft ._container_1vxwy_7{justify-content:flex-start}.vAlignmentMiddle .hAlignmentCenter ._container_1vxwy_7{justify-content:center}@media (min-width: 768px){.vAlignmentMiddle .hAlignmentCenter._blog_1vxwy_128 ._text_1vxwy_22,.vAlignmentMiddle .hAlignmentCenter._tile_1vxwy_213 ._text_1vxwy_22{border-radius:var(--radius-md) var(--radius-md) 0 0}.vAlignmentMiddle .hAlignmentCenter._blog_1vxwy_128 ._text_1vxwy_22:before,.vAlignmentMiddle .hAlignmentCenter._tile_1vxwy_213 ._text_1vxwy_22:before{content:"";position:absolute;top:-25px;right:0;height:25px;width:20px;border-bottom-right-radius:var(--radius-md);box-shadow:20px 20px 0 20px var(--color-background)}.vAlignmentMiddle .hAlignmentCenter._blog_1vxwy_128 ._text_1vxwy_22:after,.vAlignmentMiddle .hAlignmentCenter._tile_1vxwy_213 ._text_1vxwy_22:after{content:"";position:absolute;bottom:-25px;right:0;height:25px;width:20px;border-top-right-radius:var(--radius-md);box-shadow:20px -20px 0 20px var(--color-background)}}.hAlignmentRight ._container_1vxwy_7{justify-content:flex-end}@media (min-width: 768px){.hAlignmentRight._blog_1vxwy_128 ._text_1vxwy_22,.hAlignmentRight._tile_1vxwy_213 ._text_1vxwy_22{border-radius:var(--radius-md) var(--radius-md) 0 0}.hAlignmentRight._blog_1vxwy_128 ._text_1vxwy_22:before,.hAlignmentRight._tile_1vxwy_213 ._text_1vxwy_22:before{content:"";position:absolute;top:-25px;right:0;height:25px;width:20px;border-bottom-right-radius:var(--radius-md);box-shadow:20px 20px 0 20px var(--color-background)}.hAlignmentRight._blog_1vxwy_128 ._text_1vxwy_22:after,.hAlignmentRight._tile_1vxwy_213 ._text_1vxwy_22:after{content:"";position:absolute;bottom:0;left:-20px;height:25px;width:20px;border-bottom-right-radius:var(--radius-md);box-shadow:0 10px 0 0 var(--color-background)}}
|
|
1
|
+
._hero_te1fh_1{width:100%;padding-top:var(--spacing-xl);padding-bottom:var(--spacing-xl)}._container_te1fh_7{width:100%;max-width:var(--layout-width, 1300px);margin:0 auto;padding-left:var(--spacing-md);padding-right:var(--spacing-md)}._heading_te1fh_15{display:flex;flex-direction:column;width:100%;flex:1;gap:var(--spacing-md)}._heading_te1fh_15:not(:has(._text_te1fh_22 .portableTextContainer)){gap:var(--spacing-lg)}._heading_te1fh_15 h1,._heading_te1fh_15 h2,._heading_te1fh_15 h3,._heading_te1fh_15 h4,._heading_te1fh_15 h5,._heading_te1fh_15 h6{width:100%;margin-block:0}._eyebrow_te1fh_37{font-weight:var(--font-weight-bold)}._disclaimer_te1fh_41{font-size:var(--font-size-sm)}._text_te1fh_22{flex:1;display:flex;flex-direction:column;gap:var(--spacing-md)}._articleDetails_te1fh_52{color:var(--color-secondary-75);display:flex;align-items:center;margin-bottom:var(--spacing-md);gap:var(--spacing-md)}@media (max-width: 767px){._articleDetails_te1fh_52{flex-wrap:wrap;gap:var(--spacing-md)}}._articleType_te1fh_65{display:flex;align-items:center;justify-content:center;background-color:var(--color-secondary-75);padding:0 var(--spacing-md);color:#fff;width:auto;height:36px;border-radius:var(--radius-full);text-transform:capitalize;text-decoration:none}._articleCategories_te1fh_79{display:flex;flex-wrap:wrap;gap:var(--spacing-sm)}._category_te1fh_85{border:1px solid var(--color-secondary-75);display:flex;align-items:center;justify-content:center;background-color:transparent;padding:0 var(--spacing-md);color:var(--color-secondary-75);width:auto;height:36px;border-radius:var(--radius-full);text-transform:capitalize;text-decoration:none}._number_te1fh_101{display:inline-flex;align-items:center;justify-content:center;background-color:var(--color-secondary-75);color:#fff;width:25px;height:25px;border-radius:var(--radius-full);text-transform:capitalize;margin-right:var(--spacing-xs)}._pipe_te1fh_114{margin:0 var(--spacing-sm)}@media (max-width: 767px){._pipe_te1fh_114._hide_te1fh_117{display:none}}._default_te1fh_124{position:relative}._blog_te1fh_128{position:relative;padding:0 var(--spacing-md)}._blog_te1fh_128 ._container_te1fh_7{max-width:var(--layout-width, 1300px);position:relative;display:flex;align-items:flex-end;width:100%;min-height:450px;height:100%;overflow:hidden;flex-grow:1;padding:0;border-radius:var(--radius-md)}._blog_te1fh_128 ._container_te1fh_7 img{z-index:1;transition:width .3s ease-in-out,height .3s ease-in-out}@media (max-width: 767px){._blog_te1fh_128 ._overlay_te1fh_154{width:100%;padding:4rem var(--spacing-md) var(--spacing-xl)}}._blog_te1fh_128 ._text_te1fh_22{z-index:3;position:relative;max-width:650px;background-color:var(--color-background);padding:var(--spacing-xl);border-radius:var(--radius-md)}@media (min-width: 768px){._blog_te1fh_128 ._text_te1fh_22{border-radius:var(--radius-md) var(--radius-md) 0 0}._blog_te1fh_128 ._text_te1fh_22:before{content:"";position:absolute;top:-25px;left:0;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:-20px 20px 0 20px var(--color-background)}._blog_te1fh_128 ._text_te1fh_22:after{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:0 10px 0 0 var(--color-background)}}._tile_te1fh_213{position:relative;padding:0 var(--spacing-md)}._tile_te1fh_213 ._container_te1fh_7{max-width:var(--layout-width, 1300px);position:relative;display:flex;align-items:flex-end;width:100%;min-height:550px;height:100%;overflow:hidden;flex-grow:1;padding:var(--nav-height) 0 0;border-radius:var(--radius-md)}._tile_te1fh_213 ._container_te1fh_7 img{z-index:1;transition:width .3s ease-in-out,height .3s ease-in-out}@media (max-width: 767px){._tile_te1fh_213 ._overlay_te1fh_154{width:100%;padding:var(--spacing-md)}}@media (max-width: 767px){._tile_te1fh_213:has(video) ._overlay_te1fh_154{padding-bottom:3rem}}._tile_te1fh_213 ._text_te1fh_22{z-index:3;position:relative;max-width:650px;background-color:var(--color-background);padding:var(--spacing-xl);border-radius:var(--radius-md)}@media (min-width: 768px){._tile_te1fh_213 ._text_te1fh_22{border-radius:var(--radius-md) var(--radius-md) 0 0}._tile_te1fh_213 ._text_te1fh_22:before{content:"";position:absolute;top:-25px;left:0;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:-20px 20px 0 20px var(--color-background)}._tile_te1fh_213 ._text_te1fh_22:after{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:0 10px 0 0 var(--color-background)}}._fullBleed_te1fh_322{position:relative;padding-top:0;padding-bottom:0}._fullBleed_te1fh_322 ._container_te1fh_7{max-width:var(--layout-width, 1300px);position:relative;display:flex;align-items:flex-end;width:100%;min-height:550px;height:100%;overflow:hidden;flex-grow:1;border-radius:0}._fullBleed_te1fh_322 ._container_te1fh_7 img{z-index:1;transition:width .3s ease-in-out,height .3s ease-in-out}._fullBleed_te1fh_322 ._media_te1fh_349{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;z-index:1;border-radius:0}._fullBleed_te1fh_322 ._media_te1fh_349 img,._fullBleed_te1fh_322 ._media_te1fh_349 video,._fullBleed_te1fh_322 ._media_te1fh_349 iframe{width:100%;height:100%;object-fit:cover;display:block}._fullBleed_te1fh_322 ._overlay_te1fh_154{position:relative;z-index:1;min-height:80vh;display:flex;align-items:flex-end;background:linear-gradient(to top,#000000a6,#0000004d,#0000)}@media (max-width: 767px){._fullBleed_te1fh_322 ._overlay_te1fh_154{min-height:60vh}}._fullBleed_te1fh_322 ._text_te1fh_22{max-width:700px;color:#fff;background-color:transparent;padding:0;border-radius:0;z-index:3;position:relative;max-width:650px;background-color:var(--color-background);padding:var(--spacing-xl);margin-top:var(--spacing-md);margin-bottom:var(--spacing-md);border-radius:var(--radius-md)}._fullBleed_te1fh_322 ._text_te1fh_22:before,._fullBleed_te1fh_322 ._text_te1fh_22:after{display:none}@media (max-width: 767px){._fullBleed_te1fh_322:has(video) ._text_te1fh_22{margin-bottom:3rem}}._default_te1fh_124 ._media_te1fh_349{position:relative;width:100%;height:480px;margin-bottom:var(--spacing-md);border-radius:var(--radius-md);overflow:hidden}@media (max-width: 767px){._default_te1fh_124 ._media_te1fh_349{height:280px}}._default_te1fh_124 ._media_te1fh_349 img{width:100%;height:100%;object-fit:cover;object-position:center;display:block}._splitAlt_te1fh_437 ._media_te1fh_349,._split_te1fh_437 ._media_te1fh_349{height:100%;padding-bottom:0;margin-bottom:0}._splitAlt_te1fh_437 ._media_te1fh_349 video,._splitAlt_te1fh_437 ._media_te1fh_349 iframe,._split_te1fh_437 ._media_te1fh_349 video,._split_te1fh_437 ._media_te1fh_349 iframe{position:relative;border-radius:var(--radius-md)}._splitAlt_te1fh_437 ._media_te1fh_349 img,._split_te1fh_437 ._media_te1fh_349 img{border-radius:var(--radius-md);width:100%;height:auto;max-height:500px;object-fit:contain}._splitAlt_te1fh_437 ._container_te1fh_7{display:flex;align-items:center;gap:3rem}@media (max-width: 767px){._splitAlt_te1fh_437 ._container_te1fh_7{flex-direction:column-reverse;gap:var(--spacing-xl)}._splitAlt_te1fh_437 ._container_te1fh_7 ._media_te1fh_349{width:100%;max-width:500px}}._splitAlt_te1fh_437 ._container_te1fh_7 ._media_te1fh_349{flex:.65}._splitAlt_te1fh_437 ._container_te1fh_7 ._heading_te1fh_15{flex:.35}._split_te1fh_437 ._container_te1fh_7{display:flex;align-items:center;gap:3rem}._split_te1fh_437 ._container_te1fh_7 ._media_te1fh_349{flex:1}._split_te1fh_437 ._container_te1fh_7 ._media_te1fh_349 img{width:100%;height:auto;max-height:500px;object-fit:contain}@media (max-width: 767px){._split_te1fh_437 ._container_te1fh_7{flex-direction:column-reverse;gap:var(--spacing-xl)}._split_te1fh_437 ._container_te1fh_7 ._media_te1fh_349{width:100%;max-width:500px}}._videoControl_te1fh_511{position:absolute;bottom:var(--spacing-sm);right:var(--spacing-sm);z-index:5;background:#00000080;border:none;border-radius:50%;padding:var(--spacing-sm);cursor:pointer;color:#fff;display:flex;align-items:center;justify-content:center;transition:color .3s ease-in-out}._videoControl_te1fh_511 svg{width:16px;height:16px}._videoControl_te1fh_511:hover{color:var(--color-primary-25)}._media_te1fh_349{position:relative;width:100%;height:0;overflow:hidden;border-radius:var(--radius-md);flex:1;margin-bottom:var(--spacing-md);line-height:0}._media_te1fh_349 iframe,._media_te1fh_349 video{position:absolute;top:0;left:0;width:100%;height:100%;object-fit:cover}._videoBackground_te1fh_559,._iframe_te1fh_560{position:absolute;top:0;left:0;width:100%;height:100%;object-fit:cover;z-index:0;pointer-events:none}._iframe_te1fh_560{border:none}.splitAlt ._text_te1fh_22{flex:.65}.vAlignmentTop._blog_te1fh_128 ._overlay_te1fh_154,.vAlignmentTop._tile_te1fh_213 ._overlay_te1fh_154{align-self:flex-start}.vAlignmentTop._blog_te1fh_128 ._text_te1fh_22,.vAlignmentTop._tile_te1fh_213 ._text_te1fh_22{border-radius:var(--radius-md) 0 0 var(--radius-md)}@media (min-width: 768px){.vAlignmentTop._blog_te1fh_128 ._text_te1fh_22,.vAlignmentTop._tile_te1fh_213 ._text_te1fh_22{border-radius:var(--radius-md) var(--radius-md) 0 0}.vAlignmentTop._blog_te1fh_128 ._text_te1fh_22:before,.vAlignmentTop._tile_te1fh_213 ._text_te1fh_22:before{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:-20px 20px 0 20px var(--color-background)}.vAlignmentTop._blog_te1fh_128 ._text_te1fh_22:after,.vAlignmentTop._tile_te1fh_213 ._text_te1fh_22:after{content:"";position:absolute;bottom:0;right:-20px;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:0 10px 0 0 var(--color-background)}}.vAlignmentTop._default_te1fh_124 ._text_te1fh_22,.vAlignmentTop._fullBleed_te1fh_322 ._text_te1fh_22{align-self:flex-start}.vAlignmentMiddle._blog_te1fh_128 ._overlay_te1fh_154,.vAlignmentMiddle._tile_te1fh_213 ._overlay_te1fh_154{align-self:center}.vAlignmentMiddle._blog_te1fh_128.hAlignmentRight ._text_te1fh_22,.vAlignmentMiddle._tile_te1fh_213.hAlignmentRight ._text_te1fh_22{border-radius:var(--radius-md) 0 0 var(--radius-md)}@media (min-width: 768px){.vAlignmentMiddle._blog_te1fh_128.hAlignmentRight ._text_te1fh_22,.vAlignmentMiddle._tile_te1fh_213.hAlignmentRight ._text_te1fh_22{border-radius:var(--radius-md) 0 0 var(--radius-md)}.vAlignmentMiddle._blog_te1fh_128.hAlignmentRight ._text_te1fh_22:before,.vAlignmentMiddle._tile_te1fh_213.hAlignmentRight ._text_te1fh_22:before{content:"";position:absolute;bottom:0;right:-20px;left:unset;height:25px;width:20px;border-bottom-left-radius:var(--radius-md);box-shadow:-25px 20px 0 20px var(--color-background)}.vAlignmentMiddle._blog_te1fh_128.hAlignmentRight ._text_te1fh_22:after,.vAlignmentMiddle._tile_te1fh_213.hAlignmentRight ._text_te1fh_22:after{content:"";position:absolute;bottom:-25px;right:0;height:25px;width:20px;border-top-right-radius:var(--radius-md);box-shadow:20px -20px 0 20px var(--color-background)}}.vAlignmentMiddle._blog_te1fh_128._default_te1fh_124 ._text_te1fh_22,.vAlignmentMiddle._blog_te1fh_128._fullBleed_te1fh_322 ._text_te1fh_22,.vAlignmentMiddle._tile_te1fh_213._default_te1fh_124 ._text_te1fh_22,.vAlignmentMiddle._tile_te1fh_213._fullBleed_te1fh_322 ._text_te1fh_22{align-self:center}.vAlignmentMiddle .vAlignmentBottom._blog_te1fh_128 ._overlay_te1fh_154,.vAlignmentMiddle .vAlignmentBottom._tile_te1fh_213 ._overlay_te1fh_154,.vAlignmentMiddle .vAlignmentBottom._default_te1fh_124 ._text_te1fh_22,.vAlignmentMiddle .vAlignmentBottom._fullBleed_te1fh_322 ._text_te1fh_22{align-self:flex-end}.vAlignmentMiddle .hAlignmentLeft ._container_te1fh_7{justify-content:flex-start}.vAlignmentMiddle .hAlignmentCenter ._container_te1fh_7{justify-content:center}@media (min-width: 768px){.vAlignmentMiddle .hAlignmentCenter._blog_te1fh_128 ._text_te1fh_22,.vAlignmentMiddle .hAlignmentCenter._tile_te1fh_213 ._text_te1fh_22{border-radius:var(--radius-md) var(--radius-md) 0 0}.vAlignmentMiddle .hAlignmentCenter._blog_te1fh_128 ._text_te1fh_22:before,.vAlignmentMiddle .hAlignmentCenter._tile_te1fh_213 ._text_te1fh_22:before{content:"";position:absolute;top:-25px;right:0;height:25px;width:20px;border-bottom-right-radius:var(--radius-md);box-shadow:20px 20px 0 20px var(--color-background)}.vAlignmentMiddle .hAlignmentCenter._blog_te1fh_128 ._text_te1fh_22:after,.vAlignmentMiddle .hAlignmentCenter._tile_te1fh_213 ._text_te1fh_22:after{content:"";position:absolute;bottom:-25px;right:0;height:25px;width:20px;border-top-right-radius:var(--radius-md);box-shadow:20px -20px 0 20px var(--color-background)}}.hAlignmentRight ._container_te1fh_7{justify-content:flex-end}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("react/jsx-runtime");require("react");require("../../utils/mediaUtils.cjs");const e=require("../../../HeroSubComponents-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("react/jsx-runtime");require("react");require("../../utils/mediaUtils.cjs");const e=require("../../../HeroSubComponents-CdkxyNka.cjs");require("../../../play-CQBnZgNa.cjs");exports.HeroImage=e.HeroImage;exports.NativeVideo=e.NativeVideo;exports.VideoBlock=e.VideoBlock;exports.VideoControl=e.VideoControl;exports.VideoEmbed=e.VideoEmbed;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
3
|
import "../../utils/mediaUtils.mjs";
|
|
4
|
-
import { H as t, N as d, V as p, a as s, b as V } from "../../../HeroSubComponents-
|
|
4
|
+
import { H as t, N as d, V as p, a as s, b as V } from "../../../HeroSubComponents-3hFFfYfM.js";
|
|
5
5
|
import "../../../play-DYgKiSaf.js";
|
|
6
6
|
export {
|
|
7
7
|
t as HeroImage,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const i=require("react/jsx-runtime"),e=require("../../../react.esm-C_9Ma9mj.cjs"),r=require("../../../HeroSubComponents-
|
|
1
|
+
"use strict";const i=require("react/jsx-runtime"),e=require("../../../react.esm-C_9Ma9mj.cjs"),r=require("../../../HeroSubComponents-CdkxyNka.cjs");e.vi.mock("./styles.module.css",()=>({default:new Proxy({},{get:(t,n)=>n})}));e.vi.mock("lucide-react",()=>({Pause:()=>i.jsx("span",{"data-testid":"pause-icon"}),Play:()=>i.jsx("span",{"data-testid":"play-icon"})}));e.vi.mock("../../utils/mediaUtils",()=>({buildEmbedSrc:e.vi.fn((o,t)=>`https://embed.${t}.com/${o}`),resolveImageUrl:e.vi.fn(o=>o?"https://cdn.example.com/image.jpg":void 0),resolveAltText:e.vi.fn(()=>"Hero image alt text")}));e.describe("1. VideoControl — Play/Pause icons",()=>{e.it("shows Play icon when isPlaying=false",()=>{e.render(i.jsx(r.VideoControl,{isPlaying:!1,onToggle:e.vi.fn()})),e.globalExpect(e.screen.getByTestId("play-icon")).toBeInTheDocument(),e.globalExpect(e.screen.queryByTestId("pause-icon")).toBeNull()}),e.it("shows Pause icon when isPlaying=true",()=>{e.render(i.jsx(r.VideoControl,{isPlaying:!0,onToggle:e.vi.fn()})),e.globalExpect(e.screen.getByTestId("pause-icon")).toBeInTheDocument(),e.globalExpect(e.screen.queryByTestId("play-icon")).toBeNull()}),e.it("has correct aria-label when playing",()=>{e.render(i.jsx(r.VideoControl,{isPlaying:!0,onToggle:e.vi.fn()})),e.globalExpect(e.screen.getByRole("button").getAttribute("aria-label")).toBe("Pause video")}),e.it("has correct aria-label when paused",()=>{e.render(i.jsx(r.VideoControl,{isPlaying:!1,onToggle:e.vi.fn()})),e.globalExpect(e.screen.getByRole("button").getAttribute("aria-label")).toBe("Play video")})});e.describe("2. VideoControl — onToggle called on click",()=>{e.it("calls onToggle when button is clicked",()=>{const o=e.vi.fn();e.render(i.jsx(r.VideoControl,{isPlaying:!1,onToggle:o})),e.fireEvent.click(e.screen.getByRole("button")),e.globalExpect(o).toHaveBeenCalledOnce()})});e.describe("3. VideoEmbed — iframe rendered with built src",()=>{e.it("renders an iframe",()=>{const{container:o}=e.render(i.jsx(r.VideoEmbed,{url:"https://vimeo.com/123",provider:"vimeo"}));e.globalExpect(o.querySelector("iframe")).toBeInTheDocument()}),e.it("calls buildEmbedSrc with url and provider",async()=>{const{buildEmbedSrc:o}=await Promise.resolve().then(()=>require("../../utils/mediaUtils.cjs"));e.render(i.jsx(r.VideoEmbed,{url:"https://vimeo.com/123",provider:"vimeo"})),e.globalExpect(o).toHaveBeenCalledWith("https://vimeo.com/123","vimeo")}),e.it("applies wrapperClassName to the wrapper div",()=>{var t;const{container:o}=e.render(i.jsx(r.VideoEmbed,{url:"https://vimeo.com/123",provider:"vimeo",wrapperClassName:"my-wrapper"}));e.globalExpect((t=o.firstElementChild)==null?void 0:t.className).toContain("my-wrapper")})});e.describe("4. VideoEmbed — YouTube provider",()=>{e.it("calls buildEmbedSrc with youtube provider",async()=>{const{buildEmbedSrc:o}=await Promise.resolve().then(()=>require("../../utils/mediaUtils.cjs"));e.render(i.jsx(r.VideoEmbed,{url:"https://youtube.com/embed/abc",provider:"youtube"})),e.globalExpect(o).toHaveBeenCalledWith("https://youtube.com/embed/abc","youtube")})});e.describe("5. VideoBlock inline variant",()=>{const o={autoPlay:!1,isPlaying:!1,onToggle:e.vi.fn(),variant:"inline"};e.it("renders an iframe for a Vimeo URL",()=>{const{container:t}=e.render(i.jsx(r.VideoBlock,{...o,url:"https://vimeo.com/123"}));e.globalExpect(t.querySelector("iframe")).toBeInTheDocument()}),e.it("renders a native video for a plain URL",()=>{const{container:t}=e.render(i.jsx(r.VideoBlock,{...o,url:"https://cdn.example.com/clip.mp4"}));e.globalExpect(t.querySelector("video")).toBeInTheDocument()}),e.it("renders an iframe for a YouTube URL",()=>{const{container:t}=e.render(i.jsx(r.VideoBlock,{...o,url:"https://youtube.com/embed/abc"}));e.globalExpect(t.querySelector("iframe")).toBeInTheDocument()})});e.describe("6. VideoBlock background variant",()=>{const o={autoPlay:!1,isPlaying:!1,onToggle:e.vi.fn(),variant:"background"};e.it("renders an iframe for Vimeo in background mode",()=>{const{container:t}=e.render(i.jsx(r.VideoBlock,{...o,url:"https://vimeo.com/123"}));e.globalExpect(t.querySelector("iframe")).toBeInTheDocument()}),e.it("renders a native video for plain URL in background mode",()=>{const{container:t}=e.render(i.jsx(r.VideoBlock,{...o,url:"https://cdn.example.com/clip.mp4"}));e.globalExpect(t.querySelector("video")).toBeInTheDocument()})});e.describe("7. NativeVideo — renders video with correct attributes",()=>{e.it("renders a video element",()=>{const{container:o}=e.render(i.jsx(r.NativeVideo,{src:"https://cdn.example.com/clip.mp4",autoPlay:!1,isPlaying:!1,onToggle:e.vi.fn()}));e.globalExpect(o.querySelector("video")).toBeInTheDocument()}),e.it("sets src on the video element",()=>{var t;const{container:o}=e.render(i.jsx(r.NativeVideo,{src:"https://cdn.example.com/clip.mp4",autoPlay:!1,isPlaying:!1,onToggle:e.vi.fn()}));e.globalExpect((t=o.querySelector("video"))==null?void 0:t.src).toContain("clip.mp4")}),e.it("renders muted and loop attributes",()=>{const{container:o}=e.render(i.jsx(r.NativeVideo,{src:"https://cdn.example.com/clip.mp4",autoPlay:!1,isPlaying:!1,onToggle:e.vi.fn()})),t=o.querySelector("video");e.globalExpect(t.muted).toBe(!0),e.globalExpect(t.loop).toBe(!0)}),e.it("renders the VideoControl button",()=>{e.render(i.jsx(r.NativeVideo,{src:"https://cdn.example.com/clip.mp4",autoPlay:!1,isPlaying:!1,onToggle:e.vi.fn()})),e.globalExpect(e.screen.getByRole("button")).toBeInTheDocument()})});e.describe("8. NativeVideo — plays/pauses when isPlaying changes",()=>{e.it("calls video.pause() when isPlaying becomes false",()=>{HTMLMediaElement.prototype.play=e.vi.fn().mockResolvedValue(void 0),HTMLMediaElement.prototype.pause=e.vi.fn();const{rerender:o}=e.render(i.jsx(r.NativeVideo,{src:"https://cdn.example.com/clip.mp4",autoPlay:!1,isPlaying:!0,onToggle:e.vi.fn()}));o(i.jsx(r.NativeVideo,{src:"https://cdn.example.com/clip.mp4",autoPlay:!1,isPlaying:!1,onToggle:e.vi.fn()})),e.globalExpect(HTMLMediaElement.prototype.pause).toHaveBeenCalled()})});e.describe("9. HeroImage — plain <img> fallback when no imageAdapter",()=>{const o={asset:{_ref:"img-abc"}};e.it("renders an img element",()=>{const{container:t}=e.render(i.jsx(r.HeroImage,{image:o,mode:"light",variant:"intrinsic"}));e.globalExpect(t.querySelector("img")).toBeInTheDocument()}),e.it("sets the resolved src on the img",()=>{var n;const{container:t}=e.render(i.jsx(r.HeroImage,{image:o,mode:"light",variant:"intrinsic"}));e.globalExpect((n=t.querySelector("img"))==null?void 0:n.src).toContain("cdn.example.com")}),e.it("sets the alt text on the img",()=>{var n;const{container:t}=e.render(i.jsx(r.HeroImage,{image:o,mode:"light",variant:"intrinsic"}));e.globalExpect((n=t.querySelector("img"))==null?void 0:n.alt).toBe("Hero image alt text")})});e.describe("10. HeroImage — renders via imageAdapter.render when provided",()=>{const o={asset:{_ref:"img-abc"}};e.it("calls imageAdapter.render",()=>{const t={render:e.vi.fn(()=>i.jsx("img",{src:"x",alt:"adapter"}))};e.render(i.jsx(r.HeroImage,{image:o,mode:"light",variant:"fill",imageAdapter:t})),e.globalExpect(t.render).toHaveBeenCalledOnce()}),e.it("passes fill=true for the fill variant",()=>{const t={render:e.vi.fn(()=>i.jsx("img",{src:"x",alt:"adapter"}))};e.render(i.jsx(r.HeroImage,{image:o,mode:"light",variant:"fill",imageAdapter:t})),e.globalExpect(t.render).toHaveBeenCalledWith(e.globalExpect.objectContaining({fill:!0}))})});e.describe("11. HeroImage — returns null when resolveImageUrl returns undefined",()=>{e.it("renders nothing when image is undefined",async()=>{const{resolveImageUrl:o}=await Promise.resolve().then(()=>require("../../utils/mediaUtils.cjs"));e.vi.mocked(o).mockReturnValueOnce(void 0);const{container:t}=e.render(i.jsx(r.HeroImage,{image:void 0,mode:"light",variant:"intrinsic"}));e.globalExpect(t.firstChild).toBeNull()})});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as t } from "react/jsx-runtime";
|
|
2
2
|
import { v as r, d as l, i as n, r as i, g as a, s, f as y } from "../../../react.esm-DjxyacK8.js";
|
|
3
|
-
import { a as u, N as m, b as g, V as p, H as d } from "../../../HeroSubComponents-
|
|
3
|
+
import { a as u, N as m, b as g, V as p, H as d } from "../../../HeroSubComponents-3hFFfYfM.js";
|
|
4
4
|
r.mock("./styles.module.css", () => ({ default: new Proxy({}, { get: (o, c) => c }) }));
|
|
5
5
|
r.mock("lucide-react", () => ({
|
|
6
6
|
Pause: () => /* @__PURE__ */ t("span", { "data-testid": "pause-icon" }),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),_=require("react"),Y=require("./HeroContext.cjs"),s=require("../../../HeroSubComponents-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react/jsx-runtime"),_=require("react"),Y=require("./HeroContext.cjs"),s=require("../../../HeroSubComponents-CdkxyNka.cjs"),B=require("../../utils/mediaUtils.cjs"),G=require("../../hooks/usePrefersReducedMotion.cjs"),J={default:s.styles.default,split:s.styles.split,"split-35-65":s.styles.splitAlt,tile:s.styles.tile,fullBleed:s.styles.fullBleed,blog:s.styles.blog};function H({heading:e,callToAction:r,renderRichText:t,renderCallToAction:c,extraChildren:n}){return l.jsxs(l.Fragment,{children:[l.jsxs("div",{children:[e.eyebrow&&(t==null?void 0:t({blocks:e.eyebrow,className:s.styles.eyebrow})),t==null?void 0:t({blocks:e.title})]}),n,e.description&&(t==null?void 0:t({blocks:e.description})),r&&(c==null?void 0:c(r)),e.disclaimer&&(t==null?void 0:t({blocks:e.disclaimer,className:s.styles.disclaimer}))]})}function V({id:e,paddingClasses:r,layoutClass:t,verticalAlignmentClass:c,horizontalAlignmentClass:n,extraSectionClass:a,className:y,mediaNode:i,overlayContent:m}){return l.jsx("section",{id:e,className:`${s.styles.hero} ${r} ${t} ${c} ${n} ${a??""}${y?` ${y}`:""}`,children:l.jsxs("article",{className:s.styles.container,children:[i,l.jsx("div",{className:s.styles.overlay,children:l.jsx("div",{className:s.styles.text,children:m})})]})})}const K={render:({href:e,className:r,children:t})=>l.jsx("a",{href:e,className:r,children:t})};function Q({heading:e,image:r,video:t,callToAction:c,pageData:n,styleOptions:a,id:y,className:i,imageAdapter:m,linkAdapter:b,renderRichText:o,renderCallToAction:u}){var F;const $=G.usePrefersReducedMotion(),[C,L]=_.useState(!$),d=(()=>{try{return Y.useHeroContext()}catch{return null}})(),z=b??K,j=(a==null?void 0:a.layout)??"default",v=((F=a==null?void 0:a.padding)==null?void 0:F.join(" "))??"",k=J[j]??s.styles.default,w=a==null?void 0:a.verticalAlignment,f=a==null?void 0:a.horizontalAlignment,N=(a==null?void 0:a.mode)??"light",I=B.resolveImageUrl(r,N,"medium"),g=B.resolveImageUrl(r,N,"large"),S=B.resolveAltText(r,N),M=t?B.detectVideoProvider(t):null,P=!$,q=_.useCallback(()=>{L(x=>!x)},[]);_.useEffect(()=>{if(!(j==="tile"||j==="fullBleed")||typeof window>"u")return;d==null||d.setIsFullbleedHeroAtTop(!0);const E=()=>{d==null||d.setIsFullbleedHeroAtTop(window.scrollY===0)};return window.addEventListener("scroll",E,{passive:!0}),()=>window.removeEventListener("scroll",E)},[j,d]),_.useEffect(()=>{L(!$)},[$]);const p=t&&M?l.jsx(s.VideoBlock,{url:t,autoPlay:P,posterUrl:g,isPlaying:C,onToggle:q,variant:"inline"}):r?l.jsx(s.HeroImage,{image:r,mode:N,variant:"intrinsic",imageAdapter:m}):null,U=t&&M?l.jsx(s.VideoBlock,{url:t,autoPlay:P,posterUrl:g,isPlaying:C,onToggle:q,variant:"background"}):I||g?m?m.render({src:g??I??"",alt:S,fill:!0,priority:!0,style:{objectFit:"cover"},draggable:!1,sizes:"(min-width: 500px) 500px, 100vw"}):l.jsx("img",{src:g??I,alt:S,style:{position:"absolute",inset:0,width:"100%",height:"100%",objectFit:"cover"},draggable:!1}):null,W=n?X(n,z):null;switch(j){case"split":case"split-35-65":return l.jsx("section",{id:y,className:`${s.styles.hero} ${k} ${v} {verticalAlignmentClass} ${f} ${i?` ${i}`:""}`,children:l.jsxs("article",{className:s.styles.container,children:[l.jsxs("div",{className:s.styles.heading,children:[l.jsxs("div",{children:[e.eyebrow&&(o==null?void 0:o({blocks:e.eyebrow,className:s.styles.eyebrow})),o==null?void 0:o({blocks:e.title})]}),l.jsxs("div",{className:s.styles.text,children:[e.description&&(o==null?void 0:o({blocks:e.description})),c&&(u==null?void 0:u(c))]}),e.disclaimer&&(o==null?void 0:o({blocks:e.disclaimer,className:s.styles.disclaimer}))]}),p]})});case"default":return l.jsx("section",{id:y,className:`${s.styles.hero} ${v} ${k} ${w} ${f} ${i?` ${i}`:""}`,children:l.jsxs("article",{className:s.styles.container,children:[p,l.jsx("div",{className:s.styles.text,children:l.jsx(H,{heading:e,callToAction:c,renderRichText:o,renderCallToAction:u})})]})});case"tile":return l.jsx(V,{id:y,paddingClasses:v,layoutClass:k,verticalAlignmentClass:w,horizontalAlignmentClass:f,extraSectionClass:"heroTile",className:i,mediaNode:U,overlayContent:l.jsx(H,{heading:e,callToAction:c,renderRichText:o,renderCallToAction:u})});case"fullBleed":return l.jsxs("section",{"data-overlay":"true",id:y,className:`${s.styles.hero} ${s.styles.fullBleed} ${v} ${w} ${f} ${i?` ${i}`:""}`,children:[l.jsx("div",{className:s.styles.media,children:U}),l.jsx("div",{className:s.styles.container,children:l.jsx("div",{className:s.styles.text,children:l.jsx(H,{heading:e,callToAction:c,renderRichText:o,renderCallToAction:u})})})]});case"blog":return l.jsx(V,{id:y,paddingClasses:v,layoutClass:k,verticalAlignmentClass:w,horizontalAlignmentClass:f,className:i,mediaNode:U,overlayContent:l.jsx(H,{heading:e,callToAction:c,renderRichText:o,renderCallToAction:u,extraChildren:W})})}}function X(e,r){var i,m;const t=((i=e.categories)==null?void 0:i.filter(b=>{var o,u;return!((u=(o=b.slug)==null?void 0:o.current)!=null&&u.startsWith("library/type"))}))??[],c=t[0]??null,n=t[1]??null,a=((m=e.categories)==null?void 0:m.find(b=>{var o,u;return(u=(o=b.slug)==null?void 0:o.current)==null?void 0:u.startsWith("library/type")}))??null,y=n&&n.title.toLowerCase()!=="library"&&!n.slug.current.includes("keywords");return l.jsxs("div",{className:s.styles.articleDetails,children:[a&&r.render({href:`/blog/search?categories=${encodeURIComponent(a._id)}`,className:s.styles.articleType,children:a.title}),l.jsxs("div",{className:s.styles.articleCategories,children:[c&&r.render({href:`/blog/search?categories=${encodeURIComponent(c._id)}`,className:s.styles.category,children:c.title}),y&&r.render({href:`/blog/search?categories=${encodeURIComponent(n._id)}`,className:s.styles.category,children:n.title})]}),e.timeToRead>0&&l.jsxs("span",{children:[l.jsx("span",{className:s.styles.number,children:e.timeToRead}),"min read"]})]})}exports.HeroBlock=Q;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as t, jsxs as m, Fragment as K } from "react/jsx-runtime";
|
|
2
2
|
import { useState as Q, useCallback as X, useEffect as E } from "react";
|
|
3
3
|
import { useHeroContext as Z } from "./HeroContext.mjs";
|
|
4
|
-
import { V as W, s as l, H as D } from "../../../HeroSubComponents-
|
|
4
|
+
import { V as W, s as l, H as D } from "../../../HeroSubComponents-3hFFfYfM.js";
|
|
5
5
|
import { resolveImageUrl as Y, resolveAltText as A, detectVideoProvider as h } from "../../utils/mediaUtils.mjs";
|
|
6
6
|
import { usePrefersReducedMotion as O } from "../../hooks/usePrefersReducedMotion.mjs";
|
|
7
7
|
const x = {
|
package/package.json
CHANGED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
"use strict";require('./HeroSubComponents.css');const t=require("react/jsx-runtime"),l=require("react"),v=require("./next/utils/mediaUtils.cjs"),f=require("./createLucideIcon-DpotSgUx.cjs"),w=require("./play-CQBnZgNa.cjs");/**
|
|
2
|
-
* @license lucide-react v0.488.0 - ISC
|
|
3
|
-
*
|
|
4
|
-
* This source code is licensed under the ISC license.
|
|
5
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
6
|
-
*/const p=[["rect",{x:"14",y:"4",width:"4",height:"16",rx:"1",key:"zuxfzm"}],["rect",{x:"6",y:"4",width:"4",height:"16",rx:"1",key:"1okwgv"}]],b=f.createLucideIcon("pause",p),g="_hero_1vxwy_1",j="_container_1vxwy_7",C="_heading_1vxwy_15",N="_text_1vxwy_22",k="_eyebrow_1vxwy_37",B="_disclaimer_1vxwy_41",V="_articleDetails_1vxwy_52",I="_articleType_1vxwy_65",E="_articleCategories_1vxwy_79",q="_category_1vxwy_85",z="_number_1vxwy_101",T="_blog_1vxwy_128",H="_overlay_1vxwy_154",R="_tile_1vxwy_213",D="_fullBleed_1vxwy_322",F="_media_1vxwy_349",P="_splitAlt_1vxwy_437",A="_split_1vxwy_437",L="_videoControl_1vxwy_511",S="_videoBackground_1vxwy_559",U="_iframe_1vxwy_560",n={hero:g,container:j,heading:C,text:N,eyebrow:k,disclaimer:B,articleDetails:V,articleType:I,articleCategories:E,category:q,number:z,default:"_default_1vxwy_124",blog:T,overlay:H,tile:R,fullBleed:D,media:F,splitAlt:P,split:A,videoControl:L,videoBackground:S,iframe:U},h=l.memo(function({isPlaying:e,onToggle:i}){return t.jsx("button",{type:"button",title:e?"Pause the video":"Play the video","aria-label":e?"Pause video":"Play video",className:n.videoControl,onClick:i,children:e?t.jsx(b,{size:18,"aria-hidden":!0}):t.jsx(w.Play,{size:18,"aria-hidden":!0})})}),y=l.memo(function({url:e,provider:i,wrapperClassName:c,iframeClassName:s}){const r=v.buildEmbedSrc(e,i);return t.jsx("div",{className:c,children:t.jsx("iframe",{src:r,className:s,allow:"autoplay; fullscreen",allowFullScreen:!0,title:"Embedded video","aria-label":"Background video"})})}),x=l.memo(l.forwardRef(function({src:e,autoPlay:i,posterUrl:c,wrapperClassName:s,videoClassName:r,isPlaying:a,onToggle:u},m){const d=l.useRef(null);return l.useImperativeHandle(m,()=>({play(){var o;(o=d.current)==null||o.play().catch(()=>{})},pause(){var o;(o=d.current)==null||o.pause()}})),l.useEffect(()=>{const o=d.current;o&&(a?o.play().catch(()=>{}):o.pause())},[a]),t.jsxs("div",{className:s,children:[t.jsx(h,{isPlaying:a,onToggle:u}),t.jsx("video",{ref:d,src:e,autoPlay:i,loop:!0,muted:!0,playsInline:!0,poster:c,preload:"metadata",className:r,"aria-label":"Background video"})]})})),$=l.memo(function({url:e,autoPlay:i,posterUrl:c,isPlaying:s,onToggle:r,variant:a}){const u=e.includes("vimeo.com"),m=e.includes("youtube.com")||e.includes("youtu.be"),d=u||m,o=u?"vimeo":"youtube";return a==="inline"?d?t.jsx(y,{url:e,provider:o,wrapperClassName:n.media}):t.jsx(x,{src:e,autoPlay:i,posterUrl:c,wrapperClassName:n.media,isPlaying:s,onToggle:r}):d?t.jsx(y,{url:e,provider:o,wrapperClassName:n.videoBackground,iframeClassName:n.iframe}):t.jsx(x,{src:e,autoPlay:i,posterUrl:c,videoClassName:n.videoBackground,isPlaying:s,onToggle:r})}),Y=l.memo(function({image:e,mode:i,variant:c,imageAdapter:s}){const r=v.resolveImageUrl(e,i,"medium");if(!r)return null;const a=v.resolveAltText(e,i),u=t.jsx("img",{fetchPriority:"high",src:r,alt:a,draggable:!1,style:c==="fill"?{objectFit:"cover",width:"100%",height:"100%"}:{width:"100%",height:"100%"}});return s?t.jsx("div",{className:n.media,children:c==="fill"?s.render({src:r,alt:a,fill:!0,priority:!0,fetchPriority:"high",style:{objectFit:"cover"},draggable:!1,sizes:"(max-width: 767px) 600px, 1200px"}):s.render({src:r,alt:a,width:650,height:750,priority:!0,fetchPriority:"high"})}):t.jsx("div",{className:n.media,children:u})});exports.HeroImage=Y;exports.NativeVideo=x;exports.VideoBlock=$;exports.VideoControl=h;exports.VideoEmbed=y;exports.styles=n;
|