Repository navigation
Commit ff064c4
refactor(canvas): migrate shared extension infrastructure (#52)
<!-- Use a conventional commit-style title, such as "fix(hub): retain
prototype history". -->
## Why
<!-- Explain the problem and why this change matters in a short,
plain-English paragraph. Link the issue when applicable. -->
Continue the canvas extension's TypeScript migration on top of #51.
Shared command, storage, and repository helpers need compiler-checked
implementations before the remaining workflows can migrate without
relying on declarations for JavaScript behavior.
## What changes
<!-- Describe what becomes different for a first-time reader. Explain
necessary terms. Include accurate Mermaid diagrams when they clarify the
proposal, using before/after diagrams when helpful. Add screenshots for
meaningful UI changes. -->
<!-- Omit validation sections, checklists, and routine test/CI summaries
such as "CI is green" or "tests passed". Mention only known verification
gaps that affect the change, not disclaimers about drafting this
description. -->
Move command execution, private storage, state-file reads and writes,
and repository identity and context to strict TypeScript sources. Remove
the temporary command declaration and share a checked error-code reader.
Parsed storage data remains unknown until its consuming workflow checks
the fields it uses; this change does not introduce a new stored-data
format.
Keep the generated runnable `.mjs` modules committed, with the same host
entry point and no compiler or package installation required for plugin
consumers. The module build now formats every compiler-emitted runtime
file rather than naming a single module. Reuse Hub's locked Node types
and document the migration boundary. Hub clients, publishing and review
workflows, servers, browser assets, and SDK registration remain outside
this layer.
---------
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 9d7306a9-9831-4c78-89e7-3c5b581c895e
Copilot-Session: 1aff284a-77f1-4bcf-8245-e30889a2f3921 parent 1f4670d commit ff064c4
23 files changed
Lines changed: 842 additions & 88 deletions
File tree
- .github/extensions/replica-prototype
- create-canvas-context
- private-store
- read-canvas-repository
- read-error-code
- read-repository-name
- read-state
- run-command
- write-state
- hub
- docs
- script
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | 3 | | |
5 | 4 | | |
6 | | - | |
7 | 5 | | |
8 | 6 | | |
9 | 7 | | |
| |||
25 | 23 | | |
26 | 24 | | |
27 | 25 | | |
28 | | - | |
29 | 26 | | |
30 | 27 | | |
31 | 28 | | |
| |||
50 | 47 | | |
51 | 48 | | |
52 | 49 | | |
53 | | - | |
54 | 50 | | |
55 | 51 | | |
56 | 52 | | |
| |||
64 | 60 | | |
65 | 61 | | |
66 | 62 | | |
67 | | - | |
68 | 63 | | |
69 | 64 | | |
70 | 65 | | |
| |||
81 | 76 | | |
82 | 77 | | |
83 | 78 | | |
84 | | - | |
85 | 79 | | |
86 | 80 | | |
87 | 81 | | |
| |||
93 | 87 | | |
94 | 88 | | |
95 | 89 | | |
96 | | - | |
97 | 90 | | |
98 | 91 | | |
99 | 92 | | |
| |||
104 | 97 | | |
105 | 98 | | |
106 | 99 | | |
107 | | - | |
108 | 100 | | |
109 | 101 | | |
110 | 102 | | |
111 | 103 | | |
112 | 104 | | |
113 | 105 | | |
114 | 106 | | |
115 | | - | |
116 | 107 | | |
117 | 108 | | |
118 | | - | |
119 | 109 | | |
120 | 110 | | |
121 | 111 | | |
122 | 112 | | |
123 | 113 | | |
124 | 114 | | |
125 | 115 | | |
126 | | - | |
127 | 116 | | |
128 | 117 | | |
129 | | - | |
130 | 118 | | |
131 | 119 | | |
132 | 120 | | |
| |||
147 | 135 | | |
148 | 136 | | |
149 | 137 | | |
150 | | - | |
151 | 138 | | |
152 | 139 | | |
153 | 140 | | |
154 | 141 | | |
155 | 142 | | |
156 | 143 | | |
157 | 144 | | |
158 | | - | |
159 | 145 | | |
160 | 146 | | |
161 | 147 | | |
| |||
174 | 160 | | |
175 | 161 | | |
176 | 162 | | |
177 | | - | |
178 | 163 | | |
179 | 164 | | |
180 | 165 | | |
| |||
183 | 168 | | |
184 | 169 | | |
185 | 170 | | |
186 | | - | |
187 | 171 | | |
188 | 172 | | |
189 | 173 | | |
| |||
206 | 190 | | |
207 | 191 | | |
208 | 192 | | |
209 | | - | |
210 | 193 | | |
211 | 194 | | |
212 | | - | |
213 | 195 | | |
214 | 196 | | |
215 | 197 | | |
| |||
235 | 217 | | |
236 | 218 | | |
237 | 219 | | |
238 | | - | |
239 | 220 | | |
240 | 221 | | |
241 | 222 | | |
242 | 223 | | |
243 | 224 | | |
244 | 225 | | |
245 | 226 | | |
246 | | - | |
247 | 227 | | |
248 | 228 | | |
249 | | - | |
250 | 229 | | |
251 | 230 | | |
252 | 231 | | |
253 | 232 | | |
254 | | - | |
255 | 233 | | |
256 | 234 | | |
257 | 235 | | |
| |||
261 | 239 | | |
262 | 240 | | |
263 | 241 | | |
264 | | - | |
265 | 242 | | |
266 | 243 | | |
0 commit comments