@next-core/brick-kit 2.118.3 → 2.118.4
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 +11 -0
- package/dist/index.bundle.js +255 -256
- package/dist/index.bundle.js.map +1 -1
- package/dist/index.esm.js +256 -257
- package/dist/index.esm.js.map +1 -1
- package/dist/types/BrickAsComponent.d.ts +0 -2
- package/dist/types/BrickAsComponent.d.ts.map +1 -1
- package/dist/types/core/CustomTemplates/constants.d.ts +2 -1
- package/dist/types/core/CustomTemplates/constants.d.ts.map +1 -1
- package/dist/types/core/CustomTemplates/expandCustomTemplate.d.ts +18 -1
- package/dist/types/core/CustomTemplates/expandCustomTemplate.d.ts.map +1 -1
- package/dist/types/core/CustomTemplates/setupTemplateProxy.d.ts +5 -0
- package/dist/types/core/CustomTemplates/setupTemplateProxy.d.ts.map +1 -0
- package/dist/types/core/CustomTemplates/setupUseBrickInTemplate.d.ts +2 -1
- package/dist/types/core/CustomTemplates/setupUseBrickInTemplate.d.ts.map +1 -1
- package/dist/types/internal/setProperties.d.ts.map +1 -1
- package/package.json +6 -6
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
2
|
import { UseBrickConf, UseSingleBrickConf } from "@next-core/brick-types";
|
|
3
|
-
import { RuntimeBrick } from "./core/exports";
|
|
4
3
|
interface BrickAsComponentProps {
|
|
5
4
|
useBrick: UseBrickConf;
|
|
6
5
|
data?: unknown;
|
|
@@ -14,7 +13,6 @@ interface SingleBrickAsComponentProps extends BrickAsComponentProps {
|
|
|
14
13
|
refCallback?: (element: HTMLElement) => void;
|
|
15
14
|
immediatelyRefCallback?: (element: HTMLElement) => void;
|
|
16
15
|
}
|
|
17
|
-
export declare const handleProxyOfParentTemplate: (brick: RuntimeBrick, tplContextId: string) => void;
|
|
18
16
|
/**
|
|
19
17
|
* 可以渲染单个 `useBrick` 的 React 组件。
|
|
20
18
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BrickAsComponent.d.ts","sourceRoot":"","sources":["../../src/BrickAsComponent.tsx"],"names":[],"mappings":"AACA,OAAO,KAAkD,MAAM,OAAO,CAAC;AAEvE,OAAO,EACL,YAAY,EACZ,kBAAkB,
|
|
1
|
+
{"version":3,"file":"BrickAsComponent.d.ts","sourceRoot":"","sources":["../../src/BrickAsComponent.tsx"],"names":[],"mappings":"AACA,OAAO,KAAkD,MAAM,OAAO,CAAC;AAEvE,OAAO,EACL,YAAY,EACZ,kBAAkB,EAOnB,MAAM,wBAAwB,CAAC;AA+BhC,UAAU,qBAAqB;IAC7B,QAAQ,EAAE,YAAY,CAAC;IACvB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf;;OAEG;IACH,4BAA4B,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC;CAC7D;AAED,UAAU,2BAA4B,SAAQ,qBAAqB;IACjE,QAAQ,EAAE,kBAAkB,CAAC;IAC7B,WAAW,CAAC,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,IAAI,CAAC;IAC7C,sBAAsB,CAAC,EAAE,CAAC,OAAO,EAAE,WAAW,KAAK,IAAI,CAAC;CACzD;AAyED;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,sBAAsB,yDAoKlC,CAAC;AAEF;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,QAAQ,EACR,IAAI,GACL,EAAE,qBAAqB,GAAG,KAAK,CAAC,YAAY,CAW5C;AAgCD,eAAO,MAAM,gCAAgC,4HA8K5C,CAAC"}
|
|
@@ -4,7 +4,8 @@ export declare const appRegistered: Set<string>;
|
|
|
4
4
|
export declare const symbolForComputedPropsFromProxy: unique symbol;
|
|
5
5
|
export declare const symbolForRefForProxy: unique symbol;
|
|
6
6
|
export declare const symbolForTplContextId: unique symbol;
|
|
7
|
-
export
|
|
7
|
+
export declare type RuntimeBrickConfWithTplSymbols = RuntimeBrickConf & RuntimeBrickConfOfTplSymbols;
|
|
8
|
+
export interface RuntimeBrickConfOfTplSymbols {
|
|
8
9
|
[symbolForComputedPropsFromProxy]?: Record<string, any>;
|
|
9
10
|
[symbolForRefForProxy]?: RefForProxy;
|
|
10
11
|
[symbolForTplContextId]?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/core/CustomTemplates/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,EACd,WAAW,EACX,gBAAgB,EAChB,gBAAgB,EACjB,MAAM,wBAAwB,CAAC;AAEhC,eAAO,MAAM,sBAAsB,EAAE,gBAAgB,CAAC,cAAc,CACzD,CAAC;AACZ,eAAO,MAAM,aAAa,aAAoB,CAAC;AAE/C,eAAO,MAAM,+BAA+B,eAE3C,CAAC;AACF,eAAO,MAAM,oBAAoB,eAAgC,CAAC;AAClE,eAAO,MAAM,qBAAqB,eAA8B,CAAC;AAEjE,
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../src/core/CustomTemplates/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,cAAc,EACd,WAAW,EACX,gBAAgB,EAChB,gBAAgB,EACjB,MAAM,wBAAwB,CAAC;AAEhC,eAAO,MAAM,sBAAsB,EAAE,gBAAgB,CAAC,cAAc,CACzD,CAAC;AACZ,eAAO,MAAM,aAAa,aAAoB,CAAC;AAE/C,eAAO,MAAM,+BAA+B,eAE3C,CAAC;AACF,eAAO,MAAM,oBAAoB,eAAgC,CAAC;AAClE,eAAO,MAAM,qBAAqB,eAA8B,CAAC;AAEjE,oBAAY,8BAA8B,GAAG,gBAAgB,GAC3D,4BAA4B,CAAC;AAE/B,MAAM,WAAW,4BAA4B;IAC3C,CAAC,+BAA+B,CAAC,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IACxD,CAAC,oBAAoB,CAAC,CAAC,EAAE,WAAW,CAAC;IACrC,CAAC,qBAAqB,CAAC,CAAC,EAAE,MAAM,CAAC;CAClC"}
|
|
@@ -1,5 +1,22 @@
|
|
|
1
|
-
import { PluginRuntimeContext, RuntimeBrickConf } from "@next-core/brick-types";
|
|
1
|
+
import { CustomTemplateProxySlot, PluginRuntimeContext, RuntimeBrickConf, SlotsConfOfBricks } from "@next-core/brick-types";
|
|
2
2
|
import { RuntimeBrick } from "../BrickNode";
|
|
3
|
+
import { MergeBase, PropertyProxy } from "./internalInterfaces";
|
|
4
|
+
export interface ProxyContext {
|
|
5
|
+
reversedProxies: ReversedProxies;
|
|
6
|
+
templateProperties: Record<string, unknown>;
|
|
7
|
+
externalSlots: SlotsConfOfBricks;
|
|
8
|
+
templateContextId: string;
|
|
9
|
+
proxyBrick: RuntimeBrick;
|
|
10
|
+
}
|
|
11
|
+
interface ReversedProxies {
|
|
12
|
+
properties: Map<string, PropertyProxy[]>;
|
|
13
|
+
slots: Map<string, SlotProxy[]>;
|
|
14
|
+
mergeBases: Map<string, Map<string, MergeBase>>;
|
|
15
|
+
}
|
|
16
|
+
interface SlotProxy extends CustomTemplateProxySlot {
|
|
17
|
+
$$reversedRef?: string;
|
|
18
|
+
}
|
|
3
19
|
export declare function expandCustomTemplate(brickConf: RuntimeBrickConf, proxyBrick: RuntimeBrick, context: PluginRuntimeContext): RuntimeBrickConf;
|
|
4
20
|
export declare function asyncExpandCustomTemplate(brickConf: RuntimeBrickConf, proxyBrick: RuntimeBrick, context: PluginRuntimeContext): Promise<RuntimeBrickConf>;
|
|
21
|
+
export {};
|
|
5
22
|
//# sourceMappingURL=expandCustomTemplate.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"expandCustomTemplate.d.ts","sourceRoot":"","sources":["../../../../src/core/CustomTemplates/expandCustomTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"expandCustomTemplate.d.ts","sourceRoot":"","sources":["../../../../src/core/CustomTemplates/expandCustomTemplate.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,uBAAuB,EACvB,oBAAoB,EACpB,gBAAgB,EAChB,iBAAiB,EAElB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,EACL,SAAS,EACT,aAAa,EAGd,MAAM,sBAAsB,CAAC;AAY9B,MAAM,WAAW,YAAY;IAC3B,eAAe,EAAE,eAAe,CAAC;IACjC,kBAAkB,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC5C,aAAa,EAAE,iBAAiB,CAAC;IACjC,iBAAiB,EAAE,MAAM,CAAC;IAC1B,UAAU,EAAE,YAAY,CAAC;CAC1B;AAED,UAAU,eAAe;IACvB,UAAU,EAAE,GAAG,CAAC,MAAM,EAAE,aAAa,EAAE,CAAC,CAAC;IACzC,KAAK,EAAE,GAAG,CAAC,MAAM,EAAE,SAAS,EAAE,CAAC,CAAC;IAChC,UAAU,EAAE,GAAG,CAAC,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC,CAAC;CACjD;AAED,UAAU,SAAU,SAAQ,uBAAuB;IACjD,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,wBAAgB,oBAAoB,CAClC,SAAS,EAAE,gBAAgB,EAC3B,UAAU,EAAE,YAAY,EACxB,OAAO,EAAE,oBAAoB,GAC5B,gBAAgB,CAalB;AAED,wBAAsB,yBAAyB,CAC7C,SAAS,EAAE,gBAAgB,EAC3B,UAAU,EAAE,YAAY,EACxB,OAAO,EAAE,oBAAoB,GAC5B,OAAO,CAAC,gBAAgB,CAAC,CAa3B"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { SlotsConfOfBricks } from "@next-core/brick-types";
|
|
2
|
+
import type { ProxyContext } from "./expandCustomTemplate";
|
|
3
|
+
import { RuntimeBrickConfOfTplSymbols } from "./constants";
|
|
4
|
+
export declare function setupTemplateProxy(proxyContext: Partial<ProxyContext>, ref: string, slots: SlotsConfOfBricks): RuntimeBrickConfOfTplSymbols;
|
|
5
|
+
//# sourceMappingURL=setupTemplateProxy.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"setupTemplateProxy.d.ts","sourceRoot":"","sources":["../../../../src/core/CustomTemplates/setupTemplateProxy.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAGV,iBAAiB,EAClB,MAAM,wBAAwB,CAAC;AAChC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAG3D,OAAO,EACL,4BAA4B,EAI7B,MAAM,aAAa,CAAC;AAGrB,wBAAgB,kBAAkB,CAChC,YAAY,EAAE,OAAO,CAAC,YAAY,CAAC,EACnC,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,iBAAiB,GACvB,4BAA4B,CAsH9B"}
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
1
|
+
import type { ProxyContext } from "./expandCustomTemplate";
|
|
2
|
+
export declare function setupUseBrickInTemplate(props: unknown, proxyContext: Partial<ProxyContext>): void;
|
|
2
3
|
//# sourceMappingURL=setupUseBrickInTemplate.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setupUseBrickInTemplate.d.ts","sourceRoot":"","sources":["../../../../src/core/CustomTemplates/setupUseBrickInTemplate.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"setupUseBrickInTemplate.d.ts","sourceRoot":"","sources":["../../../../src/core/CustomTemplates/setupUseBrickInTemplate.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAG3D,wBAAgB,uBAAuB,CACrC,KAAK,EAAE,OAAO,EACd,YAAY,EAAE,OAAO,CAAC,YAAY,CAAC,GAClC,IAAI,CA8CN"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setProperties.d.ts","sourceRoot":"","sources":["../../../src/internal/setProperties.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAe9D,OAAO,EAGL,eAAe,EAChB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAGhE,UAAU,cAAc;IACtB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,iBAAiB,CAAC,EAAE,eAAe,CAAC;IACpC,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,eAAO,MAAM,gBAAgB,UACpB,OAAO,WACL,oBAAoB,eAChB,OAAO,oBACF,cAAc,KAC/B,OAiEF,CAAC;AAEF,wBAAgB,aAAa,CAC3B,MAAM,EAAE,WAAW,GAAG,WAAW,EAAE,EACnC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACnC,OAAO,EAAE,oBAAoB,EAC7B,UAAU,CAAC,EAAE,OAAO,GACnB,IAAI,
|
|
1
|
+
{"version":3,"file":"setProperties.d.ts","sourceRoot":"","sources":["../../../src/internal/setProperties.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAe9D,OAAO,EAGL,eAAe,EAChB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAGhE,UAAU,cAAc;IACtB,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,iBAAiB,CAAC,EAAE,eAAe,CAAC;IACpC,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB;AAED,eAAO,MAAM,gBAAgB,UACpB,OAAO,WACL,oBAAoB,eAChB,OAAO,oBACF,cAAc,KAC/B,OAiEF,CAAC;AAEF,wBAAgB,aAAa,CAC3B,MAAM,EAAE,WAAW,GAAG,WAAW,EAAE,EACnC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACnC,OAAO,EAAE,oBAAoB,EAC7B,UAAU,CAAC,EAAE,OAAO,GACnB,IAAI,CAaN;AAED,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,WAAW,EAClB,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAClC,YAAY,CAAC,EAAE,OAAO,GACrB,IAAI,CAmBN;AAED,wBAAgB,qBAAqB,CACnC,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACnC,OAAO,EAAE,oBAAoB,EAC7B,UAAU,CAAC,EAAE,OAAO,EACpB,mBAAmB,CAAC,EAAE,mBAAmB,EAAE,GAC1C,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAsCzB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@next-core/brick-kit",
|
|
3
|
-
"version": "2.118.
|
|
3
|
+
"version": "2.118.4",
|
|
4
4
|
"description": "Kernel",
|
|
5
5
|
"homepage": "https://github.com/easyops-cn/next-core/tree/master/packages/brick-kit",
|
|
6
6
|
"license": "GPL-3.0",
|
|
@@ -31,9 +31,9 @@
|
|
|
31
31
|
"test:ci": "cross-env NODE_ENV='test' CI=true jest"
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@next-core/brick-types": "^2.61.
|
|
34
|
+
"@next-core/brick-types": "^2.61.5",
|
|
35
35
|
"@next-core/color-theme": "^0.4.3",
|
|
36
|
-
"@next-core/supply": "^1.0.
|
|
36
|
+
"@next-core/supply": "^1.0.38",
|
|
37
37
|
"@next-sdk/api-gateway-sdk": "^2.0.17",
|
|
38
38
|
"@next-sdk/auth-sdk": "^1.0.0",
|
|
39
39
|
"@next-sdk/cmdb-sdk": "^2.1.1",
|
|
@@ -47,9 +47,9 @@
|
|
|
47
47
|
"devDependencies": {
|
|
48
48
|
"@ant-design/icons": "^4.5.0",
|
|
49
49
|
"@next-core/brick-http": "^2.3.7",
|
|
50
|
-
"@next-core/brick-utils": "^2.37.
|
|
50
|
+
"@next-core/brick-utils": "^2.37.12",
|
|
51
51
|
"@next-core/easyops-analytics": "^0.7.4",
|
|
52
|
-
"@next-core/illustrations": "^0.5.
|
|
52
|
+
"@next-core/illustrations": "^0.5.18",
|
|
53
53
|
"@next-core/pipes": "^1.0.2",
|
|
54
54
|
"antd": "~4.12.3",
|
|
55
55
|
"history": "^4.10.1",
|
|
@@ -80,5 +80,5 @@
|
|
|
80
80
|
"react-dom": "*",
|
|
81
81
|
"react-i18next": "*"
|
|
82
82
|
},
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "1581cae9641d53f22a4081c0b73ea10bec1bad36"
|
|
84
84
|
}
|