create-foldkit-app 0.40.0 → 0.41.0-canary.54f8bcd443b4
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.
- package/README.md +3 -3
- package/dist/examples.js +4 -4
- package/dist/templates/base/AGENTS.md +22 -0
- package/dist/templates/base/FOLDKIT.md +281 -45
- package/dist/templates/examples/api-cache/package.json +7 -6
- package/dist/templates/examples/api-cache/src/block.ts +24 -0
- package/dist/templates/examples/api-cache/src/command.ts +66 -0
- package/dist/templates/examples/api-cache/src/composition.ts +79 -0
- package/dist/templates/examples/api-cache/src/effectsLayer.ts +11 -0
- package/dist/templates/examples/api-cache/src/entry.ts +7 -12
- package/dist/templates/examples/api-cache/src/index.ts +2 -0
- package/dist/templates/examples/api-cache/src/init.ts +16 -0
- package/dist/templates/examples/api-cache/src/layer.ts +18 -0
- package/dist/templates/examples/api-cache/src/message.ts +24 -0
- package/dist/templates/examples/api-cache/src/model.fixture.ts +128 -0
- package/dist/templates/examples/api-cache/src/model.ts +45 -0
- package/dist/templates/examples/api-cache/src/scene.test.ts +118 -101
- package/dist/templates/examples/api-cache/src/story.test.ts +309 -245
- package/dist/templates/examples/api-cache/src/subscription.ts +33 -0
- package/dist/templates/examples/api-cache/src/update.ts +75 -0
- package/dist/templates/examples/api-cache/src/view/posts.ts +260 -0
- package/dist/templates/examples/api-cache/src/view/shared.ts +63 -0
- package/dist/templates/examples/api-cache/src/view/stats.ts +140 -0
- package/dist/templates/examples/api-cache/src/view/view.ts +78 -0
- package/dist/templates/examples/api-cache-query/package.json +7 -6
- package/dist/templates/examples/api-cache-query/src/block.ts +23 -0
- package/dist/templates/examples/api-cache-query/src/composition.ts +54 -0
- package/dist/templates/examples/api-cache-query/src/effectsLayer.ts +3 -0
- package/dist/templates/examples/api-cache-query/src/entry.ts +7 -13
- package/dist/templates/examples/api-cache-query/src/index.ts +2 -0
- package/dist/templates/examples/api-cache-query/src/init.ts +11 -0
- package/dist/templates/examples/api-cache-query/src/layer.ts +19 -0
- package/dist/templates/examples/api-cache-query/src/message.ts +14 -0
- package/dist/templates/examples/api-cache-query/src/model.fixture.ts +135 -0
- package/dist/templates/examples/api-cache-query/src/model.ts +22 -0
- package/dist/templates/examples/api-cache-query/src/query.ts +78 -0
- package/dist/templates/examples/api-cache-query/src/scene.test.ts +123 -103
- package/dist/templates/examples/api-cache-query/src/story.test.ts +323 -254
- package/dist/templates/examples/api-cache-query/src/subscription.ts +33 -0
- package/dist/templates/examples/api-cache-query/src/update.ts +33 -0
- package/dist/templates/examples/api-cache-query/src/view/index.ts +1 -0
- package/dist/templates/examples/api-cache-query/src/view/posts.ts +243 -0
- package/dist/templates/examples/api-cache-query/src/view/shared.ts +67 -0
- package/dist/templates/examples/api-cache-query/src/view/stats.ts +132 -0
- package/dist/templates/examples/api-cache-query/src/view/view.ts +101 -0
- package/dist/templates/examples/auth/package.json +7 -6
- package/dist/templates/examples/auth/src/block.ts +27 -0
- package/dist/templates/examples/auth/src/blocks/index.ts +4 -0
- package/dist/templates/examples/auth/src/blocks/loggedIn/block.ts +19 -0
- package/dist/templates/examples/auth/src/blocks/loggedIn/composition.ts +8 -0
- package/dist/templates/examples/auth/src/blocks/loggedIn/index.ts +2 -0
- package/dist/templates/examples/auth/src/blocks/loggedIn/init.ts +10 -0
- package/dist/templates/examples/auth/src/blocks/loggedIn/layer.ts +10 -0
- package/dist/templates/examples/auth/src/{page → blocks}/loggedIn/message.ts +0 -6
- package/dist/templates/examples/auth/src/{page → blocks}/loggedIn/model.ts +0 -11
- package/dist/templates/examples/auth/src/{page → blocks}/loggedIn/page/dashboard.ts +4 -8
- package/dist/templates/examples/auth/src/{page → blocks}/loggedIn/page/settings.ts +4 -5
- package/dist/templates/examples/auth/src/blocks/loggedIn/update.ts +7 -0
- package/dist/templates/examples/auth/src/{page → blocks}/loggedIn/view.ts +4 -6
- package/dist/templates/examples/auth/src/blocks/loggedOut/block.ts +23 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/blocks/index.ts +2 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/blocks/login/block.ts +45 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/blocks/login/composition.ts +6 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/blocks/login/index.ts +2 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/blocks/login/layer.ts +10 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/blocks/login/login.ts +123 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/blocks/login/scene.test.ts +110 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/blocks/login/story.test.ts +105 -0
- package/dist/templates/examples/auth/src/{page/loggedOut/page/login.ts → blocks/loggedOut/blocks/login/view.ts} +10 -157
- package/dist/templates/examples/auth/src/blocks/loggedOut/composition.ts +25 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/index.ts +2 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/init.ts +6 -0
- package/dist/templates/examples/auth/src/blocks/loggedOut/layer.ts +13 -0
- package/dist/templates/examples/auth/src/{page → blocks}/loggedOut/message.ts +1 -11
- package/dist/templates/examples/auth/src/{page → blocks}/loggedOut/model.ts +2 -13
- package/dist/templates/examples/auth/src/{page → blocks}/loggedOut/page/home.ts +5 -5
- package/dist/templates/examples/auth/src/blocks/loggedOut/update.ts +3 -0
- package/dist/templates/examples/auth/src/{page → blocks}/loggedOut/view.ts +8 -11
- package/dist/templates/examples/auth/src/command.ts +85 -32
- package/dist/templates/examples/auth/src/composition/bindings.ts +8 -0
- package/dist/templates/examples/auth/src/composition/composition.ts +7 -0
- package/dist/templates/examples/auth/src/composition/index.ts +3 -0
- package/dist/templates/examples/auth/src/composition/loggedIn.ts +18 -0
- package/dist/templates/examples/auth/src/composition/loggedOut.ts +18 -0
- package/dist/templates/examples/auth/src/domain/session.ts +1 -1
- package/dist/templates/examples/auth/src/effectsLayer.ts +23 -0
- package/dist/templates/examples/auth/src/entry.ts +11 -17
- package/dist/templates/examples/auth/src/flags.ts +27 -0
- package/dist/templates/examples/auth/src/index.ts +2 -0
- package/dist/templates/examples/auth/src/init.ts +53 -0
- package/dist/templates/examples/auth/src/layer.ts +15 -0
- package/dist/templates/examples/auth/src/message.ts +3 -5
- package/dist/templates/examples/auth/src/model.ts +5 -5
- package/dist/templates/examples/auth/src/route.ts +18 -13
- package/dist/templates/examples/auth/src/scene.test.ts +35 -38
- package/dist/templates/examples/auth/src/services.ts +3 -0
- package/dist/templates/examples/auth/src/update.ts +63 -156
- package/dist/templates/examples/auth/src/view.ts +23 -22
- package/dist/templates/examples/canvas-art/package.json +7 -6
- package/dist/templates/examples/canvas-art/src/{main.ts → block.ts} +132 -81
- package/dist/templates/examples/canvas-art/src/entry.ts +7 -12
- package/dist/templates/examples/canvas-art/src/scene.test.ts +39 -35
- package/dist/templates/examples/canvas-art/src/story.test.ts +125 -110
- package/dist/templates/examples/charting/package.json +7 -6
- package/dist/templates/examples/charting/src/block.ts +28 -0
- package/dist/templates/examples/charting/src/chartRegistry.ts +42 -0
- package/dist/templates/examples/charting/src/command.ts +52 -39
- package/dist/templates/examples/charting/src/composition.ts +125 -0
- package/dist/templates/examples/charting/src/domain.ts +0 -6
- package/dist/templates/examples/charting/src/effectsLayer.ts +10 -0
- package/dist/templates/examples/charting/src/entry.ts +8 -15
- package/dist/templates/examples/charting/src/githubApi.ts +19 -30
- package/dist/templates/examples/charting/src/http.ts +0 -4
- package/dist/templates/examples/charting/src/index.ts +2 -0
- package/dist/templates/examples/charting/src/init.ts +4 -15
- package/dist/templates/examples/charting/src/layer.ts +16 -0
- package/dist/templates/examples/charting/src/message.ts +3 -7
- package/dist/templates/examples/charting/src/{main.fixture.ts → model.fixture.ts} +15 -5
- package/dist/templates/examples/charting/src/model.ts +8 -5
- package/dist/templates/examples/charting/src/mount.ts +136 -0
- package/dist/templates/examples/charting/src/npmApi.ts +6 -9
- package/dist/templates/examples/charting/src/radioGroups.ts +3 -3
- package/dist/templates/examples/charting/src/scene.test.ts +54 -63
- package/dist/templates/examples/charting/src/services.ts +15 -0
- package/dist/templates/examples/charting/src/story.test.ts +119 -90
- package/dist/templates/examples/charting/src/telemetry.ts +87 -87
- package/dist/templates/examples/charting/src/update.ts +53 -183
- package/dist/templates/examples/charting/src/view/chart.ts +9 -122
- package/dist/templates/examples/charting/src/view/layout.ts +8 -8
- package/dist/templates/examples/charting/src/view/sidebar.ts +114 -115
- package/dist/templates/examples/charting/src/view/view.ts +3 -7
- package/dist/templates/examples/charting/src/weeks.ts +0 -4
- package/dist/templates/examples/counter/package.json +7 -6
- package/dist/templates/examples/counter/src/{main.ts → block.ts} +36 -28
- package/dist/templates/examples/counter/src/entry.ts +7 -11
- package/dist/templates/examples/counter/src/scene.test.ts +54 -52
- package/dist/templates/examples/counter/src/story.test.ts +52 -50
- package/dist/templates/examples/counters/package.json +7 -6
- package/dist/templates/examples/counters/src/block.ts +158 -0
- package/dist/templates/examples/counters/src/{counter.ts → blocks/counter/block.ts} +35 -24
- package/dist/templates/examples/counters/src/blocks/counter/index.ts +3 -0
- package/dist/templates/examples/counters/src/blocks/index.ts +2 -0
- package/dist/templates/examples/counters/src/entry.ts +7 -11
- package/dist/templates/examples/counters/src/scene.test.ts +94 -79
- package/dist/templates/examples/counters/src/story.test.ts +184 -103
- package/dist/templates/examples/crash-view/package.json +7 -6
- package/dist/templates/examples/crash-view/src/{main.ts → block.ts} +35 -20
- package/dist/templates/examples/crash-view/src/entry.ts +8 -13
- package/dist/templates/examples/crash-view/src/scene.test.ts +12 -10
- package/dist/templates/examples/crash-view/src/story.test.ts +19 -7
- package/dist/templates/examples/embedding/package.json +7 -6
- package/dist/templates/examples/embedding/src/{main.ts → block.ts} +77 -68
- package/dist/templates/examples/embedding/src/host.ts +13 -4
- package/dist/templates/examples/embedding/src/scene.test.ts +31 -21
- package/dist/templates/examples/embedding/src/story.test.ts +58 -46
- package/dist/templates/examples/form/package.json +7 -6
- package/dist/templates/examples/form/src/block.ts +17 -0
- package/dist/templates/examples/form/src/command.ts +63 -0
- package/dist/templates/examples/form/src/composition.ts +8 -0
- package/dist/templates/examples/form/src/effectsLayer.ts +8 -0
- package/dist/templates/examples/form/src/entry.ts +7 -11
- package/dist/templates/examples/form/src/index.ts +2 -0
- package/dist/templates/examples/form/src/init.ts +15 -0
- package/dist/templates/examples/form/src/layer.ts +12 -0
- package/dist/templates/examples/form/src/message.ts +14 -0
- package/dist/templates/examples/form/src/model.ts +19 -0
- package/dist/templates/examples/form/src/scene.test.ts +131 -111
- package/dist/templates/examples/form/src/story.test.ts +157 -143
- package/dist/templates/examples/form/src/update.ts +72 -0
- package/dist/templates/examples/form/src/validation.ts +21 -0
- package/dist/templates/examples/form/src/{main.ts → view.ts} +20 -236
- package/dist/templates/examples/generative-art/package.json +7 -6
- package/dist/templates/examples/generative-art/src/block.ts +24 -0
- package/dist/templates/examples/generative-art/src/command.ts +81 -79
- package/dist/templates/examples/generative-art/src/composition.ts +70 -0
- package/dist/templates/examples/generative-art/src/effectsLayer.ts +10 -0
- package/dist/templates/examples/generative-art/src/entry.ts +7 -10
- package/dist/templates/examples/generative-art/src/index.ts +2 -0
- package/dist/templates/examples/generative-art/src/{main.ts → init.ts} +3 -22
- package/dist/templates/examples/generative-art/src/layer.ts +18 -0
- package/dist/templates/examples/generative-art/src/message.ts +4 -5
- package/dist/templates/examples/generative-art/src/model.ts +2 -2
- package/dist/templates/examples/generative-art/src/scene.test.ts +57 -49
- package/dist/templates/examples/generative-art/src/story.test.ts +143 -129
- package/dist/templates/examples/generative-art/src/subscription.ts +21 -32
- package/dist/templates/examples/generative-art/src/update.ts +58 -114
- package/dist/templates/examples/generative-art/src/view.ts +101 -66
- package/dist/templates/examples/interrupting-commands/package.json +7 -6
- package/dist/templates/examples/interrupting-commands/src/block.ts +22 -0
- package/dist/templates/examples/interrupting-commands/src/command.ts +32 -0
- package/dist/templates/examples/interrupting-commands/src/composition.ts +8 -0
- package/dist/templates/examples/interrupting-commands/src/entry.ts +7 -11
- package/dist/templates/examples/interrupting-commands/src/index.ts +2 -0
- package/dist/templates/examples/interrupting-commands/src/init.ts +8 -0
- package/dist/templates/examples/interrupting-commands/src/layer.ts +12 -0
- package/dist/templates/examples/interrupting-commands/src/message.ts +16 -0
- package/dist/templates/examples/interrupting-commands/src/model.ts +18 -0
- package/dist/templates/examples/interrupting-commands/src/scene.test.ts +83 -75
- package/dist/templates/examples/interrupting-commands/src/story.test.ts +146 -141
- package/dist/templates/examples/interrupting-commands/src/update.ts +100 -0
- package/dist/templates/examples/interrupting-commands/src/view.ts +169 -0
- package/dist/templates/examples/job-application/package.json +7 -6
- package/dist/templates/examples/job-application/src/block.ts +28 -0
- package/dist/templates/examples/job-application/src/blocks/attachments/block.ts +36 -0
- package/dist/templates/examples/job-application/src/blocks/attachments/composition.ts +52 -0
- package/dist/templates/examples/job-application/src/blocks/attachments/index.ts +2 -0
- package/dist/templates/examples/job-application/src/blocks/attachments/init.ts +10 -0
- package/dist/templates/examples/job-application/src/blocks/attachments/layer.ts +14 -0
- package/dist/templates/examples/job-application/src/blocks/attachments/scene.test.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/attachments/story.test.ts +46 -0
- package/dist/templates/examples/job-application/src/blocks/attachments/update.ts +14 -0
- package/dist/templates/examples/job-application/src/{step → blocks}/attachments/view.ts +65 -62
- package/dist/templates/examples/job-application/src/{step/coverLetter/coverLetter.ts → blocks/coverLetter/block.ts} +30 -25
- package/dist/templates/examples/job-application/src/blocks/coverLetter/index.ts +3 -0
- package/dist/templates/examples/job-application/src/blocks/coverLetter/scene.test.ts +26 -0
- package/dist/templates/examples/job-application/src/blocks/coverLetter/story.test.ts +23 -0
- package/dist/templates/examples/job-application/src/blocks/education/block.ts +48 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/block.ts +60 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/composition.ts +30 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/inMessageUpdate.ts +12 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/index.ts +3 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/init.ts +16 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/layer.ts +16 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/story.test.ts +42 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/update.ts +29 -0
- package/dist/templates/examples/job-application/src/blocks/education/blocks/educationEntry/validation.ts +25 -0
- package/dist/templates/examples/job-application/src/{step/education/entry → blocks/education/blocks/educationEntry}/view.ts +49 -48
- package/dist/templates/examples/job-application/src/blocks/education/blocks/index.ts +2 -0
- package/dist/templates/examples/job-application/src/blocks/education/command.ts +23 -0
- package/dist/templates/examples/job-application/src/blocks/education/composition.ts +35 -0
- package/dist/templates/examples/job-application/src/blocks/education/inMessageUpdate.ts +14 -0
- package/dist/templates/examples/job-application/src/blocks/education/index.ts +3 -0
- package/dist/templates/examples/job-application/src/blocks/education/init.ts +10 -0
- package/dist/templates/examples/job-application/src/blocks/education/layer.ts +17 -0
- package/dist/templates/examples/job-application/src/blocks/education/scene.test.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/education/story.test.ts +69 -0
- package/dist/templates/examples/job-application/src/blocks/education/update.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/education/validation.ts +11 -0
- package/dist/templates/examples/job-application/src/{step → blocks}/education/view.ts +21 -15
- package/dist/templates/examples/job-application/src/blocks/index.ts +15 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/block.ts +67 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/command.ts +41 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/composition.ts +54 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/inMessageUpdate.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/index.ts +3 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/init.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/layer.ts +18 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/scene.test.ts +52 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/story.test.ts +120 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/update.ts +69 -0
- package/dist/templates/examples/job-application/src/blocks/personalInfo/validation.ts +58 -0
- package/dist/templates/examples/job-application/src/{step → blocks}/personalInfo/view.ts +79 -75
- package/dist/templates/examples/job-application/src/blocks/skills/block.ts +44 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/index.ts +2 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/block.ts +55 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/composition.ts +31 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/inMessageUpdate.ts +10 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/index.ts +3 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/init.ts +12 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/layer.ts +16 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/story.test.ts +30 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/update.ts +15 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/validation.ts +11 -0
- package/dist/templates/examples/job-application/src/blocks/skills/blocks/skillsEntry/view.ts +100 -0
- package/dist/templates/examples/job-application/src/blocks/skills/command.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/skills/composition.ts +31 -0
- package/dist/templates/examples/job-application/src/blocks/skills/inMessageUpdate.ts +14 -0
- package/dist/templates/examples/job-application/src/blocks/skills/index.ts +3 -0
- package/dist/templates/examples/job-application/src/blocks/skills/init.ts +6 -0
- package/dist/templates/examples/job-application/src/blocks/skills/layer.ts +17 -0
- package/dist/templates/examples/job-application/src/blocks/skills/scene.test.ts +17 -0
- package/dist/templates/examples/job-application/src/blocks/skills/story.test.ts +68 -0
- package/dist/templates/examples/job-application/src/blocks/skills/update.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/skills/validation.ts +11 -0
- package/dist/templates/examples/job-application/src/{step → blocks}/skills/view.ts +10 -13
- package/dist/templates/examples/job-application/src/blocks/workHistory/block.ts +48 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/index.ts +2 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/block.ts +63 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/composition.ts +78 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/inMessageUpdate.ts +11 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/index.ts +3 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/init.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/layer.ts +16 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/story.test.ts +44 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/update.ts +28 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/blocks/workHistoryEntry/validation.ts +20 -0
- package/dist/templates/examples/job-application/src/{step/workHistory/entry → blocks/workHistory/blocks/workHistoryEntry}/view.ts +44 -42
- package/dist/templates/examples/job-application/src/blocks/workHistory/command.ts +23 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/composition.ts +31 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/inMessageUpdate.ts +14 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/index.ts +3 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/init.ts +10 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/layer.ts +17 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/scene.test.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/story.test.ts +73 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/update.ts +20 -0
- package/dist/templates/examples/job-application/src/blocks/workHistory/validation.ts +11 -0
- package/dist/templates/examples/job-application/src/{step → blocks}/workHistory/view.ts +10 -16
- package/dist/templates/examples/job-application/src/command.ts +9 -8
- package/dist/templates/examples/job-application/src/composition.ts +99 -0
- package/dist/templates/examples/job-application/src/entry.ts +9 -11
- package/dist/templates/examples/job-application/src/flags.ts +27 -0
- package/dist/templates/examples/job-application/src/index.ts +2 -0
- package/dist/templates/examples/job-application/src/init.ts +13 -0
- package/dist/templates/examples/job-application/src/layer.ts +37 -0
- package/dist/templates/examples/job-application/src/message.ts +0 -20
- package/dist/templates/examples/job-application/src/model.fixture.ts +94 -0
- package/dist/templates/examples/job-application/src/model.ts +11 -16
- package/dist/templates/examples/job-application/src/navigationComponents.ts +6 -0
- package/dist/templates/examples/job-application/src/scene.test.ts +240 -185
- package/dist/templates/examples/job-application/src/services.ts +3 -0
- package/dist/templates/examples/job-application/src/story.test.ts +345 -279
- package/dist/templates/examples/job-application/src/update.ts +52 -154
- package/dist/templates/examples/job-application/src/view/preview.ts +23 -9
- package/dist/templates/examples/job-application/src/view/review.ts +29 -18
- package/dist/templates/examples/job-application/src/view/stepNav.ts +53 -56
- package/dist/templates/examples/job-application/src/view/view.ts +122 -120
- package/dist/templates/examples/kanban/package.json +7 -6
- package/dist/templates/examples/kanban/src/block.ts +30 -0
- package/dist/templates/examples/kanban/src/command.ts +36 -29
- package/dist/templates/examples/kanban/src/composition/composition.ts +11 -0
- package/dist/templates/examples/kanban/src/composition/dragAndDrop.ts +99 -0
- package/dist/templates/examples/kanban/src/composition/index.ts +3 -0
- package/dist/templates/examples/kanban/src/domain/card.ts +0 -1
- package/dist/templates/examples/kanban/src/domain/column.ts +4 -2
- package/dist/templates/examples/kanban/src/effectsLayer.ts +9 -0
- package/dist/templates/examples/kanban/src/entry.ts +9 -21
- package/dist/templates/examples/kanban/src/flags.ts +24 -0
- package/dist/templates/examples/kanban/src/index.ts +2 -0
- package/dist/templates/examples/kanban/src/init.ts +21 -0
- package/dist/templates/examples/kanban/src/layer.ts +16 -0
- package/dist/templates/examples/kanban/src/message.ts +0 -4
- package/dist/templates/examples/kanban/src/model.ts +2 -3
- package/dist/templates/examples/kanban/src/scene.test.ts +97 -94
- package/dist/templates/examples/kanban/src/services.ts +8 -0
- package/dist/templates/examples/kanban/src/story.test.ts +221 -211
- package/dist/templates/examples/kanban/src/update.ts +49 -185
- package/dist/templates/examples/kanban/src/view/card.ts +14 -21
- package/dist/templates/examples/kanban/src/view/column.ts +46 -54
- package/dist/templates/examples/kanban/src/view/view.ts +53 -20
- package/dist/templates/examples/managed-resource-layer/package.json +7 -6
- package/dist/templates/examples/managed-resource-layer/src/{main.ts → block.ts} +126 -113
- package/dist/templates/examples/managed-resource-layer/src/entry.ts +8 -12
- package/dist/templates/examples/managed-resource-layer/src/scene.test.ts +89 -84
- package/dist/templates/examples/managed-resource-layer/src/services.ts +3 -0
- package/dist/templates/examples/managed-resource-layer/src/story.test.ts +88 -68
- package/dist/templates/examples/map/package.json +7 -6
- package/dist/templates/examples/map/src/block.ts +24 -0
- package/dist/templates/examples/map/src/command.ts +137 -0
- package/dist/templates/examples/map/src/composition.ts +11 -0
- package/dist/templates/examples/map/src/effectsLayer.ts +19 -0
- package/dist/templates/examples/map/src/entry.ts +8 -11
- package/dist/templates/examples/map/src/index.ts +2 -0
- package/dist/templates/examples/map/src/init.ts +20 -0
- package/dist/templates/examples/map/src/layer.ts +12 -0
- package/dist/templates/examples/map/src/mapRegistry.ts +42 -0
- package/dist/templates/examples/map/src/message.ts +32 -0
- package/dist/templates/examples/map/src/{main.fixture.ts → model.fixture.ts} +1 -1
- package/dist/templates/examples/map/src/model.ts +34 -0
- package/dist/templates/examples/map/src/mount.test.ts +5 -3
- package/dist/templates/examples/map/src/mount.ts +180 -0
- package/dist/templates/examples/map/src/scene.test.ts +90 -97
- package/dist/templates/examples/map/src/services.ts +3 -0
- package/dist/templates/examples/map/src/story.test.ts +160 -147
- package/dist/templates/examples/map/src/update.ts +101 -0
- package/dist/templates/examples/map/src/view.ts +359 -0
- package/dist/templates/examples/pixel-art/package.json +7 -6
- package/dist/templates/examples/pixel-art/src/{main.bench.ts → app.bench.ts} +78 -53
- package/dist/templates/examples/pixel-art/src/block.ts +29 -0
- package/dist/templates/examples/pixel-art/src/command.ts +52 -48
- package/dist/templates/examples/pixel-art/src/comparison.bench.test.ts +138 -143
- package/dist/templates/examples/pixel-art/src/components.ts +12 -0
- package/dist/templates/examples/pixel-art/src/composition.ts +135 -0
- package/dist/templates/examples/pixel-art/src/effectsLayer.ts +10 -0
- package/dist/templates/examples/pixel-art/src/entry.ts +9 -21
- package/dist/templates/examples/pixel-art/src/flags.ts +24 -0
- package/dist/templates/examples/pixel-art/src/index.ts +2 -0
- package/dist/templates/examples/pixel-art/src/init.ts +39 -0
- package/dist/templates/examples/pixel-art/src/layer.ts +20 -0
- package/dist/templates/examples/pixel-art/src/message.ts +3 -9
- package/dist/templates/examples/pixel-art/src/model.ts +19 -10
- package/dist/templates/examples/pixel-art/src/scene.test.ts +260 -196
- package/dist/templates/examples/pixel-art/src/services.ts +3 -0
- package/dist/templates/examples/pixel-art/src/steps.ts +52 -0
- package/dist/templates/examples/pixel-art/src/story.test.ts +349 -278
- package/dist/templates/examples/pixel-art/src/subscription.ts +46 -29
- package/dist/templates/examples/pixel-art/src/update.ts +200 -436
- package/dist/templates/examples/pixel-art/src/view/canvas.ts +4 -3
- package/dist/templates/examples/pixel-art/src/view/dialog.ts +148 -134
- package/dist/templates/examples/pixel-art/src/view/history.ts +5 -4
- package/dist/templates/examples/pixel-art/src/view/toolbar.ts +192 -183
- package/dist/templates/examples/pixel-art/src/view/view.ts +8 -11
- package/dist/templates/examples/query-sync/package.json +7 -6
- package/dist/templates/examples/query-sync/src/block.ts +24 -0
- package/dist/templates/examples/query-sync/src/command.ts +40 -0
- package/dist/templates/examples/query-sync/src/composition.ts +60 -0
- package/dist/templates/examples/query-sync/src/effectsLayer.ts +9 -0
- package/dist/templates/examples/query-sync/src/entry.ts +9 -13
- package/dist/templates/examples/query-sync/src/index.ts +2 -0
- package/dist/templates/examples/query-sync/src/init.ts +12 -0
- package/dist/templates/examples/query-sync/src/layer.ts +16 -0
- package/dist/templates/examples/query-sync/src/message.ts +17 -0
- package/dist/templates/examples/query-sync/src/model.ts +22 -0
- package/dist/templates/examples/query-sync/src/route.ts +174 -0
- package/dist/templates/examples/query-sync/src/scene.test.ts +94 -48
- package/dist/templates/examples/query-sync/src/story.test.ts +134 -84
- package/dist/templates/examples/query-sync/src/update.ts +57 -0
- package/dist/templates/examples/query-sync/src/view.ts +530 -0
- package/dist/templates/examples/route-transitions/package.json +7 -6
- package/dist/templates/examples/route-transitions/src/block.ts +25 -0
- package/dist/templates/examples/route-transitions/src/command.ts +59 -0
- package/dist/templates/examples/route-transitions/src/composition.ts +8 -0
- package/dist/templates/examples/route-transitions/src/effectsLayer.ts +17 -0
- package/dist/templates/examples/route-transitions/src/entry.ts +9 -13
- package/dist/templates/examples/route-transitions/src/index.ts +2 -0
- package/dist/templates/examples/route-transitions/src/init.ts +21 -0
- package/dist/templates/examples/route-transitions/src/layer.ts +12 -0
- package/dist/templates/examples/route-transitions/src/message.ts +16 -0
- package/dist/templates/examples/route-transitions/src/model.ts +31 -0
- package/dist/templates/examples/route-transitions/src/route.ts +8 -9
- package/dist/templates/examples/route-transitions/src/steps.ts +94 -0
- package/dist/templates/examples/route-transitions/src/story.test.ts +170 -151
- package/dist/templates/examples/route-transitions/src/update.ts +61 -0
- package/dist/templates/examples/route-transitions/src/{main.ts → view.ts} +35 -279
- package/dist/templates/examples/routing/package.json +7 -6
- package/dist/templates/examples/routing/src/block.ts +27 -0
- package/dist/templates/examples/routing/src/blocks/index.ts +2 -0
- package/dist/templates/examples/routing/src/blocks/people/block.ts +25 -0
- package/dist/templates/examples/routing/src/blocks/people/command.ts +34 -0
- package/dist/templates/examples/routing/src/blocks/people/composition.ts +6 -0
- package/dist/templates/examples/routing/src/blocks/people/inMessage.ts +8 -0
- package/dist/templates/examples/routing/src/blocks/people/inMessageUpdate.ts +20 -0
- package/dist/templates/examples/routing/src/blocks/people/index.ts +3 -0
- package/dist/templates/examples/routing/src/blocks/people/layer.ts +17 -0
- package/dist/templates/examples/routing/src/blocks/people/message.ts +15 -0
- package/dist/templates/examples/routing/src/blocks/people/model.ts +71 -0
- package/dist/templates/examples/routing/src/blocks/people/scene.test.ts +44 -0
- package/dist/templates/examples/routing/src/blocks/people/story.test.ts +73 -0
- package/dist/templates/examples/routing/src/blocks/people/update.ts +43 -0
- package/dist/templates/examples/routing/src/blocks/people/view.ts +146 -0
- package/dist/templates/examples/routing/src/command.ts +23 -0
- package/dist/templates/examples/routing/src/composition.ts +16 -0
- package/dist/templates/examples/routing/src/effectsLayer.ts +10 -0
- package/dist/templates/examples/routing/src/entry.ts +9 -14
- package/dist/templates/examples/routing/src/fileTree.ts +1 -1
- package/dist/templates/examples/routing/src/index.ts +2 -0
- package/dist/templates/examples/routing/src/init.ts +19 -0
- package/dist/templates/examples/routing/src/layer.ts +17 -0
- package/dist/templates/examples/routing/src/message.ts +16 -0
- package/dist/templates/examples/routing/src/model.ts +10 -0
- package/dist/templates/examples/routing/src/route.ts +11 -12
- package/dist/templates/examples/routing/src/scene.test.ts +116 -105
- package/dist/templates/examples/routing/src/story.test.ts +204 -174
- package/dist/templates/examples/routing/src/subscription.ts +37 -0
- package/dist/templates/examples/routing/src/update.ts +82 -0
- package/dist/templates/examples/routing/src/{main.ts → view.ts} +31 -203
- package/dist/templates/examples/shopping-cart/package.json +7 -6
- package/dist/templates/examples/shopping-cart/src/block.ts +24 -0
- package/dist/templates/examples/shopping-cart/src/blocks/index.ts +2 -0
- package/dist/templates/examples/shopping-cart/src/blocks/products/block.ts +44 -0
- package/dist/templates/examples/shopping-cart/src/blocks/products/composition.ts +3 -0
- package/dist/templates/examples/shopping-cart/src/blocks/products/index.ts +2 -0
- package/dist/templates/examples/shopping-cart/src/blocks/products/layer.ts +10 -0
- package/dist/templates/examples/shopping-cart/src/blocks/products/products.ts +57 -0
- package/dist/templates/examples/shopping-cart/src/blocks/products/scene.test.ts +21 -0
- package/dist/templates/examples/shopping-cart/src/blocks/products/story.test.ts +58 -0
- package/dist/templates/examples/shopping-cart/src/{page/products.ts → blocks/products/view.ts} +6 -96
- package/dist/templates/examples/shopping-cart/src/command.ts +23 -0
- package/dist/templates/examples/shopping-cart/src/composition.ts +38 -0
- package/dist/templates/examples/shopping-cart/src/data/products.ts +1 -1
- package/dist/templates/examples/shopping-cart/src/domain/item.ts +0 -2
- package/dist/templates/examples/shopping-cart/src/effectsLayer.ts +8 -0
- package/dist/templates/examples/shopping-cart/src/entry.ts +9 -13
- package/dist/templates/examples/shopping-cart/src/index.ts +2 -0
- package/dist/templates/examples/shopping-cart/src/init.ts +15 -0
- package/dist/templates/examples/shopping-cart/src/layer.ts +15 -0
- package/dist/templates/examples/shopping-cart/src/message.ts +18 -0
- package/dist/templates/examples/shopping-cart/src/model.ts +14 -0
- package/dist/templates/examples/shopping-cart/src/page/cart.ts +4 -5
- package/dist/templates/examples/shopping-cart/src/page/checkout.ts +4 -5
- package/dist/templates/examples/shopping-cart/src/page/index.ts +0 -1
- package/dist/templates/examples/shopping-cart/src/route.ts +10 -14
- package/dist/templates/examples/shopping-cart/src/scene.test.ts +119 -96
- package/dist/templates/examples/shopping-cart/src/story.test.ts +154 -142
- package/dist/templates/examples/shopping-cart/src/update.ts +47 -0
- package/dist/templates/examples/shopping-cart/src/view.ts +153 -0
- package/dist/templates/examples/slow-warnings/package.json +7 -6
- package/dist/templates/examples/slow-warnings/src/block.ts +18 -0
- package/dist/templates/examples/slow-warnings/src/composition.ts +8 -0
- package/dist/templates/examples/slow-warnings/src/entry.ts +8 -20
- package/dist/templates/examples/slow-warnings/src/handleSlow.test.ts +3 -1
- package/dist/templates/examples/slow-warnings/src/index.ts +2 -0
- package/dist/templates/examples/slow-warnings/src/init.ts +12 -0
- package/dist/templates/examples/slow-warnings/src/layer.ts +13 -0
- package/dist/templates/examples/slow-warnings/src/message.ts +13 -0
- package/dist/templates/examples/slow-warnings/src/model.ts +37 -0
- package/dist/templates/examples/slow-warnings/src/scene.test.ts +36 -31
- package/dist/templates/examples/slow-warnings/src/story.test.ts +98 -88
- package/dist/templates/examples/slow-warnings/src/subscription.ts +108 -0
- package/dist/templates/examples/slow-warnings/src/update.ts +46 -0
- package/dist/templates/examples/slow-warnings/src/{main.ts → view.ts} +23 -252
- package/dist/templates/examples/slow-warnings/src/workload.ts +19 -0
- package/dist/templates/examples/snake/package.json +7 -6
- package/dist/templates/examples/snake/src/block.ts +371 -0
- package/dist/templates/examples/snake/src/domain/position.ts +1 -2
- package/dist/templates/examples/snake/src/entry.ts +7 -12
- package/dist/templates/examples/snake/src/scene.test.ts +54 -52
- package/dist/templates/examples/snake/src/story.test.ts +124 -107
- package/dist/templates/examples/ssg/package.json +4 -4
- package/dist/templates/examples/ssg/src/{main.ts → block.ts} +81 -56
- package/dist/templates/examples/ssg/src/entry.server.ts +3 -2
- package/dist/templates/examples/ssg/src/entry.ts +9 -13
- package/dist/templates/examples/ssg/src/route.ts +9 -7
- package/dist/templates/examples/ssr/package.json +9 -8
- package/dist/templates/examples/ssr/src/{main.ts → block.ts} +58 -49
- package/dist/templates/examples/ssr/src/entry.server.ts +3 -2
- package/dist/templates/examples/ssr/src/entry.ts +7 -11
- package/dist/templates/examples/ssr/src/scene.test.ts +27 -25
- package/dist/templates/examples/state-machine/package.json +7 -6
- package/dist/templates/examples/state-machine/src/block.ts +22 -0
- package/dist/templates/examples/state-machine/src/command.ts +20 -0
- package/dist/templates/examples/state-machine/src/composition.ts +41 -0
- package/dist/templates/examples/state-machine/src/entry.ts +7 -12
- package/dist/templates/examples/state-machine/src/index.ts +2 -0
- package/dist/templates/examples/state-machine/src/init.ts +10 -0
- package/dist/templates/examples/state-machine/src/layer.ts +16 -0
- package/dist/templates/examples/state-machine/src/machine.ts +235 -0
- package/dist/templates/examples/state-machine/src/message.ts +17 -0
- package/dist/templates/examples/state-machine/src/model.ts +77 -0
- package/dist/templates/examples/state-machine/src/scene.test.ts +83 -70
- package/dist/templates/examples/state-machine/src/story.test.ts +123 -144
- package/dist/templates/examples/state-machine/src/transition.ts +50 -0
- package/dist/templates/examples/state-machine/src/update.ts +21 -0
- package/dist/templates/examples/state-machine/src/view/analysis.ts +173 -0
- package/dist/templates/examples/state-machine/src/view/cart.ts +210 -0
- package/dist/templates/examples/state-machine/src/view/checkout.ts +203 -0
- package/dist/templates/examples/state-machine/src/view/header.ts +193 -0
- package/dist/templates/examples/state-machine/src/view/payment.ts +176 -0
- package/dist/templates/examples/state-machine/src/view/review.ts +323 -0
- package/dist/templates/examples/state-machine/src/view/shared.ts +134 -0
- package/dist/templates/examples/state-machine/src/view/shipping.ts +179 -0
- package/dist/templates/examples/state-machine/src/view/status.ts +131 -0
- package/dist/templates/examples/state-machine/src/view.ts +8 -1622
- package/dist/templates/examples/stopwatch/package.json +7 -6
- package/dist/templates/examples/stopwatch/src/{main.ts → block.ts} +111 -89
- package/dist/templates/examples/stopwatch/src/entry.ts +7 -12
- package/dist/templates/examples/stopwatch/src/scene.test.ts +82 -78
- package/dist/templates/examples/stopwatch/src/story.test.ts +84 -75
- package/dist/templates/examples/todo/package.json +7 -6
- package/dist/templates/examples/todo/src/block.ts +20 -0
- package/dist/templates/examples/todo/src/command.ts +40 -0
- package/dist/templates/examples/todo/src/composition.ts +8 -0
- package/dist/templates/examples/todo/src/effectsLayer.ts +5 -0
- package/dist/templates/examples/todo/src/entry.ts +11 -11
- package/dist/templates/examples/todo/src/flags.ts +21 -0
- package/dist/templates/examples/todo/src/index.ts +2 -0
- package/dist/templates/examples/todo/src/init.ts +14 -0
- package/dist/templates/examples/todo/src/layer.ts +12 -0
- package/dist/templates/examples/todo/src/message.ts +26 -0
- package/dist/templates/examples/todo/src/model.ts +35 -0
- package/dist/templates/examples/todo/src/scene.test.ts +85 -99
- package/dist/templates/examples/todo/src/services.ts +3 -0
- package/dist/templates/examples/todo/src/story.test.ts +172 -165
- package/dist/templates/examples/todo/src/update.ts +169 -0
- package/dist/templates/examples/todo/src/{main.ts → view.ts} +25 -330
- package/dist/templates/examples/ui-showcase/package.json +7 -6
- package/dist/templates/examples/ui-showcase/src/block.ts +25 -0
- package/dist/templates/examples/ui-showcase/src/blocks/index.ts +2 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/block.ts +25 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/combobox.ts +6 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/composition/animation.ts +24 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/composition/composition.ts +584 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/composition/dragAndDrop.ts +76 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/composition/index.ts +43 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/domain/domain.ts +43 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/domain/index.ts +8 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/inMessage.ts +7 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/inMessageUpdate.ts +6 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/index.ts +3 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/init.ts +60 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/layer.ts +56 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/listbox.ts +15 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/menu.ts +5 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/message.ts +36 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/model.ts +107 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/radioGroup.ts +5 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/story.test.ts +33 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/tabs.ts +5 -0
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/toast.ts +2 -2
- package/dist/templates/examples/ui-showcase/src/blocks/ui/update.ts +157 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/animation.ts +51 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/button.ts +59 -0
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/calendar.ts +29 -48
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/checkbox.ts +61 -65
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/combobox.ts +135 -139
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/datePicker.ts +32 -56
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/dialog.ts +129 -151
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/disclosure.ts +253 -0
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/dragAndDrop.ts +75 -63
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/fieldset.ts +30 -40
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/fileDrop.ts +112 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/hoverIntent.ts +81 -0
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/index.ts +2 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/input.ts +87 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/listbox.ts +259 -0
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/menu.ts +59 -66
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/meter.ts +95 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/mobileMenu.ts +48 -0
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/popover.ts +122 -132
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/progress.ts +96 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/radioGroup.ts +177 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/select.ts +119 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/slider.ts +150 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/switch.ts +79 -0
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/tabs.ts +85 -87
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/textarea.ts +92 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/toast.ts +181 -0
- package/dist/templates/examples/ui-showcase/src/blocks/ui/view/tooltip.ts +132 -0
- package/dist/templates/examples/ui-showcase/src/{ui → blocks/ui}/view/virtualList.ts +91 -113
- package/dist/templates/examples/ui-showcase/src/blocks/ui/virtualList.ts +16 -0
- package/dist/templates/examples/ui-showcase/src/command.ts +23 -0
- package/dist/templates/examples/ui-showcase/src/composition.ts +16 -0
- package/dist/templates/examples/ui-showcase/src/effectsLayer.ts +8 -0
- package/dist/templates/examples/ui-showcase/src/entry.ts +10 -23
- package/dist/templates/examples/ui-showcase/src/flags.ts +13 -0
- package/dist/templates/examples/ui-showcase/src/index.ts +2 -0
- package/dist/templates/examples/ui-showcase/src/init.ts +9 -0
- package/dist/templates/examples/ui-showcase/src/layer.ts +15 -0
- package/dist/templates/examples/ui-showcase/src/message.ts +12 -0
- package/dist/templates/examples/ui-showcase/src/model.ts +10 -0
- package/dist/templates/examples/ui-showcase/src/route.ts +209 -0
- package/dist/templates/examples/ui-showcase/src/scene.test.ts +113 -96
- package/dist/templates/examples/ui-showcase/src/story.test.ts +68 -74
- package/dist/templates/examples/ui-showcase/src/update.ts +38 -0
- package/dist/templates/examples/ui-showcase/src/view.ts +420 -0
- package/dist/templates/examples/view-transitions/package.json +7 -6
- package/dist/templates/examples/view-transitions/src/{main.ts → block.ts} +100 -70
- package/dist/templates/examples/view-transitions/src/entry.ts +9 -13
- package/dist/templates/examples/view-transitions/src/route.ts +9 -7
- package/dist/templates/examples/view-transitions/src/scene.test.ts +45 -33
- package/dist/templates/examples/weather/package.json +7 -6
- package/dist/templates/examples/weather/src/block.ts +18 -0
- package/dist/templates/examples/weather/src/command.ts +142 -0
- package/dist/templates/examples/weather/src/composition.ts +8 -0
- package/dist/templates/examples/weather/src/entry.ts +8 -11
- package/dist/templates/examples/weather/src/index.ts +2 -0
- package/dist/templates/examples/weather/src/init.ts +9 -0
- package/dist/templates/examples/weather/src/layer.ts +12 -0
- package/dist/templates/examples/weather/src/message.ts +12 -0
- package/dist/templates/examples/weather/src/model.fixture.ts +16 -0
- package/dist/templates/examples/weather/src/model.ts +21 -0
- package/dist/templates/examples/weather/src/scene.test.ts +79 -86
- package/dist/templates/examples/weather/src/services.ts +3 -0
- package/dist/templates/examples/weather/src/story.test.ts +30 -106
- package/dist/templates/examples/weather/src/update.ts +30 -0
- package/dist/templates/examples/weather/src/view.ts +146 -0
- package/dist/templates/examples/web-components/package.json +7 -6
- package/dist/templates/examples/web-components/src/{main.ts → block.ts} +82 -49
- package/dist/templates/examples/web-components/src/entry.ts +7 -11
- package/dist/templates/examples/web-components/src/scene.test.ts +74 -73
- package/dist/templates/examples/web-components/src/story.test.ts +55 -53
- package/dist/templates/examples/websocket-chat/package.json +7 -6
- package/dist/templates/examples/websocket-chat/src/block.ts +27 -0
- package/dist/templates/examples/websocket-chat/src/chatSocket.ts +4 -0
- package/dist/templates/examples/websocket-chat/src/command.ts +61 -0
- package/dist/templates/examples/websocket-chat/src/composition.ts +8 -0
- package/dist/templates/examples/websocket-chat/src/effectsLayer.ts +17 -0
- package/dist/templates/examples/websocket-chat/src/entry.ts +8 -21
- package/dist/templates/examples/websocket-chat/src/index.ts +2 -0
- package/dist/templates/examples/websocket-chat/src/init.ts +10 -0
- package/dist/templates/examples/websocket-chat/src/layer.ts +16 -0
- package/dist/templates/examples/websocket-chat/src/managedResource.ts +41 -0
- package/dist/templates/examples/websocket-chat/src/message.ts +25 -0
- package/dist/templates/examples/websocket-chat/src/model.ts +24 -0
- package/dist/templates/examples/websocket-chat/src/scene.test.ts +127 -127
- package/dist/templates/examples/websocket-chat/src/services.ts +3 -0
- package/dist/templates/examples/websocket-chat/src/story.test.ts +141 -132
- package/dist/templates/examples/websocket-chat/src/subscription.ts +50 -0
- package/dist/templates/examples/websocket-chat/src/update.ts +78 -0
- package/dist/templates/examples/websocket-chat/src/view.ts +276 -0
- package/dist/templates/examples/websocket-chat/src/webSocketConnection.test.ts +225 -0
- package/dist/templates/examples/websocket-chat/src/webSocketConnection.ts +25 -0
- package/dist/templates/release.json +18 -17
- package/dist/templates/rendering/ssg/README.md +6 -0
- package/dist/templates/rendering/ssg/src/{main.ts → block.ts} +82 -55
- package/dist/templates/rendering/ssg/src/entry.server.ts +3 -2
- package/dist/templates/rendering/ssg/src/entry.ts +10 -14
- package/dist/templates/rendering/ssg/src/route.ts +9 -7
- package/dist/templates/rendering/ssg/src/scene.test.ts +26 -21
- package/dist/templates/rendering/ssr/src/{main.ts → block.ts} +53 -48
- package/dist/templates/rendering/ssr/src/entry.server.ts +3 -2
- package/dist/templates/rendering/ssr/src/entry.ts +7 -11
- package/dist/templates/rendering/ssr/src/scene.test.ts +27 -25
- package/dist/utils/packages.js +1 -0
- package/package.json +7 -7
- package/dist/templates/examples/api-cache/src/main.fixture.ts +0 -71
- package/dist/templates/examples/api-cache/src/main.ts +0 -743
- package/dist/templates/examples/api-cache-query/src/main.fixture.ts +0 -136
- package/dist/templates/examples/api-cache-query/src/main.ts +0 -651
- package/dist/templates/examples/auth/src/main.ts +0 -76
- package/dist/templates/examples/auth/src/page/index.ts +0 -2
- package/dist/templates/examples/auth/src/page/loggedIn/index.ts +0 -4
- package/dist/templates/examples/auth/src/page/loggedIn/update.ts +0 -15
- package/dist/templates/examples/auth/src/page/loggedOut/index.ts +0 -4
- package/dist/templates/examples/auth/src/page/loggedOut/page/login.scene.test.ts +0 -109
- package/dist/templates/examples/auth/src/page/loggedOut/page/login.story.test.ts +0 -111
- package/dist/templates/examples/auth/src/page/loggedOut/update.ts +0 -26
- package/dist/templates/examples/charting/src/chartHost.ts +0 -19
- package/dist/templates/examples/charting/src/init.test.ts +0 -17
- package/dist/templates/examples/counters/src/main.ts +0 -167
- package/dist/templates/examples/interrupting-commands/src/main.ts +0 -358
- package/dist/templates/examples/job-application/src/main.fixture.ts +0 -69
- package/dist/templates/examples/job-application/src/main.ts +0 -68
- package/dist/templates/examples/job-application/src/step/attachments/attachments.ts +0 -106
- package/dist/templates/examples/job-application/src/step/attachments/index.ts +0 -2
- package/dist/templates/examples/job-application/src/step/attachments/scene.test.ts +0 -19
- package/dist/templates/examples/job-application/src/step/attachments/story.test.ts +0 -46
- package/dist/templates/examples/job-application/src/step/coverLetter/index.ts +0 -1
- package/dist/templates/examples/job-application/src/step/coverLetter/scene.test.ts +0 -24
- package/dist/templates/examples/job-application/src/step/coverLetter/story.test.ts +0 -19
- package/dist/templates/examples/job-application/src/step/education/education.ts +0 -111
- package/dist/templates/examples/job-application/src/step/education/entry/entry.ts +0 -160
- package/dist/templates/examples/job-application/src/step/education/entry/index.ts +0 -11
- package/dist/templates/examples/job-application/src/step/education/entry/story.test.ts +0 -39
- package/dist/templates/examples/job-application/src/step/education/index.ts +0 -12
- package/dist/templates/examples/job-application/src/step/education/scene.test.ts +0 -20
- package/dist/templates/examples/job-application/src/step/education/story.test.ts +0 -87
- package/dist/templates/examples/job-application/src/step/index.ts +0 -6
- package/dist/templates/examples/job-application/src/step/personalInfo/index.ts +0 -11
- package/dist/templates/examples/job-application/src/step/personalInfo/personalInfo.ts +0 -291
- package/dist/templates/examples/job-application/src/step/personalInfo/scene.test.ts +0 -38
- package/dist/templates/examples/job-application/src/step/personalInfo/story.test.ts +0 -89
- package/dist/templates/examples/job-application/src/step/skills/entry/entry.ts +0 -120
- package/dist/templates/examples/job-application/src/step/skills/entry/index.ts +0 -11
- package/dist/templates/examples/job-application/src/step/skills/entry/story.test.ts +0 -27
- package/dist/templates/examples/job-application/src/step/skills/entry/view.ts +0 -99
- package/dist/templates/examples/job-application/src/step/skills/index.ts +0 -12
- package/dist/templates/examples/job-application/src/step/skills/scene.test.ts +0 -16
- package/dist/templates/examples/job-application/src/step/skills/skills.ts +0 -108
- package/dist/templates/examples/job-application/src/step/skills/story.test.ts +0 -85
- package/dist/templates/examples/job-application/src/step/workHistory/entry/entry.ts +0 -188
- package/dist/templates/examples/job-application/src/step/workHistory/entry/index.ts +0 -11
- package/dist/templates/examples/job-application/src/step/workHistory/entry/story.test.ts +0 -42
- package/dist/templates/examples/job-application/src/step/workHistory/index.ts +0 -12
- package/dist/templates/examples/job-application/src/step/workHistory/scene.test.ts +0 -20
- package/dist/templates/examples/job-application/src/step/workHistory/story.test.ts +0 -87
- package/dist/templates/examples/job-application/src/step/workHistory/workHistory.ts +0 -111
- package/dist/templates/examples/kanban/src/main.ts +0 -55
- package/dist/templates/examples/kanban/src/subscription.ts +0 -17
- package/dist/templates/examples/map/src/main.ts +0 -788
- package/dist/templates/examples/map/src/mapHost.ts +0 -21
- package/dist/templates/examples/pixel-art/src/main.ts +0 -84
- package/dist/templates/examples/query-sync/src/main.ts +0 -893
- package/dist/templates/examples/routing/src/page/index.ts +0 -1
- package/dist/templates/examples/routing/src/page/people.scene.test.ts +0 -41
- package/dist/templates/examples/routing/src/page/people.story.test.ts +0 -73
- package/dist/templates/examples/routing/src/page/people.ts +0 -331
- package/dist/templates/examples/shopping-cart/src/main.ts +0 -299
- package/dist/templates/examples/shopping-cart/src/page/products.scene.test.ts +0 -20
- package/dist/templates/examples/shopping-cart/src/page/products.story.test.ts +0 -56
- package/dist/templates/examples/snake/src/main.ts +0 -338
- package/dist/templates/examples/state-machine/src/main.ts +0 -436
- package/dist/templates/examples/ui-showcase/src/main.ts +0 -688
- package/dist/templates/examples/ui-showcase/src/ui/init.ts +0 -189
- package/dist/templates/examples/ui-showcase/src/ui/message.ts +0 -96
- package/dist/templates/examples/ui-showcase/src/ui/model.ts +0 -144
- package/dist/templates/examples/ui-showcase/src/ui/subscriptions.ts +0 -49
- package/dist/templates/examples/ui-showcase/src/ui/update.ts +0 -1197
- package/dist/templates/examples/ui-showcase/src/ui/view/animation.ts +0 -58
- package/dist/templates/examples/ui-showcase/src/ui/view/button.ts +0 -64
- package/dist/templates/examples/ui-showcase/src/ui/view/disclosure.ts +0 -260
- package/dist/templates/examples/ui-showcase/src/ui/view/fileDrop.ts +0 -121
- package/dist/templates/examples/ui-showcase/src/ui/view/hoverIntent.ts +0 -86
- package/dist/templates/examples/ui-showcase/src/ui/view/input.ts +0 -91
- package/dist/templates/examples/ui-showcase/src/ui/view/listbox.ts +0 -263
- package/dist/templates/examples/ui-showcase/src/ui/view/meter.ts +0 -98
- package/dist/templates/examples/ui-showcase/src/ui/view/progress.ts +0 -99
- package/dist/templates/examples/ui-showcase/src/ui/view/radioGroup.ts +0 -188
- package/dist/templates/examples/ui-showcase/src/ui/view/select.ts +0 -127
- package/dist/templates/examples/ui-showcase/src/ui/view/slider.ts +0 -158
- package/dist/templates/examples/ui-showcase/src/ui/view/switch.ts +0 -82
- package/dist/templates/examples/ui-showcase/src/ui/view/textarea.ts +0 -94
- package/dist/templates/examples/ui-showcase/src/ui/view/toast.ts +0 -182
- package/dist/templates/examples/ui-showcase/src/ui/view/tooltip.ts +0 -135
- package/dist/templates/examples/weather/src/main.fixture.ts +0 -59
- package/dist/templates/examples/weather/src/main.ts +0 -349
- package/dist/templates/examples/websocket-chat/src/main.ts +0 -628
package/README.md
CHANGED
|
@@ -31,7 +31,7 @@ The starter examples apply to `spa` rendering. The `ssg` and `ssr` modes scaffol
|
|
|
31
31
|
| Example | Description |
|
|
32
32
|
| ------------------------ | ------------------------------------------------------------------------------------------------------ |
|
|
33
33
|
| `counter` | Simple increment/decrement with reset |
|
|
34
|
-
| `counters` | A dynamic list of Counter
|
|
34
|
+
| `counters` | A dynamic list of Counter Blocks with generated per-instance delivery |
|
|
35
35
|
| `todo` | CRUD operations with localStorage persistence |
|
|
36
36
|
| `stopwatch` | Timer with start/stop/reset |
|
|
37
37
|
| `crash-view` | Custom crash fallback UI with crash.view and crash.report |
|
|
@@ -48,7 +48,7 @@ The starter examples apply to `spa` rendering. The `ssg` and `ssr` modes scaffol
|
|
|
48
48
|
| `snake` | Classic game built with Subscriptions |
|
|
49
49
|
| `canvas-art` | Declarative 2D canvas with shapes, animation-frame Subscriptions, and pointer events |
|
|
50
50
|
| `generative-art` | Perlin-noise flow field with evolving particle trails, mouse vortex, and high-frequency Messages |
|
|
51
|
-
| `auth` | Authentication with
|
|
51
|
+
| `auth` | Authentication with Blocks, OutMessage, and protected routes |
|
|
52
52
|
| `shopping-cart` | Complex state management with nested Models and routing |
|
|
53
53
|
| `state-machine` | Experimental state machine checkout with guarded branches and edge Commands |
|
|
54
54
|
| `pixel-art` | Pixel editor with undo/redo, UI components, and localStorage persistence |
|
|
@@ -58,7 +58,7 @@ The starter examples apply to `spa` rendering. The `ssg` and `ssr` modes scaffol
|
|
|
58
58
|
| `map` | Interactive MapLibre GL map with Mount and Subscriptions |
|
|
59
59
|
| `web-components` | QR code designer wiring third-party web components into Foldkit with CustomElement.define |
|
|
60
60
|
| `embedding` | A Foldkit widget embedded in a plain TypeScript host page with Ports and dispose |
|
|
61
|
-
| `ui-showcase` | Every Foldkit UI component with routing and
|
|
61
|
+
| `ui-showcase` | Every Foldkit UI component with routing and Blocks |
|
|
62
62
|
|
|
63
63
|
## License
|
|
64
64
|
|
package/dist/examples.js
CHANGED
|
@@ -40,7 +40,7 @@ export const examples = [
|
|
|
40
40
|
{
|
|
41
41
|
value: 'counters',
|
|
42
42
|
title: 'counters',
|
|
43
|
-
description: 'A dynamic list of Counter
|
|
43
|
+
description: 'A dynamic list of Counter Blocks with generated per-instance delivery',
|
|
44
44
|
},
|
|
45
45
|
{
|
|
46
46
|
value: 'todo',
|
|
@@ -85,7 +85,7 @@ export const examples = [
|
|
|
85
85
|
{
|
|
86
86
|
value: 'api-cache-query',
|
|
87
87
|
title: 'api-cache-query',
|
|
88
|
-
description: 'The API Cache app rewritten with experimental Query.define. Fetching and retained entries live in Query
|
|
88
|
+
description: 'The API Cache app rewritten with experimental Query.define. Fetching and retained entries live in Query Blocks',
|
|
89
89
|
},
|
|
90
90
|
{
|
|
91
91
|
value: 'charting',
|
|
@@ -135,7 +135,7 @@ export const examples = [
|
|
|
135
135
|
{
|
|
136
136
|
value: 'auth',
|
|
137
137
|
title: 'auth',
|
|
138
|
-
description: 'Authentication with
|
|
138
|
+
description: 'Authentication with Blocks, OutMessage, and protected routes',
|
|
139
139
|
},
|
|
140
140
|
{
|
|
141
141
|
value: 'shopping-cart',
|
|
@@ -185,6 +185,6 @@ export const examples = [
|
|
|
185
185
|
{
|
|
186
186
|
value: 'ui-showcase',
|
|
187
187
|
title: 'ui-showcase',
|
|
188
|
-
description: 'Every Foldkit UI component with routing and
|
|
188
|
+
description: 'Every Foldkit UI component with routing and Blocks',
|
|
189
189
|
},
|
|
190
190
|
];
|
|
@@ -2,6 +2,26 @@
|
|
|
2
2
|
|
|
3
3
|
This is a Foldkit app. Read [`FOLDKIT.md`](./FOLDKIT.md) before writing any code in this project. It covers the architecture, the APIs, and the conventions the project is built on.
|
|
4
4
|
|
|
5
|
+
A compact feature may keep its complete implementation together. A split feature declares `FooBlock`, its adjacent key and needed authoring helpers in `block.ts`; `composition.ts` owns static Bindings, OutMessage policies and graph-aware builders; `layer.ts` completes `FooBlock.makeLayer({ init, update, view, ... })` and provides child implementation Layers. The record acquires the init plan's registered child inventory when its Layer is built; use plans from that same Composition. Keep a custom Effect constructor for genuine construction dependencies or scoped work, with explicit acquired `children`. Put a separate local handler bundle in `effectsLayer.ts`. Ordinary Services remain in `services.ts` or a feature-owned provider. Keep init, update, view, Commands and lifecycle definitions in their responsibility modules. Never use `layer.ts` for the local EffectsLayer bundle. A compact root keeps all structural pieces in `block.ts`; retain its declaration when splitting. The root entry selects `{ block: ApplicationBlock, layer }` and starts the Runtime.
|
|
6
|
+
|
|
7
|
+
A child feature exports `FooBlock = Block.make(...)` separately from its implementation `layer`. Composition and extracted builders import child contracts; only completion imports child implementation Layers. The root exports the `ApplicationBlock` and its construction `layer` for Program/Server hosting. `entry.ts` chooses the host, container and startup inputs, supplies ordinary Services through `program.provide(ApplicationLayer)`, and starts Runtime. Imported Block declarations, Compositions and Layer recipes stay passive. Child startup selectors remain deferred until parent init, handler dependencies remain in their handler constructors, and application state stays in the Model.
|
|
8
|
+
|
|
9
|
+
Split implementations named-import their needed Step helpers from `block.ts`; compact implementations destructure them beside the Block declaration. Keep Block qualification where several owners share one module. Keep shared Mount definitions in `mount.ts` and separate local handler bundles in `effectsLayer.ts`; feature barrels do not reexport authoring helpers. Keep the declaration in `block.ts` when splitting, and use an explicit `index.ts` barrel. Name the root Route union `ApplicationRoute`, ordinary Service provider `ApplicationLayer`, and its test alternative `ApplicationTestLayer`.
|
|
10
|
+
|
|
11
|
+
Block-aware Story and Scene runners return scoped Effects. Use their `init(...args)` step to preserve init Model and Commands, `given(model)` for a deliberate prebuilt state, and the paired `{ block: FeatureBlock, layer }` for implementation construction. Their ordinary steps stay synchronous and do not run handlers. See FOLDKIT.md for exact view/context/routing and deferred child-message testing forms.
|
|
12
|
+
|
|
13
|
+
Name application-authored Step values and factories for their operation: `clearSearch`, `changeSearchQuery(query)`, and `applyDomainResult(result)`. Their definitions and types establish the Step role; omit the `make` prefix and `Step` suffix from these application names. Preserve framework helpers and types such as `makeStep`, `makeFieldsStep`, `makeCommandsStep`, `makeOutMessageStep`, `makeNoopStep`, `Update.Step`, and `Update.combineSteps`, along with other public framework helpers whose names include `Step`. Keep existing naming conventions for unrelated factories, Commands, Messages, Bindings, OutMessage folds and matchers, dedicated `handle<MessageTag>` handlers, public operation keys, and applied update-like results.
|
|
14
|
+
|
|
15
|
+
Keep a Step used by only one responsibility with that code. Put reusable Steps shared by update, composition, or init in the owning Block's `steps.ts`. For a larger module, use responsibility files such as `steps/search.ts` and `steps/quoteLoading.ts`, with an explicit `steps/index.ts` barrel. The owner is the Block whose Model the Step transforms. Keep shared Steps independent of the owning update and completed Block.
|
|
16
|
+
|
|
17
|
+
`update.ts` maps incoming Messages to handlers and Steps. `composition.ts` registers relationships and maps child OutMessages to parent Steps. `steps.ts` owns the reusable transitions those entry points share. Keep Binding registration and OutMessage policy in composition. Name shared transitions for their operation, without a `make` prefix or `Step` suffix. A Step that closes over a Binding from composition must read it in a deferred producer when the modules depend on one another; module initialization must not invoke that Binding.
|
|
18
|
+
|
|
19
|
+
Declare the unique key immediately before its Block and give `Symbol('Feature')` the same description as the Block's readable name. Keep the key private unless verified declaration emission needs its original declaration exported. Split implementation modules commonly need that export because their inferred contracts name the owner key. A public barrel may re-export the original declaration with `export type` when only its identity is needed in types. Verify source and relocated declarations before removing an export.
|
|
20
|
+
|
|
21
|
+
Declare parent requests and notifications in the child's `InMessage` union and handle them with `Composition.makeInMessageUpdate`. `RequestedX` generates `Binding.requestX`, and `InformedOfX` generates `Binding.informOfX`. The remaining suffix is preserved exactly; other prefixes and empty suffixes are rejected. Methods take the constructor payload when present, with a keyed occurrence first and InMessage context last. They return connected parent Steps, so pass them directly to handler records or compose them. Do not add a manual request wrapper or an `operations` entry that only repeats an InMessage constructor. Keep explicit operations for real argument adaptation, generic interfaces or intentional local-Message mappings.
|
|
22
|
+
|
|
23
|
+
Application behavior belongs in Story or Scene. Use their DSL to deliver Messages and InMessages, resolve Commands, and assert Models, OutMessages and views. Do not manually chain acquired `update` calls or invoke application Steps as a substitute for the DSL. Pure fixture construction and intentional `given(model)` remain valid; use scoped acquisition only when a fixture genuinely needs initialized state, graph identity or custom view context. Keep pure domain/selector tests separate from application behavior, and reserve low-level transition tests for framework infrastructure. Keep Story and Scene specifications declarative: use immutable fixtures, `messageWith` for a value read from the current Model, and observable assertions. Do not carry values between steps through mutable outer captures or `mockImplementation` closures; establish a genuine DSL gap before introducing a mutable bridge.
|
|
24
|
+
|
|
5
25
|
Foldkit owns `FOLDKIT.md` and replaces it whole on upgrade. This file is yours. Anything you want an agent to know about this project goes below, where an upgrade won't touch it.
|
|
6
26
|
|
|
7
27
|
`FOLDKIT.md` reads the line below to decide whether it has already offered to vendor the Foldkit source. Leave it in place.
|
|
@@ -11,3 +31,5 @@ subtree_prompted: false
|
|
|
11
31
|
## Project Notes
|
|
12
32
|
|
|
13
33
|
Domain vocabulary, deployment steps, local conventions that differ from Foldkit's defaults: write them here.
|
|
34
|
+
|
|
35
|
+
For a required direct child field, omit `init` when its initializer accepts no arguments; use `init: { contextToArgs }` for required inputs or `init: false` when the parent supplies that field. Optional, keyed, and accessor storage remains parent-owned when `init` is omitted; explicit `init.contextToArgs`, keyed `init.instances` / `init.toItem`, or a checked custom projection chooses automatic startup. An optional `ChildInitContext` Schema on the parent Block contextually types selectors that prepare arguments for direct child initializers. Author root startup through `ApplicationComposition.makeInit`, returning parent-owned `model` fields plus optional ephemeral `childInitContext`, parent `commands`, and post-assembly `steps`. Composition initializes and places child Models and collects their Commands. Use an exhaustive `ApplicationComposition.makeUpdate` handler record for parent transitions; registered Bindings route generated child envelopes before local handlers. Use `makeUpdate({})` when the parent has no locally authored Messages and `.withContext` when handlers need dispatch context. Put delivery admission in `delivery.when`, derive required child update context with `delivery.toUpdateContext`, and provide `keySchema` for a custom keyed Binding. See FOLDKIT.md for optional presence, exact keyed identity and startup Steps.
|