@tutorialkit-rb/astro 1.5.2-rb.0.1.0

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 (63) hide show
  1. package/README.md +14 -0
  2. package/dist/default/components/DownloadButton.tsx +44 -0
  3. package/dist/default/components/HeadTags.astro +3 -0
  4. package/dist/default/components/LoginButton.tsx +55 -0
  5. package/dist/default/components/Logo.astro +30 -0
  6. package/dist/default/components/MainContainer.astro +86 -0
  7. package/dist/default/components/MetaTags.astro +44 -0
  8. package/dist/default/components/MobileContentToggle.astro +44 -0
  9. package/dist/default/components/NavCard.astro +23 -0
  10. package/dist/default/components/NavWrapper.tsx +11 -0
  11. package/dist/default/components/OpenInStackblitzLink.tsx +37 -0
  12. package/dist/default/components/PageLoadingIndicator.astro +66 -0
  13. package/dist/default/components/ResizablePanel.astro +247 -0
  14. package/dist/default/components/ThemeSwitch.tsx +24 -0
  15. package/dist/default/components/TopBar.astro +20 -0
  16. package/dist/default/components/TopBarWrapper.astro +30 -0
  17. package/dist/default/components/TutorialContent.astro +48 -0
  18. package/dist/default/components/WorkspacePanelWrapper.tsx +25 -0
  19. package/dist/default/components/setup.ts +20 -0
  20. package/dist/default/components/webcontainer.ts +46 -0
  21. package/dist/default/env-default.d.ts +19 -0
  22. package/dist/default/layouts/Layout.astro +98 -0
  23. package/dist/default/pages/[...slug].astro +39 -0
  24. package/dist/default/pages/index.astro +25 -0
  25. package/dist/default/stores/auth-store.ts +6 -0
  26. package/dist/default/stores/theme-store.ts +32 -0
  27. package/dist/default/stores/view-store.ts +5 -0
  28. package/dist/default/styles/base.css +11 -0
  29. package/dist/default/styles/markdown.css +400 -0
  30. package/dist/default/styles/panel.css +7 -0
  31. package/dist/default/styles/variables.css +396 -0
  32. package/dist/default/utils/constants.ts +6 -0
  33. package/dist/default/utils/content/files-ref.ts +25 -0
  34. package/dist/default/utils/content/squash.ts +37 -0
  35. package/dist/default/utils/content.ts +446 -0
  36. package/dist/default/utils/logger.ts +56 -0
  37. package/dist/default/utils/logo.ts +17 -0
  38. package/dist/default/utils/nav.ts +65 -0
  39. package/dist/default/utils/publicAsset.ts +27 -0
  40. package/dist/default/utils/routes.ts +34 -0
  41. package/dist/default/utils/url.ts +22 -0
  42. package/dist/default/utils/workspace.ts +31 -0
  43. package/dist/index.d.ts +57 -0
  44. package/dist/index.js +972 -0
  45. package/dist/integrations.d.ts +10 -0
  46. package/dist/remark/callouts.d.ts +3 -0
  47. package/dist/remark/import-file.d.ts +7 -0
  48. package/dist/remark/index.d.ts +2 -0
  49. package/dist/types.d.ts +9 -0
  50. package/dist/utils.d.ts +2 -0
  51. package/dist/vite-plugins/core.d.ts +2 -0
  52. package/dist/vite-plugins/css.d.ts +4 -0
  53. package/dist/vite-plugins/override-components.d.ts +78 -0
  54. package/dist/vite-plugins/store.d.ts +2 -0
  55. package/dist/webcontainer-files/cache.d.ts +21 -0
  56. package/dist/webcontainer-files/cache.spec.d.ts +1 -0
  57. package/dist/webcontainer-files/constants.d.ts +4 -0
  58. package/dist/webcontainer-files/filesmap.d.ts +38 -0
  59. package/dist/webcontainer-files/filesmap.spec.d.ts +1 -0
  60. package/dist/webcontainer-files/index.d.ts +8 -0
  61. package/dist/webcontainer-files/utils.d.ts +6 -0
  62. package/package.json +85 -0
  63. package/types.d.ts +12 -0
@@ -0,0 +1,57 @@
1
+ import type { AstroIntegration } from 'astro';
2
+ import type { ExpressiveCodePlugin } from 'astro-expressive-code';
3
+ import { type OverrideComponentsOptions } from './vite-plugins/override-components.js';
4
+ export interface Options {
5
+ /**
6
+ * Whether or not default routes are injected.
7
+ *
8
+ * Set this to false to customize the pages.
9
+ *
10
+ * Use 'tutorial-only' to only inject the tutorial routes. This is useful
11
+ * if you want to have a different landing page.
12
+ *
13
+ * @default true
14
+ */
15
+ defaultRoutes?: boolean | 'tutorial-only';
16
+ /**
17
+ * Override components of TutorialKit.
18
+ */
19
+ components?: OverrideComponentsOptions;
20
+ /**
21
+ * The value of the Cross-Origin-Embedder-Policy header for the dev server.
22
+ * This is required for webcontainer to works.
23
+ *
24
+ * Using credentialless lets you embed images from third party more easily.
25
+ * However only Firefox and Chrome supports credentialless.
26
+ *
27
+ * @see https://webcontainers.io/guides/configuring-headers
28
+ *
29
+ * @default 'require-corp'
30
+ */
31
+ isolation?: 'require-corp' | 'credentialless';
32
+ /**
33
+ * Configuration options when using the Enterprise
34
+ * version of WebContainer API.
35
+ */
36
+ enterprise?: {
37
+ /**
38
+ * The StackBlitz editor origin.
39
+ */
40
+ editorOrigin: string;
41
+ /**
42
+ * The client id.
43
+ */
44
+ clientId: string;
45
+ /**
46
+ * The OAuth scope.
47
+ */
48
+ scope: string;
49
+ };
50
+ /**
51
+ * Expressive code plugins.
52
+ *
53
+ * @default []
54
+ */
55
+ expressiveCodePlugins?: ExpressiveCodePlugin[];
56
+ }
57
+ export default function createPlugin({ defaultRoutes, components, isolation, enterprise, expressiveCodePlugins, }?: Options): AstroIntegration;