@autumnsgrove/groveengine 0.8.0 → 0.8.5

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 (86) hide show
  1. package/dist/components/OnboardingChecklist.svelte +2 -2
  2. package/dist/components/WispButton.svelte +83 -0
  3. package/dist/components/WispButton.svelte.d.ts +49 -0
  4. package/dist/components/WispPanel.svelte +1093 -0
  5. package/dist/components/WispPanel.svelte.d.ts +49 -0
  6. package/dist/components/custom/TableOfContents.svelte +12 -1
  7. package/dist/components/quota/UpgradePrompt.svelte +1 -0
  8. package/dist/config/wisp.d.ts +145 -0
  9. package/dist/config/wisp.js +175 -0
  10. package/dist/index.d.ts +2 -0
  11. package/dist/index.js +3 -0
  12. package/dist/server/inference-client.d.ts +139 -0
  13. package/dist/server/inference-client.js +294 -0
  14. package/dist/ui/components/nature/Logo.svelte +55 -19
  15. package/dist/ui/components/nature/botanical/LeafFalling.svelte +2 -2
  16. package/dist/ui/components/nature/botanical/PetalFalling.svelte +7 -7
  17. package/dist/ui/components/nature/ground/Crocus.svelte +3 -3
  18. package/dist/ui/components/nature/ground/Daffodil.svelte +3 -3
  19. package/dist/ui/components/nature/ground/Tulip.svelte +5 -5
  20. package/dist/ui/components/nature/palette.d.ts +187 -76
  21. package/dist/ui/components/nature/palette.js +169 -81
  22. package/dist/ui/components/nature/trees/TreeCherry.svelte +3 -3
  23. package/dist/ui/components/nature/trees/TreeCherry.svelte.d.ts +1 -1
  24. package/dist/ui/components/nature/trees/TreePine.svelte +2 -2
  25. package/dist/ui/components/nature/trees/TreePine.svelte.d.ts +1 -1
  26. package/dist/ui/components/primitives/textarea/textarea.svelte +1 -1
  27. package/dist/ui/components/typography/Alagard.svelte +17 -0
  28. package/dist/ui/components/typography/Alagard.svelte.d.ts +10 -0
  29. package/dist/ui/components/typography/Atkinson.svelte +17 -0
  30. package/dist/ui/components/typography/Atkinson.svelte.d.ts +10 -0
  31. package/dist/ui/components/typography/BodoniModa.svelte +17 -0
  32. package/dist/ui/components/typography/BodoniModa.svelte.d.ts +10 -0
  33. package/dist/ui/components/typography/Calistoga.svelte +17 -0
  34. package/dist/ui/components/typography/Calistoga.svelte.d.ts +10 -0
  35. package/dist/ui/components/typography/Caveat.svelte +17 -0
  36. package/dist/ui/components/typography/Caveat.svelte.d.ts +10 -0
  37. package/dist/ui/components/typography/Cormorant.svelte +17 -0
  38. package/dist/ui/components/typography/Cormorant.svelte.d.ts +10 -0
  39. package/dist/ui/components/typography/Cozette.svelte +17 -0
  40. package/dist/ui/components/typography/Cozette.svelte.d.ts +10 -0
  41. package/dist/ui/components/typography/EBGaramond.svelte +17 -0
  42. package/dist/ui/components/typography/EBGaramond.svelte.d.ts +10 -0
  43. package/dist/ui/components/typography/FontProvider.svelte +98 -0
  44. package/dist/ui/components/typography/FontProvider.svelte.d.ts +17 -0
  45. package/dist/ui/components/typography/Fraunces.svelte +17 -0
  46. package/dist/ui/components/typography/Fraunces.svelte.d.ts +10 -0
  47. package/dist/ui/components/typography/IBMPlexMono.svelte +17 -0
  48. package/dist/ui/components/typography/IBMPlexMono.svelte.d.ts +10 -0
  49. package/dist/ui/components/typography/InstrumentSans.svelte +17 -0
  50. package/dist/ui/components/typography/InstrumentSans.svelte.d.ts +10 -0
  51. package/dist/ui/components/typography/Lexend.svelte +17 -0
  52. package/dist/ui/components/typography/Lexend.svelte.d.ts +10 -0
  53. package/dist/ui/components/typography/Lora.svelte +17 -0
  54. package/dist/ui/components/typography/Lora.svelte.d.ts +10 -0
  55. package/dist/ui/components/typography/Luciole.svelte +17 -0
  56. package/dist/ui/components/typography/Luciole.svelte.d.ts +10 -0
  57. package/dist/ui/components/typography/Manrope.svelte +17 -0
  58. package/dist/ui/components/typography/Manrope.svelte.d.ts +10 -0
  59. package/dist/ui/components/typography/Merriweather.svelte +17 -0
  60. package/dist/ui/components/typography/Merriweather.svelte.d.ts +10 -0
  61. package/dist/ui/components/typography/Nunito.svelte +17 -0
  62. package/dist/ui/components/typography/Nunito.svelte.d.ts +10 -0
  63. package/dist/ui/components/typography/OpenDyslexic.svelte +17 -0
  64. package/dist/ui/components/typography/OpenDyslexic.svelte.d.ts +10 -0
  65. package/dist/ui/components/typography/PlusJakartaSans.svelte +17 -0
  66. package/dist/ui/components/typography/PlusJakartaSans.svelte.d.ts +10 -0
  67. package/dist/ui/components/typography/Quicksand.svelte +17 -0
  68. package/dist/ui/components/typography/Quicksand.svelte.d.ts +10 -0
  69. package/dist/ui/components/typography/README.md +153 -0
  70. package/dist/ui/components/typography/index.d.ts +23 -0
  71. package/dist/ui/components/typography/index.js +42 -0
  72. package/dist/ui/components/ui/GlassCarousel.svelte +446 -0
  73. package/dist/ui/components/ui/GlassCarousel.svelte.d.ts +57 -0
  74. package/dist/ui/components/ui/GlassConfirmDialog.svelte +2 -1
  75. package/dist/ui/components/ui/GlassLogo.svelte +2 -1
  76. package/dist/ui/components/ui/GlassOverlay.svelte +1 -1
  77. package/dist/ui/components/ui/index.d.ts +1 -0
  78. package/dist/ui/components/ui/index.js +1 -0
  79. package/dist/ui/index.d.ts +1 -0
  80. package/dist/ui/index.js +2 -0
  81. package/dist/ui/vineyard/index.d.ts +9 -0
  82. package/dist/ui/vineyard/index.js +8 -0
  83. package/dist/utils/csrf.js +5 -2
  84. package/dist/utils/readability.d.ts +89 -0
  85. package/dist/utils/readability.js +204 -0
  86. package/package.json +17 -1
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const EBGaramond: import("svelte").Component<Props, {}, "">;
9
+ type EBGaramond = ReturnType<typeof EBGaramond>;
10
+ export default EBGaramond;
@@ -0,0 +1,98 @@
1
+ <script lang="ts">
2
+ import { onMount } from 'svelte';
3
+ import type { Snippet } from 'svelte';
4
+ import type { FontId } from '../../tokens/fonts.js';
5
+ import { fontById, getFontUrl, getFontStack } from '../../tokens/fonts.js';
6
+
7
+ interface Props {
8
+ /** The font ID to apply */
9
+ font: FontId;
10
+ /** HTML element to render as */
11
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
12
+ /** Additional CSS classes */
13
+ class?: string;
14
+ /** Inline styles */
15
+ style?: string;
16
+ /** Content to render */
17
+ children: Snippet;
18
+ }
19
+
20
+ let { font, as = 'span', class: className = '', style = '', children }: Props = $props();
21
+
22
+ const fontDef = $derived(fontById[font]);
23
+ const fontStack = $derived(fontDef ? getFontStack(font) : 'inherit');
24
+ const combinedStyle = $derived(`font-family: ${fontStack};${style ? ` ${style}` : ''}`);
25
+
26
+ // Ensure the font is loaded (inject @font-face if not already present)
27
+ onMount(() => {
28
+ if (!fontDef) return;
29
+
30
+ const styleId = `grove-font-${font}`;
31
+ if (document.getElementById(styleId)) return;
32
+
33
+ const styleEl = document.createElement('style');
34
+ styleEl.id = styleId;
35
+ styleEl.textContent = `
36
+ @font-face {
37
+ font-family: '${fontDef.fontFamily}';
38
+ src: url('${getFontUrl(fontDef.file)}') format('${fontDef.format}');
39
+ font-weight: normal;
40
+ font-style: normal;
41
+ font-display: swap;
42
+ }
43
+ `;
44
+ document.head.appendChild(styleEl);
45
+ });
46
+ </script>
47
+
48
+ {#if as === 'div'}
49
+ <div class={className} style={combinedStyle}>
50
+ {@render children()}
51
+ </div>
52
+ {:else if as === 'p'}
53
+ <p class={className} style={combinedStyle}>
54
+ {@render children()}
55
+ </p>
56
+ {:else if as === 'h1'}
57
+ <h1 class={className} style={combinedStyle}>
58
+ {@render children()}
59
+ </h1>
60
+ {:else if as === 'h2'}
61
+ <h2 class={className} style={combinedStyle}>
62
+ {@render children()}
63
+ </h2>
64
+ {:else if as === 'h3'}
65
+ <h3 class={className} style={combinedStyle}>
66
+ {@render children()}
67
+ </h3>
68
+ {:else if as === 'h4'}
69
+ <h4 class={className} style={combinedStyle}>
70
+ {@render children()}
71
+ </h4>
72
+ {:else if as === 'h5'}
73
+ <h5 class={className} style={combinedStyle}>
74
+ {@render children()}
75
+ </h5>
76
+ {:else if as === 'h6'}
77
+ <h6 class={className} style={combinedStyle}>
78
+ {@render children()}
79
+ </h6>
80
+ {:else if as === 'code'}
81
+ <code class={className} style={combinedStyle}>
82
+ {@render children()}
83
+ </code>
84
+ {:else if as === 'pre'}
85
+ <pre class={className} style={combinedStyle}>{@render children()}</pre>
86
+ {:else if as === 'article'}
87
+ <article class={className} style={combinedStyle}>
88
+ {@render children()}
89
+ </article>
90
+ {:else if as === 'section'}
91
+ <section class={className} style={combinedStyle}>
92
+ {@render children()}
93
+ </section>
94
+ {:else}
95
+ <span class={className} style={combinedStyle}>
96
+ {@render children()}
97
+ </span>
98
+ {/if}
@@ -0,0 +1,17 @@
1
+ import type { Snippet } from 'svelte';
2
+ import type { FontId } from '../../tokens/fonts.js';
3
+ interface Props {
4
+ /** The font ID to apply */
5
+ font: FontId;
6
+ /** HTML element to render as */
7
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
8
+ /** Additional CSS classes */
9
+ class?: string;
10
+ /** Inline styles */
11
+ style?: string;
12
+ /** Content to render */
13
+ children: Snippet;
14
+ }
15
+ declare const FontProvider: import("svelte").Component<Props, {}, "">;
16
+ type FontProvider = ReturnType<typeof FontProvider>;
17
+ export default FontProvider;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="fraunces" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const Fraunces: import("svelte").Component<Props, {}, "">;
9
+ type Fraunces = ReturnType<typeof Fraunces>;
10
+ export default Fraunces;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="ibm-plex-mono" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const IBMPlexMono: import("svelte").Component<Props, {}, "">;
9
+ type IBMPlexMono = ReturnType<typeof IBMPlexMono>;
10
+ export default IBMPlexMono;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="instrument-sans" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const InstrumentSans: import("svelte").Component<Props, {}, "">;
9
+ type InstrumentSans = ReturnType<typeof InstrumentSans>;
10
+ export default InstrumentSans;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="lexend" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const Lexend: import("svelte").Component<Props, {}, "">;
9
+ type Lexend = ReturnType<typeof Lexend>;
10
+ export default Lexend;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="lora" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const Lora: import("svelte").Component<Props, {}, "">;
9
+ type Lora = ReturnType<typeof Lora>;
10
+ export default Lora;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="luciole" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const Luciole: import("svelte").Component<Props, {}, "">;
9
+ type Luciole = ReturnType<typeof Luciole>;
10
+ export default Luciole;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="manrope" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const Manrope: import("svelte").Component<Props, {}, "">;
9
+ type Manrope = ReturnType<typeof Manrope>;
10
+ export default Manrope;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="merriweather" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const Merriweather: import("svelte").Component<Props, {}, "">;
9
+ type Merriweather = ReturnType<typeof Merriweather>;
10
+ export default Merriweather;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="nunito" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const Nunito: import("svelte").Component<Props, {}, "">;
9
+ type Nunito = ReturnType<typeof Nunito>;
10
+ export default Nunito;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="opendyslexic" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const OpenDyslexic: import("svelte").Component<Props, {}, "">;
9
+ type OpenDyslexic = ReturnType<typeof OpenDyslexic>;
10
+ export default OpenDyslexic;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="plus-jakarta-sans" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const PlusJakartaSans: import("svelte").Component<Props, {}, "">;
9
+ type PlusJakartaSans = ReturnType<typeof PlusJakartaSans>;
10
+ export default PlusJakartaSans;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+ import FontProvider from './FontProvider.svelte';
4
+
5
+ interface Props {
6
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
7
+ class?: string;
8
+ style?: string;
9
+ children: Snippet;
10
+ }
11
+
12
+ let { as = 'span', class: className = '', style = '', children }: Props = $props();
13
+ </script>
14
+
15
+ <FontProvider font="quicksand" {as} class={className} {style}>
16
+ {@render children()}
17
+ </FontProvider>
@@ -0,0 +1,10 @@
1
+ import type { Snippet } from 'svelte';
2
+ interface Props {
3
+ as?: 'span' | 'div' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'code' | 'pre' | 'article' | 'section';
4
+ class?: string;
5
+ style?: string;
6
+ children: Snippet;
7
+ }
8
+ declare const Quicksand: import("svelte").Component<Props, {}, "">;
9
+ type Quicksand = ReturnType<typeof Quicksand>;
10
+ export default Quicksand;
@@ -0,0 +1,153 @@
1
+ # Typography Components
2
+
3
+ Scoped font wrapper components for the Grove Design System. Each component loads its font from CDN on-demand and applies it to children.
4
+
5
+ ## Installation
6
+
7
+ ```ts
8
+ import { Alagard, IBMPlexMono, Caveat } from '@autumnsgrove/groveengine/ui/typography';
9
+ ```
10
+
11
+ ## Quick Start
12
+
13
+ ```svelte
14
+ <!-- Fantasy game header -->
15
+ <Alagard as="h1" class="text-4xl">Welcome to the Grove</Alagard>
16
+
17
+ <!-- Code block -->
18
+ <IBMPlexMono as="code">console.log('hello');</IBMPlexMono>
19
+
20
+ <!-- Handwritten note -->
21
+ <Caveat as="p" class="text-2xl">A personal touch...</Caveat>
22
+ ```
23
+
24
+ ## Available Fonts
25
+
26
+ ### Display & Special (3)
27
+ | Component | Font | Use Case |
28
+ |-----------|------|----------|
29
+ | `Alagard` | Alagard | Fantasy, gaming, medieval themes |
30
+ | `Calistoga` | Calistoga | Friendly headlines, warm branding |
31
+ | `Caveat` | Caveat | Handwritten notes, personal touches |
32
+
33
+ ### Serif (6)
34
+ | Component | Font | Use Case |
35
+ |-----------|------|----------|
36
+ | `Cormorant` | Cormorant | Elegant headers, editorial |
37
+ | `BodoniModa` | Bodoni Moda | High fashion, sophisticated |
38
+ | `Lora` | Lora | Body text, readable articles |
39
+ | `EBGaramond` | EB Garamond | Book typography, classic feel |
40
+ | `Merriweather` | Merriweather | Screen reading, long-form content |
41
+ | `Fraunces` | Fraunces | Warm personality, soft serif |
42
+
43
+ ### Sans-Serif (6)
44
+ | Component | Font | Use Case |
45
+ |-----------|------|----------|
46
+ | `Lexend` | Lexend | Default, highly readable UI |
47
+ | `Nunito` | Nunito | Friendly, approachable interfaces |
48
+ | `Quicksand` | Quicksand | Light, modern, geometric |
49
+ | `Manrope` | Manrope | Professional, clean interfaces |
50
+ | `InstrumentSans` | Instrument Sans | Elegant simplicity |
51
+ | `PlusJakartaSans` | Plus Jakarta Sans | Balanced, versatile |
52
+
53
+ ### Monospace (2)
54
+ | Component | Font | Use Case |
55
+ |-----------|------|----------|
56
+ | `IBMPlexMono` | IBM Plex Mono | Code blocks, technical content |
57
+ | `Cozette` | Cozette | Retro terminal, pixel aesthetic |
58
+
59
+ ### Accessibility (3)
60
+ | Component | Font | Use Case |
61
+ |-----------|------|----------|
62
+ | `Atkinson` | Atkinson Hyperlegible | Low vision readers |
63
+ | `OpenDyslexic` | OpenDyslexic | Dyslexic readers |
64
+ | `Luciole` | Luciole | Visually impaired readers |
65
+
66
+ ## Props
67
+
68
+ All font components accept the same props:
69
+
70
+ | Prop | Type | Default | Description |
71
+ |------|------|---------|-------------|
72
+ | `as` | `'span' \| 'div' \| 'p' \| 'h1' \| 'h2' \| 'h3' \| 'h4' \| 'h5' \| 'h6' \| 'code' \| 'pre' \| 'article' \| 'section'` | `'span'` | HTML element to render |
73
+ | `class` | `string` | `''` | CSS classes (Tailwind works great) |
74
+ | `style` | `string` | `''` | Inline styles |
75
+
76
+ ## Dynamic Font Selection
77
+
78
+ Use `FontProvider` when you need to select fonts programmatically:
79
+
80
+ ```svelte
81
+ <script>
82
+ import { FontProvider } from '@autumnsgrove/groveengine/ui/typography';
83
+ let selectedFont = 'cormorant';
84
+ </script>
85
+
86
+ <FontProvider font={selectedFont} as="article">
87
+ <p>Content with dynamic font...</p>
88
+ </FontProvider>
89
+ ```
90
+
91
+ ## Performance
92
+
93
+ - **On-demand loading**: Fonts load from CDN only when the component mounts
94
+ - **Deduplication**: Each font's `@font-face` is injected once, even with multiple instances
95
+ - **Swap display**: Uses `font-display: swap` for fast initial render
96
+ - **CDN**: All fonts served from `cdn.grove.place` with proper caching
97
+
98
+ ## Accessibility Recommendations
99
+
100
+ | Situation | Recommended Font |
101
+ |-----------|-----------------|
102
+ | Low vision users | `Atkinson` (maximum character distinction) |
103
+ | Dyslexic readers | `OpenDyslexic` (weighted letter bottoms) |
104
+ | General accessibility | `Lexend` (designed for reading fluency) |
105
+ | Long-form reading | `Merriweather` or `Lora` (optimized for screens) |
106
+
107
+ ## Examples
108
+
109
+ ### Blog Post Header
110
+ ```svelte
111
+ <Fraunces as="h1" class="text-4xl font-bold text-bark-900">
112
+ A Warm Welcome to the Grove
113
+ </Fraunces>
114
+ ```
115
+
116
+ ### Code Documentation
117
+ ```svelte
118
+ <IBMPlexMono as="pre" class="bg-bark-900 text-cream-100 p-4 rounded-lg">
119
+ {codeExample}
120
+ </IBMPlexMono>
121
+ ```
122
+
123
+ ### Personal Note Card
124
+ ```svelte
125
+ <div class="bg-rose-50 p-6 rounded-lg">
126
+ <Caveat as="p" class="text-2xl text-rose-900">
127
+ Thanks for being here...
128
+ </Caveat>
129
+ </div>
130
+ ```
131
+
132
+ ### Mixed Typography
133
+ ```svelte
134
+ <article>
135
+ <Alagard as="h1" class="text-3xl mb-4">Quest Log</Alagard>
136
+ <Lora as="div" class="prose">
137
+ <p>Your journey begins in the misty forests...</p>
138
+ </Lora>
139
+ </article>
140
+ ```
141
+
142
+ ## Font Tokens
143
+
144
+ The typography module also exports font metadata for programmatic use:
145
+
146
+ ```ts
147
+ import {
148
+ fonts, // Array of all font definitions
149
+ fontById, // Map of font ID to definition
150
+ getFontStack, // Get full font-family string with fallbacks
151
+ getFontUrl, // Get CDN URL for a font file
152
+ } from '@autumnsgrove/groveengine/ui/typography';
153
+ ```