Add ICJ108 table style and RTL Typst helpers.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-07-18 13:55:25 +03:30
parent f98054498d
commit 727e038ca7
4 changed files with 76 additions and 8 deletions

View File

@@ -12,6 +12,14 @@
font-style: normal;
}
:root {
--text: #1f2328;
--text2: #57606a;
--stroke: #d0d7de;
--bg: #ffffff;
--fill: #f6f8fa;
}
html {
direction: rtl;
lang: fa;
@@ -24,8 +32,8 @@ body {
max-width: 48rem;
margin: 2rem auto;
padding: 0 1.25rem;
color: #1a1a1a;
background: #fff;
color: var(--text);
background: var(--bg);
}
h1, h2, h3 {
@@ -67,21 +75,43 @@ p.author,
margin: 0.15rem 0 0.5rem 0;
}
/* Match Inco Mixed ICJ108 HTML table chrome */
table {
border-collapse: separate;
border-spacing: 0;
width: 100%;
border-collapse: collapse;
margin: 1rem 0;
font-size: 0.95rem;
border: 1px solid var(--stroke);
border-radius: 8px;
overflow: hidden;
}
th, td {
border: 1px solid #ccc;
padding: 0.4rem 0.6rem;
padding: 0.55rem 0.75rem;
text-align: center;
font-size: 1.05rem;
font-variant-numeric: tabular-nums;
border: none;
}
th {
background: #eee;
thead th {
background: var(--fill);
font-size: 1rem;
color: var(--text2);
border-bottom: 1px solid var(--stroke);
line-height: 1.35;
}
tbody tr + tr td {
border-top: 1px solid var(--stroke);
}
/* Keep compound LTR numerics (e.g. 0.850 ± 0.05) in visual LTR order inside RTL tables */
table [dir="ltr"],
table .ltr {
direction: ltr;
unicode-bidi: isolate;
display: inline-block;
}
code {