makersclaw 0.8.0 → 0.8.1
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 +9 -3
- package/package.json +1 -1
- package/r/activity-log.json +52 -0
- package/r/agent-changes.json +51 -0
- package/r/agent-chat.json +53 -0
- package/r/agent-column.json +85 -0
- package/r/agent-dock.json +57 -0
- package/r/agent-kit.json +49 -0
- package/r/agent-marks.json +49 -0
- package/r/agent-pane.json +93 -0
- package/r/ai-action.json +56 -0
- package/r/annotate.json +3 -3
- package/r/approval-request.json +2 -2
- package/r/approval.json +54 -0
- package/r/ask-bar.json +50 -0
- package/r/audio-player.json +2 -2
- package/r/auth-form.json +2 -2
- package/r/automation-editor.json +66 -0
- package/r/automation-list.json +57 -0
- package/r/automation-model.json +118 -0
- package/r/automations-screen.json +71 -0
- package/r/board.json +2 -2
- package/r/calendar-view.json +3 -3
- package/r/cart.json +2 -2
- package/r/chart.json +2 -2
- package/r/chat-pane.json +84 -0
- package/r/chat.json +2 -2
- package/r/code-editor.json +2 -2
- package/r/comment-box.json +3 -3
- package/r/connect-card.json +51 -0
- package/r/contact-section.json +2 -2
- package/r/core.json +13 -7
- package/r/cost.json +51 -0
- package/r/csv-import.json +3 -3
- package/r/data-picker.json +60 -0
- package/r/data-table.json +2 -2
- package/r/diagram.json +2 -2
- package/r/doc-editor.json +2 -2
- package/r/doc-page.json +3 -3
- package/r/email-render.json +2 -2
- package/r/faq.json +2 -2
- package/r/file-upload.json +2 -2
- package/r/first-run.json +63 -0
- package/r/fix-note.json +57 -0
- package/r/flow-canvas.json +2 -2
- package/r/flow-editor.json +79 -0
- package/r/footer.json +2 -2
- package/r/gantt.json +3 -3
- package/r/job-panel.json +2 -2
- package/r/json-editor.json +3 -3
- package/r/library-shelf.json +56 -0
- package/r/map.json +2 -2
- package/r/margin-notes.json +67 -0
- package/r/menubar.json +2 -2
- package/r/mind-map.json +3 -3
- package/r/navigation-menu.json +2 -2
- package/r/needs-you.json +55 -0
- package/r/order-detail.json +2 -2
- package/r/org-chart.json +3 -3
- package/r/pace-bar.json +69 -0
- package/r/page-builder.json +2 -2
- package/r/payment-methods.json +2 -2
- package/r/pdf-document.json +2 -2
- package/r/pdf-viewer.json +2 -2
- package/r/product-detail.json +2 -2
- package/r/product-grid.json +3 -3
- package/r/record-form.json +2 -2
- package/r/record-grid.json +52 -0
- package/r/record-notes.json +4 -4
- package/r/registry.json +4086 -1512
- package/r/run-history.json +52 -0
- package/r/run-view.json +80 -0
- package/r/schedule-card.json +54 -0
- package/r/schedule-engine.json +79 -0
- package/r/schedule-gantt.json +83 -0
- package/r/schedule-ruler.json +64 -0
- package/r/search-dialog.json +2 -2
- package/r/settings-list.json +2 -2
- package/r/setup-checklist.json +2 -2
- package/r/share-dialog.json +2 -2
- package/r/sidebar.json +2 -2
- package/r/signature-pad.json +2 -2
- package/r/sketch-canvas.json +2 -2
- package/r/source-receipt.json +52 -0
- package/r/spreadsheet.json +3 -3
- package/r/stat-cards.json +3 -3
- package/r/step-picker.json +53 -0
- package/r/step-settings.json +72 -0
- package/r/suggestion.json +58 -0
- package/r/sum-bar.json +64 -0
- package/r/task-list.json +3 -3
- package/r/task-model.json +2 -2
- package/r/testimonials.json +2 -2
- package/r/tier-map.json +67 -0
- package/r/time-grid.json +73 -0
- package/r/time-strip.json +64 -0
- package/r/top-bar.json +66 -0
- package/r/transaction-list.json +2 -2
- package/r/trigger-picker.json +61 -0
- package/r/whiteboard.json +3 -3
- package/r/workflow-view.json +55 -0
- package/registry/blocks/activity-log/README.md +112 -0
- package/registry/blocks/activity-log/activity-log.jsx +351 -0
- package/registry/blocks/activity-log/block.json +33 -0
- package/registry/blocks/activity-log/demo.jsx +48 -0
- package/registry/blocks/activity-log/index.js +4 -0
- package/registry/blocks/agent-changes/README.md +94 -0
- package/registry/blocks/agent-changes/agent-changes.jsx +118 -0
- package/registry/blocks/agent-changes/block.json +28 -0
- package/registry/blocks/agent-changes/demo.jsx +39 -0
- package/registry/blocks/agent-changes/index.js +3 -0
- package/registry/blocks/agent-chat/README.md +145 -0
- package/registry/blocks/agent-chat/agent-chat.jsx +415 -0
- package/registry/blocks/agent-chat/block.json +30 -0
- package/registry/blocks/agent-chat/demo.jsx +165 -0
- package/registry/blocks/agent-chat/index.js +3 -0
- package/registry/blocks/agent-column/README.md +197 -0
- package/registry/blocks/agent-column/agent-column.jsx +492 -0
- package/registry/blocks/agent-column/block.json +67 -0
- package/registry/blocks/agent-column/column-picker.jsx +163 -0
- package/registry/blocks/agent-column/demo.jsx +50 -0
- package/registry/blocks/agent-column/index.js +7 -0
- package/registry/blocks/agent-column/model.js +164 -0
- package/registry/blocks/agent-column/receipt.jsx +483 -0
- package/registry/blocks/agent-column/spreadsheet-type.jsx +24 -0
- package/registry/blocks/agent-dock/README.md +210 -0
- package/registry/blocks/agent-dock/agent-dock.jsx +356 -0
- package/registry/blocks/agent-dock/block.json +47 -0
- package/registry/blocks/agent-dock/demo.jsx +153 -0
- package/registry/blocks/agent-dock/dock-model.js +118 -0
- package/registry/blocks/agent-dock/index.js +5 -0
- package/registry/blocks/agent-kit/README.md +73 -0
- package/registry/blocks/agent-kit/agent-kit.jsx +86 -0
- package/registry/blocks/agent-kit/block.json +10 -0
- package/registry/blocks/agent-kit/demo.jsx +35 -0
- package/registry/blocks/agent-kit/index.js +3 -0
- package/registry/blocks/agent-marks/README.md +80 -0
- package/registry/blocks/agent-marks/agent-marks.jsx +133 -0
- package/registry/blocks/agent-marks/block.json +27 -0
- package/registry/blocks/agent-marks/demo.jsx +49 -0
- package/registry/blocks/agent-marks/index.js +3 -0
- package/registry/blocks/agent-pane/README.md +225 -0
- package/registry/blocks/agent-pane/agent-pane.jsx +244 -0
- package/registry/blocks/agent-pane/block.json +41 -0
- package/registry/blocks/agent-pane/composer.jsx +6 -0
- package/registry/blocks/agent-pane/demo.jsx +233 -0
- package/registry/blocks/agent-pane/dock-context.js +10 -0
- package/registry/blocks/agent-pane/index.js +4 -0
- package/registry/blocks/agent-pane/prose.jsx +84 -0
- package/registry/blocks/agent-pane/questions.jsx +134 -0
- package/registry/blocks/agent-pane/transcript.jsx +268 -0
- package/registry/blocks/agent-pane/work.jsx +368 -0
- package/registry/blocks/ai-action/README.md +94 -0
- package/registry/blocks/ai-action/ai-action.jsx +188 -0
- package/registry/blocks/ai-action/block.json +34 -0
- package/registry/blocks/ai-action/demo.jsx +93 -0
- package/registry/blocks/ai-action/index.js +3 -0
- package/registry/blocks/approval/README.md +145 -0
- package/registry/blocks/approval/approval.jsx +163 -0
- package/registry/blocks/approval/block.json +31 -0
- package/registry/blocks/approval/demo.jsx +121 -0
- package/registry/blocks/approval/index.js +3 -0
- package/registry/blocks/ask-bar/README.md +105 -0
- package/registry/blocks/ask-bar/ask-bar.jsx +166 -0
- package/registry/blocks/ask-bar/block.json +26 -0
- package/registry/blocks/ask-bar/demo.jsx +78 -0
- package/registry/blocks/ask-bar/index.js +3 -0
- package/registry/blocks/automation-editor/README.md +291 -0
- package/registry/blocks/automation-editor/automation-editor.jsx +656 -0
- package/registry/blocks/automation-editor/block.json +39 -0
- package/registry/blocks/automation-editor/demo.jsx +284 -0
- package/registry/blocks/automation-editor/index.js +4 -0
- package/registry/blocks/automation-editor/run-inputs.jsx +82 -0
- package/registry/blocks/automation-list/README.md +129 -0
- package/registry/blocks/automation-list/automation-list.jsx +476 -0
- package/registry/blocks/automation-list/block.json +35 -0
- package/registry/blocks/automation-list/demo.jsx +67 -0
- package/registry/blocks/automation-list/index.js +3 -0
- package/registry/blocks/automation-model/README.md +109 -0
- package/registry/blocks/automation-model/block.json +135 -0
- package/registry/blocks/automation-model/catalog.js +256 -0
- package/registry/blocks/automation-model/check.js +161 -0
- package/registry/blocks/automation-model/demo.jsx +42 -0
- package/registry/blocks/automation-model/edit.js +262 -0
- package/registry/blocks/automation-model/fixes.js +287 -0
- package/registry/blocks/automation-model/glyph.jsx +13 -0
- package/registry/blocks/automation-model/graph.js +410 -0
- package/registry/blocks/automation-model/index.js +33 -0
- package/registry/blocks/automation-model/overlay.js +175 -0
- package/registry/blocks/automation-model/parts.jsx +94 -0
- package/registry/blocks/automation-model/schedule.js +53 -0
- package/registry/blocks/automation-model/templates.js +128 -0
- package/registry/blocks/automation-model/values.js +29 -0
- package/registry/blocks/automation-model/words.js +439 -0
- package/registry/blocks/automations-screen/README.md +207 -0
- package/registry/blocks/automations-screen/automations-screen.jsx +452 -0
- package/registry/blocks/automations-screen/block.json +47 -0
- package/registry/blocks/automations-screen/demo.jsx +364 -0
- package/registry/blocks/automations-screen/index.js +4 -0
- package/registry/blocks/automations-screen/screen-model.js +129 -0
- package/registry/blocks/chat-pane/README.md +143 -0
- package/registry/blocks/chat-pane/block.json +48 -0
- package/registry/blocks/chat-pane/chat-attach.js +166 -0
- package/registry/blocks/chat-pane/chat-composer.jsx +195 -0
- package/registry/blocks/chat-pane/chat-context.js +17 -0
- package/registry/blocks/chat-pane/chat-model.js +43 -0
- package/registry/blocks/chat-pane/chat-pane.jsx +398 -0
- package/registry/blocks/chat-pane/chats-list.jsx +52 -0
- package/registry/blocks/chat-pane/demo.jsx +103 -0
- package/registry/blocks/chat-pane/index.js +9 -0
- package/registry/blocks/connect-card/README.md +99 -0
- package/registry/blocks/connect-card/block.json +10 -0
- package/registry/blocks/connect-card/connect-card.jsx +103 -0
- package/registry/blocks/connect-card/demo.jsx +49 -0
- package/registry/blocks/connect-card/index.js +3 -0
- package/registry/blocks/cost/README.md +115 -0
- package/registry/blocks/cost/block.json +10 -0
- package/registry/blocks/cost/cost.jsx +176 -0
- package/registry/blocks/cost/demo.jsx +66 -0
- package/registry/blocks/cost/index.js +3 -0
- package/registry/blocks/data-picker/README.md +81 -0
- package/registry/blocks/data-picker/block.json +38 -0
- package/registry/blocks/data-picker/data-picker.jsx +210 -0
- package/registry/blocks/data-picker/demo.jsx +34 -0
- package/registry/blocks/data-picker/fields.js +89 -0
- package/registry/blocks/data-picker/index.js +4 -0
- package/registry/blocks/data-table/demo.jsx +1 -1
- package/registry/blocks/first-run/README.md +118 -0
- package/registry/blocks/first-run/block.json +11 -0
- package/registry/blocks/first-run/demo.jsx +88 -0
- package/registry/blocks/first-run/first-run-model.js +51 -0
- package/registry/blocks/first-run/first-run.jsx +156 -0
- package/registry/blocks/first-run/index.js +5 -0
- package/registry/blocks/first-run/probe-rules.js +26 -0
- package/registry/blocks/fix-note/README.md +79 -0
- package/registry/blocks/fix-note/block.json +35 -0
- package/registry/blocks/fix-note/demo.jsx +30 -0
- package/registry/blocks/fix-note/fix-note.jsx +235 -0
- package/registry/blocks/fix-note/index.js +3 -0
- package/registry/blocks/flow-editor/README.md +108 -0
- package/registry/blocks/flow-editor/block.json +44 -0
- package/registry/blocks/flow-editor/demo.jsx +115 -0
- package/registry/blocks/flow-editor/flow-canvas.jsx +568 -0
- package/registry/blocks/flow-editor/flow-editor.jsx +154 -0
- package/registry/blocks/flow-editor/index.js +6 -0
- package/registry/blocks/flow-editor/minimap.jsx +78 -0
- package/registry/blocks/flow-editor/outline.jsx +134 -0
- package/registry/blocks/library-shelf/README.md +117 -0
- package/registry/blocks/library-shelf/block.json +28 -0
- package/registry/blocks/library-shelf/demo.jsx +68 -0
- package/registry/blocks/library-shelf/index.js +3 -0
- package/registry/blocks/library-shelf/library-shelf.jsx +211 -0
- package/registry/blocks/library-shelf/probe-rules.js +15 -0
- package/registry/blocks/margin-notes/README.md +222 -0
- package/registry/blocks/margin-notes/block.json +10 -0
- package/registry/blocks/margin-notes/demo.jsx +144 -0
- package/registry/blocks/margin-notes/index.js +20 -0
- package/registry/blocks/margin-notes/margin-model.js +224 -0
- package/registry/blocks/margin-notes/margin-notes.jsx +465 -0
- package/registry/blocks/needs-you/README.md +177 -0
- package/registry/blocks/needs-you/block.json +34 -0
- package/registry/blocks/needs-you/demo.jsx +143 -0
- package/registry/blocks/needs-you/index.js +3 -0
- package/registry/blocks/needs-you/needs-you.jsx +441 -0
- package/registry/blocks/pace-bar/README.md +230 -0
- package/registry/blocks/pace-bar/block.json +10 -0
- package/registry/blocks/pace-bar/demo.jsx +255 -0
- package/registry/blocks/pace-bar/index.js +22 -0
- package/registry/blocks/pace-bar/pace-bar.jsx +461 -0
- package/registry/blocks/pace-bar/pace-model.js +288 -0
- package/registry/blocks/record-grid/README.md +100 -0
- package/registry/blocks/record-grid/block.json +28 -0
- package/registry/blocks/record-grid/demo.jsx +43 -0
- package/registry/blocks/record-grid/index.js +3 -0
- package/registry/blocks/record-grid/record-grid.jsx +251 -0
- package/registry/blocks/run-history/README.md +138 -0
- package/registry/blocks/run-history/block.json +10 -0
- package/registry/blocks/run-history/demo.jsx +74 -0
- package/registry/blocks/run-history/index.js +3 -0
- package/registry/blocks/run-history/run-history.jsx +218 -0
- package/registry/blocks/run-view/README.md +174 -0
- package/registry/blocks/run-view/block.json +50 -0
- package/registry/blocks/run-view/demo.jsx +286 -0
- package/registry/blocks/run-view/index.js +5 -0
- package/registry/blocks/run-view/run-controls.jsx +266 -0
- package/registry/blocks/run-view/run-view.jsx +236 -0
- package/registry/blocks/run-view/runs-list.jsx +99 -0
- package/registry/blocks/schedule-card/README.md +121 -0
- package/registry/blocks/schedule-card/block.json +10 -0
- package/registry/blocks/schedule-card/demo.jsx +82 -0
- package/registry/blocks/schedule-card/index.js +3 -0
- package/registry/blocks/schedule-card/schedule-card.jsx +136 -0
- package/registry/blocks/schedule-engine/README.md +137 -0
- package/registry/blocks/schedule-engine/block.json +10 -0
- package/registry/blocks/schedule-engine/demo.jsx +82 -0
- package/registry/blocks/schedule-engine/engine.js +769 -0
- package/registry/blocks/schedule-engine/index.js +9 -0
- package/registry/blocks/schedule-engine/ops.js +71 -0
- package/registry/blocks/schedule-engine/place.js +294 -0
- package/registry/blocks/schedule-engine/tree.js +79 -0
- package/registry/blocks/schedule-engine/waits.js +80 -0
- package/registry/blocks/schedule-gantt/README.md +159 -0
- package/registry/blocks/schedule-gantt/block.json +10 -0
- package/registry/blocks/schedule-gantt/demo.jsx +223 -0
- package/registry/blocks/schedule-gantt/gantt-model.js +219 -0
- package/registry/blocks/schedule-gantt/geometry.js +176 -0
- package/registry/blocks/schedule-gantt/index.js +26 -0
- package/registry/blocks/schedule-gantt/schedule-gantt.jsx +882 -0
- package/registry/blocks/schedule-gantt/sheet.jsx +372 -0
- package/registry/blocks/schedule-gantt/track.jsx +190 -0
- package/registry/blocks/schedule-ruler/README.md +148 -0
- package/registry/blocks/schedule-ruler/block.json +10 -0
- package/registry/blocks/schedule-ruler/demo.jsx +181 -0
- package/registry/blocks/schedule-ruler/index.js +21 -0
- package/registry/blocks/schedule-ruler/ruler-model.js +239 -0
- package/registry/blocks/schedule-ruler/schedule-ruler.jsx +548 -0
- package/registry/blocks/source-receipt/README.md +97 -0
- package/registry/blocks/source-receipt/block.json +30 -0
- package/registry/blocks/source-receipt/demo.jsx +71 -0
- package/registry/blocks/source-receipt/index.js +3 -0
- package/registry/blocks/source-receipt/source-receipt.jsx +107 -0
- package/registry/blocks/spreadsheet/spreadsheet.jsx +15 -1
- package/registry/blocks/step-picker/README.md +78 -0
- package/registry/blocks/step-picker/block.json +31 -0
- package/registry/blocks/step-picker/demo.jsx +23 -0
- package/registry/blocks/step-picker/index.js +3 -0
- package/registry/blocks/step-picker/step-picker.jsx +144 -0
- package/registry/blocks/step-settings/README.md +100 -0
- package/registry/blocks/step-settings/block.json +44 -0
- package/registry/blocks/step-settings/demo.jsx +93 -0
- package/registry/blocks/step-settings/fields.jsx +58 -0
- package/registry/blocks/step-settings/flow-settings.jsx +115 -0
- package/registry/blocks/step-settings/index.js +5 -0
- package/registry/blocks/step-settings/step-settings.jsx +290 -0
- package/registry/blocks/suggestion/README.md +171 -0
- package/registry/blocks/suggestion/block.json +40 -0
- package/registry/blocks/suggestion/demo.jsx +91 -0
- package/registry/blocks/suggestion/index.js +3 -0
- package/registry/blocks/suggestion/suggestion.jsx +436 -0
- package/registry/blocks/sum-bar/README.md +122 -0
- package/registry/blocks/sum-bar/block.json +10 -0
- package/registry/blocks/sum-bar/demo.jsx +110 -0
- package/registry/blocks/sum-bar/index.js +5 -0
- package/registry/blocks/sum-bar/sum-bar.jsx +209 -0
- package/registry/blocks/sum-bar/sum-model.js +126 -0
- package/registry/blocks/tier-map/README.md +217 -0
- package/registry/blocks/tier-map/block.json +10 -0
- package/registry/blocks/tier-map/demo.jsx +222 -0
- package/registry/blocks/tier-map/index.js +24 -0
- package/registry/blocks/tier-map/tier-map.jsx +574 -0
- package/registry/blocks/tier-map/tier-model.js +318 -0
- package/registry/blocks/time-grid/README.md +305 -0
- package/registry/blocks/time-grid/block.json +10 -0
- package/registry/blocks/time-grid/demo.jsx +279 -0
- package/registry/blocks/time-grid/grid-model.js +322 -0
- package/registry/blocks/time-grid/index.js +25 -0
- package/registry/blocks/time-grid/time-grid.jsx +1325 -0
- package/registry/blocks/time-strip/README.md +141 -0
- package/registry/blocks/time-strip/block.json +10 -0
- package/registry/blocks/time-strip/demo.jsx +129 -0
- package/registry/blocks/time-strip/index.js +19 -0
- package/registry/blocks/time-strip/strip-model.js +178 -0
- package/registry/blocks/time-strip/time-strip.jsx +260 -0
- package/registry/blocks/top-bar/README.md +149 -0
- package/registry/blocks/top-bar/block.json +35 -0
- package/registry/blocks/top-bar/demo.jsx +78 -0
- package/registry/blocks/top-bar/index.js +5 -0
- package/registry/blocks/top-bar/probe-rules.js +74 -0
- package/registry/blocks/top-bar/top-bar-model.js +152 -0
- package/registry/blocks/top-bar/top-bar.jsx +244 -0
- package/registry/blocks/trigger-picker/README.md +98 -0
- package/registry/blocks/trigger-picker/block.json +38 -0
- package/registry/blocks/trigger-picker/demo.jsx +59 -0
- package/registry/blocks/trigger-picker/index.js +3 -0
- package/registry/blocks/trigger-picker/trigger-picker.jsx +374 -0
- package/registry/blocks/workflow-view/README.md +123 -0
- package/registry/blocks/workflow-view/block.json +10 -0
- package/registry/blocks/workflow-view/demo.jsx +90 -0
- package/registry/blocks/workflow-view/index.js +3 -0
- package/registry/blocks/workflow-view/workflow-view.jsx +203 -0
- package/src/install.mjs +77 -16
- package/src/registry.mjs +3 -0
- package/templates/next/browser/lib/data.js +6 -1
- package/templates/next/files/README.md +627 -24
- package/templates/next/files/check/automation-format.ts +2103 -0
- package/templates/next/files/check/automation-package.ts +142 -0
- package/templates/next/files/check/run.mjs +968 -9
- package/templates/next/files/components/ui/field.jsx +17 -4
- package/templates/next/files/components/ui/icon.jsx +13 -0
- package/templates/next/files/components/ui/index.js +2 -1
- package/templates/next/files/components/ui/layout.jsx +77 -2
- package/templates/next/files/components/ui/notice.jsx +70 -0
- package/templates/next/files/components/ui/page.jsx +124 -0
- package/templates/next/files/components/ui/stat.jsx +22 -7
- package/templates/next/files/components/ui/toast.jsx +6 -3
- package/templates/next/files/lib/automations.js +660 -0
- package/templates/next/files/lib/claw.js +241 -5
- package/templates/next/files/lib/door.js +92 -0
- package/templates/next/files/lib/hooks.js +1627 -8
- package/templates/next/files/lib/platform.js +529 -21
- package/templates/next/template.json +13 -3
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "tier-map",
|
|
3
|
+
"title": "TierMap",
|
|
4
|
+
"description": "A map of cards in tiers, from a flat list where each item names its parent. The first tier is the tops; pressing a card opens the cards that serve it as the next tier beneath, joined by elbow lines (pressing it again closes them), and ONE LAYER OPENS AT A TIME. A card with something under it says how many (\"6 serving it\") and whether it is open. A card holds a small kicker line with a mark and a person's face, a title, a progress bar in a status colour with its percent, and one muted foot line. Items that sit under nothing and are not tops are shown together in an unparented group with a note and a slot for an action; items marked ghost (drafts, counted nowhere) are drawn dashed in a group of their own and can serve each other. The lines are CSS only (each tier is a grid of equal columns and the lines are placed in percent), so nothing is measured; below the width a tier needs to sit in one row it stacks, the lines become a rail down its left, and the cards go full width. Arrow keys walk the cards (left and right beside, down into the first kid, up to the parent, Escape closes). A loop of parents is broken, and a parent that is not in the list makes the item unparented. Loading, failed, empty and read-only are drawn; the model (buildTierModel, openPath, togglePath, neighbour, elbowOf) is exported as plain functions.",
|
|
5
|
+
"useWhen": "Any screen that shows what serves what, one layer at a time: a company's goals and the goals beneath them, a strategy map, initiatives under goals, work under a roadmap theme, an account and its sub-accounts, a category tree whose members are cards, a product and its components. Draws a structure the app has already worked out; it does not move cards between parents or collect anything. Not for a person-and-manager chart with zoom and drag (org-chart), a free-form map of ideas (mind-map), a full node-and-edge canvas (flow-canvas), a table with expandable rows (data-table), or a board of columns (board).",
|
|
6
|
+
"tags": ["tiers", "tree", "hierarchy", "parent", "children", "map", "goals", "okr", "strategy", "initiatives", "roadmap", "sub-accounts", "serves", "alignment", "elbow", "connector", "drafts", "ghost", "unparented", "cards", "progress"],
|
|
7
|
+
"exports": ["TierMap", "TierCard", "CARD_REM", "MAX_COLUMNS", "NEVER", "TONES", "barOf", "buildTierModel", "centreOf", "countText", "elbowOf", "fitKey", "neighbour", "openPath", "pathTo", "siblingsOf", "thresholdRem", "tiersOf", "togglePath", "toneOf"],
|
|
8
|
+
"files": ["index.js", "tier-map.jsx", "tier-model.js"],
|
|
9
|
+
"requires": []
|
|
10
|
+
}
|
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
// TierMap in every state — the gallery's and the smoke test's surface. Not
|
|
4
|
+
// installed into apps: `makersclaw add tier-map` lays index.js, tier-map.jsx
|
|
5
|
+
// and tier-model.js only.
|
|
6
|
+
// Goals a company's goals, the teams' goals beneath: one layer opens
|
|
7
|
+
// at a time (press a count), a record opens on its title, an
|
|
8
|
+
// unparented group with a note and an action, a group of drafts
|
|
9
|
+
// where one draft serves another.
|
|
10
|
+
// Deep three tiers open at once, and the path kept by the surface.
|
|
11
|
+
// Accounts the same block for an account and its sub-accounts, with a
|
|
12
|
+
// card of the app's own (renderCard).
|
|
13
|
+
// One top a top with nothing beneath it; many tops.
|
|
14
|
+
// Long words a very long title, kicker and foot.
|
|
15
|
+
// Narrow a 320 px container: tiers stack, the lines are a rail.
|
|
16
|
+
// Wide a container well past 1000 px.
|
|
17
|
+
// Odd data a loop of parents (broken), a parent that is not in the list.
|
|
18
|
+
// Read-only no onSelect: pressing a card only opens its tier.
|
|
19
|
+
// Empty, loading, failed.
|
|
20
|
+
import { useState } from "react";
|
|
21
|
+
import { Avatar, Button, StatusDot } from "../components/ui";
|
|
22
|
+
import { TierMap } from "../components/blocks/tier-map";
|
|
23
|
+
|
|
24
|
+
const person = (name) => <Avatar name={name} size="xs" />;
|
|
25
|
+
const dot = (tone, label) => <StatusDot tone={tone} label={label} hideLabel />;
|
|
26
|
+
|
|
27
|
+
const GOALS = [
|
|
28
|
+
{ id: "c1", title: "Reach $1M in annual revenue by the end of the quarter", kicker: "Company", by: person("Dana Whitfield"), value: 0.62, tone: "warning", mark: dot("warning", "Behind"), foot: "6 teams serve it" },
|
|
29
|
+
{ id: "c2", title: "Be the default rate API for small carriers", kicker: "Company", by: person("Dana Whitfield"), value: 0.41, tone: "danger", mark: dot("danger", "At risk") },
|
|
30
|
+
{ id: "c3", title: "Keep churn under 2% a month", kicker: "Company", by: person("Dana Whitfield"), value: 0.9, tone: "success", mark: dot("success", "On track") },
|
|
31
|
+
{ id: "s1", parent: "c1", title: "Close the enterprise gap", kicker: "Sales", by: person("Priya Raman"), value: 0.58, tone: "warning", mark: dot("warning", "Behind") },
|
|
32
|
+
{ id: "s2", parent: "c1", title: "Turn demos into a repeatable motion", kicker: "Sales", by: person("Marcus Reyes"), value: 0.87, tone: "success", mark: dot("success", "On track") },
|
|
33
|
+
{ id: "s3", parent: "c1", title: "Win back the lapsed accounts", kicker: "Customer success", by: person("Hannah Cole"), value: 0.75, mark: dot("info", "Quiet") },
|
|
34
|
+
{ id: "s4", parent: "c1", title: "Launch the partner programme", kicker: "Marketing", by: person("Lena Vogel"), value: 0.3, tone: "danger", mark: dot("danger", "At risk") },
|
|
35
|
+
{ id: "s5", parent: "c1", title: "Raise the average deal size", kicker: "Sales", by: person("Priya Raman"), value: 0.5 },
|
|
36
|
+
{ id: "s6", parent: "c1", title: "Shorten the sales cycle", kicker: "Sales", by: person("Marcus Reyes"), value: 1, foot: "Done 18 Sep" },
|
|
37
|
+
{ id: "e1", parent: "c2", title: "Ship the rate API v2", kicker: "Engineering", by: person("Daniel Brandt"), value: 0.44, foot: "4 key results" },
|
|
38
|
+
{ id: "e2", parent: "c2", title: "Cut p95 latency under 200 ms", kicker: "Engineering", by: person("Sofia Marchetti"), value: 0.4 },
|
|
39
|
+
{ id: "k1", parent: "s1", title: "Sign three accounts above $50k", kicker: "Key result", by: person("Priya Raman"), value: 0.66 },
|
|
40
|
+
{ id: "k2", parent: "s1", title: "Run five security reviews", kicker: "Key result", by: person("Priya Raman"), value: 0.4 },
|
|
41
|
+
{ id: "k3", parent: "s1", title: "Bring legal in on the master agreement", kicker: "Key result", by: person("Hannah Cole"), value: 0.8 },
|
|
42
|
+
{ id: "k4", parent: "s2", title: "Book 40 demos a month", kicker: "Key result", by: person("Marcus Reyes"), value: 0.95 },
|
|
43
|
+
{ id: "k5", parent: "s2", title: "Write the follow-up playbook", kicker: "Key result", by: person("Marcus Reyes"), value: 0.8 },
|
|
44
|
+
// Serves nothing: no parent, and not a top.
|
|
45
|
+
{ id: "u1", title: "Redesign the pricing page", kicker: "Marketing", by: person("Lena Vogel"), value: 0.2, foot: "Not linked to a company goal" },
|
|
46
|
+
// Drafts: counted nowhere. One serves another; one serves a real goal.
|
|
47
|
+
{ id: "g1", ghost: true, title: "Grow MRR to $80k without adding sales headcount", kicker: "Draft · Company", by: person("Dana Whitfield"), foot: "Drafted 22 Sep" },
|
|
48
|
+
{ id: "g2", ghost: true, parent: "g1", title: "Make the enterprise tier pay for itself", kicker: "Draft · Sales", foot: "Drafts are not counted anywhere until someone activates them." },
|
|
49
|
+
{ id: "g3", ghost: true, parent: "c3", title: "Offer annual plans at a discount", kicker: "Draft · Customer success" },
|
|
50
|
+
];
|
|
51
|
+
const GOAL_TOPS = ["c1", "c2", "c3"];
|
|
52
|
+
|
|
53
|
+
const note = (
|
|
54
|
+
<>
|
|
55
|
+
<p>A goal that serves nothing is worth a look: is it work the company needs, or work nobody asked for?</p>
|
|
56
|
+
<Button size="sm">Link to a company goal</Button>
|
|
57
|
+
</>
|
|
58
|
+
);
|
|
59
|
+
|
|
60
|
+
function Section({ title, note: text, children }) {
|
|
61
|
+
return (
|
|
62
|
+
<section className="grid min-w-0 gap-2">
|
|
63
|
+
<h2 className="text-sm font-semibold">{title}</h2>
|
|
64
|
+
{text ? <p className="text-xs text-muted-foreground">{text}</p> : null}
|
|
65
|
+
{children}
|
|
66
|
+
</section>
|
|
67
|
+
);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export default function Demo() {
|
|
71
|
+
const [path, setPath] = useState(["c1"]);
|
|
72
|
+
const [picked, setPicked] = useState("s1");
|
|
73
|
+
const item = GOALS.find((g) => g.id === picked);
|
|
74
|
+
|
|
75
|
+
return (
|
|
76
|
+
<div className="grid min-w-0 gap-10 p-4">
|
|
77
|
+
<Section title="Goals" note="Press a count to open its tier (the line follows); press a title to select it. Left and right walk beside, down goes in, up goes out, Escape closes.">
|
|
78
|
+
<TierMap
|
|
79
|
+
label="How goals fit"
|
|
80
|
+
items={GOALS}
|
|
81
|
+
tops={GOAL_TOPS}
|
|
82
|
+
topsLabel="Company · Q3 2026"
|
|
83
|
+
childrenLabel={(n) => `${n} serving it`}
|
|
84
|
+
open={path}
|
|
85
|
+
onOpenChange={setPath}
|
|
86
|
+
selected={picked}
|
|
87
|
+
onSelect={(g) => setPicked(g.id)}
|
|
88
|
+
unparentedLabel="Serves nothing"
|
|
89
|
+
unparentedNote={note}
|
|
90
|
+
ghostLabel="Q4 2026 drafts · aligned already"
|
|
91
|
+
/>
|
|
92
|
+
<p className="text-xs text-muted-foreground">
|
|
93
|
+
Selected: {item?.title} {"·"} open: {path.length ? path.join(" › ") : "none"}
|
|
94
|
+
</p>
|
|
95
|
+
</Section>
|
|
96
|
+
|
|
97
|
+
<Section title="Three tiers open" note="Uncontrolled, starting with a path: a company goal, a team goal, and its key results.">
|
|
98
|
+
<TierMap label="Deep path" items={GOALS} tops={GOAL_TOPS} topsLabel="Company" childrenLabel="serving it" defaultOpen={["c1", "s1"]} onSelect={() => {}} />
|
|
99
|
+
</Section>
|
|
100
|
+
|
|
101
|
+
<Section title="Accounts and sub-accounts" note="The same block with a card of the app's own: renderCard gets the item and the state, and spreads the props that take the focus.">
|
|
102
|
+
<TierMap
|
|
103
|
+
label="Accounts"
|
|
104
|
+
items={[
|
|
105
|
+
{ id: "a1", title: "Northwind Group", kicker: "Parent account", foot: "$2.4M a year" },
|
|
106
|
+
{ id: "a2", parent: "a1", title: "Northwind Freight", kicker: "Sub-account", foot: "$1.1M a year" },
|
|
107
|
+
{ id: "a3", parent: "a1", title: "Northwind Cold Chain", kicker: "Sub-account", foot: "$0.9M a year" },
|
|
108
|
+
{ id: "a4", parent: "a2", title: "Freight · Lisbon depot", kicker: "Site", foot: "$0.3M a year" },
|
|
109
|
+
{ id: "a5", parent: "a2", title: "Freight · Rotterdam depot", kicker: "Site", foot: "$0.8M a year" },
|
|
110
|
+
{ id: "b1", title: "Tidewater Supply", kicker: "Parent account", foot: "$0.6M a year" },
|
|
111
|
+
]}
|
|
112
|
+
topsLabel="Parent accounts"
|
|
113
|
+
childrenLabel="sub-accounts"
|
|
114
|
+
defaultOpen={["a1"]}
|
|
115
|
+
onSelect={() => {}}
|
|
116
|
+
renderCard={(it, s) => (
|
|
117
|
+
<div {...s.holderProps} className="w-full min-w-0 max-w-[26rem]">
|
|
118
|
+
<button
|
|
119
|
+
type="button"
|
|
120
|
+
{...s.primaryProps}
|
|
121
|
+
className="grid w-full min-w-0 gap-0.5 rounded-lg border border-border bg-card p-3 text-left text-sm outline-none hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring"
|
|
122
|
+
>
|
|
123
|
+
<span className="text-xs text-muted-foreground">{it.kicker}</span>
|
|
124
|
+
<span className="font-semibold">{it.title}</span>
|
|
125
|
+
<span className="text-xs text-muted-foreground">{it.foot}</span>
|
|
126
|
+
</button>
|
|
127
|
+
{s.toggleProps ? (
|
|
128
|
+
<button type="button" {...s.toggleProps} className="mt-1 w-full text-left text-xs text-muted-foreground underline-offset-2 hover:underline">
|
|
129
|
+
{s.open ? "Hide" : "Show"} {s.count} sub-accounts
|
|
130
|
+
</button>
|
|
131
|
+
) : null}
|
|
132
|
+
</div>
|
|
133
|
+
)}
|
|
134
|
+
/>
|
|
135
|
+
</Section>
|
|
136
|
+
|
|
137
|
+
<Section title="One top, nothing beneath it">
|
|
138
|
+
<TierMap label="One top" items={[{ id: "only", title: "Be the default rate API for small carriers", kicker: "Company", value: 0.41, tone: "danger" }]} tops={["only"]} topsLabel="Company" onSelect={() => {}} />
|
|
139
|
+
</Section>
|
|
140
|
+
|
|
141
|
+
<Section title="Many tops, one open">
|
|
142
|
+
<TierMap
|
|
143
|
+
label="Many tops"
|
|
144
|
+
items={[
|
|
145
|
+
...Array.from({ length: 7 }, (_, i) => ({ id: `t${i}`, title: `Company goal ${i + 1}`, kicker: "Company", value: (i + 1) / 8 })),
|
|
146
|
+
...Array.from({ length: 4 }, (_, i) => ({ id: `t3k${i}`, parent: "t3", title: `Team goal ${i + 1}`, kicker: "Team", value: 0.2 * (i + 1) })),
|
|
147
|
+
]}
|
|
148
|
+
tops={Array.from({ length: 7 }, (_, i) => `t${i}`)}
|
|
149
|
+
topsLabel="Company"
|
|
150
|
+
childrenLabel="serving it"
|
|
151
|
+
defaultOpen={["t3"]}
|
|
152
|
+
onSelect={() => {}}
|
|
153
|
+
/>
|
|
154
|
+
</Section>
|
|
155
|
+
|
|
156
|
+
<Section title="Very long words" note="A title, a kicker and a foot with no spaces to break on, and a long sentence.">
|
|
157
|
+
<TierMap
|
|
158
|
+
label="Long words"
|
|
159
|
+
items={[
|
|
160
|
+
{
|
|
161
|
+
id: "l1",
|
|
162
|
+
title: "An exceptionally long goal that nobody had the heart to shorten, which goes on and on past the end of any sensible line of a card",
|
|
163
|
+
kicker: "A_kicker_that_is_a_single_word_much_too_long_for_its_line",
|
|
164
|
+
foot: "https://example.com/an/extremely/long/path/that/cannot/break/anywhere/at/all/ever",
|
|
165
|
+
value: 0.31,
|
|
166
|
+
by: person("Wolfeschlegelsteinhausenbergerdorff Smith"),
|
|
167
|
+
},
|
|
168
|
+
{ id: "l2", parent: "l1", title: "Short", value: 0.9 },
|
|
169
|
+
]}
|
|
170
|
+
tops={["l1"]}
|
|
171
|
+
defaultOpen={["l1"]}
|
|
172
|
+
onSelect={() => {}}
|
|
173
|
+
/>
|
|
174
|
+
</Section>
|
|
175
|
+
|
|
176
|
+
<Section title="Narrow (320 px)" note="Tiers stack, cards go full width, the lines are a rail down the left.">
|
|
177
|
+
<div className="w-80 max-w-full">
|
|
178
|
+
<TierMap label="Narrow" items={GOALS} tops={GOAL_TOPS} topsLabel="Company" childrenLabel="serving it" defaultOpen={["c1", "s1"]} onSelect={() => {}} unparentedNote={note} />
|
|
179
|
+
</div>
|
|
180
|
+
</Section>
|
|
181
|
+
|
|
182
|
+
<Section title="Wide (1200 px)" note="A tier of six cards sits in one row with an elbow from its parent to each.">
|
|
183
|
+
<div className="w-[1200px] max-w-full">
|
|
184
|
+
<TierMap label="Wide" items={GOALS} tops={GOAL_TOPS} topsLabel="Company" childrenLabel="serving it" defaultOpen={["c1"]} onSelect={() => {}} />
|
|
185
|
+
</div>
|
|
186
|
+
</Section>
|
|
187
|
+
|
|
188
|
+
<Section title="A loop and a missing parent" note="a1 and a2 name each other: the first in the list becomes the top. A card whose parent is not in the list sits under nothing.">
|
|
189
|
+
<TierMap
|
|
190
|
+
label="Odd data"
|
|
191
|
+
items={[
|
|
192
|
+
{ id: "a1", parent: "a2", title: "Names a2 as its parent" },
|
|
193
|
+
{ id: "a2", parent: "a1", title: "Names a1 as its parent" },
|
|
194
|
+
{ id: "a3", parent: "gone", title: "Its parent is not in the list" },
|
|
195
|
+
{ id: "a4", parent: "a4", title: "Names itself" },
|
|
196
|
+
]}
|
|
197
|
+
tops={["a1"]}
|
|
198
|
+
defaultOpen={["a1"]}
|
|
199
|
+
topsLabel="Tops"
|
|
200
|
+
unparentedLabel="Under nothing"
|
|
201
|
+
onSelect={() => {}}
|
|
202
|
+
/>
|
|
203
|
+
</Section>
|
|
204
|
+
|
|
205
|
+
<Section title="Read-only" note="No onSelect: pressing a card opens its tier; a leaf does nothing.">
|
|
206
|
+
<TierMap label="Read-only" items={GOALS.slice(0, 11)} tops={GOAL_TOPS} topsLabel="Company" childrenLabel="serving it" />
|
|
207
|
+
</Section>
|
|
208
|
+
|
|
209
|
+
<Section title="Empty">
|
|
210
|
+
<TierMap label="Empty" items={[]} />
|
|
211
|
+
</Section>
|
|
212
|
+
|
|
213
|
+
<Section title="Loading">
|
|
214
|
+
<TierMap label="Loading" loading items={[]} />
|
|
215
|
+
</Section>
|
|
216
|
+
|
|
217
|
+
<Section title="Failed">
|
|
218
|
+
<TierMap label="Failed" error="The goals could not be loaded." onRetry={() => {}} items={[]} />
|
|
219
|
+
</Section>
|
|
220
|
+
</div>
|
|
221
|
+
);
|
|
222
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
// The TierMap block — `makersclaw add tier-map`. Fixed: compose it through
|
|
2
|
+
// its props (README.md beside this file). The model's helpers are plain
|
|
3
|
+
// functions; they work on the server too.
|
|
4
|
+
export { TierMap, TierCard } from "./tier-map";
|
|
5
|
+
export {
|
|
6
|
+
CARD_REM,
|
|
7
|
+
MAX_COLUMNS,
|
|
8
|
+
NEVER,
|
|
9
|
+
TONES,
|
|
10
|
+
barOf,
|
|
11
|
+
buildTierModel,
|
|
12
|
+
centreOf,
|
|
13
|
+
countText,
|
|
14
|
+
elbowOf,
|
|
15
|
+
fitKey,
|
|
16
|
+
neighbour,
|
|
17
|
+
openPath,
|
|
18
|
+
pathTo,
|
|
19
|
+
siblingsOf,
|
|
20
|
+
thresholdRem,
|
|
21
|
+
tiersOf,
|
|
22
|
+
togglePath,
|
|
23
|
+
toneOf,
|
|
24
|
+
} from "./tier-model";
|