@praxisjs/devtools 0.1.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.
Files changed (51) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/LICENSE +21 -0
  3. package/assets/logo.svg +9 -0
  4. package/assets/uno.generated.css +205 -0
  5. package/dist/index.d.ts +135 -0
  6. package/dist/index.js +1051 -0
  7. package/package.json +35 -0
  8. package/src/core/event-bus.ts +19 -0
  9. package/src/core/registry.ts +219 -0
  10. package/src/core/types.ts +45 -0
  11. package/src/decorators/debug.ts +161 -0
  12. package/src/decorators/index.ts +3 -0
  13. package/src/decorators/trace.ts +64 -0
  14. package/src/icons/ellipsis-vertical.tsx +20 -0
  15. package/src/icons/index.ts +6 -0
  16. package/src/icons/panel-bottom.tsx +19 -0
  17. package/src/icons/panel-left.tsx +19 -0
  18. package/src/icons/panel-right.tsx +19 -0
  19. package/src/icons/panel-top.tsx +19 -0
  20. package/src/icons/x.tsx +19 -0
  21. package/src/index.ts +20 -0
  22. package/src/plugins/components/components/component-detail.tsx +70 -0
  23. package/src/plugins/components/components/component-row.tsx +42 -0
  24. package/src/plugins/components/components/detail-row.tsx +22 -0
  25. package/src/plugins/components/components/detail-section.tsx +18 -0
  26. package/src/plugins/components/components/status-dot.tsx +14 -0
  27. package/src/plugins/components/components-tab.tsx +85 -0
  28. package/src/plugins/components/index.ts +9 -0
  29. package/src/plugins/signals/components/signal-detail.tsx +35 -0
  30. package/src/plugins/signals/components/signal-row.tsx +37 -0
  31. package/src/plugins/signals/index.ts +9 -0
  32. package/src/plugins/signals/signals-tab.tsx +99 -0
  33. package/src/plugins/timeline/components/badge.tsx +14 -0
  34. package/src/plugins/timeline/components/timeline-row.tsx +55 -0
  35. package/src/plugins/timeline/constants.ts +24 -0
  36. package/src/plugins/timeline/index.ts +9 -0
  37. package/src/plugins/timeline/timeline-tab.tsx +101 -0
  38. package/src/plugins/types.ts +10 -0
  39. package/src/ui/dev-tools.tsx +121 -0
  40. package/src/ui/panel.tsx +225 -0
  41. package/src/ui/shared/empty-state.tsx +12 -0
  42. package/src/ui/shared/icon-button.tsx +30 -0
  43. package/src/ui/shared/panel-section.tsx +18 -0
  44. package/src/ui/shared/search-input.tsx +18 -0
  45. package/src/ui/shared/side-panel.tsx +18 -0
  46. package/src/utils/format-time.ts +7 -0
  47. package/src/utils/format-value.ts +13 -0
  48. package/src/vite-env.d.ts +6 -0
  49. package/tsconfig.json +21 -0
  50. package/uno.config.ts +57 -0
  51. package/vite.config.ts +42 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,15 @@
1
+ # @praxisjs/devtools
2
+
3
+ ## 0.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - aaf7dab: Initial beta release
8
+
9
+ ### Patch Changes
10
+
11
+ - Updated dependencies [aaf7dab]
12
+ - @praxisjs/core@0.1.0
13
+ - @praxisjs/jsx@0.1.0
14
+ - @praxisjs/runtime@0.1.0
15
+ - @praxisjs/shared@0.1.0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026-present Mateus Martins
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,9 @@
1
+ <svg width="1024" height="1024" viewBox="0 0 1024 1024" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M605.411 445.66L641.322 498.293L641.342 498.278L697.538 578.57L742.673 512.806L512.5 178.878L281.327 512.806L512.5 848.182L603.519 715.561L650.559 782.134L512.701 983L187 510.478L512.701 40L837 510.478L698.206 712.709L668.895 671.104L604.033 578.775L512 712.504L373.199 511.5L512.233 309.092L584.13 414.469L536.746 480.456L513.69 445.66L466.305 511.5L512.166 577.425L556.48 513.91L605.411 445.66Z" fill="url(#paint0_linear_3024_20)"/>
3
+ <defs>
4
+ <linearGradient id="paint0_linear_3024_20" x1="512" y1="40" x2="512" y2="983" gradientUnits="userSpaceOnUse">
5
+ <stop stop-color="#9B76FF" stop-opacity="0.86"/>
6
+ <stop offset="1" stop-color="#2D246B"/>
7
+ </linearGradient>
8
+ </defs>
9
+ </svg>
@@ -0,0 +1,205 @@
1
+ /* layer: preflights */
2
+ *,::before,::after{--un-rotate:0;--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-scale-x:1;--un-scale-y:1;--un-scale-z:1;--un-skew-x:0;--un-skew-y:0;--un-translate-x:0;--un-translate-y:0;--un-translate-z:0;--un-pan-x: ;--un-pan-y: ;--un-pinch-zoom: ;--un-scroll-snap-strictness:proximity;--un-ordinal: ;--un-slashed-zero: ;--un-numeric-figure: ;--un-numeric-spacing: ;--un-numeric-fraction: ;--un-border-spacing-x:0;--un-border-spacing-y:0;--un-ring-offset-shadow:0 0 rgb(0 0 0 / 0);--un-ring-shadow:0 0 rgb(0 0 0 / 0);--un-shadow-inset: ;--un-shadow:0 0 rgb(0 0 0 / 0);--un-ring-inset: ;--un-ring-offset-width:0px;--un-ring-offset-color:#fff;--un-ring-width:0px;--un-ring-color:rgb(147 197 253 / 0.5);--un-blur: ;--un-brightness: ;--un-contrast: ;--un-drop-shadow: ;--un-grayscale: ;--un-hue-rotate: ;--un-invert: ;--un-saturate: ;--un-sepia: ;--un-backdrop-blur: ;--un-backdrop-brightness: ;--un-backdrop-contrast: ;--un-backdrop-grayscale: ;--un-backdrop-hue-rotate: ;--un-backdrop-invert: ;--un-backdrop-opacity: ;--un-backdrop-saturate: ;--un-backdrop-sepia: ;}::backdrop{--un-rotate:0;--un-rotate-x:0;--un-rotate-y:0;--un-rotate-z:0;--un-scale-x:1;--un-scale-y:1;--un-scale-z:1;--un-skew-x:0;--un-skew-y:0;--un-translate-x:0;--un-translate-y:0;--un-translate-z:0;--un-pan-x: ;--un-pan-y: ;--un-pinch-zoom: ;--un-scroll-snap-strictness:proximity;--un-ordinal: ;--un-slashed-zero: ;--un-numeric-figure: ;--un-numeric-spacing: ;--un-numeric-fraction: ;--un-border-spacing-x:0;--un-border-spacing-y:0;--un-ring-offset-shadow:0 0 rgb(0 0 0 / 0);--un-ring-shadow:0 0 rgb(0 0 0 / 0);--un-shadow-inset: ;--un-shadow:0 0 rgb(0 0 0 / 0);--un-ring-inset: ;--un-ring-offset-width:0px;--un-ring-offset-color:#fff;--un-ring-width:0px;--un-ring-color:rgb(147 197 253 / 0.5);--un-blur: ;--un-brightness: ;--un-contrast: ;--un-drop-shadow: ;--un-grayscale: ;--un-hue-rotate: ;--un-invert: ;--un-saturate: ;--un-sepia: ;--un-backdrop-blur: ;--un-backdrop-brightness: ;--un-backdrop-contrast: ;--un-backdrop-grayscale: ;--un-backdrop-hue-rotate: ;--un-backdrop-invert: ;--un-backdrop-opacity: ;--un-backdrop-saturate: ;--un-backdrop-sepia: ;}
3
+
4
+ :host { all: initial; display: block; font-family: Inter, ui-sans-serif, system-ui, -apple-system, sans-serif; }
5
+ * { box-sizing: border-box; }
6
+
7
+ input::placeholder { color: #6f6a8f; }
8
+ input:focus {
9
+ outline: none;
10
+ box-shadow: 0 0 0 2px rgba(155,144,230,0.3);
11
+ }
12
+
13
+ ::-webkit-scrollbar { width: 4px; height: 4px; }
14
+ ::-webkit-scrollbar-track { background: transparent; }
15
+ ::-webkit-scrollbar-thumb {
16
+ background: rgba(155,144,230,0.2);
17
+ border-radius: 2px;
18
+ }
19
+ ::-webkit-scrollbar-thumb:hover {
20
+ background: rgba(155,144,230,0.4);
21
+ }
22
+
23
+ /* layer: shortcuts */
24
+ .container{width:100%;}
25
+ @media (min-width: 640px){
26
+ .container{max-width:640px;}
27
+ }
28
+ @media (min-width: 768px){
29
+ .container{max-width:768px;}
30
+ }
31
+ @media (min-width: 1024px){
32
+ .container{max-width:1024px;}
33
+ }
34
+ @media (min-width: 1280px){
35
+ .container{max-width:1280px;}
36
+ }
37
+ @media (min-width: 1536px){
38
+ .container{max-width:1536px;}
39
+ }
40
+ /* layer: default */
41
+ .absolute{position:absolute;}
42
+ .fixed{position:fixed;}
43
+ .relative{position:relative;}
44
+ .static{position:static;}
45
+ .bottom-0{bottom:0;}
46
+ .bottom-5{bottom:1.25rem;}
47
+ .left-0{left:0;}
48
+ .right-0{right:0;}
49
+ .right-5{right:1.25rem;}
50
+ .top-0{top:0;}
51
+ .top-full{top:100%;}
52
+ .z-\[2147483647\]{z-index:2147483647;}
53
+ .z-10{z-index:10;}
54
+ .grid{display:grid;}
55
+ .grid-cols-\[1\.2fr_0\.8fr_1fr_auto\]{grid-template-columns:1.2fr 0.8fr 1fr auto;}
56
+ .m6{margin:1.5rem;}
57
+ .mx-1{margin-left:0.25rem;margin-right:0.25rem;}
58
+ .mr-\[2px\]{margin-right:2px;}
59
+ .ms{margin-inline-start:1rem;}
60
+ .mt-1{margin-top:0.25rem;}
61
+ .box-border{box-sizing:border-box;}
62
+ .inline-block{display:inline-block;}
63
+ .h-\[13px\]{height:13px;}
64
+ .h-\[22px\]{height:22px;}
65
+ .h-\[2px\]{height:2px;}
66
+ .h-\[32px\]{height:32px;}
67
+ .h-\[6px\]{height:6px;}
68
+ .h-1{height:0.25rem;}
69
+ .h-10{height:2.5rem;}
70
+ .h-3{height:0.75rem;}
71
+ .h-7{height:1.75rem;}
72
+ .h-full{height:100%;}
73
+ .h-screen{height:100vh;}
74
+ .max-w-\[200px\]{max-width:200px;}
75
+ .min-w-0{min-width:0;}
76
+ .w-\[13px\]{width:13px;}
77
+ .w-\[22px\]{width:22px;}
78
+ .w-\[2px\]{width:2px;}
79
+ .w-\[6px\]{width:6px;}
80
+ .w-1{width:0.25rem;}
81
+ .w-10{width:2.5rem;}
82
+ .w-12{width:3rem;}
83
+ .w-4{width:1rem;}
84
+ .w-full{width:100%;}
85
+ .w-px{width:1px;}
86
+ .flex{display:flex;}
87
+ .flex-1{flex:1 1 0%;}
88
+ .shrink-0{flex-shrink:0;}
89
+ .flex-row-reverse{flex-direction:row-reverse;}
90
+ .flex-col{flex-direction:column;}
91
+ .flex-col-reverse{flex-direction:column-reverse;}
92
+ .flex-wrap{flex-wrap:wrap;}
93
+ .cursor-\[ew-resize\]{cursor:ew-resize;}
94
+ .cursor-\[ns-resize\]{cursor:ns-resize;}
95
+ .cursor-default{cursor:default;}
96
+ .cursor-pointer{cursor:pointer;}
97
+ .select-none{-webkit-user-select:none;user-select:none;}
98
+ .items-center{align-items:center;}
99
+ .items-stretch{align-items:stretch;}
100
+ .justify-center{justify-content:center;}
101
+ .justify-between{justify-content:space-between;}
102
+ .gap-\[2px\]{gap:2px;}
103
+ .gap-\[3px\]{gap:3px;}
104
+ .gap-\[6px\]{gap:6px;}
105
+ .gap-1{gap:0.25rem;}
106
+ .gap-2{gap:0.5rem;}
107
+ .gap-3{gap:0.75rem;}
108
+ .overflow-hidden{overflow:hidden;}
109
+ .overflow-y-auto{overflow-y:auto;}
110
+ .truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
111
+ .border{border-width:1px;}
112
+ .border-b{border-bottom-width:1px;}
113
+ .border-l{border-left-width:1px;}
114
+ .border-r{border-right-width:1px;}
115
+ .border-t{border-top-width:1px;}
116
+ .border-border{--un-border-opacity:0.25;border-color:rgba(155, 144, 230, var(--un-border-opacity));}
117
+ .border-warn{--un-border-opacity:1;border-color:rgb(217 119 6 / var(--un-border-opacity));}
118
+ .hover\:border-accent:hover{--un-border-opacity:1;border-color:rgb(155 144 230 / var(--un-border-opacity));}
119
+ .rounded{border-radius:0.25rem;}
120
+ .rounded-full{border-radius:9999px;}
121
+ .rounded-lg{border-radius:0.5rem;}
122
+ .rounded-md{border-radius:0.375rem;}
123
+ .rounded-xl{border-radius:0.75rem;}
124
+ .rounded-r{border-top-right-radius:0.25rem;border-bottom-right-radius:0.25rem;}
125
+ .bg-\[rgba\(124\,109\,214\,0\.14\)\]{--un-bg-opacity:0.14;background-color:rgba(124, 109, 214, var(--un-bg-opacity)) /* rgba(124,109,214,0.14) */;}
126
+ .bg-\[rgba\(14\,165\,122\,0\.14\)\]{--un-bg-opacity:0.14;background-color:rgba(14, 165, 122, var(--un-bg-opacity)) /* rgba(14,165,122,0.14) */;}
127
+ .bg-\[rgba\(155\,144\,230\,0\.14\)\]{--un-bg-opacity:0.14;background-color:rgba(155, 144, 230, var(--un-bg-opacity)) /* rgba(155,144,230,0.14) */;}
128
+ .bg-\[rgba\(217\,119\,6\,0\.14\)\]{--un-bg-opacity:0.14;background-color:rgba(217, 119, 6, var(--un-bg-opacity)) /* rgba(217,119,6,0.14) */;}
129
+ .bg-\[rgba\(220\,38\,38\,0\.14\)\]{--un-bg-opacity:0.14;background-color:rgba(220, 38, 38, var(--un-bg-opacity)) /* rgba(220,38,38,0.14) */;}
130
+ .bg-\[rgba\(74\,222\,128\,0\.12\)\]{--un-bg-opacity:0.12;background-color:rgba(74, 222, 128, var(--un-bg-opacity)) /* rgba(74,222,128,0.12) */;}
131
+ .bg-accent{--un-bg-opacity:1;background-color:rgb(155 144 230 / var(--un-bg-opacity)) /* #9b90e6 */;}
132
+ .bg-bg{--un-bg-opacity:1;background-color:rgb(15 13 23 / var(--un-bg-opacity)) /* #0f0d17 */;}
133
+ .bg-border{--un-bg-opacity:0.25;background-color:rgba(155, 144, 230, var(--un-bg-opacity)) /* rgba(155,144,230,0.25) */;}
134
+ .bg-header{--un-bg-opacity:1;background-color:rgb(22 19 38 / var(--un-bg-opacity)) /* #161326 */;}
135
+ .bg-input,
136
+ .bg-section{--un-bg-opacity:1;background-color:rgb(27 24 48 / var(--un-bg-opacity)) /* #1b1830 */;}
137
+ .bg-selected{--un-bg-opacity:1;background-color:rgb(34 30 61 / var(--un-bg-opacity)) /* #221e3d */;}
138
+ .bg-soft{--un-bg-opacity:0.18;background-color:rgba(155, 144, 230, var(--un-bg-opacity)) /* rgba(155,144,230,0.18) */;}
139
+ .bg-subtle{--un-bg-opacity:1;background-color:rgb(111 106 143 / var(--un-bg-opacity)) /* #6f6a8f */;}
140
+ .bg-success{--un-bg-opacity:1;background-color:rgb(14 165 122 / var(--un-bg-opacity)) /* #0ea57a */;}
141
+ .bg-transparent{background-color:transparent /* transparent */;}
142
+ .hover\:bg-accent:hover{--un-bg-opacity:1;background-color:rgb(155 144 230 / var(--un-bg-opacity)) /* #9b90e6 */;}
143
+ .hover\:bg-section:hover{--un-bg-opacity:1;background-color:rgb(27 24 48 / var(--un-bg-opacity)) /* #1b1830 */;}
144
+ .hover\:bg-soft:hover{--un-bg-opacity:0.18;background-color:rgba(155, 144, 230, var(--un-bg-opacity)) /* rgba(155,144,230,0.18) */;}
145
+ .p-1{padding:0.25rem;}
146
+ .px{padding-left:1rem;padding-right:1rem;}
147
+ .px-\[6px\]{padding-left:6px;padding-right:6px;}
148
+ .px-2{padding-left:0.5rem;padding-right:0.5rem;}
149
+ .px-3{padding-left:0.75rem;padding-right:0.75rem;}
150
+ .py-\[2px\]{padding-top:2px;padding-bottom:2px;}
151
+ .py-\[3px\]{padding-top:3px;padding-bottom:3px;}
152
+ .py-\[4px\]{padding-top:4px;padding-bottom:4px;}
153
+ .py-\[5px\]{padding-top:5px;padding-bottom:5px;}
154
+ .py-12{padding-top:3rem;padding-bottom:3rem;}
155
+ .py-2{padding-top:0.5rem;padding-bottom:0.5rem;}
156
+ .py-6{padding-top:1.5rem;padding-bottom:1.5rem;}
157
+ .pl-\[10px\]{padding-left:10px;}
158
+ .pl-\[56px\]{padding-left:56px;}
159
+ .pl-1{padding-left:0.25rem;}
160
+ .pr-\[14px\]{padding-right:14px;}
161
+ .pr-3{padding-right:0.75rem;}
162
+ .text-center{text-align:center;}
163
+ .text-right{text-align:right;}
164
+ .text-\[10px\]{font-size:10px;}
165
+ .text-\[11px\]{font-size:11px;}
166
+ .text-\[12px\]{font-size:12px;}
167
+ .text-\[20px\]{font-size:20px;}
168
+ .text-\[9px\]{font-size:9px;}
169
+ .text-\[\#0ea57a\]{--un-text-opacity:1;color:rgb(14 165 122 / var(--un-text-opacity)) /* #0ea57a */;}
170
+ .text-\[\#4ade80\]{--un-text-opacity:1;color:rgb(74 222 128 / var(--un-text-opacity)) /* #4ade80 */;}
171
+ .text-\[\#7c6dd6\]{--un-text-opacity:1;color:rgb(124 109 214 / var(--un-text-opacity)) /* #7c6dd6 */;}
172
+ .text-\[\#9b90e6\],
173
+ .text-accent{--un-text-opacity:1;color:rgb(155 144 230 / var(--un-text-opacity)) /* #9b90e6 */;}
174
+ .text-\[\#d97706\],
175
+ .text-warn{--un-text-opacity:1;color:rgb(217 119 6 / var(--un-text-opacity)) /* #d97706 */;}
176
+ .text-\[\#dc2626\]{--un-text-opacity:1;color:rgb(220 38 38 / var(--un-text-opacity)) /* #dc2626 */;}
177
+ .text-muted{--un-text-opacity:1;color:rgb(199 195 230 / var(--un-text-opacity)) /* #c7c3e6 */;}
178
+ .text-subtle{--un-text-opacity:1;color:rgb(111 106 143 / var(--un-text-opacity)) /* #6f6a8f */;}
179
+ .text-text{--un-text-opacity:1;color:rgb(244 242 255 / var(--un-text-opacity)) /* #f4f2ff */;}
180
+ .hover\:text-text:hover{--un-text-opacity:1;color:rgb(244 242 255 / var(--un-text-opacity)) /* #f4f2ff */;}
181
+ .color-white{--un-text-opacity:1;color:rgb(255 255 255 / var(--un-text-opacity)) /* #fff */;}
182
+ .hover\:color-muted:hover{--un-text-opacity:1;color:rgb(199 195 230 / var(--un-text-opacity)) /* #c7c3e6 */;}
183
+ .font-bold{font-weight:700;}
184
+ .font-semibold{font-weight:600;}
185
+ .leading-none{line-height:1;}
186
+ .leading-relaxed{line-height:1.625;}
187
+ .tracking-\[0\.07em\]{letter-spacing:0.07em;}
188
+ .tracking-\[0\.12em\]{letter-spacing:0.12em;}
189
+ .tracking-widest{letter-spacing:0.1em;}
190
+ .font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;}
191
+ .font-sans{font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";}
192
+ .uppercase{text-transform:uppercase;}
193
+ .tabular-nums{--un-numeric-spacing:tabular-nums;font-variant-numeric:var(--un-ordinal) var(--un-slashed-zero) var(--un-numeric-figure) var(--un-numeric-spacing) var(--un-numeric-fraction);}
194
+ .shadow{--un-shadow:var(--un-shadow-inset) 0 1px 3px 0 var(--un-shadow-color, rgb(0 0 0 / 0.1)),var(--un-shadow-inset) 0 1px 2px -1px var(--un-shadow-color, rgb(0 0 0 / 0.1));box-shadow:var(--un-ring-offset-shadow), var(--un-ring-shadow), var(--un-shadow);}
195
+ .shadow-\[0_8px_32px_rgba\(0\,0\,0\,0\.7\)\]{--un-shadow:0 8px 32px var(--un-shadow-color, rgba(0, 0, 0, 0.7));box-shadow:var(--un-ring-offset-shadow), var(--un-ring-shadow), var(--un-shadow);}
196
+ .shadow-lg{--un-shadow:var(--un-shadow-inset) 0 10px 15px -3px var(--un-shadow-color, rgb(0 0 0 / 0.1)),var(--un-shadow-inset) 0 4px 6px -4px var(--un-shadow-color, rgb(0 0 0 / 0.1));box-shadow:var(--un-ring-offset-shadow), var(--un-ring-shadow), var(--un-shadow);}
197
+ .hover\:shadow-\[0_8px_32px_rgba\(56\,189\,248\,0\.1\)\]:hover{--un-shadow:0 8px 32px var(--un-shadow-color, rgba(56, 189, 248, 0.1));box-shadow:var(--un-ring-offset-shadow), var(--un-ring-shadow), var(--un-shadow);}
198
+ .outline-none{outline:2px solid transparent;outline-offset:2px;}
199
+ .filter{filter:var(--un-blur) var(--un-brightness) var(--un-contrast) var(--un-drop-shadow) var(--un-grayscale) var(--un-hue-rotate) var(--un-invert) var(--un-saturate) var(--un-sepia);}
200
+ .transition-all{transition-property:all;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-duration:150ms;}
201
+ .transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-duration:150ms;}
202
+ .transition-shadow{transition-property:box-shadow;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-duration:150ms;}
203
+ .duration-100{transition-duration:100ms;}
204
+ .duration-150{transition-duration:150ms;}
205
+ .duration-200{transition-duration:200ms;}
@@ -0,0 +1,135 @@
1
+ import { FunctionComponent } from '@praxisjs/shared';
2
+
3
+ declare type AnyConstructor = new (...args: any[]) => any;
4
+
5
+ export declare interface ComponentEntry {
6
+ id: string;
7
+ name: string;
8
+ renderCount: number;
9
+ lastRenderDuration: number;
10
+ mountedAt: number;
11
+ status: 'mounted' | 'unmounted';
12
+ lifecycle: LifecycleEvent[];
13
+ }
14
+
15
+ export declare const ComponentsPlugin: DevtoolsPlugin;
16
+
17
+ /**
18
+ * Tracks state, computed values, and methods in the devtools panel.
19
+ *
20
+ * On @State() properties (stacked):
21
+ * @Debug()
22
+ * @State() count = 0;
23
+ *
24
+ * On computed class fields:
25
+ * @Debug()
26
+ * doubled = computed(() => this.count * 2);
27
+ *
28
+ * On methods:
29
+ * @Debug()
30
+ * increment() { ... }
31
+ */
32
+ export declare function Debug(options?: DebugOptions): (target: object, key: string, descriptor?: PropertyDescriptor) => void;
33
+
34
+ export declare interface DebugOptions {
35
+ label?: string;
36
+ }
37
+
38
+ export declare const DevTools: {
39
+ plugins: DevtoolsPlugin[];
40
+ host: HTMLElement | null;
41
+ cleanup: (() => void) | null;
42
+ init(options?: DevToolsOptions): void;
43
+ registerPlugin(plugin: DevtoolsPlugin): void;
44
+ readonly registry: Registry;
45
+ remount(): void;
46
+ };
47
+
48
+ export declare interface DevToolsOptions {
49
+ plugins?: DevtoolsPlugin[];
50
+ }
51
+
52
+ export declare interface DevtoolsPlugin {
53
+ id: string;
54
+ label: string;
55
+ setup?: (registry: Registry) => void;
56
+ component: FunctionComponent<{
57
+ registry: Registry;
58
+ }>;
59
+ }
60
+
61
+ declare class EventBus {
62
+ private readonly handlers;
63
+ on<T = unknown>(event: string, handler: Handler<T>): () => void;
64
+ emit(event: string, payload: unknown): void;
65
+ }
66
+
67
+ declare type Handler<T = unknown> = (payload: T) => void;
68
+
69
+ export declare interface HistoryEntry {
70
+ value: unknown;
71
+ timestamp: number;
72
+ }
73
+
74
+ export declare interface LifecycleEvent {
75
+ hook: string;
76
+ timestamp: number;
77
+ }
78
+
79
+ export declare class Registry {
80
+ private static _instance;
81
+ static get instance(): Registry;
82
+ readonly bus: EventBus;
83
+ private readonly instanceIds;
84
+ private readonly signals;
85
+ private readonly components;
86
+ private readonly timeline;
87
+ private getInstanceId;
88
+ registerSignal(instance: object, key: string, value: unknown, componentName: string): void;
89
+ updateSignal(instance: object, key: string, newValue: unknown, oldValue: unknown): void;
90
+ registerComponent(instance: object, name: string): void;
91
+ recordRender(instance: object, duration: number): void;
92
+ recordLifecycle(instance: object, hook: string): void;
93
+ recordMethodCall(instance: object, method: string, args: unknown[], result: unknown, duration: number, componentName: string): void;
94
+ getSignals(): SignalEntry[];
95
+ getComponents(): ComponentEntry[];
96
+ getTimeline(): TimelineEntry[];
97
+ getSignalsByComponent(componentId: string): SignalEntry[];
98
+ private pushTimeline;
99
+ }
100
+
101
+ export declare interface SignalEntry {
102
+ id: string;
103
+ label: string;
104
+ componentId: string;
105
+ componentName: string;
106
+ value: unknown;
107
+ history: HistoryEntry[];
108
+ changedAt: number;
109
+ }
110
+
111
+ export declare const SignalsPlugin: DevtoolsPlugin;
112
+
113
+ export declare interface TimelineEntry {
114
+ id: string;
115
+ type: TimelineEventType;
116
+ label: string;
117
+ timestamp: number;
118
+ data: Record<string, unknown>;
119
+ }
120
+
121
+ export declare type TimelineEventType = 'signal:change' | 'component:render' | 'component:mount' | 'component:unmount' | 'lifecycle' | 'method:call';
122
+
123
+ export declare const TimelinePlugin: DevtoolsPlugin;
124
+
125
+ /**
126
+ * Instruments a component class to report renders and lifecycle events
127
+ * to the devtools panel.
128
+ *
129
+ * @Trace()
130
+ * @Component()
131
+ * class MyComponent extends BaseComponent { ... }
132
+ */
133
+ export declare function Trace(): <T extends AnyConstructor>(constructor: T) => T;
134
+
135
+ export { }