foldkit 0.31.0 → 0.33.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -9
- package/dist/devtools/overlay-styles.d.ts +3 -0
- package/dist/devtools/overlay-styles.d.ts.map +1 -0
- package/dist/devtools/overlay-styles.js +514 -0
- package/dist/devtools/overlay.d.ts +5 -0
- package/dist/devtools/overlay.d.ts.map +1 -0
- package/dist/devtools/overlay.js +632 -0
- package/dist/devtools/store.d.ts +36 -0
- package/dist/devtools/store.d.ts.map +1 -0
- package/dist/devtools/store.js +94 -0
- package/dist/html/index.d.ts +1 -1
- package/dist/html/index.d.ts.map +1 -1
- package/dist/runtime/runtime.d.ts +26 -0
- package/dist/runtime/runtime.d.ts.map +1 -1
- package/dist/runtime/runtime.js +48 -3
- package/dist/ui/combobox/multi.d.ts +2 -2
- package/dist/ui/combobox/shared.d.ts +2 -2
- package/dist/ui/combobox/single.d.ts +2 -2
- package/dist/ui/dialog/index.d.ts.map +1 -1
- package/dist/ui/dialog/index.js +12 -4
- package/dist/ui/listbox/multi.d.ts +5 -5
- package/dist/ui/listbox/shared.d.ts +2 -2
- package/dist/ui/listbox/single.d.ts +5 -5
- package/package.json +5 -4
package/README.md
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
<a href="https://www.npmjs.com/package/foldkit"><img src="https://img.shields.io/npm/v/foldkit" alt="npm version"></a>
|
|
11
11
|
</p>
|
|
12
12
|
|
|
13
|
-
<h3 align="center">
|
|
13
|
+
<h3 align="center">The frontend framework for correctness.</h3>
|
|
14
14
|
|
|
15
15
|
<p align="center">
|
|
16
16
|
<a href="https://foldkit.dev"><strong>Documentation</strong></a> · <a href="https://github.com/devinjameson/foldkit#examples"><strong>Examples</strong></a> · <a href="https://foldkit.dev/getting-started"><strong>Getting Started</strong></a>
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
|
|
21
21
|
Foldkit is an [Elm Architecture](https://guide.elm-lang.org/architecture/) framework for TypeScript, powered by [Effect](https://effect.website/). One Model, one update function, one way to do things. No hooks, no local state, no hidden mutations.
|
|
22
22
|
|
|
23
|
-
> [!
|
|
24
|
-
> Foldkit is pre-1.0.
|
|
23
|
+
> [!NOTE]
|
|
24
|
+
> Foldkit is pre-1.0. The core API is stable, but breaking changes may occur in minor releases. See the [changelog](./CHANGELOG.md) for details.
|
|
25
25
|
|
|
26
26
|
## Who It's For
|
|
27
27
|
|
|
@@ -153,17 +153,17 @@ This is what makes Foldkit unusually AI-friendly. The same property that makes t
|
|
|
153
153
|
## Examples
|
|
154
154
|
|
|
155
155
|
- **[Counter](https://github.com/devinjameson/foldkit/blob/main/examples/counter/src/main.ts)** — Increment/decrement with reset
|
|
156
|
-
- **[Stopwatch](https://github.com/devinjameson/foldkit/blob/main/examples/stopwatch/src/main.ts)** — Timer with start/stop/reset
|
|
157
|
-
- **[Weather](https://github.com/devinjameson/foldkit/blob/main/examples/weather/src/main.ts)** — HTTP requests with async state handling
|
|
158
156
|
- **[Todo](https://github.com/devinjameson/foldkit/blob/main/examples/todo/src/main.ts)** — CRUD operations with localStorage persistence
|
|
157
|
+
- **[Stopwatch](https://github.com/devinjameson/foldkit/blob/main/examples/stopwatch/src/main.ts)** — Timer with start/stop/reset
|
|
158
|
+
- **[Error View](https://github.com/devinjameson/foldkit/blob/main/examples/error-view/src/main.ts)** — Custom error fallback UI
|
|
159
159
|
- **[Form](https://github.com/devinjameson/foldkit/blob/main/examples/form/src/main.ts)** — Form validation with async email checking
|
|
160
|
+
- **[Weather](https://github.com/devinjameson/foldkit/blob/main/examples/weather/src/main.ts)** — HTTP requests with async state handling
|
|
160
161
|
- **[Routing](https://github.com/devinjameson/foldkit/blob/main/examples/routing/src/main.ts)** — URL routing with parser combinators
|
|
161
|
-
- **[
|
|
162
|
+
- **[Query Sync](https://github.com/devinjameson/foldkit/blob/main/examples/query-sync/src/main.ts)** — URL query parameter sync with filtering and sorting
|
|
162
163
|
- **[Snake](https://github.com/devinjameson/foldkit/blob/main/examples/snake/src/main.ts)** — Classic game built with Subscriptions
|
|
163
|
-
- **[WebSocket Chat](https://github.com/devinjameson/foldkit/blob/main/examples/websocket-chat/src/main.ts)** — Managed Resources with WebSocket integration
|
|
164
164
|
- **[Auth](https://github.com/devinjameson/foldkit/blob/main/examples/auth/src/main.ts)** — Authentication flow with Submodels and OutMessage
|
|
165
|
-
- **[
|
|
166
|
-
- **[
|
|
165
|
+
- **[Shopping Cart](https://github.com/devinjameson/foldkit/blob/main/examples/shopping-cart/src/main.ts)** — Nested models and complex state
|
|
166
|
+
- **[WebSocket Chat](https://github.com/devinjameson/foldkit/blob/main/examples/websocket-chat/src/main.ts)** — Managed Resources with WebSocket integration
|
|
167
167
|
- **[Typing Game](https://github.com/devinjameson/foldkit/tree/main/packages/typing-game)** — Multiplayer typing game with Effect RPC backend
|
|
168
168
|
|
|
169
169
|
## License
|
|
@@ -0,0 +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";
|
|
2
|
+
export { overlayStyles };
|
|
3
|
+
//# sourceMappingURL=overlay-styles.d.ts.map
|
|
@@ -0,0 +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"}
|
|
@@ -0,0 +1,514 @@
|
|
|
1
|
+
const overlayStyles = `:host {
|
|
2
|
+
--dt-bg: #1e1e2e;
|
|
3
|
+
--dt-surface-selected: #282839;
|
|
4
|
+
--dt-border: #585b70;
|
|
5
|
+
--dt-text: #cdd6f4;
|
|
6
|
+
--dt-text-muted: #9399b2;
|
|
7
|
+
--dt-accent: #cba6f7;
|
|
8
|
+
--dt-live: #a6e3a1;
|
|
9
|
+
--dt-paused: #fab387;
|
|
10
|
+
--dt-json-string: #a6e3a1;
|
|
11
|
+
--dt-json-number: #89b4fa;
|
|
12
|
+
--dt-json-boolean: #fab387;
|
|
13
|
+
--dt-json-null: #9399b2;
|
|
14
|
+
--dt-json-key: #89dceb;
|
|
15
|
+
--dt-json-tag: #cba6f7;
|
|
16
|
+
--dt-json-preview: #9399b2;
|
|
17
|
+
--dt-json-arrow: #9399b2;
|
|
18
|
+
--dt-tree-hover: #313244;
|
|
19
|
+
--dt-diff-changed: #74c7ec;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
*,
|
|
23
|
+
*::before,
|
|
24
|
+
*::after {
|
|
25
|
+
box-sizing: border-box;
|
|
26
|
+
margin: 0;
|
|
27
|
+
padding: 0;
|
|
28
|
+
}
|
|
29
|
+
button {
|
|
30
|
+
font: inherit;
|
|
31
|
+
color: inherit;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.fixed {
|
|
35
|
+
position: fixed;
|
|
36
|
+
}
|
|
37
|
+
.flex {
|
|
38
|
+
display: flex;
|
|
39
|
+
}
|
|
40
|
+
.flex-col {
|
|
41
|
+
flex-direction: column;
|
|
42
|
+
}
|
|
43
|
+
.flex-1 {
|
|
44
|
+
flex: 1 1 0%;
|
|
45
|
+
}
|
|
46
|
+
.items-center {
|
|
47
|
+
align-items: center;
|
|
48
|
+
}
|
|
49
|
+
.justify-center {
|
|
50
|
+
justify-content: center;
|
|
51
|
+
}
|
|
52
|
+
.justify-between {
|
|
53
|
+
justify-content: space-between;
|
|
54
|
+
}
|
|
55
|
+
.shrink-0 {
|
|
56
|
+
flex-shrink: 0;
|
|
57
|
+
}
|
|
58
|
+
.inline-block {
|
|
59
|
+
display: inline-block;
|
|
60
|
+
}
|
|
61
|
+
.gap-0\\.5 {
|
|
62
|
+
gap: 2px;
|
|
63
|
+
}
|
|
64
|
+
.gap-1\\.5 {
|
|
65
|
+
gap: 6px;
|
|
66
|
+
}
|
|
67
|
+
.gap-2 {
|
|
68
|
+
gap: 8px;
|
|
69
|
+
}
|
|
70
|
+
.gap-px {
|
|
71
|
+
gap: 1px;
|
|
72
|
+
}
|
|
73
|
+
.px-1 {
|
|
74
|
+
padding-left: 4px;
|
|
75
|
+
padding-right: 4px;
|
|
76
|
+
}
|
|
77
|
+
.px-2 {
|
|
78
|
+
padding-left: 8px;
|
|
79
|
+
padding-right: 8px;
|
|
80
|
+
}
|
|
81
|
+
.px-2\\.5 {
|
|
82
|
+
padding-left: 10px;
|
|
83
|
+
padding-right: 10px;
|
|
84
|
+
}
|
|
85
|
+
.px-3 {
|
|
86
|
+
padding-left: 12px;
|
|
87
|
+
padding-right: 12px;
|
|
88
|
+
}
|
|
89
|
+
.py-0\\.5 {
|
|
90
|
+
padding-top: 2px;
|
|
91
|
+
padding-bottom: 2px;
|
|
92
|
+
}
|
|
93
|
+
.pt-1 {
|
|
94
|
+
padding-top: 4px;
|
|
95
|
+
}
|
|
96
|
+
.pl-1 {
|
|
97
|
+
padding-left: 4px;
|
|
98
|
+
}
|
|
99
|
+
.py-1 {
|
|
100
|
+
padding-top: 4px;
|
|
101
|
+
padding-bottom: 4px;
|
|
102
|
+
}
|
|
103
|
+
.py-1\\.5 {
|
|
104
|
+
padding-top: 6px;
|
|
105
|
+
padding-bottom: 6px;
|
|
106
|
+
}
|
|
107
|
+
.py-2 {
|
|
108
|
+
padding-top: 8px;
|
|
109
|
+
padding-bottom: 8px;
|
|
110
|
+
}
|
|
111
|
+
.py-px {
|
|
112
|
+
padding-top: 1px;
|
|
113
|
+
padding-bottom: 1px;
|
|
114
|
+
}
|
|
115
|
+
.w-1\\.5 {
|
|
116
|
+
width: 6px;
|
|
117
|
+
}
|
|
118
|
+
.h-1\\.5 {
|
|
119
|
+
height: 6px;
|
|
120
|
+
}
|
|
121
|
+
.w-3 {
|
|
122
|
+
width: 12px;
|
|
123
|
+
}
|
|
124
|
+
.w-5 {
|
|
125
|
+
width: 20px;
|
|
126
|
+
}
|
|
127
|
+
.h-5 {
|
|
128
|
+
height: 20px;
|
|
129
|
+
}
|
|
130
|
+
.w-14 {
|
|
131
|
+
width: 56px;
|
|
132
|
+
}
|
|
133
|
+
.h-14 {
|
|
134
|
+
height: 56px;
|
|
135
|
+
}
|
|
136
|
+
.min-w-0 {
|
|
137
|
+
min-width: 0;
|
|
138
|
+
}
|
|
139
|
+
.min-w-5 {
|
|
140
|
+
min-width: 20px;
|
|
141
|
+
}
|
|
142
|
+
.min-h-0 {
|
|
143
|
+
min-height: 0;
|
|
144
|
+
}
|
|
145
|
+
/* Badge positions — flush against side edge */
|
|
146
|
+
.dt-pos-br {
|
|
147
|
+
bottom: 16px;
|
|
148
|
+
right: 0;
|
|
149
|
+
border-radius: 6px 0 0 6px;
|
|
150
|
+
}
|
|
151
|
+
.dt-pos-bl {
|
|
152
|
+
bottom: 16px;
|
|
153
|
+
left: 0;
|
|
154
|
+
border-radius: 0 6px 6px 0;
|
|
155
|
+
}
|
|
156
|
+
.dt-pos-tr {
|
|
157
|
+
top: 16px;
|
|
158
|
+
right: 0;
|
|
159
|
+
border-radius: 6px 0 0 6px;
|
|
160
|
+
}
|
|
161
|
+
.dt-pos-tl {
|
|
162
|
+
top: 16px;
|
|
163
|
+
left: 0;
|
|
164
|
+
border-radius: 0 6px 6px 0;
|
|
165
|
+
}
|
|
166
|
+
.overflow-hidden {
|
|
167
|
+
overflow: hidden;
|
|
168
|
+
}
|
|
169
|
+
.overflow-auto {
|
|
170
|
+
overflow: auto;
|
|
171
|
+
}
|
|
172
|
+
.overflow-y-auto {
|
|
173
|
+
overflow-y: auto;
|
|
174
|
+
}
|
|
175
|
+
.truncate {
|
|
176
|
+
overflow: hidden;
|
|
177
|
+
text-overflow: ellipsis;
|
|
178
|
+
white-space: nowrap;
|
|
179
|
+
}
|
|
180
|
+
.rounded {
|
|
181
|
+
border-radius: 4px;
|
|
182
|
+
}
|
|
183
|
+
.rounded-lg {
|
|
184
|
+
border-radius: 8px;
|
|
185
|
+
}
|
|
186
|
+
.rounded-full {
|
|
187
|
+
border-radius: 9999px;
|
|
188
|
+
}
|
|
189
|
+
.border {
|
|
190
|
+
border-width: 1px;
|
|
191
|
+
border-style: solid;
|
|
192
|
+
border-color: var(--dt-border);
|
|
193
|
+
}
|
|
194
|
+
.border-b {
|
|
195
|
+
border-bottom: 1px solid var(--dt-border);
|
|
196
|
+
}
|
|
197
|
+
.border-t {
|
|
198
|
+
border-top: 1px solid var(--dt-border);
|
|
199
|
+
}
|
|
200
|
+
.border-r {
|
|
201
|
+
border-right: 1px solid var(--dt-border);
|
|
202
|
+
}
|
|
203
|
+
.border-l {
|
|
204
|
+
border-left: 1px solid var(--dt-border);
|
|
205
|
+
}
|
|
206
|
+
.border-none {
|
|
207
|
+
border: none;
|
|
208
|
+
}
|
|
209
|
+
.border-l-3 {
|
|
210
|
+
border-left: 3px solid transparent;
|
|
211
|
+
}
|
|
212
|
+
.border-dt-live {
|
|
213
|
+
border-color: var(--dt-live);
|
|
214
|
+
}
|
|
215
|
+
.selected {
|
|
216
|
+
background-color: var(--dt-surface-selected);
|
|
217
|
+
}
|
|
218
|
+
.dt-row:hover:not(.selected) {
|
|
219
|
+
background-color: var(--dt-tree-hover);
|
|
220
|
+
}
|
|
221
|
+
.dt-header-button:hover {
|
|
222
|
+
color: var(--dt-text);
|
|
223
|
+
}
|
|
224
|
+
.dt-resume-button:hover {
|
|
225
|
+
color: var(--dt-text);
|
|
226
|
+
}
|
|
227
|
+
.dt-tab-button {
|
|
228
|
+
position: relative;
|
|
229
|
+
background: transparent;
|
|
230
|
+
border: none;
|
|
231
|
+
border-right: 1px solid var(--dt-border);
|
|
232
|
+
outline: none;
|
|
233
|
+
flex: 1;
|
|
234
|
+
}
|
|
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);
|
|
246
|
+
}
|
|
247
|
+
.dt-tab-button:not(.dt-tab-active):hover {
|
|
248
|
+
color: var(--dt-text);
|
|
249
|
+
background-color: rgba(49, 50, 68, 0.3);
|
|
250
|
+
}
|
|
251
|
+
.font-sans {
|
|
252
|
+
font-family:
|
|
253
|
+
system-ui,
|
|
254
|
+
-apple-system,
|
|
255
|
+
BlinkMacSystemFont,
|
|
256
|
+
'Segoe UI',
|
|
257
|
+
Roboto,
|
|
258
|
+
sans-serif;
|
|
259
|
+
}
|
|
260
|
+
.font-mono {
|
|
261
|
+
font-family:
|
|
262
|
+
ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;
|
|
263
|
+
}
|
|
264
|
+
.font-medium {
|
|
265
|
+
font-weight: 500;
|
|
266
|
+
}
|
|
267
|
+
.font-semibold {
|
|
268
|
+
font-weight: 600;
|
|
269
|
+
}
|
|
270
|
+
.text-xs {
|
|
271
|
+
font-size: 12px;
|
|
272
|
+
}
|
|
273
|
+
.text-2xs {
|
|
274
|
+
font-size: 10px;
|
|
275
|
+
}
|
|
276
|
+
.text-sm {
|
|
277
|
+
font-size: 11px;
|
|
278
|
+
}
|
|
279
|
+
.text-base {
|
|
280
|
+
font-size: 13px;
|
|
281
|
+
}
|
|
282
|
+
.text-md {
|
|
283
|
+
font-size: 15px;
|
|
284
|
+
}
|
|
285
|
+
.text-lg {
|
|
286
|
+
font-size: 20px;
|
|
287
|
+
}
|
|
288
|
+
.text-xl {
|
|
289
|
+
font-size: 26px;
|
|
290
|
+
}
|
|
291
|
+
.italic {
|
|
292
|
+
font-style: italic;
|
|
293
|
+
}
|
|
294
|
+
.text-right {
|
|
295
|
+
text-align: right;
|
|
296
|
+
}
|
|
297
|
+
.tracking-wide {
|
|
298
|
+
letter-spacing: 0.025em;
|
|
299
|
+
}
|
|
300
|
+
.tracking-wider {
|
|
301
|
+
letter-spacing: 0.05em;
|
|
302
|
+
}
|
|
303
|
+
.leading-snug {
|
|
304
|
+
line-height: 1.35;
|
|
305
|
+
}
|
|
306
|
+
.bg-dt-bg {
|
|
307
|
+
background-color: var(--dt-bg);
|
|
308
|
+
}
|
|
309
|
+
.bg-dt-live {
|
|
310
|
+
background-color: var(--dt-live);
|
|
311
|
+
}
|
|
312
|
+
.bg-transparent {
|
|
313
|
+
background-color: transparent;
|
|
314
|
+
}
|
|
315
|
+
.text-dt {
|
|
316
|
+
color: var(--dt-text);
|
|
317
|
+
}
|
|
318
|
+
.text-dt-muted {
|
|
319
|
+
color: var(--dt-text-muted);
|
|
320
|
+
}
|
|
321
|
+
.text-dt-accent {
|
|
322
|
+
color: var(--dt-accent);
|
|
323
|
+
}
|
|
324
|
+
.text-dt-live {
|
|
325
|
+
color: var(--dt-live);
|
|
326
|
+
}
|
|
327
|
+
.text-dt-paused {
|
|
328
|
+
color: var(--dt-paused);
|
|
329
|
+
}
|
|
330
|
+
.cursor-pointer {
|
|
331
|
+
cursor: pointer;
|
|
332
|
+
}
|
|
333
|
+
.outline-none {
|
|
334
|
+
outline: none;
|
|
335
|
+
}
|
|
336
|
+
.transition-colors {
|
|
337
|
+
transition-property: color, background-color, border-color;
|
|
338
|
+
transition-duration: 100ms;
|
|
339
|
+
transition-timing-function: ease;
|
|
340
|
+
}
|
|
341
|
+
|
|
342
|
+
/* Panel */
|
|
343
|
+
.dt-panel {
|
|
344
|
+
width: 360px;
|
|
345
|
+
height: 480px;
|
|
346
|
+
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
|
|
347
|
+
z-index: 99998;
|
|
348
|
+
}
|
|
349
|
+
/* Panel positions */
|
|
350
|
+
.dt-panel-br {
|
|
351
|
+
bottom: 16px;
|
|
352
|
+
right: 28px;
|
|
353
|
+
}
|
|
354
|
+
.dt-panel-bl {
|
|
355
|
+
bottom: 16px;
|
|
356
|
+
left: 28px;
|
|
357
|
+
}
|
|
358
|
+
.dt-panel-tr {
|
|
359
|
+
top: 16px;
|
|
360
|
+
right: 28px;
|
|
361
|
+
}
|
|
362
|
+
.dt-panel-tl {
|
|
363
|
+
top: 16px;
|
|
364
|
+
left: 28px;
|
|
365
|
+
}
|
|
366
|
+
.dt-panel-wide {
|
|
367
|
+
width: 720px;
|
|
368
|
+
}
|
|
369
|
+
.dt-message-pane {
|
|
370
|
+
width: 320px;
|
|
371
|
+
flex-shrink: 0;
|
|
372
|
+
}
|
|
373
|
+
.dt-badge {
|
|
374
|
+
z-index: 99999;
|
|
375
|
+
box-shadow: -2px 0 8px rgba(0, 0, 0, 0.3);
|
|
376
|
+
transition: background-color 150ms ease;
|
|
377
|
+
}
|
|
378
|
+
.dt-badge-accent {
|
|
379
|
+
border: none;
|
|
380
|
+
}
|
|
381
|
+
.dt-badge-accent:hover {
|
|
382
|
+
background-color: #252538;
|
|
383
|
+
}
|
|
384
|
+
.dt-badge-paused {
|
|
385
|
+
background-color: var(--dt-paused);
|
|
386
|
+
color: var(--dt-bg);
|
|
387
|
+
border: none;
|
|
388
|
+
}
|
|
389
|
+
.dt-badge-paused:hover {
|
|
390
|
+
background-color: #e0a070;
|
|
391
|
+
}
|
|
392
|
+
.message-list > :last-child {
|
|
393
|
+
border-bottom: none;
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
/* JSON tree */
|
|
397
|
+
.tree-row {
|
|
398
|
+
position: relative;
|
|
399
|
+
white-space: nowrap;
|
|
400
|
+
line-height: 1.5;
|
|
401
|
+
padding-right: 8px;
|
|
402
|
+
}
|
|
403
|
+
.tree-row-expandable:hover {
|
|
404
|
+
background-color: var(--dt-tree-hover);
|
|
405
|
+
}
|
|
406
|
+
.inspector-tree {
|
|
407
|
+
font-family:
|
|
408
|
+
ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;
|
|
409
|
+
}
|
|
410
|
+
.json-key {
|
|
411
|
+
color: var(--dt-json-key);
|
|
412
|
+
}
|
|
413
|
+
.json-string {
|
|
414
|
+
color: var(--dt-json-string);
|
|
415
|
+
}
|
|
416
|
+
.json-number {
|
|
417
|
+
color: var(--dt-json-number);
|
|
418
|
+
}
|
|
419
|
+
.json-boolean {
|
|
420
|
+
color: var(--dt-json-boolean);
|
|
421
|
+
}
|
|
422
|
+
.json-null {
|
|
423
|
+
color: var(--dt-json-null);
|
|
424
|
+
}
|
|
425
|
+
.json-tag {
|
|
426
|
+
color: var(--dt-json-tag);
|
|
427
|
+
margin-right: 4px;
|
|
428
|
+
}
|
|
429
|
+
.json-preview {
|
|
430
|
+
color: var(--dt-json-preview);
|
|
431
|
+
}
|
|
432
|
+
.json-arrow {
|
|
433
|
+
color: var(--dt-json-arrow);
|
|
434
|
+
width: 10px;
|
|
435
|
+
height: 10px;
|
|
436
|
+
user-select: none;
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
/* Diff */
|
|
440
|
+
.diff-changed {
|
|
441
|
+
background-color: rgba(116, 199, 236, 0.06);
|
|
442
|
+
}
|
|
443
|
+
.diff-dot {
|
|
444
|
+
position: absolute;
|
|
445
|
+
left: 3px;
|
|
446
|
+
width: 5px;
|
|
447
|
+
height: 5px;
|
|
448
|
+
border-radius: 9999px;
|
|
449
|
+
background-color: var(--dt-diff-changed);
|
|
450
|
+
}
|
|
451
|
+
.diff-dot-inline {
|
|
452
|
+
width: 5px;
|
|
453
|
+
height: 5px;
|
|
454
|
+
border-radius: 9999px;
|
|
455
|
+
background-color: var(--dt-diff-changed);
|
|
456
|
+
flex-shrink: 0;
|
|
457
|
+
}
|
|
458
|
+
.dot-column {
|
|
459
|
+
width: 5px;
|
|
460
|
+
flex-shrink: 0;
|
|
461
|
+
display: flex;
|
|
462
|
+
align-items: center;
|
|
463
|
+
justify-content: center;
|
|
464
|
+
}
|
|
465
|
+
.pause-column {
|
|
466
|
+
width: 8px;
|
|
467
|
+
flex-shrink: 0;
|
|
468
|
+
display: flex;
|
|
469
|
+
align-items: center;
|
|
470
|
+
justify-content: center;
|
|
471
|
+
}
|
|
472
|
+
.dt-pause-icon {
|
|
473
|
+
width: 8px;
|
|
474
|
+
height: 8px;
|
|
475
|
+
color: var(--dt-paused);
|
|
476
|
+
}
|
|
477
|
+
|
|
478
|
+
/* Interaction blocker — covers the app while time-travelling */
|
|
479
|
+
.dt-interaction-blocker {
|
|
480
|
+
position: fixed;
|
|
481
|
+
inset: 0;
|
|
482
|
+
z-index: 99997;
|
|
483
|
+
cursor: not-allowed;
|
|
484
|
+
}
|
|
485
|
+
|
|
486
|
+
/* Mobile */
|
|
487
|
+
@media (max-width: 767px) {
|
|
488
|
+
.dt-panel {
|
|
489
|
+
top: 0;
|
|
490
|
+
left: 0;
|
|
491
|
+
right: 0;
|
|
492
|
+
bottom: 0;
|
|
493
|
+
width: 100%;
|
|
494
|
+
height: 100%;
|
|
495
|
+
border-radius: 0;
|
|
496
|
+
border: none;
|
|
497
|
+
}
|
|
498
|
+
.dt-panel-wide {
|
|
499
|
+
width: 100%;
|
|
500
|
+
}
|
|
501
|
+
.dt-content {
|
|
502
|
+
flex-direction: column;
|
|
503
|
+
}
|
|
504
|
+
.dt-message-pane {
|
|
505
|
+
width: 100%;
|
|
506
|
+
max-height: 40%;
|
|
507
|
+
border-bottom: 1px solid var(--dt-border);
|
|
508
|
+
}
|
|
509
|
+
.dt-inspector-pane {
|
|
510
|
+
border-left: none;
|
|
511
|
+
}
|
|
512
|
+
}
|
|
513
|
+
`;
|
|
514
|
+
export { overlayStyles };
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { Effect, Option } from 'effect';
|
|
2
|
+
import type { DevtoolsMode, DevtoolsPosition } from '../runtime/runtime';
|
|
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>;
|
|
5
|
+
//# sourceMappingURL=overlay.d.ts.map
|
|
@@ -0,0 +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"}
|