oficina / equipo Public

Clone
git clone https://amadan.net/oficina/equipo

Plain git — no account needed to clone.

Download

Download this file

1package equipo
2
3// The fixture deliberately exercises child navigations inside the real wrapper.
4// These labels are test content, never product copy.
5const previewFramesFixture = `<!doctype html><meta name="viewport" content="width=device-width"><style>body{font:18px system-ui;padding:16px;background:#f6faf7;color:#173b26}iframe{display:block;border:1px solid #aac6b3;width:100%;height:64px;margin:12px 0}h1{font-size:24px}</style><h1>Preview frame checks</h1><p id="status">Loading frames</p><iframe id="srcdoc" srcdoc="<p>srcdoc frame loaded</p>"></iframe><iframe id="blob"></iframe><iframe id="data" src="data:text/html,%3Cp%3Edata%20frame%20loaded%3C/p%3E"></iframe><iframe id="blank" src="about:blank"></iframe><script>
6const blob = URL.createObjectURL(new Blob(['<p>blob frame loaded</p>'], {type:'text/html'}));
7document.querySelector('#blob').src = blob;
8window.addEventListener('load',()=>{
9 document.querySelector('#blank').contentDocument.body.textContent='about:blank frame loaded';
10 const deadline=performance.now()+5000;
11 const check=()=>{
12 const ok = document.querySelector('#srcdoc').contentDocument?.body?.textContent.includes('srcdoc frame loaded') && document.querySelector('#blob').contentDocument?.body?.textContent.includes('blob frame loaded');
13 if(!ok && performance.now()<deadline){setTimeout(check,25);return}
14 document.querySelector('#status').textContent=ok?'srcdoc and blob verified':'Frame check failed';
15 fetch('/frames-result?ok='+Boolean(ok));
16 };
17 check();
18});</script>`
19