fix: update preview styles

This commit is contained in:
2026-08-30 22:40:32 +05:00
parent 86b1c813e7
commit 6c8f7b2d8b
4 changed files with 56 additions and 25 deletions
+4 -3
View File
@@ -9,17 +9,18 @@
let { settings, preview }: Props = $props();
</script>
<div class="ws">
<div class="page-grid">
<section class="ws-settings">{@render settings()}</section>
{@render preview()}
</div>
<style>
.ws {
.page-grid {
display: grid;
grid-template-columns: minmax(0, 1.05fr) minmax(520px, 0.95fr);
align-items: start;
gap: 56px;
width: 100%;
max-width: none;
margin: auto;
padding: 60px clamp(24px, 4vw, 72px) 72px;
@@ -28,7 +29,7 @@
min-width: 0;
}
@media (max-width: 800px) {
.ws {
.page-grid {
grid-template-columns: 1fr;
gap: var(--ws-gap-mobile);
padding: 36px 16px 48px;
@@ -15,8 +15,15 @@
<style>
.preview-stack {
display: grid;
grid-template-columns: 1fr;
grid-template-columns: 1fr 1fr;
gap: 12px;
width: 100%;
min-width: 0;
display: grid;
}
@media (max-width: 1100px) {
.preview-stack {
grid-template-columns: repeat(3, minmax(220px, 1fr));
}
}
</style>
+30 -12
View File
@@ -20,33 +20,51 @@
<style>
.preview-tile {
display: flex;
flex-direction: column;
gap: 0.3rem;
width: 100%;
min-width: 0;
overflow: hidden;
border: 1px solid var(--line);
border-radius: var(--radius);
padding: 0.4rem;
background: var(--panel);
background: var(--background);
}
.tile-canvas {
border-radius: var(--radius);
width: 100%;
min-width: 0;
min-height: 260px;
min-height: clamp(300px, 22vw, 430px);
overflow: hidden;
min-height: 120px;
aspect-ratio: 1.35;
background-color: #e4e8eb;
background-image:
linear-gradient(45deg, #d2d8dc 25%, #0000 25%),
linear-gradient(-45deg, #d2d8dc 25%, #0000 25%),
linear-gradient(45deg, #0000 75%, #d2d8dc 75%),
linear-gradient(-45deg, #0000 75%, #d2d8dc 75%);
background-position:
0 0,
0 7px,
7px -7px,
-7px 0;
background-size: 14px 14px;
place-items: center;
padding: 16px;
display: grid;
}
.tile-label {
display: flex;
align-items: baseline;
justify-content: space-between;
gap: 0.5rem;
gap: 8px;
padding: 8px;
border-top: 1px solid var(--line);
font: 9px var(--font-mono);
color: var(--blue);
}
.tile-label span {
font: 10px var(--font-mono);
letter-spacing: 0.08em;
text-transform: uppercase;
color: var(--blue);
}
.tile-label b {
font: 400 10px var(--font-mono);
color: var(--muted);
text-align: right;
}
</style>