@blueking/bkflow-canvas-editor 1.1.0-beta.41 → 1.1.0-beta.43
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/README.md +0 -40
- package/dist/advanced.cjs.js +1 -1
- package/dist/advanced.esm.js +1 -1
- package/dist/context-Bg6nsbrK.js +688 -0
- package/dist/context-iqnF_HqS.cjs +1 -0
- package/dist/index-B0DQFaEe.cjs +82 -0
- package/dist/index-BBNwbryo.cjs +1 -0
- package/dist/index-BSJC2Tb-.js +512 -0
- package/dist/{index-B1ybORjU.js → index-Bqm08e7H.js} +28707 -28167
- package/dist/index-BycpBKMO.cjs +1 -0
- package/dist/index-Ckij2Mxn.cjs +1 -0
- package/dist/index-D7t1wcMU.js +234 -0
- package/dist/index-DgQ-ScE5.js +162 -0
- package/dist/index.cjs.js +1 -1
- package/dist/index.d.ts +2 -26
- package/dist/index.es.min-BpHMrg2Y.cjs +2 -0
- package/dist/index.es.min-DYp0DL9J.js +3543 -0
- package/dist/index.esm.js +34 -43
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/dist/bkflow-canvas-editor_false-B70uLuHL.cjs +0 -1
- package/dist/bkflow-canvas-editor_false-BlC281Zg.cjs +0 -1
- package/dist/bkflow-canvas-editor_false-Casww7p4.js +0 -5
- package/dist/bkflow-canvas-editor_false-i9G8sqQi.js +0 -5
- package/dist/context-C3QIuIf6.cjs +0 -5
- package/dist/context-De9a4Qek.js +0 -1507
- package/dist/index-9BCO-loN.js +0 -533
- package/dist/index-A1xVRjtJ.cjs +0 -1
- package/dist/index-BwF4LXst.cjs +0 -1
- package/dist/index-CjCy-0c0.js +0 -236
- package/dist/index-RacKW0MR.js +0 -168
- package/dist/index-bzXGuf5c.cjs +0 -1
- package/dist/index-iB9uV7YQ.cjs +0 -85
package/README.md
CHANGED
|
@@ -1402,46 +1402,6 @@ resolve: {
|
|
|
1402
1402
|
- FlowEdit 会自动将版本相关 props 透传给内嵌的 FlowDebug 组件
|
|
1403
1403
|
- 版本功能依赖 `fetchFlowDraftDetail` 和 `fetchFlowDetailByVersion` 两个 API 方法
|
|
1404
1404
|
|
|
1405
|
-
## 国际化
|
|
1406
|
-
|
|
1407
|
-
包内自带 `zh-cn` 与 `en` 词条,默认 `zh-cn`。宿主在挂载前调用一次 `setLocale` 即可:
|
|
1408
|
-
|
|
1409
|
-
```typescript
|
|
1410
|
-
import { setLocale } from '@blueking/bkflow-canvas-editor';
|
|
1411
|
-
|
|
1412
|
-
setLocale('en');
|
|
1413
|
-
```
|
|
1414
|
-
|
|
1415
|
-
语言是进程级全局状态,切换后需由宿主刷新页面;不支持同一页面内两个画布实例使用不同语言。
|
|
1416
|
-
|
|
1417
|
-
组件库(bkui-vue / element-plus)的文案由包内自动联动,宿主无需在 `app.use(bkui)` 时额外配置。
|
|
1418
|
-
|
|
1419
|
-
`setLocale` 只管前端文案。**后端下发的内容(插件名称、插件表单 schema 标签、接口报错)
|
|
1420
|
-
不受它影响**——bkflow 后端按 `blueking_language` Cookie(`zh-cn` / `en`)判定语言,
|
|
1421
|
-
不读 `Accept-Language` 请求头,宿主需自行设置该 Cookie。
|
|
1422
|
-
|
|
1423
|
-
locale 非 `zh-cn` 时本包会改写 bkui-vue 的 `defaultRootConfig.locale` 以覆盖命令式
|
|
1424
|
-
`Message` / `InfoBox`,**影响范围是整个宿主应用**。详见
|
|
1425
|
-
[docs/usage.md 的国际化章节](./docs/usage.md#国际化)。
|
|
1426
|
-
|
|
1427
|
-
进阶用法:
|
|
1428
|
-
|
|
1429
|
-
| API | 用途 |
|
|
1430
|
-
| --- | --- |
|
|
1431
|
-
| `registerMessages(locale, messages, options?)` | 深合并覆盖个别词条,或注册包内没有的新语言 |
|
|
1432
|
-
| `setTranslator(fn)` | 完全接管翻译,桥接宿主已有的 i18n;返回 `undefined` 时回落包内词条 |
|
|
1433
|
-
| `getLocale()` | 读取当前语言 |
|
|
1434
|
-
|
|
1435
|
-
注册新语言时可一并提供 bkui-vue 语言包:
|
|
1436
|
-
|
|
1437
|
-
```typescript
|
|
1438
|
-
import { registerMessages } from '@blueking/bkflow-canvas-editor';
|
|
1439
|
-
import jaMessages from './ja';
|
|
1440
|
-
import { jp } from 'bkui-vue/lib/locale';
|
|
1441
|
-
|
|
1442
|
-
registerMessages('ja', jaMessages, { bkuiLocale: jp });
|
|
1443
|
-
```
|
|
1444
|
-
|
|
1445
1405
|
## License
|
|
1446
1406
|
|
|
1447
1407
|
MIT
|
package/dist/advanced.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./context-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./context-iqnF_HqS.cjs");exports.PLUGIN_GROUP_ICON_MAP=e.PLUGIN_GROUP_ICON_MAP;exports.SOPS_PLUGIN_GROUP_NAME=e.SOPS_PLUGIN_GROUP_NAME;exports.provideVariableInputCreateVariable=e.provideVariableInputCreateVariable;exports.resolveSopsPluginSources=e.resolveSopsPluginSources;exports.useFlowApi=e.useFlowApi;exports.useVariableInputCreateVariable=e.useVariableInputCreateVariable;exports.withSopsPluginGroup=e.withSopsPluginGroup;
|
package/dist/advanced.esm.js
CHANGED