foldkit 0.33.0 → 0.33.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.
@@ -1,3 +1,3 @@
1
- declare const overlayStyles = ":host {\n --dt-bg: #1e1e2e;\n --dt-surface-selected: #282839;\n --dt-border: #585b70;\n --dt-text: #cdd6f4;\n --dt-text-muted: #9399b2;\n --dt-accent: #cba6f7;\n --dt-live: #a6e3a1;\n --dt-paused: #fab387;\n --dt-json-string: #a6e3a1;\n --dt-json-number: #89b4fa;\n --dt-json-boolean: #fab387;\n --dt-json-null: #9399b2;\n --dt-json-key: #89dceb;\n --dt-json-tag: #cba6f7;\n --dt-json-preview: #9399b2;\n --dt-json-arrow: #9399b2;\n --dt-tree-hover: #313244;\n --dt-diff-changed: #74c7ec;\n}\n\n*,\n*::before,\n*::after {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n}\nbutton {\n font: inherit;\n color: inherit;\n}\n\n.fixed {\n position: fixed;\n}\n.flex {\n display: flex;\n}\n.flex-col {\n flex-direction: column;\n}\n.flex-1 {\n flex: 1 1 0%;\n}\n.items-center {\n align-items: center;\n}\n.justify-center {\n justify-content: center;\n}\n.justify-between {\n justify-content: space-between;\n}\n.shrink-0 {\n flex-shrink: 0;\n}\n.inline-block {\n display: inline-block;\n}\n.gap-0\\.5 {\n gap: 2px;\n}\n.gap-1\\.5 {\n gap: 6px;\n}\n.gap-2 {\n gap: 8px;\n}\n.gap-px {\n gap: 1px;\n}\n.px-1 {\n padding-left: 4px;\n padding-right: 4px;\n}\n.px-2 {\n padding-left: 8px;\n padding-right: 8px;\n}\n.px-2\\.5 {\n padding-left: 10px;\n padding-right: 10px;\n}\n.px-3 {\n padding-left: 12px;\n padding-right: 12px;\n}\n.py-0\\.5 {\n padding-top: 2px;\n padding-bottom: 2px;\n}\n.pt-1 {\n padding-top: 4px;\n}\n.pl-1 {\n padding-left: 4px;\n}\n.py-1 {\n padding-top: 4px;\n padding-bottom: 4px;\n}\n.py-1\\.5 {\n padding-top: 6px;\n padding-bottom: 6px;\n}\n.py-2 {\n padding-top: 8px;\n padding-bottom: 8px;\n}\n.py-px {\n padding-top: 1px;\n padding-bottom: 1px;\n}\n.w-1\\.5 {\n width: 6px;\n}\n.h-1\\.5 {\n height: 6px;\n}\n.w-3 {\n width: 12px;\n}\n.w-5 {\n width: 20px;\n}\n.h-5 {\n height: 20px;\n}\n.w-14 {\n width: 56px;\n}\n.h-14 {\n height: 56px;\n}\n.min-w-0 {\n min-width: 0;\n}\n.min-w-5 {\n min-width: 20px;\n}\n.min-h-0 {\n min-height: 0;\n}\n/* Badge positions \u2014 flush against side edge */\n.dt-pos-br {\n bottom: 16px;\n right: 0;\n border-radius: 6px 0 0 6px;\n}\n.dt-pos-bl {\n bottom: 16px;\n left: 0;\n border-radius: 0 6px 6px 0;\n}\n.dt-pos-tr {\n top: 16px;\n right: 0;\n border-radius: 6px 0 0 6px;\n}\n.dt-pos-tl {\n top: 16px;\n left: 0;\n border-radius: 0 6px 6px 0;\n}\n.overflow-hidden {\n overflow: hidden;\n}\n.overflow-auto {\n overflow: auto;\n}\n.overflow-y-auto {\n overflow-y: auto;\n}\n.truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.rounded {\n border-radius: 4px;\n}\n.rounded-lg {\n border-radius: 8px;\n}\n.rounded-full {\n border-radius: 9999px;\n}\n.border {\n border-width: 1px;\n border-style: solid;\n border-color: var(--dt-border);\n}\n.border-b {\n border-bottom: 1px solid var(--dt-border);\n}\n.border-t {\n border-top: 1px solid var(--dt-border);\n}\n.border-r {\n border-right: 1px solid var(--dt-border);\n}\n.border-l {\n border-left: 1px solid var(--dt-border);\n}\n.border-none {\n border: none;\n}\n.border-l-3 {\n border-left: 3px solid transparent;\n}\n.border-dt-live {\n border-color: var(--dt-live);\n}\n.selected {\n background-color: var(--dt-surface-selected);\n}\n.dt-row:hover:not(.selected) {\n background-color: var(--dt-tree-hover);\n}\n.dt-header-button:hover {\n color: var(--dt-text);\n}\n.dt-resume-button:hover {\n color: var(--dt-text);\n}\n.dt-tab-button {\n position: relative;\n background: transparent;\n border: none;\n border-right: 1px solid var(--dt-border);\n outline: none;\n flex: 1;\n}\n.dt-tab-label {\n position: relative;\n}\n.dt-tab-arrow {\n position: absolute;\n right: 100%;\n top: 50%;\n transform: translateY(-50%);\n margin-right: 5px;\n font-size: 15px;\n color: var(--dt-accent);\n}\n.dt-tab-button:not(.dt-tab-active):hover {\n color: var(--dt-text);\n background-color: rgba(49, 50, 68, 0.3);\n}\n.font-sans {\n font-family:\n system-ui,\n -apple-system,\n BlinkMacSystemFont,\n 'Segoe UI',\n Roboto,\n sans-serif;\n}\n.font-mono {\n font-family:\n ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;\n}\n.font-medium {\n font-weight: 500;\n}\n.font-semibold {\n font-weight: 600;\n}\n.text-xs {\n font-size: 12px;\n}\n.text-2xs {\n font-size: 10px;\n}\n.text-sm {\n font-size: 11px;\n}\n.text-base {\n font-size: 13px;\n}\n.text-md {\n font-size: 15px;\n}\n.text-lg {\n font-size: 20px;\n}\n.text-xl {\n font-size: 26px;\n}\n.italic {\n font-style: italic;\n}\n.text-right {\n text-align: right;\n}\n.tracking-wide {\n letter-spacing: 0.025em;\n}\n.tracking-wider {\n letter-spacing: 0.05em;\n}\n.leading-snug {\n line-height: 1.35;\n}\n.bg-dt-bg {\n background-color: var(--dt-bg);\n}\n.bg-dt-live {\n background-color: var(--dt-live);\n}\n.bg-transparent {\n background-color: transparent;\n}\n.text-dt {\n color: var(--dt-text);\n}\n.text-dt-muted {\n color: var(--dt-text-muted);\n}\n.text-dt-accent {\n color: var(--dt-accent);\n}\n.text-dt-live {\n color: var(--dt-live);\n}\n.text-dt-paused {\n color: var(--dt-paused);\n}\n.cursor-pointer {\n cursor: pointer;\n}\n.outline-none {\n outline: none;\n}\n.transition-colors {\n transition-property: color, background-color, border-color;\n transition-duration: 100ms;\n transition-timing-function: ease;\n}\n\n/* Panel */\n.dt-panel {\n width: 360px;\n height: 480px;\n box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);\n z-index: 99998;\n}\n/* Panel positions */\n.dt-panel-br {\n bottom: 16px;\n right: 28px;\n}\n.dt-panel-bl {\n bottom: 16px;\n left: 28px;\n}\n.dt-panel-tr {\n top: 16px;\n right: 28px;\n}\n.dt-panel-tl {\n top: 16px;\n left: 28px;\n}\n.dt-panel-wide {\n width: 720px;\n}\n.dt-message-pane {\n width: 320px;\n flex-shrink: 0;\n}\n.dt-badge {\n z-index: 99999;\n box-shadow: -2px 0 8px rgba(0, 0, 0, 0.3);\n transition: background-color 150ms ease;\n}\n.dt-badge-accent {\n border: none;\n}\n.dt-badge-accent:hover {\n background-color: #252538;\n}\n.dt-badge-paused {\n background-color: var(--dt-paused);\n color: var(--dt-bg);\n border: none;\n}\n.dt-badge-paused:hover {\n background-color: #e0a070;\n}\n.message-list > :last-child {\n border-bottom: none;\n}\n\n/* JSON tree */\n.tree-row {\n position: relative;\n white-space: nowrap;\n line-height: 1.5;\n padding-right: 8px;\n}\n.tree-row-expandable:hover {\n background-color: var(--dt-tree-hover);\n}\n.inspector-tree {\n font-family:\n ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;\n}\n.json-key {\n color: var(--dt-json-key);\n}\n.json-string {\n color: var(--dt-json-string);\n}\n.json-number {\n color: var(--dt-json-number);\n}\n.json-boolean {\n color: var(--dt-json-boolean);\n}\n.json-null {\n color: var(--dt-json-null);\n}\n.json-tag {\n color: var(--dt-json-tag);\n margin-right: 4px;\n}\n.json-preview {\n color: var(--dt-json-preview);\n}\n.json-arrow {\n color: var(--dt-json-arrow);\n width: 10px;\n height: 10px;\n user-select: none;\n}\n\n/* Diff */\n.diff-changed {\n background-color: rgba(116, 199, 236, 0.06);\n}\n.diff-dot {\n position: absolute;\n left: 3px;\n width: 5px;\n height: 5px;\n border-radius: 9999px;\n background-color: var(--dt-diff-changed);\n}\n.diff-dot-inline {\n width: 5px;\n height: 5px;\n border-radius: 9999px;\n background-color: var(--dt-diff-changed);\n flex-shrink: 0;\n}\n.dot-column {\n width: 5px;\n flex-shrink: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n.pause-column {\n width: 8px;\n flex-shrink: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n.dt-pause-icon {\n width: 8px;\n height: 8px;\n color: var(--dt-paused);\n}\n\n/* Interaction blocker \u2014 covers the app while time-travelling */\n.dt-interaction-blocker {\n position: fixed;\n inset: 0;\n z-index: 99997;\n cursor: not-allowed;\n}\n\n/* Mobile */\n@media (max-width: 767px) {\n .dt-panel {\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n width: 100%;\n height: 100%;\n border-radius: 0;\n border: none;\n }\n .dt-panel-wide {\n width: 100%;\n }\n .dt-content {\n flex-direction: column;\n }\n .dt-message-pane {\n width: 100%;\n max-height: 40%;\n border-bottom: 1px solid var(--dt-border);\n }\n .dt-inspector-pane {\n border-left: none;\n }\n}\n";
1
+ declare const overlayStyles = ":host {\n --dt-bg: #1e1e2e;\n --dt-surface-selected: #282839;\n --dt-border: #585b70;\n --dt-text: #cdd6f4;\n --dt-text-muted: #9399b2;\n --dt-accent: #cba6f7;\n --dt-live: #a6e3a1;\n --dt-paused: #fab387;\n --dt-json-string: #a6e3a1;\n --dt-json-number: #89b4fa;\n --dt-json-boolean: #fab387;\n --dt-json-null: #9399b2;\n --dt-json-key: #89dceb;\n --dt-json-tag: #cba6f7;\n --dt-json-preview: #9399b2;\n --dt-json-arrow: #9399b2;\n --dt-tree-hover: #313244;\n --dt-diff-changed: #74c7ec;\n}\n\n*,\n*::before,\n*::after {\n box-sizing: border-box;\n margin: 0;\n padding: 0;\n}\nbutton {\n font: inherit;\n color: inherit;\n}\nul {\n list-style: none;\n}\n\n.fixed {\n position: fixed;\n}\n.flex {\n display: flex;\n}\n.flex-col {\n flex-direction: column;\n}\n.flex-1 {\n flex: 1 1 0%;\n}\n.items-center {\n align-items: center;\n}\n.justify-center {\n justify-content: center;\n}\n.justify-between {\n justify-content: space-between;\n}\n.shrink-0 {\n flex-shrink: 0;\n}\n.inline-block {\n display: inline-block;\n}\n.gap-0\\.5 {\n gap: 2px;\n}\n.gap-1\\.5 {\n gap: 6px;\n}\n.gap-2 {\n gap: 8px;\n}\n.gap-px {\n gap: 1px;\n}\n.px-1 {\n padding-left: 4px;\n padding-right: 4px;\n}\n.px-2 {\n padding-left: 8px;\n padding-right: 8px;\n}\n.px-2\\.5 {\n padding-left: 10px;\n padding-right: 10px;\n}\n.p-3 {\n padding: 12px;\n}\n.px-3 {\n padding-left: 12px;\n padding-right: 12px;\n}\n.py-0\\.5 {\n padding-top: 2px;\n padding-bottom: 2px;\n}\n.pt-1 {\n padding-top: 4px;\n}\n.pl-1 {\n padding-left: 4px;\n}\n.py-1 {\n padding-top: 4px;\n padding-bottom: 4px;\n}\n.py-1\\.5 {\n padding-top: 6px;\n padding-bottom: 6px;\n}\n.py-2 {\n padding-top: 8px;\n padding-bottom: 8px;\n}\n.py-px {\n padding-top: 1px;\n padding-bottom: 1px;\n}\n.w-1\\.5 {\n width: 6px;\n}\n.h-1\\.5 {\n height: 6px;\n}\n.w-3 {\n width: 12px;\n}\n.w-5 {\n width: 20px;\n}\n.h-5 {\n height: 20px;\n}\n.w-14 {\n width: 56px;\n}\n.h-14 {\n height: 56px;\n}\n.min-w-0 {\n min-width: 0;\n}\n.min-w-5 {\n min-width: 20px;\n}\n.min-h-0 {\n min-height: 0;\n}\n/* Badge positions \u2014 flush against side edge */\n.dt-pos-br {\n bottom: 16px;\n right: 0;\n border-radius: 6px 0 0 6px;\n}\n.dt-pos-bl {\n bottom: 16px;\n left: 0;\n border-radius: 0 6px 6px 0;\n}\n.dt-pos-tr {\n top: 16px;\n right: 0;\n border-radius: 6px 0 0 6px;\n}\n.dt-pos-tl {\n top: 16px;\n left: 0;\n border-radius: 0 6px 6px 0;\n}\n.overflow-hidden {\n overflow: hidden;\n}\n.overflow-auto {\n overflow: auto;\n}\n.overflow-y-auto {\n overflow-y: auto;\n}\n.overscroll-contain {\n overscroll-behavior: contain;\n}\n.truncate {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.rounded {\n border-radius: 4px;\n}\n.rounded-lg {\n border-radius: 8px;\n}\n.rounded-full {\n border-radius: 9999px;\n}\n.border {\n border-width: 1px;\n border-style: solid;\n border-color: var(--dt-border);\n}\n.border-b {\n border-bottom: 1px solid var(--dt-border);\n}\n.border-t {\n border-top: 1px solid var(--dt-border);\n}\n.border-r {\n border-right: 1px solid var(--dt-border);\n}\n.border-l {\n border-left: 1px solid var(--dt-border);\n}\n.border-none {\n border: none;\n}\n.border-l-3 {\n border-left: 3px solid transparent;\n}\n.border-dt-live {\n border-color: var(--dt-live);\n}\n.selected {\n background-color: var(--dt-surface-selected);\n}\n.dt-row:hover:not(.selected) {\n background-color: var(--dt-tree-hover);\n}\n.dt-header-button:hover {\n color: var(--dt-text);\n}\n.dt-resume-button:hover {\n opacity: 0.7;\n}\n.dt-tab-button {\n position: relative;\n background: transparent;\n border: none;\n border-right: 1px solid var(--dt-border);\n outline: none;\n flex: 1;\n}\n.dt-tab-active {\n background-color: var(--dt-surface-selected);\n}\n.dt-tab-button:not(.dt-tab-active):hover {\n color: var(--dt-text);\n background-color: rgba(49, 50, 68, 0.3);\n}\n.font-sans {\n font-family:\n system-ui,\n -apple-system,\n BlinkMacSystemFont,\n 'Segoe UI',\n Roboto,\n sans-serif;\n}\n.font-mono {\n font-family:\n ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;\n}\n.font-medium {\n font-weight: 500;\n}\n.font-semibold {\n font-weight: 600;\n}\n.text-xs {\n font-size: 12px;\n}\n.text-2xs {\n font-size: 10px;\n}\n.text-sm {\n font-size: 11px;\n}\n.text-base {\n font-size: 13px;\n}\n.text-md {\n font-size: 15px;\n}\n.text-lg {\n font-size: 20px;\n}\n.text-xl {\n font-size: 26px;\n}\n.italic {\n font-style: italic;\n}\n.text-right {\n text-align: right;\n}\n.tracking-wide {\n letter-spacing: 0.025em;\n}\n.tracking-wider {\n letter-spacing: 0.05em;\n}\n.leading-none {\n line-height: 1;\n}\n.leading-snug {\n line-height: 1.35;\n}\n.bg-dt-bg {\n background-color: var(--dt-bg);\n}\n.bg-dt-live {\n background-color: var(--dt-live);\n}\n.bg-transparent {\n background-color: transparent;\n}\n.text-dt {\n color: var(--dt-text);\n}\n.text-dt-muted {\n color: var(--dt-text-muted);\n}\n.text-dt-accent {\n color: var(--dt-accent);\n}\n.text-dt-live {\n color: var(--dt-live);\n}\n.text-dt-paused {\n color: var(--dt-paused);\n}\n.cursor-pointer {\n cursor: pointer;\n}\n.outline-none {\n outline: none;\n}\n.transition-colors {\n transition-property: color, background-color, border-color;\n transition-duration: 100ms;\n transition-timing-function: ease;\n}\n\n/* Panel */\n.dt-panel {\n width: 360px;\n height: 480px;\n box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);\n z-index: 99998;\n}\n/* Panel positions */\n.dt-panel-br {\n bottom: 16px;\n right: 28px;\n}\n.dt-panel-bl {\n bottom: 16px;\n left: 28px;\n}\n.dt-panel-tr {\n top: 16px;\n right: 28px;\n}\n.dt-panel-tl {\n top: 16px;\n left: 28px;\n}\n.dt-panel-wide {\n width: 720px;\n}\n.dt-message-pane {\n width: 320px;\n flex-shrink: 0;\n}\n.dt-badge {\n z-index: 99999;\n box-shadow: -2px 0 8px rgba(0, 0, 0, 0.3);\n transition: background-color 150ms ease;\n}\n.dt-badge-accent {\n border: none;\n}\n.dt-badge-accent:hover {\n background-color: #252538;\n}\n.dt-badge-paused {\n background-color: var(--dt-paused);\n color: var(--dt-bg);\n border: none;\n}\n.dt-badge-paused:hover {\n background-color: #e0a070;\n}\n.message-list > :last-child {\n border-bottom: none;\n}\n\n/* JSON tree */\n.tree-row {\n position: relative;\n white-space: nowrap;\n line-height: 18px;\n padding-right: 8px;\n}\n.tree-row-expandable:hover {\n background-color: var(--dt-tree-hover);\n}\n.inspector-tree {\n font-family:\n ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;\n}\n.json-key {\n color: var(--dt-json-key);\n}\n.json-string {\n color: var(--dt-json-string);\n}\n.json-number {\n color: var(--dt-json-number);\n}\n.json-boolean {\n color: var(--dt-json-boolean);\n}\n.json-null {\n color: var(--dt-json-null);\n}\n.json-tag {\n color: var(--dt-json-tag);\n margin-right: 4px;\n}\n.json-preview {\n color: var(--dt-json-preview);\n}\n.json-arrow {\n color: var(--dt-json-arrow);\n width: 10px;\n height: 10px;\n user-select: none;\n}\n\n/* Diff */\n.diff-changed {\n background-color: rgba(116, 199, 236, 0.06);\n}\n.diff-dot {\n position: absolute;\n left: 3px;\n width: 5px;\n height: 5px;\n border-radius: 9999px;\n background-color: var(--dt-diff-changed);\n}\n.diff-dot-inline {\n width: 5px;\n height: 5px;\n border-radius: 9999px;\n background-color: var(--dt-diff-changed);\n flex-shrink: 0;\n}\n.dot-column {\n width: 5px;\n flex-shrink: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n.pause-column {\n width: 8px;\n flex-shrink: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n.dt-pause-icon {\n width: 8px;\n height: 8px;\n color: var(--dt-paused);\n}\n\n/* Interaction blocker \u2014 covers the app while time-travelling */\n.dt-interaction-blocker {\n position: fixed;\n inset: 0;\n z-index: 99997;\n cursor: not-allowed;\n}\n\n/* Mobile */\n@media (max-width: 767px) {\n .dt-panel {\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n width: 100%;\n height: 100%;\n border-radius: 0;\n border: none;\n }\n .dt-panel-wide {\n width: 100%;\n }\n .dt-content {\n flex-direction: column;\n }\n .dt-message-pane {\n width: 100%;\n max-height: 40%;\n border-bottom: 1px solid var(--dt-border);\n }\n .dt-inspector-pane {\n border-left: none;\n }\n}\n";
2
2
  export { overlayStyles };
3
3
  //# sourceMappingURL=overlay-styles.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"overlay-styles.d.ts","sourceRoot":"","sources":["../../src/devtools/overlay-styles.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,aAAa,iwQAggBlB,CAAA;AAED,OAAO,EAAE,aAAa,EAAE,CAAA"}
1
+ {"version":3,"file":"overlay-styles.d.ts","sourceRoot":"","sources":["../../src/devtools/overlay-styles.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,aAAa,mwQAmgBlB,CAAA;AAED,OAAO,EAAE,aAAa,EAAE,CAAA"}
@@ -30,6 +30,9 @@ button {
30
30
  font: inherit;
31
31
  color: inherit;
32
32
  }
33
+ ul {
34
+ list-style: none;
35
+ }
33
36
 
34
37
  .fixed {
35
38
  position: fixed;
@@ -82,6 +85,9 @@ button {
82
85
  padding-left: 10px;
83
86
  padding-right: 10px;
84
87
  }
88
+ .p-3 {
89
+ padding: 12px;
90
+ }
85
91
  .px-3 {
86
92
  padding-left: 12px;
87
93
  padding-right: 12px;
@@ -172,6 +178,9 @@ button {
172
178
  .overflow-y-auto {
173
179
  overflow-y: auto;
174
180
  }
181
+ .overscroll-contain {
182
+ overscroll-behavior: contain;
183
+ }
175
184
  .truncate {
176
185
  overflow: hidden;
177
186
  text-overflow: ellipsis;
@@ -222,7 +231,7 @@ button {
222
231
  color: var(--dt-text);
223
232
  }
224
233
  .dt-resume-button:hover {
225
- color: var(--dt-text);
234
+ opacity: 0.7;
226
235
  }
227
236
  .dt-tab-button {
228
237
  position: relative;
@@ -232,17 +241,8 @@ button {
232
241
  outline: none;
233
242
  flex: 1;
234
243
  }
235
- .dt-tab-label {
236
- position: relative;
237
- }
238
- .dt-tab-arrow {
239
- position: absolute;
240
- right: 100%;
241
- top: 50%;
242
- transform: translateY(-50%);
243
- margin-right: 5px;
244
- font-size: 15px;
245
- color: var(--dt-accent);
244
+ .dt-tab-active {
245
+ background-color: var(--dt-surface-selected);
246
246
  }
247
247
  .dt-tab-button:not(.dt-tab-active):hover {
248
248
  color: var(--dt-text);
@@ -300,6 +300,9 @@ button {
300
300
  .tracking-wider {
301
301
  letter-spacing: 0.05em;
302
302
  }
303
+ .leading-none {
304
+ line-height: 1;
305
+ }
303
306
  .leading-snug {
304
307
  line-height: 1.35;
305
308
  }
@@ -397,7 +400,7 @@ button {
397
400
  .tree-row {
398
401
  position: relative;
399
402
  white-space: nowrap;
400
- line-height: 1.5;
403
+ line-height: 18px;
401
404
  padding-right: 8px;
402
405
  }
403
406
  .tree-row-expandable:hover {
@@ -1,5 +1,5 @@
1
1
  import { Effect, Option } from 'effect';
2
2
  import type { DevtoolsMode, DevtoolsPosition } from '../runtime/runtime';
3
3
  import { type DevtoolsStore } from './store';
4
- export declare const createOverlay: (store: DevtoolsStore, position: DevtoolsPosition, mode: DevtoolsMode, maybeMessage: Option.Option<string>) => Effect.Effect<void, never, never>;
4
+ export declare const createOverlay: (store: DevtoolsStore, position: DevtoolsPosition, mode: DevtoolsMode, maybeBanner: Option.Option<string>) => Effect.Effect<void, never, never>;
5
5
  //# sourceMappingURL=overlay.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"overlay.d.ts","sourceRoot":"","sources":["../../src/devtools/overlay.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,MAAM,EAIN,MAAM,EAQP,MAAM,QAAQ,CAAA;AAOf,OAAO,KAAK,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AAKxE,OAAO,EAAE,KAAK,aAAa,EAA+B,MAAM,SAAS,CAAA;AAsrCzE,eAAO,MAAM,aAAa,GACxB,OAAO,aAAa,EACpB,UAAU,gBAAgB,EAC1B,MAAM,YAAY,EAClB,cAAc,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,sCAiDjC,CAAA"}
1
+ {"version":3,"file":"overlay.d.ts","sourceRoot":"","sources":["../../src/devtools/overlay.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,MAAM,EAIN,MAAM,EAQP,MAAM,QAAQ,CAAA;AAOf,OAAO,KAAK,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AAMxE,OAAO,EAAE,KAAK,aAAa,EAA+B,MAAM,SAAS,CAAA;AA8vCzE,eAAO,MAAM,aAAa,GACxB,OAAO,aAAa,EACpB,UAAU,gBAAgB,EAC1B,MAAM,YAAY,EAClB,aAAa,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,sCA2ChC,CAAA"}
@@ -6,6 +6,7 @@ import { m } from '../message';
6
6
  import { makeElement } from '../runtime/runtime';
7
7
  import { makeSubscriptions } from '../runtime/subscription';
8
8
  import { evo } from '../struct';
9
+ import { lockScroll, unlockScroll } from '../task/scrollLock';
9
10
  import * as Tabs from '../ui/tabs';
10
11
  import { overlayStyles } from './overlay-styles';
11
12
  import { INIT_INDEX } from './store';
@@ -25,6 +26,7 @@ const InspectorTabsModel = S.Struct({
25
26
  });
26
27
  const Model = S.Struct({
27
28
  isOpen: S.Boolean,
29
+ isMobile: S.Boolean,
28
30
  entries: S.Array(DisplayEntry),
29
31
  startIndex: S.Number,
30
32
  isPaused: S.Boolean,
@@ -37,6 +39,13 @@ const Model = S.Struct({
37
39
  affectedPaths: S.HashSetFromSelf(S.String),
38
40
  inspectorTabs: InspectorTabsModel,
39
41
  });
42
+ const Flags = S.Struct({
43
+ isMobile: S.Boolean,
44
+ entries: S.Array(DisplayEntry),
45
+ startIndex: S.Number,
46
+ isPaused: S.Boolean,
47
+ pausedAtIndex: S.Number,
48
+ });
40
49
  // MESSAGE
41
50
  const ClickedToggle = m('ClickedToggle');
42
51
  const ClickedRow = m('ClickedRow', { index: S.Number });
@@ -46,7 +55,12 @@ const CompletedJump = m('CompletedJump');
46
55
  const CompletedResume = m('CompletedResume');
47
56
  const ClickedFollowLatest = m('ClickedFollowLatest');
48
57
  const CompletedClear = m('CompletedClear');
49
- const CompletedScroll = m('CompletedScroll');
58
+ const LockedScroll = m('LockedScroll');
59
+ const UnlockedScroll = m('UnlockedScroll');
60
+ const ScrolledToTop = m('ScrolledToTop');
61
+ const CrossedMobileBreakpoint = m('CrossedMobileBreakpoint', {
62
+ isMobile: S.Boolean,
63
+ });
50
64
  const ReceivedInspectedState = m('ReceivedInspectedState', {
51
65
  model: S.Unknown,
52
66
  maybeMessage: S.OptionFromSelf(S.Unknown),
@@ -63,9 +77,11 @@ const ReceivedStoreUpdate = m('ReceivedStoreUpdate', {
63
77
  isPaused: S.Boolean,
64
78
  pausedAtIndex: S.Number,
65
79
  });
66
- const Message = S.Union(ClickedToggle, ClickedRow, ClickedResume, ClickedClear, ClickedFollowLatest, CompletedJump, CompletedResume, CompletedClear, CompletedScroll, ReceivedInspectedState, ToggledTreeNode, GotInspectorTabsMessage, ReceivedStoreUpdate);
80
+ const Message = S.Union(ClickedToggle, ClickedRow, ClickedResume, ClickedClear, ClickedFollowLatest, CompletedJump, CompletedResume, CompletedClear, LockedScroll, UnlockedScroll, ScrolledToTop, CrossedMobileBreakpoint, ReceivedInspectedState, ToggledTreeNode, GotInspectorTabsMessage, ReceivedStoreUpdate);
67
81
  // HELPERS
68
82
  const MILLIS_PER_SECOND = 1000;
83
+ const MOBILE_BREAKPOINT = 767;
84
+ const MOBILE_BREAKPOINT_QUERY = `(max-width: ${MOBILE_BREAKPOINT}px)`;
69
85
  const TREE_INDENT_PX = 12;
70
86
  const MAX_PREVIEW_KEYS = 3;
71
87
  const formatTimeDelta = (deltaMs) => M.value(deltaMs).pipe(M.when(0, () => '0ms'), M.when(Number_.lessThan(MILLIS_PER_SECOND), ms => `+${Math.round(ms)}ms`), M.orElse(ms => `+${(ms / MILLIS_PER_SECOND).toFixed(1)}s`));
@@ -184,19 +200,27 @@ const makeUpdate = (store, shadow, mode) => {
184
200
  yield* store.clear;
185
201
  return CompletedClear();
186
202
  });
203
+ const toggleScrollLock = (shouldLock) => shouldLock
204
+ ? lockScroll.pipe(Effect.as(LockedScroll()))
205
+ : unlockScroll.pipe(Effect.as(UnlockedScroll()));
187
206
  const scrollToTop = Effect.sync(() => {
188
207
  const messageList = shadow.querySelector(MESSAGE_LIST_SELECTOR);
189
208
  if (messageList instanceof HTMLElement) {
190
209
  messageList.scrollTop = 0;
191
210
  }
192
- return CompletedScroll();
211
+ return ScrolledToTop();
193
212
  });
194
213
  return (model, message) => M.value(message).pipe(M.withReturnType(), M.tags({
195
- ClickedToggle: () => [
196
- evo(model, {
197
- isOpen: isOpen => !isOpen,
198
- }),
199
- [],
214
+ ClickedToggle: () => {
215
+ const nextIsOpen = !model.isOpen;
216
+ return [
217
+ evo(model, { isOpen: () => nextIsOpen }),
218
+ OptionExt.when(model.isMobile, toggleScrollLock(nextIsOpen)).pipe(Option.toArray),
219
+ ];
220
+ },
221
+ CrossedMobileBreakpoint: ({ isMobile }) => [
222
+ evo(model, { isMobile: () => isMobile }),
223
+ OptionExt.when(model.isOpen, toggleScrollLock(isMobile)).pipe(Option.toArray),
200
224
  ],
201
225
  ClickedRow: ({ index }) => M.value(mode).pipe(M.withReturnType(), M.when('TimeTravel', () => [
202
226
  model,
@@ -218,13 +242,11 @@ const makeUpdate = (store, shadow, mode) => {
218
242
  ClickedClear: () => [
219
243
  evo(model, {
220
244
  maybeSelectedIndex: () => Option.none(),
221
- maybeInspectedModel: () => Option.none(),
222
- maybeInspectedMessage: () => Option.none(),
223
245
  expandedPaths: () => HashSet.empty(),
224
246
  changedPaths: () => HashSet.empty(),
225
247
  affectedPaths: () => HashSet.empty(),
226
248
  }),
227
- [clear],
249
+ [clear, inspectLatest],
228
250
  ],
229
251
  ClickedFollowLatest: () => [
230
252
  evo(model, {
@@ -273,17 +295,29 @@ const makeUpdate = (store, shadow, mode) => {
273
295
  shouldFollowLatest ? [scrollToTop, inspectLatest] : [],
274
296
  ];
275
297
  },
276
- }), M.tag('CompletedJump', 'CompletedResume', 'CompletedClear', 'CompletedScroll', () => [model, []]), M.exhaustive);
298
+ }), M.tag('CompletedJump', 'CompletedResume', 'CompletedClear', 'LockedScroll', 'UnlockedScroll', 'ScrolledToTop', () => [model, []]), M.exhaustive);
277
299
  };
278
300
  // SUBSCRIPTION
279
301
  const SubscriptionDeps = S.Struct({
280
302
  storeUpdates: S.Null,
303
+ mobileBreakpoint: S.Null,
281
304
  });
282
305
  const makeOverlaySubscriptions = (store) => makeSubscriptions(SubscriptionDeps)({
283
306
  storeUpdates: {
284
307
  modelToDependencies: () => null,
285
308
  depsToStream: () => Stream.concat(Stream.make(pipe(SubscriptionRef.get(store.stateRef), Effect.map(state => ReceivedStoreUpdate(toDisplayState(state))))), pipe(store.stateRef.changes, Stream.map(state => Effect.succeed(ReceivedStoreUpdate(toDisplayState(state)))))),
286
309
  },
310
+ mobileBreakpoint: {
311
+ modelToDependencies: () => null,
312
+ depsToStream: () => Stream.async(emit => {
313
+ const mediaQuery = window.matchMedia(MOBILE_BREAKPOINT_QUERY);
314
+ const handler = (event) => {
315
+ emit.single(Effect.succeed(CrossedMobileBreakpoint({ isMobile: event.matches })));
316
+ };
317
+ mediaQuery.addEventListener('change', handler);
318
+ return Effect.sync(() => mediaQuery.removeEventListener('change', handler));
319
+ }),
320
+ },
287
321
  });
288
322
  // VIEW
289
323
  const indexClass = 'text-2xs text-dt-muted font-mono min-w-5';
@@ -301,8 +335,8 @@ const PANEL_POSITION_CLASS = {
301
335
  TopRight: 'dt-panel-tr',
302
336
  TopLeft: 'dt-panel-tl',
303
337
  };
304
- const makeView = (position, mode, maybeMessage) => {
305
- const { div, span, button, svg, path, Class, Style, OnClick, AriaHidden, Xmlns, Fill, ViewBox, StrokeWidth, Stroke, StrokeLinecap, StrokeLinejoin, D, } = html();
338
+ const makeView = (position, mode, maybeBanner) => {
339
+ const { div, header, span, ul, button, svg, path, keyed, Class, Style, OnClick, AriaHidden, Xmlns, Fill, ViewBox, StrokeWidth, Stroke, StrokeLinecap, StrokeLinejoin, D, empty, } = html();
306
340
  // JSON TREE
307
341
  const leafValueView = (value) => M.value(value).pipe(M.when(Predicate.isNull, () => span([Class('json-null italic')], ['null'])), M.when(Predicate.isUndefined, () => span([Class('json-null italic')], ['undefined'])), M.when(Predicate.isString, stringValue => span([Class('json-string')], [`"${stringValue}"`])), M.when(Predicate.isNumber, numberValue => span([Class('json-number')], [String(numberValue)])), M.when(Predicate.isBoolean, booleanValue => span([Class('json-boolean')], [String(booleanValue)])), M.orElse(unknownValue => span([Class('json-null')], [String(unknownValue)])));
308
342
  const keyView = (key) => span([Class('json-key')], [`${key}:\u00a0`]);
@@ -389,7 +423,9 @@ const makeView = (position, mode, maybeMessage) => {
389
423
  const treeView = (value, rootPath, expandedPaths, changedPaths, affectedPaths, maybeRootLabel, indentRootChildren) => {
390
424
  const nodes = [];
391
425
  flattenTree(value, rootPath, expandedPaths, changedPaths, affectedPaths, 0, maybeRootLabel, nodes, indentRootChildren);
392
- return div([Class('inspector-tree flex-1 overflow-auto min-h-0 min-w-0')], nodes.map(flatNodeView));
426
+ return div([
427
+ Class('inspector-tree flex-1 overflow-auto overscroll-contain min-h-0 min-w-0'),
428
+ ], nodes.map(flatNodeView));
393
429
  };
394
430
  const inspectedTimestamp = (model) => {
395
431
  const lastIndex = Array_.isEmptyReadonlyArray(model.entries)
@@ -441,10 +477,7 @@ const makeView = (position, mode, maybeMessage) => {
441
477
  tabListClassName: 'flex border-b shrink-0',
442
478
  tabToConfig: (tab, { isActive }) => ({
443
479
  buttonClassName: clsx('dt-tab-button cursor-pointer text-base font-mono px-3 py-1', isActive ? 'text-dt dt-tab-active' : 'text-dt-muted'),
444
- buttonContent: span([Class('dt-tab-label')], [
445
- ...(isActive ? [span([Class('dt-tab-arrow')], ['→'])] : []),
446
- tab,
447
- ]),
480
+ buttonContent: span([], [tab]),
448
481
  panelClassName: 'flex flex-col flex-1 min-h-0 min-w-0',
449
482
  panelContent: Option.match(model.maybeInspectedModel, {
450
483
  onNone: () => emptyInspectorView,
@@ -476,47 +509,47 @@ const makeView = (position, mode, maybeMessage) => {
476
509
  ], []),
477
510
  ])
478
511
  : div([
479
- Class('flex flex-col items-center gap-0.5 text-dt-muted font-semibold tracking-wider'),
512
+ Class('flex flex-col items-center gap-0.5 text-dt-muted font-semibold tracking-wider leading-none'),
480
513
  ], [span([], ['D']), span([], ['E']), span([], ['V'])]),
481
514
  ]);
482
515
  const headerClass = 'flex items-center justify-between px-3 py-1.5 border-b shrink-0';
483
- const liveHeaderView = div([Class(headerClass)], [
484
- span([Class('text-base text-dt-live font-medium font-mono')], ['Live']),
485
- button([Class(headerButtonClass), OnClick(ClickedClear())], ['Clear history']),
486
- ]);
487
- const pausedHeaderView = (model) => div([Class(headerClass)], [
488
- button([
489
- Class('dt-resume-button bg-transparent border-none text-dt-live cursor-pointer text-base font-mono font-medium'),
490
- OnClick(ClickedResume()),
491
- ], ['Resume ']),
492
- span([Class('text-base text-dt-paused font-mono')], [
493
- model.pausedAtIndex === INIT_INDEX
494
- ? 'Paused (init)'
495
- : `Paused (${model.pausedAtIndex + 1})`,
496
- ]),
497
- button([Class(headerButtonClass), OnClick(ClickedClear())], ['Clear history']),
498
- ]);
499
- const inspectingHeaderView = (selectedIndex) => div([Class(headerClass)], [
500
- button([
501
- Class('dt-resume-button bg-transparent border-none text-dt-live cursor-pointer text-base font-mono font-medium'),
502
- OnClick(ClickedFollowLatest()),
503
- ], ['Follow latest →']),
504
- span([Class('text-base text-dt-accent font-mono')], [
505
- selectedIndex === INIT_INDEX
506
- ? 'Inspecting (init)'
507
- : `Inspecting (${selectedIndex + 1})`,
508
- ]),
509
- button([Class(headerButtonClass), OnClick(ClickedClear())], ['Clear history']),
510
- ]);
511
- const headerView = (model) => M.value(mode).pipe(M.when('Inspect', () => Option.match(model.maybeSelectedIndex, {
512
- onNone: () => liveHeaderView,
513
- onSome: inspectingHeaderView,
514
- })), M.when('TimeTravel', () => model.isPaused ? pausedHeaderView(model) : liveHeaderView), M.exhaustive);
515
- const initRowView = (isSelected, isPausedHere) => div([
516
+ const actionButtonClass = 'dt-resume-button bg-transparent border-none text-dt-live cursor-pointer text-base font-mono font-medium';
517
+ const statusClass = 'text-base font-mono';
518
+ const clearHistoryButton = button([Class(headerButtonClass), OnClick(ClickedClear())], ['Clear history']);
519
+ const headerView = (model) => {
520
+ const { status, action } = M.value(mode).pipe(M.withReturnType(), M.when('TimeTravel', () => model.isPaused
521
+ ? {
522
+ status: span([Class(`${statusClass} text-dt-paused`)], [
523
+ model.pausedAtIndex === INIT_INDEX
524
+ ? 'Paused (init)'
525
+ : `Paused (${model.pausedAtIndex + 1})`,
526
+ ]),
527
+ action: button([Class(actionButtonClass), OnClick(ClickedResume())], ['Resume →']),
528
+ }
529
+ : {
530
+ status: span([Class(`${statusClass} text-dt-live font-medium`)], ['Live']),
531
+ action: empty,
532
+ }), M.when('Inspect', () => Option.match(model.maybeSelectedIndex, {
533
+ onNone: () => ({
534
+ status: empty,
535
+ action: empty,
536
+ }),
537
+ onSome: selectedIndex => ({
538
+ status: span([Class(`${statusClass} text-dt-accent`)], [
539
+ selectedIndex === INIT_INDEX
540
+ ? 'Inspecting (init)'
541
+ : `Inspecting (${selectedIndex + 1})`,
542
+ ]),
543
+ action: button([Class(actionButtonClass), OnClick(ClickedFollowLatest())], ['Follow Latest →']),
544
+ }),
545
+ })), M.exhaustive);
546
+ return header([Class(headerClass)], [status, action, clearHistoryButton]);
547
+ };
548
+ const initRowView = (isSelected, isPausedHere) => keyed('li')('init', [
516
549
  Class(clsx(ROW_BASE, isSelected && 'selected')),
517
550
  OnClick(ClickedRow({ index: INIT_INDEX })),
518
551
  ], [
519
- span([Class('pause-column')], isPausedHere ? [pauseIconView] : []),
552
+ ...OptionExt.when(mode === 'TimeTravel', span([Class('pause-column')], isPausedHere ? [pauseIconView] : [])).pipe(Option.toArray),
520
553
  span([Class('dot-column')], []),
521
554
  span([Class(indexClass)], []),
522
555
  span([Class('text-base text-dt-muted font-mono')], ['Init']),
@@ -536,11 +569,11 @@ const makeView = (position, mode, maybeMessage) => {
536
569
  D('M5.75 3v18M18.25 3v18'),
537
570
  ], []),
538
571
  ]);
539
- const messageRowView = (tag, absoluteIndex, isSelected, isPausedHere, timeDelta, isModelChanged) => div([
572
+ const messageRowView = (tag, absoluteIndex, isSelected, isPausedHere, timeDelta, isModelChanged) => keyed('li')(String(absoluteIndex), [
540
573
  Class(clsx(ROW_BASE, isSelected && 'selected')),
541
574
  OnClick(ClickedRow({ index: absoluteIndex })),
542
575
  ], [
543
- span([Class('pause-column')], isPausedHere ? [pauseIconView] : []),
576
+ ...OptionExt.when(mode === 'TimeTravel', span([Class('pause-column')], isPausedHere ? [pauseIconView] : [])).pipe(Option.toArray),
544
577
  span([Class('dot-column')], isModelChanged ? [inlineDiffDotView] : []),
545
578
  span([Class(indexClass)], [String(absoluteIndex + 1)]),
546
579
  span([Class('text-base text-dt font-mono flex-1 truncate')], [tag]),
@@ -564,18 +597,18 @@ const makeView = (position, mode, maybeMessage) => {
564
597
  const isPausedHere = model.isPaused && model.pausedAtIndex === absoluteIndex;
565
598
  return messageRowView(entry.tag, absoluteIndex, isSelected, isPausedHere, entry.timestamp - baseTimestamp, entry.isModelChanged);
566
599
  }), Array_.reverse);
567
- return div([Class('message-list flex-1 overflow-y-auto min-h-0')], [
600
+ return ul([Class('message-list flex-1 overflow-y-auto overscroll-contain min-h-0')], [
568
601
  ...messageRows,
569
602
  initRowView(isInitSelected, model.isPaused && model.pausedAtIndex === INIT_INDEX),
570
603
  ]);
571
604
  };
572
605
  // PANEL
573
- const panelView = (model) => div([
606
+ const panelView = (model) => keyed('div')('dt-panel', [
574
607
  Class(clsx('fixed dt-panel dt-panel-wide bg-dt-bg border rounded-lg flex flex-col overflow-hidden font-mono text-dt', PANEL_POSITION_CLASS[position])),
575
608
  ], [
576
- ...pipe(maybeMessage, Option.map(message => div([
577
- Class('px-3 py-1.5 border-b text-sm text-dt-muted font-mono shrink-0 leading-snug'),
578
- ], [message])), Option.toArray),
609
+ ...Option.map(maybeBanner, banner => div([
610
+ Class('px-3 py-2 border-b text-sm text-dt-muted font-mono shrink-0 leading-snug'),
611
+ ], [banner])).pipe(Option.toArray),
579
612
  headerView(model),
580
613
  div([Class('flex flex-1 min-h-0 dt-content')], [
581
614
  div([Class('flex flex-col min-h-0 dt-message-pane')], [messageListView(model)]),
@@ -584,19 +617,20 @@ const makeView = (position, mode, maybeMessage) => {
584
617
  ]);
585
618
  const interactionBlocker = div([Class('dt-interaction-blocker')], []);
586
619
  return (model) => div([], [
587
- ...pipe(OptionExt.when(model.isPaused && mode === 'TimeTravel', interactionBlocker), Option.toArray),
588
- ...pipe(OptionExt.when(model.isOpen, panelView(model)), Option.toArray),
620
+ ...OptionExt.when(model.isPaused && mode === 'TimeTravel', interactionBlocker).pipe(Option.toArray),
621
+ ...OptionExt.when(model.isOpen, panelView(model)).pipe(Option.toArray),
589
622
  badgeView(model),
590
623
  ]);
591
624
  };
592
625
  // CREATE
593
- export const createOverlay = (store, position, mode, maybeMessage) => Effect.gen(function* () {
594
- const existingHost = document.getElementById('foldkit-devtools');
626
+ const DEVTOOLS_HOST_ID = 'foldkit-devtools';
627
+ const createShadowContainer = () => {
628
+ const existingHost = document.getElementById(DEVTOOLS_HOST_ID);
595
629
  if (existingHost) {
596
630
  existingHost.remove();
597
631
  }
598
632
  const host = document.createElement('div');
599
- host.id = 'foldkit-devtools';
633
+ host.id = DEVTOOLS_HOST_ID;
600
634
  document.body.appendChild(host);
601
635
  const shadow = host.attachShadow({ mode: 'open' });
602
636
  const styleElement = document.createElement('style');
@@ -604,10 +638,21 @@ export const createOverlay = (store, position, mode, maybeMessage) => Effect.gen
604
638
  shadow.appendChild(styleElement);
605
639
  const container = document.createElement('div');
606
640
  shadow.appendChild(container);
607
- const currentState = yield* SubscriptionRef.get(store.stateRef);
608
- const init = () => [
641
+ return { container, shadow };
642
+ };
643
+ export const createOverlay = (store, position, mode, maybeBanner) => Effect.gen(function* () {
644
+ const { container, shadow } = createShadowContainer();
645
+ const flags = Effect.gen(function* () {
646
+ const storeState = yield* SubscriptionRef.get(store.stateRef);
647
+ return {
648
+ isMobile: window.matchMedia(MOBILE_BREAKPOINT_QUERY).matches,
649
+ ...toDisplayState(storeState),
650
+ };
651
+ });
652
+ const init = (flags) => [
609
653
  {
610
654
  isOpen: false,
655
+ ...flags,
611
656
  maybeSelectedIndex: Option.none(),
612
657
  maybeInspectedModel: Option.none(),
613
658
  maybeInspectedMessage: Option.none(),
@@ -615,15 +660,16 @@ export const createOverlay = (store, position, mode, maybeMessage) => Effect.gen
615
660
  changedPaths: HashSet.empty(),
616
661
  affectedPaths: HashSet.empty(),
617
662
  inspectorTabs: Tabs.init({ id: INSPECTOR_TABS_ID }),
618
- ...toDisplayState(currentState),
619
663
  },
620
664
  [],
621
665
  ];
622
666
  const overlayRuntime = makeElement({
623
667
  Model,
668
+ Flags,
669
+ flags,
624
670
  init,
625
671
  update: makeUpdate(store, shadow, mode),
626
- view: makeView(position, mode, maybeMessage),
672
+ view: makeView(position, mode, maybeBanner),
627
673
  container,
628
674
  subscriptions: makeOverlaySubscriptions(store),
629
675
  devtools: { show: 'Never' },
@@ -1 +1 @@
1
- {"version":3,"file":"store.d.ts","sourceRoot":"","sources":["../../src/devtools/store.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,eAAe,EAAQ,MAAM,QAAQ,CAAA;AAE9E,eAAO,MAAM,UAAU,KAAK,CAAA;AAI5B,MAAM,MAAM,YAAY,GAAG,QAAQ,CAAC;IAClC,GAAG,EAAE,MAAM,CAAA;IACX,OAAO,EAAE,OAAO,CAAA;IAChB,YAAY,EAAE,MAAM,CAAA;IACpB,SAAS,EAAE,MAAM,CAAA;IACjB,cAAc,EAAE,OAAO,CAAA;CACxB,CAAC,CAAA;AAEF,MAAM,MAAM,UAAU,GAAG,QAAQ,CAAC;IAChC,OAAO,EAAE,aAAa,CAAC,YAAY,CAAC,CAAA;IACpC,SAAS,EAAE,OAAO,CAAC,OAAO,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IAC3C,cAAc,EAAE,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAA;IACt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ACd,mBAAgC,KAC/B,MAAM,CAAC,MAAM,CAAC,aAAa,CA2J1B,CAAA;AAEJ,MAAM,MAAM,aAAa,GAAG,QAAQ,CAAC;IACnC,UAAU,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAA;IACnD,aAAa,EAAE,CACb,OAAO,EAAE,QAAQ,CAAC;QAAE,IAAI,EAAE,MAAM,CAAA;KAAE,CAAC,EACnC,gBAAgB,EAAE,OAAO,EACzB,YAAY,EAAE,MAAM,EACpB,cAAc,EAAE,OAAO,KACpB,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAA;IACxB,eAAe,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAA;IAC1D,iBAAiB,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAA;IAC3E,MAAM,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAA;IAC9C,MAAM,EAAE,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAA;IAC3B,KAAK,EAAE,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAA;IAC1B,QAAQ,EAAE,eAAe,CAAC,eAAe,CAAC,UAAU,CAAC,CAAA;CACtD,CAAC,CAAA"}
@@ -80,7 +80,14 @@ export const createDevtoolsStore = (bridge, maxEntries = DEFAULT_MAX_ENTRIES) =>
80
80
  isPaused: false,
81
81
  }));
82
82
  });
83
- const clear = SubscriptionRef.set(stateRef, emptyState);
83
+ const clear = SubscriptionRef.update(stateRef, state => ({
84
+ ...emptyState,
85
+ maybeInitModel: state.maybeInitModel,
86
+ keyframes: Option.match(state.maybeInitModel, {
87
+ onNone: () => HashMap.empty(),
88
+ onSome: model => HashMap.set(HashMap.empty(), 0, model),
89
+ }),
90
+ }));
84
91
  return {
85
92
  recordInit,
86
93
  recordMessage,
@@ -21,13 +21,13 @@ export type DevtoolsMode = 'Inspect' | 'TimeTravel';
21
21
  * - `show`: `'Never'` disables devtools entirely, `'Development'` (default) enables in dev mode only, `'Always'` enables in all environments including production.
22
22
  * - `position`: Where the badge and panel appear. Defaults to `'BottomRight'`.
23
23
  * - `mode`: `'TimeTravel'` (default) enables full time-travel debugging. `'Inspect'` allows browsing state snapshots without pausing the app.
24
- * - `message`: Optional text shown as a banner at the top of the panel.
24
+ * - `banner`: Optional text shown as a banner at the top of the panel.
25
25
  */
26
26
  export type DevtoolsConfig = Readonly<{
27
27
  show?: DevtoolsShow;
28
28
  position?: DevtoolsPosition;
29
29
  mode?: DevtoolsMode;
30
- message?: string;
30
+ banner?: string;
31
31
  }>;
32
32
  declare const Dispatch_base: Context.TagClass<Dispatch, "@foldkit/Dispatch", {
33
33
  readonly dispatchAsync: (message: unknown) => Effect.Effect<void>;
@@ -1 +1 @@
1
- {"version":3,"file":"runtime.d.ts","sourceRoot":"","sources":["../../src/runtime/runtime.ts"],"names":[],"mappings":"AACA,OAAO,EAGL,OAAO,EACP,MAAM,EAGN,KAAK,EAQL,MAAM,EAKP,MAAM,QAAQ,CAAA;AAGf,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAA;AAGzC,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAA;AAC9B,OAAO,EAAE,GAAG,EAA+B,MAAM,QAAQ,CAAA;AAOzD,OAAO,KAAK,EAAyB,gBAAgB,EAAE,MAAM,mBAAmB,CAAA;AAChF,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAA;AACnD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAIzC,0DAA0D;AAC1D,MAAM,MAAM,gBAAgB,GACxB,aAAa,GACb,YAAY,GACZ,UAAU,GACV,SAAS,CAAA;AAEb,wCAAwC;AACxC,MAAM,MAAM,Y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CAAC,MAAM,CAAC,MAAM,CAAC,EACzD,KAAK,EACL,SAAS,GAAG,KAAK,EACjB,uBAAuB,GAAG,KAAK,EAE/B,MAAM,EAAE,0BAA0B,CAChC,KAAK,EACL,OAAO,EACP,aAAa,EACb,KAAK,EACL,SAAS,EACT,uBAAuB,CACxB,GACA,iBAAiB,CAAA;AAEpB,wBAAgB,eAAe,CAC7B,KAAK,EACL,OAAO,SAAS;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,EAChC,aAAa,SAAS,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,EACzD,SAAS,GAAG,KAAK,EACjB,uBAAuB,GAAG,KAAK,EAE/B,MAAM,EAAE,6BAA6B,CACnC,KAAK,EACL,OAAO,EACP,aAAa,EACb,SAAS,EACT,uBAAuB,CACxB,GACA,iBAAiB,CAAA;AA0FpB,kEAAkE;AAClE,eAAO,MAAM,GAAG,GAAI,gBAAgB,iBAAiB,KAAG,IAUvD,CAAA"}
@@ -138,7 +138,7 @@ const makeRuntime = ({ Model, Flags: _Flags, flags: flags_, init, update, view,
138
138
  const show = devtools?.show ?? DEFAULT_DEVTOOLS_SHOW;
139
139
  const devtoolsPosition = devtools?.position ?? DEFAULT_DEVTOOLS_POSITION;
140
140
  const devtoolsMode = devtools?.mode ?? DEFAULT_DEVTOOLS_MODE;
141
- const maybeDevtoolsMessage = Option.fromNullable(devtools?.message);
141
+ const maybeDevtoolsBanner = Option.fromNullable(devtools?.banner);
142
142
  const isInIframe = window.self !== window.top;
143
143
  const isDevtoolsEnabled = Match.value(show).pipe(Match.when('Never', () => false), Match.when('Always', () => true), Match.when('Development', () => !!import.meta.hot && !isInIframe), Match.exhaustive);
144
144
  if (isDevtoolsEnabled) {
@@ -153,7 +153,7 @@ const makeRuntime = ({ Model, Flags: _Flags, flags: flags_, init, update, view,
153
153
  });
154
154
  yield* Ref.set(maybeDevtoolsStoreRef, Option.some(devtoolsStore));
155
155
  yield* devtoolsStore.recordInit(initModel);
156
- yield* createOverlay(devtoolsStore, devtoolsPosition, devtoolsMode, maybeDevtoolsMessage);
156
+ yield* createOverlay(devtoolsStore, devtoolsPosition, devtoolsMode, maybeDevtoolsBanner);
157
157
  }
158
158
  yield* render(initModel);
159
159
  addBfcacheRestoreListener();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "foldkit",
3
- "version": "0.33.0",
3
+ "version": "0.33.1",
4
4
  "description": "Elm-inspired UI framework powered by Effect",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",