@fuzdev/fuz_ui 0.217.0 → 0.219.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.
@@ -1,6 +1,7 @@
1
1
  <script lang="ts">
2
2
  import Code from '@fuzdev/fuz_code/Code.svelte';
3
3
  import Mdz from '@fuzdev/mdz/Mdz.svelte';
4
+ import { mdz_from_tsdoc } from '@fuzdev/mdz/tsdoc_mdz.ts';
4
5
  import {
5
6
  mdz_code_context,
6
7
  mdz_codeblock_context,
@@ -8,6 +9,7 @@
8
9
  } from '@fuzdev/mdz/mdz_contexts.ts';
9
10
 
10
11
  import { set_library_context_with_fallback, type Library } from './library.svelte.js';
12
+ import type { Module } from './module.svelte.js';
11
13
  import { tome_get_by_slug, type Tome } from './tome.js';
12
14
  import TomeContent from './TomeContent.svelte';
13
15
  import TomeSection from './TomeSection.svelte';
@@ -70,6 +72,20 @@
70
72
  const source_url = $derived(module?.url_github);
71
73
  </script>
72
74
 
75
+ <!-- Marker chips from the module comment, shared by the module page and directory listings. -->
76
+ {#snippet doc_chips(m: Module)}
77
+ {#if m.is_deprecated || m.is_internal}
78
+ <p class="row gap_md flex-wrap:wrap">
79
+ {#if m.is_deprecated}
80
+ <span class="chip">⚠️ deprecated</span>
81
+ {/if}
82
+ {#if m.is_internal}
83
+ <span class="chip">internal</span>
84
+ {/if}
85
+ </p>
86
+ {/if}
87
+ {/snippet}
88
+
73
89
  <svelte:head>
74
90
  <title>{module_name} - API docs - {library.pkg_json.name}</title>
75
91
  </svelte:head>
@@ -92,6 +108,7 @@
92
108
  {#each directory_modules as child_module (child_module.path)}
93
109
  <li>
94
110
  <h3><ModuleLink module_path={child_module.path} /></h3>
111
+ {@render doc_chips(child_module)}
95
112
  {#if child_module.module_comment}
96
113
  <Mdz content={child_module.module_comment} />
97
114
  {/if}
@@ -101,9 +118,33 @@
101
118
  </section>
102
119
  {/if}
103
120
  {:else}
104
- {#if module.module_comment}
121
+ <!-- module comment: mirrors the compact `doc_extras` form in `DeclarationDetail` -->
122
+ {#if module.has_module_doc}
105
123
  <section>
106
- <Mdz content={module.module_comment} />
124
+ {@render doc_chips(module)}
125
+ {#if module.deprecated_message}
126
+ <p>{module.deprecated_message}</p>
127
+ {/if}
128
+ {#if module.internal_message}
129
+ <p>{module.internal_message}</p>
130
+ {/if}
131
+ {#if module.module_comment}
132
+ <Mdz content={module.module_comment} />
133
+ {/if}
134
+ {#if module.since}
135
+ <p><strong>since</strong> {module.since}</p>
136
+ {/if}
137
+ {#each module.examples as example (example)}
138
+ <Mdz content={example} />
139
+ {/each}
140
+ {#if module.see_also.length}
141
+ <p><strong>see also</strong></p>
142
+ <ul>
143
+ {#each module.see_also as ref (ref)}
144
+ <li><Mdz content={mdz_from_tsdoc(ref)} /></li>
145
+ {/each}
146
+ </ul>
147
+ {/if}
107
148
  </section>
108
149
  {/if}
109
150
  {#if source_url}
@@ -1 +1 @@
1
- {"version":3,"file":"ApiModule.svelte.d.ts","sourceRoot":"../src/lib/","sources":["../src/lib/ApiModule.svelte"],"names":[],"mappings":"AAWA,OAAO,EAAqC,KAAK,OAAO,EAAE,MAAM,qBAAqB,CAAC;AACtF,OAAO,EAAoB,KAAK,IAAI,EAAE,MAAM,WAAW,CAAC;AAWvD,KAAK,gBAAgB,GAAI;IACxB;;OAEG;IACH,WAAW,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;IACpC;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;CACZ,CAAC;AAgMH,QAAA,MAAM,SAAS,sDAAwC,CAAC;AACxD,KAAK,SAAS,GAAG,UAAU,CAAC,OAAO,SAAS,CAAC,CAAC;AAC9C,eAAe,SAAS,CAAC"}
1
+ {"version":3,"file":"ApiModule.svelte.d.ts","sourceRoot":"../src/lib/","sources":["../src/lib/ApiModule.svelte"],"names":[],"mappings":"AAYA,OAAO,EAAqC,KAAK,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAEtF,OAAO,EAAoB,KAAK,IAAI,EAAE,MAAM,WAAW,CAAC;AAWvD,KAAK,gBAAgB,GAAI;IACxB;;OAEG;IACH,WAAW,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAC;IACpC;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;;;OAGG;IACH,IAAI,CAAC,EAAE,IAAI,CAAC;CACZ,CAAC;AAyOH,QAAA,MAAM,SAAS,sDAAwC,CAAC;AACxD,KAAK,SAAS,GAAG,UAAU,CAAC,OAAO,SAAS,CAAC,CAAC;AAC9C,eAAe,SAAS,CAAC"}
package/dist/logos.d.ts CHANGED
@@ -48,13 +48,6 @@ export declare const logo_fuz_blog: {
48
48
  d: string;
49
49
  }[];
50
50
  };
51
- export declare const logo_fuz_mastodon: {
52
- label: string;
53
- fill: string;
54
- paths: {
55
- d: string;
56
- }[];
57
- };
58
51
  export declare const logo_fuz_repos: {
59
52
  label: string;
60
53
  fill: string;
@@ -1 +1 @@
1
- {"version":3,"file":"logos.d.ts","sourceRoot":"../src/lib/","sources":["../src/lib/logos.ts"],"names":[],"mappings":"AAuBA,eAAO,MAAM,QAAQ;;;;;;CAgCF,CAAC;AAEpB,eAAO,MAAM,QAAQ;;;;;;CAQF,CAAC;AAEpB,eAAO,MAAM,YAAY;;;;;;CAIN,CAAC;AAEpB,eAAO,MAAM,YAAY;;;;;;;CAKN,CAAC;AAEpB,eAAO,MAAM,WAAW;;;;;;CAIL,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAIP,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAIP,CAAC;AAEpB,eAAO,MAAM,iBAAiB;;;;;;CAIX,CAAC;AAEpB,eAAO,MAAM,cAAc;;;;;;CAIR,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAIP,CAAC;AAEpB,eAAO,MAAM,mBAAmB;;;;;;CAQb,CAAC;AAEpB,eAAO,MAAM,iBAAiB;;;;;;CAQX,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAwBP,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAQP,CAAC;AAEpB,eAAO,MAAM,QAAQ;;;;;;CAQF,CAAC;AAEpB,eAAO,MAAM,WAAW;;;;;;;;;CAWL,CAAC;AAEpB,eAAO,MAAM,QAAQ;;;;;;CAQF,CAAC"}
1
+ {"version":3,"file":"logos.d.ts","sourceRoot":"../src/lib/","sources":["../src/lib/logos.ts"],"names":[],"mappings":"AAuBA,eAAO,MAAM,QAAQ;;;;;;CAgCF,CAAC;AAEpB,eAAO,MAAM,QAAQ;;;;;;CAQF,CAAC;AAEpB,eAAO,MAAM,YAAY;;;;;;CAIN,CAAC;AAEpB,eAAO,MAAM,YAAY;;;;;;;CAKN,CAAC;AAEpB,eAAO,MAAM,WAAW;;;;;;CAIL,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAIP,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAIP,CAAC;AAEpB,eAAO,MAAM,cAAc;;;;;;CAIR,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAIP,CAAC;AAEpB,eAAO,MAAM,mBAAmB;;;;;;CAQb,CAAC;AAEpB,eAAO,MAAM,iBAAiB;;;;;;CAQX,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAwBP,CAAC;AAEpB,eAAO,MAAM,aAAa;;;;;;CAQP,CAAC;AAEpB,eAAO,MAAM,QAAQ;;;;;;CAQF,CAAC;AAEpB,eAAO,MAAM,WAAW;;;;;;;;;CAWL,CAAC;AAEpB,eAAO,MAAM,QAAQ;;;;;;CAQF,CAAC"}
package/dist/logos.js CHANGED
@@ -85,11 +85,6 @@ export const logo_fuz_blog = {
85
85
  fill: '#d8bc31',
86
86
  paths: logo_fuz.paths
87
87
  };
88
- export const logo_fuz_mastodon = {
89
- label: 'a friendly purple spider facing you',
90
- fill: '#8866cc',
91
- paths: logo_fuz.paths
92
- };
93
88
  export const logo_fuz_repos = {
94
89
  label: 'a friendly blue spider facing you',
95
90
  fill: '#6199d1',
@@ -33,7 +33,22 @@ export declare class Module {
33
33
  * Import-style path with ./ prefix.
34
34
  */
35
35
  get path_import(): string;
36
+ /**
37
+ * Prose of the `@module` comment, tag lines removed. Absent for a tag-only
38
+ * comment, whose tags still populate the doc fields below.
39
+ */
36
40
  get module_comment(): string | undefined;
41
+ get deprecated_message(): string | undefined;
42
+ /**
43
+ * Internal-API marker from the module comment's `@internal` tag. Presence
44
+ * means the tag was written; an empty string is a bare tag.
45
+ */
46
+ get internal_message(): string | undefined;
47
+ get since(): string | undefined;
48
+ get examples(): NonNullable<ModuleJsonInput['examples']>;
49
+ get see_also(): NonNullable<ModuleJsonInput['seeAlso']>;
50
+ get is_deprecated(): boolean;
51
+ get is_internal(): boolean;
37
52
  /**
38
53
  * Array of `Declaration` instances. Filters out default exports.
39
54
  */
@@ -58,7 +73,12 @@ export declare class Module {
58
73
  * filter in `declarations`).
59
74
  */
60
75
  get has_declarations(): boolean;
61
- get has_module_comment(): boolean;
76
+ /**
77
+ * Whether the module comment documents anything — prose or any doc field.
78
+ * A tag-only comment (just `@see`, say) has no `module_comment` but still
79
+ * counts.
80
+ */
81
+ get has_module_doc(): boolean;
62
82
  /**
63
83
  * Modules this imports (paths relative to src/lib).
64
84
  */
@@ -1 +1 @@
1
- {"version":3,"file":"module.svelte.d.ts","sourceRoot":"../src/lib/","sources":["../src/lib/module.svelte.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACX,eAAe,EACf,iBAAiB,EACjB,yBAAyB,EACzB,MAAM,yBAAyB,CAAC;AAGjC,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAwBnD;;;;;;;;;;;GAWG;AACH,qBAAa,MAAM;;IAClB,QAAQ,CAAC,OAAO,EAAE,OAAO,CA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OAAO,CAErC;IAID;;;;OAIG;IACH,IAAI,gCAAgC,IAAI,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,yBAAyB,CAAC,CAAC,CAKpF;IAED;;;;OAIG;IACH,IAAI,qBAAqB,IAAI,WAAW,CAAC,eAAe,CAAC,qBAAqB,CAAC,CAAC,CAE/E;IAED,IAAI,yBAAyB,IAAI,OAAO,CAEvC;IAED;;;OAGG;IACH,IAAI,kBAAkB,IAAI,OAAO,CAOhC;gBAEW,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,eAAe;IAK1D;;OAEG;IACH,uBAAuB,CAAC,IAAI,EAAE,MAAM,GAAG,WAAW,GAAG,SAAS;CAG9D"}
@@ -57,9 +57,40 @@ export class Module {
57
57
  get path_import() {
58
58
  return './' + this.path;
59
59
  }
60
+ /**
61
+ * Prose of the `@module` comment, tag lines removed. Absent for a tag-only
62
+ * comment, whose tags still populate the doc fields below.
63
+ */
60
64
  get module_comment() {
61
65
  return this.module_json.moduleComment;
62
66
  }
67
+ get deprecated_message() {
68
+ return this.module_json.deprecatedMessage;
69
+ }
70
+ /**
71
+ * Internal-API marker from the module comment's `@internal` tag. Presence
72
+ * means the tag was written; an empty string is a bare tag.
73
+ */
74
+ get internal_message() {
75
+ return this.module_json.internalMessage;
76
+ }
77
+ get since() {
78
+ return this.module_json.since;
79
+ }
80
+ get examples() {
81
+ return this.module_json.examples ?? EMPTY_ARRAY;
82
+ }
83
+ get see_also() {
84
+ return this.module_json.seeAlso ?? EMPTY_ARRAY;
85
+ }
86
+ // presence, not truthiness — a bare `@deprecated` (no message text) arrives as `''`
87
+ get is_deprecated() {
88
+ return this.deprecated_message !== undefined;
89
+ }
90
+ // presence, not truthiness — a bare `@internal` (no message text) arrives as `''`
91
+ get is_internal() {
92
+ return this.internal_message !== undefined;
93
+ }
63
94
  #declarations;
64
95
  /**
65
96
  * Array of `Declaration` instances. Filters out default exports.
@@ -99,8 +130,18 @@ export class Module {
99
130
  get has_declarations() {
100
131
  return this.declarations.length > 0;
101
132
  }
102
- get has_module_comment() {
103
- return !!this.module_comment;
133
+ /**
134
+ * Whether the module comment documents anything — prose or any doc field.
135
+ * A tag-only comment (just `@see`, say) has no `module_comment` but still
136
+ * counts.
137
+ */
138
+ get has_module_doc() {
139
+ return (!!this.module_comment ||
140
+ this.is_deprecated ||
141
+ this.is_internal ||
142
+ !!this.since ||
143
+ this.examples.length > 0 ||
144
+ this.see_also.length > 0);
104
145
  }
105
146
  /**
106
147
  * Modules this imports (paths relative to src/lib).
@@ -1 +1 @@
1
- {"version":3,"file":"projects.d.ts","sourceRoot":"../src/lib/","sources":["../src/lib/projects.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAmBxC;;GAEG;AACH,MAAM,WAAW,WAAW;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,OAAO,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;CACpB;AAID,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,WAAW,CAc5C,CAAC"}
1
+ {"version":3,"file":"projects.d.ts","sourceRoot":"../src/lib/","sources":["../src/lib/projects.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAkBxC;;GAEG;AACH,MAAM,WAAW,WAAW;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,OAAO,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;CACpB;AAID,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,WAAW,CAa5C,CAAC"}
package/dist/projects.js CHANGED
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  // TODO when fuz.dev is ready
3
3
  // logo_fuz,
4
- logo_fuz_ui, logo_fuz_code, logo_fuz_blog, logo_fuz_mastodon, logo_fuz_repos, logo_fuz_template, logo_fuz_css, logo_fuz_util, logo_fuz_host, logo_gro, logo_svelte_docinfo, logo_fuz_app, logo_tsv } from './logos.js';
4
+ logo_fuz_ui, logo_fuz_code, logo_fuz_blog, logo_fuz_repos, logo_fuz_template, logo_fuz_css, logo_fuz_util, logo_fuz_host, logo_gro, logo_svelte_docinfo, logo_fuz_app, logo_tsv } from './logos.js';
5
5
  // TODO ideally this wouldn't duplicate metadata like descriptions, but adding fuz_repos to this repo is heavy
6
6
  // prettier-ignore
7
7
  export const project_items = [
@@ -11,7 +11,6 @@ export const project_items = [
11
11
  { name: 'fuz_template', url: 'https://template.fuz.dev/', logo: logo_fuz_template, description: 'a web app template with TypeScript + SvelteKit + optional Rust for the fuz-stack', glyph: '❄', color_class: 'color_h_50' },
12
12
  { name: 'fuz_blog', url: 'https://blog.fuz.dev/', logo: logo_fuz_blog, description: 'blog software from scratch with SvelteKit', glyph: '🖊️', color_class: 'color_e_50' },
13
13
  { name: 'fuz_code', url: 'https://code.fuz.dev/', logo: logo_fuz_code, description: 'syntax styling utilities and components for TypeScript, Svelte, Markdown, and more', glyph: '🎨', color_class: 'color_g_50' },
14
- { name: 'fuz_mastodon', url: 'https://mastodon.fuz.dev/', logo: logo_fuz_mastodon, description: 'Mastodon components and helpers for Svelte, SvelteKit, and Fuz', glyph: '🦣', color_class: 'color_d_50' },
15
14
  { name: 'fuz_repos', url: 'https://repos.fuz.dev/', logo: logo_fuz_repos, description: 'a tool for managing many repos', glyph: '🪄', color_class: 'color_a_50' },
16
15
  { name: 'svelte-docinfo', url: 'https://svelte-docinfo.fuz.dev/', logo: logo_svelte_docinfo, description: 'static analysis for TypeScript and Svelte', glyph: '📜', color_class: 'color_i_50' },
17
16
  { name: 'fuz_util', url: 'https://util.fuz.dev/', logo: logo_fuz_util, description: 'utility belt for JS', glyph: '🦕', color_class: 'color_f_50' },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fuzdev/fuz_ui",
3
- "version": "0.217.0",
3
+ "version": "0.219.0",
4
4
  "description": "Svelte UI library",
5
5
  "tagline": "friendly user zystem",
6
6
  "glyph": "🧶",
@@ -64,7 +64,7 @@
64
64
  "@changesets/changelog-git": "^0.2.1",
65
65
  "@fuzdev/blake3-wasm": "^0.2.0",
66
66
  "@fuzdev/fuz_code": "^0.54.0",
67
- "@fuzdev/fuz_css": "^0.70.0",
67
+ "@fuzdev/fuz_css": "^0.71.0",
68
68
  "@fuzdev/fuz_schema": "^0.5.0",
69
69
  "@fuzdev/fuz_util": "^0.77.0",
70
70
  "@fuzdev/gro": "^0.220.0",
@@ -82,7 +82,7 @@
82
82
  "jsdom": "^29.1.1",
83
83
  "svelte": "^5.57.2",
84
84
  "svelte-check": "^4.7.6",
85
- "svelte-docinfo": "^0.13.0",
85
+ "svelte-docinfo": "^0.14.0",
86
86
  "tslib": "^2.8.1",
87
87
  "typescript": "^6.0.3",
88
88
  "typescript-eslint": "^8.71.1",
package/src/lib/logos.ts CHANGED
@@ -96,12 +96,6 @@ export const logo_fuz_blog = {
96
96
  paths: logo_fuz.paths
97
97
  } satisfies SvgData;
98
98
 
99
- export const logo_fuz_mastodon = {
100
- label: 'a friendly purple spider facing you',
101
- fill: '#8866cc',
102
- paths: logo_fuz.paths
103
- } satisfies SvgData;
104
-
105
99
  export const logo_fuz_repos = {
106
100
  label: 'a friendly blue spider facing you',
107
101
  fill: '#6199d1',
@@ -72,10 +72,48 @@ export class Module {
72
72
  return './' + this.path;
73
73
  }
74
74
 
75
+ /**
76
+ * Prose of the `@module` comment, tag lines removed. Absent for a tag-only
77
+ * comment, whose tags still populate the doc fields below.
78
+ */
75
79
  get module_comment(): string | undefined {
76
80
  return this.module_json.moduleComment;
77
81
  }
78
82
 
83
+ get deprecated_message(): string | undefined {
84
+ return this.module_json.deprecatedMessage;
85
+ }
86
+
87
+ /**
88
+ * Internal-API marker from the module comment's `@internal` tag. Presence
89
+ * means the tag was written; an empty string is a bare tag.
90
+ */
91
+ get internal_message(): string | undefined {
92
+ return this.module_json.internalMessage;
93
+ }
94
+
95
+ get since(): string | undefined {
96
+ return this.module_json.since;
97
+ }
98
+
99
+ get examples(): NonNullable<ModuleJsonInput['examples']> {
100
+ return this.module_json.examples ?? EMPTY_ARRAY;
101
+ }
102
+
103
+ get see_also(): NonNullable<ModuleJsonInput['seeAlso']> {
104
+ return this.module_json.seeAlso ?? EMPTY_ARRAY;
105
+ }
106
+
107
+ // presence, not truthiness — a bare `@deprecated` (no message text) arrives as `''`
108
+ get is_deprecated(): boolean {
109
+ return this.deprecated_message !== undefined;
110
+ }
111
+
112
+ // presence, not truthiness — a bare `@internal` (no message text) arrives as `''`
113
+ get is_internal(): boolean {
114
+ return this.internal_message !== undefined;
115
+ }
116
+
79
117
  #declarations: Array<Declaration> | undefined;
80
118
 
81
119
  /**
@@ -121,8 +159,20 @@ export class Module {
121
159
  return this.declarations.length > 0;
122
160
  }
123
161
 
124
- get has_module_comment(): boolean {
125
- return !!this.module_comment;
162
+ /**
163
+ * Whether the module comment documents anything — prose or any doc field.
164
+ * A tag-only comment (just `@see`, say) has no `module_comment` but still
165
+ * counts.
166
+ */
167
+ get has_module_doc(): boolean {
168
+ return (
169
+ !!this.module_comment ||
170
+ this.is_deprecated ||
171
+ this.is_internal ||
172
+ !!this.since ||
173
+ this.examples.length > 0 ||
174
+ this.see_also.length > 0
175
+ );
126
176
  }
127
177
 
128
178
  /**
@@ -5,7 +5,6 @@ import {
5
5
  logo_fuz_ui,
6
6
  logo_fuz_code,
7
7
  logo_fuz_blog,
8
- logo_fuz_mastodon,
9
8
  logo_fuz_repos,
10
9
  logo_fuz_template,
11
10
  logo_fuz_css,
@@ -38,7 +37,6 @@ export const project_items: Array<ProjectItem> = [
38
37
  {name: 'fuz_template', url: 'https://template.fuz.dev/', logo: logo_fuz_template, description: 'a web app template with TypeScript + SvelteKit + optional Rust for the fuz-stack', glyph: '❄', color_class: 'color_h_50'},
39
38
  {name: 'fuz_blog', url: 'https://blog.fuz.dev/', logo: logo_fuz_blog, description: 'blog software from scratch with SvelteKit', glyph: '🖊️', color_class: 'color_e_50'},
40
39
  {name: 'fuz_code', url: 'https://code.fuz.dev/', logo: logo_fuz_code, description: 'syntax styling utilities and components for TypeScript, Svelte, Markdown, and more', glyph: '🎨', color_class: 'color_g_50'},
41
- {name: 'fuz_mastodon', url: 'https://mastodon.fuz.dev/', logo: logo_fuz_mastodon, description: 'Mastodon components and helpers for Svelte, SvelteKit, and Fuz', glyph: '🦣', color_class: 'color_d_50'},
42
40
  {name: 'fuz_repos', url: 'https://repos.fuz.dev/', logo: logo_fuz_repos, description: 'a tool for managing many repos', glyph: '🪄', color_class: 'color_a_50'},
43
41
  {name: 'svelte-docinfo', url: 'https://svelte-docinfo.fuz.dev/', logo: logo_svelte_docinfo, description: 'static analysis for TypeScript and Svelte', glyph: '📜', color_class: 'color_i_50'},
44
42
  {name: 'fuz_util', url: 'https://util.fuz.dev/', logo: logo_fuz_util, description: 'utility belt for JS', glyph: '🦕', color_class: 'color_f_50'},