@pisell/materials 6.11.5 → 6.11.7

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 (195) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/index.js +1 -1
  5. package/build/lowcode/meta.js +7 -7
  6. package/build/lowcode/preview.js +9 -9
  7. package/build/lowcode/render/default/view.css +1 -1
  8. package/build/lowcode/render/default/view.js +23 -23
  9. package/build/lowcode/view.css +1 -1
  10. package/build/lowcode/view.js +19 -19
  11. package/es/components/PisellTabbar/PisellTabbar.js +47 -44
  12. package/es/components/PisellTabbar/locales.d.ts +8 -0
  13. package/es/components/PisellTabbar/locales.js +8 -0
  14. package/es/components/PisellTabbar/template/Template1/PisellTabbar.d.ts +3 -18
  15. package/es/components/PisellTabbar/template/Template1/PisellTabbar.js +124 -28
  16. package/es/components/PisellTabbar/template/Template1/constants.js +1 -1
  17. package/es/components/PisellTabbar2/locales.d.ts +8 -0
  18. package/es/components/PisellTabbar2/locales.js +8 -0
  19. package/es/components/PisellTabbar3/locales.d.ts +8 -0
  20. package/es/components/PisellTabbar3/locales.js +8 -0
  21. package/es/components/config-provider/index.d.ts +2 -0
  22. package/es/components/config-provider/index.js +6 -0
  23. package/es/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +2 -0
  24. package/es/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +2 -0
  25. package/es/components/dataSourceComponents/fields/Translation/BaseTranslation.js +8 -0
  26. package/es/components/dataSourceComponents/fields/Translation/type.d.ts +2 -0
  27. package/es/components/dataSourceComponents/fields/Upload/constants.d.ts +1 -1
  28. package/es/components/dataSourceComponents/fields/Upload/constants.js +1 -1
  29. package/es/components/dataSourceComponents/fields/Upload/utils.js +1 -1
  30. package/es/components/page/index.js +11 -1
  31. package/es/components/pisellDateTimeDisplay/PisellDateTimeDisplay.js +47 -34
  32. package/es/components/pisellDateTimeDisplay/PisellDateTimeDisplay.stories.d.ts +19 -0
  33. package/es/components/pisellDateTimeDisplay/PisellDateTimeDisplay.stories.js +74 -0
  34. package/es/components/pisellDateTimeDisplay/components/DateDisplay.d.ts +6 -1
  35. package/es/components/pisellDateTimeDisplay/components/DateDisplay.js +10 -3
  36. package/es/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.d.ts +7 -0
  37. package/es/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.js +81 -0
  38. package/es/components/pisellDateTimeDisplay/formats/index.d.ts +1 -0
  39. package/es/components/pisellDateTimeDisplay/formats/index.js +1 -0
  40. package/es/components/pisellDateTimeDisplay/hooks/useCurrentTime.d.ts +2 -2
  41. package/es/components/pisellDateTimeDisplay/hooks/useCurrentTime.js +2 -2
  42. package/es/components/pisellDateTimeDisplay/types.d.ts +48 -2
  43. package/es/components/pisellDateTimeDisplay/utils/formatDate.js +25 -6
  44. package/es/components/pisellDateTimeDisplay/utils/formatDateOrRelative.d.ts +17 -0
  45. package/es/components/pisellDateTimeDisplay/utils/formatDateOrRelative.js +38 -0
  46. package/es/components/pisellDateTimeDisplay/utils/formatWeekday.js +11 -12
  47. package/es/components/pisellDateTimeDisplay/utils/index.d.ts +3 -1
  48. package/es/components/pisellDateTimeDisplay/utils/index.js +3 -1
  49. package/es/components/pisellDateTimeDisplay/utils/localeUtils.d.ts +2 -7
  50. package/es/components/pisellDateTimeDisplay/utils/localeUtils.js +4 -17
  51. package/es/components/pisellDateTimeDisplay/utils/relativeDay.d.ts +23 -0
  52. package/es/components/pisellDateTimeDisplay/utils/relativeDay.js +45 -0
  53. package/es/components/pisellLookup/components/LookupTrigger.js +66 -6
  54. package/es/components/pisellText/components/Editable/index.d.ts +3 -0
  55. package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.d.ts +32 -0
  56. package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.js +197 -0
  57. package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.less +49 -0
  58. package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.stories.d.ts +61 -0
  59. package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.stories.js +209 -0
  60. package/es/components/pisellTimeRangeDisplay/components/DateBlock.d.ts +20 -0
  61. package/es/components/pisellTimeRangeDisplay/components/DateBlock.js +30 -0
  62. package/es/components/pisellTimeRangeDisplay/components/DurationBlock.d.ts +19 -0
  63. package/es/components/pisellTimeRangeDisplay/components/DurationBlock.js +25 -0
  64. package/es/components/pisellTimeRangeDisplay/components/TimeRangeBlock.d.ts +30 -0
  65. package/es/components/pisellTimeRangeDisplay/components/TimeRangeBlock.js +86 -0
  66. package/es/components/pisellTimeRangeDisplay/components/WeekdayBlock.d.ts +18 -0
  67. package/es/components/pisellTimeRangeDisplay/components/WeekdayBlock.js +23 -0
  68. package/es/components/pisellTimeRangeDisplay/components/index.d.ts +8 -0
  69. package/es/components/pisellTimeRangeDisplay/components/index.js +4 -0
  70. package/es/components/pisellTimeRangeDisplay/index.d.ts +3 -0
  71. package/es/components/pisellTimeRangeDisplay/index.js +1 -0
  72. package/es/components/pisellTimeRangeDisplay/types.d.ts +137 -0
  73. package/es/components/pisellTimeRangeDisplay/types.js +1 -0
  74. package/es/components/pisellTimeRangeDisplay/utils/formatDuration.d.ts +14 -0
  75. package/es/components/pisellTimeRangeDisplay/utils/formatDuration.js +53 -0
  76. package/es/components/pisellTimeRangeDisplay/utils/index.d.ts +4 -0
  77. package/es/components/pisellTimeRangeDisplay/utils/index.js +5 -0
  78. package/es/components/pisellTimeRangeDisplay/utils/parseTimeRange.d.ts +23 -0
  79. package/es/components/pisellTimeRangeDisplay/utils/parseTimeRange.js +27 -0
  80. package/es/components/productCard/cartSkuCard/components/timeRange/index.d.ts +2 -0
  81. package/es/components/productCard/cartSkuCard/components/timeRange/index.js +5 -1
  82. package/es/components/productCard/cartSkuCard/locales.d.ts +64 -0
  83. package/es/components/productCard/cartSkuCard/locales.js +16 -0
  84. package/es/components/productCard/locales.d.ts +54 -0
  85. package/es/components/productCard/locales.js +84 -0
  86. package/es/components/productCard/utils.d.ts +2 -0
  87. package/es/components/productCard/utils.js +8 -2
  88. package/es/components/translation/index.d.ts +2 -0
  89. package/es/components/translation/index.js +12 -0
  90. package/es/components/translation/utils.d.ts +2 -0
  91. package/es/components/translation/utils.js +3 -1
  92. package/es/components/walletCard/index.d.ts +2 -0
  93. package/es/components/walletCard/index.js +11 -3
  94. package/es/index.d.ts +2 -0
  95. package/es/index.js +7 -0
  96. package/es/locales/index.js +6 -2
  97. package/es/locales/ja.d.ts +337 -0
  98. package/es/locales/ja.js +416 -0
  99. package/es/locales/pt.d.ts +337 -0
  100. package/es/locales/pt.js +416 -0
  101. package/es/utils/platform.d.ts +1 -1
  102. package/lib/components/PisellTabbar/PisellTabbar.js +64 -57
  103. package/lib/components/PisellTabbar/locales.d.ts +8 -0
  104. package/lib/components/PisellTabbar/locales.js +8 -0
  105. package/lib/components/PisellTabbar/template/Template1/PisellTabbar.d.ts +3 -18
  106. package/lib/components/PisellTabbar/template/Template1/PisellTabbar.js +171 -55
  107. package/lib/components/PisellTabbar/template/Template1/constants.js +1 -1
  108. package/lib/components/PisellTabbar2/locales.d.ts +8 -0
  109. package/lib/components/PisellTabbar2/locales.js +8 -0
  110. package/lib/components/PisellTabbar3/locales.d.ts +8 -0
  111. package/lib/components/PisellTabbar3/locales.js +8 -0
  112. package/lib/components/config-provider/index.d.ts +2 -0
  113. package/lib/components/config-provider/index.js +6 -0
  114. package/lib/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +2 -0
  115. package/lib/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +2 -0
  116. package/lib/components/dataSourceComponents/fields/Translation/BaseTranslation.js +5 -1
  117. package/lib/components/dataSourceComponents/fields/Translation/type.d.ts +2 -0
  118. package/lib/components/dataSourceComponents/fields/Upload/constants.d.ts +1 -1
  119. package/lib/components/dataSourceComponents/fields/Upload/constants.js +1 -1
  120. package/lib/components/dataSourceComponents/fields/Upload/utils.js +1 -1
  121. package/lib/components/page/index.js +11 -1
  122. package/lib/components/pisellDateTimeDisplay/PisellDateTimeDisplay.js +27 -17
  123. package/lib/components/pisellDateTimeDisplay/PisellDateTimeDisplay.stories.d.ts +19 -0
  124. package/lib/components/pisellDateTimeDisplay/PisellDateTimeDisplay.stories.js +63 -0
  125. package/lib/components/pisellDateTimeDisplay/components/DateDisplay.d.ts +6 -1
  126. package/lib/components/pisellDateTimeDisplay/components/DateDisplay.js +5 -1
  127. package/lib/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.d.ts +7 -0
  128. package/lib/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.js +98 -0
  129. package/lib/components/pisellDateTimeDisplay/formats/index.d.ts +1 -0
  130. package/lib/components/pisellDateTimeDisplay/formats/index.js +29 -0
  131. package/lib/components/pisellDateTimeDisplay/hooks/useCurrentTime.d.ts +2 -2
  132. package/lib/components/pisellDateTimeDisplay/types.d.ts +48 -2
  133. package/lib/components/pisellDateTimeDisplay/utils/formatDate.js +14 -1
  134. package/lib/components/pisellDateTimeDisplay/utils/formatDateOrRelative.d.ts +17 -0
  135. package/lib/components/pisellDateTimeDisplay/utils/formatDateOrRelative.js +54 -0
  136. package/lib/components/pisellDateTimeDisplay/utils/formatWeekday.js +6 -6
  137. package/lib/components/pisellDateTimeDisplay/utils/index.d.ts +3 -1
  138. package/lib/components/pisellDateTimeDisplay/utils/index.js +8 -2
  139. package/lib/components/pisellDateTimeDisplay/utils/localeUtils.d.ts +2 -7
  140. package/lib/components/pisellDateTimeDisplay/utils/localeUtils.js +2 -11
  141. package/lib/components/pisellDateTimeDisplay/utils/relativeDay.d.ts +23 -0
  142. package/lib/components/pisellDateTimeDisplay/utils/relativeDay.js +54 -0
  143. package/lib/components/pisellLookup/components/LookupTrigger.js +45 -7
  144. package/lib/components/pisellText/components/Editable/index.d.ts +3 -0
  145. package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.d.ts +32 -0
  146. package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.js +193 -0
  147. package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.less +49 -0
  148. package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.stories.d.ts +61 -0
  149. package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.stories.js +187 -0
  150. package/lib/components/pisellTimeRangeDisplay/components/DateBlock.d.ts +20 -0
  151. package/lib/components/pisellTimeRangeDisplay/components/DateBlock.js +69 -0
  152. package/lib/components/pisellTimeRangeDisplay/components/DurationBlock.d.ts +19 -0
  153. package/lib/components/pisellTimeRangeDisplay/components/DurationBlock.js +65 -0
  154. package/lib/components/pisellTimeRangeDisplay/components/TimeRangeBlock.d.ts +30 -0
  155. package/lib/components/pisellTimeRangeDisplay/components/TimeRangeBlock.js +120 -0
  156. package/lib/components/pisellTimeRangeDisplay/components/WeekdayBlock.d.ts +18 -0
  157. package/lib/components/pisellTimeRangeDisplay/components/WeekdayBlock.js +64 -0
  158. package/lib/components/pisellTimeRangeDisplay/components/index.d.ts +8 -0
  159. package/lib/components/pisellTimeRangeDisplay/components/index.js +38 -0
  160. package/lib/components/pisellTimeRangeDisplay/index.d.ts +3 -0
  161. package/lib/components/pisellTimeRangeDisplay/index.js +40 -0
  162. package/lib/components/pisellTimeRangeDisplay/types.d.ts +137 -0
  163. package/lib/components/pisellTimeRangeDisplay/types.js +17 -0
  164. package/lib/components/pisellTimeRangeDisplay/utils/formatDuration.d.ts +14 -0
  165. package/lib/components/pisellTimeRangeDisplay/utils/formatDuration.js +52 -0
  166. package/lib/components/pisellTimeRangeDisplay/utils/index.d.ts +4 -0
  167. package/lib/components/pisellTimeRangeDisplay/utils/index.js +47 -0
  168. package/lib/components/pisellTimeRangeDisplay/utils/parseTimeRange.d.ts +23 -0
  169. package/lib/components/pisellTimeRangeDisplay/utils/parseTimeRange.js +49 -0
  170. package/lib/components/productCard/cartSkuCard/components/timeRange/index.d.ts +2 -0
  171. package/lib/components/productCard/cartSkuCard/components/timeRange/index.js +5 -1
  172. package/lib/components/productCard/cartSkuCard/locales.d.ts +64 -0
  173. package/lib/components/productCard/cartSkuCard/locales.js +18 -0
  174. package/lib/components/productCard/locales.d.ts +54 -0
  175. package/lib/components/productCard/locales.js +60 -0
  176. package/lib/components/productCard/utils.d.ts +2 -0
  177. package/lib/components/productCard/utils.js +8 -2
  178. package/lib/components/translation/index.d.ts +2 -0
  179. package/lib/components/translation/index.js +14 -0
  180. package/lib/components/translation/utils.d.ts +2 -0
  181. package/lib/components/translation/utils.js +3 -1
  182. package/lib/components/walletCard/index.d.ts +2 -0
  183. package/lib/components/walletCard/index.js +11 -3
  184. package/lib/index.d.ts +2 -0
  185. package/lib/index.js +3 -0
  186. package/lib/locales/index.js +6 -2
  187. package/lib/locales/ja.d.ts +337 -0
  188. package/lib/locales/ja.js +396 -0
  189. package/lib/locales/pt.d.ts +337 -0
  190. package/lib/locales/pt.js +396 -0
  191. package/lib/utils/platform.d.ts +1 -1
  192. package/lowcode/pisell-time-range-display/index.ts +3 -0
  193. package/lowcode/pisell-time-range-display/meta.ts +375 -0
  194. package/lowcode/pisell-time-range-display/snippets.ts +1 -0
  195. package/package.json +3 -3
@@ -0,0 +1,52 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __export = (target, all) => {
6
+ for (var name in all)
7
+ __defProp(target, name, { get: all[name], enumerable: true });
8
+ };
9
+ var __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from === "object" || typeof from === "function") {
11
+ for (let key of __getOwnPropNames(from))
12
+ if (!__hasOwnProp.call(to, key) && key !== except)
13
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
14
+ }
15
+ return to;
16
+ };
17
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
+
19
+ // src/components/pisellTimeRangeDisplay/utils/formatDuration.ts
20
+ var formatDuration_exports = {};
21
+ __export(formatDuration_exports, {
22
+ formatDuration: () => formatDuration
23
+ });
24
+ module.exports = __toCommonJS(formatDuration_exports);
25
+ function isChineseLocale(locale) {
26
+ if (!locale) return false;
27
+ const n = locale.toLowerCase();
28
+ return n.startsWith("zh");
29
+ }
30
+ function formatDuration(ms, showSeconds = false, locale) {
31
+ if (!Number.isFinite(ms) || ms < 0) {
32
+ return isChineseLocale(locale) ? "0分钟" : "0m";
33
+ }
34
+ const d = Math.floor(ms / 864e5);
35
+ const h = Math.floor(ms % 864e5 / 36e5);
36
+ const m = Math.floor(ms % 36e5 / 6e4);
37
+ const s = Math.floor(ms % 6e4 / 1e3);
38
+ const useZh = isChineseLocale(locale);
39
+ const units = useZh ? { d: "天", h: "时", m: "分钟", s: "秒" } : { d: "d", h: "h", m: "m", s: "s" };
40
+ const parts = [];
41
+ if (d > 0) parts.push(`${d}${units.d}`);
42
+ if (h > 0) parts.push(`${h}${units.h}`);
43
+ if (m > 0) parts.push(`${m}${units.m}`);
44
+ if (showSeconds || parts.length === 0 && s >= 0) {
45
+ parts.push(`${s}${units.s}`);
46
+ }
47
+ return parts.length > 0 ? parts.join("") : useZh ? "0分钟" : "0m";
48
+ }
49
+ // Annotate the CommonJS export names for ESM import in node:
50
+ 0 && (module.exports = {
51
+ formatDuration
52
+ });
@@ -0,0 +1,4 @@
1
+ export { parseTimeRange } from './parseTimeRange';
2
+ export type { ParseTimeRangeResult } from './parseTimeRange';
3
+ export { formatDuration } from './formatDuration';
4
+ export { formatTime, formatDate, formatWeekday, getDayjsLocale, getRelativeDay, getRelativeDayLabel, getDatePartDisplay, } from '../../pisellDateTimeDisplay/utils';
@@ -0,0 +1,47 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __export = (target, all) => {
6
+ for (var name in all)
7
+ __defProp(target, name, { get: all[name], enumerable: true });
8
+ };
9
+ var __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from === "object" || typeof from === "function") {
11
+ for (let key of __getOwnPropNames(from))
12
+ if (!__hasOwnProp.call(to, key) && key !== except)
13
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
14
+ }
15
+ return to;
16
+ };
17
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
+
19
+ // src/components/pisellTimeRangeDisplay/utils/index.ts
20
+ var utils_exports = {};
21
+ __export(utils_exports, {
22
+ formatDate: () => import_utils.formatDate,
23
+ formatDuration: () => import_formatDuration.formatDuration,
24
+ formatTime: () => import_utils.formatTime,
25
+ formatWeekday: () => import_utils.formatWeekday,
26
+ getDatePartDisplay: () => import_utils.getDatePartDisplay,
27
+ getDayjsLocale: () => import_utils.getDayjsLocale,
28
+ getRelativeDay: () => import_utils.getRelativeDay,
29
+ getRelativeDayLabel: () => import_utils.getRelativeDayLabel,
30
+ parseTimeRange: () => import_parseTimeRange.parseTimeRange
31
+ });
32
+ module.exports = __toCommonJS(utils_exports);
33
+ var import_parseTimeRange = require("./parseTimeRange");
34
+ var import_formatDuration = require("./formatDuration");
35
+ var import_utils = require("../../pisellDateTimeDisplay/utils");
36
+ // Annotate the CommonJS export names for ESM import in node:
37
+ 0 && (module.exports = {
38
+ formatDate,
39
+ formatDuration,
40
+ formatTime,
41
+ formatWeekday,
42
+ getDatePartDisplay,
43
+ getDayjsLocale,
44
+ getRelativeDay,
45
+ getRelativeDayLabel,
46
+ parseTimeRange
47
+ });
@@ -0,0 +1,23 @@
1
+ import { type Dayjs } from 'dayjs';
2
+ import type { DayjsLike } from '../types';
3
+ export interface ParseTimeRangeResult {
4
+ /** 开始时间(已应用 locale) */
5
+ start: Dayjs;
6
+ /** 结束时间(已应用 locale) */
7
+ end: Dayjs;
8
+ /** 是否同一天(按本地时区自然日判定) */
9
+ isSameDay: boolean;
10
+ }
11
+ /**
12
+ * 解析 startAt / endAt 为 Dayjs,并判定是否同一天
13
+ *
14
+ * @param startAt 开始时间(dayjs 兼容值)
15
+ * @param endAt 结束时间(dayjs 兼容值)
16
+ * @param locale dayjs locale,可选
17
+ * @returns { start, end, isSameDay }
18
+ *
19
+ * @example
20
+ * parseTimeRange('2026-02-04 09:00', '2026-02-04 18:00', 'zh-cn')
21
+ * // => { start: Dayjs, end: Dayjs, isSameDay: true }
22
+ */
23
+ export declare function parseTimeRange(startAt: DayjsLike, endAt: DayjsLike, locale?: string): ParseTimeRangeResult;
@@ -0,0 +1,49 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf;
6
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
7
+ var __export = (target, all) => {
8
+ for (var name in all)
9
+ __defProp(target, name, { get: all[name], enumerable: true });
10
+ };
11
+ var __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from === "object" || typeof from === "function") {
13
+ for (let key of __getOwnPropNames(from))
14
+ if (!__hasOwnProp.call(to, key) && key !== except)
15
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
16
+ }
17
+ return to;
18
+ };
19
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
24
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
25
+ mod
26
+ ));
27
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
28
+
29
+ // src/components/pisellTimeRangeDisplay/utils/parseTimeRange.ts
30
+ var parseTimeRange_exports = {};
31
+ __export(parseTimeRange_exports, {
32
+ parseTimeRange: () => parseTimeRange
33
+ });
34
+ module.exports = __toCommonJS(parseTimeRange_exports);
35
+ var import_dayjs = __toESM(require("dayjs"));
36
+ function parseTimeRange(startAt, endAt, locale) {
37
+ let start = (0, import_dayjs.default)(startAt);
38
+ let end = (0, import_dayjs.default)(endAt);
39
+ if (locale) {
40
+ start = start.locale(locale);
41
+ end = end.locale(locale);
42
+ }
43
+ const isSameDay = start.isSame(end, "day");
44
+ return { start, end, isSameDay };
45
+ }
46
+ // Annotate the CommonJS export names for ESM import in node:
47
+ 0 && (module.exports = {
48
+ parseTimeRange
49
+ });
@@ -2,6 +2,8 @@ import React from 'react';
2
2
  import 'dayjs/locale/zh-cn';
3
3
  import 'dayjs/locale/en';
4
4
  import 'dayjs/locale/zh-tw';
5
+ import 'dayjs/locale/ja';
6
+ import 'dayjs/locale/pt';
5
7
  import './index.less';
6
8
  declare const TimeRange: (props: any) => React.JSX.Element | null;
7
9
  export default TimeRange;
@@ -40,12 +40,16 @@ var import_dayjs = __toESM(require("dayjs"));
40
40
  var import_zh_cn = require("dayjs/locale/zh-cn");
41
41
  var import_en = require("dayjs/locale/en");
42
42
  var import_zh_tw = require("dayjs/locale/zh-tw");
43
+ var import_ja = require("dayjs/locale/ja");
44
+ var import_pt = require("dayjs/locale/pt");
43
45
  var import_index = require("./index.less");
44
46
  var import__ = require("../../index");
45
47
  var localeTypes = {
46
48
  "en-US": "en",
47
49
  "zh-CN": "zh-cn",
48
- "zh-HK": "zh-tw"
50
+ "zh-HK": "zh-tw",
51
+ "ja": "ja",
52
+ "pt": "pt"
49
53
  };
50
54
  var TimeRange = (props) => {
51
55
  const { dataSource = {} } = props;
@@ -95,5 +95,69 @@ declare const _default: {
95
95
  'pisell2.product.card.add.holder.modal.add': string;
96
96
  'pisell2.product.card.closing-soon.warning': string;
97
97
  };
98
+ ja: {
99
+ 'pisell2.product.card.discount.reason': string;
100
+ 'pisell2.cart.sku-card.more': string;
101
+ 'pisell2.cart.sku-card.packages.title': string;
102
+ 'pisell2.cart.sku-card.sales.title': string;
103
+ 'pisell2.cart.sku-card.actions.delete': string;
104
+ 'pisell2.cart.sku-card.unassigned': string;
105
+ 'pisell2.product.card.day': (val: number) => string;
106
+ 'pisell2.product.card.day.event': (val: number) => string;
107
+ 'pisell2.product.card.minute': (val: number) => string;
108
+ 'pisell2.product.card.discount.note': string;
109
+ 'pisell2.product.card.edit': string;
110
+ 'pisell2.product.card.discount.add.note': string;
111
+ 'pisell2.product.card.discount.edit.note': string;
112
+ 'pisell2.product.card.confirm': string;
113
+ 'pisell2.product.card.cancel': string;
114
+ 'pisell2.product.card.note.pla': string;
115
+ 'pisell2.product.card.items.package': string;
116
+ 'pisell2.product.card.view-all': string;
117
+ 'pisell2.product.card.view-less': string;
118
+ 'pisell2.product.card.add.holder.button.text': (val: string) => string;
119
+ 'pisell2.product.card.add.holder.placeholder': (val: string) => string;
120
+ 'pisell2.product.card.add.holder.placeholder.multiple': (num: number, val: string) => string;
121
+ 'pisell2.product.card.add.holder.modal.title.1': string;
122
+ 'pisell2.product.card.hour.minute': (hour: number, minute: number) => string;
123
+ 'pisell2.product.card.sales': string;
124
+ 'pisell2.product.card.add.holder.modal.cancel': string;
125
+ 'pisell2.product.card.add.holder.modal.clear': string;
126
+ 'pisell2.product.card.add.holder.modal.apply': string;
127
+ 'pisell2.product.card.add.holder.modal.add': string;
128
+ 'pisell2.product.card.closing-soon.warning': string;
129
+ };
130
+ pt: {
131
+ 'pisell2.product.card.discount.reason': string;
132
+ 'pisell2.cart.sku-card.more': string;
133
+ 'pisell2.cart.sku-card.packages.title': string;
134
+ 'pisell2.cart.sku-card.sales.title': string;
135
+ 'pisell2.cart.sku-card.actions.delete': string;
136
+ 'pisell2.cart.sku-card.unassigned': string;
137
+ 'pisell2.product.card.day': (val: number) => string;
138
+ 'pisell2.product.card.day.event': (val: number) => string;
139
+ 'pisell2.product.card.minute': (val: number) => string;
140
+ 'pisell2.product.card.discount.note': string;
141
+ 'pisell2.product.card.edit': string;
142
+ 'pisell2.product.card.discount.add.note': string;
143
+ 'pisell2.product.card.discount.edit.note': string;
144
+ 'pisell2.product.card.confirm': string;
145
+ 'pisell2.product.card.cancel': string;
146
+ 'pisell2.product.card.note.pla': string;
147
+ 'pisell2.product.card.items.package': string;
148
+ 'pisell2.product.card.view-all': string;
149
+ 'pisell2.product.card.view-less': string;
150
+ 'pisell2.product.card.add.holder.button.text': (val: string) => string;
151
+ 'pisell2.product.card.add.holder.placeholder': (val: string) => string;
152
+ 'pisell2.product.card.add.holder.placeholder.multiple': (num: number, val: string) => string;
153
+ 'pisell2.product.card.add.holder.modal.title.1': string;
154
+ 'pisell2.product.card.hour.minute': (hour: number, minute: number) => string;
155
+ 'pisell2.product.card.sales': string;
156
+ 'pisell2.product.card.add.holder.modal.cancel': string;
157
+ 'pisell2.product.card.add.holder.modal.clear': string;
158
+ 'pisell2.product.card.add.holder.modal.apply': string;
159
+ 'pisell2.product.card.add.holder.modal.add': string;
160
+ 'pisell2.product.card.closing-soon.warning': string;
161
+ };
98
162
  };
99
163
  export default _default;
@@ -60,5 +60,23 @@ var locales_default = {
60
60
  "pisell2.cart.sku-card.sales.title": "銷售",
61
61
  "pisell2.cart.sku-card.actions.delete": "刪除",
62
62
  "pisell2.cart.sku-card.unassigned": "未分配"
63
+ },
64
+ ja: {
65
+ ...import_locales.default.ja,
66
+ "pisell2.product.card.discount.reason": "割引理由",
67
+ "pisell2.cart.sku-card.more": "もっと...",
68
+ "pisell2.cart.sku-card.packages.title": "パッケージ内のアイテム",
69
+ "pisell2.cart.sku-card.sales.title": "セール",
70
+ "pisell2.cart.sku-card.actions.delete": "削除",
71
+ "pisell2.cart.sku-card.unassigned": "未割り当て"
72
+ },
73
+ pt: {
74
+ ...import_locales.default.pt,
75
+ "pisell2.product.card.discount.reason": "Motivo do desconto",
76
+ "pisell2.cart.sku-card.more": "mais...",
77
+ "pisell2.cart.sku-card.packages.title": "Itens no pacote",
78
+ "pisell2.cart.sku-card.sales.title": "Vendas",
79
+ "pisell2.cart.sku-card.actions.delete": "Excluir",
80
+ "pisell2.cart.sku-card.unassigned": "Não atribuído"
63
81
  }
64
82
  };
@@ -80,5 +80,59 @@ declare const _default: {
80
80
  'pisell2.product.card.add.holder.modal.add': string;
81
81
  'pisell2.product.card.closing-soon.warning': string;
82
82
  };
83
+ ja: {
84
+ 'pisell2.product.card.day': (val: number) => string;
85
+ 'pisell2.product.card.day.event': (val: number) => string;
86
+ 'pisell2.product.card.minute': (val: number) => string;
87
+ 'pisell2.product.card.discount.reason': string;
88
+ 'pisell2.product.card.discount.note': string;
89
+ 'pisell2.product.card.edit': string;
90
+ 'pisell2.product.card.discount.add.note': string;
91
+ 'pisell2.product.card.discount.edit.note': string;
92
+ 'pisell2.product.card.confirm': string;
93
+ 'pisell2.product.card.cancel': string;
94
+ 'pisell2.product.card.note.pla': string;
95
+ 'pisell2.product.card.items.package': string;
96
+ 'pisell2.product.card.view-all': string;
97
+ 'pisell2.product.card.view-less': string;
98
+ 'pisell2.product.card.add.holder.button.text': (val: string) => string;
99
+ 'pisell2.product.card.add.holder.placeholder': (val: string) => string;
100
+ 'pisell2.product.card.add.holder.placeholder.multiple': (num: number, val: string) => string;
101
+ 'pisell2.product.card.add.holder.modal.title.1': string;
102
+ 'pisell2.product.card.hour.minute': (hour: number, minute: number) => string;
103
+ 'pisell2.product.card.sales': string;
104
+ 'pisell2.product.card.add.holder.modal.cancel': string;
105
+ 'pisell2.product.card.add.holder.modal.clear': string;
106
+ 'pisell2.product.card.add.holder.modal.apply': string;
107
+ 'pisell2.product.card.add.holder.modal.add': string;
108
+ 'pisell2.product.card.closing-soon.warning': string;
109
+ };
110
+ pt: {
111
+ 'pisell2.product.card.day': (val: number) => string;
112
+ 'pisell2.product.card.day.event': (val: number) => string;
113
+ 'pisell2.product.card.minute': (val: number) => string;
114
+ 'pisell2.product.card.discount.reason': string;
115
+ 'pisell2.product.card.discount.note': string;
116
+ 'pisell2.product.card.edit': string;
117
+ 'pisell2.product.card.discount.add.note': string;
118
+ 'pisell2.product.card.discount.edit.note': string;
119
+ 'pisell2.product.card.confirm': string;
120
+ 'pisell2.product.card.cancel': string;
121
+ 'pisell2.product.card.note.pla': string;
122
+ 'pisell2.product.card.items.package': string;
123
+ 'pisell2.product.card.view-all': string;
124
+ 'pisell2.product.card.view-less': string;
125
+ 'pisell2.product.card.add.holder.button.text': (val: string) => string;
126
+ 'pisell2.product.card.add.holder.placeholder': (val: string) => string;
127
+ 'pisell2.product.card.add.holder.placeholder.multiple': (num: number, val: string) => string;
128
+ 'pisell2.product.card.add.holder.modal.title.1': string;
129
+ 'pisell2.product.card.hour.minute': (hour: number, minute: number) => string;
130
+ 'pisell2.product.card.sales': string;
131
+ 'pisell2.product.card.add.holder.modal.cancel': string;
132
+ 'pisell2.product.card.add.holder.modal.clear': string;
133
+ 'pisell2.product.card.add.holder.modal.apply': string;
134
+ 'pisell2.product.card.add.holder.modal.add': string;
135
+ 'pisell2.product.card.closing-soon.warning': string;
136
+ };
83
137
  };
84
138
  export default _default;
@@ -112,5 +112,65 @@ var locales_default = {
112
112
  "pisell2.product.card.add.holder.modal.apply": "應用",
113
113
  "pisell2.product.card.add.holder.modal.add": "添加",
114
114
  "pisell2.product.card.closing-soon.warning": "當前入場時間臨近營業結束,請確認是否仍要購買。"
115
+ },
116
+ ja: {
117
+ "pisell2.product.card.day": (val) => `${val > 1 ? "日" : "日"}`,
118
+ "pisell2.product.card.day.event": (val) => `${val > 1 ? "個のイベント" : "個のイベント"}`,
119
+ "pisell2.product.card.minute": (val) => `${val > 1 ? "分" : "分"}`,
120
+ "pisell2.product.card.discount.reason": "割引理由",
121
+ "pisell2.product.card.discount.note": "備考",
122
+ "pisell2.product.card.edit": "編集",
123
+ "pisell2.product.card.discount.add.note": "備考を追加",
124
+ "pisell2.product.card.discount.edit.note": "備考を編集",
125
+ "pisell2.product.card.confirm": "確認",
126
+ "pisell2.product.card.cancel": "キャンセル",
127
+ "pisell2.product.card.note.pla": "備考を入力してください",
128
+ "pisell2.product.card.items.package": "パッケージ内のアイテム",
129
+ "pisell2.product.card.view-all": "すべて表示",
130
+ "pisell2.product.card.view-less": "折りたたむ",
131
+ "pisell2.product.card.add.holder.button.text": (val) => `${val || ""}を追加`,
132
+ "pisell2.product.card.add.holder.placeholder": (val) => `${val || ""}を選択してください`,
133
+ "pisell2.product.card.add.holder.placeholder.multiple": (num, val) => `${num}${val || ""}を選択してください`,
134
+ "pisell2.product.card.add.holder.modal.title.1": `選択してください`,
135
+ "pisell2.product.card.hour.minute": (hour, minute) => {
136
+ if (hour <= 0 && minute <= 0) return `${0}分`;
137
+ return `${hour > 0 ? `${hour}時間` : ""}${hour > 0 && minute > 0 ? " " : ""}${minute > 0 ? `${minute}分` : ""}`;
138
+ },
139
+ "pisell2.product.card.sales": "販売",
140
+ "pisell2.product.card.add.holder.modal.cancel": "キャンセル",
141
+ "pisell2.product.card.add.holder.modal.clear": "クリア",
142
+ "pisell2.product.card.add.holder.modal.apply": "適用",
143
+ "pisell2.product.card.add.holder.modal.add": "新規追加",
144
+ "pisell2.product.card.closing-soon.warning": "会場はまもなく閉場します。訪問に十分な時間があることを確認してください。"
145
+ },
146
+ pt: {
147
+ "pisell2.product.card.day": (val) => `${val > 1 ? " dias" : " dia"}`,
148
+ "pisell2.product.card.day.event": (val) => `${val > 1 ? " eventos" : " evento"}`,
149
+ "pisell2.product.card.minute": (val) => `${val > 1 ? " minutos" : " minuto"}`,
150
+ "pisell2.product.card.discount.reason": "Motivo do desconto",
151
+ "pisell2.product.card.discount.note": "Nota",
152
+ "pisell2.product.card.edit": "Editar",
153
+ "pisell2.product.card.discount.add.note": "Adicionar nota",
154
+ "pisell2.product.card.discount.edit.note": "Editar nota",
155
+ "pisell2.product.card.confirm": "Confirmar",
156
+ "pisell2.product.card.cancel": "Cancelar",
157
+ "pisell2.product.card.note.pla": "Por favor, insira a nota",
158
+ "pisell2.product.card.items.package": "Itens no pacote",
159
+ "pisell2.product.card.view-all": "Ver tudo",
160
+ "pisell2.product.card.view-less": "Ver menos",
161
+ "pisell2.product.card.add.holder.button.text": (val) => `Adicionar ${val || ""}`,
162
+ "pisell2.product.card.add.holder.placeholder": (val) => `Por favor, selecione ${val || ""}`,
163
+ "pisell2.product.card.add.holder.placeholder.multiple": (num, val) => `Por favor, selecione ${num} ${val || ""}`,
164
+ "pisell2.product.card.add.holder.modal.title.1": `Por favor, selecione`,
165
+ "pisell2.product.card.hour.minute": (hour, minute) => {
166
+ if (hour <= 0 && minute <= 0) return `${0}min`;
167
+ return `${hour > 0 ? `${hour}h` : ""}${hour > 0 && minute > 0 ? " " : ""}${minute > 0 ? `${minute}min` : ""}`;
168
+ },
169
+ "pisell2.product.card.sales": "Vendas",
170
+ "pisell2.product.card.add.holder.modal.cancel": "Cancelar",
171
+ "pisell2.product.card.add.holder.modal.clear": "Limpar",
172
+ "pisell2.product.card.add.holder.modal.apply": "Aplicar",
173
+ "pisell2.product.card.add.holder.modal.add": "Adicionar Novo",
174
+ "pisell2.product.card.closing-soon.warning": "O local fechará em breve. Por favor, certifique-se de ter tempo suficiente para sua visita."
115
175
  }
116
176
  };
@@ -1,6 +1,8 @@
1
1
  import 'dayjs/locale/zh-cn';
2
2
  import 'dayjs/locale/en';
3
3
  import 'dayjs/locale/zh-tw';
4
+ import 'dayjs/locale/ja';
5
+ import 'dayjs/locale/pt';
4
6
  /**
5
7
  * @title: 是否英文
6
8
  * @description:
@@ -39,6 +39,8 @@ var import_utils = require("@pisell/utils");
39
39
  var import_zh_cn = require("dayjs/locale/zh-cn");
40
40
  var import_en = require("dayjs/locale/en");
41
41
  var import_zh_tw = require("dayjs/locale/zh-tw");
42
+ var import_ja = require("dayjs/locale/ja");
43
+ var import_pt = require("dayjs/locale/pt");
42
44
  var import_useEngineContext = __toESM(require("../../hooks/useEngineContext"));
43
45
  var isEn = (item) => {
44
46
  const locale = (item == null ? void 0 : item.locale) || "en-US";
@@ -46,7 +48,9 @@ var isEn = (item) => {
46
48
  const localeTypes = {
47
49
  "en-US": "en",
48
50
  "zh-CN": "zh-cn",
49
- "zh-HK": "zh-tw"
51
+ "zh-HK": "zh-tw",
52
+ "ja": "ja",
53
+ "pt": "pt"
50
54
  };
51
55
  import_dayjs.default.locale(localeTypes[locale]);
52
56
  return _isEn;
@@ -70,7 +74,9 @@ var getServiceTime = (item, currentDate) => {
70
74
  const localeTypes = {
71
75
  "en-US": "en",
72
76
  "zh-CN": "zh-cn",
73
- "zh-HK": "zh-tw"
77
+ "zh-HK": "zh-tw",
78
+ "ja": "ja",
79
+ "pt": "pt"
74
80
  };
75
81
  import_dayjs.default.locale(localeTypes[locale]);
76
82
  let startDate = (0, import_dayjs.default)(item == null ? void 0 : item.start_date);
@@ -4,6 +4,8 @@ declare type Value = {
4
4
  en: string;
5
5
  'zh-CN': string;
6
6
  'zh-HK': string;
7
+ 'ja': string;
8
+ 'pt': string;
7
9
  };
8
10
  interface TranslationProps {
9
11
  value: Value;
@@ -64,6 +64,20 @@ var defaultGlobal = {
64
64
  text: "繁體中文",
65
65
  primary: 0,
66
66
  status: "published"
67
+ },
68
+ {
69
+ id: 4,
70
+ code: "ja",
71
+ text: "日本語",
72
+ primary: 0,
73
+ status: "published"
74
+ },
75
+ {
76
+ id: 5,
77
+ code: "pt",
78
+ text: "Português",
79
+ primary: 0,
80
+ status: "published"
67
81
  }
68
82
  ]
69
83
  },
@@ -2,6 +2,8 @@ export declare const locales: {
2
2
  en: string;
3
3
  "zh-CN": string;
4
4
  "zh-HK": string;
5
+ ja: string;
6
+ pt: string;
5
7
  };
6
8
  export declare const checkIfAllValuesAreEqual: (obj: any) => boolean;
7
9
  export declare const createTranslationText: (text: string, isAll?: boolean) => any;
@@ -27,7 +27,9 @@ module.exports = __toCommonJS(utils_exports);
27
27
  var locales = {
28
28
  en: "",
29
29
  "zh-CN": "",
30
- "zh-HK": ""
30
+ "zh-HK": "",
31
+ "ja": "",
32
+ "pt": ""
31
33
  };
32
34
  var checkIfAllValuesAreEqual = (obj) => {
33
35
  const valuesArray = Object.values(obj);
@@ -7,6 +7,8 @@ export interface WalletCardItem {
7
7
  en: string;
8
8
  'zh-CN': string;
9
9
  'zh-HK': string;
10
+ 'ja': string;
11
+ 'pt': string;
10
12
  };
11
13
  display?: 0 | 1;
12
14
  value?: number;
@@ -74,7 +74,9 @@ var DEFAULT_PROPS = {
74
74
  original: "Balance",
75
75
  "zh-CN": "充值卡",
76
76
  "zh-HK": "充值卡",
77
- en: "Balance"
77
+ en: "Balance",
78
+ "ja": "残高",
79
+ "pt": "Saldo"
78
80
  }
79
81
  },
80
82
  {
@@ -84,7 +86,9 @@ var DEFAULT_PROPS = {
84
86
  original: "Points",
85
87
  "zh-CN": "积分卡",
86
88
  "zh-HK": "積分卡",
87
- en: "Points"
89
+ en: "Points",
90
+ "ja": "ポイント",
91
+ "pt": "Pontos"
88
92
  }
89
93
  },
90
94
  {
@@ -94,7 +98,9 @@ var DEFAULT_PROPS = {
94
98
  original: "Voucher",
95
99
  "zh-CN": "代金券",
96
100
  "zh-HK": "代金券",
97
- en: "Voucher"
101
+ en: "Voucher",
102
+ "ja": "クーポン",
103
+ "pt": "Cupom"
98
104
  }
99
105
  },
100
106
  {
@@ -104,6 +110,8 @@ var DEFAULT_PROPS = {
104
110
  original: "Discount",
105
111
  "zh-CN": "折扣卡",
106
112
  "zh-HK": "折扣卡",
113
+ "ja": "割引カード",
114
+ "pt": "Cartão de desconto",
107
115
  en: "Discount"
108
116
  }
109
117
  }
package/lib/index.d.ts CHANGED
@@ -61,6 +61,8 @@ export type { PisellStatisticProps as CardMetricItemProps } from './components/c
61
61
  export { default as CardPro } from './components/cardPro';
62
62
  export { default as Cascader } from './components/cascader';
63
63
  export { default as Checkbox } from './components/checkbox';
64
+ export { PisellTimeRangeDisplay } from './components/pisellTimeRangeDisplay';
65
+ export type { PisellTimeRangeDisplayProps } from './components/pisellTimeRangeDisplay';
64
66
  export { default as ClassicLayout } from './components/classicLayout';
65
67
  export { default as Collapse } from './components/collapse';
66
68
  export { default as Component } from './components/component';
package/lib/index.js CHANGED
@@ -189,6 +189,7 @@ __export(src_exports, {
189
189
  PisellTabbarTemplate1: () => import_Template1.default,
190
190
  PisellTags: () => import_pisellTags.default,
191
191
  PisellText: () => import_pisellText.default,
192
+ PisellTimeRangeDisplay: () => import_pisellTimeRangeDisplay.PisellTimeRangeDisplay,
192
193
  PisellToast: () => import_pisellToast.default,
193
194
  PisellToolBar: () => import_ToolBar.default,
194
195
  PisellTooltip: () => import_pisellTooltip.default,
@@ -282,6 +283,7 @@ var import_cardMetricItem = __toESM(require("./components/cardMetricItem"));
282
283
  var import_cardPro = __toESM(require("./components/cardPro"));
283
284
  var import_cascader = __toESM(require("./components/cascader"));
284
285
  var import_checkbox = __toESM(require("./components/checkbox"));
286
+ var import_pisellTimeRangeDisplay = require("./components/pisellTimeRangeDisplay");
285
287
  var import_classicLayout = __toESM(require("./components/classicLayout"));
286
288
  var import_collapse = __toESM(require("./components/collapse"));
287
289
  var import_component = __toESM(require("./components/component"));
@@ -594,6 +596,7 @@ var import_pisellFind = require("./components/pisellFind");
594
596
  PisellTabbarTemplate1,
595
597
  PisellTags,
596
598
  PisellText,
599
+ PisellTimeRangeDisplay,
597
600
  PisellToast,
598
601
  PisellToolBar,
599
602
  PisellTooltip,
@@ -35,6 +35,8 @@ module.exports = __toCommonJS(locales_exports);
35
35
  var import_zh_CN = __toESM(require("./zh-CN"));
36
36
  var import_en_US = __toESM(require("./en-US"));
37
37
  var import_zh_TW = __toESM(require("./zh-TW"));
38
+ var import_ja = __toESM(require("./ja"));
39
+ var import_pt = __toESM(require("./pt"));
38
40
  var import_locale = require("../utils/locale");
39
41
  var langMap = {
40
42
  "zh-CN": import_zh_CN.default,
@@ -42,7 +44,9 @@ var langMap = {
42
44
  "zh-TW": import_zh_TW.default,
43
45
  "zh-HK": import_zh_TW.default,
44
46
  en: import_en_US.default,
45
- original: import_en_US.default
47
+ original: import_en_US.default,
48
+ "ja": import_ja.default,
49
+ "pt": import_pt.default
46
50
  };
47
51
  var getText = (id) => {
48
52
  var _a;
@@ -50,7 +54,7 @@ var getText = (id) => {
50
54
  return;
51
55
  }
52
56
  let locale = (0, import_locale.getCurrentLocale)();
53
- return ((_a = langMap == null ? void 0 : langMap[locale]) == null ? void 0 : _a[id]) || id;
57
+ return ((_a = langMap == null ? void 0 : langMap[locale]) == null ? void 0 : _a[id]) || langMap["en-US"][id] || id;
54
58
  };
55
59
  // Annotate the CommonJS export names for ESM import in node:
56
60
  0 && (module.exports = {