mordoc 0.1.1
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/README.md +240 -0
- package/bin/cli.js +81 -0
- package/dist/build/Builder.d.ts +91 -0
- package/dist/build/Builder.d.ts.map +1 -0
- package/dist/build/Builder.js +391 -0
- package/dist/build/Builder.js.map +1 -0
- package/dist/build/ClientBundler.d.ts +36 -0
- package/dist/build/ClientBundler.d.ts.map +1 -0
- package/dist/build/ClientBundler.js +132 -0
- package/dist/build/ClientBundler.js.map +1 -0
- package/dist/build/HtmlGenerator.d.ts +46 -0
- package/dist/build/HtmlGenerator.d.ts.map +1 -0
- package/dist/build/HtmlGenerator.js +200 -0
- package/dist/build/HtmlGenerator.js.map +1 -0
- package/dist/build/SearchIndexer.d.ts +31 -0
- package/dist/build/SearchIndexer.d.ts.map +1 -0
- package/dist/build/SearchIndexer.js +116 -0
- package/dist/build/SearchIndexer.js.map +1 -0
- package/dist/cli/build.d.ts +20 -0
- package/dist/cli/build.d.ts.map +1 -0
- package/dist/cli/build.js +111 -0
- package/dist/cli/build.js.map +1 -0
- package/dist/cli/create-app.d.ts +14 -0
- package/dist/cli/create-app.d.ts.map +1 -0
- package/dist/cli/create-app.js +216 -0
- package/dist/cli/create-app.js.map +1 -0
- package/dist/cli/dev.d.ts +20 -0
- package/dist/cli/dev.d.ts.map +1 -0
- package/dist/cli/dev.js +169 -0
- package/dist/cli/dev.js.map +1 -0
- package/dist/client/App.d.ts +17 -0
- package/dist/client/App.d.ts.map +1 -0
- package/dist/client/App.js +94 -0
- package/dist/client/App.js.map +1 -0
- package/dist/client/contexts/ConfigContext.d.ts +22 -0
- package/dist/client/contexts/ConfigContext.d.ts.map +1 -0
- package/dist/client/contexts/ConfigContext.js +27 -0
- package/dist/client/contexts/ConfigContext.js.map +1 -0
- package/dist/client/contexts/ContentContext.d.ts +31 -0
- package/dist/client/contexts/ContentContext.d.ts.map +1 -0
- package/dist/client/contexts/ContentContext.js +46 -0
- package/dist/client/contexts/ContentContext.js.map +1 -0
- package/dist/client/contexts/SearchContext.d.ts +38 -0
- package/dist/client/contexts/SearchContext.d.ts.map +1 -0
- package/dist/client/contexts/SearchContext.js +207 -0
- package/dist/client/contexts/SearchContext.js.map +1 -0
- package/dist/client/contexts/ThemeContext.d.ts +23 -0
- package/dist/client/contexts/ThemeContext.d.ts.map +1 -0
- package/dist/client/contexts/ThemeContext.js +62 -0
- package/dist/client/contexts/ThemeContext.js.map +1 -0
- package/dist/client/hooks/useContent.d.ts +12 -0
- package/dist/client/hooks/useContent.d.ts.map +1 -0
- package/dist/client/hooks/useContent.js +74 -0
- package/dist/client/hooks/useContent.js.map +1 -0
- package/dist/client/hooks/useNavigation.d.ts +15 -0
- package/dist/client/hooks/useNavigation.d.ts.map +1 -0
- package/dist/client/hooks/useNavigation.js +101 -0
- package/dist/client/hooks/useNavigation.js.map +1 -0
- package/dist/client/hooks/useSearch.d.ts +22 -0
- package/dist/client/hooks/useSearch.d.ts.map +1 -0
- package/dist/client/hooks/useSearch.js +64 -0
- package/dist/client/hooks/useSearch.js.map +1 -0
- package/dist/client/main.d.ts +5 -0
- package/dist/client/main.d.ts.map +1 -0
- package/dist/client/main.js +66 -0
- package/dist/client/main.js.map +1 -0
- package/dist/components/Callout.d.ts +9 -0
- package/dist/components/Callout.d.ts.map +1 -0
- package/dist/components/Callout.js +24 -0
- package/dist/components/Callout.js.map +1 -0
- package/dist/components/Card.d.ts +10 -0
- package/dist/components/Card.d.ts.map +1 -0
- package/dist/components/Card.js +15 -0
- package/dist/components/Card.js.map +1 -0
- package/dist/components/CardGrid.d.ts +8 -0
- package/dist/components/CardGrid.d.ts.map +1 -0
- package/dist/components/CardGrid.js +9 -0
- package/dist/components/CardGrid.js.map +1 -0
- package/dist/components/CodeBlock.d.ts +24 -0
- package/dist/components/CodeBlock.d.ts.map +1 -0
- package/dist/components/CodeBlock.js +76 -0
- package/dist/components/CodeBlock.js.map +1 -0
- package/dist/components/ContentPage.d.ts +9 -0
- package/dist/components/ContentPage.d.ts.map +1 -0
- package/dist/components/ContentPage.js +36 -0
- package/dist/components/ContentPage.js.map +1 -0
- package/dist/components/Header.d.ts +14 -0
- package/dist/components/Header.d.ts.map +1 -0
- package/dist/components/Header.js +30 -0
- package/dist/components/Header.js.map +1 -0
- package/dist/components/Heading.d.ts +16 -0
- package/dist/components/Heading.d.ts.map +1 -0
- package/dist/components/Heading.js +31 -0
- package/dist/components/Heading.js.map +1 -0
- package/dist/components/Image.d.ts +8 -0
- package/dist/components/Image.d.ts.map +1 -0
- package/dist/components/Image.js +24 -0
- package/dist/components/Image.js.map +1 -0
- package/dist/components/Layout.d.ts +14 -0
- package/dist/components/Layout.d.ts.map +1 -0
- package/dist/components/Layout.js +32 -0
- package/dist/components/Layout.js.map +1 -0
- package/dist/components/MarkdocRenderer.d.ts +15 -0
- package/dist/components/MarkdocRenderer.d.ts.map +1 -0
- package/dist/components/MarkdocRenderer.js +73 -0
- package/dist/components/MarkdocRenderer.js.map +1 -0
- package/dist/components/MobileMenu.d.ts +14 -0
- package/dist/components/MobileMenu.d.ts.map +1 -0
- package/dist/components/MobileMenu.js +45 -0
- package/dist/components/MobileMenu.js.map +1 -0
- package/dist/components/PageNavigation.d.ts +9 -0
- package/dist/components/PageNavigation.d.ts.map +1 -0
- package/dist/components/PageNavigation.js +23 -0
- package/dist/components/PageNavigation.js.map +1 -0
- package/dist/components/SearchModal.d.ts +9 -0
- package/dist/components/SearchModal.d.ts.map +1 -0
- package/dist/components/SearchModal.js +74 -0
- package/dist/components/SearchModal.js.map +1 -0
- package/dist/components/SideNav.d.ts +9 -0
- package/dist/components/SideNav.d.ts.map +1 -0
- package/dist/components/SideNav.js +66 -0
- package/dist/components/SideNav.js.map +1 -0
- package/dist/components/TableOfContents.d.ts +10 -0
- package/dist/components/TableOfContents.d.ts.map +1 -0
- package/dist/components/TableOfContents.js +151 -0
- package/dist/components/TableOfContents.js.map +1 -0
- package/dist/config/ConfigLoader.d.ts +50 -0
- package/dist/config/ConfigLoader.d.ts.map +1 -0
- package/dist/config/ConfigLoader.js +214 -0
- package/dist/config/ConfigLoader.js.map +1 -0
- package/dist/config/StyleCompiler.d.ts +17 -0
- package/dist/config/StyleCompiler.d.ts.map +1 -0
- package/dist/config/StyleCompiler.js +116 -0
- package/dist/config/StyleCompiler.js.map +1 -0
- package/dist/config/ThemeGenerator.d.ts +14 -0
- package/dist/config/ThemeGenerator.d.ts.map +1 -0
- package/dist/config/ThemeGenerator.js +129 -0
- package/dist/config/ThemeGenerator.js.map +1 -0
- package/dist/content/ContentLoader.d.ts +70 -0
- package/dist/content/ContentLoader.d.ts.map +1 -0
- package/dist/content/ContentLoader.js +146 -0
- package/dist/content/ContentLoader.js.map +1 -0
- package/dist/content/ContentProcessor.d.ts +84 -0
- package/dist/content/ContentProcessor.d.ts.map +1 -0
- package/dist/content/ContentProcessor.js +380 -0
- package/dist/content/ContentProcessor.js.map +1 -0
- package/dist/content/RouteManager.d.ts +69 -0
- package/dist/content/RouteManager.d.ts.map +1 -0
- package/dist/content/RouteManager.js +143 -0
- package/dist/content/RouteManager.js.map +1 -0
- package/dist/styles/components/callout.d.ts +11 -0
- package/dist/styles/components/callout.d.ts.map +1 -0
- package/dist/styles/components/callout.js +83 -0
- package/dist/styles/components/callout.js.map +1 -0
- package/dist/styles/components/card.d.ts +11 -0
- package/dist/styles/components/card.d.ts.map +1 -0
- package/dist/styles/components/card.js +179 -0
- package/dist/styles/components/card.js.map +1 -0
- package/dist/styles/components/codeblock.d.ts +11 -0
- package/dist/styles/components/codeblock.d.ts.map +1 -0
- package/dist/styles/components/codeblock.js +249 -0
- package/dist/styles/components/codeblock.js.map +1 -0
- package/dist/styles/components/content.d.ts +11 -0
- package/dist/styles/components/content.d.ts.map +1 -0
- package/dist/styles/components/content.js +198 -0
- package/dist/styles/components/content.js.map +1 -0
- package/dist/styles/components/fonts.d.ts +11 -0
- package/dist/styles/components/fonts.d.ts.map +1 -0
- package/dist/styles/components/fonts.js +34 -0
- package/dist/styles/components/fonts.js.map +1 -0
- package/dist/styles/components/header.d.ts +11 -0
- package/dist/styles/components/header.d.ts.map +1 -0
- package/dist/styles/components/header.js +293 -0
- package/dist/styles/components/header.js.map +1 -0
- package/dist/styles/components/heading.d.ts +11 -0
- package/dist/styles/components/heading.d.ts.map +1 -0
- package/dist/styles/components/heading.js +115 -0
- package/dist/styles/components/heading.js.map +1 -0
- package/dist/styles/components/layout.d.ts +11 -0
- package/dist/styles/components/layout.d.ts.map +1 -0
- package/dist/styles/components/layout.js +79 -0
- package/dist/styles/components/layout.js.map +1 -0
- package/dist/styles/components/mobilemenu.d.ts +11 -0
- package/dist/styles/components/mobilemenu.d.ts.map +1 -0
- package/dist/styles/components/mobilemenu.js +112 -0
- package/dist/styles/components/mobilemenu.js.map +1 -0
- package/dist/styles/components/reset.d.ts +11 -0
- package/dist/styles/components/reset.d.ts.map +1 -0
- package/dist/styles/components/reset.js +131 -0
- package/dist/styles/components/reset.js.map +1 -0
- package/dist/styles/components/searchmodal.d.ts +11 -0
- package/dist/styles/components/searchmodal.d.ts.map +1 -0
- package/dist/styles/components/searchmodal.js +333 -0
- package/dist/styles/components/searchmodal.js.map +1 -0
- package/dist/styles/components/sidenav.d.ts +11 -0
- package/dist/styles/components/sidenav.d.ts.map +1 -0
- package/dist/styles/components/sidenav.js +209 -0
- package/dist/styles/components/sidenav.js.map +1 -0
- package/dist/styles/components/toc.d.ts +11 -0
- package/dist/styles/components/toc.d.ts.map +1 -0
- package/dist/styles/components/toc.js +112 -0
- package/dist/styles/components/toc.js.map +1 -0
- package/dist/styles/components/typography.d.ts +11 -0
- package/dist/styles/components/typography.d.ts.map +1 -0
- package/dist/styles/components/typography.js +247 -0
- package/dist/styles/components/typography.js.map +1 -0
- package/dist/styles/components/utility.d.ts +11 -0
- package/dist/styles/components/utility.d.ts.map +1 -0
- package/dist/styles/components/utility.js +231 -0
- package/dist/styles/components/utility.js.map +1 -0
- package/dist/styles/types.d.ts +79 -0
- package/dist/styles/types.d.ts.map +1 -0
- package/dist/styles/types.js +7 -0
- package/dist/styles/types.js.map +1 -0
- package/dist/styles/utils.d.ts +21 -0
- package/dist/styles/utils.d.ts.map +1 -0
- package/dist/styles/utils.js +50 -0
- package/dist/styles/utils.js.map +1 -0
- package/dist/styles/variables/main.d.ts +15 -0
- package/dist/styles/variables/main.d.ts.map +1 -0
- package/dist/styles/variables/main.js +116 -0
- package/dist/styles/variables/main.js.map +1 -0
- package/dist/types/config.d.ts +43 -0
- package/dist/types/config.d.ts.map +1 -0
- package/dist/types/config.js +7 -0
- package/dist/types/config.js.map +1 -0
- package/dist/types/content.d.ts +46 -0
- package/dist/types/content.d.ts.map +1 -0
- package/dist/types/content.js +7 -0
- package/dist/types/content.js.map +1 -0
- package/dist/types/navigation.d.ts +45 -0
- package/dist/types/navigation.d.ts.map +1 -0
- package/dist/types/navigation.js +7 -0
- package/dist/types/navigation.js.map +1 -0
- package/dist/utils/language-utils.d.ts +41 -0
- package/dist/utils/language-utils.d.ts.map +1 -0
- package/dist/utils/language-utils.js +79 -0
- package/dist/utils/language-utils.js.map +1 -0
- package/dist/utils/slugify.d.ts +20 -0
- package/dist/utils/slugify.d.ts.map +1 -0
- package/dist/utils/slugify.js +44 -0
- package/dist/utils/slugify.js.map +1 -0
- package/package.json +58 -0
|
@@ -0,0 +1,198 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Content page styles
|
|
4
|
+
* Main content area, article wrapper, and page footer
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.ContentStyleGenerator = void 0;
|
|
8
|
+
const utils_1 = require("../utils");
|
|
9
|
+
class ContentStyleGenerator {
|
|
10
|
+
constructor(globalVars) {
|
|
11
|
+
this.globalVars = globalVars;
|
|
12
|
+
}
|
|
13
|
+
generate() {
|
|
14
|
+
return `/* Content Page */
|
|
15
|
+
.content-page {
|
|
16
|
+
width: 100%;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.content-wrapper {
|
|
20
|
+
display: flex;
|
|
21
|
+
gap: ${this.globalVars.spacing3xl};
|
|
22
|
+
width: 100%;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.content-article {
|
|
26
|
+
flex: 1;
|
|
27
|
+
min-width: 0;
|
|
28
|
+
max-width: 60rem;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.content-header {
|
|
32
|
+
margin-bottom: ${this.globalVars.spacingXl};
|
|
33
|
+
border-bottom: 1px solid ${this.globalVars.borderColorLight};
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
${(0, utils_1.darkMode)(` .content-header {
|
|
37
|
+
border-bottom-color: ${this.globalVars.borderColorDark};
|
|
38
|
+
}`)}
|
|
39
|
+
|
|
40
|
+
.content-title {
|
|
41
|
+
margin-top: 0;
|
|
42
|
+
font-size: 2.5rem;
|
|
43
|
+
font-weight: 700;
|
|
44
|
+
line-height: 1.2;
|
|
45
|
+
letter-spacing: -0.02em;
|
|
46
|
+
margin-bottom: 1rem;
|
|
47
|
+
color: ${this.globalVars.primaryColorLight};
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
${(0, utils_1.darkMode)(` .content-title {
|
|
51
|
+
color: ${this.globalVars.primaryColorDark};
|
|
52
|
+
}`)}
|
|
53
|
+
|
|
54
|
+
.content-description {
|
|
55
|
+
font-size: 1rem;
|
|
56
|
+
line-height: 1.7;
|
|
57
|
+
font-weight: 400;
|
|
58
|
+
color: ${this.globalVars.textPrimaryLight};
|
|
59
|
+
margin-bottom: 1rem;
|
|
60
|
+
max-width: 42rem;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
${(0, utils_1.darkMode)(` .content-description {
|
|
64
|
+
color: ${this.globalVars.textPrimaryDark};
|
|
65
|
+
}`)}
|
|
66
|
+
|
|
67
|
+
.content-meta {
|
|
68
|
+
display: flex;
|
|
69
|
+
font-size: 0.875rem;
|
|
70
|
+
color: ${this.globalVars.textSecondaryLight};
|
|
71
|
+
margin-bottom: 1rem;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
${(0, utils_1.darkMode)(` .content-meta {
|
|
75
|
+
color: ${this.globalVars.textSecondaryDark};
|
|
76
|
+
}`)}
|
|
77
|
+
|
|
78
|
+
.content-tags {
|
|
79
|
+
display: flex;
|
|
80
|
+
flex-wrap: wrap;
|
|
81
|
+
gap: ${this.globalVars.spacingSm};
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.content-tag {
|
|
85
|
+
padding: ${this.globalVars.spacingXs} ${this.globalVars.spacingSm};
|
|
86
|
+
background: ${this.globalVars.surfaceColorLight};
|
|
87
|
+
color: ${this.globalVars.textPrimaryLight};
|
|
88
|
+
border-radius: ${this.globalVars.borderRadiusSm};
|
|
89
|
+
font-size: ${this.globalVars.fontSizeSm};
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
${(0, utils_1.darkMode)(` .content-tag {
|
|
93
|
+
background: ${this.globalVars.surfaceColorDark};
|
|
94
|
+
color: ${this.globalVars.textPrimaryDark};
|
|
95
|
+
}`)}
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
.content-body {
|
|
99
|
+
margin-bottom: ${this.globalVars.spacing2xl};
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.content-toc {
|
|
103
|
+
width: 280px;
|
|
104
|
+
flex-shrink: 0;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.content-footer {
|
|
108
|
+
margin-top: ${this.globalVars.spacing3xl};
|
|
109
|
+
margin-bottom: ${this.globalVars.spacing2xl};
|
|
110
|
+
padding-top: ${this.globalVars.spacingXl};
|
|
111
|
+
border-top: 1px solid ${this.globalVars.borderColorLight};
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
${(0, utils_1.darkMode)(` .content-footer {
|
|
115
|
+
border-top-color: ${this.globalVars.borderColorDark};
|
|
116
|
+
}`)}
|
|
117
|
+
|
|
118
|
+
.content-footer-info p {
|
|
119
|
+
text-align: center;
|
|
120
|
+
color: ${this.globalVars.textSecondaryLight};
|
|
121
|
+
font-size: ${this.globalVars.fontSizeSm};
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
${(0, utils_1.darkMode)(` .content-footer-info p {
|
|
125
|
+
color: ${this.globalVars.textSecondaryDark};
|
|
126
|
+
}`)}
|
|
127
|
+
|
|
128
|
+
.content-footer-text {
|
|
129
|
+
margin: 0 0 ${this.globalVars.spacingSm} 0;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.content-footer-powered {
|
|
133
|
+
margin: 0;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.content-footer-powered a {
|
|
137
|
+
color: ${this.globalVars.linkColorLight};
|
|
138
|
+
text-decoration: none;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
${(0, utils_1.darkMode)(` .content-footer-powered a {
|
|
142
|
+
color: ${this.globalVars.linkColorDark};
|
|
143
|
+
}`)}
|
|
144
|
+
|
|
145
|
+
.content-footer-powered a:hover {
|
|
146
|
+
text-decoration: underline;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
${(0, utils_1.mediaQuery)('xl', ` .content-toc {
|
|
150
|
+
width: 240px;
|
|
151
|
+
}`)}
|
|
152
|
+
|
|
153
|
+
${(0, utils_1.mediaQuery)('lg', ` .content-toc {
|
|
154
|
+
width: 220px;
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
.content-article {
|
|
158
|
+
max-width: 720px;
|
|
159
|
+
}`)}
|
|
160
|
+
|
|
161
|
+
${(0, utils_1.mediaQuery)('lg', ` .content-wrapper {
|
|
162
|
+
gap: ${this.globalVars.spacing2xl};
|
|
163
|
+
}`)}
|
|
164
|
+
|
|
165
|
+
${(0, utils_1.mediaQuery)('md', ` .content-wrapper {
|
|
166
|
+
flex-direction: column;
|
|
167
|
+
gap: ${this.globalVars.spacingXl};
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.content-article {
|
|
171
|
+
max-width: 100%;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.content-toc {
|
|
175
|
+
width: 100%;
|
|
176
|
+
order: -1;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
.content-title {
|
|
180
|
+
font-size: ${this.globalVars.fontSize3xl};
|
|
181
|
+
}`)}
|
|
182
|
+
|
|
183
|
+
${(0, utils_1.mediaQuery)('sm', ` .content-toc {
|
|
184
|
+
display: none;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.content-title {
|
|
188
|
+
font-size: ${this.globalVars.fontSize2xl};
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
.content-meta {
|
|
192
|
+
flex-direction: column;
|
|
193
|
+
gap: ${this.globalVars.spacingSm};
|
|
194
|
+
}`)}`;
|
|
195
|
+
}
|
|
196
|
+
}
|
|
197
|
+
exports.ContentStyleGenerator = ContentStyleGenerator;
|
|
198
|
+
//# sourceMappingURL=content.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content.js","sourceRoot":"","sources":["../../../src/styles/components/content.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAGH,oCAAgD;AAEhD,MAAa,qBAAqB;IAChC,YAAoB,UAA2B;QAA3B,eAAU,GAAV,UAAU,CAAiB;IAAG,CAAC;IAEnD,QAAQ;QACN,OAAO;;;;;;;SAOF,IAAI,CAAC,UAAU,CAAC,UAAU;;;;;;;;;;;mBAWhB,IAAI,CAAC,UAAU,CAAC,SAAS;6BACf,IAAI,CAAC,UAAU,CAAC,gBAAgB;;;EAG3D,IAAA,gBAAQ,EAAC;2BACgB,IAAI,CAAC,UAAU,CAAC,eAAe;IACtD,CAAC;;;;;;;;;WASM,IAAI,CAAC,UAAU,CAAC,iBAAiB;;;EAG1C,IAAA,gBAAQ,EAAC;aACE,IAAI,CAAC,UAAU,CAAC,gBAAgB;IACzC,CAAC;;;;;;WAMM,IAAI,CAAC,UAAU,CAAC,gBAAgB;;;;;EAKzC,IAAA,gBAAQ,EAAC;aACE,IAAI,CAAC,UAAU,CAAC,eAAe;IACxC,CAAC;;;;;WAKM,IAAI,CAAC,UAAU,CAAC,kBAAkB;;;;EAI3C,IAAA,gBAAQ,EAAC;aACE,IAAI,CAAC,UAAU,CAAC,iBAAiB;IAC1C,CAAC;;;;;SAKI,IAAI,CAAC,UAAU,CAAC,SAAS;;;;aAIrB,IAAI,CAAC,UAAU,CAAC,SAAS,IAAI,IAAI,CAAC,UAAU,CAAC,SAAS;gBACnD,IAAI,CAAC,UAAU,CAAC,iBAAiB;WACtC,IAAI,CAAC,UAAU,CAAC,gBAAgB;mBACxB,IAAI,CAAC,UAAU,CAAC,cAAc;eAClC,IAAI,CAAC,UAAU,CAAC,UAAU;;;EAGvC,IAAA,gBAAQ,EAAC;kBACO,IAAI,CAAC,UAAU,CAAC,gBAAgB;aACrC,IAAI,CAAC,UAAU,CAAC,eAAe;IACxC,CAAC;;;;mBAIc,IAAI,CAAC,UAAU,CAAC,UAAU;;;;;;;;;gBAS7B,IAAI,CAAC,UAAU,CAAC,UAAU;mBACvB,IAAI,CAAC,UAAU,CAAC,UAAU;iBAC5B,IAAI,CAAC,UAAU,CAAC,SAAS;0BAChB,IAAI,CAAC,UAAU,CAAC,gBAAgB;;;EAGxD,IAAA,gBAAQ,EAAC;wBACa,IAAI,CAAC,UAAU,CAAC,eAAe;IACnD,CAAC;;;;WAIM,IAAI,CAAC,UAAU,CAAC,kBAAkB;eAC9B,IAAI,CAAC,UAAU,CAAC,UAAU;;;EAGvC,IAAA,gBAAQ,EAAC;aACE,IAAI,CAAC,UAAU,CAAC,iBAAiB;IAC1C,CAAC;;;gBAGW,IAAI,CAAC,UAAU,CAAC,SAAS;;;;;;;;WAQ9B,IAAI,CAAC,UAAU,CAAC,cAAc;;;;EAIvC,IAAA,gBAAQ,EAAC;aACE,IAAI,CAAC,UAAU,CAAC,aAAa;IACtC,CAAC;;;;;;EAMH,IAAA,kBAAU,EAAC,IAAI,EAAE;;IAEf,CAAC;;EAEH,IAAA,kBAAU,EAAC,IAAI,EAAE;;;;;;IAMf,CAAC;;EAEH,IAAA,kBAAU,EAAC,IAAI,EAAE;WACR,IAAI,CAAC,UAAU,CAAC,UAAU;IACjC,CAAC;;EAEH,IAAA,kBAAU,EAAC,IAAI,EAAE;;WAER,IAAI,CAAC,UAAU,CAAC,SAAS;;;;;;;;;;;;;iBAanB,IAAI,CAAC,UAAU,CAAC,WAAW;IACxC,CAAC;;EAEH,IAAA,kBAAU,EAAC,IAAI,EAAE;;;;;iBAKF,IAAI,CAAC,UAAU,CAAC,WAAW;;;;;WAKjC,IAAI,CAAC,UAAU,CAAC,SAAS;IAChC,CAAC,EAAE,CAAC;IACN,CAAC;CACF;AA1LD,sDA0LC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Font declarations
|
|
3
|
+
* @font-face rules for bundled fonts (Inter)
|
|
4
|
+
*/
|
|
5
|
+
import { GlobalVariables } from '../types';
|
|
6
|
+
export declare class FontStyleGenerator {
|
|
7
|
+
private globalVars;
|
|
8
|
+
constructor(globalVars: GlobalVariables);
|
|
9
|
+
generate(): string;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=fonts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fonts.d.ts","sourceRoot":"","sources":["../../../src/styles/components/fonts.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAE3C,qBAAa,kBAAkB;IACjB,OAAO,CAAC,UAAU;gBAAV,UAAU,EAAE,eAAe;IAE/C,QAAQ,IAAI,MAAM;CAoBnB"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Font declarations
|
|
4
|
+
* @font-face rules for bundled fonts (Inter)
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.FontStyleGenerator = void 0;
|
|
8
|
+
class FontStyleGenerator {
|
|
9
|
+
constructor(globalVars) {
|
|
10
|
+
this.globalVars = globalVars;
|
|
11
|
+
}
|
|
12
|
+
generate() {
|
|
13
|
+
return `/* Font Declarations */
|
|
14
|
+
@font-face {
|
|
15
|
+
font-family: 'Inter';
|
|
16
|
+
font-style: normal;
|
|
17
|
+
font-weight: 100 900;
|
|
18
|
+
font-display: swap;
|
|
19
|
+
src: url('/assets/fonts/inter/Inter-VariableFont_opsz,wght.ttf') format('truetype-variations');
|
|
20
|
+
font-named-instance: 'Regular';
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
@font-face {
|
|
24
|
+
font-family: 'Inter';
|
|
25
|
+
font-style: italic;
|
|
26
|
+
font-weight: 100 900;
|
|
27
|
+
font-display: swap;
|
|
28
|
+
src: url('/assets/fonts/inter/Inter-Italic-VariableFont_opsz,wght.ttf') format('truetype-variations');
|
|
29
|
+
font-named-instance: 'Italic';
|
|
30
|
+
}`;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
exports.FontStyleGenerator = FontStyleGenerator;
|
|
34
|
+
//# sourceMappingURL=fonts.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fonts.js","sourceRoot":"","sources":["../../../src/styles/components/fonts.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH,MAAa,kBAAkB;IAC7B,YAAoB,UAA2B;QAA3B,eAAU,GAAV,UAAU,CAAiB;IAAG,CAAC;IAEnD,QAAQ;QACN,OAAO;;;;;;;;;;;;;;;;;EAiBT,CAAC;IACD,CAAC;CACF;AAvBD,gDAuBC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Header component styles
|
|
3
|
+
* Top navigation bar with logo, search, and optional top-level navigation
|
|
4
|
+
*/
|
|
5
|
+
import { GlobalVariables } from '../types';
|
|
6
|
+
export declare class HeaderStyleGenerator {
|
|
7
|
+
private globalVars;
|
|
8
|
+
constructor(globalVars: GlobalVariables);
|
|
9
|
+
generate(userOverrides?: Record<string, string>): string;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=header.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"header.d.ts","sourceRoot":"","sources":["../../../src/styles/components/header.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAQ3C,qBAAa,oBAAoB;IACnB,OAAO,CAAC,UAAU;gBAAV,UAAU,EAAE,eAAe;IAE/C,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM;CA4RzD"}
|
|
@@ -0,0 +1,293 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Header component styles
|
|
4
|
+
* Top navigation bar with logo, search, and optional top-level navigation
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.HeaderStyleGenerator = void 0;
|
|
8
|
+
const utils_1 = require("../utils");
|
|
9
|
+
class HeaderStyleGenerator {
|
|
10
|
+
constructor(globalVars) {
|
|
11
|
+
this.globalVars = globalVars;
|
|
12
|
+
}
|
|
13
|
+
generate(userOverrides) {
|
|
14
|
+
const defaults = {
|
|
15
|
+
searchHoverBorderColorLight: this.globalVars.primaryColorLight,
|
|
16
|
+
searchHoverBorderColorDark: this.globalVars.primaryColorDark,
|
|
17
|
+
};
|
|
18
|
+
const vars = (0, utils_1.mergeOverrides)(defaults, userOverrides, ['searchHoverBorderColorLight', 'searchHoverBorderColorDark']);
|
|
19
|
+
return `/* Header */
|
|
20
|
+
.site-header {
|
|
21
|
+
background-color: ${this.globalVars.backgroundColorLight};
|
|
22
|
+
border-bottom: 1px solid ${this.globalVars.borderColorLight};
|
|
23
|
+
position: sticky;
|
|
24
|
+
top: 0;
|
|
25
|
+
z-index: 100;
|
|
26
|
+
flex-shrink: 0;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
${(0, utils_1.darkMode)(` .site-header {
|
|
30
|
+
background-color: ${this.globalVars.backgroundColorDark};
|
|
31
|
+
border-bottom-color: ${this.globalVars.borderColorDark};
|
|
32
|
+
}`)}
|
|
33
|
+
|
|
34
|
+
.site-header.has-nav {
|
|
35
|
+
height: 144px;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.site-header.no-nav {
|
|
39
|
+
height: 80px;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.header-top {
|
|
43
|
+
height: 80px;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.site-header.has-nav .header-top {
|
|
47
|
+
border-bottom: 1px solid ${this.globalVars.borderColorLight};
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.header-bottom {
|
|
51
|
+
height: 64px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.header-container {
|
|
55
|
+
max-width: 100%;
|
|
56
|
+
margin: 0 auto;
|
|
57
|
+
height: 100%;
|
|
58
|
+
display: grid;
|
|
59
|
+
grid-template-columns: 1fr auto 1fr;
|
|
60
|
+
align-items: center;
|
|
61
|
+
padding: 0 ${this.globalVars.spacingXl} 0 ${this.globalVars.spacingMd};
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.mobile-menu-button {
|
|
65
|
+
display: none;
|
|
66
|
+
align-items: center;
|
|
67
|
+
justify-content: center;
|
|
68
|
+
width: 40px;
|
|
69
|
+
height: 40px;
|
|
70
|
+
padding: 0;
|
|
71
|
+
background: transparent;
|
|
72
|
+
border: none;
|
|
73
|
+
color: ${this.globalVars.textPrimaryLight};
|
|
74
|
+
cursor: pointer;
|
|
75
|
+
border-radius: ${this.globalVars.borderRadiusMd};
|
|
76
|
+
transition: background-color 0.2s ease;
|
|
77
|
+
flex-shrink: 0;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
${(0, utils_1.darkMode)(` .mobile-menu-button {
|
|
81
|
+
color: ${this.globalVars.textPrimaryDark};
|
|
82
|
+
}`)}
|
|
83
|
+
|
|
84
|
+
.mobile-menu-button:hover {
|
|
85
|
+
background: ${this.globalVars.surfaceColorLight};
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
${(0, utils_1.darkMode)(` .mobile-menu-button:hover {
|
|
89
|
+
background: ${this.globalVars.surfaceColorDark};
|
|
90
|
+
}`)}
|
|
91
|
+
|
|
92
|
+
.header-brand {
|
|
93
|
+
display: flex;
|
|
94
|
+
align-items: center;
|
|
95
|
+
justify-content: flex-start;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.header-logo-link {
|
|
99
|
+
text-decoration: none;
|
|
100
|
+
color: ${this.globalVars.textPrimaryLight};
|
|
101
|
+
font-weight: ${this.globalVars.fontWeightSemibold};
|
|
102
|
+
font-size: ${this.globalVars.fontSizeLg};
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.header-logo {
|
|
106
|
+
height: 2.5rem;
|
|
107
|
+
max-width: 250px;
|
|
108
|
+
object-fit: contain;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.header-logo-light {
|
|
112
|
+
display: block;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.header-logo-dark {
|
|
116
|
+
display: none;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
${(0, utils_1.darkMode)(` .header-logo-light {
|
|
120
|
+
display: none;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.header-logo-dark {
|
|
124
|
+
display: block;
|
|
125
|
+
}`)}
|
|
126
|
+
|
|
127
|
+
.header-search {
|
|
128
|
+
display: flex;
|
|
129
|
+
justify-content: center;
|
|
130
|
+
height: 2.2rem;
|
|
131
|
+
padding: 0 ${this.globalVars.spacingLg};
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.header-search-button {
|
|
135
|
+
display: flex;
|
|
136
|
+
align-items: center;
|
|
137
|
+
gap: ${this.globalVars.spacingSm};
|
|
138
|
+
padding: ${this.globalVars.spacingSm} ${this.globalVars.spacingMd};
|
|
139
|
+
background: ${this.globalVars.surfaceColorLight};
|
|
140
|
+
border: 1px solid ${this.globalVars.borderColorLight};
|
|
141
|
+
border-radius: ${this.globalVars.borderRadiusLg};
|
|
142
|
+
color: ${this.globalVars.textSecondaryLight};
|
|
143
|
+
cursor: pointer;
|
|
144
|
+
transition: all 0.2s ease;
|
|
145
|
+
min-width: 300px;
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
${(0, utils_1.darkMode)(` .header-search-button {
|
|
149
|
+
background: ${this.globalVars.surfaceColorDark};
|
|
150
|
+
border-color: ${this.globalVars.borderColorDark};
|
|
151
|
+
color: ${this.globalVars.textSecondaryDark};
|
|
152
|
+
}`)}
|
|
153
|
+
|
|
154
|
+
.header-search-button:hover {
|
|
155
|
+
border-color: ${vars.searchHoverBorderColorLight};
|
|
156
|
+
background: ${this.globalVars.backgroundColorLight};
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
${(0, utils_1.darkMode)(` .header-search-button:hover {
|
|
160
|
+
border-color: ${vars.searchHoverBorderColorDark};
|
|
161
|
+
background: ${this.globalVars.backgroundColorDark};
|
|
162
|
+
}`)}
|
|
163
|
+
|
|
164
|
+
.search-icon {
|
|
165
|
+
width: 16px;
|
|
166
|
+
height: 16px;
|
|
167
|
+
flex-shrink: 0;
|
|
168
|
+
color: ${this.globalVars.textSecondaryLight};
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
${(0, utils_1.darkMode)(` .search-icon {
|
|
172
|
+
color: ${this.globalVars.textSecondaryDark};
|
|
173
|
+
}`)}
|
|
174
|
+
|
|
175
|
+
.search-text {
|
|
176
|
+
flex: 1;
|
|
177
|
+
text-align: left;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.search-shortcut {
|
|
181
|
+
padding-left: 6px;
|
|
182
|
+
padding-right: 6px;
|
|
183
|
+
padding-bottom: 1px;
|
|
184
|
+
background: ${this.globalVars.surfaceColorLight};
|
|
185
|
+
font-size: ${this.globalVars.fontSizeSm};
|
|
186
|
+
font-family: ${this.globalVars.fontFamilyBase};
|
|
187
|
+
color: ${this.globalVars.textSecondaryLight};
|
|
188
|
+
font-weight: ${this.globalVars.fontWeightMedium};
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
${(0, utils_1.darkMode)(` .search-shortcut {
|
|
192
|
+
background: ${this.globalVars.surfaceColorDark};
|
|
193
|
+
color: ${this.globalVars.textSecondaryDark};
|
|
194
|
+
}`)}
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
.header-actions {
|
|
198
|
+
display: flex;
|
|
199
|
+
align-items: center;
|
|
200
|
+
gap: ${this.globalVars.spacingSm};
|
|
201
|
+
justify-content: flex-end;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
.header-nav {
|
|
205
|
+
width: 100%;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
.header-nav-list {
|
|
209
|
+
display: flex;
|
|
210
|
+
list-style: none;
|
|
211
|
+
gap: ${this.globalVars.spacingLg};
|
|
212
|
+
margin: 0;
|
|
213
|
+
padding: 0;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
.header-nav-item {
|
|
217
|
+
margin: 0;
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
.header-nav-link {
|
|
221
|
+
text-decoration: none;
|
|
222
|
+
color: ${this.globalVars.navTextColorLight};
|
|
223
|
+
padding: ${this.globalVars.spacingSm} 0;
|
|
224
|
+
transition: color 0.2s ease;
|
|
225
|
+
font-size: ${this.globalVars.fontSizeSm};
|
|
226
|
+
font-weight: ${this.globalVars.fontWeightMedium};
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
.header-nav-link:hover {
|
|
230
|
+
color: ${this.globalVars.navHoverColorLight};
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
.header-nav-link.active {
|
|
234
|
+
color: ${this.globalVars.navActiveColorLight};
|
|
235
|
+
border-bottom: 2px solid ${this.globalVars.primaryColorLight};
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
${(0, utils_1.darkMode)(` .header-nav-link {
|
|
239
|
+
color: ${this.globalVars.navTextColorDark};
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
.header-nav-link:hover {
|
|
243
|
+
color: ${this.globalVars.navHoverColorDark};
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
.header-nav-link.active {
|
|
247
|
+
color: ${this.globalVars.navActiveColorDark};
|
|
248
|
+
}`)}
|
|
249
|
+
|
|
250
|
+
${(0, utils_1.mediaQuery)('md', ` .header-search {
|
|
251
|
+
padding: 0 ${this.globalVars.spacingSm};
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
.header-search-button {
|
|
255
|
+
min-width: 200px;
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
.header-container {
|
|
259
|
+
padding: 0 ${this.globalVars.spacingMd};
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
.search-text {
|
|
263
|
+
display: none;
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
.search-shortcut {
|
|
267
|
+
display: none;
|
|
268
|
+
}`)}
|
|
269
|
+
|
|
270
|
+
${(0, utils_1.mediaQuery)('sm', ` .mobile-menu-button {
|
|
271
|
+
display: flex;
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
.header-container {
|
|
275
|
+
padding: 0 ${this.globalVars.spacingSm};
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
.header-brand {
|
|
279
|
+
flex: 1;
|
|
280
|
+
justify-content: center;
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
.header-search {
|
|
284
|
+
display: none;
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
.header-actions {
|
|
288
|
+
min-width: auto;
|
|
289
|
+
}`)}`;
|
|
290
|
+
}
|
|
291
|
+
}
|
|
292
|
+
exports.HeaderStyleGenerator = HeaderStyleGenerator;
|
|
293
|
+
//# sourceMappingURL=header.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"header.js","sourceRoot":"","sources":["../../../src/styles/components/header.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Heading with anchor link styles
|
|
3
|
+
* Headings with copyable anchor links for deep linking
|
|
4
|
+
*/
|
|
5
|
+
import { GlobalVariables } from '../types';
|
|
6
|
+
export declare class HeadingStyleGenerator {
|
|
7
|
+
private globalVars;
|
|
8
|
+
constructor(globalVars: GlobalVariables);
|
|
9
|
+
generate(userOverrides?: Record<string, string>): string;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=heading.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"heading.d.ts","sourceRoot":"","sources":["../../../src/styles/components/heading.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAQ3C,qBAAa,qBAAqB;IACpB,OAAO,CAAC,UAAU;gBAAV,UAAU,EAAE,eAAe;IAE/C,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,MAAM;CA0GzD"}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Heading with anchor link styles
|
|
4
|
+
* Headings with copyable anchor links for deep linking
|
|
5
|
+
*/
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.HeadingStyleGenerator = void 0;
|
|
8
|
+
const utils_1 = require("../utils");
|
|
9
|
+
class HeadingStyleGenerator {
|
|
10
|
+
constructor(globalVars) {
|
|
11
|
+
this.globalVars = globalVars;
|
|
12
|
+
}
|
|
13
|
+
generate(userOverrides) {
|
|
14
|
+
const defaults = {
|
|
15
|
+
anchorLinkColor: this.globalVars.textSecondaryLight,
|
|
16
|
+
anchorLinkColorDark: this.globalVars.textSecondaryDark,
|
|
17
|
+
};
|
|
18
|
+
const vars = (0, utils_1.mergeOverrides)(defaults, userOverrides, ['anchorLinkColor', 'anchorLinkColorDark']);
|
|
19
|
+
return `/* Heading with Anchor Link */
|
|
20
|
+
.heading-with-anchor {
|
|
21
|
+
position: relative;
|
|
22
|
+
scroll-margin-top: calc(${this.globalVars.headerHeight} + ${this.globalVars.spacingMd});
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.heading-anchor-link {
|
|
26
|
+
position: absolute;
|
|
27
|
+
left: -1.5rem;
|
|
28
|
+
opacity: 0;
|
|
29
|
+
padding: 0.25rem;
|
|
30
|
+
background: transparent;
|
|
31
|
+
border: none;
|
|
32
|
+
color: ${vars.anchorLinkColor};
|
|
33
|
+
cursor: pointer;
|
|
34
|
+
transition: opacity 0.2s ease, background-color 0.2s ease;
|
|
35
|
+
display: inline-flex;
|
|
36
|
+
align-items: center;
|
|
37
|
+
justify-content: center;
|
|
38
|
+
border-radius: ${this.globalVars.borderRadiusSm};
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
${(0, utils_1.darkMode)(` .heading-anchor-link {
|
|
42
|
+
color: ${vars.anchorLinkColorDark};
|
|
43
|
+
}`)}
|
|
44
|
+
|
|
45
|
+
.heading-anchor-link:hover {
|
|
46
|
+
opacity: 1;
|
|
47
|
+
background-color: ${this.globalVars.surfaceColorLight};
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
${(0, utils_1.darkMode)(` .heading-anchor-link:hover {
|
|
51
|
+
background-color: ${this.globalVars.surfaceColorDark};
|
|
52
|
+
}`)}
|
|
53
|
+
|
|
54
|
+
.heading-with-anchor:hover .heading-anchor-link {
|
|
55
|
+
opacity: 0.7;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.heading-with-anchor:hover .heading-anchor-link:hover {
|
|
59
|
+
opacity: 1;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.heading-anchor-link:focus-visible {
|
|
63
|
+
opacity: 1;
|
|
64
|
+
outline: 2px solid ${vars.anchorLinkColor};
|
|
65
|
+
outline-offset: 2px;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
${(0, utils_1.darkMode)(` .heading-anchor-link:focus-visible {
|
|
69
|
+
outline-color: ${vars.anchorLinkColorDark};
|
|
70
|
+
}`)}
|
|
71
|
+
|
|
72
|
+
.heading-copied-tooltip {
|
|
73
|
+
position: absolute;
|
|
74
|
+
left: 50%;
|
|
75
|
+
top: 100%;
|
|
76
|
+
transform: translateX(-50%);
|
|
77
|
+
margin-top: 0.5rem;
|
|
78
|
+
padding: 0.25rem 0.5rem;
|
|
79
|
+
background-color: ${this.globalVars.textSecondaryLight};
|
|
80
|
+
color: ${this.globalVars.backgroundColorLight};
|
|
81
|
+
font-size: ${this.globalVars.fontSizeSm};
|
|
82
|
+
border-radius: ${this.globalVars.borderRadiusMd};
|
|
83
|
+
white-space: nowrap;
|
|
84
|
+
pointer-events: none;
|
|
85
|
+
font-family: ${this.globalVars.fontFamilyBase};
|
|
86
|
+
font-weight: ${this.globalVars.fontWeightNormal};
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
${(0, utils_1.darkMode)(` .heading-copied-tooltip {
|
|
90
|
+
background-color: ${this.globalVars.textSecondaryDark};
|
|
91
|
+
color: ${this.globalVars.backgroundColorDark};
|
|
92
|
+
}`)}
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
@media (hover: none) and (pointer: coarse) {
|
|
96
|
+
.heading-anchor-link {
|
|
97
|
+
opacity: 0.6;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.heading-with-anchor:active .heading-anchor-link {
|
|
101
|
+
opacity: 1;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
${(0, utils_1.mediaQuery)('md', ` .heading-anchor-link {
|
|
106
|
+
position: relative;
|
|
107
|
+
left: auto;
|
|
108
|
+
margin-left: 0.5rem;
|
|
109
|
+
display: inline-flex;
|
|
110
|
+
vertical-align: middle;
|
|
111
|
+
}`)}`;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
exports.HeadingStyleGenerator = HeadingStyleGenerator;
|
|
115
|
+
//# sourceMappingURL=heading.js.map
|