@tanstack/react-hotkeys-devtools 0.11.1 → 0.12.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.
@@ -1,10 +1,10 @@
1
- import { JSX } from "react";
2
- import { DevtoolsPanelProps } from "@tanstack/devtools-utils/react";
1
+ import { ReactElement } from "react";
2
+ import { HotkeysDevtoolsPanelProps } from "@tanstack/hotkeys-devtools";
3
3
  declare namespace ReactHotkeysDevtools_d_exports {
4
4
  export { HotkeysDevtoolsPanel, HotkeysDevtoolsPanelNoOp, HotkeysDevtoolsReactInit };
5
5
  }
6
- export interface HotkeysDevtoolsReactInit extends Partial<DevtoolsPanelProps> {}
7
- type HotkeysDevtoolsPanelComponent = (props?: HotkeysDevtoolsReactInit) => JSX.Element;
6
+ export interface HotkeysDevtoolsReactInit extends Partial<HotkeysDevtoolsPanelProps> {}
7
+ type HotkeysDevtoolsPanelComponent = (props?: HotkeysDevtoolsReactInit) => ReactElement;
8
8
  export declare const HotkeysDevtoolsPanel: HotkeysDevtoolsPanelComponent;
9
9
  export declare const HotkeysDevtoolsPanelNoOp: HotkeysDevtoolsPanelComponent;
10
10
  //#endregion
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { HotkeysDevtoolsPanel as HotkeysDevtoolsPanel$1, HotkeysDevtoolsReactInit, ReactHotkeysDevtools_d_exports } from "./ReactHotkeysDevtools.js";
2
- import { hotkeysDevtoolsPlugin as hotkeysDevtoolsPlugin$1, plugin_d_exports } from "./plugin.js";
2
+ import { HotkeysDevtoolsReactPlugin, hotkeysDevtoolsPlugin as hotkeysDevtoolsPlugin$1, plugin_d_exports } from "./plugin.js";
3
3
  //#region src/index.d.ts
4
4
  export declare const HotkeysDevtoolsPanel: typeof HotkeysDevtoolsPanel$1;
5
5
  export declare const hotkeysDevtoolsPlugin: typeof hotkeysDevtoolsPlugin$1;
6
6
  //#endregion
7
- export type { HotkeysDevtoolsReactInit };
7
+ export type { HotkeysDevtoolsReactInit, HotkeysDevtoolsReactPlugin };
package/dist/plugin.d.ts CHANGED
@@ -1,8 +1,16 @@
1
- import { createReactPlugin } from "@tanstack/devtools-utils/react";
1
+ import { ReactElement } from "react";
2
+ import { HotkeysDevtoolsPanelProps } from "@tanstack/hotkeys-devtools";
2
3
  declare namespace plugin_d_exports {
3
- export { hotkeysDevtoolsNoOpPlugin, hotkeysDevtoolsPlugin };
4
+ export { HotkeysDevtoolsReactPlugin, hotkeysDevtoolsNoOpPlugin, hotkeysDevtoolsPlugin };
4
5
  }
5
- type HotkeysDevtoolsPluginFactory = ReturnType<typeof createReactPlugin>[0];
6
+ /** A plugin for `TanStackDevtools` from `@tanstack/react-devtools`. */
7
+ export interface HotkeysDevtoolsReactPlugin {
8
+ name: string;
9
+ id?: string;
10
+ defaultOpen?: boolean;
11
+ render: (el: HTMLElement, props: HotkeysDevtoolsPanelProps) => ReactElement;
12
+ }
13
+ type HotkeysDevtoolsPluginFactory = () => HotkeysDevtoolsReactPlugin;
6
14
  export declare const hotkeysDevtoolsPlugin: HotkeysDevtoolsPluginFactory;
7
15
  export declare const hotkeysDevtoolsNoOpPlugin: HotkeysDevtoolsPluginFactory;
8
16
  //#endregion
@@ -1,3 +1,3 @@
1
1
  import { HotkeysDevtoolsPanel, HotkeysDevtoolsReactInit } from "./ReactHotkeysDevtools.js";
2
- import { hotkeysDevtoolsPlugin } from "./plugin.js";
3
- export { HotkeysDevtoolsPanel, type HotkeysDevtoolsReactInit, hotkeysDevtoolsPlugin };
2
+ import { HotkeysDevtoolsReactPlugin, hotkeysDevtoolsPlugin } from "./plugin.js";
3
+ export { HotkeysDevtoolsPanel, type HotkeysDevtoolsReactInit, type HotkeysDevtoolsReactPlugin, hotkeysDevtoolsPlugin };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tanstack/react-hotkeys-devtools",
3
- "version": "0.11.1",
3
+ "version": "0.12.0",
4
4
  "description": "React devtools for TanStack Hotkeys",
5
5
  "author": "Tanner Linsley",
6
6
  "license": "MIT",
@@ -37,14 +37,14 @@
37
37
  "dist"
38
38
  ],
39
39
  "peerDependencies": {
40
- "@types/react": ">=16.8",
41
- "@types/react-dom": ">=16.8",
42
- "react": ">=16.8",
43
- "react-dom": ">=16.8"
40
+ "@types/react": ">=18.0.0",
41
+ "@types/react-dom": ">=18.0.0",
42
+ "react": ">=18.0.0",
43
+ "react-dom": ">=18.0.0"
44
44
  },
45
45
  "dependencies": {
46
46
  "@tanstack/devtools-utils": "^0.7.0",
47
- "@tanstack/hotkeys-devtools": "1.6.0"
47
+ "@tanstack/hotkeys-devtools": "1.6.1"
48
48
  },
49
49
  "devDependencies": {
50
50
  "@eslint-react/eslint-plugin": "^4.2.3",