Fix preview.html to native 320x240 without internal scale.
Card host now scales the iframe; remove broken transform that clipped UI to the corner. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -5,10 +5,10 @@
|
||||
<title>POMO</title>
|
||||
<style>
|
||||
*{box-sizing:border-box;margin:0;padding:0}
|
||||
html,body{width:100%;height:100%;overflow:hidden;background:#000}
|
||||
.bezel{width:100%;height:100%;display:grid;place-items:center;background:#1a1408}
|
||||
html,body{width:320px;height:240px;overflow:hidden;background:#000;margin:0}
|
||||
.bezel{width:320px;height:240px;background:#1a1408}
|
||||
.screen{width:320px;height:240px;background:#0A1016;color:#EAF0F6;font:12px/1.2 system-ui,sans-serif;
|
||||
position:relative;overflow:hidden;transform-origin:center;transform:scale(var(--s,1))}
|
||||
position:relative;overflow:hidden;}
|
||||
.title{position:absolute;left:12px;top:4px;color:#E85D4C;font-size:20px;font-weight:700}
|
||||
.chip{position:absolute;right:12px;top:8px;color:#7A8B9C}
|
||||
.pm{position:absolute;left:12px;top:32px;width:40px;height:44px;border:0;border-radius:8px;background:#243140;color:#EAF0F6;font-size:18px}
|
||||
@@ -50,10 +50,6 @@
|
||||
<div class="audio">Speaker OFF</div>
|
||||
<div class="acts"><button class="start" type="button">START</button><button class="reset" type="button">RESET</button></div>
|
||||
</div></div>
|
||||
<script>
|
||||
(function(){function fit(){var s=document.getElementById('s');var r=s.parentElement.getBoundingClientRect();
|
||||
s.style.setProperty('--s',Math.min(r.width/320,r.height/240));}
|
||||
fit();addEventListener('resize',fit);})();
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user