@lukoweb/apitogo 0.2.56 → 0.2.57

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.
Files changed (80) hide show
  1. package/dist/cli/cli.js +1026 -540
  2. package/dist/declarations/cli/platform/client/platform-api.d.ts +6 -0
  3. package/dist/declarations/config/validators/ZudokuConfig.d.ts +2 -0
  4. package/dist/declarations/lib/authentication/providers/openid.d.ts +2 -1
  5. package/dist/declarations/lib/plugins/markdown/index.d.ts +2 -1
  6. package/dist/flat-config.d.ts +1 -0
  7. package/docs/cli/commands.md +50 -32
  8. package/docs/cli/go-live.md +66 -93
  9. package/docs/cli/overview.md +18 -17
  10. package/docs/cli/setup.md +130 -141
  11. package/docs/cli/shape.md +94 -11
  12. package/docs/components/slot.mdx +116 -119
  13. package/docs/configuration/api-reference.md +98 -397
  14. package/docs/configuration/authentication.md +118 -159
  15. package/docs/configuration/footer.mdx +89 -118
  16. package/docs/configuration/make-config.mdx +2 -2
  17. package/docs/configuration/overview.md +97 -166
  18. package/docs/configuration/plans.md +100 -110
  19. package/docs/configuration/portal.md +116 -0
  20. package/docs/customization/colors-theme.mdx +255 -278
  21. package/docs/customization/fonts.md +105 -110
  22. package/docs/customization/landing-page.md +189 -188
  23. package/docs/deploy/apitogo.md +13 -17
  24. package/docs/deployment.md +15 -9
  25. package/docs/guides/stripe-setup.mdx +123 -0
  26. package/docs/markdown/frontmatter.md +172 -173
  27. package/docs/mcp/go-live.md +100 -100
  28. package/docs/mcp/overview.md +76 -76
  29. package/docs/quickstart.md +88 -72
  30. package/docs/writing.mdx +68 -72
  31. package/package.json +1 -1
  32. package/src/config/v2/docs-navigation.ts +7 -2
  33. package/src/config/v2/index.ts +1 -0
  34. package/src/config/v2/resolve.ts +28 -0
  35. package/src/config/v2/rules.ts +32 -1
  36. package/src/config/v2/schema.ts +9 -0
  37. package/src/config/v2/services.ts +78 -2
  38. package/src/config/v2/starter-landing.ts +41 -0
  39. package/src/config/v2/wrapper.ts +127 -7
  40. package/src/config/validators/ZudokuConfig.ts +794 -792
  41. package/src/lib/authentication/providers/openid.tsx +6 -1
  42. package/src/lib/plugins/markdown/index.tsx +86 -82
  43. package/src/vite/dev-server.ts +9 -1
  44. package/src/vite/dev-ssr-config.ts +32 -0
  45. package/src/vite/plugin-config.ts +4 -2
  46. package/src/vite/plugin-docs.ts +213 -205
  47. package/docs/concepts/auth-provider-api-identities.md +0 -105
  48. package/docs/configuration/ai-assistants.md +0 -65
  49. package/docs/configuration/api-catalog.md +0 -109
  50. package/docs/configuration/authentication-auth0.md +0 -181
  51. package/docs/configuration/authentication-azure-ad.md +0 -245
  52. package/docs/configuration/authentication-clerk.md +0 -117
  53. package/docs/configuration/authentication-firebase.md +0 -69
  54. package/docs/configuration/authentication-pingfederate.md +0 -143
  55. package/docs/configuration/authentication-supabase.md +0 -233
  56. package/docs/configuration/build-configuration.mdx +0 -147
  57. package/docs/configuration/docs.md +0 -282
  58. package/docs/configuration/llms.md +0 -90
  59. package/docs/configuration/manifest.md +0 -129
  60. package/docs/configuration/navigation.mdx +0 -415
  61. package/docs/configuration/protected-routes.md +0 -150
  62. package/docs/configuration/search.md +0 -164
  63. package/docs/configuration/sentry.mdx +0 -44
  64. package/docs/configuration/site.md +0 -124
  65. package/docs/configuration/slots.mdx +0 -125
  66. package/docs/configuration/vite-config.md +0 -18
  67. package/docs/custom-plugins.md +0 -285
  68. package/docs/deploy/apache-nginx.md +0 -41
  69. package/docs/deploy/cloudflare-pages.md +0 -74
  70. package/docs/deploy/direct-upload.md +0 -17
  71. package/docs/deploy/github-pages.md +0 -49
  72. package/docs/deploy/vercel.md +0 -101
  73. package/docs/extending/events.md +0 -124
  74. package/docs/guides/environment-variables.md +0 -94
  75. package/docs/guides/managing-api-keys-and-identities.md +0 -89
  76. package/docs/guides/navigation-rules.mdx +0 -203
  77. package/docs/guides/processors.mdx +0 -234
  78. package/docs/guides/transforming-examples.md +0 -156
  79. package/docs/guides/using-multiple-apis.md +0 -87
  80. package/docs/plugins.md +0 -24
@@ -1,278 +1,255 @@
1
- ---
2
- sidebar_icon: paintbrush
3
- title: Colors & Theme
4
- description:
5
- Customize your APIToGo site's colors and theme with flexible options, including light/dark modes,
6
- custom CSS, and shadcn registry integration.
7
- ---
8
-
9
- APIToGo provides flexible theming options allowing you to customize colors, import themes from
10
- [shadcn registries](https://ui.shadcn.com/docs/registry), and add custom CSS. You can create
11
- cohesive light and dark mode experiences that match your brand.
12
-
13
- :::tip
14
-
15
- Try out the interactive [Theme Playground](/docs/theme-playground) to experiment with colors and see
16
- real-time previews of your theme changes.
17
-
18
- :::
19
-
20
- The theme system is built on [shadcn/ui theming](https://ui.shadcn.com/docs/theming) and
21
- [Tailwind v4](https://tailwindcss.com), giving us a great foundation to build upon:
22
-
23
- - **CSS variables** match `shadcn/ui` conventions
24
- - **Tailwind v4** CSS variable system for modern styling
25
- - **Theme editors** like [tweakcn](https://tweakcn.com/) work out of the box
26
- - **Shadcn registries** are supported
27
- - **Landing homepage**, **portal footer**, and **MCP-generated custom pages** all use the same
28
- semantic tokens (`bg-primary`, `text-muted-foreground`, `border-border`, etc.)
29
-
30
- ## Custom Colors
31
-
32
- You can manually define colors for both light and dark modes, either by extending the
33
- [default theme](#default-theme) or creating a completely custom theme. Colors can be specified as
34
- hex values, RGB, HSL, OKLCH, etc. - basically anything that is supported by
35
- [Tailwind CSS](https://tailwindcss.com):
36
-
37
- ```ts title=config
38
- const config = {
39
- theme: {
40
- light: {
41
- background: "#ffffff",
42
- foreground: "#020817",
43
- card: "#ffffff",
44
- cardForeground: "#020817",
45
- popover: "#ffffff",
46
- popoverForeground: "#020817",
47
- primary: "#0284c7",
48
- primaryForeground: "#ffffff",
49
- secondary: "#f1f5f9",
50
- secondaryForeground: "#020817",
51
- muted: "#f1f5f9",
52
- mutedForeground: "#64748b",
53
- accent: "#f1f5f9",
54
- accentForeground: "#020817",
55
- destructive: "#ef4444",
56
- destructiveForeground: "#ffffff",
57
- border: "#e2e8f0",
58
- input: "#e2e8f0",
59
- ring: "#0284c7",
60
- radius: "0.5rem",
61
- },
62
- dark: {
63
- background: "#020817",
64
- foreground: "#f8fafc",
65
- card: "#020817",
66
- cardForeground: "#f8fafc",
67
- popover: "#020817",
68
- popoverForeground: "#f8fafc",
69
- primary: "#0ea5e9",
70
- primaryForeground: "#f8fafc",
71
- secondary: "#1e293b",
72
- secondaryForeground: "#f8fafc",
73
- muted: "#1e293b",
74
- mutedForeground: "#94a3b8",
75
- accent: "#1e293b",
76
- accentForeground: "#f8fafc",
77
- destructive: "#ef4444",
78
- destructiveForeground: "#f8fafc",
79
- border: "#1e293b",
80
- input: "#1e293b",
81
- ring: "#0ea5e9",
82
- radius: "0.5rem",
83
- },
84
- },
85
- };
86
- ```
87
-
88
- ## Available Theme Variables
89
-
90
- | Variable | Description |
91
- | ----------------------- | ------------------------------------- |
92
- | `background` | Main background color |
93
- | `foreground` | Main text color |
94
- | `card` | Card background color |
95
- | `cardForeground` | Card text color |
96
- | `popover` | Popover background color |
97
- | `popoverForeground` | Popover text color |
98
- | `primary` | Primary action color |
99
- | `primaryForeground` | Text color on primary backgrounds |
100
- | `secondary` | Secondary action color |
101
- | `secondaryForeground` | Text color on secondary backgrounds |
102
- | `muted` | Muted/subtle background color |
103
- | `mutedForeground` | Text color for muted elements |
104
- | `accent` | Accent color for highlights |
105
- | `accentForeground` | Text color on accent backgrounds |
106
- | `destructive` | Color for destructive actions |
107
- | `destructiveForeground` | Text color on destructive backgrounds |
108
- | `border` | Border color |
109
- | `input` | Input field border color |
110
- | `ring` | Focus ring color |
111
- | `radius` | Border radius value |
112
-
113
- :::note
114
-
115
- While shadcn/ui defines additional theme variables, APIToGo currently uses only these core
116
- variables.
117
-
118
- :::
119
-
120
- ## shadcn Registry Integration
121
-
122
- The easiest way to customize your theme is by using a Shadcn registry theme. For example you can use
123
- the great [tweakcn](https://tweakcn.com/) visual theme editor.
124
-
125
- ### Using tweakcn Themes
126
-
127
- <Stepper>
128
-
129
- 1. Visit [tweakcn.com](https://tweakcn.com/) to select a preset or customize your theme visually
130
-
131
- <Framed align="start">![](./tweakcn0.webp)</Framed>
132
- <Framed align="start">![](./tweakcn1.webp)</Framed>
133
-
134
- 1. Copy the registry URL from the "Copy" section
135
-
136
- <Framed align="start">![](./tweakcn2.webp)</Framed>
137
-
138
- 1. Add it to your configuration:
139
- ```ts title=config
140
- const config = {
141
- theme: {
142
- registryUrl: "https://tweakcn.com/r/themes/northern-lights.json",
143
- },
144
- };
145
- ```
146
- 1. The theme will then be automatically imported with all color variables, fonts, and styling
147
- configured for you 🚀
148
-
149
- <Framed align="start">![](/tweakcn-northlight.png)</Framed>
150
-
151
- </Stepper>
152
-
153
- You can still override specific values if needed:
154
-
155
- ```ts title=config
156
- const config = {
157
- theme: {
158
- registryUrl: "https://tweakcn.com/api/registry/theme/xyz123",
159
- // Override specific colors
160
- light: {
161
- primary: "#0066cc",
162
- },
163
- dark: {
164
- primary: "#3399ff",
165
- },
166
- },
167
- };
168
- ```
169
-
170
- Alternatively, you can copy the CSS code and paste it into your `customCss` configuration:
171
-
172
- ```ts title=config
173
- const config = {
174
- theme: {
175
- customCss: `
176
- /* Copied CSS code */
177
- `,
178
- },
179
- };
180
- ```
181
-
182
- ## Custom CSS
183
-
184
- For advanced styling, you can add custom CSS either as a string or structured object:
185
-
186
- :::note
187
-
188
- Changes to `customCss` require restarting the development server to take effect.
189
-
190
- :::
191
-
192
- ### CSS String
193
-
194
- ```ts title=config
195
- const config = {
196
- theme: {
197
- customCss: `
198
- .custom {
199
- background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
200
- }
201
- `,
202
- },
203
- };
204
- ```
205
-
206
- ### CSS Object
207
-
208
- ```ts title=config
209
- const config = {
210
- theme: {
211
- customCss: {
212
- ".custom": {
213
- background: "linear-gradient(135deg, #667eea 0%, #764ba2 100%)",
214
- },
215
- },
216
- },
217
- };
218
- ```
219
-
220
- ## Default Theme
221
-
222
- APIToGo comes with a built-in default theme based on
223
- [shadcn/ui zinc base colors](https://ui.shadcn.com/docs/theming#zinc). If you want to start
224
- completely from scratch without any default styling, you can disable the default theme:
225
-
226
- ```ts title=config
227
- const config = {
228
- theme: {
229
- noDefaultTheme: true,
230
- // Your custom theme configuration
231
- },
232
- };
233
- ```
234
-
235
- When `noDefaultTheme` is set to `true`, no default colors or styling will be applied, giving you
236
- complete control over your theme. Changing this requires to restart the development server.
237
-
238
- ## Complete Example
239
-
240
- Here's a comprehensive example combining multiple theming approaches:
241
-
242
- ```ts title=config
243
- const config = {
244
- theme: {
245
- // Import base theme from registry
246
- registryUrl: "https://tweakcn.com/api/registry/theme/modern-blue",
247
-
248
- // Override specific colors
249
- light: {
250
- primary: "#0066cc",
251
- accent: "#f0f9ff",
252
- },
253
- dark: {
254
- primary: "#3399ff",
255
- accent: "#0c1b2e",
256
- },
257
-
258
- // Custom fonts
259
- fonts: {
260
- sans: "Inter",
261
- mono: "JetBrains Mono",
262
- },
263
-
264
- // Additional custom styling
265
- customCss: {
266
- ".hero-section": {
267
- background: "var(--primary)",
268
- color: "var(--primary-foreground)",
269
- padding: "2rem",
270
- "border-radius": "var(--radius)",
271
- },
272
- },
273
- },
274
- };
275
- ```
276
-
277
- This configuration imports a base theme, customizes colors for both light and dark modes, sets
278
- fonts, and adds custom component styling.
1
+ ---
2
+ sidebar_icon: paintbrush
3
+ title: Colors & Theme
4
+ description:
5
+ Customize your APIToGo site's colors and theme with flexible options, including light/dark modes,
6
+ custom CSS, and shadcn registry integration.
7
+ ---
8
+
9
+ APIToGo provides flexible theming options allowing you to customize colors, import themes from
10
+ [shadcn registries](https://ui.shadcn.com/docs/registry), and add custom CSS. You can create
11
+ cohesive light and dark mode experiences that match your brand.
12
+
13
+ :::tip
14
+
15
+ Try out the interactive [Theme Playground](/docs/theme-playground) to experiment with colors and see
16
+ real-time previews of your theme changes.
17
+
18
+ :::
19
+
20
+ The theme system is built on [shadcn/ui theming](https://ui.shadcn.com/docs/theming) and
21
+ [Tailwind v4](https://tailwindcss.com), giving us a great foundation to build upon:
22
+
23
+ - **CSS variables** match `shadcn/ui` conventions
24
+ - **Tailwind v4** CSS variable system for modern styling
25
+ - **Theme editors** like [tweakcn](https://tweakcn.com/) work out of the box
26
+ - **Shadcn registries** are supported
27
+ - **Landing homepage**, **portal footer**, and **MCP-generated custom pages** all use the same
28
+ semantic tokens (`bg-primary`, `text-muted-foreground`, `border-border`, etc.)
29
+
30
+ ## Where the theme lives
31
+
32
+ The portal's theme is **`apitogo/portal/theme.json`**. `apitogo add portal` writes it with the
33
+ default colors, so it changes nothing until you edit it. To keep it somewhere else, name the file in
34
+ `portal.theme` in `apitogo.config.json`. Every example below is the content of that file.
35
+
36
+ `apitogo check` reports a theme file that is not valid JSON.
37
+
38
+ ## Custom Colors
39
+
40
+ You can manually define colors for both light and dark modes, either by extending the
41
+ [default theme](#default-theme) or creating a completely custom theme. Colors can be specified as
42
+ hex values, RGB, HSL, OKLCH, etc. - basically anything that is supported by
43
+ [Tailwind CSS](https://tailwindcss.com):
44
+
45
+ ```json title=apitogo/portal/theme.json
46
+ {
47
+ "light": {
48
+ "background": "#ffffff",
49
+ "foreground": "#020817",
50
+ "card": "#ffffff",
51
+ "cardForeground": "#020817",
52
+ "popover": "#ffffff",
53
+ "popoverForeground": "#020817",
54
+ "primary": "#0284c7",
55
+ "primaryForeground": "#ffffff",
56
+ "secondary": "#f1f5f9",
57
+ "secondaryForeground": "#020817",
58
+ "muted": "#f1f5f9",
59
+ "mutedForeground": "#64748b",
60
+ "accent": "#f1f5f9",
61
+ "accentForeground": "#020817",
62
+ "destructive": "#ef4444",
63
+ "destructiveForeground": "#ffffff",
64
+ "border": "#e2e8f0",
65
+ "input": "#e2e8f0",
66
+ "ring": "#0284c7",
67
+ "radius": "0.5rem"
68
+ },
69
+ "dark": {
70
+ "background": "#020817",
71
+ "foreground": "#f8fafc",
72
+ "card": "#020817",
73
+ "cardForeground": "#f8fafc",
74
+ "popover": "#020817",
75
+ "popoverForeground": "#f8fafc",
76
+ "primary": "#0ea5e9",
77
+ "primaryForeground": "#f8fafc",
78
+ "secondary": "#1e293b",
79
+ "secondaryForeground": "#f8fafc",
80
+ "muted": "#1e293b",
81
+ "mutedForeground": "#94a3b8",
82
+ "accent": "#1e293b",
83
+ "accentForeground": "#f8fafc",
84
+ "destructive": "#ef4444",
85
+ "destructiveForeground": "#f8fafc",
86
+ "border": "#1e293b",
87
+ "input": "#1e293b",
88
+ "ring": "#0ea5e9",
89
+ "radius": "0.5rem"
90
+ }
91
+ }
92
+ ```
93
+
94
+ ## Available Theme Variables
95
+
96
+ | Variable | Description |
97
+ | ----------------------- | ------------------------------------- |
98
+ | `background` | Main background color |
99
+ | `foreground` | Main text color |
100
+ | `card` | Card background color |
101
+ | `cardForeground` | Card text color |
102
+ | `popover` | Popover background color |
103
+ | `popoverForeground` | Popover text color |
104
+ | `primary` | Primary action color |
105
+ | `primaryForeground` | Text color on primary backgrounds |
106
+ | `secondary` | Secondary action color |
107
+ | `secondaryForeground` | Text color on secondary backgrounds |
108
+ | `muted` | Muted/subtle background color |
109
+ | `mutedForeground` | Text color for muted elements |
110
+ | `accent` | Accent color for highlights |
111
+ | `accentForeground` | Text color on accent backgrounds |
112
+ | `destructive` | Color for destructive actions |
113
+ | `destructiveForeground` | Text color on destructive backgrounds |
114
+ | `border` | Border color |
115
+ | `input` | Input field border color |
116
+ | `ring` | Focus ring color |
117
+ | `radius` | Border radius value |
118
+
119
+ :::note
120
+
121
+ While shadcn/ui defines additional theme variables, APIToGo currently uses only these core
122
+ variables.
123
+
124
+ :::
125
+
126
+ ## shadcn Registry Integration
127
+
128
+ The easiest way to customize your theme is by using a Shadcn registry theme. For example you can use
129
+ the great [tweakcn](https://tweakcn.com/) visual theme editor.
130
+
131
+ ### Using tweakcn Themes
132
+
133
+ <Stepper>
134
+
135
+ 1. Visit [tweakcn.com](https://tweakcn.com/) to select a preset or customize your theme visually
136
+
137
+ <Framed align="start">![](./tweakcn0.webp)</Framed>
138
+ <Framed align="start">![](./tweakcn1.webp)</Framed>
139
+
140
+ 1. Copy the registry URL from the "Copy" section
141
+
142
+ <Framed align="start">![](./tweakcn2.webp)</Framed>
143
+
144
+ 1. Add it to your configuration:
145
+ ```json title=apitogo/portal/theme.json
146
+ {
147
+ "registryUrl": "https://tweakcn.com/r/themes/northern-lights.json"
148
+ }
149
+ ```
150
+ 1. The theme will then be automatically imported with all color variables, fonts, and styling
151
+ configured for you 🚀
152
+
153
+ <Framed align="start">![](/tweakcn-northlight.png)</Framed>
154
+
155
+ </Stepper>
156
+
157
+ You can still override specific values if needed:
158
+
159
+ ```json title=apitogo/portal/theme.json
160
+ {
161
+ "registryUrl": "https://tweakcn.com/api/registry/theme/xyz123",
162
+ "light": {
163
+ "primary": "#0066cc"
164
+ },
165
+ "dark": {
166
+ "primary": "#3399ff"
167
+ }
168
+ }
169
+ ```
170
+
171
+ Alternatively, you can copy the CSS code and paste it into your `customCss` configuration:
172
+
173
+ ```json title=apitogo/portal/theme.json
174
+ {
175
+ "customCss": "/* the copied CSS */"
176
+ }
177
+ ```
178
+
179
+ ## Custom CSS
180
+
181
+ For advanced styling, you can add custom CSS either as a string or structured object:
182
+
183
+ :::note
184
+
185
+ Changes to `customCss` require restarting the development server to take effect.
186
+
187
+ :::
188
+
189
+ ### CSS String
190
+
191
+ ```json title=apitogo/portal/theme.json
192
+ {
193
+ "customCss": ".custom { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); }"
194
+ }
195
+ ```
196
+
197
+ ### CSS Object
198
+
199
+ ```json title=apitogo/portal/theme.json
200
+ {
201
+ "customCss": {
202
+ ".custom": {
203
+ "background": "linear-gradient(135deg, #667eea 0%, #764ba2 100%)"
204
+ }
205
+ }
206
+ }
207
+ ```
208
+
209
+ ## Default Theme
210
+
211
+ APIToGo comes with a built-in default theme: teal on navy and white, the colors `theme.json` starts
212
+ with. If you want to start completely from scratch without any default styling, you can disable the
213
+ default theme:
214
+
215
+ ```json title=apitogo/portal/theme.json
216
+ {
217
+ "noDefaultTheme": true
218
+ }
219
+ ```
220
+
221
+ When `noDefaultTheme` is set to `true`, no default colors or styling will be applied, giving you
222
+ complete control over your theme. Changing this requires to restart the development server.
223
+
224
+ ## Complete Example
225
+
226
+ Here's a comprehensive example combining multiple theming approaches:
227
+
228
+ ```json title=apitogo/portal/theme.json
229
+ {
230
+ "registryUrl": "https://tweakcn.com/api/registry/theme/modern-blue",
231
+ "light": {
232
+ "primary": "#0066cc",
233
+ "accent": "#f0f9ff"
234
+ },
235
+ "dark": {
236
+ "primary": "#3399ff",
237
+ "accent": "#0c1b2e"
238
+ },
239
+ "fonts": {
240
+ "sans": "Inter",
241
+ "mono": "JetBrains Mono"
242
+ },
243
+ "customCss": {
244
+ ".hero-section": {
245
+ "background": "var(--primary)",
246
+ "color": "var(--primary-foreground)",
247
+ "padding": "2rem",
248
+ "border-radius": "var(--radius)"
249
+ }
250
+ }
251
+ }
252
+ ```
253
+
254
+ This configuration imports a base theme, customizes colors for both light and dark modes, sets
255
+ fonts, and adds custom component styling.