varvara-typedoc-theme 0.3.1 → 0.3.3
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 +11 -10
- package/assets/overrides.css +21 -15
- package/dist/index.js +19 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -6,6 +6,7 @@ Varvara TypeDoc Theme is a custom theme for TypeDoc, designed to provide a seaml
|
|
|
6
6
|
|
|
7
7
|
[](https://www.npmjs.com/package/varvara-typedoc-theme)
|
|
8
8
|
[](https://github.com/marcmarine/varvara-js/blob/main/LICENSE)
|
|
9
|
+
[](https://github.com/marcmarine/varvara-js/blob/main/packages/typedoc-theme/CHANGELOG.md)
|
|
9
10
|
|
|
10
11
|
## Installation
|
|
11
12
|
|
|
@@ -24,7 +25,7 @@ npm install varvara-typedoc-theme --save-dev
|
|
|
24
25
|
Use the following command to generate documentation with the Varvara theme:
|
|
25
26
|
|
|
26
27
|
```bash
|
|
27
|
-
npx typedoc --plugin varvara-typedoc-theme --theme varvara
|
|
28
|
+
npx typedoc --plugin varvara-typedoc-theme --theme varvara-css
|
|
28
29
|
```
|
|
29
30
|
|
|
30
31
|
### Method 2: Configuration File
|
|
@@ -41,7 +42,7 @@ const config = {
|
|
|
41
42
|
plugin: ['varvara-typedoc-theme'],
|
|
42
43
|
|
|
43
44
|
// Set the theme to Varvara
|
|
44
|
-
theme: 'varvara',
|
|
45
|
+
theme: 'varvara-css',
|
|
45
46
|
|
|
46
47
|
// Optional: Include version information
|
|
47
48
|
includeVersion: true
|
|
@@ -71,31 +72,31 @@ Varvara CSS provides variables to customize the theme appearance:
|
|
|
71
72
|
|
|
72
73
|
@media (prefers-color-scheme: light) {
|
|
73
74
|
:root {
|
|
74
|
-
--va-color-
|
|
75
|
-
--va-color-
|
|
75
|
+
--va-foreground-color-default: DimGray;
|
|
76
|
+
--va-background-color-default: WhiteSmoke;
|
|
76
77
|
--va-border-color: Gainsboro;
|
|
77
78
|
--va-space-ratio: 0.5;
|
|
78
79
|
}
|
|
79
80
|
}
|
|
80
81
|
@media (prefers-color-scheme: dark) {
|
|
81
82
|
:root {
|
|
82
|
-
--va-color-
|
|
83
|
-
--va-color-
|
|
83
|
+
--va-foreground-color-default: Silver;
|
|
84
|
+
--va-background-color-default: MidnightBlue;
|
|
84
85
|
--va-border-color: RoyalBlue;
|
|
85
86
|
--va-space-ratio: 0.5;
|
|
86
87
|
}
|
|
87
88
|
}
|
|
88
89
|
|
|
89
90
|
[data-theme='light'] {
|
|
90
|
-
--va-color-
|
|
91
|
-
--va-color-
|
|
91
|
+
--va-foreground-color-default: DimGray;
|
|
92
|
+
--va-background-color-default: WhiteSmoke;
|
|
92
93
|
--va-border-color: Gainsboro;
|
|
93
94
|
--va-space-ratio: 0.5;
|
|
94
95
|
}
|
|
95
96
|
|
|
96
97
|
[data-theme='dark'] {
|
|
97
|
-
--va-color-
|
|
98
|
-
--va-color-
|
|
98
|
+
--va-foreground-color-default: Silver;
|
|
99
|
+
--va-background-color-default: MidnightBlue;
|
|
99
100
|
--va-border-color: RoyalBlue;
|
|
100
101
|
--va-space-ratio: 0.5;
|
|
101
102
|
}
|
package/assets/overrides.css
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
:root {
|
|
2
|
+
--va-link-color: var(--va-color-primary);
|
|
3
|
+
}
|
|
4
|
+
|
|
1
5
|
[data-theme='light'] {
|
|
2
6
|
color-scheme: light;
|
|
3
7
|
}
|
|
@@ -23,11 +27,6 @@
|
|
|
23
27
|
flex: 1;
|
|
24
28
|
}
|
|
25
29
|
|
|
26
|
-
body {
|
|
27
|
-
background-color: var(--va-color-background);
|
|
28
|
-
color: var(--va-color-foreground);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
30
|
a {
|
|
32
31
|
color: var(--va-color-primary);
|
|
33
32
|
}
|
|
@@ -40,8 +39,8 @@ a {
|
|
|
40
39
|
position: absolute;
|
|
41
40
|
right: 0;
|
|
42
41
|
bottom: 0;
|
|
43
|
-
background-color: var(--va-
|
|
44
|
-
color: var(--va-color-
|
|
42
|
+
background-color: var(--va-foreground-color-muted);
|
|
43
|
+
color: var(--va-background-color-default);
|
|
45
44
|
padding: var(--va-space-1);
|
|
46
45
|
font-size: var(--va-font-size-0);
|
|
47
46
|
}
|
|
@@ -61,7 +60,7 @@ a {
|
|
|
61
60
|
}
|
|
62
61
|
|
|
63
62
|
dialog {
|
|
64
|
-
background-color: var(--va-color-
|
|
63
|
+
background-color: var(--va-background-color-default);
|
|
65
64
|
}
|
|
66
65
|
|
|
67
66
|
.navigation-links a span {
|
|
@@ -95,7 +94,7 @@ footer {
|
|
|
95
94
|
}
|
|
96
95
|
|
|
97
96
|
.container {
|
|
98
|
-
padding: 0 var(--va-space-
|
|
97
|
+
padding: 0 var(--va-space-4);
|
|
99
98
|
}
|
|
100
99
|
|
|
101
100
|
@media (max-width: 769px) {
|
|
@@ -109,7 +108,7 @@ footer {
|
|
|
109
108
|
flex-direction: column;
|
|
110
109
|
}
|
|
111
110
|
html .col-sidebar {
|
|
112
|
-
background-color: var(--va-color-
|
|
111
|
+
background-color: var(--va-background-color-default);
|
|
113
112
|
}
|
|
114
113
|
}
|
|
115
114
|
|
|
@@ -117,30 +116,37 @@ footer {
|
|
|
117
116
|
.container-main {
|
|
118
117
|
grid-template-areas: 'header content' 'sidebar content';
|
|
119
118
|
grid-auto-rows: auto 1fr;
|
|
120
|
-
margin: var(--va-space-
|
|
119
|
+
margin: var(--va-space-6) auto;
|
|
121
120
|
}
|
|
121
|
+
|
|
122
122
|
.container {
|
|
123
|
-
padding: 0 var(--va-space-
|
|
123
|
+
padding: 0 var(--va-space-6);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
#tsd-toolbar-menu-trigger {
|
|
127
|
+
display: none;
|
|
124
128
|
}
|
|
125
129
|
}
|
|
126
130
|
|
|
127
131
|
@media (min-width: 1200px) {
|
|
128
132
|
.container-main {
|
|
129
|
-
grid-template-columns: minmax(0,
|
|
133
|
+
grid-template-columns: minmax(0, 20rem) minmax(0, 2.5fr) minmax(0, 20rem);
|
|
130
134
|
grid-template-areas:
|
|
131
135
|
'header content toc'
|
|
132
136
|
'sidebar content toc';
|
|
133
137
|
}
|
|
134
138
|
.page-menu,
|
|
135
139
|
.site-menu {
|
|
136
|
-
top: var(--va-space-
|
|
137
|
-
max-height: calc(100vh - calc(var(--va-space-
|
|
140
|
+
top: var(--va-space-6);
|
|
141
|
+
max-height: calc(100vh - calc(var(--va-space-6) * 2));
|
|
138
142
|
}
|
|
139
143
|
}
|
|
140
144
|
|
|
141
145
|
@media (min-width: 770px) and (max-width: 1399px) {
|
|
142
146
|
.col-sidebar {
|
|
147
|
+
top: var(--va-space-6);
|
|
143
148
|
padding-top: 0;
|
|
149
|
+
max-height: calc(100vh - calc(var(--va-space-6) * 2));
|
|
144
150
|
}
|
|
145
151
|
.page-menu {
|
|
146
152
|
margin-bottom: 1rem;
|
package/dist/index.js
CHANGED
|
@@ -29,9 +29,11 @@ function footer(context) {
|
|
|
29
29
|
class: "tsd-generator"
|
|
30
30
|
}, pre, /* @__PURE__ */ JSX.createElement("a", {
|
|
31
31
|
href: "https://typedoc.org/",
|
|
32
|
+
class: "va-link",
|
|
32
33
|
target: "_blank"
|
|
33
34
|
}, "TypeDoc"), " & ", /* @__PURE__ */ JSX.createElement("a", {
|
|
34
35
|
href: "https://varvara.js.org/",
|
|
36
|
+
class: "va-link",
|
|
35
37
|
target: "_blank"
|
|
36
38
|
}, "Varvara CSS"), post);
|
|
37
39
|
}
|
|
@@ -221,6 +223,22 @@ function toolbar(context) {
|
|
|
221
223
|
stroke: "currentColor"
|
|
222
224
|
}, /* @__PURE__ */ JSX4.createElement("path", {
|
|
223
225
|
d: "m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z"
|
|
226
|
+
}))), /* @__PURE__ */ JSX4.createElement("a", {
|
|
227
|
+
href: "#",
|
|
228
|
+
class: "va-button",
|
|
229
|
+
id: "tsd-toolbar-menu-trigger",
|
|
230
|
+
"data-toggle": "menu",
|
|
231
|
+
"aria-label": i18n4.theme_menu()
|
|
232
|
+
}, /* @__PURE__ */ JSX4.createElement("svg", {
|
|
233
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
234
|
+
fill: "none",
|
|
235
|
+
viewBox: "0 0 24 24",
|
|
236
|
+
"stroke-width": "2.5",
|
|
237
|
+
width: "16",
|
|
238
|
+
height: "16",
|
|
239
|
+
stroke: "currentColor"
|
|
240
|
+
}, /* @__PURE__ */ JSX4.createElement("path", {
|
|
241
|
+
d: "M3.75 9h16.5m-16.5 6.75h16.5"
|
|
224
242
|
})))), /* @__PURE__ */ JSX4.createElement("div", {
|
|
225
243
|
class: "navigation-links va-button-group"
|
|
226
244
|
}, Object.entries(context.options.getValue("navigationLinks")).map(([label, url]) => /* @__PURE__ */ JSX4.createElement("a", {
|
|
@@ -458,7 +476,7 @@ class VarvaraTheme extends DefaultTheme2 {
|
|
|
458
476
|
|
|
459
477
|
// src/index.tsx
|
|
460
478
|
function load(app) {
|
|
461
|
-
app.renderer.defineTheme("varvara", VarvaraTheme);
|
|
479
|
+
app.renderer.defineTheme("varvara-css", VarvaraTheme);
|
|
462
480
|
}
|
|
463
481
|
export {
|
|
464
482
|
load
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "varvara-typedoc-theme",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.3",
|
|
4
4
|
"author": "Marc Mariné <shenobi@gmail.com>",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
],
|
|
16
16
|
"license": "MIT",
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"varvara-css": "^0.
|
|
18
|
+
"varvara-css": "^0.7.0"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
21
|
"@types/bun": "latest"
|