@hairy/utils 1.0.16 → 1.0.17
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/index.cjs.js +66 -64
- package/index.d.ts +66 -68
- package/index.esm.js +67 -64
- package/index.iife.js +66 -64
- package/index.iife.min.js +1 -1
- package/package.json +6 -4
package/index.cjs.js
CHANGED
|
@@ -9,7 +9,7 @@ function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'defau
|
|
|
9
9
|
|
|
10
10
|
var dayjs__default = /*#__PURE__*/_interopDefaultLegacy(dayjs);
|
|
11
11
|
|
|
12
|
-
const
|
|
12
|
+
const colourBlend = (colorOne, colorTwo, ratio) => {
|
|
13
13
|
ratio = Math.max(Math.min(Number(ratio), 1), 0);
|
|
14
14
|
const r1 = parseInt(colorOne.slice(1, 3), 16);
|
|
15
15
|
const g1 = parseInt(colorOne.slice(3, 5), 16);
|
|
@@ -35,18 +35,18 @@ const hexToRgba = (hex, opacity) => {
|
|
|
35
35
|
};
|
|
36
36
|
};
|
|
37
37
|
const fuseThemeColor = (color) => ({
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"
|
|
42
|
-
"
|
|
43
|
-
"
|
|
44
|
-
"
|
|
45
|
-
"
|
|
46
|
-
"
|
|
47
|
-
"
|
|
48
|
-
"
|
|
49
|
-
"
|
|
38
|
+
"light-2": colourBlend("#ffffff", color, 0.8),
|
|
39
|
+
"light-4": colourBlend("#ffffff", color, 0.6),
|
|
40
|
+
"light-6": colourBlend("#ffffff", color, 0.4),
|
|
41
|
+
"light-8": colourBlend("#ffffff", color, 0.2),
|
|
42
|
+
"dark-2": colourBlend("#000000", color, 0.8),
|
|
43
|
+
"dark-4": colourBlend("#000000", color, 0.6),
|
|
44
|
+
"dark-6": colourBlend("#000000", color, 0.4),
|
|
45
|
+
"dark-8": colourBlend("#000000", color, 0.2),
|
|
46
|
+
"opacity-2": hexToRgba(color, 0.8).rgba,
|
|
47
|
+
"opacity-4": hexToRgba(color, 0.6).rgba,
|
|
48
|
+
"opacity-6": hexToRgba(color, 0.4).rgba,
|
|
49
|
+
"opacity-8": hexToRgba(color, 0.2).rgba
|
|
50
50
|
});
|
|
51
51
|
|
|
52
52
|
const formatClearHtml = (string_) => string_.replace(/<[!/]*[^<>]*>/gi, "");
|
|
@@ -94,49 +94,18 @@ const isChrome = UA && /chrome\/\d+/.test(UA) && !isEdge;
|
|
|
94
94
|
const isPhantomJS = UA && /phantomjs/.test(UA);
|
|
95
95
|
const isFF = typeof UA == "string" && UA.match(/firefox\/(\d+)/);
|
|
96
96
|
const isMobile = isBrowser && navigator.userAgent.toLowerCase().includes("mobile");
|
|
97
|
-
|
|
98
|
-
const analyUnit = (size, unit = "px") => {
|
|
99
|
-
return lodash.isString(size) && /\D/g.test(size) ? size : size + unit;
|
|
100
|
-
};
|
|
101
|
-
const analySize = (size, unit) => {
|
|
102
|
-
if (typeof size === "string" || typeof size === "number") {
|
|
103
|
-
return { width: analyUnit(size, unit), height: analyUnit(size, unit) };
|
|
104
|
-
}
|
|
105
|
-
if (Array.isArray(size)) {
|
|
106
|
-
return { width: analyUnit(size[0], unit), height: analyUnit(size[1], unit) };
|
|
107
|
-
}
|
|
108
|
-
if (typeof size === "object") {
|
|
109
|
-
return { width: analyUnit(size.width, unit), height: analyUnit(size.height, unit) };
|
|
110
|
-
}
|
|
111
|
-
return { width: "", height: "" };
|
|
112
|
-
};
|
|
113
|
-
|
|
114
|
-
const checkedTypeof = (target) => {
|
|
115
|
-
return Object.prototype.toString.call(target).slice(8, -1);
|
|
116
|
-
};
|
|
117
|
-
const assert = (condition, ...infos) => {
|
|
118
|
-
if (!condition)
|
|
119
|
-
console.warn(...infos);
|
|
120
|
-
return condition;
|
|
121
|
-
};
|
|
122
|
-
const isClient = typeof window !== "undefined";
|
|
123
97
|
const isFormData = (value) => lodash.isObject(value) && value instanceof FormData;
|
|
124
98
|
const isWindow = (value) => typeof window !== "undefined" && toString.call(value) === "[object Window]";
|
|
125
99
|
|
|
126
|
-
const
|
|
127
|
-
|
|
128
|
-
if (queryString.length > 0)
|
|
129
|
-
url += "?" + queryString.join("&");
|
|
130
|
-
return url;
|
|
131
|
-
};
|
|
132
|
-
const awaitPromise = (code = 1e3) => {
|
|
133
|
-
return new Promise((resolve) => setTimeout(resolve, code));
|
|
100
|
+
const formDataToObject = (formData) => {
|
|
101
|
+
return Object.fromEntries(formData.entries());
|
|
134
102
|
};
|
|
135
|
-
const
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
103
|
+
const objectToFormData = (object) => {
|
|
104
|
+
const formData = new FormData();
|
|
105
|
+
for (const [key, value] of Object.entries(object)) {
|
|
106
|
+
formData.append(key, String(value));
|
|
107
|
+
}
|
|
108
|
+
return formData;
|
|
140
109
|
};
|
|
141
110
|
const pickByParams = (params, filters, deep = false) => {
|
|
142
111
|
deep && lodash.forIn(params, (value, key) => {
|
|
@@ -149,16 +118,6 @@ const pickByParams = (params, filters, deep = false) => {
|
|
|
149
118
|
}
|
|
150
119
|
return pickValue;
|
|
151
120
|
};
|
|
152
|
-
const formDataToObject = (formData) => {
|
|
153
|
-
return Object.fromEntries(formData.entries());
|
|
154
|
-
};
|
|
155
|
-
const objectToFormData = (object) => {
|
|
156
|
-
const formData = new FormData();
|
|
157
|
-
for (const [key, value] of Object.entries(object)) {
|
|
158
|
-
formData.append(key, value);
|
|
159
|
-
}
|
|
160
|
-
return formData;
|
|
161
|
-
};
|
|
162
121
|
const objectFlat = (object, deep = 1) => {
|
|
163
122
|
const flatDeep = (object2, deep2 = 1) => {
|
|
164
123
|
let _object = {};
|
|
@@ -173,17 +132,61 @@ const objectFlat = (object, deep = 1) => {
|
|
|
173
132
|
};
|
|
174
133
|
return flatDeep(object, deep);
|
|
175
134
|
};
|
|
135
|
+
|
|
136
|
+
const analyUnit = (value, unit = "px") => {
|
|
137
|
+
const empty = !(lodash.isString(value) || lodash.isNumber(value));
|
|
138
|
+
if (empty)
|
|
139
|
+
return "";
|
|
140
|
+
return lodash.isString(value) && /\D/g.test(value) ? value : value + unit;
|
|
141
|
+
};
|
|
142
|
+
const analySize = (size, unit) => {
|
|
143
|
+
if (typeof size === "string" || typeof size === "number") {
|
|
144
|
+
return { width: analyUnit(size, unit), height: analyUnit(size, unit) };
|
|
145
|
+
}
|
|
146
|
+
if (Array.isArray(size)) {
|
|
147
|
+
return { width: analyUnit(size[0], unit), height: analyUnit(size[1], unit) };
|
|
148
|
+
}
|
|
149
|
+
if (typeof size === "object") {
|
|
150
|
+
return { width: analyUnit(size.width, unit), height: analyUnit(size.height, unit) };
|
|
151
|
+
}
|
|
152
|
+
return { width: "", height: "" };
|
|
153
|
+
};
|
|
154
|
+
|
|
155
|
+
const urlParamsAnaly = (url, params) => {
|
|
156
|
+
const queryString = Object.keys(params).map((key) => `${key}=${params[key]}`);
|
|
157
|
+
if (queryString.length > 0)
|
|
158
|
+
url += "?" + queryString.join("&");
|
|
159
|
+
return url;
|
|
160
|
+
};
|
|
161
|
+
const awaitPromise = (ms = 1e3) => {
|
|
162
|
+
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
163
|
+
};
|
|
164
|
+
const generateArray = (start, end) => {
|
|
165
|
+
start = Number(start);
|
|
166
|
+
end = Number(end);
|
|
167
|
+
end = end > start ? end : start;
|
|
168
|
+
return [...new Array(end + 1).keys()].slice(start);
|
|
169
|
+
};
|
|
176
170
|
const noop = () => {
|
|
177
171
|
};
|
|
172
|
+
const checkedTypeof = (target) => {
|
|
173
|
+
const value = Object.prototype.toString.call(target).slice(8, -1).toLocaleLowerCase();
|
|
174
|
+
return value;
|
|
175
|
+
};
|
|
176
|
+
const assert = (condition, ...infos) => {
|
|
177
|
+
if (!condition)
|
|
178
|
+
console.warn(...infos);
|
|
179
|
+
return condition;
|
|
180
|
+
};
|
|
178
181
|
|
|
179
182
|
exports.UA = UA;
|
|
180
183
|
exports.analySize = analySize;
|
|
181
184
|
exports.analyUnit = analyUnit;
|
|
182
185
|
exports.assert = assert;
|
|
183
186
|
exports.awaitPromise = awaitPromise;
|
|
184
|
-
exports.blendColor = blendColor;
|
|
185
187
|
exports.capitalizeCamelCase = capitalizeCamelCase;
|
|
186
188
|
exports.checkedTypeof = checkedTypeof;
|
|
189
|
+
exports.colourBlend = colourBlend;
|
|
187
190
|
exports.formDataToObject = formDataToObject;
|
|
188
191
|
exports.formatClearHtml = formatClearHtml;
|
|
189
192
|
exports.formatCoverPhone = formatCoverPhone;
|
|
@@ -197,7 +200,6 @@ exports.hexToRgba = hexToRgba;
|
|
|
197
200
|
exports.isAndroid = isAndroid;
|
|
198
201
|
exports.isBrowser = isBrowser;
|
|
199
202
|
exports.isChrome = isChrome;
|
|
200
|
-
exports.isClient = isClient;
|
|
201
203
|
exports.isEdge = isEdge;
|
|
202
204
|
exports.isFF = isFF;
|
|
203
205
|
exports.isFormData = isFormData;
|
package/index.d.ts
CHANGED
|
@@ -1,13 +1,11 @@
|
|
|
1
|
-
import { LooseNumber as LooseNumber$1 } from '@hairy/utils';
|
|
2
|
-
|
|
3
1
|
/**
|
|
4
|
-
* 颜色混合器
|
|
2
|
+
* 颜色混合器 - 仅支持 hex 颜色完整值
|
|
5
3
|
* @param colorOne 颜色值
|
|
6
4
|
* @param colorTwo 颜色值
|
|
7
5
|
* @param ratio 根据 colorTwo 混合比例, 0~1 区间, 1 则是完全的 colorTwo
|
|
8
6
|
* @returns 混合颜色
|
|
9
7
|
*/
|
|
10
|
-
declare const
|
|
8
|
+
declare const colourBlend: (colorOne: string, colorTwo: string, ratio: number) => string;
|
|
11
9
|
/**
|
|
12
10
|
* 将 hex 颜色转成 rgb
|
|
13
11
|
* @param hex
|
|
@@ -25,18 +23,18 @@ declare const hexToRgba: (hex: string, opacity: number) => {
|
|
|
25
23
|
* @param color
|
|
26
24
|
*/
|
|
27
25
|
declare const fuseThemeColor: (color: string) => {
|
|
28
|
-
'
|
|
29
|
-
'
|
|
30
|
-
'
|
|
31
|
-
'
|
|
32
|
-
'
|
|
33
|
-
'
|
|
34
|
-
'
|
|
35
|
-
'
|
|
36
|
-
'
|
|
37
|
-
'
|
|
38
|
-
'
|
|
39
|
-
'
|
|
26
|
+
'light-2': string;
|
|
27
|
+
'light-4': string;
|
|
28
|
+
'light-6': string;
|
|
29
|
+
'light-8': string;
|
|
30
|
+
'dark-2': string;
|
|
31
|
+
'dark-4': string;
|
|
32
|
+
'dark-6': string;
|
|
33
|
+
'dark-8': string;
|
|
34
|
+
'opacity-2': string;
|
|
35
|
+
'opacity-4': string;
|
|
36
|
+
'opacity-6': string;
|
|
37
|
+
'opacity-8': string;
|
|
40
38
|
};
|
|
41
39
|
|
|
42
40
|
/**
|
|
@@ -70,10 +68,11 @@ declare const formatThousandBitSeparator: (target: number | string, unit?: strin
|
|
|
70
68
|
declare const formatUnix: (timestamp: number, format?: string) => string;
|
|
71
69
|
/**
|
|
72
70
|
* 隐藏手机号中间四位
|
|
71
|
+
* @param phone 手机号
|
|
73
72
|
*/
|
|
74
73
|
declare const formatCoverPhone: (phone: string) => string;
|
|
75
74
|
/**
|
|
76
|
-
*
|
|
75
|
+
* 数字位数不够时,进行前补零
|
|
77
76
|
* @param num 数值
|
|
78
77
|
* @param lh 长度
|
|
79
78
|
*/
|
|
@@ -97,29 +96,32 @@ declare const isIOS: boolean;
|
|
|
97
96
|
declare const isChrome: boolean | "";
|
|
98
97
|
declare const isPhantomJS: boolean | "";
|
|
99
98
|
declare const isFF: false | RegExpMatchArray | null;
|
|
100
|
-
declare const isMobile: boolean;
|
|
99
|
+
declare const isMobile: boolean;
|
|
100
|
+
declare const isFormData: (value: any) => value is FormData;
|
|
101
|
+
declare const isWindow: (value: any) => value is Window;
|
|
101
102
|
|
|
102
103
|
/**
|
|
103
|
-
*
|
|
104
|
-
* @param
|
|
105
|
-
* @param unit 单元
|
|
106
|
-
* @returns string
|
|
104
|
+
* 将 formData 转换为 object
|
|
105
|
+
* @param formData
|
|
107
106
|
*/
|
|
108
|
-
declare const
|
|
109
|
-
/** size 转换配置 */
|
|
110
|
-
declare type AnalySizeOption = LooseNumber$1 | [LooseNumber$1, LooseNumber$1] | {
|
|
111
|
-
width: LooseNumber$1;
|
|
112
|
-
height: LooseNumber$1;
|
|
113
|
-
};
|
|
107
|
+
declare const formDataToObject: (formData: FormData) => Record<string, string>;
|
|
114
108
|
/**
|
|
115
|
-
* 将
|
|
116
|
-
* @param
|
|
117
|
-
* @returns
|
|
109
|
+
* 将 object 转换为 formData
|
|
110
|
+
* @param object
|
|
118
111
|
*/
|
|
119
|
-
declare const
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
112
|
+
declare const objectToFormData: (object: Record<string, string | number>) => FormData;
|
|
113
|
+
/**
|
|
114
|
+
* 过滤对象|数组中 filters 中的值
|
|
115
|
+
* @param params
|
|
116
|
+
* @param filters
|
|
117
|
+
*/
|
|
118
|
+
declare const pickByParams: <T extends object>(params: T, filters: any[], deep?: boolean) => Partial<T>;
|
|
119
|
+
/**
|
|
120
|
+
* 对象扁平化处理
|
|
121
|
+
* @param object 对象
|
|
122
|
+
* @param deep 深度
|
|
123
|
+
*/
|
|
124
|
+
declare const objectFlat: (object: Record<string, any>, deep?: number) => Record<string, any>;
|
|
123
125
|
|
|
124
126
|
declare type PlainObject = {
|
|
125
127
|
[key: string]: any;
|
|
@@ -148,20 +150,26 @@ declare type Option<L extends Key = 'label', V extends Key = 'value', C extends
|
|
|
148
150
|
};
|
|
149
151
|
|
|
150
152
|
/**
|
|
151
|
-
*
|
|
152
|
-
* @param
|
|
153
|
-
* @
|
|
153
|
+
* 如果有单位,如百分比,px单位等,直接返回,如果是纯粹的数值,则加上px单位
|
|
154
|
+
* @param size 尺寸
|
|
155
|
+
* @param unit 单元
|
|
156
|
+
* @returns string
|
|
154
157
|
*/
|
|
155
|
-
declare const
|
|
158
|
+
declare const analyUnit: (value: LooseNumber, unit?: string) => string;
|
|
159
|
+
/** size 转换配置 */
|
|
160
|
+
declare type AnalySizeOption = LooseNumber | [LooseNumber, LooseNumber] | {
|
|
161
|
+
width: LooseNumber;
|
|
162
|
+
height: LooseNumber;
|
|
163
|
+
};
|
|
156
164
|
/**
|
|
157
|
-
*
|
|
158
|
-
* @param
|
|
159
|
-
* @
|
|
165
|
+
* 将 size 转换为宽高
|
|
166
|
+
* @param size { AnalySizeOption }
|
|
167
|
+
* @returns
|
|
160
168
|
*/
|
|
161
|
-
declare const
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
169
|
+
declare const analySize: (size: AnalySizeOption, unit?: string | undefined) => {
|
|
170
|
+
width: string;
|
|
171
|
+
height: string;
|
|
172
|
+
};
|
|
165
173
|
|
|
166
174
|
/**
|
|
167
175
|
* 地址参数计算
|
|
@@ -174,7 +182,7 @@ declare const urlParamsAnaly: (url: string, params: Record<string, any>) => stri
|
|
|
174
182
|
* 自定义 Promise 等待
|
|
175
183
|
* @param code 等待时间
|
|
176
184
|
*/
|
|
177
|
-
declare const awaitPromise: (
|
|
185
|
+
declare const awaitPromise: (ms?: number) => Promise<unknown>;
|
|
178
186
|
/**
|
|
179
187
|
* 生成递进的数组
|
|
180
188
|
* @param start 开始数值
|
|
@@ -182,29 +190,19 @@ declare const awaitPromise: (code?: number) => Promise<unknown>;
|
|
|
182
190
|
* @returns 递进的数组
|
|
183
191
|
*/
|
|
184
192
|
declare const generateArray: (start: number, end: number) => number[];
|
|
193
|
+
/** 空的方法 */
|
|
194
|
+
declare const noop: () => void;
|
|
185
195
|
/**
|
|
186
|
-
*
|
|
187
|
-
* @param
|
|
188
|
-
* @
|
|
189
|
-
*/
|
|
190
|
-
declare const pickByParams: <T extends object>(params: T, filters: any[], deep?: boolean) => Partial<T>;
|
|
191
|
-
/**
|
|
192
|
-
* 将 formData 转换为 ojbect
|
|
193
|
-
* @param formData
|
|
194
|
-
*/
|
|
195
|
-
declare const formDataToObject: (formData: FormData) => Record<string, string>;
|
|
196
|
-
/**
|
|
197
|
-
* 将 object 转换为 formData
|
|
198
|
-
* @param object
|
|
196
|
+
* 获取数据类型
|
|
197
|
+
* @param target 检测对象
|
|
198
|
+
* @returns 返回字符串
|
|
199
199
|
*/
|
|
200
|
-
declare const
|
|
200
|
+
declare const checkedTypeof: (target: any) => "string" | "number" | "bigint" | "boolean" | "symbol" | "undefined" | "object" | "function" | "null" | "regexp";
|
|
201
201
|
/**
|
|
202
|
-
*
|
|
203
|
-
* @param
|
|
204
|
-
* @param
|
|
202
|
+
* 不符合预期则弹出警告
|
|
203
|
+
* @param condition
|
|
204
|
+
* @param infos
|
|
205
205
|
*/
|
|
206
|
-
declare const
|
|
207
|
-
/** 空的方法 */
|
|
208
|
-
declare const noop: () => void;
|
|
206
|
+
declare const assert: (condition: boolean, ...infos: any[]) => boolean;
|
|
209
207
|
|
|
210
|
-
export { AnalySizeOption, DeepKeyof, DeepPartial, DeepReadonly, DeepReplace, DeepRequired, Key, LooseNumber, Option, PlainObject, UA, analySize, analyUnit, assert, awaitPromise,
|
|
208
|
+
export { AnalySizeOption, DeepKeyof, DeepPartial, DeepReadonly, DeepReplace, DeepRequired, Key, LooseNumber, Option, PlainObject, UA, analySize, analyUnit, assert, awaitPromise, capitalizeCamelCase, checkedTypeof, colourBlend, formDataToObject, formatClearHtml, formatCoverPhone, formatInteger, formatPrice, formatThousandBitSeparator, formatUnix, fuseThemeColor, generateArray, hexToRgba, isAndroid, isBrowser, isChrome, isEdge, isFF, isFormData, isIE, isIE11, isIE9, isIOS, isMobile, isPhantomJS, isWeex, isWindow, noop, objectFlat, objectToFormData, pickByParams, prefixZero, urlParamsAnaly, weexPlatform };
|
package/index.esm.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import dayjs from 'dayjs';
|
|
2
|
-
import { camelCase,
|
|
2
|
+
import { camelCase, isObject, forIn, pickBy, isPlainObject, isString, isNumber } from 'lodash';
|
|
3
3
|
|
|
4
|
-
const
|
|
4
|
+
const colourBlend = (colorOne, colorTwo, ratio) => {
|
|
5
5
|
ratio = Math.max(Math.min(Number(ratio), 1), 0);
|
|
6
6
|
const r1 = parseInt(colorOne.slice(1, 3), 16);
|
|
7
7
|
const g1 = parseInt(colorOne.slice(3, 5), 16);
|
|
@@ -27,18 +27,18 @@ const hexToRgba = (hex, opacity) => {
|
|
|
27
27
|
};
|
|
28
28
|
};
|
|
29
29
|
const fuseThemeColor = (color) => ({
|
|
30
|
-
"
|
|
31
|
-
"
|
|
32
|
-
"
|
|
33
|
-
"
|
|
34
|
-
"
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"
|
|
30
|
+
"light-2": colourBlend("#ffffff", color, 0.8),
|
|
31
|
+
"light-4": colourBlend("#ffffff", color, 0.6),
|
|
32
|
+
"light-6": colourBlend("#ffffff", color, 0.4),
|
|
33
|
+
"light-8": colourBlend("#ffffff", color, 0.2),
|
|
34
|
+
"dark-2": colourBlend("#000000", color, 0.8),
|
|
35
|
+
"dark-4": colourBlend("#000000", color, 0.6),
|
|
36
|
+
"dark-6": colourBlend("#000000", color, 0.4),
|
|
37
|
+
"dark-8": colourBlend("#000000", color, 0.2),
|
|
38
|
+
"opacity-2": hexToRgba(color, 0.8).rgba,
|
|
39
|
+
"opacity-4": hexToRgba(color, 0.6).rgba,
|
|
40
|
+
"opacity-6": hexToRgba(color, 0.4).rgba,
|
|
41
|
+
"opacity-8": hexToRgba(color, 0.2).rgba
|
|
42
42
|
});
|
|
43
43
|
|
|
44
44
|
const formatClearHtml = (string_) => string_.replace(/<[!/]*[^<>]*>/gi, "");
|
|
@@ -86,49 +86,18 @@ const isChrome = UA && /chrome\/\d+/.test(UA) && !isEdge;
|
|
|
86
86
|
const isPhantomJS = UA && /phantomjs/.test(UA);
|
|
87
87
|
const isFF = typeof UA == "string" && UA.match(/firefox\/(\d+)/);
|
|
88
88
|
const isMobile = isBrowser && navigator.userAgent.toLowerCase().includes("mobile");
|
|
89
|
-
|
|
90
|
-
const analyUnit = (size, unit = "px") => {
|
|
91
|
-
return isString(size) && /\D/g.test(size) ? size : size + unit;
|
|
92
|
-
};
|
|
93
|
-
const analySize = (size, unit) => {
|
|
94
|
-
if (typeof size === "string" || typeof size === "number") {
|
|
95
|
-
return { width: analyUnit(size, unit), height: analyUnit(size, unit) };
|
|
96
|
-
}
|
|
97
|
-
if (Array.isArray(size)) {
|
|
98
|
-
return { width: analyUnit(size[0], unit), height: analyUnit(size[1], unit) };
|
|
99
|
-
}
|
|
100
|
-
if (typeof size === "object") {
|
|
101
|
-
return { width: analyUnit(size.width, unit), height: analyUnit(size.height, unit) };
|
|
102
|
-
}
|
|
103
|
-
return { width: "", height: "" };
|
|
104
|
-
};
|
|
105
|
-
|
|
106
|
-
const checkedTypeof = (target) => {
|
|
107
|
-
return Object.prototype.toString.call(target).slice(8, -1);
|
|
108
|
-
};
|
|
109
|
-
const assert = (condition, ...infos) => {
|
|
110
|
-
if (!condition)
|
|
111
|
-
console.warn(...infos);
|
|
112
|
-
return condition;
|
|
113
|
-
};
|
|
114
|
-
const isClient = typeof window !== "undefined";
|
|
115
89
|
const isFormData = (value) => isObject(value) && value instanceof FormData;
|
|
116
90
|
const isWindow = (value) => typeof window !== "undefined" && toString.call(value) === "[object Window]";
|
|
117
91
|
|
|
118
|
-
const
|
|
119
|
-
|
|
120
|
-
if (queryString.length > 0)
|
|
121
|
-
url += "?" + queryString.join("&");
|
|
122
|
-
return url;
|
|
123
|
-
};
|
|
124
|
-
const awaitPromise = (code = 1e3) => {
|
|
125
|
-
return new Promise((resolve) => setTimeout(resolve, code));
|
|
92
|
+
const formDataToObject = (formData) => {
|
|
93
|
+
return Object.fromEntries(formData.entries());
|
|
126
94
|
};
|
|
127
|
-
const
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
95
|
+
const objectToFormData = (object) => {
|
|
96
|
+
const formData = new FormData();
|
|
97
|
+
for (const [key, value] of Object.entries(object)) {
|
|
98
|
+
formData.append(key, String(value));
|
|
99
|
+
}
|
|
100
|
+
return formData;
|
|
132
101
|
};
|
|
133
102
|
const pickByParams = (params, filters, deep = false) => {
|
|
134
103
|
deep && forIn(params, (value, key) => {
|
|
@@ -141,16 +110,6 @@ const pickByParams = (params, filters, deep = false) => {
|
|
|
141
110
|
}
|
|
142
111
|
return pickValue;
|
|
143
112
|
};
|
|
144
|
-
const formDataToObject = (formData) => {
|
|
145
|
-
return Object.fromEntries(formData.entries());
|
|
146
|
-
};
|
|
147
|
-
const objectToFormData = (object) => {
|
|
148
|
-
const formData = new FormData();
|
|
149
|
-
for (const [key, value] of Object.entries(object)) {
|
|
150
|
-
formData.append(key, value);
|
|
151
|
-
}
|
|
152
|
-
return formData;
|
|
153
|
-
};
|
|
154
113
|
const objectFlat = (object, deep = 1) => {
|
|
155
114
|
const flatDeep = (object2, deep2 = 1) => {
|
|
156
115
|
let _object = {};
|
|
@@ -165,7 +124,51 @@ const objectFlat = (object, deep = 1) => {
|
|
|
165
124
|
};
|
|
166
125
|
return flatDeep(object, deep);
|
|
167
126
|
};
|
|
127
|
+
|
|
128
|
+
const analyUnit = (value, unit = "px") => {
|
|
129
|
+
const empty = !(isString(value) || isNumber(value));
|
|
130
|
+
if (empty)
|
|
131
|
+
return "";
|
|
132
|
+
return isString(value) && /\D/g.test(value) ? value : value + unit;
|
|
133
|
+
};
|
|
134
|
+
const analySize = (size, unit) => {
|
|
135
|
+
if (typeof size === "string" || typeof size === "number") {
|
|
136
|
+
return { width: analyUnit(size, unit), height: analyUnit(size, unit) };
|
|
137
|
+
}
|
|
138
|
+
if (Array.isArray(size)) {
|
|
139
|
+
return { width: analyUnit(size[0], unit), height: analyUnit(size[1], unit) };
|
|
140
|
+
}
|
|
141
|
+
if (typeof size === "object") {
|
|
142
|
+
return { width: analyUnit(size.width, unit), height: analyUnit(size.height, unit) };
|
|
143
|
+
}
|
|
144
|
+
return { width: "", height: "" };
|
|
145
|
+
};
|
|
146
|
+
|
|
147
|
+
const urlParamsAnaly = (url, params) => {
|
|
148
|
+
const queryString = Object.keys(params).map((key) => `${key}=${params[key]}`);
|
|
149
|
+
if (queryString.length > 0)
|
|
150
|
+
url += "?" + queryString.join("&");
|
|
151
|
+
return url;
|
|
152
|
+
};
|
|
153
|
+
const awaitPromise = (ms = 1e3) => {
|
|
154
|
+
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
155
|
+
};
|
|
156
|
+
const generateArray = (start, end) => {
|
|
157
|
+
start = Number(start);
|
|
158
|
+
end = Number(end);
|
|
159
|
+
end = end > start ? end : start;
|
|
160
|
+
return [...new Array(end + 1).keys()].slice(start);
|
|
161
|
+
};
|
|
168
162
|
const noop = () => {
|
|
169
163
|
};
|
|
164
|
+
const checkedTypeof = (target) => {
|
|
165
|
+
const value = Object.prototype.toString.call(target).slice(8, -1).toLocaleLowerCase();
|
|
166
|
+
return value;
|
|
167
|
+
};
|
|
168
|
+
const assert = (condition, ...infos) => {
|
|
169
|
+
if (!condition)
|
|
170
|
+
console.warn(...infos);
|
|
171
|
+
return condition;
|
|
172
|
+
};
|
|
170
173
|
|
|
171
|
-
export { UA, analySize, analyUnit, assert, awaitPromise,
|
|
174
|
+
export { UA, analySize, analyUnit, assert, awaitPromise, capitalizeCamelCase, checkedTypeof, colourBlend, formDataToObject, formatClearHtml, formatCoverPhone, formatInteger, formatPrice, formatThousandBitSeparator, formatUnix, fuseThemeColor, generateArray, hexToRgba, isAndroid, isBrowser, isChrome, isEdge, isFF, isFormData, isIE, isIE11, isIE9, isIOS, isMobile, isPhantomJS, isWeex, isWindow, noop, objectFlat, objectToFormData, pickByParams, prefixZero, urlParamsAnaly, weexPlatform };
|
package/index.iife.js
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
var dayjs__default = /*#__PURE__*/_interopDefaultLegacy(dayjs);
|
|
7
7
|
|
|
8
|
-
const
|
|
8
|
+
const colourBlend = (colorOne, colorTwo, ratio) => {
|
|
9
9
|
ratio = Math.max(Math.min(Number(ratio), 1), 0);
|
|
10
10
|
const r1 = parseInt(colorOne.slice(1, 3), 16);
|
|
11
11
|
const g1 = parseInt(colorOne.slice(3, 5), 16);
|
|
@@ -31,18 +31,18 @@
|
|
|
31
31
|
};
|
|
32
32
|
};
|
|
33
33
|
const fuseThemeColor = (color) => ({
|
|
34
|
-
"
|
|
35
|
-
"
|
|
36
|
-
"
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
41
|
-
"
|
|
42
|
-
"
|
|
43
|
-
"
|
|
44
|
-
"
|
|
45
|
-
"
|
|
34
|
+
"light-2": colourBlend("#ffffff", color, 0.8),
|
|
35
|
+
"light-4": colourBlend("#ffffff", color, 0.6),
|
|
36
|
+
"light-6": colourBlend("#ffffff", color, 0.4),
|
|
37
|
+
"light-8": colourBlend("#ffffff", color, 0.2),
|
|
38
|
+
"dark-2": colourBlend("#000000", color, 0.8),
|
|
39
|
+
"dark-4": colourBlend("#000000", color, 0.6),
|
|
40
|
+
"dark-6": colourBlend("#000000", color, 0.4),
|
|
41
|
+
"dark-8": colourBlend("#000000", color, 0.2),
|
|
42
|
+
"opacity-2": hexToRgba(color, 0.8).rgba,
|
|
43
|
+
"opacity-4": hexToRgba(color, 0.6).rgba,
|
|
44
|
+
"opacity-6": hexToRgba(color, 0.4).rgba,
|
|
45
|
+
"opacity-8": hexToRgba(color, 0.2).rgba
|
|
46
46
|
});
|
|
47
47
|
|
|
48
48
|
const formatClearHtml = (string_) => string_.replace(/<[!/]*[^<>]*>/gi, "");
|
|
@@ -90,49 +90,18 @@
|
|
|
90
90
|
const isPhantomJS = UA && /phantomjs/.test(UA);
|
|
91
91
|
const isFF = typeof UA == "string" && UA.match(/firefox\/(\d+)/);
|
|
92
92
|
const isMobile = isBrowser && navigator.userAgent.toLowerCase().includes("mobile");
|
|
93
|
-
|
|
94
|
-
const analyUnit = (size, unit = "px") => {
|
|
95
|
-
return lodash.isString(size) && /\D/g.test(size) ? size : size + unit;
|
|
96
|
-
};
|
|
97
|
-
const analySize = (size, unit) => {
|
|
98
|
-
if (typeof size === "string" || typeof size === "number") {
|
|
99
|
-
return { width: analyUnit(size, unit), height: analyUnit(size, unit) };
|
|
100
|
-
}
|
|
101
|
-
if (Array.isArray(size)) {
|
|
102
|
-
return { width: analyUnit(size[0], unit), height: analyUnit(size[1], unit) };
|
|
103
|
-
}
|
|
104
|
-
if (typeof size === "object") {
|
|
105
|
-
return { width: analyUnit(size.width, unit), height: analyUnit(size.height, unit) };
|
|
106
|
-
}
|
|
107
|
-
return { width: "", height: "" };
|
|
108
|
-
};
|
|
109
|
-
|
|
110
|
-
const checkedTypeof = (target) => {
|
|
111
|
-
return Object.prototype.toString.call(target).slice(8, -1);
|
|
112
|
-
};
|
|
113
|
-
const assert = (condition, ...infos) => {
|
|
114
|
-
if (!condition)
|
|
115
|
-
console.warn(...infos);
|
|
116
|
-
return condition;
|
|
117
|
-
};
|
|
118
|
-
const isClient = typeof window !== "undefined";
|
|
119
93
|
const isFormData = (value) => lodash.isObject(value) && value instanceof FormData;
|
|
120
94
|
const isWindow = (value) => typeof window !== "undefined" && toString.call(value) === "[object Window]";
|
|
121
95
|
|
|
122
|
-
const
|
|
123
|
-
|
|
124
|
-
if (queryString.length > 0)
|
|
125
|
-
url += "?" + queryString.join("&");
|
|
126
|
-
return url;
|
|
127
|
-
};
|
|
128
|
-
const awaitPromise = (code = 1e3) => {
|
|
129
|
-
return new Promise((resolve) => setTimeout(resolve, code));
|
|
96
|
+
const formDataToObject = (formData) => {
|
|
97
|
+
return Object.fromEntries(formData.entries());
|
|
130
98
|
};
|
|
131
|
-
const
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
99
|
+
const objectToFormData = (object) => {
|
|
100
|
+
const formData = new FormData();
|
|
101
|
+
for (const [key, value] of Object.entries(object)) {
|
|
102
|
+
formData.append(key, String(value));
|
|
103
|
+
}
|
|
104
|
+
return formData;
|
|
136
105
|
};
|
|
137
106
|
const pickByParams = (params, filters, deep = false) => {
|
|
138
107
|
deep && lodash.forIn(params, (value, key) => {
|
|
@@ -145,16 +114,6 @@
|
|
|
145
114
|
}
|
|
146
115
|
return pickValue;
|
|
147
116
|
};
|
|
148
|
-
const formDataToObject = (formData) => {
|
|
149
|
-
return Object.fromEntries(formData.entries());
|
|
150
|
-
};
|
|
151
|
-
const objectToFormData = (object) => {
|
|
152
|
-
const formData = new FormData();
|
|
153
|
-
for (const [key, value] of Object.entries(object)) {
|
|
154
|
-
formData.append(key, value);
|
|
155
|
-
}
|
|
156
|
-
return formData;
|
|
157
|
-
};
|
|
158
117
|
const objectFlat = (object, deep = 1) => {
|
|
159
118
|
const flatDeep = (object2, deep2 = 1) => {
|
|
160
119
|
let _object = {};
|
|
@@ -169,17 +128,61 @@
|
|
|
169
128
|
};
|
|
170
129
|
return flatDeep(object, deep);
|
|
171
130
|
};
|
|
131
|
+
|
|
132
|
+
const analyUnit = (value, unit = "px") => {
|
|
133
|
+
const empty = !(lodash.isString(value) || lodash.isNumber(value));
|
|
134
|
+
if (empty)
|
|
135
|
+
return "";
|
|
136
|
+
return lodash.isString(value) && /\D/g.test(value) ? value : value + unit;
|
|
137
|
+
};
|
|
138
|
+
const analySize = (size, unit) => {
|
|
139
|
+
if (typeof size === "string" || typeof size === "number") {
|
|
140
|
+
return { width: analyUnit(size, unit), height: analyUnit(size, unit) };
|
|
141
|
+
}
|
|
142
|
+
if (Array.isArray(size)) {
|
|
143
|
+
return { width: analyUnit(size[0], unit), height: analyUnit(size[1], unit) };
|
|
144
|
+
}
|
|
145
|
+
if (typeof size === "object") {
|
|
146
|
+
return { width: analyUnit(size.width, unit), height: analyUnit(size.height, unit) };
|
|
147
|
+
}
|
|
148
|
+
return { width: "", height: "" };
|
|
149
|
+
};
|
|
150
|
+
|
|
151
|
+
const urlParamsAnaly = (url, params) => {
|
|
152
|
+
const queryString = Object.keys(params).map((key) => `${key}=${params[key]}`);
|
|
153
|
+
if (queryString.length > 0)
|
|
154
|
+
url += "?" + queryString.join("&");
|
|
155
|
+
return url;
|
|
156
|
+
};
|
|
157
|
+
const awaitPromise = (ms = 1e3) => {
|
|
158
|
+
return new Promise((resolve) => setTimeout(resolve, ms));
|
|
159
|
+
};
|
|
160
|
+
const generateArray = (start, end) => {
|
|
161
|
+
start = Number(start);
|
|
162
|
+
end = Number(end);
|
|
163
|
+
end = end > start ? end : start;
|
|
164
|
+
return [...new Array(end + 1).keys()].slice(start);
|
|
165
|
+
};
|
|
172
166
|
const noop = () => {
|
|
173
167
|
};
|
|
168
|
+
const checkedTypeof = (target) => {
|
|
169
|
+
const value = Object.prototype.toString.call(target).slice(8, -1).toLocaleLowerCase();
|
|
170
|
+
return value;
|
|
171
|
+
};
|
|
172
|
+
const assert = (condition, ...infos) => {
|
|
173
|
+
if (!condition)
|
|
174
|
+
console.warn(...infos);
|
|
175
|
+
return condition;
|
|
176
|
+
};
|
|
174
177
|
|
|
175
178
|
exports.UA = UA;
|
|
176
179
|
exports.analySize = analySize;
|
|
177
180
|
exports.analyUnit = analyUnit;
|
|
178
181
|
exports.assert = assert;
|
|
179
182
|
exports.awaitPromise = awaitPromise;
|
|
180
|
-
exports.blendColor = blendColor;
|
|
181
183
|
exports.capitalizeCamelCase = capitalizeCamelCase;
|
|
182
184
|
exports.checkedTypeof = checkedTypeof;
|
|
185
|
+
exports.colourBlend = colourBlend;
|
|
183
186
|
exports.formDataToObject = formDataToObject;
|
|
184
187
|
exports.formatClearHtml = formatClearHtml;
|
|
185
188
|
exports.formatCoverPhone = formatCoverPhone;
|
|
@@ -193,7 +196,6 @@
|
|
|
193
196
|
exports.isAndroid = isAndroid;
|
|
194
197
|
exports.isBrowser = isBrowser;
|
|
195
198
|
exports.isChrome = isChrome;
|
|
196
|
-
exports.isClient = isClient;
|
|
197
199
|
exports.isEdge = isEdge;
|
|
198
200
|
exports.isFF = isFF;
|
|
199
201
|
exports.isFormData = isFormData;
|
package/index.iife.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(e,r
|
|
1
|
+
!function(e,t,r){"use strict";function i(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var a=i(t);const n=(e,t,r)=>{r=Math.max(Math.min(Number(r),1),0);const i=parseInt(e.slice(1,3),16),a=parseInt(e.slice(3,5),16),n=parseInt(e.slice(5,7),16),o=parseInt(t.slice(1,3),16),s=parseInt(t.slice(3,5),16),c=parseInt(t.slice(5,7),16);let l=Math.round(i*(1-r)+o*r),f=Math.round(a*(1-r)+s*r),d=Math.round(n*(1-r)+c*r);return l=("0"+(l||0).toString(16)).slice(-2),f=("0"+(f||0).toString(16)).slice(-2),d=("0"+(d||0).toString(16)).slice(-2),"#"+l+f+d},o=(e,t)=>{const r="rgba("+parseInt("0x"+e.slice(1,3))+","+parseInt("0x"+e.slice(3,5))+","+parseInt("0x"+e.slice(5,7))+","+t+")";return{red:parseInt("0x"+e.slice(1,3)),green:parseInt("0x"+e.slice(3,5)),blue:parseInt("0x"+e.slice(5,7)),rgba:r}},s="undefined"!=typeof window,c="undefined"!=typeof WXEnvironment&&!!WXEnvironment.platform,l=c&&WXEnvironment.platform.toLowerCase(),f=s&&window.navigator.userAgent.toLowerCase(),d=f&&/msie|trident/.test(f),p=f&&f.indexOf("msie 9.0")>0,g=s&&navigator.userAgent.includes("Trident")&&navigator.userAgent.includes("rv:11.0"),m=f&&f.indexOf("edge/")>0,u=f&&f.indexOf("android")>0||"android"===l,h=f&&/iphone|ipad|ipod|ios/.test(f)||"ios"===l,y=f&&/chrome\/\d+/.test(f)&&!m,b=f&&/phantomjs/.test(f),w="string"==typeof f&&f.match(/firefox\/(\d+)/),j=s&&navigator.userAgent.toLowerCase().includes("mobile"),x=(e,t,i=!1)=>{i&&r.forIn(e,((a,n)=>{r.isObject(a)&&(e[n]=x(e[n],t,i))}));const a=r.pickBy(e,(e=>!t.includes(e)));return Array.isArray(e)?Object.values(a):a},I=(e,t="px")=>!(r.isString(e)||r.isNumber(e))?"":r.isString(e)&&/\D/g.test(e)?e:e+t;e.UA=f,e.analySize=(e,t)=>"string"==typeof e||"number"==typeof e?{width:I(e,t),height:I(e,t)}:Array.isArray(e)?{width:I(e[0],t),height:I(e[1],t)}:"object"==typeof e?{width:I(e.width,t),height:I(e.height,t)}:{width:"",height:""},e.analyUnit=I,e.assert=(e,...t)=>(e||console.warn(...t),e),e.awaitPromise=(e=1e3)=>new Promise((t=>setTimeout(t,e))),e.capitalizeCamelCase=e=>{let t=r.camelCase(e);return t=t.slice(0,1).toLocaleUpperCase()+t.slice(1),t},e.checkedTypeof=e=>Object.prototype.toString.call(e).slice(8,-1).toLocaleLowerCase(),e.colourBlend=n,e.formDataToObject=e=>Object.fromEntries(e.entries()),e.formatClearHtml=e=>e.replace(/<[!/]*[^<>]*>/gi,""),e.formatCoverPhone=e=>e.replace(/^(\d{3})\d{4}(\d{4})$/,"$1****$2"),e.formatInteger=e=>e.replace(/^(0+)|\D+/g,""),e.formatPrice=e=>e.replace(/^[^\d+]/,"").replace(/[^\d,.{|}]/g,"").replace(".","$#$").replace(/\./g,"").replace("$#$",".").replace(/\.{2,}/g,".").replace(/^(-)*(\d+)\.(\d\d).*$/,"$1$2.$3"),e.formatThousandBitSeparator=(e,t=",")=>{if(""===e)return"";const r=String(e).split(".");for(let e=0;e<r.length;e++)r[e]=r[e].replace(new RegExp("(\\d)(?=(\\d{3})+$)","ig"),`$1${t||""}`);return r.join(".")},e.formatUnix=(e,t="YYYY-MM-DD HH:mm:ss")=>a.default.unix(e).format(t),e.fuseThemeColor=e=>({"light-2":n("#ffffff",e,.8),"light-4":n("#ffffff",e,.6),"light-6":n("#ffffff",e,.4),"light-8":n("#ffffff",e,.2),"dark-2":n("#000000",e,.8),"dark-4":n("#000000",e,.6),"dark-6":n("#000000",e,.4),"dark-8":n("#000000",e,.2),"opacity-2":o(e,.8).rgba,"opacity-4":o(e,.6).rgba,"opacity-6":o(e,.4).rgba,"opacity-8":o(e,.2).rgba}),e.generateArray=(e,t)=>(e=Number(e),t=(t=Number(t))>e?t:e,[...new Array(t+1).keys()].slice(e)),e.hexToRgba=o,e.isAndroid=u,e.isBrowser=s,e.isChrome=y,e.isEdge=m,e.isFF=w,e.isFormData=e=>r.isObject(e)&&e instanceof FormData,e.isIE=d,e.isIE11=g,e.isIE9=p,e.isIOS=h,e.isMobile=j,e.isPhantomJS=b,e.isWeex=c,e.isWindow=e=>"undefined"!=typeof window&&"[object Window]"===toString.call(e),e.noop=()=>{},e.objectFlat=(e,t=1)=>{const i=(e,t=1)=>{let a={};for(const[n,o]of Object.entries(e))r.isPlainObject(o)?a={...a,...t>0?i(o,t-1):o}:a[n]=o;return a};return i(e,t)},e.objectToFormData=e=>{const t=new FormData;for(const[r,i]of Object.entries(e))t.append(r,String(i));return t},e.pickByParams=x,e.prefixZero=(e,t=2)=>(new Array(t).join("0")+e).slice(-t),e.urlParamsAnaly=(e,t)=>{const r=Object.keys(t).map((e=>`${e}=${t[e]}`));return r.length>0&&(e+="?"+r.join("&")),e},e.weexPlatform=l,Object.defineProperty(e,"__esModule",{value:!0})}(this.hairyUtils=this.hairyUtils||{},dayjs,_);
|
package/package.json
CHANGED
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hairy/utils",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.17",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"dayjs": "^1.10.6"
|
|
7
|
-
"lodash": "^4.17.21"
|
|
6
|
+
"dayjs": "^1.10.6"
|
|
8
7
|
},
|
|
9
8
|
"devDependencies": {
|
|
10
9
|
"@types/lodash": "^4.14.171"
|
|
11
10
|
},
|
|
11
|
+
"peerDependencies": {
|
|
12
|
+
"lodash": "^4.17.21"
|
|
13
|
+
},
|
|
12
14
|
"main": "./index.cjs.js",
|
|
13
15
|
"types": "./index.d.ts",
|
|
14
16
|
"module": "./index.esm.js",
|
|
@@ -31,7 +33,7 @@
|
|
|
31
33
|
},
|
|
32
34
|
"./*": "./*"
|
|
33
35
|
},
|
|
34
|
-
"gitHead": "
|
|
36
|
+
"gitHead": "bca71be627bca344863814aa00ac4593a2e3f195",
|
|
35
37
|
"publishConfig": {
|
|
36
38
|
"access": "public"
|
|
37
39
|
}
|