@axewo/fin-locale 2.0.12 → 3.0.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.
Files changed (67) hide show
  1. package/README.md +15 -16
  2. package/dist/create-i18n.cjs +1 -0
  3. package/dist/create-i18n.mjs +77 -0
  4. package/dist/index.cjs +1 -1
  5. package/dist/index.mjs +14 -10
  6. package/dist/locales/en/index.cjs +1 -0
  7. package/dist/{index6.mjs → locales/en/index.mjs} +1 -1
  8. package/dist/locales/en/platform.cjs +1 -0
  9. package/dist/locales/en/platform.mjs +78 -0
  10. package/dist/locales/en.cjs +1 -0
  11. package/dist/locales/en.mjs +4 -0
  12. package/dist/locales/zh-CN/index.cjs +1 -0
  13. package/dist/{index5.mjs → locales/zh-CN/index.mjs} +1 -1
  14. package/dist/locales/zh-CN/platform.cjs +1 -0
  15. package/dist/locales/zh-CN/platform.mjs +78 -0
  16. package/dist/locales/zh-CN.cjs +1 -0
  17. package/dist/locales/zh-CN.mjs +4 -0
  18. package/dist/types/create-i18n.d.ts +13 -4
  19. package/dist/types/create-i18n.d.ts.map +1 -1
  20. package/dist/types/entries/en.d.ts +3 -0
  21. package/dist/types/entries/en.d.ts.map +1 -0
  22. package/dist/types/entries/zh-CN.d.ts +3 -0
  23. package/dist/types/entries/zh-CN.d.ts.map +1 -0
  24. package/dist/types/index.d.ts +3 -3
  25. package/dist/types/index.d.ts.map +1 -1
  26. package/dist/types/{lang/zh-CN → locales/en}/dashboard-additions.d.ts.map +1 -1
  27. package/dist/types/{lang/zh-CN → locales/en}/dashboard-core-additions.d.ts.map +1 -1
  28. package/dist/types/{lang/zh-CN → locales/en}/formula-additions.d.ts.map +1 -1
  29. package/dist/types/{lang/zh-CN → locales/en}/index.d.ts.map +1 -1
  30. package/dist/types/locales/en/platform.d.ts +78 -0
  31. package/dist/types/locales/en/platform.d.ts.map +1 -0
  32. package/dist/types/{lang/zh-CN → locales/en}/ui-additions.d.ts.map +1 -1
  33. package/dist/types/locales/en.d.ts +4 -0
  34. package/dist/types/locales/zh-CN/dashboard-additions.d.ts.map +1 -0
  35. package/dist/types/{lang/en → locales/zh-CN}/dashboard-core-additions.d.ts.map +1 -1
  36. package/dist/types/locales/zh-CN/formula-additions.d.ts.map +1 -0
  37. package/dist/types/{lang/en → locales/zh-CN}/index.d.ts.map +1 -1
  38. package/dist/types/locales/zh-CN/platform.d.ts +78 -0
  39. package/dist/types/locales/zh-CN/platform.d.ts.map +1 -0
  40. package/dist/types/locales/zh-CN/ui-additions.d.ts.map +1 -0
  41. package/dist/types/locales/zh-CN.d.ts +4 -0
  42. package/package.json +24 -2
  43. package/dist/index2.cjs +0 -1
  44. package/dist/index2.mjs +0 -57
  45. package/dist/index5.cjs +0 -1
  46. package/dist/index6.cjs +0 -1
  47. package/dist/types/lang/en/dashboard-additions.d.ts.map +0 -1
  48. package/dist/types/lang/en/formula-additions.d.ts.map +0 -1
  49. package/dist/types/lang/en/ui-additions.d.ts.map +0 -1
  50. /package/dist/{index4.cjs → locales/en/formula-additions.cjs} +0 -0
  51. /package/dist/{index4.mjs → locales/en/formula-additions.mjs} +0 -0
  52. /package/dist/{index8.cjs → locales/en/ui-additions.cjs} +0 -0
  53. /package/dist/{index8.mjs → locales/en/ui-additions.mjs} +0 -0
  54. /package/dist/{index3.cjs → locales/zh-CN/formula-additions.cjs} +0 -0
  55. /package/dist/{index3.mjs → locales/zh-CN/formula-additions.mjs} +0 -0
  56. /package/dist/{index7.cjs → locales/zh-CN/ui-additions.cjs} +0 -0
  57. /package/dist/{index7.mjs → locales/zh-CN/ui-additions.mjs} +0 -0
  58. /package/dist/types/{lang → locales}/en/dashboard-additions.d.ts +0 -0
  59. /package/dist/types/{lang → locales}/en/dashboard-core-additions.d.ts +0 -0
  60. /package/dist/types/{lang → locales}/en/formula-additions.d.ts +0 -0
  61. /package/dist/types/{lang → locales}/en/index.d.ts +0 -0
  62. /package/dist/types/{lang → locales}/en/ui-additions.d.ts +0 -0
  63. /package/dist/types/{lang → locales}/zh-CN/dashboard-additions.d.ts +0 -0
  64. /package/dist/types/{lang → locales}/zh-CN/dashboard-core-additions.d.ts +0 -0
  65. /package/dist/types/{lang → locales}/zh-CN/formula-additions.d.ts +0 -0
  66. /package/dist/types/{lang → locales}/zh-CN/index.d.ts +0 -0
  67. /package/dist/types/{lang → locales}/zh-CN/ui-additions.d.ts +0 -0
package/README.md CHANGED
@@ -1,26 +1,25 @@
1
1
  # @axewo/fin-locale
2
2
 
3
- > Fin UI 国际化多语言语言包
3
+ Fin UI 与微前端统一的多语言入口,基于 vue-i18n,内置简体中文和英文。应用只需维护业务语言映射。
4
4
 
5
- ## 📦 安装
5
+ ```sh
6
+ pnpm add @axewo/fin-locale vue-i18n
7
+ ```
6
8
 
7
- ```bash
8
- # 使用 pnpm
9
- pnpm add @axewo/fin-locale
9
+ ```ts
10
+ import { installFinI18n, useFinLocale } from '@axewo/fin-locale'
11
+ import messages from './locales'
10
12
 
11
- # 使用 npm
12
- npm install @axewo/fin-locale
13
+ // 每个 Vue App 独立注入,先于根组件 setup。
14
+ installFinI18n(app, { locale: 'zh-CN', messages })
13
15
 
14
- # 使用 yarn
15
- yarn add @axewo/fin-locale
16
+ // 在组件 setup 中使用。
17
+ const { t, locale, setLocale } = useFinLocale()
18
+ setLocale('en')
16
19
  ```
17
20
 
18
- ## 🚀 使用说明
19
-
20
- ```typescript
21
- import { ... } from '@axewo/fin-locale'
22
- ```
21
+ 业务 `messages` 为 `{ 'zh-CN': {...}, en: {...} }`,递归合并公共词条;业务命名空间建议独立于 `fin.*`。使用 fin-ui 的 `FinLocaleProvider` 让 Fin UI 和 Element Plus 跟随同一语言与尺寸。
23
22
 
24
- ## 📄 License
23
+ 包根导出 `zhCN`、`en`、`createFinI18n`、`installFinI18n`、`useFinLocale`、`normalizeFinLocale`、`translateFinBuiltin`、`useFinText`。规范子路径为 `/locales/zh-CN` 和 `/locales/en`,旧 `/lang/zh-CN`、`/lang/en` 保留兼容;源码只维护 `src/locales`。
25
24
 
26
- [MIT](./LICENSE)
25
+ `useFinText` 供可独立使用的公共展示组件读取当前 App 的翻译,未注入时回退中文;业务页面应使用 `useFinLocale`。非 Vue 启动边界使用 `translateFinBuiltin(key, locale)`,不创建共享全局实例。
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("vue-i18n"),L=require("vue"),o=require("@axewo/fin-core/locale"),F=require("./locales/zh-CN/index.cjs"),p=require("./locales/zh-CN/formula-additions.cjs"),M=require("./locales/en/index.cjs"),_=require("./locales/en/formula-additions.cjs"),d=require("./locales/zh-CN/platform.cjs"),I=require("./locales/en/platform.cjs");function r(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const i=o.mergeLocaleMessages(o.mergeLocaleMessages(F,p),d),a=o.mergeLocaleMessages(o.mergeLocaleMessages(M,_),I);function g(e,t="zh-CN"){let n=o.normalizeFinLocale(t)==="en"?a:i;for(const s of e.split("."))n=r(n)?n[s]:void 0;return typeof n=="string"?n:e}function z(e){const t={"zh-CN":o.mergeLocaleMessages({},i),en:o.mergeLocaleMessages({},a)};if(!r(e))return t;for(const[n,s]of Object.entries(e))r(s)&&(t[n]=t[n]?o.mergeLocaleMessages(t[n],s):o.mergeLocaleMessages({},s));return t}function f(e){const{messages:t,...n}=e||{};return u.createI18n({locale:"zh-CN",fallbackLocale:"zh-CN",legacy:!1,...n,messages:z(t)})}function m(){const{t:e,locale:t}=u.useI18n({useScope:"global"});return{t:e,locale:t,setLocale:n=>{t.value=o.normalizeFinLocale(n)}}}function b(){var n;const e=(n=L.getCurrentInstance())==null?void 0:n.appContext.app;if(!(e!=null&&e.__VUE_I18N_SYMBOL__))return s=>g(s);const{t}=m();return s=>t(s)}function q(e,t){const n=e,s=n.__VUE_I18N_SYMBOL__;if(s){const l=n._context.provides[s];if(l)return l}const c=f(t);return e.use(c),c}Object.defineProperty(exports,"normalizeFinLocale",{enumerable:!0,get:()=>o.normalizeFinLocale});exports.createFinI18n=f;exports.en=a;exports.installFinI18n=q;exports.translateFinBuiltin=g;exports.useFinLocale=m;exports.useFinText=b;exports.zhCN=i;
@@ -0,0 +1,77 @@
1
+ import { createI18n as m, useI18n as u } from "vue-i18n";
2
+ import { getCurrentInstance as p } from "vue";
3
+ import { mergeLocaleMessages as r, normalizeFinLocale as c } from "@axewo/fin-core/locale";
4
+ import { normalizeFinLocale as U } from "@axewo/fin-core/locale";
5
+ import g from "./locales/zh-CN/index.mjs";
6
+ import _ from "./locales/zh-CN/formula-additions.mjs";
7
+ import z from "./locales/en/index.mjs";
8
+ import h from "./locales/en/formula-additions.mjs";
9
+ import C from "./locales/zh-CN/platform.mjs";
10
+ import F from "./locales/en/platform.mjs";
11
+ function s(e) {
12
+ return typeof e == "object" && e !== null && !Array.isArray(e);
13
+ }
14
+ const l = r(r(g, _), C), f = r(r(z, h), F);
15
+ function N(e, n = "zh-CN") {
16
+ let t = c(n) === "en" ? f : l;
17
+ for (const o of e.split(".")) t = s(t) ? t[o] : void 0;
18
+ return typeof t == "string" ? t : e;
19
+ }
20
+ function I(e) {
21
+ const n = {
22
+ "zh-CN": r({}, l),
23
+ en: r({}, f)
24
+ };
25
+ if (!s(e))
26
+ return n;
27
+ for (const [t, o] of Object.entries(e))
28
+ s(o) && (n[t] = n[t] ? r(n[t], o) : r({}, o));
29
+ return n;
30
+ }
31
+ function L(e) {
32
+ const { messages: n, ...t } = e || {};
33
+ return m({
34
+ locale: "zh-CN",
35
+ fallbackLocale: "zh-CN",
36
+ legacy: !1,
37
+ ...t,
38
+ messages: I(n)
39
+ });
40
+ }
41
+ function d() {
42
+ const { t: e, locale: n } = u({ useScope: "global" });
43
+ return {
44
+ t: e,
45
+ locale: n,
46
+ setLocale: (t) => {
47
+ n.value = c(t);
48
+ }
49
+ };
50
+ }
51
+ function v() {
52
+ var t;
53
+ const e = (t = p()) == null ? void 0 : t.appContext.app;
54
+ if (!(e != null && e.__VUE_I18N_SYMBOL__)) return (o) => N(o);
55
+ const { t: n } = d();
56
+ return (o) => n(o);
57
+ }
58
+ function E(e, n) {
59
+ const t = e, o = t.__VUE_I18N_SYMBOL__;
60
+ if (o) {
61
+ const a = t._context.provides[o];
62
+ if (a)
63
+ return a;
64
+ }
65
+ const i = L(n);
66
+ return e.use(i), i;
67
+ }
68
+ export {
69
+ L as createFinI18n,
70
+ f as en,
71
+ E as installFinI18n,
72
+ U as normalizeFinLocale,
73
+ N as translateFinBuiltin,
74
+ d as useFinLocale,
75
+ v as useFinText,
76
+ l as zhCN
77
+ };
package/dist/index.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index2.cjs"),n=require("./index3.cjs"),i=require("./index4.cjs");exports.createFinI18n=e.createFinI18n;exports.en=e.en;exports.installFinI18n=e.installFinI18n;exports.useFinLocale=e.useFinLocale;exports.zhCN=e.zhCN;exports.zhCNFormulaAdditions=n;exports.enFormulaAdditions=i;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./create-i18n.cjs"),n=require("./locales/zh-CN/formula-additions.cjs"),i=require("./locales/en/formula-additions.cjs"),t=require("@axewo/fin-core/locale");exports.createFinI18n=e.createFinI18n;exports.en=e.en;exports.installFinI18n=e.installFinI18n;exports.translateFinBuiltin=e.translateFinBuiltin;exports.useFinLocale=e.useFinLocale;exports.useFinText=e.useFinText;exports.zhCN=e.zhCN;exports.zhCNFormulaAdditions=n;exports.enFormulaAdditions=i;Object.defineProperty(exports,"normalizeFinLocale",{enumerable:!0,get:()=>t.normalizeFinLocale});
package/dist/index.mjs CHANGED
@@ -1,12 +1,16 @@
1
- import { createFinI18n as n, en as a, installFinI18n as r, useFinLocale as t, zhCN as i } from "./index2.mjs";
2
- import { default as d } from "./index3.mjs";
3
- import { default as f } from "./index4.mjs";
1
+ import { createFinI18n as o, en as i, installFinI18n as t, translateFinBuiltin as a, useFinLocale as r, useFinText as l, zhCN as s } from "./create-i18n.mjs";
2
+ import { default as m } from "./locales/zh-CN/formula-additions.mjs";
3
+ import { default as d } from "./locales/en/formula-additions.mjs";
4
+ import { normalizeFinLocale as x } from "@axewo/fin-core/locale";
4
5
  export {
5
- n as createFinI18n,
6
- a as en,
7
- f as enFormulaAdditions,
8
- r as installFinI18n,
9
- t as useFinLocale,
10
- i as zhCN,
11
- d as zhCNFormulaAdditions
6
+ o as createFinI18n,
7
+ i as en,
8
+ d as enFormulaAdditions,
9
+ t as installFinI18n,
10
+ x as normalizeFinLocale,
11
+ a as translateFinBuiltin,
12
+ r as useFinLocale,
13
+ l as useFinText,
14
+ s as zhCN,
15
+ m as zhCNFormulaAdditions
12
16
  };
@@ -0,0 +1 @@
1
+ "use strict";const e=require("./ui-additions.cjs"),a={fin:{upload:e.fin.upload,common:{confirm:"Confirm",cancel:"Cancel",close:"Close",save:"Save",submit:"Submit",reset:"Reset",search:"Search",refresh:"Refresh",loading:"Loading...",noData:"No Data",operation:"Operation",more:"More",index:"No.",edit:"Edit",delete:"Delete",view:"View",add:"Add",total:"Total",undo:"Undo",editMode:"Edit Mode",viewMode:"View Mode",withdraw:"Withdraw",yes:"Yes",no:"No",confirmDelete:"Are you sure you want to delete this record?",confirmDeleteTitle:"Delete Confirmation",deleteSuccess:"Deleted successfully",deleteFailed:"Delete failed",deleteConfirm:"Confirm Delete",saveSuccess:"Saved successfully",saveFailed:"Save failed",retry:"Retry",loadFailed:"Load failed",export:"Export",columnSettings:"Column Settings",requestFailed:"Request failed, please try again later",viewDetail:"Details"},finCopy:{copyEmptyContent:"Nothing to copy",copySuccess:"Copied successfully",copyFailed:"Copy failed"},copy:{action:"Copy",noContent:"Nothing to copy",success:"Copied successfully",failed:"Copy failed",copyEmptyContent:"Nothing to copy",copySuccess:"Copied successfully",copyFailed:"Copy failed"},finForm:{submit:"Submit",reset:"Reset",query:"Search",cancel:"Cancel",expand:"Expand",collapse:"Collapse",selectPlaceholder:"Please select {label}",inputPlaceholder:"Please enter {label}",dateRangeStartPlaceholder:"Start date",dateRangeEndPlaceholder:"End date",yes:"Yes",no:"No",validationFailed:"Validation failed",formRefUnavailable:"Form ref not available",submitFailed:"Submission failed, please try again later",validationSummary:"Form validation failed, please check {count} fields",required:"{label} is required"},form:{...e.fin.form,submit:"Submit",reset:"Reset",query:"Search",cancel:"Cancel",expand:"Expand",collapse:"Collapse",pleaseSelect:"Please select {label}",selectPlaceholder:"Please select",pleaseInput:"Please enter {label}",inputPlaceholder:"Please enter {label}",dateRangeStartPlaceholder:"Start date",dateRangeEndPlaceholder:"End date",startTime:"Start time",endTime:"End time",yes:"Yes",no:"No",validationFailed:"Validation failed",formRefUnavailable:"Form ref not available",submitFailed:"Submission failed, please try again later",validationSummary:"Form validation failed, please check {count} fields",required:"{label} is required"},finSelect:{searchPlaceholder:"Search by keyword",selectPlaceholder:"Please select",noData:"No data",loading:"Loading...",loadMore:"Load more",allLoaded:"All data loaded"},select:{searchPlaceholder:"Search by keyword",selectPlaceholder:"Please select",placeholder:"Please select",noData:"No data",loading:"Loading...",loadMore:"Load more",allLoaded:"All data loaded"},pageHeader:{back:"Back"},langInput:{...e.fin.langInput,pleaseInput:"Please enter"},mathEditor:{title:"Formula editor",subtitle:"Drag or click resources; edit visually or as source",searchPlaceholder:"Search parameters, indicators, or functions",searchReferences:"Search parameters or indicators",searchFunctions:"Search functions",parameters:"Parameters",indicators:"Indicators",functions:"Functions",resources:"References",tools:"Functions and constants",inspector:"Inspector",toolbar:"Formula editor toolbar",operators:"Operators",constants:"Constants",addConstant:"Add to expression",invalidConstant:"Enter a valid decimal number",constantOutOfRange:"Constant is outside the allowed range",structureActions:"Structure actions",groupExpression:"Add parentheses",ungroupExpression:"Remove parentheses",collapseReferences:"Collapse references",expandReferences:"Expand references",collapseTools:"Collapse functions and constants",expandTools:"Expand functions and constants",unary:"Unary",binary:"Binary",parameterCount:"{count} parameters",signatureCount:"{count} signatures",noFunctions:"No matching functions",operatorCategory:{arithmetic:"Arithmetic",comparison:"Comparison",logical:"Logical"},functionCategory:{all:"All",condition:"Conditional",aggregation:"Aggregation",math:"Math",string:"String",date:"Date",statistics:"Statistics"},undo:"Undo",redo:"Redo",reset:"Reset",clear:"Clear",visualMode:"Visual",sourceMode:"Source",canvas:"Formula canvas",panCanvasHint:"Drag the canvas or use arrow keys to pan; horizontal scrolling also navigates long formulas",emptyHint:"Add a parameter, indicator, or function",loading:"Loading resources...",loadFailed:"Failed to load resources",retry:"Retry",noResources:"No matching resources",ungroupedReferences:"Other",loadMore:"Load more",placeholder:"Required",deleteNode:"Delete node",nodeActions:"Node actions",insertLeft:"Insert on the left",insertRight:"Insert on the right",addPrefixOperator:"Add prefix operator",addPredicateOperator:"Add condition",removeOperator:"Remove current operation",keepLeftOperand:"Remove operation and keep left",keepRightOperand:"Remove operation and keep right",predicateCategory:{collection:"Collection tests",range:"Range tests",null:"Null tests"},changeOperator:"Change operator",backToNodeActions:"Back to node actions",revertSource:"Restore valid formula",externalConflict:"The external formula changed. Choose which version to keep.",keepLocal:"Keep draft",useExternal:"Use external",validationPassed:"Validation passed",validationErrors:"{count} errors",validationWarnings:"{count} warnings",selection:"Selected node",nodeType:"Node type",noSelection:"Select a node in the canvas to inspect it",diagnostics:"Diagnostics",noDiagnostics:"No issues found",formulaText:"Valid formula text",showFullFormula:"View full formula",hideFullFormula:"Hide full formula",sourceJson:"View source",copySourceJson:"Copy source JSON",viewTools:"Canvas view controls",zoomIn:"Zoom in",zoomOut:"Zoom out",resetView:"Reset canvas view",lastValidFormulaHint:"The source draft is invalid; showing and copying the last valid formula",showDiagnostics:"Show validation details",hideDiagnostics:"Hide validation details",clearSearch:"Clear search",filterLoadedResources:"Filter loaded resources",viewResourceDetail:"View {name} details",resourceDetail:"{name} details",closeResourceDetail:"Close resource details",resourceDisabled:"Disabled",resourceMissing:"Unavailable",resourceForbidden:"No access",resourceIncompatible:"Incompatible version",resourceId:"Resource ID",sourceId:"Source ID",version:"Version",returnType:"Return type",description:"Description",fieldPath:"Field path",resourceStatus:"Resource status",signatureRules:"Signatures",examples:"Examples",operationSyntax:"Operation syntax",operatorSymbol:"Operator",operandTypes:"Operand types",nullable:"Nullable",unit:"Unit",dynamicInference:"Dynamically inferred",cannotDisplay:"Unable to display",clearCollectionValue:"Clear collection value",deleteCollectionValue:"Delete collection value",addCollectionValue:"Add collection value",addFunctionArgument:"Add function argument",currentReplacementTarget:"Current replacement target",replaceCurrentNode:"Replace current node",replacing:"Replacing",replace:"Replace",clearUnavailableResource:"Clear unavailable resource",replacingResource:"Replacing “{name}”",cancelReplacement:"Cancel replacement",confirmReplacement:"Confirm replacement",replacementDescription:"Replacing this node removes all nested expressions. Continue?",replacementWarning:"Only the selected node will be replaced. Its nested expressions cannot be restored.",continueReplacement:"Continue replacement",commandBlocked:{targetRequired:"Select a target position in the formula first",targetNotFound:"The target node no longer exists; select it again",resourceUnavailable:"This resource is unavailable",replacementRequired:"This node already has content; choose Replace first",replacementUnsupported:"Operators cannot replace nodes; choose a field, parameter, or function",resourceTypeIncompatible:"The resource type is incompatible with this argument slot",functionNotFound:"The function definition does not exist or is not loaded",functionSignatureNotFound:"No function signature matches the current arguments",functionSignatureAmbiguous:"Multiple function signatures match; choose one explicitly",functionArgumentLoss:"This operation would discard existing function arguments",functionArgumentLimit:"The function has reached its argument limit",functionArgumentRequired:"A required function argument cannot be deleted",inValueRequired:"A collection condition must keep at least one value slot",editorLocked:"The editor cannot be modified"}},validation:{...e.fin.validation,required:"Cannot be empty",format:"Invalid format",min:"Cannot be less than",max:"Cannot be greater than",failed:"Validation failed"},crud:{...e.fin.crud,addSuccess:"Added successfully",editSuccess:"Updated successfully",addFailed:"Add failed",editFailed:"Update failed",columnSettings:{showColumns:"Show Columns",save:"Save Settings"}}}};module.exports=a;
@@ -1,4 +1,4 @@
1
- import e from "./index8.mjs";
1
+ import e from "./ui-additions.mjs";
2
2
  const o = {
3
3
  fin: {
4
4
  upload: e.fin.upload,
@@ -0,0 +1 @@
1
+ "use strict";const e={fin:{shell:{closePopover:"Close popover",expand:"Expand sidebar",collapse:"Collapse sidebar",search:"Search menus",searchPlaceholder:"Search menus and apps…",searchTitle:"Menu search",noResults:"No matching menus",notifications:"Notifications",noMessages:"Message service is not connected",messageHint:"Notifications will appear here after the service is connected.",profile:"My profile",exiting:"Confirming sign out…",closeTabMenu:"Close tab menu",leftTabs:"Scroll tabs left",rightTabs:"Scroll tabs right",openedPages:"Open pages",moreTabs:"More tab actions",tabMenu:"Tab actions",refresh:"Refresh page",close:"Close current",closeOthers:"Close others",closeLeft:"Close left",closeRight:"Close right",closeAll:"Close all business pages",mainNav:"Main navigation",ready:"Workspace is ready",closeTab:"Close",pageLoading:"Loading page…",pageFailed:"Page failed to load",reload:"Reload"},errors:{unauthenticated:"Your session has expired. Please sign in again.",forbidden:"403: You do not have permission for this action.",timeout:"The operation timed out. Please try again.",network:"Connection failed. Please check your network.",unknown:"The operation failed. Please try again or contact support.",cancelled:"Operation cancelled"},auth:{independent:"Standalone mode",login:"Sign in",logout:"Sign out",username:"Username",password:"Password",required:"Sign in to access business features.",devSettings:"Development settings",token:"Test token",verify:"Verify and apply",clear:"Clear credentials",close:"Close",configured:"Credentials configured",unconfigured:"No credentials configured",memoryHint:"Credentials are stored in memory and cleared when the page reloads.",developmentStorageHint:"Development credentials are stored locally and validated on reload. Clear credentials or sign out to remove them.",verifyHint:"User and permissions are updated only after the session endpoint validates the token.",saved:"Credentials verified",cleared:"Credentials cleared"},micro:{connected:"Connected to host",disconnected:"Host unavailable",workspace:"Workspace",language:"Language",standalone:"Standalone mode",loading:"Starting application, please wait…",retry:"Retry startup",startupFailed:"Application failed to start",startupCancelled:"Startup was cancelled. You can retry."}}};module.exports=e;
@@ -0,0 +1,78 @@
1
+ const e = {
2
+ fin: {
3
+ shell: {
4
+ closePopover: "Close popover",
5
+ expand: "Expand sidebar",
6
+ collapse: "Collapse sidebar",
7
+ search: "Search menus",
8
+ searchPlaceholder: "Search menus and apps…",
9
+ searchTitle: "Menu search",
10
+ noResults: "No matching menus",
11
+ notifications: "Notifications",
12
+ noMessages: "Message service is not connected",
13
+ messageHint: "Notifications will appear here after the service is connected.",
14
+ profile: "My profile",
15
+ exiting: "Confirming sign out…",
16
+ closeTabMenu: "Close tab menu",
17
+ leftTabs: "Scroll tabs left",
18
+ rightTabs: "Scroll tabs right",
19
+ openedPages: "Open pages",
20
+ moreTabs: "More tab actions",
21
+ tabMenu: "Tab actions",
22
+ refresh: "Refresh page",
23
+ close: "Close current",
24
+ closeOthers: "Close others",
25
+ closeLeft: "Close left",
26
+ closeRight: "Close right",
27
+ closeAll: "Close all business pages",
28
+ mainNav: "Main navigation",
29
+ ready: "Workspace is ready",
30
+ closeTab: "Close",
31
+ pageLoading: "Loading page…",
32
+ pageFailed: "Page failed to load",
33
+ reload: "Reload"
34
+ },
35
+ errors: {
36
+ unauthenticated: "Your session has expired. Please sign in again.",
37
+ forbidden: "403: You do not have permission for this action.",
38
+ timeout: "The operation timed out. Please try again.",
39
+ network: "Connection failed. Please check your network.",
40
+ unknown: "The operation failed. Please try again or contact support.",
41
+ cancelled: "Operation cancelled"
42
+ },
43
+ auth: {
44
+ independent: "Standalone mode",
45
+ login: "Sign in",
46
+ logout: "Sign out",
47
+ username: "Username",
48
+ password: "Password",
49
+ required: "Sign in to access business features.",
50
+ devSettings: "Development settings",
51
+ token: "Test token",
52
+ verify: "Verify and apply",
53
+ clear: "Clear credentials",
54
+ close: "Close",
55
+ configured: "Credentials configured",
56
+ unconfigured: "No credentials configured",
57
+ memoryHint: "Credentials are stored in memory and cleared when the page reloads.",
58
+ developmentStorageHint: "Development credentials are stored locally and validated on reload. Clear credentials or sign out to remove them.",
59
+ verifyHint: "User and permissions are updated only after the session endpoint validates the token.",
60
+ saved: "Credentials verified",
61
+ cleared: "Credentials cleared"
62
+ },
63
+ micro: {
64
+ connected: "Connected to host",
65
+ disconnected: "Host unavailable",
66
+ workspace: "Workspace",
67
+ language: "Language",
68
+ standalone: "Standalone mode",
69
+ loading: "Starting application, please wait…",
70
+ retry: "Retry startup",
71
+ startupFailed: "Application failed to start",
72
+ startupCancelled: "Startup was cancelled. You can retry."
73
+ }
74
+ }
75
+ };
76
+ export {
77
+ e as default
78
+ };
@@ -0,0 +1 @@
1
+ "use strict";const e=require("../create-i18n.cjs");module.exports=e.en;
@@ -0,0 +1,4 @@
1
+ import { en as f } from "../create-i18n.mjs";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1 @@
1
+ "use strict";const e=require("./ui-additions.cjs"),a={fin:{upload:e.fin.upload,common:{confirm:"确认",cancel:"取消",close:"关闭",save:"保存",submit:"提交",reset:"重置",search:"搜索",refresh:"刷新",loading:"加载中...",noData:"暂无数据",operation:"操作",more:"更多",index:"序号",edit:"编辑",delete:"删除",view:"查看",add:"新增",total:"合计",undo:"撤回",editMode:"编辑模式",viewMode:"查看模式",withdraw:"撤回",yes:"是",no:"否",confirmDelete:"确认删除该条记录吗?",confirmDeleteTitle:"删除确认",deleteSuccess:"删除成功",deleteFailed:"删除失败",deleteConfirm:"确认删除",saveSuccess:"保存成功",saveFailed:"保存失败",retry:"重试",loadFailed:"加载失败",export:"导出",columnSettings:"列设置",requestFailed:"请求失败,请稍后重试",viewDetail:"详情"},finCopy:{copyEmptyContent:"没有可复制的内容",copySuccess:"复制成功",copyFailed:"复制失败"},copy:{action:"复制",noContent:"没有可复制的内容",success:"复制成功",failed:"复制失败",copyEmptyContent:"没有可复制的内容",copySuccess:"复制成功",copyFailed:"复制失败"},finForm:{submit:"提交",reset:"重置",query:"查询",cancel:"取消",expand:"展开",collapse:"收起",selectPlaceholder:"请选择{label}",inputPlaceholder:"请输入{label}",dateRangeStartPlaceholder:"开始时间",dateRangeEndPlaceholder:"结束时间",yes:"是",no:"否",validationFailed:"验证失败",formRefUnavailable:"表单引用不可用",submitFailed:"提交失败,请稍后重试",validationSummary:"表单验证失败,请检查 {count} 个字段",required:"{label}为必填项"},form:{...e.fin.form,submit:"提交",reset:"重置",query:"查询",cancel:"取消",expand:"展开",collapse:"收起",pleaseSelect:"请选择{label}",selectPlaceholder:"请选择",pleaseInput:"请输入{label}",inputPlaceholder:"请输入{label}",dateRangeStartPlaceholder:"开始时间",dateRangeEndPlaceholder:"结束时间",startTime:"开始时间",endTime:"结束时间",yes:"是",no:"否",validationFailed:"验证失败",formRefUnavailable:"表单引用不可用",submitFailed:"提交失败,请稍后重试",validationSummary:"表单验证失败,请检查 {count} 个字段",required:"{label}为必填项"},finSelect:{searchPlaceholder:"请输入关键词搜索",selectPlaceholder:"请选择",noData:"无数据",loading:"加载中...",loadMore:"加载更多",allLoaded:"已加载全部"},select:{searchPlaceholder:"请输入关键词搜索",selectPlaceholder:"请选择",placeholder:"请选择",noData:"无数据",loading:"加载中...",loadMore:"加载更多",allLoaded:"已加载全部"},pageHeader:{back:"返回"},langInput:{...e.fin.langInput,pleaseInput:"请输入"},mathEditor:{title:"计算公式",subtitle:"拖入资源或点击添加,支持可视化与源码双向编辑",searchPlaceholder:"搜索参数、指标或函数",searchReferences:"搜索参数或指标",searchFunctions:"搜索函数",parameters:"参数",indicators:"指标",functions:"函数",resources:"引用资源",tools:"函数与常量",inspector:"检查器",toolbar:"公式编辑工具栏",operators:"运算符",constants:"常量",addConstant:"插入常量",invalidConstant:"请输入有效的十进制数值",constantOutOfRange:"常量超出允许范围",structureActions:"结构操作",groupExpression:"添加括号",ungroupExpression:"移除括号",collapseReferences:"折叠引用资源",expandReferences:"展开引用资源",collapseTools:"折叠函数与常量",expandTools:"展开函数与常量",unary:"一元",binary:"二元",parameterCount:"{count} 参数",signatureCount:"{count} 个签名",noFunctions:"没有匹配的函数",operatorCategory:{arithmetic:"算术运算",comparison:"比较运算",logical:"逻辑运算"},functionCategory:{all:"全部",condition:"条件",aggregation:"聚合",math:"数学",string:"字符串",date:"日期",statistics:"统计"},undo:"撤销",redo:"重做",reset:"重置",clear:"清空",visualMode:"可视化",sourceMode:"源码",canvas:"公式画布",panCanvasHint:"拖动画布或使用方向键平移,横向滚轮也可浏览长公式",emptyHint:"从左侧添加参数、指标或函数",loading:"正在加载资源...",loadFailed:"资源加载失败",retry:"重试",noResources:"没有匹配的资源",ungroupedReferences:"其他",loadMore:"加载更多",placeholder:"待补充",deleteNode:"删除节点",nodeActions:"节点操作",insertLeft:"在左侧插入",insertRight:"在右侧插入",addPrefixOperator:"添加前缀运算",addPredicateOperator:"添加条件判断",removeOperator:"移除当前运算",keepLeftOperand:"移除运算并保留左侧",keepRightOperand:"移除运算并保留右侧",predicateCategory:{collection:"集合判断",range:"范围判断",null:"空值判断"},changeOperator:"修改运算符",backToNodeActions:"返回节点操作",revertSource:"恢复有效公式",externalConflict:"外部公式已更新,请选择要保留的版本。",keepLocal:"保留当前草稿",useExternal:"使用外部版本",validationPassed:"校验通过",validationErrors:"{count} 个错误",validationWarnings:"{count} 个提示",selection:"当前节点",nodeType:"节点类型",noSelection:"选择画布中的节点以查看详情",diagnostics:"校验结果",noDiagnostics:"未发现问题",formulaText:"有效公式文本",showFullFormula:"查看完整公式",hideFullFormula:"收起完整公式",sourceJson:"查看源码",copySourceJson:"复制源码 JSON",viewTools:"画布视图工具",zoomIn:"放大画布",zoomOut:"缩小画布",resetView:"复位画布视图",lastValidFormulaHint:"源码草稿有误,当前展示并复制最后一次有效公式",showDiagnostics:"展开校验详情",hideDiagnostics:"收起校验详情",clearSearch:"清空搜索",filterLoadedResources:"筛选已加载内容",viewResourceDetail:"查看{name}详情",resourceDetail:"{name}详情",closeResourceDetail:"关闭资源详情",resourceDisabled:"已停用",resourceMissing:"已失效",resourceForbidden:"无权限",resourceIncompatible:"版本不兼容",resourceId:"资源标识",sourceId:"数据源",version:"版本",returnType:"返回类型",description:"描述",fieldPath:"字段路径",resourceStatus:"资源状态",signatureRules:"参数规则",examples:"示例",operationSyntax:"运算结构",operatorSymbol:"运算符",operandTypes:"操作数类型",nullable:"允许空值",unit:"单位",dynamicInference:"动态推导",cannotDisplay:"无法展示",clearCollectionValue:"清空集合值",deleteCollectionValue:"删除集合值",addCollectionValue:"添加集合值",addFunctionArgument:"添加函数参数",currentReplacementTarget:"当前替换目标",replaceCurrentNode:"替换当前节点",replacing:"替换中",replace:"替换",clearUnavailableResource:"清空失效资源",replacingResource:"正在替换“{name}”",cancelReplacement:"取消替换",confirmReplacement:"确认替换",replacementDescription:"替换后将删除当前节点包含的全部子表达式,是否继续?",replacementWarning:"此操作只替换当前选中的节点,已包含的子表达式无法恢复。",continueReplacement:"继续替换",commandBlocked:{targetRequired:"请先选择公式中的目标位置",targetNotFound:"目标节点已不存在,请重新选择",resourceUnavailable:"当前资源不可用",replacementRequired:"当前节点已有内容,请先选择“替换”",replacementUnsupported:"运算符不能替换节点,请选择字段、参数或函数",resourceTypeIncompatible:"资源类型与当前参数槽不兼容",functionNotFound:"函数定义不存在或尚未加载",functionSignatureNotFound:"没有符合当前参数的函数签名",functionSignatureAmbiguous:"存在多个可用函数签名,请明确选择",functionArgumentLoss:"该操作会丢失已有函数参数",functionArgumentLimit:"函数参数已达到上限",functionArgumentRequired:"必填函数参数不能删除",inValueRequired:"集合条件至少需要保留一个值槽位",editorLocked:"当前编辑器不可修改"}},validation:{...e.fin.validation,required:"不能为空",format:"格式不正确",min:"不能小于",max:"不能大于",failed:"验证失败"},crud:{...e.fin.crud,addSuccess:"新增成功",editSuccess:"编辑成功",addFailed:"新增失败",editFailed:"编辑失败",columnSettings:{showColumns:"显示列",save:"保存配置"}}}};module.exports=a;
@@ -1,4 +1,4 @@
1
- import e from "./index7.mjs";
1
+ import e from "./ui-additions.mjs";
2
2
  const o = {
3
3
  fin: {
4
4
  upload: e.fin.upload,
@@ -0,0 +1 @@
1
+ "use strict";const e={fin:{shell:{closePopover:"关闭弹出菜单",expand:"展开侧栏",collapse:"折叠侧栏",search:"搜索菜单",searchPlaceholder:"搜索菜单、应用…",searchTitle:"菜单搜索",noResults:"未找到匹配的菜单",notifications:"消息通知",noMessages:"尚未接入消息服务",messageHint:"接入后将在这里显示真实的通知消息。",profile:"个人中心",exiting:"正在确认退出…",closeTabMenu:"关闭页签菜单",leftTabs:"向左查看页签",rightTabs:"向右查看页签",openedPages:"已打开页面",moreTabs:"更多页签操作",tabMenu:"页签操作菜单",refresh:"刷新页面",close:"关闭当前",closeOthers:"关闭其他",closeLeft:"关闭左侧",closeRight:"关闭右侧",closeAll:"关闭全部业务页",mainNav:"主导航",ready:"工作空间已就绪",closeTab:"关闭",pageLoading:"页面加载中…",pageFailed:"页面加载失败",reload:"重新加载"},errors:{unauthenticated:"登录已失效,请重新登录",forbidden:"403:无权执行此操作,请联系管理员",timeout:"操作超时,请稍后重试",network:"连接失败,请检查网络后重试",unknown:"操作失败,请稍后重试或联系管理员",cancelled:"操作已取消"},auth:{independent:"独立运行",login:"登录",logout:"退出登录",username:"账号",password:"密码",required:"请登录后访问业务功能",devSettings:"开发设置",token:"测试 Token",verify:"验证并应用",clear:"清除凭据",close:"关闭",configured:"已配置凭据",unconfigured:"未配置凭据",memoryHint:"凭据仅保存在内存,刷新页面后需重新设置。",developmentStorageHint:"开发凭据保存在本地,刷新后自动验证恢复;清除凭据或退出登录时删除。",verifyHint:"验证会话接口成功后才会更新用户与权限。",saved:"凭据已验证",cleared:"凭据已清除"},micro:{connected:"宿主已连接",disconnected:"未连接宿主",workspace:"工作空间",language:"语言",standalone:"独立运行",loading:"正在启动应用,请稍候…",retry:"重试启动",startupFailed:"应用启动失败",startupCancelled:"应用启动已取消,可重试启动"}}};module.exports=e;
@@ -0,0 +1,78 @@
1
+ const e = {
2
+ fin: {
3
+ shell: {
4
+ closePopover: "关闭弹出菜单",
5
+ expand: "展开侧栏",
6
+ collapse: "折叠侧栏",
7
+ search: "搜索菜单",
8
+ searchPlaceholder: "搜索菜单、应用…",
9
+ searchTitle: "菜单搜索",
10
+ noResults: "未找到匹配的菜单",
11
+ notifications: "消息通知",
12
+ noMessages: "尚未接入消息服务",
13
+ messageHint: "接入后将在这里显示真实的通知消息。",
14
+ profile: "个人中心",
15
+ exiting: "正在确认退出…",
16
+ closeTabMenu: "关闭页签菜单",
17
+ leftTabs: "向左查看页签",
18
+ rightTabs: "向右查看页签",
19
+ openedPages: "已打开页面",
20
+ moreTabs: "更多页签操作",
21
+ tabMenu: "页签操作菜单",
22
+ refresh: "刷新页面",
23
+ close: "关闭当前",
24
+ closeOthers: "关闭其他",
25
+ closeLeft: "关闭左侧",
26
+ closeRight: "关闭右侧",
27
+ closeAll: "关闭全部业务页",
28
+ mainNav: "主导航",
29
+ ready: "工作空间已就绪",
30
+ closeTab: "关闭",
31
+ pageLoading: "页面加载中…",
32
+ pageFailed: "页面加载失败",
33
+ reload: "重新加载"
34
+ },
35
+ errors: {
36
+ unauthenticated: "登录已失效,请重新登录",
37
+ forbidden: "403:无权执行此操作,请联系管理员",
38
+ timeout: "操作超时,请稍后重试",
39
+ network: "连接失败,请检查网络后重试",
40
+ unknown: "操作失败,请稍后重试或联系管理员",
41
+ cancelled: "操作已取消"
42
+ },
43
+ auth: {
44
+ independent: "独立运行",
45
+ login: "登录",
46
+ logout: "退出登录",
47
+ username: "账号",
48
+ password: "密码",
49
+ required: "请登录后访问业务功能",
50
+ devSettings: "开发设置",
51
+ token: "测试 Token",
52
+ verify: "验证并应用",
53
+ clear: "清除凭据",
54
+ close: "关闭",
55
+ configured: "已配置凭据",
56
+ unconfigured: "未配置凭据",
57
+ memoryHint: "凭据仅保存在内存,刷新页面后需重新设置。",
58
+ developmentStorageHint: "开发凭据保存在本地,刷新后自动验证恢复;清除凭据或退出登录时删除。",
59
+ verifyHint: "验证会话接口成功后才会更新用户与权限。",
60
+ saved: "凭据已验证",
61
+ cleared: "凭据已清除"
62
+ },
63
+ micro: {
64
+ connected: "宿主已连接",
65
+ disconnected: "未连接宿主",
66
+ workspace: "工作空间",
67
+ language: "语言",
68
+ standalone: "独立运行",
69
+ loading: "正在启动应用,请稍候…",
70
+ retry: "重试启动",
71
+ startupFailed: "应用启动失败",
72
+ startupCancelled: "应用启动已取消,可重试启动"
73
+ }
74
+ }
75
+ };
76
+ export {
77
+ e as default
78
+ };
@@ -0,0 +1 @@
1
+ "use strict";const e=require("../create-i18n.cjs");module.exports=e.zhCN;
@@ -0,0 +1,4 @@
1
+ import { zhCN as f } from "../create-i18n.mjs";
2
+ export {
3
+ f as default
4
+ };
@@ -1,9 +1,15 @@
1
1
  import { I18nOptions, I18n, Composer } from 'vue-i18n';
2
2
  import { App } from 'vue';
3
+ export { normalizeFinLocale, type FinLocale } from '@axewo/fin-core/locale';
3
4
  type MessageTree = Record<string, any>;
4
5
  /** 供工厂和公共导出共同使用的完整内置语言包。 */
5
6
  export declare const zhCN: MessageTree;
6
7
  export declare const en: MessageTree;
8
+ /**
9
+ * Vue 尚未启动时读取公共文案,供启动错误边界和无框架适配器使用;不创建全局 i18n 单例。
10
+ * @returns 找不到键时返回键本身;业务完整插值和复数规则应使用实例的 t。
11
+ */
12
+ export declare function translateFinBuiltin(key: string, locale?: unknown): string;
7
13
  /**
8
14
  * 创建财务组件库国际化实例。
9
15
  *
@@ -18,12 +24,15 @@ export declare function createFinI18n(options?: Partial<I18nOptions>): I18n;
18
24
  export declare function useFinLocale(): {
19
25
  t: Composer['t'];
20
26
  locale: Composer['locale'];
27
+ setLocale: (value: unknown) => void;
21
28
  };
29
+ /** 公共外壳可选消费当前应用的翻译;未安装 i18n 的独立使用场景读取中文内置包,不创建全局实例。 */
30
+ export declare function useFinText(): (key: string) => string;
22
31
  /**
23
- * Install the built-in i18n instance only when the app does not already have
24
- * a vue-i18n plugin. This keeps an application's custom locale configuration
25
- * intact while allowing `app.use(FinUI)` to work out of the box.
32
+ * 当前 App 尚未安装 vue-i18n 时创建并注入内置实例;已安装时复用原实例,不覆盖已有配置。
33
+ * @param app 当前 Vue App,必须在根组件 setup 前调用。
34
+ * @param options 当前应用的语言及业务词条;已有实例时这些选项不会重复应用。
35
+ * @returns 当前 App 独立的 i18n 实例;不创建模块级单例,不改变其他 App。
26
36
  */
27
37
  export declare function installFinI18n(app: App, options?: Partial<I18nOptions>): I18n | undefined;
28
- export {};
29
38
  //# sourceMappingURL=create-i18n.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"create-i18n.d.ts","sourceRoot":"","sources":["../../src/create-i18n.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAuB,KAAK,WAAW,EAAE,KAAK,IAAI,EAAE,KAAK,QAAQ,EAAE,MAAM,UAAU,CAAA;AAC1F,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,KAAK,CAAA;AAM9B,KAAK,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;AAsBtC,4BAA4B;AAC5B,eAAO,MAAM,IAAI,aAAmD,CAAA;AACpE,eAAO,MAAM,EAAE,aAA+C,CAAA;AAyB9D;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAAG,IAAI,CAUlE;AAED;;;GAGG;AACH,wBAAgB,YAAY,IAAI;IAAE,CAAC,EAAE,QAAQ,CAAC,GAAG,CAAC,CAAC;IAAC,MAAM,EAAE,QAAQ,CAAC,QAAQ,CAAC,CAAA;CAAE,CAG/E;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAAG,IAAI,GAAG,SAAS,CAiBzF"}
1
+ {"version":3,"file":"create-i18n.d.ts","sourceRoot":"","sources":["../../src/create-i18n.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAuB,KAAK,WAAW,EAAE,KAAK,IAAI,EAAE,KAAK,QAAQ,EAAE,MAAM,UAAU,CAAA;AAC1F,OAAO,EAAsB,KAAK,GAAG,EAAE,MAAM,KAAK,CAAA;AAGlD,OAAO,EAAE,kBAAkB,EAAE,KAAK,SAAS,EAAE,MAAM,wBAAwB,CAAA;AAQ3E,KAAK,WAAW,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;AAMtC,4BAA4B;AAC5B,eAAO,MAAM,IAAI,EAAE,WAAkG,CAAA;AACrH,eAAO,MAAM,EAAE,EAAE,WAA8F,CAAA;AAE/G;;;GAGG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,GAAE,OAAiB,GAAG,MAAM,CAIlF;AAyBD;;;;;GAKG;AACH,wBAAgB,aAAa,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAAG,IAAI,CAUlE;AAED;;;GAGG;AACH,wBAAgB,YAAY,IAAI;IAC9B,CAAC,EAAE,QAAQ,CAAC,GAAG,CAAC,CAAA;IAChB,MAAM,EAAE,QAAQ,CAAC,QAAQ,CAAC,CAAA;IAC1B,SAAS,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;CACpC,CASA;AAED,uDAAuD;AACvD,wBAAgB,UAAU,IAAI,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAOpD;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,GAAG,IAAI,GAAG,SAAS,CAiBzF"}
@@ -0,0 +1,3 @@
1
+ /** 公开子路径转发完整内置词条,业务优先从包根命名导入 en。 */
2
+ export { en as default } from '../create-i18n';
3
+ //# sourceMappingURL=en.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"en.d.ts","sourceRoot":"","sources":["../../../src/entries/en.ts"],"names":[],"mappings":"AAAA,oCAAoC;AACpC,OAAO,EAAE,EAAE,IAAI,OAAO,EAAE,MAAM,gBAAgB,CAAA"}
@@ -0,0 +1,3 @@
1
+ /** 公开子路径转发完整内置词条,业务优先从包根命名导入 zhCN。 */
2
+ export { zhCN as default } from '../create-i18n';
3
+ //# sourceMappingURL=zh-CN.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"zh-CN.d.ts","sourceRoot":"","sources":["../../../src/entries/zh-CN.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,OAAO,EAAE,IAAI,IAAI,OAAO,EAAE,MAAM,gBAAgB,CAAA"}
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * @axewo/fin-locale - 国际化统一入口
3
3
  */
4
- export { createFinI18n, en, installFinI18n, useFinLocale, zhCN } from './create-i18n';
5
- export { default as zhCNFormulaAdditions } from './lang/zh-CN/formula-additions';
6
- export { default as enFormulaAdditions } from './lang/en/formula-additions';
4
+ export { createFinI18n, en, installFinI18n, useFinLocale, useFinText, zhCN, normalizeFinLocale, translateFinBuiltin, type FinLocale } from './create-i18n';
5
+ export { default as zhCNFormulaAdditions } from './locales/zh-CN/formula-additions';
6
+ export { default as enFormulaAdditions } from './locales/en/formula-additions';
7
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,aAAa,EAAE,EAAE,EAAE,cAAc,EAAE,YAAY,EAAE,IAAI,EAAE,MAAM,eAAe,CAAA;AACrF,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,gCAAgC,CAAA;AAChF,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,6BAA6B,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,aAAa,EAAE,EAAE,EAAE,cAAc,EAAE,YAAY,EAAE,UAAU,EAAE,IAAI,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,KAAK,SAAS,EAAE,MAAM,eAAe,CAAA;AAC1J,OAAO,EAAE,OAAO,IAAI,oBAAoB,EAAE,MAAM,mCAAmC,CAAA;AACnF,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,gCAAgC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"dashboard-additions.d.ts","sourceRoot":"","sources":["../../../../src/lang/zh-CN/dashboard-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAyJC"}
1
+ {"version":3,"file":"dashboard-additions.d.ts","sourceRoot":"","sources":["../../../../src/locales/en/dashboard-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAyJC"}
@@ -1 +1 @@
1
- {"version":3,"file":"dashboard-core-additions.d.ts","sourceRoot":"","sources":["../../../../src/lang/zh-CN/dashboard-core-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAsPC"}
1
+ {"version":3,"file":"dashboard-core-additions.d.ts","sourceRoot":"","sources":["../../../../src/locales/en/dashboard-core-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAqPC"}
@@ -1 +1 @@
1
- {"version":3,"file":"formula-additions.d.ts","sourceRoot":"","sources":["../../../../src/lang/zh-CN/formula-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAoGC"}
1
+ {"version":3,"file":"formula-additions.d.ts","sourceRoot":"","sources":["../../../../src/locales/en/formula-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAoGC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lang/zh-CN/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,wBA+SC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/locales/en/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,wBAgTC"}
@@ -0,0 +1,78 @@
1
+ /** 与中文保持相同的公共键与插值结构。 */
2
+ declare const _default: {
3
+ fin: {
4
+ shell: {
5
+ closePopover: string;
6
+ expand: string;
7
+ collapse: string;
8
+ search: string;
9
+ searchPlaceholder: string;
10
+ searchTitle: string;
11
+ noResults: string;
12
+ notifications: string;
13
+ noMessages: string;
14
+ messageHint: string;
15
+ profile: string;
16
+ exiting: string;
17
+ closeTabMenu: string;
18
+ leftTabs: string;
19
+ rightTabs: string;
20
+ openedPages: string;
21
+ moreTabs: string;
22
+ tabMenu: string;
23
+ refresh: string;
24
+ close: string;
25
+ closeOthers: string;
26
+ closeLeft: string;
27
+ closeRight: string;
28
+ closeAll: string;
29
+ mainNav: string;
30
+ ready: string;
31
+ closeTab: string;
32
+ pageLoading: string;
33
+ pageFailed: string;
34
+ reload: string;
35
+ };
36
+ errors: {
37
+ unauthenticated: string;
38
+ forbidden: string;
39
+ timeout: string;
40
+ network: string;
41
+ unknown: string;
42
+ cancelled: string;
43
+ };
44
+ auth: {
45
+ independent: string;
46
+ login: string;
47
+ logout: string;
48
+ username: string;
49
+ password: string;
50
+ required: string;
51
+ devSettings: string;
52
+ token: string;
53
+ verify: string;
54
+ clear: string;
55
+ close: string;
56
+ configured: string;
57
+ unconfigured: string;
58
+ memoryHint: string;
59
+ developmentStorageHint: string;
60
+ verifyHint: string;
61
+ saved: string;
62
+ cleared: string;
63
+ };
64
+ micro: {
65
+ connected: string;
66
+ disconnected: string;
67
+ workspace: string;
68
+ language: string;
69
+ standalone: string;
70
+ loading: string;
71
+ retry: string;
72
+ startupFailed: string;
73
+ startupCancelled: string;
74
+ };
75
+ };
76
+ };
77
+ export default _default;
78
+ //# sourceMappingURL=platform.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"platform.d.ts","sourceRoot":"","sources":["../../../../src/locales/en/platform.ts"],"names":[],"mappings":"AAAA,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACxB,wBA2EC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ui-additions.d.ts","sourceRoot":"","sources":["../../../../src/lang/zh-CN/ui-additions.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkDhB,CAAA;AAED,eAAe,WAAW,CAAA"}
1
+ {"version":3,"file":"ui-additions.d.ts","sourceRoot":"","sources":["../../../../src/locales/en/ui-additions.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkDhB,CAAA;AAED,eAAe,WAAW,CAAA"}
@@ -0,0 +1,4 @@
1
+ export {}
2
+ import _default from '../entries/en'
3
+ export default _default
4
+ export {}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dashboard-additions.d.ts","sourceRoot":"","sources":["../../../../src/locales/zh-CN/dashboard-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAyJC"}
@@ -1 +1 @@
1
- {"version":3,"file":"dashboard-core-additions.d.ts","sourceRoot":"","sources":["../../../../src/lang/en/dashboard-core-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAqPC"}
1
+ {"version":3,"file":"dashboard-core-additions.d.ts","sourceRoot":"","sources":["../../../../src/locales/zh-CN/dashboard-core-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAsPC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"formula-additions.d.ts","sourceRoot":"","sources":["../../../../src/locales/zh-CN/formula-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAoGC"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lang/en/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,wBAgTC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/locales/zh-CN/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,wBA+SC"}
@@ -0,0 +1,78 @@
1
+ /** 公共平台文案;业务应用只维护自己的业务命名空间。 */
2
+ declare const _default: {
3
+ fin: {
4
+ shell: {
5
+ closePopover: string;
6
+ expand: string;
7
+ collapse: string;
8
+ search: string;
9
+ searchPlaceholder: string;
10
+ searchTitle: string;
11
+ noResults: string;
12
+ notifications: string;
13
+ noMessages: string;
14
+ messageHint: string;
15
+ profile: string;
16
+ exiting: string;
17
+ closeTabMenu: string;
18
+ leftTabs: string;
19
+ rightTabs: string;
20
+ openedPages: string;
21
+ moreTabs: string;
22
+ tabMenu: string;
23
+ refresh: string;
24
+ close: string;
25
+ closeOthers: string;
26
+ closeLeft: string;
27
+ closeRight: string;
28
+ closeAll: string;
29
+ mainNav: string;
30
+ ready: string;
31
+ closeTab: string;
32
+ pageLoading: string;
33
+ pageFailed: string;
34
+ reload: string;
35
+ };
36
+ errors: {
37
+ unauthenticated: string;
38
+ forbidden: string;
39
+ timeout: string;
40
+ network: string;
41
+ unknown: string;
42
+ cancelled: string;
43
+ };
44
+ auth: {
45
+ independent: string;
46
+ login: string;
47
+ logout: string;
48
+ username: string;
49
+ password: string;
50
+ required: string;
51
+ devSettings: string;
52
+ token: string;
53
+ verify: string;
54
+ clear: string;
55
+ close: string;
56
+ configured: string;
57
+ unconfigured: string;
58
+ memoryHint: string;
59
+ developmentStorageHint: string;
60
+ verifyHint: string;
61
+ saved: string;
62
+ cleared: string;
63
+ };
64
+ micro: {
65
+ connected: string;
66
+ disconnected: string;
67
+ workspace: string;
68
+ language: string;
69
+ standalone: string;
70
+ loading: string;
71
+ retry: string;
72
+ startupFailed: string;
73
+ startupCancelled: string;
74
+ };
75
+ };
76
+ };
77
+ export default _default;
78
+ //# sourceMappingURL=platform.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"platform.d.ts","sourceRoot":"","sources":["../../../../src/locales/zh-CN/platform.ts"],"names":[],"mappings":"AAAA,+BAA+B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAC/B,wBA0EC"}
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ui-additions.d.ts","sourceRoot":"","sources":["../../../../src/locales/zh-CN/ui-additions.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkDhB,CAAA;AAED,eAAe,WAAW,CAAA"}
@@ -0,0 +1,4 @@
1
+ export {}
2
+ import _default from '../entries/zh-CN'
3
+ export default _default
4
+ export {}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@axewo/fin-locale",
3
- "version": "2.0.12",
3
+ "version": "3.0.0",
4
4
  "type": "module",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.mjs",
@@ -11,9 +11,31 @@
11
11
  "import": "./dist/index.mjs",
12
12
  "require": "./dist/index.cjs"
13
13
  },
14
- "./lang/*": "./dist/lang/*"
14
+ "./locales/zh-CN": {
15
+ "types": "./dist/types/entries/zh-CN.d.ts",
16
+ "import": "./dist/locales/zh-CN.mjs",
17
+ "require": "./dist/locales/zh-CN.cjs"
18
+ },
19
+ "./locales/en": {
20
+ "types": "./dist/types/entries/en.d.ts",
21
+ "import": "./dist/locales/en.mjs",
22
+ "require": "./dist/locales/en.cjs"
23
+ },
24
+ "./lang/zh-CN": {
25
+ "types": "./dist/types/entries/zh-CN.d.ts",
26
+ "import": "./dist/locales/zh-CN.mjs",
27
+ "require": "./dist/locales/zh-CN.cjs"
28
+ },
29
+ "./lang/en": {
30
+ "types": "./dist/types/entries/en.d.ts",
31
+ "import": "./dist/locales/en.mjs",
32
+ "require": "./dist/locales/en.cjs"
33
+ }
15
34
  },
16
35
  "sideEffects": false,
36
+ "dependencies": {
37
+ "@axewo/fin-core": "3.0.0"
38
+ },
17
39
  "files": [
18
40
  "dist",
19
41
  "README.md"
package/dist/index2.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("vue-i18n"),g=require("./index5.cjs"),d=require("./index3.cjs"),m=require("./index6.cjs"),I=require("./index4.cjs");function r(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function i(e,n){const t={...e};for(const[s,o]of Object.entries(n))t[s]=r(t[s])&&r(o)?i(t[s],o):o;return t}const a=i(g,d),l=i(m,I);function b(e){const n={"zh-CN":a,en:l};if(!r(e))return n;for(const[t,s]of Object.entries(e))r(s)&&(n[t]=n[t]?i(n[t],s):s);return n}function f(e){const{messages:n,...t}=e||{};return u.createI18n({locale:"zh-CN",fallbackLocale:"zh-CN",legacy:!1,...t,messages:b(n)})}function y(){const{t:e,locale:n}=u.useI18n({useScope:"global"});return{t:e,locale:n}}function _(e,n){const t=e,s=t.__VUE_I18N_SYMBOL__;if(s){const c=t._context.provides[s];if(c)return c}const o=f(n);return e.use(o),o}exports.createFinI18n=f;exports.en=l;exports.installFinI18n=_;exports.useFinLocale=y;exports.zhCN=a;
package/dist/index2.mjs DELETED
@@ -1,57 +0,0 @@
1
- import { createI18n as a, useI18n as f } from "vue-i18n";
2
- import u from "./index5.mjs";
3
- import l from "./index3.mjs";
4
- import m from "./index6.mjs";
5
- import g from "./index4.mjs";
6
- function r(e) {
7
- return typeof e == "object" && e !== null && !Array.isArray(e);
8
- }
9
- function i(e, n) {
10
- const t = { ...e };
11
- for (const [o, s] of Object.entries(n))
12
- t[o] = r(t[o]) && r(s) ? i(t[o], s) : s;
13
- return t;
14
- }
15
- const p = i(u, l), h = i(m, g);
16
- function N(e) {
17
- const n = {
18
- "zh-CN": p,
19
- en: h
20
- };
21
- if (!r(e))
22
- return n;
23
- for (const [t, o] of Object.entries(e))
24
- r(o) && (n[t] = n[t] ? i(n[t], o) : o);
25
- return n;
26
- }
27
- function _(e) {
28
- const { messages: n, ...t } = e || {};
29
- return a({
30
- locale: "zh-CN",
31
- fallbackLocale: "zh-CN",
32
- legacy: !1,
33
- ...t,
34
- messages: N(n)
35
- });
36
- }
37
- function d() {
38
- const { t: e, locale: n } = f({ useScope: "global" });
39
- return { t: e, locale: n };
40
- }
41
- function F(e, n) {
42
- const t = e, o = t.__VUE_I18N_SYMBOL__;
43
- if (o) {
44
- const c = t._context.provides[o];
45
- if (c)
46
- return c;
47
- }
48
- const s = _(n);
49
- return e.use(s), s;
50
- }
51
- export {
52
- _ as createFinI18n,
53
- h as en,
54
- F as installFinI18n,
55
- d as useFinLocale,
56
- p as zhCN
57
- };
package/dist/index5.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";const e=require("./index7.cjs"),a={fin:{upload:e.fin.upload,common:{confirm:"确认",cancel:"取消",close:"关闭",save:"保存",submit:"提交",reset:"重置",search:"搜索",refresh:"刷新",loading:"加载中...",noData:"暂无数据",operation:"操作",more:"更多",index:"序号",edit:"编辑",delete:"删除",view:"查看",add:"新增",total:"合计",undo:"撤回",editMode:"编辑模式",viewMode:"查看模式",withdraw:"撤回",yes:"是",no:"否",confirmDelete:"确认删除该条记录吗?",confirmDeleteTitle:"删除确认",deleteSuccess:"删除成功",deleteFailed:"删除失败",deleteConfirm:"确认删除",saveSuccess:"保存成功",saveFailed:"保存失败",retry:"重试",loadFailed:"加载失败",export:"导出",columnSettings:"列设置",requestFailed:"请求失败,请稍后重试",viewDetail:"详情"},finCopy:{copyEmptyContent:"没有可复制的内容",copySuccess:"复制成功",copyFailed:"复制失败"},copy:{action:"复制",noContent:"没有可复制的内容",success:"复制成功",failed:"复制失败",copyEmptyContent:"没有可复制的内容",copySuccess:"复制成功",copyFailed:"复制失败"},finForm:{submit:"提交",reset:"重置",query:"查询",cancel:"取消",expand:"展开",collapse:"收起",selectPlaceholder:"请选择{label}",inputPlaceholder:"请输入{label}",dateRangeStartPlaceholder:"开始时间",dateRangeEndPlaceholder:"结束时间",yes:"是",no:"否",validationFailed:"验证失败",formRefUnavailable:"表单引用不可用",submitFailed:"提交失败,请稍后重试",validationSummary:"表单验证失败,请检查 {count} 个字段",required:"{label}为必填项"},form:{...e.fin.form,submit:"提交",reset:"重置",query:"查询",cancel:"取消",expand:"展开",collapse:"收起",pleaseSelect:"请选择{label}",selectPlaceholder:"请选择",pleaseInput:"请输入{label}",inputPlaceholder:"请输入{label}",dateRangeStartPlaceholder:"开始时间",dateRangeEndPlaceholder:"结束时间",startTime:"开始时间",endTime:"结束时间",yes:"是",no:"否",validationFailed:"验证失败",formRefUnavailable:"表单引用不可用",submitFailed:"提交失败,请稍后重试",validationSummary:"表单验证失败,请检查 {count} 个字段",required:"{label}为必填项"},finSelect:{searchPlaceholder:"请输入关键词搜索",selectPlaceholder:"请选择",noData:"无数据",loading:"加载中...",loadMore:"加载更多",allLoaded:"已加载全部"},select:{searchPlaceholder:"请输入关键词搜索",selectPlaceholder:"请选择",placeholder:"请选择",noData:"无数据",loading:"加载中...",loadMore:"加载更多",allLoaded:"已加载全部"},pageHeader:{back:"返回"},langInput:{...e.fin.langInput,pleaseInput:"请输入"},mathEditor:{title:"计算公式",subtitle:"拖入资源或点击添加,支持可视化与源码双向编辑",searchPlaceholder:"搜索参数、指标或函数",searchReferences:"搜索参数或指标",searchFunctions:"搜索函数",parameters:"参数",indicators:"指标",functions:"函数",resources:"引用资源",tools:"函数与常量",inspector:"检查器",toolbar:"公式编辑工具栏",operators:"运算符",constants:"常量",addConstant:"插入常量",invalidConstant:"请输入有效的十进制数值",constantOutOfRange:"常量超出允许范围",structureActions:"结构操作",groupExpression:"添加括号",ungroupExpression:"移除括号",collapseReferences:"折叠引用资源",expandReferences:"展开引用资源",collapseTools:"折叠函数与常量",expandTools:"展开函数与常量",unary:"一元",binary:"二元",parameterCount:"{count} 参数",signatureCount:"{count} 个签名",noFunctions:"没有匹配的函数",operatorCategory:{arithmetic:"算术运算",comparison:"比较运算",logical:"逻辑运算"},functionCategory:{all:"全部",condition:"条件",aggregation:"聚合",math:"数学",string:"字符串",date:"日期",statistics:"统计"},undo:"撤销",redo:"重做",reset:"重置",clear:"清空",visualMode:"可视化",sourceMode:"源码",canvas:"公式画布",panCanvasHint:"拖动画布或使用方向键平移,横向滚轮也可浏览长公式",emptyHint:"从左侧添加参数、指标或函数",loading:"正在加载资源...",loadFailed:"资源加载失败",retry:"重试",noResources:"没有匹配的资源",ungroupedReferences:"其他",loadMore:"加载更多",placeholder:"待补充",deleteNode:"删除节点",nodeActions:"节点操作",insertLeft:"在左侧插入",insertRight:"在右侧插入",addPrefixOperator:"添加前缀运算",addPredicateOperator:"添加条件判断",removeOperator:"移除当前运算",keepLeftOperand:"移除运算并保留左侧",keepRightOperand:"移除运算并保留右侧",predicateCategory:{collection:"集合判断",range:"范围判断",null:"空值判断"},changeOperator:"修改运算符",backToNodeActions:"返回节点操作",revertSource:"恢复有效公式",externalConflict:"外部公式已更新,请选择要保留的版本。",keepLocal:"保留当前草稿",useExternal:"使用外部版本",validationPassed:"校验通过",validationErrors:"{count} 个错误",validationWarnings:"{count} 个提示",selection:"当前节点",nodeType:"节点类型",noSelection:"选择画布中的节点以查看详情",diagnostics:"校验结果",noDiagnostics:"未发现问题",formulaText:"有效公式文本",showFullFormula:"查看完整公式",hideFullFormula:"收起完整公式",sourceJson:"查看源码",copySourceJson:"复制源码 JSON",viewTools:"画布视图工具",zoomIn:"放大画布",zoomOut:"缩小画布",resetView:"复位画布视图",lastValidFormulaHint:"源码草稿有误,当前展示并复制最后一次有效公式",showDiagnostics:"展开校验详情",hideDiagnostics:"收起校验详情",clearSearch:"清空搜索",filterLoadedResources:"筛选已加载内容",viewResourceDetail:"查看{name}详情",resourceDetail:"{name}详情",closeResourceDetail:"关闭资源详情",resourceDisabled:"已停用",resourceMissing:"已失效",resourceForbidden:"无权限",resourceIncompatible:"版本不兼容",resourceId:"资源标识",sourceId:"数据源",version:"版本",returnType:"返回类型",description:"描述",fieldPath:"字段路径",resourceStatus:"资源状态",signatureRules:"参数规则",examples:"示例",operationSyntax:"运算结构",operatorSymbol:"运算符",operandTypes:"操作数类型",nullable:"允许空值",unit:"单位",dynamicInference:"动态推导",cannotDisplay:"无法展示",clearCollectionValue:"清空集合值",deleteCollectionValue:"删除集合值",addCollectionValue:"添加集合值",addFunctionArgument:"添加函数参数",currentReplacementTarget:"当前替换目标",replaceCurrentNode:"替换当前节点",replacing:"替换中",replace:"替换",clearUnavailableResource:"清空失效资源",replacingResource:"正在替换“{name}”",cancelReplacement:"取消替换",confirmReplacement:"确认替换",replacementDescription:"替换后将删除当前节点包含的全部子表达式,是否继续?",replacementWarning:"此操作只替换当前选中的节点,已包含的子表达式无法恢复。",continueReplacement:"继续替换",commandBlocked:{targetRequired:"请先选择公式中的目标位置",targetNotFound:"目标节点已不存在,请重新选择",resourceUnavailable:"当前资源不可用",replacementRequired:"当前节点已有内容,请先选择“替换”",replacementUnsupported:"运算符不能替换节点,请选择字段、参数或函数",resourceTypeIncompatible:"资源类型与当前参数槽不兼容",functionNotFound:"函数定义不存在或尚未加载",functionSignatureNotFound:"没有符合当前参数的函数签名",functionSignatureAmbiguous:"存在多个可用函数签名,请明确选择",functionArgumentLoss:"该操作会丢失已有函数参数",functionArgumentLimit:"函数参数已达到上限",functionArgumentRequired:"必填函数参数不能删除",inValueRequired:"集合条件至少需要保留一个值槽位",editorLocked:"当前编辑器不可修改"}},validation:{...e.fin.validation,required:"不能为空",format:"格式不正确",min:"不能小于",max:"不能大于",failed:"验证失败"},crud:{...e.fin.crud,addSuccess:"新增成功",editSuccess:"编辑成功",addFailed:"新增失败",editFailed:"编辑失败",columnSettings:{showColumns:"显示列",save:"保存配置"}}}};module.exports=a;
package/dist/index6.cjs DELETED
@@ -1 +0,0 @@
1
- "use strict";const e=require("./index8.cjs"),a={fin:{upload:e.fin.upload,common:{confirm:"Confirm",cancel:"Cancel",close:"Close",save:"Save",submit:"Submit",reset:"Reset",search:"Search",refresh:"Refresh",loading:"Loading...",noData:"No Data",operation:"Operation",more:"More",index:"No.",edit:"Edit",delete:"Delete",view:"View",add:"Add",total:"Total",undo:"Undo",editMode:"Edit Mode",viewMode:"View Mode",withdraw:"Withdraw",yes:"Yes",no:"No",confirmDelete:"Are you sure you want to delete this record?",confirmDeleteTitle:"Delete Confirmation",deleteSuccess:"Deleted successfully",deleteFailed:"Delete failed",deleteConfirm:"Confirm Delete",saveSuccess:"Saved successfully",saveFailed:"Save failed",retry:"Retry",loadFailed:"Load failed",export:"Export",columnSettings:"Column Settings",requestFailed:"Request failed, please try again later",viewDetail:"Details"},finCopy:{copyEmptyContent:"Nothing to copy",copySuccess:"Copied successfully",copyFailed:"Copy failed"},copy:{action:"Copy",noContent:"Nothing to copy",success:"Copied successfully",failed:"Copy failed",copyEmptyContent:"Nothing to copy",copySuccess:"Copied successfully",copyFailed:"Copy failed"},finForm:{submit:"Submit",reset:"Reset",query:"Search",cancel:"Cancel",expand:"Expand",collapse:"Collapse",selectPlaceholder:"Please select {label}",inputPlaceholder:"Please enter {label}",dateRangeStartPlaceholder:"Start date",dateRangeEndPlaceholder:"End date",yes:"Yes",no:"No",validationFailed:"Validation failed",formRefUnavailable:"Form ref not available",submitFailed:"Submission failed, please try again later",validationSummary:"Form validation failed, please check {count} fields",required:"{label} is required"},form:{...e.fin.form,submit:"Submit",reset:"Reset",query:"Search",cancel:"Cancel",expand:"Expand",collapse:"Collapse",pleaseSelect:"Please select {label}",selectPlaceholder:"Please select",pleaseInput:"Please enter {label}",inputPlaceholder:"Please enter {label}",dateRangeStartPlaceholder:"Start date",dateRangeEndPlaceholder:"End date",startTime:"Start time",endTime:"End time",yes:"Yes",no:"No",validationFailed:"Validation failed",formRefUnavailable:"Form ref not available",submitFailed:"Submission failed, please try again later",validationSummary:"Form validation failed, please check {count} fields",required:"{label} is required"},finSelect:{searchPlaceholder:"Search by keyword",selectPlaceholder:"Please select",noData:"No data",loading:"Loading...",loadMore:"Load more",allLoaded:"All data loaded"},select:{searchPlaceholder:"Search by keyword",selectPlaceholder:"Please select",placeholder:"Please select",noData:"No data",loading:"Loading...",loadMore:"Load more",allLoaded:"All data loaded"},pageHeader:{back:"Back"},langInput:{...e.fin.langInput,pleaseInput:"Please enter"},mathEditor:{title:"Formula editor",subtitle:"Drag or click resources; edit visually or as source",searchPlaceholder:"Search parameters, indicators, or functions",searchReferences:"Search parameters or indicators",searchFunctions:"Search functions",parameters:"Parameters",indicators:"Indicators",functions:"Functions",resources:"References",tools:"Functions and constants",inspector:"Inspector",toolbar:"Formula editor toolbar",operators:"Operators",constants:"Constants",addConstant:"Add to expression",invalidConstant:"Enter a valid decimal number",constantOutOfRange:"Constant is outside the allowed range",structureActions:"Structure actions",groupExpression:"Add parentheses",ungroupExpression:"Remove parentheses",collapseReferences:"Collapse references",expandReferences:"Expand references",collapseTools:"Collapse functions and constants",expandTools:"Expand functions and constants",unary:"Unary",binary:"Binary",parameterCount:"{count} parameters",signatureCount:"{count} signatures",noFunctions:"No matching functions",operatorCategory:{arithmetic:"Arithmetic",comparison:"Comparison",logical:"Logical"},functionCategory:{all:"All",condition:"Conditional",aggregation:"Aggregation",math:"Math",string:"String",date:"Date",statistics:"Statistics"},undo:"Undo",redo:"Redo",reset:"Reset",clear:"Clear",visualMode:"Visual",sourceMode:"Source",canvas:"Formula canvas",panCanvasHint:"Drag the canvas or use arrow keys to pan; horizontal scrolling also navigates long formulas",emptyHint:"Add a parameter, indicator, or function",loading:"Loading resources...",loadFailed:"Failed to load resources",retry:"Retry",noResources:"No matching resources",ungroupedReferences:"Other",loadMore:"Load more",placeholder:"Required",deleteNode:"Delete node",nodeActions:"Node actions",insertLeft:"Insert on the left",insertRight:"Insert on the right",addPrefixOperator:"Add prefix operator",addPredicateOperator:"Add condition",removeOperator:"Remove current operation",keepLeftOperand:"Remove operation and keep left",keepRightOperand:"Remove operation and keep right",predicateCategory:{collection:"Collection tests",range:"Range tests",null:"Null tests"},changeOperator:"Change operator",backToNodeActions:"Back to node actions",revertSource:"Restore valid formula",externalConflict:"The external formula changed. Choose which version to keep.",keepLocal:"Keep draft",useExternal:"Use external",validationPassed:"Validation passed",validationErrors:"{count} errors",validationWarnings:"{count} warnings",selection:"Selected node",nodeType:"Node type",noSelection:"Select a node in the canvas to inspect it",diagnostics:"Diagnostics",noDiagnostics:"No issues found",formulaText:"Valid formula text",showFullFormula:"View full formula",hideFullFormula:"Hide full formula",sourceJson:"View source",copySourceJson:"Copy source JSON",viewTools:"Canvas view controls",zoomIn:"Zoom in",zoomOut:"Zoom out",resetView:"Reset canvas view",lastValidFormulaHint:"The source draft is invalid; showing and copying the last valid formula",showDiagnostics:"Show validation details",hideDiagnostics:"Hide validation details",clearSearch:"Clear search",filterLoadedResources:"Filter loaded resources",viewResourceDetail:"View {name} details",resourceDetail:"{name} details",closeResourceDetail:"Close resource details",resourceDisabled:"Disabled",resourceMissing:"Unavailable",resourceForbidden:"No access",resourceIncompatible:"Incompatible version",resourceId:"Resource ID",sourceId:"Source ID",version:"Version",returnType:"Return type",description:"Description",fieldPath:"Field path",resourceStatus:"Resource status",signatureRules:"Signatures",examples:"Examples",operationSyntax:"Operation syntax",operatorSymbol:"Operator",operandTypes:"Operand types",nullable:"Nullable",unit:"Unit",dynamicInference:"Dynamically inferred",cannotDisplay:"Unable to display",clearCollectionValue:"Clear collection value",deleteCollectionValue:"Delete collection value",addCollectionValue:"Add collection value",addFunctionArgument:"Add function argument",currentReplacementTarget:"Current replacement target",replaceCurrentNode:"Replace current node",replacing:"Replacing",replace:"Replace",clearUnavailableResource:"Clear unavailable resource",replacingResource:"Replacing “{name}”",cancelReplacement:"Cancel replacement",confirmReplacement:"Confirm replacement",replacementDescription:"Replacing this node removes all nested expressions. Continue?",replacementWarning:"Only the selected node will be replaced. Its nested expressions cannot be restored.",continueReplacement:"Continue replacement",commandBlocked:{targetRequired:"Select a target position in the formula first",targetNotFound:"The target node no longer exists; select it again",resourceUnavailable:"This resource is unavailable",replacementRequired:"This node already has content; choose Replace first",replacementUnsupported:"Operators cannot replace nodes; choose a field, parameter, or function",resourceTypeIncompatible:"The resource type is incompatible with this argument slot",functionNotFound:"The function definition does not exist or is not loaded",functionSignatureNotFound:"No function signature matches the current arguments",functionSignatureAmbiguous:"Multiple function signatures match; choose one explicitly",functionArgumentLoss:"This operation would discard existing function arguments",functionArgumentLimit:"The function has reached its argument limit",functionArgumentRequired:"A required function argument cannot be deleted",inValueRequired:"A collection condition must keep at least one value slot",editorLocked:"The editor cannot be modified"}},validation:{...e.fin.validation,required:"Cannot be empty",format:"Invalid format",min:"Cannot be less than",max:"Cannot be greater than",failed:"Validation failed"},crud:{...e.fin.crud,addSuccess:"Added successfully",editSuccess:"Updated successfully",addFailed:"Add failed",editFailed:"Update failed",columnSettings:{showColumns:"Show Columns",save:"Save Settings"}}}};module.exports=a;
@@ -1 +0,0 @@
1
- {"version":3,"file":"dashboard-additions.d.ts","sourceRoot":"","sources":["../../../../src/lang/en/dashboard-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAyJC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"formula-additions.d.ts","sourceRoot":"","sources":["../../../../src/lang/en/formula-additions.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,wBAoGC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"ui-additions.d.ts","sourceRoot":"","sources":["../../../../src/lang/en/ui-additions.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkDhB,CAAA;AAED,eAAe,WAAW,CAAA"}
File without changes
File without changes