@publier/shell 2.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.
Files changed (141) hide show
  1. package/README.md +1 -0
  2. package/dist/build-integration.d.mts +7 -0
  3. package/dist/build-integration.mjs +1 -0
  4. package/dist/index-DWtFsw7E.d.mts +1033 -0
  5. package/dist/index.d.mts +33 -0
  6. package/dist/index.mjs +1 -0
  7. package/dist/integration-BIJIcnAT.mjs +99 -0
  8. package/dist/integration-CKjtSkwa.d.mts +183 -0
  9. package/dist/integration.d.mts +2 -0
  10. package/dist/integration.mjs +1 -0
  11. package/dist/loaders/index.d.mts +54 -0
  12. package/dist/loaders/index.mjs +1 -0
  13. package/dist/plugins/remark-asides.d.mts +8 -0
  14. package/dist/plugins/remark-asides.mjs +2 -0
  15. package/dist/plugins/remark-snippets.d.mts +11 -0
  16. package/dist/plugins/remark-snippets.mjs +1 -0
  17. package/dist/plugins/remark-structure.d.mts +13 -0
  18. package/dist/plugins/remark-structure.mjs +1 -0
  19. package/dist/plugins/remark-vars.d.mts +7 -0
  20. package/dist/plugins/remark-vars.mjs +1 -0
  21. package/dist/presets-C7z73xlB.d.mts +16 -0
  22. package/dist/presets-DL0qjtya.mjs +1 -0
  23. package/dist/runtime/code-group-sync.d.mts +30 -0
  24. package/dist/runtime/code-group-sync.mjs +103 -0
  25. package/dist/runtime/lazy-upgrade-registry.d.mts +29 -0
  26. package/dist/runtime/lazy-upgrade-registry.mjs +1 -0
  27. package/dist/runtime/tabs-sync.d.mts +25 -0
  28. package/dist/runtime/tabs-sync.mjs +106 -0
  29. package/dist/search/index.d.mts +92 -0
  30. package/dist/search/index.mjs +1 -0
  31. package/dist/tailwind/css-plugin.d.mts +16 -0
  32. package/dist/tailwind/css-plugin.mjs +1 -0
  33. package/dist/tailwind/index.d.mts +6 -0
  34. package/dist/tailwind/index.mjs +1 -0
  35. package/dist/tailwind/loader.d.mts +94 -0
  36. package/dist/tailwind/loader.mjs +2 -0
  37. package/dist/theme-toggle-element-DzFjxwpS.mjs +1 -0
  38. package/dist/themes/almond.css +115 -0
  39. package/dist/themes/aspen.css +95 -0
  40. package/dist/themes/catppuccin.css +98 -0
  41. package/dist/themes/dark.css +98 -0
  42. package/dist/themes/dusk.css +98 -0
  43. package/dist/themes/emerald.css +95 -0
  44. package/dist/themes/light.css +95 -0
  45. package/dist/themes/maple.css +119 -0
  46. package/dist/themes/neutral.css +73 -0
  47. package/dist/themes/ocean.css +98 -0
  48. package/dist/themes/purple.css +95 -0
  49. package/dist/themes/ruby.css +95 -0
  50. package/dist/themes/solar.css +98 -0
  51. package/dist/themes/vitepress.css +95 -0
  52. package/package.json +189 -0
  53. package/publier-gate +0 -0
  54. package/src/astro-modules.d.ts +20 -0
  55. package/src/components/LastModified.astro +25 -0
  56. package/src/components/announcement-banner.astro +25 -0
  57. package/src/components/aside.astro +17 -0
  58. package/src/components/ask-ai.tsx +146 -0
  59. package/src/components/badge.astro +18 -0
  60. package/src/components/breadcrumbs.astro +23 -0
  61. package/src/components/callouts/caution.astro +13 -0
  62. package/src/components/callouts/check.astro +13 -0
  63. package/src/components/callouts/danger.astro +13 -0
  64. package/src/components/callouts/info.astro +13 -0
  65. package/src/components/callouts/note.astro +13 -0
  66. package/src/components/callouts/tip.astro +13 -0
  67. package/src/components/callouts/warning.astro +13 -0
  68. package/src/components/card-grid.astro +14 -0
  69. package/src/components/card.astro +18 -0
  70. package/src/components/code-group.astro +55 -0
  71. package/src/components/columns.astro +18 -0
  72. package/src/components/docs-layout.astro +25 -0
  73. package/src/components/file-tree-node.astro +13 -0
  74. package/src/components/file-tree.astro +9 -0
  75. package/src/components/icon.astro +18 -0
  76. package/src/components/index.ts +155 -0
  77. package/src/components/link-button.astro +21 -0
  78. package/src/components/link-card.astro +21 -0
  79. package/src/components/open-in-ai.astro +13 -0
  80. package/src/components/package-install.astro +17 -0
  81. package/src/components/panels.astro +16 -0
  82. package/src/components/search-button.astro +21 -0
  83. package/src/components/sidebar.astro +12 -0
  84. package/src/components/skip-link.astro +12 -0
  85. package/src/components/steps.astro +13 -0
  86. package/src/components/table-of-contents.astro +22 -0
  87. package/src/components/tabs.astro +17 -0
  88. package/src/components/theme-storage.ts +5 -0
  89. package/src/components/theme-toggle-element.ts +85 -0
  90. package/src/components/theme-toggle.astro +25 -0
  91. package/src/components/tile-grid.astro +13 -0
  92. package/src/components/tile.astro +17 -0
  93. package/src/components/top-nav-mobile.astro +11 -0
  94. package/src/components/top-nav.astro +20 -0
  95. package/src/components/types.ts +510 -0
  96. package/src/components/ui/blur-image.astro +60 -0
  97. package/src/components/ui/changelog-entry.astro +56 -0
  98. package/src/components/ui/cta-band.astro +30 -0
  99. package/src/components/ui/feature-grid.astro +38 -0
  100. package/src/components/ui/feature-section.astro +85 -0
  101. package/src/components/ui/frame.astro +52 -0
  102. package/src/components/ui/hero.astro +47 -0
  103. package/src/components/ui/jobs-list.astro +53 -0
  104. package/src/components/ui/logo-cloud.astro +68 -0
  105. package/src/components/ui/press-gallery.astro +52 -0
  106. package/src/components/ui/pricing-comparison-table.astro +73 -0
  107. package/src/components/ui/pricing-section.astro +113 -0
  108. package/src/components/ui/pricing-table.astro +54 -0
  109. package/src/components/ui/status-indicator.astro +38 -0
  110. package/src/components/ui/team-grid.astro +63 -0
  111. package/src/components/ui/testimonial-card.astro +42 -0
  112. package/src/components/ui/types.ts +323 -0
  113. package/src/components/update-badge.astro +15 -0
  114. package/src/components/version-switcher.astro +20 -0
  115. package/src/icons/index.tsx +246 -0
  116. package/src/icons/resolve.tsx +45 -0
  117. package/src/layouts/base-layout.astro +63 -0
  118. package/src/qwik.ts +3 -0
  119. package/src/routes/blog-index.astro +20 -0
  120. package/src/routes/blog-rss.xml.ts +40 -0
  121. package/src/routes/blog-slug.astro +32 -0
  122. package/src/routes/changelog-index.astro +25 -0
  123. package/src/routes/changelog-rss.xml.ts +47 -0
  124. package/src/routes/docs-slug.astro +31 -0
  125. package/src/routes/not-found.astro +14 -0
  126. package/src/runtime/banner-init.ts +9 -0
  127. package/src/runtime/lazy-upgrade-init.ts +5 -0
  128. package/src/runtime/sidebar-scroll-init.ts +3 -0
  129. package/src/runtime/theme-init.ts +16 -0
  130. package/src/schemas/blog.ts +37 -0
  131. package/src/schemas/changelog.ts +28 -0
  132. package/src/schemas/common.ts +82 -0
  133. package/src/schemas/docs.ts +101 -0
  134. package/src/schemas/index.ts +14 -0
  135. package/src/schemas/pages.ts +22 -0
  136. package/src/styles/base.css +627 -0
  137. package/src/styles/expressive-code.css +41 -0
  138. package/src/styles/rules.css +66 -0
  139. package/src/styles/tailwind-sources.css +17 -0
  140. package/src/tailwind/preset.css +193 -0
  141. package/src/virtual-modules.d.ts +164 -0
@@ -0,0 +1,28 @@
1
+
2
+
3
+ import { z } from 'astro/zod';
4
+
5
+ export const changelogSchema = z.object({
6
+
7
+ title: z.string(),
8
+
9
+
10
+ description: z.string().optional(),
11
+
12
+
13
+ date: z.coerce.date(),
14
+
15
+
16
+ author: z.string().optional(),
17
+
18
+
19
+ tags: z.array(z.string()).optional(),
20
+
21
+
22
+ version: z.string().optional(),
23
+
24
+
25
+ draft: z.boolean().default(false),
26
+ });
27
+
28
+ export type ChangelogEntry = z.infer<typeof changelogSchema>;
@@ -0,0 +1,82 @@
1
+ import { z } from 'astro/zod';
2
+
3
+ export const BadgeConfigSchema = z
4
+ .union([
5
+ z.string(),
6
+ z.object({
7
+ variant: z
8
+ .enum(['note', 'tip', 'caution', 'danger', 'success', 'default'])
9
+ .default('default'),
10
+ text: z.string(),
11
+ class: z.string().optional(),
12
+ }),
13
+ ])
14
+ .optional();
15
+
16
+ export const HeadConfigSchema = z
17
+ .array(
18
+ z.object({
19
+ tag: z.enum(['title', 'base', 'link', 'style', 'meta', 'script', 'noscript', 'template']),
20
+ attrs: z.record(z.string(), z.union([z.string(), z.boolean(), z.undefined()])).default({}),
21
+ content: z.string().default(''),
22
+ }),
23
+ )
24
+ .default([]);
25
+
26
+ export const FrontmatterTableOfContentsSchema = z
27
+ .union([
28
+ z.object({
29
+ minHeadingLevel: z.number().int().min(1).max(6).optional(),
30
+ maxHeadingLevel: z.number().int().min(1).max(6).optional(),
31
+ }),
32
+ z.literal(false),
33
+ ])
34
+ .optional();
35
+
36
+ export const PrevNextLinkConfigSchema = z
37
+ .union([
38
+ z.boolean(),
39
+ z.string(),
40
+ z.object({
41
+ link: z.string().optional(),
42
+ label: z.string().optional(),
43
+ }),
44
+ ])
45
+ .optional();
46
+
47
+ export const HeroSchema = z
48
+ .object({
49
+ title: z.string().optional(),
50
+ tagline: z.string().optional(),
51
+ image: z
52
+ .union([
53
+ z.object({
54
+ alt: z.string(),
55
+ file: z.string(),
56
+ }),
57
+ z.object({
58
+ alt: z.string(),
59
+ dark: z.string(),
60
+ light: z.string(),
61
+ }),
62
+ z.object({
63
+ html: z.string(),
64
+ }),
65
+ ])
66
+ .optional(),
67
+ actions: z
68
+ .array(
69
+ z.object({
70
+ text: z.string(),
71
+ link: z.string(),
72
+ variant: z.enum(['primary', 'secondary', 'minimal']).default('primary'),
73
+ icon: z.string().optional(),
74
+ }),
75
+ )
76
+ .default([]),
77
+ })
78
+ .optional();
79
+
80
+ export const SidebarLinkAttrsSchema = z
81
+ .record(z.string(), z.union([z.string(), z.number(), z.boolean(), z.undefined()]))
82
+ .default({});
@@ -0,0 +1,101 @@
1
+ import { z } from 'astro/zod';
2
+ import {
3
+ BadgeConfigSchema,
4
+ FrontmatterTableOfContentsSchema,
5
+ HeadConfigSchema,
6
+ HeroSchema,
7
+ PrevNextLinkConfigSchema,
8
+ SidebarLinkAttrsSchema,
9
+ } from './common.ts';
10
+
11
+ type BaseSchema = z.ZodTypeAny;
12
+
13
+ const PublierDocsFrontmatterSchema = () =>
14
+ z.object({
15
+
16
+ title: z.string(),
17
+
18
+
19
+ description: z.string().optional(),
20
+
21
+
22
+ head: HeadConfigSchema,
23
+
24
+
25
+ tableOfContents: FrontmatterTableOfContentsSchema,
26
+
27
+
28
+ layout: z.enum(['doc', 'splash']).default('doc'),
29
+
30
+
31
+ hero: HeroSchema,
32
+
33
+
34
+ lastUpdated: z.union([z.date(), z.boolean()]).optional(),
35
+
36
+
37
+ prev: PrevNextLinkConfigSchema,
38
+
39
+
40
+ next: PrevNextLinkConfigSchema,
41
+
42
+
43
+ sidebar: z
44
+ .object({
45
+
46
+ order: z.number().optional(),
47
+
48
+
49
+ label: z.string().optional(),
50
+
51
+
52
+ hidden: z.boolean().default(false),
53
+
54
+
55
+ badge: BadgeConfigSchema,
56
+
57
+
58
+ attrs: SidebarLinkAttrsSchema,
59
+ })
60
+ .optional(),
61
+
62
+
63
+ banner: z
64
+ .object({
65
+ content: z.string(),
66
+ })
67
+ .optional(),
68
+
69
+
70
+ draft: z.boolean().default(false),
71
+
72
+
73
+
74
+
75
+ tags: z.array(z.string()).optional(),
76
+
77
+
78
+ order: z.number().optional(),
79
+ });
80
+
81
+ type DefaultSchema = ReturnType<typeof PublierDocsFrontmatterSchema>;
82
+
83
+ type ExtendedSchema<T extends BaseSchema = never> = [T] extends [never]
84
+ ? DefaultSchema
85
+ : T extends BaseSchema
86
+ ? z.ZodIntersection<DefaultSchema, T>
87
+ : DefaultSchema;
88
+
89
+ interface DocsSchemaOpts<T extends BaseSchema> {
90
+
91
+ extend?: T;
92
+ }
93
+
94
+ export function docsSchema<T extends BaseSchema = never>(
95
+ opts?: DocsSchemaOpts<T>,
96
+ ): ExtendedSchema<T> {
97
+ const base = PublierDocsFrontmatterSchema();
98
+ return (opts?.extend ? base.and(opts.extend) : base) as ExtendedSchema<T>;
99
+ }
100
+
101
+ export type DocsFrontmatter = z.infer<DefaultSchema>;
@@ -0,0 +1,14 @@
1
+
2
+
3
+ export { type BlogEntry, blogSchema } from './blog.ts';
4
+ export { type ChangelogEntry, changelogSchema } from './changelog.ts';
5
+ export {
6
+ BadgeConfigSchema,
7
+ FrontmatterTableOfContentsSchema,
8
+ HeadConfigSchema,
9
+ HeroSchema,
10
+ PrevNextLinkConfigSchema,
11
+ SidebarLinkAttrsSchema,
12
+ } from './common.ts';
13
+ export { type DocsFrontmatter, docsSchema } from './docs.ts';
14
+ export { type PageEntry, pagesSchema } from './pages.ts';
@@ -0,0 +1,22 @@
1
+
2
+
3
+ import { z } from 'astro/zod';
4
+
5
+ export const pagesSchema = z.object({
6
+
7
+ title: z.string(),
8
+
9
+
10
+ description: z.string().optional(),
11
+
12
+
13
+ image: z.string().optional(),
14
+
15
+
16
+ imageAlt: z.string().optional(),
17
+
18
+
19
+ draft: z.boolean().default(false),
20
+ });
21
+
22
+ export type PageEntry = z.infer<typeof pagesSchema>;