@das-fed/upf-utils 6.4.0-hot.13 → 6.4.0-hot.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/api-services/es5.js +1811 -1697
- package/api-services/index.js +1456 -1363
- package/api-services/index.js.gz +0 -0
- package/api-services/modules/app-manage/es5.js +2116 -2001
- package/api-services/modules/app-manage/index.js +1846 -1752
- package/api-services/modules/app-manage/index.js.gz +0 -0
- package/api-services/modules/authentication/es5.js +1769 -1666
- package/api-services/modules/authentication/index.js +1509 -1433
- package/api-services/modules/authentication/index.js.gz +0 -0
- package/api-services/modules/bems/es5.js +1732 -1629
- package/api-services/modules/bems/index.js +1468 -1392
- package/api-services/modules/bems/index.js.gz +0 -0
- package/api-services/modules/contract/es5.js +1769 -1666
- package/api-services/modules/contract/index.js +1509 -1433
- package/api-services/modules/contract/index.js.gz +0 -0
- package/api-services/modules/duty-manage/es5.js +1953 -1850
- package/api-services/modules/duty-manage/index.js +1688 -1612
- package/api-services/modules/duty-manage/index.js.gz +0 -0
- package/api-services/modules/enterpriseright/es5.js +1769 -1666
- package/api-services/modules/enterpriseright/index.js +1509 -1433
- package/api-services/modules/enterpriseright/index.js.gz +0 -0
- package/api-services/modules/es5.js +1394 -1292
- package/api-services/modules/file/es5.js +1701 -1611
- package/api-services/modules/file/index.js +1411 -1354
- package/api-services/modules/file/index.js.gz +0 -0
- package/api-services/modules/gateway-edge/es5.js +1769 -1666
- package/api-services/modules/gateway-edge/index.js +1509 -1433
- package/api-services/modules/gateway-edge/index.js.gz +0 -0
- package/api-services/modules/index.js +1063 -988
- package/api-services/modules/index.js.gz +0 -0
- package/api-services/modules/iot/es5.js +2005 -1890
- package/api-services/modules/iot/index.js +1741 -1647
- package/api-services/modules/iot/index.js.gz +0 -0
- package/api-services/modules/justauth/es5.js +1945 -1845
- package/api-services/modules/justauth/index.js +1672 -1600
- package/api-services/modules/justauth/index.js.gz +0 -0
- package/api-services/modules/knowledge/es5.js +2115 -2003
- package/api-services/modules/knowledge/index.js +1846 -1756
- package/api-services/modules/knowledge/index.js.gz +0 -0
- package/api-services/modules/link/es5.js +1769 -1666
- package/api-services/modules/link/index.js +1509 -1433
- package/api-services/modules/link/index.js.gz +0 -0
- package/api-services/modules/permission/es5.js +1769 -1666
- package/api-services/modules/permission/index.js +1509 -1433
- package/api-services/modules/permission/index.js.gz +0 -0
- package/api-services/modules/platformManage/es5.js +2068 -1977
- package/api-services/modules/platformManage/index.js +1829 -1771
- package/api-services/modules/platformManage/index.js.gz +0 -0
- package/api-services/modules/portal/es5.js +1769 -1666
- package/api-services/modules/portal/index.js +1509 -1433
- package/api-services/modules/portal/index.js.gz +0 -0
- package/api-services/modules/space-manage/es5.js +1950 -1847
- package/api-services/modules/space-manage/index.js +1681 -1605
- package/api-services/modules/space-manage/index.js.gz +0 -0
- package/api-services/modules/super-admin/es5.js +1942 -1851
- package/api-services/modules/super-admin/index.js +1685 -1627
- package/api-services/modules/super-admin/index.js.gz +0 -0
- package/api-services/modules/supplier/es5.js +1771 -1668
- package/api-services/modules/supplier/index.js +1511 -1435
- package/api-services/modules/supplier/index.js.gz +0 -0
- package/api-services/modules/supplychain-manage/es5.js +2116 -2001
- package/api-services/modules/supplychain-manage/index.js +1846 -1752
- package/api-services/modules/supplychain-manage/index.js.gz +0 -0
- package/api-services/modules/systemConfiguration/es5.js +1769 -1666
- package/api-services/modules/systemConfiguration/index.js +1509 -1433
- package/api-services/modules/systemConfiguration/index.js.gz +0 -0
- package/api-services/modules/tool/es5.js +2116 -2001
- package/api-services/modules/tool/index.js +1846 -1752
- package/api-services/modules/tool/index.js.gz +0 -0
- package/api-services/src/create-service/es5.js +2114 -1999
- package/api-services/src/create-service/index.js +1844 -1750
- package/api-services/src/create-service/index.js.gz +0 -0
- package/common-info/es5.js +2125 -2034
- package/common-info/getPermissionMethod/es5.js +1943 -1852
- package/common-info/getPermissionMethod/index.js +1700 -1642
- package/common-info/getPermissionMethod/index.js.gz +0 -0
- package/common-info/index.js +1856 -1798
- package/common-info/index.js.gz +0 -0
- package/common-tools/timezone-format/es5.d.ts +56 -2
- package/common-tools/timezone-format/es5.js +778 -512
- package/common-tools/timezone-format/index.d.ts +56 -2
- package/common-tools/timezone-format/index.js +539 -323
- package/common-tools/timezone-format/index.js.gz +0 -0
- package/create-api-service/es5.js +2115 -2000
- package/create-api-service/index.js +1845 -1751
- package/create-api-service/index.js.gz +0 -0
- package/dimple-canvas/use-dimple-canvas/core/antv-x6/index.d.ts +29 -0
- package/dimple-canvas/use-dimple-canvas/core/antv-x6/index.js +19826 -0
- package/dimple-canvas/use-dimple-canvas/core/antv-x6/index.js.gz +0 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/index.d.ts +55 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/index.js +116 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/index.js.gz +0 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/add-event-listener.d.ts +104 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/add-event-listener.js +17 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/add-object/index.d.ts +8 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/add-object/index.js +51 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/add-object/index.js.gz +0 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/create-canvas.d.ts +5 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/create-canvas.js +14 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/find.d.ts +7 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/find.js +5 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/guideline.d.ts +5 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/guideline.js +180 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/guideline.js.gz +0 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/lib.d.ts +4 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/lib.js +7535 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/lib.js.gz +0 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/load-json.d.ts +6 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/load-json.js +13 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/remove-object.d.ts +6 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/remove-object.js +7 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/rule.d.ts +8 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/rule.js +193 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/rule.js.gz +0 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/transform-axis.d.ts +11 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/transform-axis.js +20 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/transformer.d.ts +5 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/transformer.js +52 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/transformer.js.gz +0 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/wheel-zoom.d.ts +4 -0
- package/dimple-canvas/use-dimple-canvas/core/konva/utils/wheel-zoom.js +14 -0
- package/dimple-canvas/use-dimple-canvas/es5.d.ts +9 -0
- package/dimple-canvas/use-dimple-canvas/es5.js +20 -0
- package/dimple-canvas/use-dimple-canvas/index.d.ts +9 -0
- package/dimple-canvas/use-dimple-canvas/index.js +10 -0
- package/esm-map.json +31 -1
- package/package.json +3 -3
- package/theme/bridge.d.ts +42 -0
- package/theme/color.d.ts +7 -0
- package/theme/es5.d.ts +15 -32
- package/theme/es5.js +1120 -651
- package/theme/index.d.ts +15 -32
- package/theme/index.js +720 -468
- package/theme/index.js.gz +0 -0
- package/theme/source-variables.d.ts +35 -0
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { Dayjs } from 'dayjs';
|
|
1
|
+
import { default as dayjs, Dayjs } from 'dayjs';
|
|
2
2
|
import { default as dayjsTimezoneIanaPlugin, PackedIanaData, PreloadDayjsIanaOptions } from './get-iana-data/dayjs-timezone-iana-plugin';
|
|
3
3
|
import { loadIanaData as loadMomentIanaData, loadIanaFromApi as loadMomentIanaFromApi, LoadIanaFromApiOptions, MomentWithTimezone, PackedIanaTzData } from './get-iana-data/moment-iana-loader';
|
|
4
4
|
|
|
5
5
|
export * from './get-iana-data';
|
|
6
6
|
export { dayjsTimezoneIanaPlugin, loadMomentIanaData, loadMomentIanaFromApi };
|
|
7
|
+
export type TimeZoneDayjsFactory = typeof dayjs;
|
|
7
8
|
export type TimeValue = string | number | Date | Dayjs | null | undefined;
|
|
8
9
|
export type TimeZoneFlag = number | string | null | undefined;
|
|
9
10
|
export type TimeZoneDateLibrary = 'dayjs' | 'moment';
|
|
@@ -94,9 +95,21 @@ export interface FormatLocalDateTimeOptions {
|
|
|
94
95
|
/** 未传 timeZone 时是否读取 sessionStorage/客户端时区。默认 false,兼容旧 toLocalDate。 */
|
|
95
96
|
useClientTimeZone?: boolean;
|
|
96
97
|
}
|
|
98
|
+
export interface FormatLocalDateTimeIntlOptions {
|
|
99
|
+
/** 输出格式,支持常用 YYYY/MM/DD/HH/mm/ss/SSS token,默认 YYYY-MM-DD HH:mm:ss。 */
|
|
100
|
+
format?: string;
|
|
101
|
+
/** 目标 IANA 时区;为空时读取当前客户端时区。 */
|
|
102
|
+
timeZone?: string | null;
|
|
103
|
+
/** Intl 本地化语言,默认 zh-CN。 */
|
|
104
|
+
locale?: string;
|
|
105
|
+
}
|
|
97
106
|
export interface ApplyIanaTimeZoneOptions {
|
|
98
107
|
/** 指定默认时区,后续 dayjs.tz(value) 可直接使用。 */
|
|
99
108
|
defaultTimeZone?: string;
|
|
109
|
+
/** 写入运行期快照的数据来源,供 mframe 注入 iframe 首屏复用。 */
|
|
110
|
+
runtimeSource?: RuntimeIanaTimeZoneDataSource;
|
|
111
|
+
/** 是否同步 window.__UPF_IANA_TIMEZONE_DATA__ 并派发事件,默认 true。 */
|
|
112
|
+
syncRuntimeSnapshot?: boolean;
|
|
100
113
|
}
|
|
101
114
|
export interface LoadIanaTimeZoneOptions extends PreloadDayjsIanaOptions, ApplyIanaTimeZoneOptions {
|
|
102
115
|
}
|
|
@@ -107,6 +120,40 @@ export interface ApplyIanaTimeZoneResult {
|
|
|
107
120
|
export interface LoadMomentIanaTimeZoneOptions extends LoadIanaFromApiOptions {
|
|
108
121
|
url?: string;
|
|
109
122
|
}
|
|
123
|
+
export interface ClientTimeZoneChangeDetail {
|
|
124
|
+
/** 当前用户选择的 IANA 时区;空字符串表示清空选择并回退本机推断。 */
|
|
125
|
+
timeZone: string;
|
|
126
|
+
/** 触发来源,用于区分主应用、子应用同步或本窗口事件。 */
|
|
127
|
+
source?: string;
|
|
128
|
+
timestamp: number;
|
|
129
|
+
}
|
|
130
|
+
export interface SetClientTimeZoneOptions {
|
|
131
|
+
/** 是否写入 sessionStorage.timeZone,默认 true。 */
|
|
132
|
+
persist?: boolean;
|
|
133
|
+
/** 是否通知 onClientTimeZoneChange 订阅者,默认 true。 */
|
|
134
|
+
notify?: boolean;
|
|
135
|
+
/** 是否派发 window timezonechange 事件,默认 true。 */
|
|
136
|
+
dispatchEvent?: boolean;
|
|
137
|
+
/** 是否同步 dayjs 默认时区,默认 true。 */
|
|
138
|
+
syncDefault?: boolean;
|
|
139
|
+
source?: string;
|
|
140
|
+
}
|
|
141
|
+
export type ClientTimeZoneChangeHandler = (timeZone: string, detail: ClientTimeZoneChangeDetail) => void;
|
|
142
|
+
export type RuntimeIanaTimeZoneDataSource = 'iana' | 'fallback';
|
|
143
|
+
export interface RuntimeIanaTimeZoneDataSnapshot extends PackedIanaData {
|
|
144
|
+
/** 数据来源:接口 IANA 数据或降级兜底数据。 */
|
|
145
|
+
source: RuntimeIanaTimeZoneDataSource;
|
|
146
|
+
/** 写入快照时间,供宿主和 iframe 判断是否需要刷新。 */
|
|
147
|
+
timestamp: number;
|
|
148
|
+
}
|
|
149
|
+
export declare const TIMEZONE_CHANGE_EVENT = "timezonechange";
|
|
150
|
+
export declare const UPF_TIMEZONE_MESSAGE_TYPE = "__UPF_TIMEZONE_CHANGE__";
|
|
151
|
+
export declare const IANA_TIMEZONE_DATA_CHANGE_EVENT = "ianatimezonedatachange";
|
|
152
|
+
export declare const timeZoneDayjs: TimeZoneDayjsFactory;
|
|
153
|
+
export declare const setRuntimeIanaTimeZoneDataSnapshot: (data: Pick<PackedIanaData, "version" | "zones" | "links">, source?: RuntimeIanaTimeZoneDataSource) => RuntimeIanaTimeZoneDataSnapshot;
|
|
154
|
+
export declare const getRuntimeIanaTimeZoneDataSnapshot: () => RuntimeIanaTimeZoneDataSnapshot | null;
|
|
155
|
+
export declare const getRuntimeNameZoneDataSnapshot: () => RuntimeIanaTimeZoneDataSnapshot | null;
|
|
156
|
+
export declare const clientTimeZone: any;
|
|
110
157
|
export declare const isKnownTimeZone: (timeZone?: string | null) => any;
|
|
111
158
|
export declare const rebuildKnownTimeZoneIds: (data: Pick<PackedIanaData, "zones" | "links">) => any;
|
|
112
159
|
export declare const getKnownTimeZoneIds: () => any;
|
|
@@ -114,13 +161,20 @@ export declare const applyDayjsIanaTimeZoneData: (data: PackedIanaData, options?
|
|
|
114
161
|
export declare const loadDayjsIanaTimeZoneData: (options?: LoadIanaTimeZoneOptions) => Promise<ApplyIanaTimeZoneResult>;
|
|
115
162
|
export declare const applyMomentIanaTimeZoneData: (moment: MomentWithTimezone, data: PackedIanaTzData) => PackedIanaTzData;
|
|
116
163
|
export declare const loadMomentIanaTimeZoneData: (moment: MomentWithTimezone, options?: LoadMomentIanaTimeZoneOptions) => unknown;
|
|
164
|
+
export declare const setDefaultTimeZone: (timeZone?: string | null) => boolean;
|
|
165
|
+
export declare const setClientTimeZone: (timeZone?: string | null, options?: SetClientTimeZoneOptions) => any;
|
|
166
|
+
export declare const syncClientTimeZone: (source?: string) => any;
|
|
167
|
+
export declare const onClientTimeZoneChange: (handler: ClientTimeZoneChangeHandler) => () => any;
|
|
168
|
+
export declare const initClientTimeZoneSync: () => boolean;
|
|
117
169
|
export declare const getClientTimeZone: () => any;
|
|
118
170
|
export declare const resolveTimeZone: (timeZone?: string | null) => any;
|
|
119
|
-
export declare const setDefaultTimeZone: (timeZone?: string | null) => boolean;
|
|
120
171
|
export declare const normalizeLocaleCode: (locale?: string, supportedLocales?: string[]) => any;
|
|
172
|
+
export declare const getTimeZoneDayjs: () => TimeZoneDayjsFactory;
|
|
121
173
|
export declare const getZoneUtcOffset: (value: TimeValue, timeZone?: string | null) => any;
|
|
122
174
|
export declare const formatInTimeZone: (value?: TimeValue, timeZone?: string | null, format?: string) => any;
|
|
175
|
+
export declare const isMomentTimezoneFormatInstance: (moment?: unknown) => moment is MomentTimezoneFormatInstance;
|
|
123
176
|
export declare const formatLocalDateTime: (value?: TimeValue, options?: FormatLocalDateTimeOptions | string) => string;
|
|
177
|
+
export declare const formatLocalDateTimeIntl: (value?: TimeValue, options?: FormatLocalDateTimeIntlOptions | string) => string;
|
|
124
178
|
export declare const toLocalDate: (value?: TimeValue, format?: string, options?: Omit<FormatLocalDateTimeOptions, "format">) => string;
|
|
125
179
|
export declare const formatTimeZoneOffsetLabel: (value?: TimeValue, timeZone?: string | null) => string;
|
|
126
180
|
export declare const resolveUtcOffsetFallback: (option: Pick<TimeZoneOption, "timeZoneId" | "baseUtcOffsetText" | "currentUtcOffsetText">, referenceDate?: Date) => string;
|