@open-press/cli 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +58 -0
- package/dist/cli.js +365 -0
- package/package.json +57 -0
- package/template/core/.turbo/turbo-test.log +341 -0
- package/template/core/CHANGELOG.md +11 -0
- package/template/core/README.md +36 -0
- package/template/core/engine/chrome-pdf.d.mts +34 -0
- package/template/core/engine/chrome-pdf.mjs +344 -0
- package/template/core/engine/cli.mjs +93 -0
- package/template/core/engine/commands/_shared.mjs +170 -0
- package/template/core/engine/commands/deploy.mjs +31 -0
- package/template/core/engine/commands/dev.mjs +26 -0
- package/template/core/engine/commands/export.mjs +8 -0
- package/template/core/engine/commands/init.mjs +24 -0
- package/template/core/engine/commands/inspect.mjs +35 -0
- package/template/core/engine/commands/migrate-to-react.mjs +27 -0
- package/template/core/engine/commands/pdf.mjs +26 -0
- package/template/core/engine/commands/preview.mjs +26 -0
- package/template/core/engine/commands/render.mjs +17 -0
- package/template/core/engine/commands/replace.mjs +41 -0
- package/template/core/engine/commands/search.mjs +33 -0
- package/template/core/engine/commands/typecheck.mjs +5 -0
- package/template/core/engine/commands/validate.mjs +17 -0
- package/template/core/engine/config.d.mts +40 -0
- package/template/core/engine/config.mjs +160 -0
- package/template/core/engine/deploy-sync.mjs +15 -0
- package/template/core/engine/document-export.mjs +15 -0
- package/template/core/engine/file-utils.mjs +106 -0
- package/template/core/engine/fonts.mjs +62 -0
- package/template/core/engine/init.mjs +90 -0
- package/template/core/engine/inspection.mjs +348 -0
- package/template/core/engine/issue-report.mjs +44 -0
- package/template/core/engine/katex-assets.mjs +45 -0
- package/template/core/engine/page-block.mjs +30 -0
- package/template/core/engine/page-renderer.mjs +217 -0
- package/template/core/engine/pdf-media.mjs +45 -0
- package/template/core/engine/public-assets.mjs +19 -0
- package/template/core/engine/react/chapter-css.mjs +53 -0
- package/template/core/engine/react/comment-endpoint.d.mts +11 -0
- package/template/core/engine/react/comment-endpoint.mjs +128 -0
- package/template/core/engine/react/comment-marker.mjs +306 -0
- package/template/core/engine/react/document-entry.mjs +253 -0
- package/template/core/engine/react/document-export.mjs +392 -0
- package/template/core/engine/react/mdx-compile.mjs +295 -0
- package/template/core/engine/react/measurement-css.mjs +44 -0
- package/template/core/engine/react/migrate-to-react.mjs +355 -0
- package/template/core/engine/react/pagination-constants.mjs +3 -0
- package/template/core/engine/react/pagination.mjs +121 -0
- package/template/core/engine/react/project-asset-endpoint.d.mts +10 -0
- package/template/core/engine/react/project-asset-endpoint.mjs +379 -0
- package/template/core/engine/react/workspace-discovery.mjs +156 -0
- package/template/core/engine/source-text-tools.mjs +280 -0
- package/template/core/engine/source-workspace.mjs +76 -0
- package/template/core/engine/static-server.mjs +493 -0
- package/template/core/engine/validation.mjs +172 -0
- package/template/core/index.html +13 -0
- package/template/core/openpress.config.mjs +12 -0
- package/template/core/package.json +86 -0
- package/template/core/src/main.tsx +16 -0
- package/template/core/src/openpress/App.tsx +127 -0
- package/template/core/src/openpress/composerMentions.ts +188 -0
- package/template/core/src/openpress/core/basePages.tsx +87 -0
- package/template/core/src/openpress/core/index.tsx +20 -0
- package/template/core/src/openpress/core/types.ts +71 -0
- package/template/core/src/openpress/frameScheduler.ts +32 -0
- package/template/core/src/openpress/indexes.ts +329 -0
- package/template/core/src/openpress/inspector.ts +282 -0
- package/template/core/src/openpress/pageRoute.ts +21 -0
- package/template/core/src/openpress/pagination.ts +845 -0
- package/template/core/src/openpress/projectIdentity.ts +15 -0
- package/template/core/src/openpress/projectSources.ts +24 -0
- package/template/core/src/openpress/projectWorkspace.tsx +919 -0
- package/template/core/src/openpress/publicPage.tsx +469 -0
- package/template/core/src/openpress/reactDocumentMetadata.ts +41 -0
- package/template/core/src/openpress/readerPageRegistry.ts +41 -0
- package/template/core/src/openpress/readerRuntime.ts +230 -0
- package/template/core/src/openpress/readerScroll.ts +92 -0
- package/template/core/src/openpress/readerState.ts +15 -0
- package/template/core/src/openpress/renderer.tsx +91 -0
- package/template/core/src/openpress/runtimeMode.ts +22 -0
- package/template/core/src/openpress/types.ts +112 -0
- package/template/core/src/openpress/workbench.tsx +1299 -0
- package/template/core/src/openpress/workbenchPanels.tsx +122 -0
- package/template/core/src/openpress/workbenchTypes.ts +4 -0
- package/template/core/src/styles/openpress/app-shell.css +251 -0
- package/template/core/src/styles/openpress/media-workspace.css +230 -0
- package/template/core/src/styles/openpress/print-route.css +186 -0
- package/template/core/src/styles/openpress/project-workspace.css +1318 -0
- package/template/core/src/styles/openpress/public-viewer.css +983 -0
- package/template/core/src/styles/openpress/reader-runtime.css +792 -0
- package/template/core/src/styles/openpress/responsive.css +384 -0
- package/template/core/src/styles/openpress/workbench-panels.css +558 -0
- package/template/core/src/styles/openpress/workbench.css +720 -0
- package/template/core/src/styles/openpress.css +14 -0
- package/template/core/src/vite-env.d.ts +9 -0
- package/template/core/tsconfig.json +37 -0
- package/template/core/vite.config.ts +512 -0
- package/template/skills/chinese-ai-writing-polish/SKILL.md +195 -0
- package/template/skills/claude-document/SKILL.md +66 -0
- package/template/skills/claude-document/starter/document/chapters/01-document-shape/chapter.tsx +30 -0
- package/template/skills/claude-document/starter/document/chapters/01-document-shape/content/01-document-shape.mdx +51 -0
- package/template/skills/claude-document/starter/document/chapters/02-review-loop/chapter.tsx +30 -0
- package/template/skills/claude-document/starter/document/chapters/02-review-loop/content/01-review-loop.mdx +31 -0
- package/template/skills/claude-document/starter/document/components/ChapterOpenerVisual.tsx +96 -0
- package/template/skills/claude-document/starter/document/components/Page.tsx +27 -0
- package/template/skills/claude-document/starter/document/design.md +142 -0
- package/template/skills/claude-document/starter/document/index.tsx +89 -0
- package/template/skills/claude-document/starter/document/media/README.md +13 -0
- package/template/skills/claude-document/starter/document/openpress.config.mjs +26 -0
- package/template/skills/claude-document/starter/document/theme/README.md +15 -0
- package/template/skills/claude-document/starter/document/theme/base/page-contract.css +525 -0
- package/template/skills/claude-document/starter/document/theme/base/print.css +93 -0
- package/template/skills/claude-document/starter/document/theme/base/typography.css +612 -0
- package/template/skills/claude-document/starter/document/theme/fonts.css +4 -0
- package/template/skills/claude-document/starter/document/theme/page-surfaces/back-cover.css +72 -0
- package/template/skills/claude-document/starter/document/theme/page-surfaces/chapter-opener.css +236 -0
- package/template/skills/claude-document/starter/document/theme/page-surfaces/cover.css +309 -0
- package/template/skills/claude-document/starter/document/theme/page-surfaces/toc.css +213 -0
- package/template/skills/claude-document/starter/document/theme/patterns/_chart-frame.css +53 -0
- package/template/skills/claude-document/starter/document/theme/patterns/figure-grid.css +68 -0
- package/template/skills/claude-document/starter/document/theme/patterns/table-utilities.css +66 -0
- package/template/skills/claude-document/starter/document/theme/shell/reader-controls.css +789 -0
- package/template/skills/claude-document/starter/document/theme/tokens.css +89 -0
- package/template/skills/claude-document/starter/openpress.config.mjs +5 -0
- package/template/skills/editorial-monograph/SKILL.md +73 -0
- package/template/skills/editorial-monograph/starter/document/chapters/01-product-and-use-cases/content/01-product-and-use-cases.mdx +31 -0
- package/template/skills/editorial-monograph/starter/document/chapters/02-workflow/content/01-workflow.mdx +89 -0
- package/template/skills/editorial-monograph/starter/document/chapters/03-agent-skills-contributors/content/01-agent-skills-contributors.mdx +52 -0
- package/template/skills/editorial-monograph/starter/document/chapters/04-validation-deploy/content/01-validation-deploy.mdx +39 -0
- package/template/skills/editorial-monograph/starter/document/components/ChapterOpenerVisual/index.tsx +76 -0
- package/template/skills/editorial-monograph/starter/document/components/Page.tsx +27 -0
- package/template/skills/editorial-monograph/starter/document/components/TokenSwatchGrid/index.tsx +46 -0
- package/template/skills/editorial-monograph/starter/document/components/TokenSwatchGrid/style.css +63 -0
- package/template/skills/editorial-monograph/starter/document/components/TypeSpecimen/index.tsx +38 -0
- package/template/skills/editorial-monograph/starter/document/components/TypeSpecimen/style.css +111 -0
- package/template/skills/editorial-monograph/starter/document/design.md +279 -0
- package/template/skills/editorial-monograph/starter/document/index.tsx +73 -0
- package/template/skills/editorial-monograph/starter/document/media/README.md +13 -0
- package/template/skills/editorial-monograph/starter/document/openpress.config.mjs +26 -0
- package/template/skills/editorial-monograph/starter/document/theme/README.md +11 -0
- package/template/skills/editorial-monograph/starter/document/theme/base/page-contract.css +505 -0
- package/template/skills/editorial-monograph/starter/document/theme/base/print.css +93 -0
- package/template/skills/editorial-monograph/starter/document/theme/base/typography.css +336 -0
- package/template/skills/editorial-monograph/starter/document/theme/fonts.css +3 -0
- package/template/skills/editorial-monograph/starter/document/theme/page-surfaces/back-cover.css +43 -0
- package/template/skills/editorial-monograph/starter/document/theme/page-surfaces/chapter-opener.css +205 -0
- package/template/skills/editorial-monograph/starter/document/theme/page-surfaces/cover.css +147 -0
- package/template/skills/editorial-monograph/starter/document/theme/page-surfaces/toc.css +139 -0
- package/template/skills/editorial-monograph/starter/document/theme/patterns/_chart-frame.css +49 -0
- package/template/skills/editorial-monograph/starter/document/theme/patterns/figure-grid.css +68 -0
- package/template/skills/editorial-monograph/starter/document/theme/patterns/table-utilities.css +66 -0
- package/template/skills/editorial-monograph/starter/document/theme/shell/reader-controls.css +761 -0
- package/template/skills/editorial-monograph/starter/document/theme/tokens.css +80 -0
- package/template/skills/editorial-monograph/starter/openpress.config.mjs +5 -0
- package/template/skills/openpress/SKILL.md +114 -0
- package/template/skills/openpress/references/cli-commands.md +31 -0
- package/template/skills/openpress/references/local-review.md +43 -0
- package/template/skills/openpress-deploy/SKILL.md +69 -0
- package/template/skills/openpress-deploy/references/cloudflare-pages.md +51 -0
- package/template/skills/openpress-design/SKILL.md +51 -0
- package/template/skills/openpress-design/references/pdf-safe-css.md +29 -0
- package/template/skills/openpress-design/references/responsive-fixed-layout.md +48 -0
- package/template/skills/openpress-design/references/theme-and-components.md +77 -0
- package/template/skills/openpress-diagram-drawing/SKILL.md +44 -0
- package/template/skills/openpress-diagram-drawing/references/diagram-patterns.md +93 -0
- package/template/skills/openpress-document-hierarchy/SKILL.md +81 -0
- package/template/skills/openpress-document-hierarchy/agents/openai.yaml +4 -0
- package/template/skills/openpress-document-hierarchy/references/data-structures-outline.md +115 -0
- package/template/skills/openpress-init/SKILL.md +84 -0
- package/template/skills/openpress-style-pack-contributor/SKILL.md +62 -0
- package/template/skills/openpress-style-pack-contributor/references/starter-contract.md +49 -0
- package/template/skills/openpress-update/SKILL.md +88 -0
- package/template/skills/openpress-writing/SKILL.md +68 -0
- package/template/skills/openpress-writing/references/source-and-writing-rules.md +120 -0
- package/template/skills/teaching-notes-writing/SKILL.md +54 -0
- package/template/skills/teaching-notes-writing/references/programming.md +65 -0
- package/template/skills/teaching-notes-writing/references/teaching-patterns.md +60 -0
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
/* page-surfaces / cover
|
|
2
|
+
* Cover and back-cover share most of their layout chrome (meta header, byline
|
|
3
|
+
* footer, central main column). Shared selectors live here so cover is the
|
|
4
|
+
* primary reference; back-cover.css only refines the parts that differ.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
.reader-page--cover,
|
|
8
|
+
.reader-page--back-cover {
|
|
9
|
+
background: var(--openpress-color-document);
|
|
10
|
+
padding: clamp(28px, 5cqw, 48px) clamp(24px, 4.5cqw, 42px);
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
justify-content: space-between;
|
|
13
|
+
gap: clamp(16px, 2.5cqw, 24px);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.reader-app.is-ready .reader-page--cover,
|
|
17
|
+
.reader-app.is-ready .reader-page--back-cover,
|
|
18
|
+
.reader-page--cover.is-active,
|
|
19
|
+
.reader-page--back-cover.is-active {
|
|
20
|
+
display: flex;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.cover-meta,
|
|
24
|
+
.back-cover-meta {
|
|
25
|
+
display: flex;
|
|
26
|
+
justify-content: space-between;
|
|
27
|
+
align-items: flex-start;
|
|
28
|
+
gap: var(--openpress-space-3);
|
|
29
|
+
padding-bottom: var(--openpress-space-2);
|
|
30
|
+
border-bottom: 1px solid var(--openpress-color-ink);
|
|
31
|
+
font-family: var(--openpress-font-body);
|
|
32
|
+
font-size: clamp(8pt, 1.25cqw, 9.5pt);
|
|
33
|
+
color: var(--openpress-color-muted);
|
|
34
|
+
letter-spacing: 0.12em;
|
|
35
|
+
flex-shrink: 0;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.mihua-logo,
|
|
39
|
+
.openpress-logo {
|
|
40
|
+
display: block;
|
|
41
|
+
width: clamp(112px, 18cqw, 154px);
|
|
42
|
+
height: auto;
|
|
43
|
+
flex-shrink: 0;
|
|
44
|
+
object-fit: contain;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.cover-meta-title {
|
|
48
|
+
margin-left: auto;
|
|
49
|
+
max-width: 48%;
|
|
50
|
+
padding-top: 0.35em;
|
|
51
|
+
text-align: right;
|
|
52
|
+
white-space: nowrap;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.cover-main,
|
|
56
|
+
.back-cover-main {
|
|
57
|
+
display: flex;
|
|
58
|
+
flex-direction: column;
|
|
59
|
+
flex: 1;
|
|
60
|
+
min-height: 0;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.cover-title {
|
|
64
|
+
margin: 0;
|
|
65
|
+
font-family: var(--openpress-font-serif);
|
|
66
|
+
font-size: clamp(36px, 8.5cqw, 64px);
|
|
67
|
+
font-weight: 300;
|
|
68
|
+
line-height: 1;
|
|
69
|
+
letter-spacing: 0.01em;
|
|
70
|
+
color: var(--openpress-color-ink);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.cover-tagline {
|
|
74
|
+
margin: var(--openpress-space-2) 0 0;
|
|
75
|
+
font-family: var(--openpress-font-serif);
|
|
76
|
+
font-size: clamp(14px, 2.4cqw, 20px);
|
|
77
|
+
font-weight: 300;
|
|
78
|
+
letter-spacing: 0.08em;
|
|
79
|
+
color: var(--openpress-color-muted);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.cover-rule,
|
|
83
|
+
.back-cover-rule {
|
|
84
|
+
height: 1px;
|
|
85
|
+
width: 40px;
|
|
86
|
+
background: var(--openpress-color-ink);
|
|
87
|
+
margin: var(--openpress-space-3) 0;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.cover-subtitle {
|
|
91
|
+
margin: 0;
|
|
92
|
+
font-family: var(--openpress-font-body);
|
|
93
|
+
font-size: clamp(10.5pt, 1.85cqw, 12.5pt);
|
|
94
|
+
font-weight: 400;
|
|
95
|
+
letter-spacing: 0.02em;
|
|
96
|
+
line-height: 1.55;
|
|
97
|
+
color: var(--openpress-color-ink);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.cover-summary {
|
|
101
|
+
margin: var(--openpress-space-2) 0 0;
|
|
102
|
+
font-family: var(--openpress-font-body);
|
|
103
|
+
font-size: clamp(9pt, 1.65cqw, 10pt);
|
|
104
|
+
line-height: 1.8;
|
|
105
|
+
color: var(--openpress-color-muted);
|
|
106
|
+
max-width: 90%;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.cover-visual,
|
|
110
|
+
.back-cover-visual {
|
|
111
|
+
margin: var(--openpress-space-3) 0 0;
|
|
112
|
+
flex-shrink: 0;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.cover-visual img,
|
|
116
|
+
.back-cover-visual img {
|
|
117
|
+
display: block;
|
|
118
|
+
width: 100%;
|
|
119
|
+
height: auto;
|
|
120
|
+
max-height: 22cqh;
|
|
121
|
+
object-fit: cover;
|
|
122
|
+
border: 0;
|
|
123
|
+
padding: 0;
|
|
124
|
+
background: transparent;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.cover-byline,
|
|
128
|
+
.back-cover-byline {
|
|
129
|
+
display: flex;
|
|
130
|
+
justify-content: space-between;
|
|
131
|
+
align-items: baseline;
|
|
132
|
+
padding-top: var(--openpress-space-2);
|
|
133
|
+
border-top: 1px solid var(--openpress-color-ink);
|
|
134
|
+
font-family: var(--openpress-font-body);
|
|
135
|
+
font-size: clamp(8pt, 1.25cqw, 9.5pt);
|
|
136
|
+
color: var(--openpress-color-muted);
|
|
137
|
+
letter-spacing: 0.12em;
|
|
138
|
+
flex-shrink: 0;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.cover-byline span:first-child,
|
|
142
|
+
.back-cover-byline span:first-child {
|
|
143
|
+
font-family: var(--openpress-font-serif);
|
|
144
|
+
font-weight: 400;
|
|
145
|
+
letter-spacing: 0.04em;
|
|
146
|
+
color: var(--openpress-color-ink);
|
|
147
|
+
}
|
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
/* page-surfaces / toc
|
|
2
|
+
* Table-of-contents page surface routed by `kind: toc` and built by the
|
|
3
|
+
* engine's renderToc(). Layout uses a 3-column grid (index / title / page).
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
.reader-page--toc {
|
|
7
|
+
padding: 0;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.reader-page--toc h2 {
|
|
11
|
+
margin-top: 0;
|
|
12
|
+
font-family: var(--openpress-font-serif);
|
|
13
|
+
font-weight: 300;
|
|
14
|
+
letter-spacing: 0.12em;
|
|
15
|
+
font-size: clamp(15pt, 3.6cqw, 18pt);
|
|
16
|
+
border-bottom: 0;
|
|
17
|
+
padding-bottom: 0;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.reader-page--toc h2.toc-heading--continuation {
|
|
21
|
+
margin-bottom: 0;
|
|
22
|
+
color: var(--openpress-color-muted);
|
|
23
|
+
font-family: var(--openpress-font-mono);
|
|
24
|
+
font-size: calc(8.5pt - var(--openpress-type-step-down));
|
|
25
|
+
font-weight: 400;
|
|
26
|
+
letter-spacing: 0.08em;
|
|
27
|
+
text-align: right;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.toc-list {
|
|
31
|
+
display: flex;
|
|
32
|
+
flex-direction: column;
|
|
33
|
+
gap: 0.75mm;
|
|
34
|
+
margin: 10mm 0 0;
|
|
35
|
+
padding: 0;
|
|
36
|
+
list-style: none;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.toc-continuation .toc-list {
|
|
40
|
+
margin-top: 5mm;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.toc-list li {
|
|
44
|
+
border-bottom: 0;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.toc-list a {
|
|
48
|
+
display: grid;
|
|
49
|
+
grid-template-columns: 9mm minmax(0, 1fr) 12mm;
|
|
50
|
+
column-gap: 3mm;
|
|
51
|
+
align-items: baseline;
|
|
52
|
+
color: var(--openpress-color-ink);
|
|
53
|
+
text-decoration: none;
|
|
54
|
+
padding: 1.6mm 0;
|
|
55
|
+
font-weight: 400;
|
|
56
|
+
line-height: 1.38;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.toc-list a:hover .toc-title {
|
|
60
|
+
color: var(--openpress-color-muted);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.toc-index {
|
|
64
|
+
display: inline-block;
|
|
65
|
+
color: var(--openpress-color-muted);
|
|
66
|
+
font-family: var(--openpress-font-mono);
|
|
67
|
+
font-variant-numeric: tabular-nums;
|
|
68
|
+
font-weight: 400;
|
|
69
|
+
letter-spacing: 0;
|
|
70
|
+
font-size: 9.5pt;
|
|
71
|
+
text-align: left;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.toc-level-2 a {
|
|
75
|
+
margin-top: 2.5mm;
|
|
76
|
+
padding: 3mm 0 2mm;
|
|
77
|
+
border-top: 1px solid rgba(169, 180, 194, 0.42);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.toc-level-2:first-child a {
|
|
81
|
+
margin-top: 0;
|
|
82
|
+
border-top: 0;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.toc-level-2 .toc-title {
|
|
86
|
+
color: var(--openpress-color-ink);
|
|
87
|
+
font-size: 12pt;
|
|
88
|
+
font-weight: 500;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.toc-level-2 .toc-title::after {
|
|
92
|
+
content: none;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.toc-level-2 .toc-page {
|
|
96
|
+
color: var(--openpress-color-ink);
|
|
97
|
+
font-size: 9.8pt;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.toc-level-3 a {
|
|
101
|
+
grid-template-columns: 9mm minmax(0, 1fr) 12mm;
|
|
102
|
+
padding: 1.28mm 0 1.28mm 7mm;
|
|
103
|
+
color: var(--openpress-color-muted);
|
|
104
|
+
font-size: 10pt;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.toc-level-3 .toc-index {
|
|
108
|
+
font-size: 9pt;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.toc-level-3 .toc-page {
|
|
112
|
+
font-size: 9.5pt;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.toc-title {
|
|
116
|
+
display: flex;
|
|
117
|
+
gap: 3mm;
|
|
118
|
+
align-items: baseline;
|
|
119
|
+
color: var(--openpress-color-ink);
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.toc-title::after {
|
|
123
|
+
content: "";
|
|
124
|
+
flex: 1;
|
|
125
|
+
min-width: 10mm;
|
|
126
|
+
border-bottom: 1px dotted rgba(72, 101, 129, 0.32);
|
|
127
|
+
transform: translateY(-0.22em);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.toc-page {
|
|
131
|
+
color: var(--openpress-color-muted);
|
|
132
|
+
font-family: var(--openpress-font-mono);
|
|
133
|
+
font-variant-numeric: tabular-nums;
|
|
134
|
+
font-weight: 400;
|
|
135
|
+
font-size: 9.8pt;
|
|
136
|
+
justify-self: end;
|
|
137
|
+
min-width: 10mm;
|
|
138
|
+
text-align: right;
|
|
139
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/* _chart-frame.css
|
|
2
|
+
* 共用圖表外框。文件圖表只要在 figure 上掛 chart-frame,
|
|
3
|
+
* 元件自己的 class 只負責內部結構樣式。
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
.reader-page--content .page-body > figure.chart-frame,
|
|
7
|
+
:where(.chart-frame) {
|
|
8
|
+
width: 100%;
|
|
9
|
+
max-width: none;
|
|
10
|
+
margin: var(--openpress-space-3) 0 var(--openpress-space-4);
|
|
11
|
+
margin-left: 0;
|
|
12
|
+
margin-right: 0;
|
|
13
|
+
padding: var(--openpress-space-2);
|
|
14
|
+
border: 1px solid rgba(0, 0, 0, 0.07);
|
|
15
|
+
background: var(--openpress-color-document);
|
|
16
|
+
box-sizing: border-box;
|
|
17
|
+
break-inside: avoid;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
:where(.chart-frame) figcaption {
|
|
21
|
+
margin-top: var(--openpress-space-2);
|
|
22
|
+
color: var(--openpress-color-muted);
|
|
23
|
+
font-size: clamp(10px, 1.05cqw, 11px);
|
|
24
|
+
line-height: 1.55;
|
|
25
|
+
letter-spacing: 0.04em;
|
|
26
|
+
text-align: center;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.reader-page--content .page-body > figure svg,
|
|
30
|
+
:where(.chart-frame) svg {
|
|
31
|
+
display: block;
|
|
32
|
+
max-width: 100%;
|
|
33
|
+
height: auto;
|
|
34
|
+
overflow: visible;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
@media (max-width: 899px) {
|
|
38
|
+
.reader-page--content .page-body > figure.chart-frame,
|
|
39
|
+
:where(.chart-frame) {
|
|
40
|
+
max-height: 100%;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.reader-page--content .page-body > figure svg,
|
|
44
|
+
:where(.chart-frame) svg {
|
|
45
|
+
width: 100%;
|
|
46
|
+
max-height: 100%;
|
|
47
|
+
object-fit: contain;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/* figure-grid
|
|
2
|
+
* Reusable image grid pattern for inline Markdown/HTML figures.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
table.figure-grid {
|
|
6
|
+
border: 0;
|
|
7
|
+
background: transparent;
|
|
8
|
+
table-layout: fixed;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
div.figure-grid {
|
|
12
|
+
display: grid;
|
|
13
|
+
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
14
|
+
gap: 4mm;
|
|
15
|
+
margin: var(--openpress-space-4) 0 var(--openpress-space-2);
|
|
16
|
+
break-inside: avoid;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
table.figure-grid td {
|
|
20
|
+
border: 0;
|
|
21
|
+
padding: 0 2mm 3mm;
|
|
22
|
+
vertical-align: top;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
table.figure-grid figure,
|
|
26
|
+
div.figure-grid figure {
|
|
27
|
+
margin-top: 0;
|
|
28
|
+
margin-bottom: 0;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.figure-grid img {
|
|
32
|
+
width: auto;
|
|
33
|
+
height: auto;
|
|
34
|
+
max-width: 100%;
|
|
35
|
+
max-height: 62mm;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/* Three-column triptych: one lead figure plus two siblings, centered on the
|
|
39
|
+
* page. Use this when a section needs a coordinated trio of images at a fixed
|
|
40
|
+
* aspect ratio (e.g. founder profile, milestone photo set). */
|
|
41
|
+
div.figure-grid--triptych {
|
|
42
|
+
grid-template-columns: repeat(3, minmax(0, 1fr));
|
|
43
|
+
gap: 3mm;
|
|
44
|
+
width: min(92%, 156mm);
|
|
45
|
+
margin: var(--openpress-space-4) auto var(--openpress-space-2);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
div.figure-grid--triptych figure {
|
|
49
|
+
display: flex;
|
|
50
|
+
flex-direction: column;
|
|
51
|
+
align-items: center;
|
|
52
|
+
margin: 0;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
div.figure-grid--triptych img {
|
|
56
|
+
width: 100%;
|
|
57
|
+
max-height: none;
|
|
58
|
+
aspect-ratio: 3 / 2;
|
|
59
|
+
object-fit: cover;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
div.figure-grid--triptych .figure-grid__lead img {
|
|
63
|
+
aspect-ratio: 4 / 3;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
div.figure-grid--triptych figcaption {
|
|
67
|
+
text-align: left;
|
|
68
|
+
}
|
package/template/skills/editorial-monograph/starter/document/theme/patterns/table-utilities.css
ADDED
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/* table-utilities
|
|
2
|
+
* Semantic table helpers used by content Markdown.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
.cell-check,
|
|
6
|
+
.cell-partial,
|
|
7
|
+
.cell-dash {
|
|
8
|
+
display: inline-block;
|
|
9
|
+
font-feature-settings: "tnum";
|
|
10
|
+
line-height: 1;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.cell-check {
|
|
14
|
+
color: #24a148;
|
|
15
|
+
font-weight: 600;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.cell-partial {
|
|
19
|
+
color: #b58105;
|
|
20
|
+
font-weight: 500;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.cell-dash {
|
|
24
|
+
color: var(--openpress-color-text-placeholder);
|
|
25
|
+
letter-spacing: -0.04em;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.status-text {
|
|
29
|
+
display: inline;
|
|
30
|
+
font-size: inherit;
|
|
31
|
+
line-height: inherit;
|
|
32
|
+
white-space: nowrap;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.status-live {
|
|
36
|
+
color: #198038;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.status-building {
|
|
40
|
+
color: #0f62fe;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.status-planned {
|
|
44
|
+
color: #525252;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.status-ai-full {
|
|
48
|
+
color: #007d79;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.status-ai-partial {
|
|
52
|
+
color: #8a5a00;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
td.numeric,
|
|
56
|
+
th.numeric {
|
|
57
|
+
text-align: right;
|
|
58
|
+
font-variant-numeric: tabular-nums;
|
|
59
|
+
white-space: nowrap;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
td.savings-rate,
|
|
63
|
+
th.savings-rate {
|
|
64
|
+
color: var(--openpress-color-green);
|
|
65
|
+
font-weight: 600;
|
|
66
|
+
}
|