@rxflow/base 0.0.2-alpha.3 → 0.0.2-alpha.5

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.
@@ -2,7 +2,7 @@ export declare const useTheme: () => {
2
2
  fontSize: number;
3
3
  fontFamily: string;
4
4
  primaryColor: string;
5
- collapseButtonShape?: "rect" | "circle" | undefined;
5
+ collapseButtonShape?: "circle" | "rect" | undefined;
6
6
  autoHideCountWhenExpanded?: boolean | undefined;
7
7
  showCount?: boolean | undefined;
8
8
  };
package/cjs/index.d.ts CHANGED
@@ -23,6 +23,6 @@ export * from './utils/layouts/mindmap';
23
23
  export * from './constants/NodeRoleType';
24
24
  export * from './constants/InnerFlowType';
25
25
  export * from './constants/SelectionStrategy';
26
- export { FlowContext } from './providers/FlowProvider';
26
+ export { FlowContext, FlowProvider } from './providers/FlowProvider';
27
27
  export { Flow };
28
28
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.tsx"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;AACH,OAAO,EAAC,IAAI,EAAC,MAAM,QAAQ,CAAC;AAG5B,QAAA,MAAM,QAAQ,qLAAmB,CAAA;AAEjC,eAAe,QAAQ,CAAC;AAExB,cAAc,SAAS,CAAC;AAExB,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,yBAAyB,CAAC;AACxC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,OAAO,EAAC,WAAW,EAAC,MAAM,0BAA0B,CAAC;AAErD,OAAO,EAAC,IAAI,EAAC,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.tsx"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;AACH,OAAO,EAAC,IAAI,EAAC,MAAM,QAAQ,CAAC;AAG5B,QAAA,MAAM,QAAQ,qLAAmB,CAAA;AAEjC,eAAe,QAAQ,CAAC;AAExB,cAAc,SAAS,CAAC;AAExB,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,yBAAyB,CAAC;AACxC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,OAAO,EAAC,WAAW,EAAE,YAAY,EAAC,MAAM,0BAA0B,CAAC;AAEnE,OAAO,EAAC,IAAI,EAAC,CAAA"}
package/cjs/index.js CHANGED
@@ -5,7 +5,8 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  var _exportNames = {
7
7
  Flow: true,
8
- FlowContext: true
8
+ FlowContext: true,
9
+ FlowProvider: true
9
10
  };
10
11
  Object.defineProperty(exports, "Flow", {
11
12
  enumerable: true,
@@ -19,6 +20,12 @@ Object.defineProperty(exports, "FlowContext", {
19
20
  return _FlowProvider.FlowContext;
20
21
  }
21
22
  });
23
+ Object.defineProperty(exports, "FlowProvider", {
24
+ enumerable: true,
25
+ get: function () {
26
+ return _FlowProvider.FlowProvider;
27
+ }
28
+ });
22
29
  exports.default = void 0;
23
30
  var _Flow = require("./Flow");
24
31
  var _createFlow = require("./hoc/createFlow");
@@ -1,22 +1,13 @@
1
- /**
2
- * @author: yanxianliang
3
- * @date: 2025-10-16 17:28
4
- * @modified:2025/10/16 17:28 by yanxianliang
5
- * @desc: 全局状态管理器
6
- *
7
- * Copyright (c) 2025 by yanxianliang, All Rights Reserved.
8
- */
9
- import { BaseStateType, ExtractState } from "../types";
10
1
  import React from "react";
11
2
  import { UseBoundStore } from "zustand";
12
3
  import type { StoreApi } from "zustand/vanilla";
4
+ import { BaseStateType, ExtractState } from "../types";
13
5
  export declare const FlowContext: React.Context<{
14
6
  useStore?: UseBoundStore<StoreApi<BaseStateType>> | undefined;
15
7
  }>;
16
- export declare const FlowProvider: React.MemoExoticComponent<({ children, }: {
8
+ export declare const FlowProvider: React.ComponentType<{
17
9
  children: React.ReactNode;
18
- id?: string | undefined;
19
- }) => string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined>;
10
+ }>;
20
11
  /**
21
12
  * hooks 创建
22
13
  * selector 创建
@@ -1 +1 @@
1
- {"version":3,"file":"FlowProvider.d.ts","sourceRoot":"","sources":["FlowProvider.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAAC,aAAa,EAAE,YAAY,EAAC,MAAM,UAAU,CAAC;AAErD,OAAO,KAAmC,MAAM,OAAO,CAAC;AACxD,OAAO,EAAS,aAAa,EAAC,MAAM,SAAS,CAAC;AAE9C,OAAO,KAAK,EAAC,QAAQ,EAAC,MAAM,iBAAiB,CAAC;AAG9C,eAAO,MAAM,WAAW;;EAET,CAAC;AA+BhB,eAAO,MAAM,YAAY;cAIX,MAAM,SAAS;;4TAY3B,CAAA;AAGF;;;GAGG;AACH,eAAO,MAAM,WAAW,wBAA2B,aAAa,SAAS,aAAa,CAAC,CAAC,KAAK,CAAC,MAO7F,CAAA;AAED,eAAO,MAAM,WAAW,qKAOvB,CAAA;AAED,eAAO,MAAM,WAAW,2BAOvB,CAAA"}
1
+ {"version":3,"file":"FlowProvider.d.ts","sourceRoot":"","sources":["FlowProvider.tsx"],"names":[],"mappings":"AASA,OAAO,KAAmC,MAAM,OAAO,CAAC;AACxD,OAAO,EAAS,aAAa,EAAC,MAAM,SAAS,CAAC;AAE9C,OAAO,KAAK,EAAC,QAAQ,EAAC,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAC,aAAa,EAAE,YAAY,EAAC,MAAM,UAAU,CAAC;AAGrD,eAAO,MAAM,WAAW;;EAET,CAAC;AA8BhB,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,aAAa,CAAC;IAAE,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAAC,CAe1E,CAAA;AAGF;;;GAGG;AACH,eAAO,MAAM,WAAW,wBAA2B,aAAa,SAAS,aAAa,CAAC,CAAC,KAAK,CAAC,MAO7F,CAAA;AAED,eAAO,MAAM,WAAW,qKAOvB,CAAA;AAED,eAAO,MAAM,WAAW,2BAOvB,CAAA"}
@@ -2,7 +2,7 @@ export declare const useTheme: () => {
2
2
  fontSize: number;
3
3
  fontFamily: string;
4
4
  primaryColor: string;
5
- collapseButtonShape?: "rect" | "circle" | undefined;
5
+ collapseButtonShape?: "circle" | "rect" | undefined;
6
6
  autoHideCountWhenExpanded?: boolean | undefined;
7
7
  showCount?: boolean | undefined;
8
8
  };
package/esm/index.d.ts CHANGED
@@ -23,6 +23,6 @@ export * from './utils/layouts/mindmap';
23
23
  export * from './constants/NodeRoleType';
24
24
  export * from './constants/InnerFlowType';
25
25
  export * from './constants/SelectionStrategy';
26
- export { FlowContext } from './providers/FlowProvider';
26
+ export { FlowContext, FlowProvider } from './providers/FlowProvider';
27
27
  export { Flow };
28
28
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.tsx"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;AACH,OAAO,EAAC,IAAI,EAAC,MAAM,QAAQ,CAAC;AAG5B,QAAA,MAAM,QAAQ,qLAAmB,CAAA;AAEjC,eAAe,QAAQ,CAAC;AAExB,cAAc,SAAS,CAAC;AAExB,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,yBAAyB,CAAC;AACxC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,OAAO,EAAC,WAAW,EAAC,MAAM,0BAA0B,CAAC;AAErD,OAAO,EAAC,IAAI,EAAC,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.tsx"],"names":[],"mappings":";AAAA;;;;;;;;GAQG;AACH,OAAO,EAAC,IAAI,EAAC,MAAM,QAAQ,CAAC;AAG5B,QAAA,MAAM,QAAQ,qLAAmB,CAAA;AAEjC,eAAe,QAAQ,CAAC;AAExB,cAAc,SAAS,CAAC;AAExB,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,wBAAwB,CAAC;AACvC,cAAc,qBAAqB,CAAC;AACpC,cAAc,yBAAyB,CAAC;AACxC,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,+BAA+B,CAAC;AAC9C,OAAO,EAAC,WAAW,EAAE,YAAY,EAAC,MAAM,0BAA0B,CAAC;AAEnE,OAAO,EAAC,IAAI,EAAC,CAAA"}
package/esm/index.js CHANGED
@@ -23,5 +23,5 @@ export * from "./utils/layouts/mindmap";
23
23
  export * from "./constants/NodeRoleType";
24
24
  export * from "./constants/InnerFlowType";
25
25
  export * from "./constants/SelectionStrategy";
26
- export { FlowContext } from "./providers/FlowProvider";
26
+ export { FlowContext, FlowProvider } from "./providers/FlowProvider";
27
27
  export { Flow };
@@ -1,22 +1,13 @@
1
- /**
2
- * @author: yanxianliang
3
- * @date: 2025-10-16 17:28
4
- * @modified:2025/10/16 17:28 by yanxianliang
5
- * @desc: 全局状态管理器
6
- *
7
- * Copyright (c) 2025 by yanxianliang, All Rights Reserved.
8
- */
9
- import { BaseStateType, ExtractState } from "../types";
10
1
  import React from "react";
11
2
  import { UseBoundStore } from "zustand";
12
3
  import type { StoreApi } from "zustand/vanilla";
4
+ import { BaseStateType, ExtractState } from "../types";
13
5
  export declare const FlowContext: React.Context<{
14
6
  useStore?: UseBoundStore<StoreApi<BaseStateType>> | undefined;
15
7
  }>;
16
- export declare const FlowProvider: React.MemoExoticComponent<({ children, }: {
8
+ export declare const FlowProvider: React.ComponentType<{
17
9
  children: React.ReactNode;
18
- id?: string | undefined;
19
- }) => string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined>;
10
+ }>;
20
11
  /**
21
12
  * hooks 创建
22
13
  * selector 创建
@@ -1 +1 @@
1
- {"version":3,"file":"FlowProvider.d.ts","sourceRoot":"","sources":["FlowProvider.tsx"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAAC,aAAa,EAAE,YAAY,EAAC,MAAM,UAAU,CAAC;AAErD,OAAO,KAAmC,MAAM,OAAO,CAAC;AACxD,OAAO,EAAS,aAAa,EAAC,MAAM,SAAS,CAAC;AAE9C,OAAO,KAAK,EAAC,QAAQ,EAAC,MAAM,iBAAiB,CAAC;AAG9C,eAAO,MAAM,WAAW;;EAET,CAAC;AA+BhB,eAAO,MAAM,YAAY;cAIX,MAAM,SAAS;;4TAY3B,CAAA;AAGF;;;GAGG;AACH,eAAO,MAAM,WAAW,wBAA2B,aAAa,SAAS,aAAa,CAAC,CAAC,KAAK,CAAC,MAO7F,CAAA;AAED,eAAO,MAAM,WAAW,qKAOvB,CAAA;AAED,eAAO,MAAM,WAAW,2BAOvB,CAAA"}
1
+ {"version":3,"file":"FlowProvider.d.ts","sourceRoot":"","sources":["FlowProvider.tsx"],"names":[],"mappings":"AASA,OAAO,KAAmC,MAAM,OAAO,CAAC;AACxD,OAAO,EAAS,aAAa,EAAC,MAAM,SAAS,CAAC;AAE9C,OAAO,KAAK,EAAC,QAAQ,EAAC,MAAM,iBAAiB,CAAC;AAC9C,OAAO,EAAC,aAAa,EAAE,YAAY,EAAC,MAAM,UAAU,CAAC;AAGrD,eAAO,MAAM,WAAW;;EAET,CAAC;AA8BhB,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,aAAa,CAAC;IAAE,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAAC,CAe1E,CAAA;AAGF;;;GAGG;AACH,eAAO,MAAM,WAAW,wBAA2B,aAAa,SAAS,aAAa,CAAC,CAAC,KAAK,CAAC,MAO7F,CAAA;AAED,eAAO,MAAM,WAAW,qKAOvB,CAAA;AAED,eAAO,MAAM,WAAW,2BAOvB,CAAA"}
@@ -12,7 +12,6 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
12
12
  *
13
13
  * Copyright (c) 2025 by yanxianliang, All Rights Reserved.
14
14
  */
15
-
16
15
  import { ReactFlowProvider } from "@xyflow/react";
17
16
  import React, { memo, useContext, useState } from "react";
18
17
  import { create } from "zustand";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rxflow/base",
3
- "version": "0.0.2-alpha.3",
3
+ "version": "0.0.2-alpha.5",
4
4
  "description": "BaseFlow - 核心 Flow 组件库",
5
5
  "keywords": [
6
6
  "reactflow",
@@ -42,7 +42,7 @@
42
42
  "dependencies": {
43
43
  "@ant-design/icons": "^6.0.0",
44
44
  "@antv/hierarchy": "0.6.14",
45
- "@rxflow/manhattan": "^0.0.2-alpha.3",
45
+ "@rxflow/manhattan": "^0.0.2-alpha.5",
46
46
  "@xyflow/react": "^12.8.6",
47
47
  "@xyflow/system": "^0.0.70",
48
48
  "@zumer/snapdom": "^1.9.9",