pangea-lib 1.16.12 → 1.16.14
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/dist/main.cjs.js +15 -15
- package/dist/main.es.js +51 -42
- package/dist/types/i18n/create-i18n.d.ts +12 -3
- package/dist/types/i18n/i18n.d.ts +5 -1
- package/dist/types/i18n/i18n.store.d.ts +4 -8
- package/dist/types/i18n/i18n.types.d.ts +3 -7
- package/dist/types/i18n/index.d.ts +0 -1
- package/dist/types/main.d.ts +1 -1
- package/package.json +1 -1
package/dist/main.es.js
CHANGED
|
@@ -14050,43 +14050,53 @@ const H61 = /* @__PURE__ */ h3(z61, [["__scopeId", "data-v-b350b31a"]]), M61 = /
|
|
|
14050
14050
|
};
|
|
14051
14051
|
}
|
|
14052
14052
|
});
|
|
14053
|
-
const g61 = /* @__PURE__ */ h3(M61, [["__scopeId", "data-v-68e8fb55"]]), V61 =
|
|
14054
|
-
id: "pga-i18n",
|
|
14055
|
-
state: () => ({
|
|
14056
|
-
currentLanguage: "es"
|
|
14057
|
-
}),
|
|
14058
|
-
actions: {
|
|
14059
|
-
setLanguage(e) {
|
|
14060
|
-
this.currentLanguage = e;
|
|
14061
|
-
}
|
|
14062
|
-
},
|
|
14063
|
-
persist: !0
|
|
14064
|
-
});
|
|
14065
|
-
function C61(e) {
|
|
14066
|
-
return (c) => (a, t = {}) => {
|
|
14067
|
-
const i = V61().currentLanguage, n = e == null ? void 0 : e[c], r = n == null ? void 0 : n[i], s = (r == null ? void 0 : r[a]) || "", o = t.count ? t.count : 0, l = s.split("|").map((u) => u.trim());
|
|
14068
|
-
let f = l[0];
|
|
14069
|
-
l.length === 2 ? f = o === 1 ? l[0] : l[1] : l.length === 3 && (f = o === 0 ? l[0] : o === 1 ? l[1] : l[2]), f = f.replace(new RegExp("{count}", "g"), o.toString());
|
|
14070
|
-
for (const u in t)
|
|
14071
|
-
u !== "count" && t[u] && (f = f.replace(new RegExp(`{${u}}`, "g"), t[u].toString()));
|
|
14072
|
-
return f;
|
|
14073
|
-
};
|
|
14074
|
-
}
|
|
14075
|
-
const b61 = {
|
|
14053
|
+
const g61 = /* @__PURE__ */ h3(M61, [["__scopeId", "data-v-68e8fb55"]]), V61 = {
|
|
14076
14054
|
es: {
|
|
14077
14055
|
cancelBtn: "Cancelar",
|
|
14078
14056
|
selectBtn: "Seleccionar"
|
|
14079
14057
|
}
|
|
14080
|
-
},
|
|
14058
|
+
}, C61 = {
|
|
14081
14059
|
es: {
|
|
14082
14060
|
cancelBtn: "Cancelar",
|
|
14083
14061
|
acceptBtn: "Aceptar"
|
|
14084
14062
|
}
|
|
14085
|
-
},
|
|
14063
|
+
}, b61 = {
|
|
14086
14064
|
// components
|
|
14087
|
-
PgaDatePicker:
|
|
14088
|
-
PgaModal:
|
|
14089
|
-
}
|
|
14065
|
+
PgaDatePicker: V61,
|
|
14066
|
+
PgaModal: C61
|
|
14067
|
+
};
|
|
14068
|
+
function L61(e, c) {
|
|
14069
|
+
return Cp({
|
|
14070
|
+
id: e,
|
|
14071
|
+
state: () => ({
|
|
14072
|
+
currentLanguage: c
|
|
14073
|
+
}),
|
|
14074
|
+
actions: {
|
|
14075
|
+
setLanguage(a) {
|
|
14076
|
+
this.currentLanguage = a;
|
|
14077
|
+
}
|
|
14078
|
+
},
|
|
14079
|
+
persist: !0
|
|
14080
|
+
});
|
|
14081
|
+
}
|
|
14082
|
+
function y61(e, c, a) {
|
|
14083
|
+
const t = L61(e, c);
|
|
14084
|
+
function i(n) {
|
|
14085
|
+
return (r, s = {}) => {
|
|
14086
|
+
const o = t().currentLanguage, l = a == null ? void 0 : a[n], f = l == null ? void 0 : l[o], u = (f == null ? void 0 : f[r]) || "", h = s.count ? s.count : 0, m = u.split("|").map((d) => d.trim());
|
|
14087
|
+
let v = m[0];
|
|
14088
|
+
m.length === 2 ? v = h === 1 ? m[0] : m[1] : m.length === 3 && (v = h === 0 ? m[0] : h === 1 ? m[1] : m[2]), v = v.replace(new RegExp("{count}", "g"), h.toString());
|
|
14089
|
+
for (const d in s)
|
|
14090
|
+
d !== "count" && s[d] && (v = v.replace(new RegExp(`{${d}}`, "g"), s[d].toString()));
|
|
14091
|
+
return v;
|
|
14092
|
+
};
|
|
14093
|
+
}
|
|
14094
|
+
return {
|
|
14095
|
+
useI18nStore: t,
|
|
14096
|
+
useI18n: i
|
|
14097
|
+
};
|
|
14098
|
+
}
|
|
14099
|
+
const { useI18nStore: Ms1, useI18n: Gm } = y61("pga-i18n", "es", b61), x61 = { class: "modal--header" }, w61 = ["textContent"], k61 = { class: "modal--body" }, S61 = {
|
|
14090
14100
|
key: 0,
|
|
14091
14101
|
class: "modal--footer"
|
|
14092
14102
|
}, _61 = ["textContent"], N61 = ["textContent"], A61 = /* @__PURE__ */ A1({
|
|
@@ -29259,7 +29269,7 @@ const ut1 = /* @__PURE__ */ h3(ft1, [["__scopeId", "data-v-5f611679"]]), ht1 = /
|
|
|
29259
29269
|
PgaSelector: W61,
|
|
29260
29270
|
PgaSpinner: q61
|
|
29261
29271
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
29262
|
-
function
|
|
29272
|
+
function Vs1(e, c, a = "animate__") {
|
|
29263
29273
|
return new Promise((t) => {
|
|
29264
29274
|
const i = `${a}${c}`, n = document.querySelector(e);
|
|
29265
29275
|
if (n) {
|
|
@@ -29277,11 +29287,11 @@ function mt1(e, c) {
|
|
|
29277
29287
|
});
|
|
29278
29288
|
return a === "-0" ? "0" : a;
|
|
29279
29289
|
}
|
|
29280
|
-
function
|
|
29290
|
+
function Cs1(e, c, a, t = !0) {
|
|
29281
29291
|
let i = mt1(e, c);
|
|
29282
29292
|
return t && (i = i += ` ${a}`), i;
|
|
29283
29293
|
}
|
|
29284
|
-
function
|
|
29294
|
+
function bs1(e, c) {
|
|
29285
29295
|
const t = {
|
|
29286
29296
|
...{
|
|
29287
29297
|
format: "short",
|
|
@@ -31878,7 +31888,7 @@ l1.HTML5_FMT = {
|
|
|
31878
31888
|
MONTH: "YYYY-MM"
|
|
31879
31889
|
// <input type="month" />
|
|
31880
31890
|
};
|
|
31881
|
-
function
|
|
31891
|
+
function Ls1(e, c, a) {
|
|
31882
31892
|
c && Object.keys(c).forEach((t) => {
|
|
31883
31893
|
if (e.hasOwnProperty(t)) {
|
|
31884
31894
|
if (!c[t] || c[t] instanceof File)
|
|
@@ -31897,7 +31907,7 @@ function bs1(e, c, a) {
|
|
|
31897
31907
|
}
|
|
31898
31908
|
});
|
|
31899
31909
|
}
|
|
31900
|
-
function
|
|
31910
|
+
function ys1(e) {
|
|
31901
31911
|
if (!e)
|
|
31902
31912
|
return !1;
|
|
31903
31913
|
let c = e;
|
|
@@ -31933,20 +31943,19 @@ function vs1(e) {
|
|
|
31933
31943
|
c.style.setProperty(`--pga${a.charAt(0).toUpperCase()}${a.slice(1)}Color`, t);
|
|
31934
31944
|
}
|
|
31935
31945
|
}
|
|
31936
|
-
const
|
|
31946
|
+
const xs1 = (e, c) => {
|
|
31937
31947
|
const a = ds1(c);
|
|
31938
31948
|
vs1(a.colors), Object.entries(ht1).forEach(([t, i]) => {
|
|
31939
31949
|
e.component(t, i);
|
|
31940
31950
|
});
|
|
31941
31951
|
};
|
|
31942
31952
|
export {
|
|
31943
|
-
|
|
31944
|
-
|
|
31945
|
-
|
|
31946
|
-
|
|
31947
|
-
|
|
31948
|
-
|
|
31953
|
+
Vs1 as animateCSS,
|
|
31954
|
+
Ls1 as copyModelFields,
|
|
31955
|
+
y61 as createI18n,
|
|
31956
|
+
xs1 as default,
|
|
31957
|
+
Cs1 as getCoinAmountInString,
|
|
31958
|
+
bs1 as getDatetimeInString,
|
|
31949
31959
|
mt1 as getNumberInString,
|
|
31950
|
-
|
|
31951
|
-
V61 as useI18nStore
|
|
31960
|
+
ys1 as isCurrentUrl
|
|
31952
31961
|
};
|
|
@@ -1,3 +1,12 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
export type Props = {
|
|
2
|
+
[prop: string]: string | number;
|
|
3
|
+
count?: number;
|
|
4
|
+
};
|
|
5
|
+
export declare function createI18n(storeId: string, defaultLanguage: string, messages: any): {
|
|
6
|
+
useI18nStore: import('pinia').StoreDefinition<string, {
|
|
7
|
+
currentLanguage: string;
|
|
8
|
+
}, {}, {
|
|
9
|
+
setLanguage(language: string): void;
|
|
10
|
+
}>;
|
|
11
|
+
useI18n: (fileName: string) => (messageKey: string, props?: Props) => string;
|
|
12
|
+
};
|
|
@@ -1 +1,5 @@
|
|
|
1
|
-
export declare const
|
|
1
|
+
export declare const useI18nStore: import('pinia').StoreDefinition<string, {
|
|
2
|
+
currentLanguage: string;
|
|
3
|
+
}, {}, {
|
|
4
|
+
setLanguage(language: string): void;
|
|
5
|
+
}>, useI18n: (fileName: string) => (messageKey: string, props?: import('./create-i18n').Props) => string;
|
|
@@ -1,9 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
};
|
|
6
|
-
export declare const useI18nStore: import('pinia').StoreDefinition<"pga-i18n", I18nStoreState, {}, {
|
|
7
|
-
setLanguage(language: Language): void;
|
|
1
|
+
export declare function createI18nStore<L extends string>(id: string, defaultLanguage: L): import('pinia').StoreDefinition<string, {
|
|
2
|
+
currentLanguage: L;
|
|
3
|
+
}, {}, {
|
|
4
|
+
setLanguage(language: L): void;
|
|
8
5
|
}>;
|
|
9
|
-
export {};
|
|
@@ -1,9 +1,5 @@
|
|
|
1
|
-
import { default as
|
|
1
|
+
import { default as messages } from './i18n.messages';
|
|
2
2
|
|
|
3
3
|
export type Language = 'es';
|
|
4
|
-
export type FileName = keyof typeof
|
|
5
|
-
export type MessageKey<T extends FileName> = keyof (typeof
|
|
6
|
-
export type Props = {
|
|
7
|
-
[prop: string]: string | number;
|
|
8
|
-
count?: number;
|
|
9
|
-
};
|
|
4
|
+
export type FileName = keyof typeof messages;
|
|
5
|
+
export type MessageKey<T extends FileName> = keyof (typeof messages)[T][Language];
|
package/dist/types/main.d.ts
CHANGED