@arc-ui/community-components 3.3.0 → 3.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.
Files changed (104) hide show
  1. package/.turbo/turbo-build.log +132 -12
  2. package/CHANGELOG.md +12 -0
  3. package/lib/Accordion/Accordion.mjs +1 -1
  4. package/lib/ActionTile/ActionTile.mjs +9 -9
  5. package/lib/ArticleSidebar/ArticleSidebar.mjs +44 -44
  6. package/lib/Author/Author.mjs +1 -1
  7. package/lib/BannerWithTabs/BannerWithTabs.mjs +6 -6
  8. package/lib/ContentInfoWidget/ContentInfoWidget.mjs +6 -6
  9. package/lib/CopyLead/CopyLead.cjs +18 -8
  10. package/lib/CopyLead/CopyLead.mjs +59 -49
  11. package/lib/DownloadList/DownloadList.mjs +9 -9
  12. package/lib/FAQs/FAQs.mjs +21 -21
  13. package/lib/FeaturePost/FeaturePost.cjs +1 -1
  14. package/lib/FeaturePost/FeaturePost.mjs +53 -53
  15. package/lib/Highlights/Highlights.mjs +19 -19
  16. package/lib/InlineLinkGroup/InlineLinkGroup.mjs +10 -10
  17. package/lib/LinkTile/LinkTile.mjs +5 -5
  18. package/lib/ProductNavigation/ProductNavigation.cjs +1 -1
  19. package/lib/ProductNavigation/ProductNavigation.mjs +17 -17
  20. package/lib/PromoListing/PromoListing.cjs +1 -1
  21. package/lib/PromoListing/PromoListing.mjs +15 -15
  22. package/lib/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.cjs +2 -2
  23. package/lib/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.mjs +8 -8
  24. package/lib/Quote/Quote.mjs +8 -8
  25. package/lib/SectionHeading/SectionHeading.mjs +1 -1
  26. package/lib/Statistics/Statistics.mjs +31 -31
  27. package/lib/Summary/Summary.cjs +1 -1
  28. package/lib/Summary/Summary.mjs +11 -11
  29. package/lib/ThumbnailSignpost/ThumbnailSignpost.mjs +1 -1
  30. package/lib/VideoHeroCard/VideoHeroCard.cjs +76 -0
  31. package/lib/VideoHeroCard/VideoHeroCard.mjs +74 -0
  32. package/lib/VideoPortraitCard/VideoPortraitCard.cjs +22 -0
  33. package/lib/VideoPortraitCard/VideoPortraitCard.mjs +20 -0
  34. package/lib/_shared/cjs/Preview-Dx1kCzJ1.cjs +102 -0
  35. package/lib/_shared/cjs/VideoCardThumbnail-BqYgpk0u.cjs +440 -0
  36. package/lib/_shared/cjs/dash.all.min-BPXzla24.cjs +6 -0
  37. package/lib/_shared/cjs/hls-Ckhp5fVA.cjs +36628 -0
  38. package/lib/_shared/cjs/index-DjiIVIaV.cjs +96 -0
  39. package/lib/_shared/cjs/index-oGP6D6gL.cjs +14826 -0
  40. package/lib/_shared/cjs/{index.es-Dq8bYrbW.cjs → index.es-B0J3cvrY.cjs} +1 -1
  41. package/lib/_shared/cjs/mixin-BFwaXKGB.cjs +1027 -0
  42. package/lib/_shared/cjs/react-CEvhi3LL.cjs +737 -0
  43. package/lib/_shared/cjs/react-CqsEClV0.cjs +466 -0
  44. package/lib/_shared/cjs/react-DE6M3seI.cjs +496 -0
  45. package/lib/_shared/cjs/react-Dri2yjKm.cjs +554 -0
  46. package/lib/_shared/cjs/react-DxToimBj.cjs +4239 -0
  47. package/lib/_shared/cjs/react-JTfV8OSA.cjs +325 -0
  48. package/lib/_shared/cjs/react-caXJFZ8W.cjs +400 -0
  49. package/lib/_shared/cjs/react-fep2ei7j.cjs +727 -0
  50. package/lib/_shared/esm/{Accordion-DrOTh90S.mjs → Accordion-DtU7jbCv.mjs} +15 -15
  51. package/lib/_shared/esm/Author-CJQFrQM9.mjs +27 -0
  52. package/lib/_shared/esm/Preview-CmbKOgEO.mjs +100 -0
  53. package/lib/_shared/esm/{SectionHeading-DZOg_gYi.mjs → SectionHeading-BskdQ2Tt.mjs} +9 -9
  54. package/lib/_shared/esm/{ThumbnailSignpost-DaZByYIH.mjs → ThumbnailSignpost-CBSdQiHw.mjs} +12 -12
  55. package/lib/_shared/esm/VideoCardThumbnail-VfOKmPCv.mjs +437 -0
  56. package/lib/_shared/esm/dash.all.min-CbWI_8dN.mjs +4 -0
  57. package/lib/_shared/esm/hls-AFbJDS9D.mjs +36625 -0
  58. package/lib/_shared/esm/index-CrcIrdjn.mjs +14799 -0
  59. package/lib/_shared/esm/index-DYnuIO1L.mjs +94 -0
  60. package/lib/_shared/esm/{index.es-Bfdys5__.mjs → index.es-DraZ-qKh.mjs} +1 -1
  61. package/lib/_shared/esm/mixin-BGGG8VrM.mjs +1024 -0
  62. package/lib/_shared/esm/react-BGimq-TB.mjs +4237 -0
  63. package/lib/_shared/esm/react-BHT4t_eQ.mjs +494 -0
  64. package/lib/_shared/esm/react-BSd0sGcO.mjs +464 -0
  65. package/lib/_shared/esm/react-CSr43fZV.mjs +552 -0
  66. package/lib/_shared/esm/react-Ca6E7Fr-.mjs +398 -0
  67. package/lib/_shared/esm/react-DG070IvZ.mjs +725 -0
  68. package/lib/_shared/esm/react-DZyqy7W7.mjs +735 -0
  69. package/lib/_shared/esm/react-WW_9iHcl.mjs +323 -0
  70. package/lib/index.cjs +249 -123
  71. package/lib/index.cjs.map +1 -1
  72. package/lib/index.d.cts +55 -2
  73. package/lib/index.d.mts +55 -2
  74. package/lib/index.mjs +248 -124
  75. package/lib/index.mjs.map +1 -1
  76. package/lib/styles.css +1 -1
  77. package/package.json +17 -14
  78. package/rollup.config.js +1 -1
  79. package/src/components/CopyLead/components/MediaContent/MediaContent.tsx +7 -6
  80. package/src/components/CopyLead/templates/Content/Content.tsx +5 -3
  81. package/src/components/CopyLead/templates/Media/Media.tsx +5 -6
  82. package/src/components/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.tsx +2 -0
  83. package/src/components/VideoHeroCard/VideoHeroCard.tsx +63 -0
  84. package/src/components/VideoHeroCard/components/VideoHeroCardContent/VideoHeroCardContent.module.css +32 -0
  85. package/src/components/VideoHeroCard/components/VideoHeroCardContent/VideoHeroCardContent.tsx +97 -0
  86. package/src/components/VideoHeroCard/components/VideoHeroCardContent/index.ts +4 -0
  87. package/src/components/VideoHeroCard/index.ts +1 -0
  88. package/src/components/VideoPortraitCard/VideoPortraitCard.tsx +54 -0
  89. package/src/components/VideoPortraitCard/index.ts +4 -0
  90. package/src/components/index.ts +2 -0
  91. package/src/internal/MultiLineText/MultiLineText.tsx +25 -0
  92. package/src/internal/MultiLineText/index.ts +1 -0
  93. package/src/internal/VideoCardPlayer/VideoCardPlayer.module.css +54 -0
  94. package/src/internal/VideoCardPlayer/VideoCardPlayer.tsx +62 -0
  95. package/src/internal/VideoCardPlayer/components/VideoCardPlayIcon/VideoCardPlayIcon.module.css +41 -0
  96. package/src/internal/VideoCardPlayer/components/VideoCardPlayIcon/VideoCardPlayIcon.tsx +28 -0
  97. package/src/internal/VideoCardPlayer/components/VideoCardPlayIcon/index.ts +1 -0
  98. package/src/internal/VideoCardPlayer/components/VideoCardThumbnail/VideoCardThumbnail.module.css +58 -0
  99. package/src/internal/VideoCardPlayer/components/VideoCardThumbnail/VideoCardThumbnail.tsx +38 -0
  100. package/src/internal/VideoCardPlayer/components/VideoCardThumbnail/index.ts +1 -0
  101. package/src/internal/VideoCardPlayer/index.ts +2 -0
  102. package/src/internal/VideoCardPlayer/types/player-props.ts +6 -0
  103. package/versions.json +1 -1
  104. package/lib/_shared/esm/Author-BVCRPgkl.mjs +0 -27
@@ -0,0 +1,400 @@
1
+ 'use strict';
2
+
3
+ var React = require('react');
4
+ var mixin = require('./mixin-BFwaXKGB.cjs');
5
+ var hls = require('./hls-Ckhp5fVA.cjs');
6
+
7
+ const HlsVideoMixin = (superclass) => {
8
+ return class HlsVideo extends superclass {
9
+ static shadowRootOptions = { ...superclass.shadowRootOptions };
10
+ static getTemplateHTML = (attrs, props = {}) => {
11
+ const { src, ...rest } = attrs;
12
+ return `
13
+ <script type="application/json" id="config">
14
+ ${JSON.stringify(props.config || {})}
15
+ </script>
16
+ ${superclass.getTemplateHTML(rest)}
17
+ `;
18
+ };
19
+ #airplaySourceEl = null;
20
+ #config = null;
21
+ constructor() {
22
+ super();
23
+ this.#upgradeProperty("config");
24
+ }
25
+ get config() {
26
+ return this.#config;
27
+ }
28
+ set config(value) {
29
+ this.#config = value;
30
+ }
31
+ attributeChangedCallback(attrName, oldValue, newValue) {
32
+ if (attrName !== "src") {
33
+ super.attributeChangedCallback(attrName, oldValue, newValue);
34
+ }
35
+ if (attrName === "src" && oldValue != newValue) {
36
+ this.load();
37
+ }
38
+ }
39
+ #destroy() {
40
+ var _a, _b;
41
+ (_a = this.#airplaySourceEl) == null ? void 0 : _a.remove();
42
+ (_b = this.nativeEl) == null ? void 0 : _b.removeEventListener(
43
+ "webkitcurrentplaybacktargetiswirelesschanged",
44
+ this.#toggleHlsLoad
45
+ );
46
+ if (this.api) {
47
+ this.api.detachMedia();
48
+ this.api.destroy();
49
+ this.api = null;
50
+ }
51
+ }
52
+ async load() {
53
+ var _a, _b;
54
+ const isFirstLoad = !this.api;
55
+ this.#destroy();
56
+ if (!this.src) {
57
+ return;
58
+ }
59
+ if (isFirstLoad && !this.#config) {
60
+ this.#config = JSON.parse(((_a = this.shadowRoot.getElementById("config")) == null ? void 0 : _a.textContent) || "{}");
61
+ }
62
+ if (hls.Hls.isSupported()) {
63
+ await Promise.resolve();
64
+ this.api = new hls.Hls({
65
+ // Mimic the media element with an Infinity duration for live streams.
66
+ liveDurationInfinity: true,
67
+ // Disable auto quality level/fragment loading.
68
+ autoStartLoad: false,
69
+ // Custom configuration for hls.js.
70
+ ...this.config
71
+ });
72
+ this.api.loadSource(this.src);
73
+ this.api.attachMedia(this.nativeEl);
74
+ switch (this.nativeEl.preload) {
75
+ case "none": {
76
+ const loadSourceOnPlay = () => this.api.startLoad();
77
+ this.nativeEl.addEventListener("play", loadSourceOnPlay, {
78
+ once: true
79
+ });
80
+ this.api.on(hls.Hls.Events.DESTROYING, () => {
81
+ this.nativeEl.removeEventListener("play", loadSourceOnPlay);
82
+ });
83
+ break;
84
+ }
85
+ case "metadata": {
86
+ const originalLength = this.api.config.maxBufferLength;
87
+ const originalSize = this.api.config.maxBufferSize;
88
+ this.api.config.maxBufferLength = 1;
89
+ this.api.config.maxBufferSize = 1;
90
+ const increaseBufferOnPlay = () => {
91
+ this.api.config.maxBufferLength = originalLength;
92
+ this.api.config.maxBufferSize = originalSize;
93
+ };
94
+ this.nativeEl.addEventListener("play", increaseBufferOnPlay, {
95
+ once: true
96
+ });
97
+ this.api.on(hls.Hls.Events.DESTROYING, () => {
98
+ this.nativeEl.removeEventListener("play", increaseBufferOnPlay);
99
+ });
100
+ this.api.startLoad();
101
+ break;
102
+ }
103
+ default:
104
+ this.api.startLoad();
105
+ }
106
+ if (this.nativeEl.webkitCurrentPlaybackTargetIsWireless) {
107
+ this.api.stopLoad();
108
+ }
109
+ this.nativeEl.addEventListener(
110
+ "webkitcurrentplaybacktargetiswirelesschanged",
111
+ this.#toggleHlsLoad
112
+ );
113
+ this.#airplaySourceEl = document.createElement("source");
114
+ this.#airplaySourceEl.setAttribute("type", "application/x-mpegURL");
115
+ this.#airplaySourceEl.setAttribute("src", this.src);
116
+ this.nativeEl.disableRemotePlayback = false;
117
+ this.nativeEl.append(this.#airplaySourceEl);
118
+ const levelIdMap = /* @__PURE__ */ new WeakMap();
119
+ this.api.on(hls.Hls.Events.MANIFEST_PARSED, (event, data) => {
120
+ if (this.nativeEl.autoplay && this.nativeEl.paused) {
121
+ this.nativeEl.play().catch((err) => {
122
+ console.warn("Autoplay failed:", err);
123
+ });
124
+ }
125
+ removeAllMediaTracks();
126
+ let videoTrack = this.videoTracks.getTrackById("main");
127
+ if (!videoTrack) {
128
+ videoTrack = this.addVideoTrack("main");
129
+ videoTrack.id = "main";
130
+ videoTrack.selected = true;
131
+ }
132
+ for (const [id, level] of data.levels.entries()) {
133
+ const videoRendition = videoTrack.addRendition(
134
+ level.url[0],
135
+ level.width,
136
+ level.height,
137
+ level.videoCodec,
138
+ level.bitrate
139
+ );
140
+ levelIdMap.set(level, `${id}`);
141
+ videoRendition.id = `${id}`;
142
+ }
143
+ for (let [id, a] of data.audioTracks.entries()) {
144
+ const kind = a.default ? "main" : "alternative";
145
+ const audioTrack = this.addAudioTrack(kind, a.name, a.lang);
146
+ audioTrack.id = `${id}`;
147
+ if (a.default) {
148
+ audioTrack.enabled = true;
149
+ }
150
+ }
151
+ });
152
+ this.audioTracks.addEventListener("change", () => {
153
+ var _a2;
154
+ const audioTrackId = +((_a2 = [...this.audioTracks].find((t) => t.enabled)) == null ? void 0 : _a2.id);
155
+ const availableIds = this.api.audioTracks.map((t) => t.id);
156
+ if (audioTrackId != this.api.audioTrack && availableIds.includes(audioTrackId)) {
157
+ this.api.audioTrack = audioTrackId;
158
+ }
159
+ });
160
+ this.api.on(hls.Hls.Events.LEVELS_UPDATED, (event, data) => {
161
+ const videoTrack = this.videoTracks[this.videoTracks.selectedIndex ?? 0];
162
+ if (!videoTrack) return;
163
+ const levelIds = data.levels.map((l) => levelIdMap.get(l));
164
+ for (const rendition of this.videoRenditions) {
165
+ if (rendition.id && !levelIds.includes(rendition.id)) {
166
+ videoTrack.removeRendition(rendition);
167
+ }
168
+ }
169
+ });
170
+ let lastFailedLevel = null;
171
+ this.api.on(hls.Hls.Events.ERROR, (event, data) => {
172
+ if (data.type === hls.Hls.ErrorTypes.NETWORK_ERROR && data.details === hls.Hls.ErrorDetails.FRAG_LOAD_ERROR) {
173
+ lastFailedLevel = data.frag.level;
174
+ }
175
+ });
176
+ this.api.on(hls.Hls.Events.LEVEL_SWITCHED, (event, data) => {
177
+ const newLevel = data.level;
178
+ if (lastFailedLevel !== null && newLevel < lastFailedLevel) {
179
+ console.warn(
180
+ `\u26A0\uFE0F hls.js downgraded quality from level ${lastFailedLevel} to ${newLevel} due to fragment load failure.`
181
+ );
182
+ this.videoRenditions.selectedIndex = newLevel;
183
+ lastFailedLevel = null;
184
+ }
185
+ });
186
+ const switchRendition = (event) => {
187
+ const level = event.target.selectedIndex;
188
+ if (level != this.api.nextLevel) {
189
+ this.api.nextLevel = level;
190
+ }
191
+ };
192
+ (_b = this.videoRenditions) == null ? void 0 : _b.addEventListener("change", switchRendition);
193
+ const removeAllMediaTracks = () => {
194
+ for (const videoTrack of this.videoTracks) {
195
+ this.removeVideoTrack(videoTrack);
196
+ }
197
+ for (const audioTrack of this.audioTracks) {
198
+ this.removeAudioTrack(audioTrack);
199
+ }
200
+ };
201
+ this.api.once(hls.Hls.Events.DESTROYING, removeAllMediaTracks);
202
+ return;
203
+ }
204
+ await Promise.resolve();
205
+ if (this.nativeEl.canPlayType("application/vnd.apple.mpegurl")) {
206
+ this.nativeEl.src = this.src;
207
+ }
208
+ }
209
+ #toggleHlsLoad = () => {
210
+ var _a, _b, _c;
211
+ if ((_a = this.nativeEl) == null ? void 0 : _a.webkitCurrentPlaybackTargetIsWireless) {
212
+ (_b = this.api) == null ? void 0 : _b.stopLoad();
213
+ } else {
214
+ (_c = this.api) == null ? void 0 : _c.startLoad();
215
+ }
216
+ };
217
+ // This is a pattern to update property values that are set before
218
+ // the custom element is upgraded.
219
+ // https://web.dev/custom-elements-best-practices/#make-properties-lazy
220
+ #upgradeProperty(prop) {
221
+ if (Object.prototype.hasOwnProperty.call(this, prop)) {
222
+ const value = this[prop];
223
+ delete this[prop];
224
+ this[prop] = value;
225
+ }
226
+ }
227
+ };
228
+ };
229
+ const HlsVideoElement = HlsVideoMixin(mixin.MediaTracksMixin(mixin.CustomVideoElement));
230
+ if (globalThis.customElements && !globalThis.customElements.get("hls-video")) {
231
+ globalThis.customElements.define("hls-video", HlsVideoElement);
232
+ }
233
+ var hls_video_element_default = HlsVideoElement;
234
+
235
+ // ../../node_modules/ce-la-react/dist/ce-la-react.js
236
+ var reservedReactProps = /* @__PURE__ */ new Set([
237
+ "style",
238
+ "children",
239
+ "ref",
240
+ "key",
241
+ "suppressContentEditableWarning",
242
+ "suppressHydrationWarning",
243
+ "dangerouslySetInnerHTML"
244
+ ]);
245
+ var reactPropToAttrNameMap = {
246
+ className: "class",
247
+ htmlFor: "for"
248
+ };
249
+ function defaultToAttributeName(propName) {
250
+ return propName.toLowerCase();
251
+ }
252
+ function defaultToAttributeValue(propValue) {
253
+ if (typeof propValue === "boolean") return propValue ? "" : void 0;
254
+ if (typeof propValue === "function") return void 0;
255
+ if (typeof propValue === "object" && propValue !== null) return void 0;
256
+ return propValue;
257
+ }
258
+ function createComponent({
259
+ react: React2,
260
+ tagName,
261
+ elementClass,
262
+ events,
263
+ displayName,
264
+ defaultProps,
265
+ toAttributeName = defaultToAttributeName,
266
+ toAttributeValue = defaultToAttributeValue
267
+ }) {
268
+ const IS_REACT_19_OR_NEWER = Number.parseInt(React2.version) >= 19;
269
+ const ReactComponent = React2.forwardRef((props, ref) => {
270
+ var _a, _b;
271
+ const elementRef = React2.useRef(null);
272
+ const prevElemPropsRef = React2.useRef(/* @__PURE__ */ new Map());
273
+ const eventProps = {};
274
+ const attrs = {};
275
+ const reactProps = {};
276
+ const elementProps = {};
277
+ for (const [k, v] of Object.entries(props)) {
278
+ if (reservedReactProps.has(k)) {
279
+ reactProps[k] = v;
280
+ continue;
281
+ }
282
+ const attrName = toAttributeName(reactPropToAttrNameMap[k] ?? k);
283
+ if (elementClass.prototype && k in elementClass.prototype && !(k in (((_a = globalThis.HTMLElement) == null ? void 0 : _a.prototype) ?? {})) && !((_b = elementClass.observedAttributes) == null ? void 0 : _b.some((attr) => attr === attrName))) {
284
+ elementProps[k] = v;
285
+ continue;
286
+ }
287
+ if (k.startsWith("on")) {
288
+ eventProps[k] = v;
289
+ continue;
290
+ }
291
+ const attrValue = toAttributeValue(v);
292
+ if (attrName && attrValue != null) {
293
+ attrs[attrName] = String(attrValue);
294
+ if (!IS_REACT_19_OR_NEWER) {
295
+ reactProps[attrName] = attrValue;
296
+ }
297
+ }
298
+ if (attrName && IS_REACT_19_OR_NEWER) {
299
+ const attrValueFromDefault = defaultToAttributeValue(v);
300
+ if (attrValue !== attrValueFromDefault) {
301
+ reactProps[attrName] = attrValue;
302
+ } else {
303
+ reactProps[attrName] = v;
304
+ }
305
+ }
306
+ }
307
+ if (typeof window !== "undefined") {
308
+ for (const propName in eventProps) {
309
+ const callback = eventProps[propName];
310
+ const useCapture = propName.endsWith("Capture");
311
+ const eventName = ((events == null ? void 0 : events[propName]) ?? propName.slice(2).toLowerCase()).slice(
312
+ 0,
313
+ useCapture ? -7 : void 0
314
+ );
315
+ React2.useLayoutEffect(() => {
316
+ const eventTarget = elementRef == null ? void 0 : elementRef.current;
317
+ if (!eventTarget || typeof callback !== "function") return;
318
+ eventTarget.addEventListener(eventName, callback, useCapture);
319
+ return () => {
320
+ eventTarget.removeEventListener(eventName, callback, useCapture);
321
+ };
322
+ }, [elementRef == null ? void 0 : elementRef.current, callback]);
323
+ }
324
+ React2.useLayoutEffect(() => {
325
+ if (elementRef.current === null) return;
326
+ const newElemProps = /* @__PURE__ */ new Map();
327
+ for (const key in elementProps) {
328
+ setProperty(elementRef.current, key, elementProps[key]);
329
+ prevElemPropsRef.current.delete(key);
330
+ newElemProps.set(key, elementProps[key]);
331
+ }
332
+ for (const [key, _value] of prevElemPropsRef.current) {
333
+ setProperty(elementRef.current, key, void 0);
334
+ }
335
+ prevElemPropsRef.current = newElemProps;
336
+ });
337
+ }
338
+ if (typeof window === "undefined" && (elementClass == null ? void 0 : elementClass.getTemplateHTML) && (elementClass == null ? void 0 : elementClass.shadowRootOptions)) {
339
+ const { mode, delegatesFocus } = elementClass.shadowRootOptions;
340
+ const templateShadowRoot = React2.createElement("template", {
341
+ shadowrootmode: mode,
342
+ shadowrootdelegatesfocus: delegatesFocus,
343
+ dangerouslySetInnerHTML: {
344
+ __html: elementClass.getTemplateHTML(attrs, props)
345
+ },
346
+ key: "ce-la-react-ssr-template-shadow-root"
347
+ });
348
+ reactProps.children = [templateShadowRoot, reactProps.children];
349
+ }
350
+ return React2.createElement(tagName, {
351
+ ...defaultProps,
352
+ ...reactProps,
353
+ ref: React2.useCallback(
354
+ (node) => {
355
+ elementRef.current = node;
356
+ if (typeof ref === "function") {
357
+ ref(node);
358
+ } else if (ref !== null) {
359
+ ref.current = node;
360
+ }
361
+ },
362
+ [ref]
363
+ )
364
+ }, reactProps.children);
365
+ });
366
+ ReactComponent.displayName = displayName ?? elementClass.name;
367
+ return ReactComponent;
368
+ }
369
+ function setProperty(node, name, value) {
370
+ var _a;
371
+ node[name] = value;
372
+ if (value == null && name in (((_a = globalThis.HTMLElement) == null ? void 0 : _a.prototype) ?? {})) {
373
+ node.removeAttribute(name);
374
+ }
375
+ }
376
+
377
+ // dist/react.ts
378
+ var react_default = createComponent({
379
+ react: React,
380
+ tagName: "hls-video",
381
+ elementClass: hls_video_element_default,
382
+ toAttributeName(propName) {
383
+ if (propName === "muted") return "";
384
+ if (propName === "defaultMuted") return "muted";
385
+ return defaultToAttributeName(propName);
386
+ }
387
+ });
388
+ /*! Bundled license information:
389
+
390
+ ce-la-react/dist/ce-la-react.js:
391
+ (**
392
+ * @license
393
+ * Copyright 2018 Google LLC
394
+ * SPDX-License-Identifier: BSD-3-Clause
395
+ *
396
+ * Modified version of `@lit/react` for vanilla custom elements with support for SSR.
397
+ *)
398
+ */
399
+
400
+ exports.default = react_default;