@stackshift-ui/youtube-video 6.0.5 → 6.0.6
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/chunk-LHKILQPY.mjs +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +2 -0
- package/dist/index.mjs +2 -0
- package/dist/youtube-video.d.ts +9 -0
- package/dist/youtube-video.js +1 -0
- package/dist/youtube-video.mjs +1 -0
- package/package.json +6 -6
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{DefaultComponent as l,useStackShiftUIComponents as n}from"@stackshift-ui/system";import{jsx as o}from"react/jsx-runtime";var t="YoutubeVideo",m=({videoLinkId:e,title:a,children:p,className:d,as:s,...r})=>{let{[t]:i=l}=n();return o(i,{as:s,className:"aspect-video",...r,"data-testid":t,children:o("iframe",{"aria-label":"Show Video Frame",className:"w-full h-full rounded-lg",src:`https://www.youtube.com/embed/${e}`,srcDoc:`<style>*{padding:0;margin:0;overflow:hidden;border-radius:8px}html,body{height:100%}img,span{position:absolute;width:100%;top:0;bottom:0;margin:auto}span{height:1.5em;text-align:center;font:48px/1.5 sans-serif;color:white;text-shadow:0 0 0.5em black}</style><a href=${`https://www.youtube.com/embed/${e}`}><img src=${`https://i.ytimg.com/vi_webp/${e}/maxresdefault.webp`} alt=${a} loading="lazy" /><span>\u25B6</span></a>`,frameBorder:"0",loading:"lazy",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture"})})};m.displayName=t;export{m as a};
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./youtube-video";
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
"use strict";var i=Object.defineProperty;var c=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var f=Object.prototype.hasOwnProperty;var h=(e,t)=>{for(var a in t)i(e,a,{get:t[a],enumerable:!0})},b=(e,t,a,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of u(t))!f.call(e,o)&&o!==a&&i(e,o,{get:()=>t[o],enumerable:!(r=c(t,o))||r.enumerable});return e};var g=e=>b(i({},"__esModule",{value:!0}),e);var y={};h(y,{YoutubeVideo:()=>m});module.exports=g(y);var s=require("@stackshift-ui/system"),n=require("react/jsx-runtime"),l="YoutubeVideo",m=({videoLinkId:e,title:t,children:a,className:r,as:o,...p})=>{let{[l]:d=s.DefaultComponent}=(0,s.useStackShiftUIComponents)();return(0,n.jsx)(d,{as:o,className:"aspect-video",...p,"data-testid":l,children:(0,n.jsx)("iframe",{"aria-label":"Show Video Frame",className:"w-full h-full rounded-lg",src:`https://www.youtube.com/embed/${e}`,srcDoc:`<style>*{padding:0;margin:0;overflow:hidden;border-radius:8px}html,body{height:100%}img,span{position:absolute;width:100%;top:0;bottom:0;margin:auto}span{height:1.5em;text-align:center;font:48px/1.5 sans-serif;color:white;text-shadow:0 0 0.5em black}</style><a href=${`https://www.youtube.com/embed/${e}`}><img src=${`https://i.ytimg.com/vi_webp/${e}/maxresdefault.webp`} alt=${t} loading="lazy" /><span>\u25B6</span></a>`,frameBorder:"0",loading:"lazy",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture"})})};m.displayName=l;0&&(module.exports={YoutubeVideo});
|
package/dist/index.mjs
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ElementType, HTMLProps, ReactNode } from "react";
|
|
2
|
+
export interface YoutubeVideoProps extends Omit<HTMLProps<HTMLElement>, "as"> {
|
|
3
|
+
videoLinkId?: string;
|
|
4
|
+
title?: string;
|
|
5
|
+
children?: ReactNode;
|
|
6
|
+
className?: string;
|
|
7
|
+
as?: ElementType;
|
|
8
|
+
}
|
|
9
|
+
export declare const YoutubeVideo: React.FC<YoutubeVideoProps>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";var i=Object.defineProperty;var c=Object.getOwnPropertyDescriptor;var u=Object.getOwnPropertyNames;var h=Object.prototype.hasOwnProperty;var f=(e,t)=>{for(var a in t)i(e,a,{get:t[a],enumerable:!0})},b=(e,t,a,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of u(t))!h.call(e,o)&&o!==a&&i(e,o,{get:()=>t[o],enumerable:!(r=c(t,o))||r.enumerable});return e};var g=e=>b(i({},"__esModule",{value:!0}),e);var y={};f(y,{YoutubeVideo:()=>m});module.exports=g(y);var s=require("@stackshift-ui/system"),n=require("react/jsx-runtime"),l="YoutubeVideo",m=({videoLinkId:e,title:t,children:a,className:r,as:o,...p})=>{let{[l]:d=s.DefaultComponent}=(0,s.useStackShiftUIComponents)();return(0,n.jsx)(d,{as:o,className:"aspect-video",...p,"data-testid":l,children:(0,n.jsx)("iframe",{"aria-label":"Show Video Frame",className:"w-full h-full rounded-lg",src:`https://www.youtube.com/embed/${e}`,srcDoc:`<style>*{padding:0;margin:0;overflow:hidden;border-radius:8px}html,body{height:100%}img,span{position:absolute;width:100%;top:0;bottom:0;margin:auto}span{height:1.5em;text-align:center;font:48px/1.5 sans-serif;color:white;text-shadow:0 0 0.5em black}</style><a href=${`https://www.youtube.com/embed/${e}`}><img src=${`https://i.ytimg.com/vi_webp/${e}/maxresdefault.webp`} alt=${t} loading="lazy" /><span>\u25B6</span></a>`,frameBorder:"0",loading:"lazy",allow:"accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture"})})};m.displayName=l;0&&(module.exports={YoutubeVideo});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a}from"./chunk-LHKILQPY.mjs";export{a as YoutubeVideo};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stackshift-ui/youtube-video",
|
|
3
3
|
"description": "",
|
|
4
|
-
"version": "6.0.
|
|
4
|
+
"version": "6.0.6",
|
|
5
5
|
"private": false,
|
|
6
6
|
"sideEffects": false,
|
|
7
7
|
"main": "./dist/index.js",
|
|
@@ -29,19 +29,19 @@
|
|
|
29
29
|
"typescript": "^5.6.2",
|
|
30
30
|
"vite-tsconfig-paths": "^5.0.1",
|
|
31
31
|
"vitest": "^2.1.1",
|
|
32
|
-
"@stackshift-ui/eslint-config": "6.0.
|
|
33
|
-
"@stackshift-ui/typescript-config": "6.0.
|
|
32
|
+
"@stackshift-ui/eslint-config": "6.0.5",
|
|
33
|
+
"@stackshift-ui/typescript-config": "6.0.5"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@stackshift-ui/scripts": "6.0.
|
|
37
|
-
"@stackshift-ui/system": "6.0.
|
|
36
|
+
"@stackshift-ui/scripts": "6.0.5",
|
|
37
|
+
"@stackshift-ui/system": "6.0.6"
|
|
38
38
|
},
|
|
39
39
|
"peerDependencies": {
|
|
40
40
|
"@types/react": "16.8 - 19",
|
|
41
41
|
"next": "10 - 14",
|
|
42
42
|
"react": "16.8 - 19",
|
|
43
43
|
"react-dom": "16.8 - 19",
|
|
44
|
-
"@stackshift-ui/system": ">=6.0.
|
|
44
|
+
"@stackshift-ui/system": ">=6.0.6"
|
|
45
45
|
},
|
|
46
46
|
"peerDependenciesMeta": {
|
|
47
47
|
"next": {
|