@praxisjs/devtools 0.1.1 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +38 -0
- package/dist/index.d.ts +15 -10
- package/dist/index.js +1046 -852
- package/package.json +8 -7
- package/src/decorators/debug.ts +153 -78
- package/src/decorators/trace.ts +15 -11
- package/src/icons/ellipsis-vertical.tsx +25 -19
- package/src/icons/panel-bottom.tsx +24 -18
- package/src/icons/panel-left.tsx +24 -18
- package/src/icons/panel-right.tsx +24 -18
- package/src/icons/panel-top.tsx +24 -18
- package/src/icons/x.tsx +24 -18
- package/src/plugins/components/components/component-detail.tsx +59 -54
- package/src/plugins/components/components/component-row.tsx +36 -33
- package/src/plugins/components/components/detail-row.tsx +21 -18
- package/src/plugins/components/components/detail-section.tsx +14 -12
- package/src/plugins/components/components/status-dot.tsx +20 -11
- package/src/plugins/components/components-tab.tsx +66 -61
- package/src/plugins/signals/components/signal-detail.tsx +35 -27
- package/src/plugins/signals/components/signal-row.tsx +32 -28
- package/src/plugins/signals/signals-tab.tsx +92 -79
- package/src/plugins/timeline/components/badge.tsx +15 -9
- package/src/plugins/timeline/components/timeline-row.tsx +52 -45
- package/src/plugins/timeline/timeline-tab.tsx +90 -77
- package/src/plugins/types.ts +2 -2
- package/src/ui/dev-tools.tsx +45 -39
- package/src/ui/panel.tsx +152 -146
- package/src/ui/shared/empty-state.tsx +17 -11
- package/src/ui/shared/icon-button.tsx +28 -25
- package/src/ui/shared/panel-section.tsx +14 -12
- package/src/ui/shared/search-input.tsx +19 -15
- package/src/ui/shared/side-panel.tsx +16 -13
- package/vite.config.ts +3 -9
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,43 @@
|
|
|
1
1
|
# @praxisjs/devtools
|
|
2
2
|
|
|
3
|
+
## 0.2.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- f52354d: Add `@Computed()` decorator to `@praxisjs/decorators` for declaring read-only reactive getters backed by a cached `computed()` signal. The getter recomputes automatically when any `@State` or `@Prop` dependency changes, and the result is cached until a dependency is invalidated — unlike a plain getter which recalculates on every read.
|
|
8
|
+
|
|
9
|
+
`@Debug()` in `@praxisjs/devtools` now supports `@Computed()` getters (`ClassGetterDecoratorContext`) in addition to fields and methods, allowing computed values to be tracked and historized in the devtools panel.
|
|
10
|
+
|
|
11
|
+
Also fixes a bug in the `computed()` primitive where an erroneous `track(recompute)` call caused premature dependency tracking on signal creation.
|
|
12
|
+
|
|
13
|
+
- Updated dependencies [f52354d]
|
|
14
|
+
- @praxisjs/decorators@0.4.0
|
|
15
|
+
- @praxisjs/core@0.4.0
|
|
16
|
+
- @praxisjs/runtime@0.2.1
|
|
17
|
+
- @praxisjs/jsx@0.2.1
|
|
18
|
+
|
|
19
|
+
## 0.2.0
|
|
20
|
+
|
|
21
|
+
### Minor Changes
|
|
22
|
+
|
|
23
|
+
- bb0d4f8: **Refactor decorator system and component architecture across PraxisJS packages**
|
|
24
|
+
|
|
25
|
+
- Replaced legacy decorator signatures (`constructor`, `target`, `propertyKey`, method descriptor) with the standard TC39 decorator context API (`ClassDecoratorContext`, `ClassFieldDecoratorContext`, `ClassMethodDecoratorContext`) across `@praxisjs/decorators`, `@praxisjs/store`, `@praxisjs/concurrent`, `@praxisjs/router`, `@praxisjs/motion`, `@praxisjs/di`, and `@praxisjs/fsm`.
|
|
26
|
+
- Introduced `StatefulComponent` and `StatelessComponent` as the new base classes, replacing the deprecated `BaseComponent`/`Function Component` pattern, across `@praxisjs/core`, `@praxisjs/runtime`, `@praxisjs/devtools`, and templates.
|
|
27
|
+
- Implemented core rendering functionality in `@praxisjs/runtime` (`mountChildren`, `mountComponent`, reactive scope management) and removed the deprecated `renderer.ts`.
|
|
28
|
+
- Refactored `@praxisjs/jsx` to delegate rendering to `@praxisjs/runtime` and improved type safety with `flattenChildren` and `isComponent` utilities.
|
|
29
|
+
- Updated internal module structure with new `internal` exports in `package.json` files for shared utilities and types.
|
|
30
|
+
- Removed `experimentalDecorators`/`emitDecoratorMetadata` from `tsconfig.json` in favor of native decorator support.
|
|
31
|
+
|
|
32
|
+
### Patch Changes
|
|
33
|
+
|
|
34
|
+
- Updated dependencies [bb0d4f8]
|
|
35
|
+
- @praxisjs/decorators@0.3.0
|
|
36
|
+
- @praxisjs/runtime@0.2.0
|
|
37
|
+
- @praxisjs/core@0.3.0
|
|
38
|
+
- @praxisjs/jsx@0.2.0
|
|
39
|
+
- @praxisjs/shared@0.2.0
|
|
40
|
+
|
|
3
41
|
## 0.1.1
|
|
4
42
|
|
|
5
43
|
### Patch Changes
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ComponentElement } from '@praxisjs/shared';
|
|
2
2
|
|
|
3
3
|
declare type AnyConstructor = new (...args: any[]) => any;
|
|
4
4
|
|
|
@@ -21,15 +21,22 @@ export declare const ComponentsPlugin: DevtoolsPlugin;
|
|
|
21
21
|
* @Debug()
|
|
22
22
|
* @State() count = 0;
|
|
23
23
|
*
|
|
24
|
-
* On
|
|
25
|
-
* @Debug()
|
|
26
|
-
*
|
|
24
|
+
* On @Computed() getters (stacked):
|
|
25
|
+
* @Debug({ label: "doubled" })
|
|
26
|
+
* @Computed()
|
|
27
|
+
* get doubled() { return this.count * 2; }
|
|
27
28
|
*
|
|
28
29
|
* On methods:
|
|
29
30
|
* @Debug()
|
|
30
31
|
* increment() { ... }
|
|
31
32
|
*/
|
|
32
|
-
export declare function Debug(options?: DebugOptions):
|
|
33
|
+
export declare function Debug(options?: DebugOptions): DebugDecorator;
|
|
34
|
+
|
|
35
|
+
declare interface DebugDecorator {
|
|
36
|
+
(value: (...args: unknown[]) => unknown, context: ClassMethodDecoratorContext): (...args: unknown[]) => unknown;
|
|
37
|
+
(value: unknown, context: ClassGetterDecoratorContext): void;
|
|
38
|
+
(value: undefined, context: ClassFieldDecoratorContext): void;
|
|
39
|
+
}
|
|
33
40
|
|
|
34
41
|
export declare interface DebugOptions {
|
|
35
42
|
label?: string;
|
|
@@ -53,9 +60,7 @@ export declare interface DevtoolsPlugin {
|
|
|
53
60
|
id: string;
|
|
54
61
|
label: string;
|
|
55
62
|
setup?: (registry: Registry) => void;
|
|
56
|
-
component:
|
|
57
|
-
registry: Registry;
|
|
58
|
-
}>;
|
|
63
|
+
component: ComponentElement;
|
|
59
64
|
}
|
|
60
65
|
|
|
61
66
|
declare class EventBus {
|
|
@@ -128,8 +133,8 @@ export declare const TimelinePlugin: DevtoolsPlugin;
|
|
|
128
133
|
*
|
|
129
134
|
* @Trace()
|
|
130
135
|
* @Component()
|
|
131
|
-
* class MyComponent extends
|
|
136
|
+
* class MyComponent extends StatefulComponent { ... }
|
|
132
137
|
*/
|
|
133
|
-
export declare function Trace(): <T extends AnyConstructor>(constructor: T) => T;
|
|
138
|
+
export declare function Trace(): <T extends AnyConstructor>(constructor: T, _context: ClassDecoratorContext) => T;
|
|
134
139
|
|
|
135
140
|
export { }
|