Restore point before Stufe 3 (central resolver-service refactoring). Includes this session's work: - Success Story (usecase) rebuild: new fields/tabs, UsecaseSerializer, thin List/Show renderers, MM relations, inline content elements. - vitec_columns content block (two-column layout with per-item content) incl. unified header section; special-cased JSON resolution. - Container per-column flex (items[].config align/justify) + gap on parent. - Unified header section across CEs/plugins/containers; header fields in JSON. - ISO-style architecture spec: Documentation/Headless-JSON-Architecture.md. - Cleanup: removed local scratch + verified .bak backups. - Fixes: B-6 (undefined thumbnail variable in Downloadcardcollection image resolver), B-7 (unsatisfiable legacy CType OR branch in Downloadcard/Datasheets). Rollback: git reset --hard snapshot-2026-07-09-pre-stufe3 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 line
2.5 KiB
JavaScript
1 line
2.5 KiB
JavaScript
import{C as e,D as t,Q as n,Z as r,c as i,d as a,k as o,n as s}from"./index-7LYai_r-.js";var c=n(),l=r();function u(){return(0,l.jsxs)(`svg`,{viewBox:`0 0 64 64`,width:`72`,height:`72`,xmlns:`http://www.w3.org/2000/svg`,"aria-hidden":`true`,children:[(0,l.jsx)(`circle`,{cx:`32`,cy:`32`,r:`32`,fill:`rgba(var(--vitec-black), 0.55)`}),(0,l.jsx)(`polygon`,{points:`26,18 50,32 26,46`,fill:`rgba(var(--vitec-white), 1)`})]})}function d({element:n,className:r,nested:d,devInfoTags:f,uid:p,spaceBefore:m,spaceAfter:h}){let g=i(n),_=a(n),v=n.data?.youtube_code,y=!!n.data?.hide_controls,b=n.data?.poster?.[0]?.publicUrl,x=(n.data?.custom_video)?.[0]?.publicUrl,S=n.appearance?.frameClass?.split(`,`).map(e=>e.trim()).includes(`vitec-full-width`)??!1,[C,w]=(0,c.useState)(!1),T=b??(v?`https://img.youtube.com/vi/${v}/maxresdefault.jpg`:void 0),E=v?`https://www.youtube-nocookie.com/embed/${v}?controls=${y?`0`:`1`}&autoplay=${C?`1`:`0`}&rel=0&modestbranding=1`:void 0,D=y&&!C,O=!!(E||x);return(0,l.jsx)(s,{className:r,devInfoTags:f,fullWidth:S,nested:d,uid:p,spaceBefore:m,spaceAfter:h,children:(0,l.jsx)(`div`,{className:`vitec_video__inner`,children:(0,l.jsxs)(e,{spacing:2,children:[(g||_)&&(0,l.jsxs)(e,{spacing:.5,children:[g&&(0,l.jsx)(o,{variant:`h4`,children:g}),_&&(0,l.jsx)(o,{variant:`subtitle1`,color:`text.secondary`,children:_})]}),D&&O&&T&&(0,l.jsxs)(t,{className:`vitec_video__poster`,onClick:()=>w(!0),sx:{position:`relative`,borderRadius:2,overflow:`hidden`,cursor:`pointer`,"&:hover .vitec_video__play-btn":{transform:`scale(1.1)`}},children:[(0,l.jsx)(t,{component:`img`,src:T,alt:g??`Video`,sx:{width:`100%`,height:`auto`,display:`block`}}),(0,l.jsx)(t,{className:`vitec_video__play-btn`,sx:{position:`absolute`,inset:0,display:`flex`,alignItems:`center`,justifyContent:`center`,transition:`transform 0.15s ease`},children:(0,l.jsx)(u,{})})]}),D&&!O&&T&&(0,l.jsx)(t,{component:`img`,src:T,alt:g??`Video placeholder`,sx:{width:`100%`,borderRadius:2,display:`block`}}),(!y||C)&&E&&(0,l.jsx)(t,{className:`vitec_video__embed`,sx:{position:`relative`,paddingTop:`56.25%`,borderRadius:2,overflow:`hidden`},children:(0,l.jsx)(t,{component:`iframe`,src:E,title:g??`Video`,allow:`accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture`,allowFullScreen:!0,sx:{position:`absolute`,top:0,left:0,width:`100%`,height:`100%`,border:`none`}})}),!E&&x&&(!y||C)&&(0,l.jsx)(t,{component:`video`,src:x,poster:b,controls:!y,autoPlay:C,sx:{width:`100%`,borderRadius:2,display:`block`}})]})})})}export{d as VitecVideo}; |