Spaces:
Running
Running
§6 cat gutter nudged right; sandbox output card bottom padding
Browse files- results.js: shift category labels and hairline brackets ~22 px right so
they sit close to their task rows instead of pinned to the svg edge.
- sandbox.css: bump .sb-card__body padding-bottom 0 → 22 px on the
sandbox panel so the output sequence block doesn't kiss the card edge.
Co-authored-by: Cursor <cursoragent@cursor.com>
assets/js/sections/intro.js
CHANGED
|
@@ -253,8 +253,8 @@
|
|
| 253 |
}
|
| 254 |
return d;
|
| 255 |
}
|
| 256 |
-
el("path", { d: pathD(phaseA), fill: "none", stroke: STROKE, "stroke-width":
|
| 257 |
-
el("path", { d: pathD(phaseB), fill: "none", stroke: STROKE, "stroke-width":
|
| 258 |
|
| 259 |
// 3. Letter glyphs themselves (no haloes, since the rung is already
|
| 260 |
// interrupted around each letter). fade tracks fadeForSep so the
|
|
@@ -280,11 +280,10 @@
|
|
| 280 |
const ySpread = 12;
|
| 281 |
const yA0 = yAt(6, phaseA), yB0 = yAt(6, phaseB);
|
| 282 |
const yA1 = yAt(W - 6, phaseA), yB1 = yAt(W - 6, phaseB);
|
| 283 |
-
|
| 284 |
-
text(svg, 6,
|
| 285 |
-
text(svg,
|
| 286 |
-
text(svg, 6,
|
| 287 |
-
text(svg, W - 6, Math.max(yA1, yB1) + ySpread + 2, "5′", endTagOpts);
|
| 288 |
}
|
| 289 |
|
| 290 |
root.querySelectorAll("[data-helix]").forEach(buildHelix);
|
|
|
|
| 253 |
}
|
| 254 |
return d;
|
| 255 |
}
|
| 256 |
+
el("path", { d: pathD(phaseA), fill: "none", stroke: STROKE, "stroke-width": 2, "stroke-linecap": "round" }, svg);
|
| 257 |
+
el("path", { d: pathD(phaseB), fill: "none", stroke: STROKE, "stroke-width": 2, "stroke-linecap": "round" }, svg);
|
| 258 |
|
| 259 |
// 3. Letter glyphs themselves (no haloes, since the rung is already
|
| 260 |
// interrupted around each letter). fade tracks fadeForSep so the
|
|
|
|
| 280 |
const ySpread = 12;
|
| 281 |
const yA0 = yAt(6, phaseA), yB0 = yAt(6, phaseB);
|
| 282 |
const yA1 = yAt(W - 6, phaseA), yB1 = yAt(W - 6, phaseB);
|
| 283 |
+
text(svg, 6, Math.min(yA0, yB0) - ySpread, "5′", { mono: true, size: 9, weight: 500, fill: FAINT });
|
| 284 |
+
text(svg, W - 6, Math.min(yA1, yB1) - ySpread, "3′", { mono: true, size: 9, weight: 500, fill: FAINT });
|
| 285 |
+
text(svg, 6, Math.max(yA0, yB0) + ySpread + 2, "3′", { mono: true, size: 9, weight: 500, fill: FAINT });
|
| 286 |
+
text(svg, W - 6, Math.max(yA1, yB1) + ySpread + 2, "5′", { mono: true, size: 9, weight: 500, fill: FAINT });
|
|
|
|
| 287 |
}
|
| 288 |
|
| 289 |
root.querySelectorAll("[data-helix]").forEach(buildHelix);
|
assets/js/sections/results.js
CHANGED
|
@@ -167,16 +167,22 @@
|
|
| 167 |
// One italic serif label per category, vertically centred on its run
|
| 168 |
// of rows. Pure typographic separator — no boxes, no rules — to keep
|
| 169 |
// the chart calm.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 170 |
groups.forEach(g => {
|
| 171 |
const yTop = rowYs[g.rows[0]];
|
| 172 |
const yBot = rowYs[g.rows[g.rows.length - 1]] + rowH;
|
| 173 |
const yMid = (yTop + yBot) / 2 + 6;
|
| 174 |
-
svg += `<text x="${
|
| 175 |
// Subtle vertical hairline to bracket the category run when it has
|
| 176 |
// more than one row. Skip for solo-row categories (Generative,
|
| 177 |
// Long-context) — a hairline next to a single row reads as noise.
|
| 178 |
if (g.rows.length > 1) {
|
| 179 |
-
svg += `<line x1="${
|
| 180 |
}
|
| 181 |
});
|
| 182 |
|
|
|
|
| 167 |
// One italic serif label per category, vertically centred on its run
|
| 168 |
// of rows. Pure typographic separator — no boxes, no rules — to keep
|
| 169 |
// the chart calm.
|
| 170 |
+
// Category labels and hairlines were sitting flush against the
|
| 171 |
+
// svg's left padding which felt visually adrift from the task
|
| 172 |
+
// labels. Nudging the whole gutter right by ~22 px ties the
|
| 173 |
+
// category brackets to the rows they label without crowding them.
|
| 174 |
+
const catLabelX = padL + 24;
|
| 175 |
+
const catHairlineX = padL + catW - 4;
|
| 176 |
groups.forEach(g => {
|
| 177 |
const yTop = rowYs[g.rows[0]];
|
| 178 |
const yBot = rowYs[g.rows[g.rows.length - 1]] + rowH;
|
| 179 |
const yMid = (yTop + yBot) / 2 + 6;
|
| 180 |
+
svg += `<text x="${catLabelX}" y="${yMid}" font-family="Georgia, serif" font-size="18" font-style="italic" fill="#666" text-anchor="start">${escapeXml(g.cat)}</text>`;
|
| 181 |
// Subtle vertical hairline to bracket the category run when it has
|
| 182 |
// more than one row. Skip for solo-row categories (Generative,
|
| 183 |
// Long-context) — a hairline next to a single row reads as noise.
|
| 184 |
if (g.rows.length > 1) {
|
| 185 |
+
svg += `<line x1="${catHairlineX}" y1="${yTop + 4}" x2="${catHairlineX}" y2="${yBot - 4}" stroke="#d8d4c8" stroke-width="1.5"/>`;
|
| 186 |
}
|
| 187 |
});
|
| 188 |
|
assets/styles/sandbox.css
CHANGED
|
@@ -95,7 +95,7 @@
|
|
| 95 |
color: #1f1f1d;
|
| 96 |
}
|
| 97 |
#panel-sandbox .sb-card__body {
|
| 98 |
-
padding: 16px 20px
|
| 99 |
}
|
| 100 |
#panel-sandbox .sb-examples {
|
| 101 |
display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px;
|
|
|
|
| 95 |
color: #1f1f1d;
|
| 96 |
}
|
| 97 |
#panel-sandbox .sb-card__body {
|
| 98 |
+
padding: 16px 20px 22px;
|
| 99 |
}
|
| 100 |
#panel-sandbox .sb-examples {
|
| 101 |
display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px;
|