@tanstack/solid-pacer-devtools 0.2.0 → 0.3.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/dist/esm/SolidPacerDevtools.d.ts +2 -1
- package/dist/esm/SolidPacerDevtools.js +2 -2
- package/dist/esm/SolidPacerDevtools.js.map +1 -1
- package/dist/esm/index.d.ts +1 -0
- package/dist/esm/index.js +3 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/plugin-prod.d.ts +4 -0
- package/dist/esm/plugin-prod.js +16 -0
- package/dist/esm/plugin-prod.js.map +1 -0
- package/dist/esm/plugin.d.ts +4 -0
- package/dist/esm/plugin.js +16 -0
- package/dist/esm/plugin.js.map +1 -0
- package/dist/esm/production.d.ts +2 -1
- package/dist/esm/production.js +3 -1
- package/dist/esm/production.js.map +1 -1
- package/package.json +2 -2
- package/src/SolidPacerDevtools.tsx +5 -3
- package/src/index.ts +2 -0
- package/src/plugin-prod.tsx +10 -0
- package/src/plugin.tsx +10 -0
- package/src/production.ts +2 -0
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
export interface PacerDevtoolsSolidInit {
|
|
2
|
+
theme?: 'light' | 'dark';
|
|
2
3
|
}
|
|
3
|
-
export declare const PacerDevtoolsPanel: (
|
|
4
|
+
export declare const PacerDevtoolsPanel: (props?: PacerDevtoolsSolidInit) => import("solid-js").JSX.Element;
|
|
@@ -2,12 +2,12 @@ import { template, use } from "solid-js/web";
|
|
|
2
2
|
import { PacerDevtoolsCore } from "@tanstack/pacer-devtools";
|
|
3
3
|
import { createSignal, onMount, onCleanup } from "solid-js";
|
|
4
4
|
var _tmpl$ = /* @__PURE__ */ template(`<div>`);
|
|
5
|
-
const PacerDevtoolsPanel = (
|
|
5
|
+
const PacerDevtoolsPanel = (props) => {
|
|
6
6
|
let devToolRef;
|
|
7
7
|
const [devtools] = createSignal(new PacerDevtoolsCore({}));
|
|
8
8
|
onMount(() => {
|
|
9
9
|
if (devToolRef) {
|
|
10
|
-
devtools().mount(devToolRef);
|
|
10
|
+
devtools().mount(devToolRef, props?.theme ?? "dark");
|
|
11
11
|
onCleanup(() => {
|
|
12
12
|
devtools().unmount();
|
|
13
13
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SolidPacerDevtools.js","sources":["../../src/SolidPacerDevtools.tsx"],"sourcesContent":["import { PacerDevtoolsCore } from '@tanstack/pacer-devtools'\nimport { createSignal, onCleanup, onMount } from 'solid-js'\n\nexport interface PacerDevtoolsSolidInit {}\n\nexport const PacerDevtoolsPanel = (
|
|
1
|
+
{"version":3,"file":"SolidPacerDevtools.js","sources":["../../src/SolidPacerDevtools.tsx"],"sourcesContent":["import { PacerDevtoolsCore } from '@tanstack/pacer-devtools'\nimport { createSignal, onCleanup, onMount } from 'solid-js'\n\nexport interface PacerDevtoolsSolidInit {\n theme?: 'light' | 'dark'\n}\n\nexport const PacerDevtoolsPanel = (props?: PacerDevtoolsSolidInit) => {\n let devToolRef: HTMLDivElement | undefined\n const [devtools] = createSignal(new PacerDevtoolsCore({}))\n onMount(() => {\n if (devToolRef) {\n devtools().mount(devToolRef, props?.theme ?? 'dark')\n\n onCleanup(() => {\n devtools().unmount()\n })\n }\n })\n\n return <div style={{ height: '100%' }} ref={devToolRef} />\n}\n"],"names":["PacerDevtoolsPanel","props","devToolRef","devtools","createSignal","PacerDevtoolsCore","onMount","mount","theme","onCleanup","unmount","_el$","_tmpl$","_ref$","_$use","style","setProperty"],"mappings":";;;;AAOO,MAAMA,qBAAqBA,CAACC,UAAmC;AACpE,MAAIC;AACJ,QAAM,CAACC,QAAQ,IAAIC,aAAa,IAAIC,kBAAkB,CAAA,CAAE,CAAC;AACzDC,UAAQ,MAAM;AACZ,QAAIJ,YAAY;AACdC,eAAAA,EAAWI,MAAML,YAAYD,OAAOO,SAAS,MAAM;AAEnDC,gBAAU,MAAM;AACdN,iBAAAA,EAAWO,QAAAA;AAAAA,MAAQ,CACpB;AAAA,IAAA;AAAA,EACH,CACD;AAED,UAAA,MAAA;AAAA,QAAAC,OAAAC,OAAAA;AAAA,QAAAC,QAA4CX;AAAU,WAAAW,UAAA,aAAAC,IAAAD,OAAAF,IAAA,IAAVT,aAAUS;AAAAA,SAAAI,MAAAC,YAAA,UAAA,MAAA;AAAA,WAAAL;AAAAA,EAAAA,GAAA;AACxD;"}
|
package/dist/esm/index.d.ts
CHANGED
package/dist/esm/index.js
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { PacerDevtoolsPanel as PacerDevtoolsPanel$1 } from "./SolidPacerDevtools.js";
|
|
3
|
+
import { pacerDevtoolsPlugin } from "./plugin.js";
|
|
3
4
|
const PacerDevtoolsPanel = process.env.NODE_ENV !== "development" ? function() {
|
|
4
5
|
return null;
|
|
5
6
|
} : PacerDevtoolsPanel$1;
|
|
6
7
|
export {
|
|
7
|
-
PacerDevtoolsPanel
|
|
8
|
+
PacerDevtoolsPanel,
|
|
9
|
+
pacerDevtoolsPlugin
|
|
8
10
|
};
|
|
9
11
|
//# sourceMappingURL=index.js.map
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../src/index.ts"],"sourcesContent":["'use client'\n\nimport * as Devtools from './SolidPacerDevtools'\n\nexport const PacerDevtoolsPanel: (typeof Devtools)['PacerDevtoolsPanel'] =\n process.env.NODE_ENV !== 'development'\n ? function () {\n return null\n }\n : Devtools.PacerDevtoolsPanel\n\nexport type { PacerDevtoolsSolidInit } from './SolidPacerDevtools'\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../src/index.ts"],"sourcesContent":["'use client'\n\nimport * as Devtools from './SolidPacerDevtools'\n\nexport const PacerDevtoolsPanel: (typeof Devtools)['PacerDevtoolsPanel'] =\n process.env.NODE_ENV !== 'development'\n ? function () {\n return null\n }\n : Devtools.PacerDevtoolsPanel\n\nexport type { PacerDevtoolsSolidInit } from './SolidPacerDevtools'\n\nexport { pacerDevtoolsPlugin } from './plugin'\n"],"names":[],"mappings":";;;AAIO;AAGC;AACF;;;;;"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { createComponent } from "solid-js/web";
|
|
2
|
+
import { PacerDevtoolsPanel } from "./production.js";
|
|
3
|
+
function pacerDevtoolsPlugin() {
|
|
4
|
+
return {
|
|
5
|
+
name: "TanStack Pacer",
|
|
6
|
+
render: (_el, theme) => {
|
|
7
|
+
return createComponent(PacerDevtoolsPanel, {
|
|
8
|
+
theme
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
export {
|
|
14
|
+
pacerDevtoolsPlugin
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=plugin-prod.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin-prod.js","sources":["../../src/plugin-prod.tsx"],"sourcesContent":["import { PacerDevtoolsPanel } from './production'\n\nexport function pacerDevtoolsPlugin() {\n return {\n name: 'TanStack Pacer',\n render: (_el: HTMLElement, theme: 'light' | 'dark') => {\n return <PacerDevtoolsPanel theme={theme} />\n },\n }\n}\n"],"names":["pacerDevtoolsPlugin","name","render","_el","theme","_$createComponent","PacerDevtoolsPanel"],"mappings":";;AAEO,SAASA,sBAAsB;AACpC,SAAO;AAAA,IACLC,MAAM;AAAA,IACNC,QAAQA,CAACC,KAAkBC,UAA4B;AACrD,aAAAC,gBAAQC,oBAAkB;AAAA,QAACF;AAAAA,MAAAA,CAAY;AAAA,IAAA;AAAA,EACzC;AAEJ;"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { createComponent } from "solid-js/web";
|
|
2
|
+
import { PacerDevtoolsPanel } from "./index.js";
|
|
3
|
+
function pacerDevtoolsPlugin() {
|
|
4
|
+
return {
|
|
5
|
+
name: "TanStack Pacer",
|
|
6
|
+
render: (_el, theme) => {
|
|
7
|
+
return createComponent(PacerDevtoolsPanel, {
|
|
8
|
+
theme
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
export {
|
|
14
|
+
pacerDevtoolsPlugin
|
|
15
|
+
};
|
|
16
|
+
//# sourceMappingURL=plugin.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.js","sources":["../../src/plugin.tsx"],"sourcesContent":["import { PacerDevtoolsPanel } from './index'\n\nexport function pacerDevtoolsPlugin() {\n return {\n name: 'TanStack Pacer',\n render: (_el: HTMLElement, theme: 'light' | 'dark') => {\n return <PacerDevtoolsPanel theme={theme} />\n },\n }\n}\n"],"names":["pacerDevtoolsPlugin","name","render","_el","theme","_$createComponent","PacerDevtoolsPanel"],"mappings":";;AAEO,SAASA,sBAAsB;AACpC,SAAO;AAAA,IACLC,MAAM;AAAA,IACNC,QAAQA,CAACC,KAAkBC,UAA4B;AACrD,aAAAC,gBAAQC,oBAAkB;AAAA,QAACF;AAAAA,MAAAA,CAAY;AAAA,IAAA;AAAA,EACzC;AAEJ;"}
|
package/dist/esm/production.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import * as Devtools from './SolidPacerDevtools.js';
|
|
2
|
-
export declare const PacerDevtoolsPanel: (
|
|
2
|
+
export declare const PacerDevtoolsPanel: (props?: Devtools.PacerDevtoolsSolidInit) => import("solid-js").JSX.Element;
|
|
3
3
|
export type { PacerDevtoolsSolidInit } from './SolidPacerDevtools.js';
|
|
4
|
+
export { pacerDevtoolsPlugin } from './plugin-prod.js';
|
package/dist/esm/production.js
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { PacerDevtoolsPanel as PacerDevtoolsPanel$1 } from "./SolidPacerDevtools.js";
|
|
3
|
+
import { pacerDevtoolsPlugin } from "./plugin-prod.js";
|
|
3
4
|
const PacerDevtoolsPanel = PacerDevtoolsPanel$1;
|
|
4
5
|
export {
|
|
5
|
-
PacerDevtoolsPanel
|
|
6
|
+
PacerDevtoolsPanel,
|
|
7
|
+
pacerDevtoolsPlugin
|
|
6
8
|
};
|
|
7
9
|
//# sourceMappingURL=production.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"production.js","sources":["../../src/production.ts"],"sourcesContent":["'use client'\n\nimport * as Devtools from './SolidPacerDevtools'\n\nexport const PacerDevtoolsPanel = Devtools.PacerDevtoolsPanel\n\nexport type { PacerDevtoolsSolidInit } from './SolidPacerDevtools'\n"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"production.js","sources":["../../src/production.ts"],"sourcesContent":["'use client'\n\nimport * as Devtools from './SolidPacerDevtools'\n\nexport const PacerDevtoolsPanel = Devtools.PacerDevtoolsPanel\n\nexport type { PacerDevtoolsSolidInit } from './SolidPacerDevtools'\n\nexport { pacerDevtoolsPlugin } from './plugin-prod'\n"],"names":[],"mappings":";;;AAIO;;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tanstack/solid-pacer-devtools",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Solid adapter for devtools for Pacer.",
|
|
5
5
|
"author": "Tanner Linsley",
|
|
6
6
|
"license": "MIT",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"solid-js": ">=1.9.7"
|
|
53
53
|
},
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@tanstack/pacer-devtools": "0.
|
|
55
|
+
"@tanstack/pacer-devtools": "0.3.0"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"vite-plugin-solid": "^2.11.8"
|
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
import { PacerDevtoolsCore } from '@tanstack/pacer-devtools'
|
|
2
2
|
import { createSignal, onCleanup, onMount } from 'solid-js'
|
|
3
3
|
|
|
4
|
-
export interface PacerDevtoolsSolidInit {
|
|
4
|
+
export interface PacerDevtoolsSolidInit {
|
|
5
|
+
theme?: 'light' | 'dark'
|
|
6
|
+
}
|
|
5
7
|
|
|
6
|
-
export const PacerDevtoolsPanel = (
|
|
8
|
+
export const PacerDevtoolsPanel = (props?: PacerDevtoolsSolidInit) => {
|
|
7
9
|
let devToolRef: HTMLDivElement | undefined
|
|
8
10
|
const [devtools] = createSignal(new PacerDevtoolsCore({}))
|
|
9
11
|
onMount(() => {
|
|
10
12
|
if (devToolRef) {
|
|
11
|
-
devtools().mount(devToolRef)
|
|
13
|
+
devtools().mount(devToolRef, props?.theme ?? 'dark')
|
|
12
14
|
|
|
13
15
|
onCleanup(() => {
|
|
14
16
|
devtools().unmount()
|
package/src/index.ts
CHANGED
package/src/plugin.tsx
ADDED