radiant-docs 0.1.37 → 0.1.39
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/package.json +1 -1
- package/template/astro.config.mjs +2 -0
- package/template/src/components/Footer.astro +1 -1
- package/template/src/components/Header.astro +8 -8
- package/template/src/components/OpenApiPage.astro +18 -18
- package/template/src/components/Search.astro +18 -18
- package/template/src/components/Sidebar.astro +4 -2
- package/template/src/components/SidebarDropdown.astro +82 -79
- package/template/src/components/SidebarSegmented.astro +5 -5
- package/template/src/components/TableOfContents.astro +24 -15
- package/template/src/components/ThemeSwitcher.astro +15 -8
- package/template/src/components/chat/AskAiWidget.tsx +4 -3
- package/template/src/components/endpoint/PlaygroundBar.astro +3 -3
- package/template/src/components/endpoint/PlaygroundButton.astro +2 -2
- package/template/src/components/endpoint/PlaygroundField.astro +53 -53
- package/template/src/components/endpoint/PlaygroundForm.astro +38 -22
- package/template/src/components/endpoint/RequestSnippets.astro +54 -21
- package/template/src/components/endpoint/ResponseDisplay.astro +24 -24
- package/template/src/components/endpoint/ResponseFieldTree.astro +12 -12
- package/template/src/components/endpoint/ResponseFields.astro +19 -19
- package/template/src/components/endpoint/ResponseSnippets.astro +66 -29
- package/template/src/components/ui/CodeTabEdge.astro +6 -4
- package/template/src/components/ui/Field.astro +7 -7
- package/template/src/components/ui/demo/Demo.astro +1 -1
- package/template/src/components/user/Accordion.astro +3 -3
- package/template/src/components/user/Callout.astro +8 -8
- package/template/src/components/user/CodeBlock.astro +63 -25
- package/template/src/components/user/CodeGroup.astro +259 -22
- package/template/src/components/user/ComponentPreviewBlock.astro +36 -10
- package/template/src/components/user/Image.astro +2 -2
- package/template/src/components/user/Step.astro +4 -4
- package/template/src/components/user/Tab.astro +1 -1
- package/template/src/components/user/Tabs.astro +142 -42
- package/template/src/layouts/Layout.astro +1 -1
- package/template/src/lib/code/code-block.ts +150 -15
- package/template/src/lib/mdx/remark-resolve-internal-links.ts +639 -0
- package/template/src/pages/404.astro +44 -0
- package/template/src/styles/global.css +51 -19
|
@@ -55,6 +55,9 @@
|
|
|
55
55
|
--border-light: var(--color-neutral-100);
|
|
56
56
|
--input: oklch(0.922 0 0);
|
|
57
57
|
--ring: oklch(0.708 0 0);
|
|
58
|
+
--rd-code-surface: #ffffff;
|
|
59
|
+
--rd-code-tab-edge-bg: var(--rd-code-surface);
|
|
60
|
+
--rd-code-tab-edge-border: var(--color-neutral-200);
|
|
58
61
|
}
|
|
59
62
|
|
|
60
63
|
/* 3. Dark Mode */
|
|
@@ -77,6 +80,13 @@
|
|
|
77
80
|
--border-light: color-mix(in srgb, var(--color-neutral-800) 50%, transparent);
|
|
78
81
|
--input: oklch(1 0 0 / 15%);
|
|
79
82
|
--ring: oklch(0.556 0 0);
|
|
83
|
+
--rd-code-surface: color-mix(
|
|
84
|
+
in srgb,
|
|
85
|
+
var(--color-neutral-800) 55%,
|
|
86
|
+
var(--color-neutral-900) 45%
|
|
87
|
+
);
|
|
88
|
+
--rd-code-tab-edge-bg: var(--rd-code-surface);
|
|
89
|
+
--rd-code-tab-edge-border: var(--color-neutral-800);
|
|
80
90
|
}
|
|
81
91
|
|
|
82
92
|
@variant dark (&:where(.dark, .dark *));
|
|
@@ -141,9 +151,42 @@
|
|
|
141
151
|
}
|
|
142
152
|
}
|
|
143
153
|
|
|
154
|
+
/* Markdown table styling */
|
|
155
|
+
.prose-rules :where(table) {
|
|
156
|
+
@apply w-full overflow-hidden rounded-xl border border-neutral-200 shadow-xs dark:border-neutral-800;
|
|
157
|
+
border-collapse: separate;
|
|
158
|
+
border-spacing: 0;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.prose-rules :where(thead th) {
|
|
162
|
+
@apply bg-neutral-50 dark:bg-neutral-900/60;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.prose-rules :where(th, td) {
|
|
166
|
+
@apply border-b border-neutral-200 px-4 py-2 align-top dark:border-neutral-800;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
.prose-rules :where(th + th, td + td) {
|
|
170
|
+
@apply border-l border-neutral-200 dark:border-neutral-800;
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
.prose-rules :where(tbody tr:last-child td) {
|
|
174
|
+
@apply border-b-0;
|
|
175
|
+
}
|
|
176
|
+
|
|
144
177
|
/* Code single-line styling */
|
|
145
178
|
:is(.prose, .prose-rules) :not(pre) > code {
|
|
146
|
-
@apply px-1 py-px bg-neutral-100/90 text-neutral-600 rounded-md font-mono font-medium border border-neutral-200/80 after:hidden before:hidden;
|
|
179
|
+
@apply px-1 py-px bg-neutral-100/90 text-neutral-600 rounded-md font-mono font-medium border border-neutral-200/80 after:hidden before:hidden dark:bg-neutral-800/80 dark:text-neutral-200 dark:border-neutral-700/80;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
[data-rd-code-theme] [data-rd-token] {
|
|
183
|
+
color: var(--rd-token-color, currentColor);
|
|
184
|
+
background-color: var(--rd-token-bg, transparent);
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.dark [data-rd-code-theme] [data-rd-token] {
|
|
188
|
+
color: var(--rd-token-color-dark, var(--rd-token-color, currentColor));
|
|
189
|
+
background-color: var(--rd-token-bg-dark, var(--rd-token-bg, transparent));
|
|
147
190
|
}
|
|
148
191
|
|
|
149
192
|
/* Keep nested blockquote content flush with the quote container edges */
|
|
@@ -203,22 +246,11 @@
|
|
|
203
246
|
);
|
|
204
247
|
}
|
|
205
248
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
--theme-transition: 200ms; /* Set your desired sync speed */
|
|
214
|
-
|
|
215
|
-
transition-duration: var(--theme-transition) !important;
|
|
216
|
-
transition-property:
|
|
217
|
-
background-color, border-color, color, fill, stroke !important;
|
|
218
|
-
}
|
|
219
|
-
/* Ensure the pill slider is NOT affected by the forced color duration
|
|
220
|
-
so its movement remains independent */
|
|
221
|
-
.is-switching-theme .anchor-pill {
|
|
222
|
-
transition-duration: 200ms !important;
|
|
223
|
-
transition-property: left, width, background-color !important;
|
|
249
|
+
/* While toggling the root theme class, disable transitions for one frame
|
|
250
|
+
so all dark/light styles flip atomically. */
|
|
251
|
+
.is-switching-theme *,
|
|
252
|
+
.is-switching-theme *::before,
|
|
253
|
+
.is-switching-theme *::after {
|
|
254
|
+
transition-duration: 0ms !important;
|
|
255
|
+
transition-delay: 0ms !important;
|
|
224
256
|
}
|