ng-cw-v12
Version:
Angular UI component library
1,306 lines • 60.7 kB
JavaScript
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common'), require('rxjs'), require('rxjs/operators')) :
typeof define === 'function' && define.amd ? define('ng-cw-v12/common-service', ['exports', '@angular/core', '@angular/common', 'rxjs', 'rxjs/operators'], factory) :
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global["ng-cw-v12"] = global["ng-cw-v12"] || {}, global["ng-cw-v12"]["common-service"] = {}), global.ng.core, global.ng.common, global.rxjs, global.rxjs.operators));
})(this, (function (exports, i0, common, rxjs, operators) { 'use strict';
function _interopNamespace(e) {
if (e && e.__esModule) return e;
var n = Object.create(null);
if (e) {
Object.keys(e).forEach(function (k) {
if (k !== 'default') {
var d = Object.getOwnPropertyDescriptor(e, k);
Object.defineProperty(n, k, d.get ? d : {
enumerable: true,
get: function () { return e[k]; }
});
}
});
}
n["default"] = e;
return Object.freeze(n);
}
var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
/******************************************************************************
Copyright (c) Microsoft Corporation.
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */
/* global Reflect, Promise */
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b)
if (Object.prototype.hasOwnProperty.call(b, p))
d[p] = b[p]; };
return extendStatics(d, b);
};
function __extends(d, b) {
if (typeof b !== "function" && b !== null)
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
}
var __assign = function () {
__assign = Object.assign || function __assign(t) {
for (var s, i = 1, n = arguments.length; i < n; i++) {
s = arguments[i];
for (var p in s)
if (Object.prototype.hasOwnProperty.call(s, p))
t[p] = s[p];
}
return t;
};
return __assign.apply(this, arguments);
};
function __rest(s, e) {
var t = {};
for (var p in s)
if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
t[p] = s[p];
if (s != null && typeof Object.getOwnPropertySymbols === "function")
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
t[p[i]] = s[p[i]];
}
return t;
}
function __decorate(decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
r = Reflect.decorate(decorators, target, key, desc);
else
for (var i = decorators.length - 1; i >= 0; i--)
if (d = decorators[i])
r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
return c > 3 && r && Object.defineProperty(target, key, r), r;
}
function __param(paramIndex, decorator) {
return function (target, key) { decorator(target, key, paramIndex); };
}
function __esDecorate(ctor, descriptorIn, decorators, contextIn, initializers, extraInitializers) {
function accept(f) { if (f !== void 0 && typeof f !== "function")
throw new TypeError("Function expected"); return f; }
var kind = contextIn.kind, key = kind === "getter" ? "get" : kind === "setter" ? "set" : "value";
var target = !descriptorIn && ctor ? contextIn["static"] ? ctor : ctor.prototype : null;
var descriptor = descriptorIn || (target ? Object.getOwnPropertyDescriptor(target, contextIn.name) : {});
var _, done = false;
for (var i = decorators.length - 1; i >= 0; i--) {
var context = {};
for (var p in contextIn)
context[p] = p === "access" ? {} : contextIn[p];
for (var p in contextIn.access)
context.access[p] = contextIn.access[p];
context.addInitializer = function (f) { if (done)
throw new TypeError("Cannot add initializers after decoration has completed"); extraInitializers.push(accept(f || null)); };
var result = (0, decorators[i])(kind === "accessor" ? { get: descriptor.get, set: descriptor.set } : descriptor[key], context);
if (kind === "accessor") {
if (result === void 0)
continue;
if (result === null || typeof result !== "object")
throw new TypeError("Object expected");
if (_ = accept(result.get))
descriptor.get = _;
if (_ = accept(result.set))
descriptor.set = _;
if (_ = accept(result.init))
initializers.push(_);
}
else if (_ = accept(result)) {
if (kind === "field")
initializers.push(_);
else
descriptor[key] = _;
}
}
if (target)
Object.defineProperty(target, contextIn.name, descriptor);
done = true;
}
;
function __runInitializers(thisArg, initializers, value) {
var useValue = arguments.length > 2;
for (var i = 0; i < initializers.length; i++) {
value = useValue ? initializers[i].call(thisArg, value) : initializers[i].call(thisArg);
}
return useValue ? value : void 0;
}
;
function __propKey(x) {
return typeof x === "symbol" ? x : "".concat(x);
}
;
function __setFunctionName(f, name, prefix) {
if (typeof name === "symbol")
name = name.description ? "[".concat(name.description, "]") : "";
return Object.defineProperty(f, "name", { configurable: true, value: prefix ? "".concat(prefix, " ", name) : name });
}
;
function __metadata(metadataKey, metadataValue) {
if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
return Reflect.metadata(metadataKey, metadataValue);
}
function __awaiter(thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try {
step(generator.next(value));
}
catch (e) {
reject(e);
} }
function rejected(value) { try {
step(generator["throw"](value));
}
catch (e) {
reject(e);
} }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
}
function __generator(thisArg, body) {
var _ = { label: 0, sent: function () { if (t[0] & 1)
throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function () { return this; }), g;
function verb(n) { return function (v) { return step([n, v]); }; }
function step(op) {
if (f)
throw new TypeError("Generator is already executing.");
while (g && (g = 0, op[0] && (_ = 0)), _)
try {
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done)
return t;
if (y = 0, t)
op = [op[0] & 2, t.value];
switch (op[0]) {
case 0:
case 1:
t = op;
break;
case 4:
_.label++;
return { value: op[1], done: false };
case 5:
_.label++;
y = op[1];
op = [0];
continue;
case 7:
op = _.ops.pop();
_.trys.pop();
continue;
default:
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) {
_ = 0;
continue;
}
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) {
_.label = op[1];
break;
}
if (op[0] === 6 && _.label < t[1]) {
_.label = t[1];
t = op;
break;
}
if (t && _.label < t[2]) {
_.label = t[2];
_.ops.push(op);
break;
}
if (t[2])
_.ops.pop();
_.trys.pop();
continue;
}
op = body.call(thisArg, _);
}
catch (e) {
op = [6, e];
y = 0;
}
finally {
f = t = 0;
}
if (op[0] & 5)
throw op[1];
return { value: op[0] ? op[1] : void 0, done: true };
}
}
var __createBinding = Object.create ? (function (o, m, k, k2) {
if (k2 === undefined)
k2 = k;
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function () { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function (o, m, k, k2) {
if (k2 === undefined)
k2 = k;
o[k2] = m[k];
});
function __exportStar(m, o) {
for (var p in m)
if (p !== "default" && !Object.prototype.hasOwnProperty.call(o, p))
__createBinding(o, m, p);
}
function __values(o) {
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
if (m)
return m.call(o);
if (o && typeof o.length === "number")
return {
next: function () {
if (o && i >= o.length)
o = void 0;
return { value: o && o[i++], done: !o };
}
};
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
}
function __read(o, n) {
var m = typeof Symbol === "function" && o[Symbol.iterator];
if (!m)
return o;
var i = m.call(o), r, ar = [], e;
try {
while ((n === void 0 || n-- > 0) && !(r = i.next()).done)
ar.push(r.value);
}
catch (error) {
e = { error: error };
}
finally {
try {
if (r && !r.done && (m = i["return"]))
m.call(i);
}
finally {
if (e)
throw e.error;
}
}
return ar;
}
/** @deprecated */
function __spread() {
for (var ar = [], i = 0; i < arguments.length; i++)
ar = ar.concat(__read(arguments[i]));
return ar;
}
/** @deprecated */
function __spreadArrays() {
for (var s = 0, i = 0, il = arguments.length; i < il; i++)
s += arguments[i].length;
for (var r = Array(s), k = 0, i = 0; i < il; i++)
for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)
r[k] = a[j];
return r;
}
function __spreadArray(to, from, pack) {
if (pack || arguments.length === 2)
for (var i = 0, l = from.length, ar; i < l; i++) {
if (ar || !(i in from)) {
if (!ar)
ar = Array.prototype.slice.call(from, 0, i);
ar[i] = from[i];
}
}
return to.concat(ar || Array.prototype.slice.call(from));
}
function __await(v) {
return this instanceof __await ? (this.v = v, this) : new __await(v);
}
function __asyncGenerator(thisArg, _arguments, generator) {
if (!Symbol.asyncIterator)
throw new TypeError("Symbol.asyncIterator is not defined.");
var g = generator.apply(thisArg, _arguments || []), i, q = [];
return i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i;
function verb(n) { if (g[n])
i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }
function resume(n, v) { try {
step(g[n](v));
}
catch (e) {
settle(q[0][3], e);
} }
function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }
function fulfill(value) { resume("next", value); }
function reject(value) { resume("throw", value); }
function settle(f, v) { if (f(v), q.shift(), q.length)
resume(q[0][0], q[0][1]); }
}
function __asyncDelegator(o) {
var i, p;
return i = {}, verb("next"), verb("throw", function (e) { throw e; }), verb("return"), i[Symbol.iterator] = function () { return this; }, i;
function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: false } : f ? f(v) : v; } : f; }
}
function __asyncValues(o) {
if (!Symbol.asyncIterator)
throw new TypeError("Symbol.asyncIterator is not defined.");
var m = o[Symbol.asyncIterator], i;
return m ? m.call(o) : (o = typeof __values === "function" ? __values(o) : o[Symbol.iterator](), i = {}, verb("next"), verb("throw"), verb("return"), i[Symbol.asyncIterator] = function () { return this; }, i);
function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }
function settle(resolve, reject, d, v) { Promise.resolve(v).then(function (v) { resolve({ value: v, done: d }); }, reject); }
}
function __makeTemplateObject(cooked, raw) {
if (Object.defineProperty) {
Object.defineProperty(cooked, "raw", { value: raw });
}
else {
cooked.raw = raw;
}
return cooked;
}
;
var __setModuleDefault = Object.create ? (function (o, v) {
Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function (o, v) {
o["default"] = v;
};
function __importStar(mod) {
if (mod && mod.__esModule)
return mod;
var result = {};
if (mod != null)
for (var k in mod)
if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k))
__createBinding(result, mod, k);
__setModuleDefault(result, mod);
return result;
}
function __importDefault(mod) {
return (mod && mod.__esModule) ? mod : { default: mod };
}
function __classPrivateFieldGet(receiver, state, kind, f) {
if (kind === "a" && !f)
throw new TypeError("Private accessor was defined without a getter");
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
throw new TypeError("Cannot read private member from an object whose class did not declare it");
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
}
function __classPrivateFieldSet(receiver, state, value, kind, f) {
if (kind === "m")
throw new TypeError("Private method is not writable");
if (kind === "a" && !f)
throw new TypeError("Private accessor was defined without a setter");
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver))
throw new TypeError("Cannot write private member to an object whose class did not declare it");
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
}
function __classPrivateFieldIn(state, receiver) {
if (receiver === null || (typeof receiver !== "object" && typeof receiver !== "function"))
throw new TypeError("Cannot use 'in' operator on non-object");
return typeof state === "function" ? receiver === state : state.has(receiver);
}
var NcCommonService = /** @class */ (function () {
function NcCommonService(platformId, rendererFactory) {
var _this = this;
this.platformId = platformId;
this.rendererFactory = rendererFactory;
// ---------------------经纬度---------------------
this.x_PI = 3.14159265358979324 * 3000.0 / 180.0;
this.PI = 3.1415926535897932384626;
this.a = 6378245.0;
this.ee = 0.00669342162296594323;
// ---------------------节流、防抖---------------------
this.debounceTasks = new Map();
this.throttleTasks = new Map();
// ---------------------消息提示---------------------
this.fullLoadingElement = null;
this.fullLoadingKeyframesStyle = null;
// ---------------------调试---------------------
/**
* 美化控制台打印(log info error warning success)
*/
this.console = {
log: function (textOrTitle, content) {
var title = !content ? 'Log' : textOrTitle;
var text = !content ? textOrTitle : content;
_this.prettyPrint(title, text, '#909399');
},
info: function (textOrTitle, content) {
var title = !content ? 'Info' : textOrTitle;
var text = !content ? textOrTitle : content;
_this.prettyPrint(title, text, '#40a9ff');
},
error: function (textOrTitle, content) {
var title = !content ? 'Error' : textOrTitle;
var text = !content ? textOrTitle : content;
_this.prettyPrint(title, text, '#F56C6C');
},
warning: function (textOrTitle, content) {
var title = !content ? 'Warning' : textOrTitle;
var text = !content ? textOrTitle : content;
_this.prettyPrint(title, text, '#E6A23C');
},
success: function (textOrTitle, content) {
var title = !content ? 'Success' : textOrTitle;
var text = !content ? textOrTitle : content;
_this.prettyPrint(title, text, '#67C23A');
}
};
// 性能计时器
this.timers = {};
this.isBrowser = common.isPlatformBrowser(this.platformId);
this.renderer = this.rendererFactory.createRenderer(null, null);
}
// ---------------------数字类---------------------
/**
* 精确加法
* @param value1 第一个加数
* @param value2 第二个加数
* @returns 两数之和
*/
NcCommonService.prototype.mathAdd = function (value1, value2) {
// 将浮点数转换为字符串
var aStr = value1.toString();
var bStr = value2.toString();
// 找到小数点后的位置
var aDecimals = (aStr.split('.')[1] || '').length;
var bDecimals = (bStr.split('.')[1] || '').length;
// 找到最大的小数位数
var maxDecimals = Math.max(aDecimals, bDecimals);
// 将浮点数转换为整数
var aInt = Math.round(value1 * Math.pow(10, maxDecimals));
var bInt = Math.round(value2 * Math.pow(10, maxDecimals));
// 进行整数加法
var resultInt = aInt + bInt;
// 将结果转换回浮点数
return resultInt / Math.pow(10, maxDecimals);
};
/**
* 精确减法
* @param value1 被减数
* @param value2 减数
* @returns 两数之差
*/
NcCommonService.prototype.mathSubtract = function (value1, value2) {
// 将浮点数转换为字符串
var aStr = value1.toString();
var bStr = value2.toString();
// 找到小数点后的位置
var aDecimals = (aStr.split('.')[1] || '').length;
var bDecimals = (bStr.split('.')[1] || '').length;
// 找到最大的小数位数
var maxDecimals = Math.max(aDecimals, bDecimals);
// 将浮点数转换为整数
var aInt = Math.round(value1 * Math.pow(10, maxDecimals));
var bInt = Math.round(value2 * Math.pow(10, maxDecimals));
// 进行整数减法
var resultInt = aInt - bInt;
// 将结果转换回浮点数
return resultInt / Math.pow(10, maxDecimals);
};
/**
* 精确乘法
* @param value1 第一个乘数
* @param value2 第二个乘数
* @returns 两数之积
*/
NcCommonService.prototype.mathMultiply = function (value1, value2) {
// 将浮点数转换为字符串
var aStr = value1.toString();
var bStr = value2.toString();
// 找到小数点后的位置
var aDecimals = (aStr.split('.')[1] || '').length;
var bDecimals = (bStr.split('.')[1] || '').length;
// 将浮点数转换为整数
var aInt = parseInt(aStr.replace('.', ''));
var bInt = parseInt(bStr.replace('.', ''));
// 进行整数乘法
var resultInt = aInt * bInt;
// 计算最终的小数位数
var totalDecimals = aDecimals + bDecimals;
// 将结果转换回浮点数
return resultInt / Math.pow(10, totalDecimals);
};
/**
* 精确除法
* @param value1 被除数
* @param value2 除数
* @returns 两数之商
*/
NcCommonService.prototype.mathDivide = function (value1, value2) {
// 将浮点数转换为字符串
var aStr = value1.toString();
var bStr = value2.toString();
// 找到小数点后的位置
var aDecimals = (aStr.split('.')[1] || '').length;
var bDecimals = (bStr.split('.')[1] || '').length;
// 找到最大的小数位数
var maxDecimals = Math.max(aDecimals, bDecimals);
// 将浮点数转换为整数
var aInt = Math.round(value1 * Math.pow(10, maxDecimals));
var bInt = Math.round(value2 * Math.pow(10, maxDecimals));
// 进行整数除法并直接返回结果
return aInt / bInt;
};
/**
* 保留指定小数位数
* @param num 需要处理的数值
* @param len 要保留的小数位数
* @returns 处理后的数值,保留指定小数位数
*/
NcCommonService.prototype.retainDecimal = function (num, len) {
var n = Math.pow(10, len);
return Math.round(num * n) / n;
};
/**
* 保留指定小数位数的百分比
* @param num 需要处理的数值
* @param len 要保留的小数位数
* @returns 处理后的百分比值,保留指定小数位数
*/
NcCommonService.prototype.retainPercentDecimal = function (num, len) {
var n = Math.pow(10, len + 2);
return this.mathMultiply(Math.round(num * n) / n, 100);
};
// ---------------------存储---------------------
/**
* 设置Cookie
* @param key Cookie的键
* @param value Cookie的值
* @param ttl Cookie的生存时间(毫秒)
*/
NcCommonService.prototype.setCookie = function (key, value, ttl) {
var expires = new Date(Date.now() + ttl).toUTCString();
document.cookie = key + "=" + encodeURIComponent(value) + ";expires=" + expires + ";path=/";
};
/**
* 获取Cookie
* @param key Cookie的键
* @returns Cookie的值,如果不存在则返回null
*/
NcCommonService.prototype.getCookie = function (key) {
var match = document.cookie.match(new RegExp('(^| )' + key + '=([^;]+)'));
return match ? decodeURIComponent(match[2]) : null;
};
/**
* 删除指定的Cookie
* @param key 要删除的Cookie的键
*/
NcCommonService.prototype.removeCookie = function (key) {
document.cookie = key + "=;expires=Thu, 01 Jan 1970 00:00:00 GMT;path=/";
};
/**
* 清除所有Cookie
*/
NcCommonService.prototype.clearCookie = function () {
document.cookie.split(";").forEach(function (c) {
document.cookie = c.replace(/^ +/, "").replace(/=.*/, "=;expires=Thu, 01 Jan 1970 00:00:00 GMT;path=/");
});
};
/**
* 设置LocalStorage项
* @param key LocalStorage的键
* @param value LocalStorage的值
* @param ttl 可选的生存时间(毫秒)
*/
NcCommonService.prototype.setLocalStorage = function (key, value, ttl) {
var item = { value: value, expiry: ttl ? Date.now() + ttl : null };
localStorage.setItem(key, JSON.stringify(item));
};
/**
* 获取LocalStorage项
* @param key LocalStorage的键
* @returns LocalStorage的值,如果不存在或已过期则返回null
*/
NcCommonService.prototype.getLocalStorage = function (key) {
var itemStr = localStorage.getItem(key);
if (!itemStr)
return null;
var item = JSON.parse(itemStr);
if (item.expiry && Date.now() > item.expiry) {
localStorage.removeItem(key);
return null;
}
return item.value;
};
/**
* 删除指定的LocalStorage项
* @param key 要删除的LocalStorage项的键
*/
NcCommonService.prototype.removeLocalStorage = function (key) {
localStorage.removeItem(key);
};
/**
* 清除所有LocalStorage项
*/
NcCommonService.prototype.clearLocalStorage = function () {
localStorage.clear();
};
/**
* 设置SessionStorage项
* @param key SessionStorage的键
* @param value SessionStorage的值
*/
NcCommonService.prototype.setSessionStorage = function (key, value) {
sessionStorage.setItem(key, JSON.stringify(value));
};
/**
* 获取SessionStorage项
* @param key SessionStorage的键
* @returns SessionStorage的值,如果不存在则返回null
*/
NcCommonService.prototype.getSessionStorage = function (key) {
var item = sessionStorage.getItem(key);
return item ? JSON.parse(item) : null;
};
/**
* 删除指定的SessionStorage项
* @param key 要删除的SessionStorage项的键
*/
NcCommonService.prototype.removeSessionStorage = function (key) {
sessionStorage.removeItem(key);
};
/**
* 清除所有SessionStorage项
*/
NcCommonService.prototype.clearSessionStorage = function () {
sessionStorage.clear();
};
// ---------------------日期类---------------------
/**
* 格式化时间
* @param format 格式化模板,如 'yyyy-MM-dd HH:mm:ss',注意MM为月份、mm为分钟
* @param dateInput 可选。要格式化的日期,可以是Date对象、时间戳(number)或日期字符串,默认为当前时间
* @returns 格式化后的日期字符串
*/
NcCommonService.prototype.formatDate = function (format, dateInput) {
if (!format) {
return '';
}
var date;
if (!dateInput) {
date = new Date();
}
else if (dateInput instanceof Date) {
date = dateInput;
}
else {
date = new Date(dateInput);
}
// 验证日期是否有效
if (isNaN(date.getTime())) {
console.warn('Invalid date input provided to formatDate');
return '';
}
var year = date.getFullYear().toString();
var month = (date.getMonth() + 1).toString().padStart(2, '0');
var day = (date.getDate()).toString().padStart(2, '0');
var hours = (date.getHours()).toString().padStart(2, '0');
var minutes = (date.getMinutes()).toString().padStart(2, '0');
var seconds = (date.getSeconds()).toString().padStart(2, '0');
return format
.replace('yyyy', year)
.replace('MM', month)
.replace('dd', day)
.replace('HH', hours)
.replace('mm', minutes)
.replace('ss', seconds);
};
/**
* 获取两日期间的所有日期
* @param startDate 开始日期
* @param endDate 结束日期
* @returns 日期数组
*/
NcCommonService.prototype.getRangeDate = function (startDate, endDate) {
var datesArray = [];
var currentDate = new Date(startDate);
while (currentDate <= endDate) {
datesArray.push(new Date(currentDate));
currentDate.setDate(currentDate.getDate() + 1);
}
return datesArray;
};
/**
* 获取两日期间的天数
* @param startDate 开始日期
* @param endDate 结束日期
* @returns 天数
*/
NcCommonService.prototype.getDaysBetween = function (startDate, endDate) {
var oneDay = 24 * 60 * 60 * 1000;
return Math.round(Math.abs((startDate.getTime() - endDate.getTime()) / oneDay));
};
// ---------------------数组、对象---------------------
/**
* 数组去重
* @param array 要去重的数组
* @param keyFn 可选的函数,用于从每个数组项中提取用于比较的键,例如:item => item.id
* @returns T[]
*/
NcCommonService.prototype.uniqueArray = function (array, keyFn) {
if (!keyFn) {
return Array.from(new Set(array));
}
var seen = new Set();
return array.filter(function (item) {
var key = keyFn(item);
if (seen.has(key)) {
return false;
}
seen.add(key);
return true;
});
};
/**
* 数组排序
* @param array 要排序的数组
* @param order 指定排序顺序,'asc' 为升序,'desc' 为降序
* @param keyFn 可选。可以是对象的键名或一个函数,用于从数组项中提取排序值,例如:'age'或 item => item.name.length
* @returns T[]
*/
NcCommonService.prototype.sortArray = function (array, order, key) {
return __spreadArray([], __read(array)).sort(function (a, b) {
var valueA;
var valueB;
if (typeof key === 'function') {
valueA = key(a);
valueB = key(b);
}
else if (key) {
valueA = a[key];
valueB = b[key];
}
else {
valueA = a;
valueB = b;
}
if (valueA === valueB)
return 0;
if (typeof valueA === 'string' && typeof valueB === 'string') {
return order === 'asc'
? valueA.localeCompare(valueB)
: valueB.localeCompare(valueA);
}
return order === 'asc'
? (valueA < valueB ? -1 : 1)
: (valueB < valueA ? -1 : 1);
});
};
/**
* 判断对象是否为空
* @param obj
* @returns boolean
*/
NcCommonService.prototype.isObjectEmpty = function (obj) {
return Object.keys(obj).length === 0;
};
/**
* 百度坐标系 (BD-09) 与火星坐标系 (GCJ-02) 的转换
* 即百度 转 谷歌、高德
* @param lng 经度
* @param lat 纬度
* @returns [lng, lat]
*/
NcCommonService.prototype.bd09togcj02 = function (lng, lat) {
var x_pi = 3.14159265358979324 * 3000.0 / 180.0;
var x = lng - 0.0065;
var y = lat - 0.006;
var z = Math.sqrt(x * x + y * y) - 0.00002 * Math.sin(y * x_pi);
var theta = Math.atan2(y, x) - 0.000003 * Math.cos(x * x_pi);
var gg_lng = z * Math.cos(theta);
var gg_lat = z * Math.sin(theta);
return [gg_lng, gg_lat];
};
/**
* 火星坐标系 (GCJ-02) 与百度坐标系 (BD-09) 的转换
* 即谷歌、高德 转 百度
* @param lng 经度
* @param lat 纬度
* @returns [lng, lat]
*/
NcCommonService.prototype.gcj02tobd09 = function (lng, lat) {
var z = Math.sqrt(lng * lng + lat * lat) + 0.00002 * Math.sin(lat * this.x_PI);
var theta = Math.atan2(lat, lng) + 0.000003 * Math.cos(lng * this.x_PI);
var bd_lng = z * Math.cos(theta) + 0.0065;
var bd_lat = z * Math.sin(theta) + 0.006;
return [bd_lng, bd_lat];
};
/**
* WGS84转火星坐标系 (GCJ-02)
* 即WGS84 转 谷歌、高德
* @param lng 经度
* @param lat 纬度
* @returns [lng, lat]
*/
NcCommonService.prototype.wgs84togcj02 = function (lng, lat) {
if (this.out_of_china(lng, lat)) {
return [lng, lat];
}
else {
var dlat = this.transformlat(lng - 105.0, lat - 35.0);
var dlng = this.transformlng(lng - 105.0, lat - 35.0);
var radlat = lat / 180.0 * this.PI;
var magic = Math.sin(radlat);
magic = 1 - this.ee * magic * magic;
var sqrtmagic = Math.sqrt(magic);
dlat = (dlat * 180.0) / ((this.a * (1 - this.ee)) / (magic * sqrtmagic) * this.PI);
dlng = (dlng * 180.0) / (this.a / sqrtmagic * Math.cos(radlat) * this.PI);
var mglat = lat + dlat;
var mglng = lng + dlng;
return [mglng, mglat];
}
};
/**
* 火星坐标系 (GCJ-02)转WGS84
* 即谷歌、高德 转 WGS84
* @param lng 经度
* @param lat 纬度
* @returns [lng, lat]
*/
NcCommonService.prototype.gcj02towgs84 = function (lng, lat) {
if (this.out_of_china(lng, lat)) {
return [lng, lat];
}
else {
var dlat = this.transformlat(lng - 105.0, lat - 35.0);
var dlng = this.transformlng(lng - 105.0, lat - 35.0);
var radlat = lat / 180.0 * this.PI;
var magic = Math.sin(radlat);
magic = 1 - this.ee * magic * magic;
var sqrtmagic = Math.sqrt(magic);
dlat = (dlat * 180.0) / ((this.a * (1 - this.ee)) / (magic * sqrtmagic) * this.PI);
dlng = (dlng * 180.0) / (this.a / sqrtmagic * Math.cos(radlat) * this.PI);
var mglat = lat + dlat;
var mglng = lng + dlng;
return [lng * 2 - mglng, lat * 2 - mglat];
}
};
NcCommonService.prototype.transformlat = function (lng, lat) {
var ret = -100.0 + 2.0 * lng + 3.0 * lat + 0.2 * lat * lat + 0.1 * lng * lat + 0.2 * Math.sqrt(Math.abs(lng));
ret += (20.0 * Math.sin(6.0 * lng * this.PI) + 20.0 * Math.sin(2.0 * lng * this.PI)) * 2.0 / 3.0;
ret += (20.0 * Math.sin(lat * this.PI) + 40.0 * Math.sin(lat / 3.0 * this.PI)) * 2.0 / 3.0;
ret += (160.0 * Math.sin(lat / 12.0 * this.PI) + 320 * Math.sin(lat * this.PI / 30.0)) * 2.0 / 3.0;
return ret;
};
NcCommonService.prototype.transformlng = function (lng, lat) {
var ret = 300.0 + lng + 2.0 * lat + 0.1 * lng * lng + 0.1 * lng * lat + 0.1 * Math.sqrt(Math.abs(lng));
ret += (20.0 * Math.sin(6.0 * lng * this.PI) + 20.0 * Math.sin(2.0 * lng * this.PI)) * 2.0 / 3.0;
ret += (20.0 * Math.sin(lng * this.PI) + 40.0 * Math.sin(lng / 3.0 * this.PI)) * 2.0 / 3.0;
ret += (150.0 * Math.sin(lng / 12.0 * this.PI) + 300.0 * Math.sin(lng / 30.0 * this.PI)) * 2.0 / 3.0;
return ret;
};
/**
* 判断是否在国内,不在国内则不做偏移
*/
NcCommonService.prototype.out_of_china = function (lng, lat) {
return (lng < 72.004 || lng > 137.8347) || ((lat < 0.8293 || lat > 55.8271) || false);
};
/**
* 小数形式经纬度转度分秒形式(秒保留3位小数)
* @param digital 109.86330555555556
* @returns degrees '109°51′47.9″'
*/
NcCommonService.prototype.digitalToDegrees = function (digital) {
var digitalString = digital.toString();
var index1 = digitalString.indexOf('.');
var du = index1 < 0 ? Number(digitalString) : Number(digitalString.substring(0, index1)); //109
var fen = 0;
var miao = 0;
if (index1 > 0) {
var strFen = Number("0" + digitalString.substring(index1)); //0.86330555555556
var strFenString = (strFen * 60).toString(); //'51.7983333333336'
var index2 = strFenString.indexOf('.');
if (index2 > 0) {
fen = Number(strFenString.substring(0, index2)); //51
var strMiao = Number("0" + strFenString.substring(index2)); //0.7983333333336
miao = Number((strMiao * 60).toFixed(3)); //47.900000000016 47.9
}
else {
fen = Number(strFenString);
}
}
return du + "\u00B0" + fen + "\u2032" + miao + "\u2033";
};
/**
* 度分秒形式经纬度转小数形式
* @param degrees '109°51′47.900000000016″'
* @returns digital 109.86330555555556
*/
NcCommonService.prototype.degreesToDigital = function (degrees) {
var temp1 = degrees.split('°');
var temp2 = temp1[1].split('′');
var du = temp1[0];
var fen = temp2[0];
var miao = temp2[1].substring(0, temp2[1].length - 1);
return Number(du) + Number(fen) / 60 + Number(miao) / 3600;
};
/**
* 防抖(Debounce):适用于避免短时间内多次触发的场景,只有在事件停止触发后的一段时间才会执行。例如:搜索框输入,避免频繁的API请求。
* @param key 用于标识Subject的唯一键,不同防抖任务应使用不同的key,相同key的任务会共享首次设置的delay时间
* @param delay 防抖延迟时间(毫秒)
* @param fn 要防抖的函数
*/
NcCommonService.prototype.debounce = function (key, delay, fn) {
var subject = this.debounceTasks.get(key);
if (!subject) {
subject = new rxjs.Subject();
subject.pipe(operators.debounceTime(delay)).subscribe(function (fnToExecute) {
fnToExecute();
});
this.debounceTasks.set(key, subject);
}
subject.next(fn);
};
/**
* 节流(Throttle):适用于限制事件在固定时间间隔内执行的场景,确保事件不会过于频繁地触发。例如:滚动页面时的事件处理,避免频繁的计算和渲染。
* @param key 用于标识Subject的唯一键,不同节流任务应使用不同的key,相同key的任务会共享首次设置的delay时间
* @param delay 节流延迟时间(毫秒)
* @param fn 要节流的函数
*/
NcCommonService.prototype.throttle = function (key, delay, fn) {
var subject = this.throttleTasks.get(key);
if (!subject) {
subject = new rxjs.Subject();
subject.pipe(operators.throttleTime(delay)).subscribe(function (fnToExecute) {
fnToExecute();
});
this.throttleTasks.set(key, subject);
}
subject.next(fn);
};
/**
* 显示全屏加载中(全屏蒙版)
* @param content 可选。提示内容,默认:'加载中,请稍后...'
*/
NcCommonService.prototype.showFullLoading = function (content) {
if (content === void 0) { content = '加载中,请稍后...'; }
if (this.fullLoadingElement) {
return;
}
this.fullLoadingElement = this.renderer.createElement('div');
this.renderer.addClass(this.fullLoadingElement, 'full-loading-container');
this.renderer.setStyle(this.fullLoadingElement, 'position', 'fixed');
this.renderer.setStyle(this.fullLoadingElement, 'top', '0');
this.renderer.setStyle(this.fullLoadingElement, 'left', '0');
this.renderer.setStyle(this.fullLoadingElement, 'width', '100%');
this.renderer.setStyle(this.fullLoadingElement, 'height', '100%');
this.renderer.setStyle(this.fullLoadingElement, 'background-color', 'rgba(0,0,0,0.5)');
this.renderer.setStyle(this.fullLoadingElement, 'display', 'flex');
this.renderer.setStyle(this.fullLoadingElement, 'flex-direction', 'column');
this.renderer.setStyle(this.fullLoadingElement, 'justify-content', 'center');
this.renderer.setStyle(this.fullLoadingElement, 'align-items', 'center');
this.renderer.setStyle(this.fullLoadingElement, 'z-index', '9999');
var spinner = this.renderer.createElement('div');
this.renderer.addClass(spinner, 'full-loading-spinner');
this.renderer.setStyle(spinner, 'border', '4px solid #f3f3f3');
this.renderer.setStyle(spinner, 'border-top', '4px solid #3498db');
this.renderer.setStyle(spinner, 'border-radius', '50%');
this.renderer.setStyle(spinner, 'width', '50px');
this.renderer.setStyle(spinner, 'height', '50px');
this.renderer.setStyle(spinner, 'animation', 'fullSpin 1s linear infinite');
var loadingText = this.renderer.createElement('div');
this.renderer.addClass(loadingText, 'full-loading-text');
this.renderer.setStyle(loadingText, 'color', 'white');
this.renderer.setStyle(loadingText, 'margin-top', '20px');
this.renderer.setStyle(loadingText, 'font-size', '18px');
this.renderer.setStyle(loadingText, 'letter-spacing', '1.5px');
this.renderer.appendChild(loadingText, this.renderer.createText(content));
var keyframes = "\n @keyframes fullSpin {\n 0% { transform: rotate(0deg); }\n 100% { transform: rotate(360deg); }\n }\n ";
this.fullLoadingKeyframesStyle = this.renderer.createElement('style');
this.renderer.appendChild(this.fullLoadingKeyframesStyle, this.renderer.createText(keyframes));
this.renderer.appendChild(document.body, this.fullLoadingKeyframesStyle);
this.renderer.appendChild(this.fullLoadingElement, spinner);
if (content) {
this.renderer.appendChild(this.fullLoadingElement, loadingText);
}
this.renderer.appendChild(document.body, this.fullLoadingElement);
};
/**
* 移除全屏加载中(全屏蒙版)
*/
NcCommonService.prototype.removeFullLoading = function () {
if (this.fullLoadingElement) {
this.renderer.removeChild(document.body, this.fullLoadingElement);
this.fullLoadingElement = null;
}
if (this.fullLoadingKeyframesStyle) {
this.renderer.removeChild(document.body, this.fullLoadingKeyframesStyle);
this.fullLoadingKeyframesStyle = null;
}
};
//美化打印
NcCommonService.prototype.prettyPrint = function (title, content, color) {
console.log("%c " + title + " %c " + (typeof content == 'object' ? '👇' : content) + " %c", "background:" + color + ";border:1px solid " + color + "; padding: 1px; border-radius: 2px 0 0 2px; color: #fff;", "border:1px solid " + color + "; border-radius: 0 2px 2px 0; color: " + color + ";padding: 1px;", 'background:transparent');
if (typeof content == 'object') {
console.table(content);
}
};
;
/**
* 开始性能计时器
* @param timerName 计时器名称
*/
NcCommonService.prototype.startTimer = function (timerName) {
this.timers[timerName] = performance.now();
};
/**
* 结束性能计时器并返回持续时间
* @param timerName 计时器名称
* @returns 计时器持续时间(毫秒)
*/
NcCommonService.prototype.endTimer = function (timerName) {
if (!this.timers[timerName]) {
console.warn("\u8BA1\u65F6\u5668 \"" + timerName + "\" \u4E0D\u5B58\u5728\u3002");
return 0;
}
var duration = performance.now() - this.timers[timerName];
delete this.timers[timerName];
return duration;
};
// ---------------------其他---------------------
/**
* 深克隆
* @param obj 被克隆对象
* @returns 克隆对象
*/
NcCommonService.prototype.deepClone = function (obj, seen) {
var e_1, _a, e_2, _b, e_3, _c;
if (seen === void 0) { seen = new Map(); }
// Handle immutable types and functions
if (obj === null || typeof obj !== 'object') {
return obj;
}
// Handle circular references
if (seen.has(obj)) {
return seen.get(obj);
}
// Handle Date
if (obj instanceof Date) {
return new Date(obj.getTime());
}
// Handle RegExp
if (obj instanceof RegExp) {
var regExpClone = new RegExp(obj.source, obj.flags);
regExpClone.lastIndex = obj.lastIndex; // Preserve the lastIndex property
return regExpClone;
}
// Handle Array
if (Array.isArray(obj)) {
var arrClone = [];
seen.set(obj, arrClone);
try {
for (var obj_1 = __values(obj), obj_1_1 = obj_1.next(); !obj_1_1.done; obj_1_1 = obj_1.next()) {
var item = obj_1_1.value;
arrClone.push(this.deepClone(item, seen));
}
}
catch (e_1_1) { e_1 = { error: e_1_1 }; }
finally {
try {
if (obj_1_1 && !obj_1_1.done && (_a = obj_1.return)) _a.call(obj_1);
}
finally { if (e_1) throw e_1.error; }
}
return arrClone;
}
// Handle Set
if (obj instanceof Set) {
var setClone = new Set();
seen.set(obj, setClone);
try {
for (var obj_2 = __values(obj), obj_2_1 = obj_2.next(); !obj_2_1.done; obj_2_1 = obj_2.next()) {
var item = obj_2_1.value;
setClone.add(this.deepClone(item, seen));
}
}
catch (e_2_1) { e_2 = { error: e_2_1 }; }
finally {
try {
if (obj_2_1 && !obj_2_1.done && (_b = obj_2.return)) _b.call(obj_2);
}
finally { if (e_2) throw e_2.error; }
}
return setClone;
}
// Handle Map
if (obj instanceof Map) {
var mapClone = new Map();
seen.set(obj, mapClone);
try {
for (var obj_3 = __values(obj), obj_3_1 = obj_3.next(); !obj_3_1.done; obj_3_1 = obj_3.next()) {
var _d = __read(obj_3_1.value, 2), key = _d[0], value = _d[1];
mapClone.set(this.deepClone(key, seen), this.deepClone(value, seen));
}
}
catch (e_3_1) { e_3 = { error: e_3_1 }; }
finally {
try {
if (obj_3_1 && !obj_3_1.done && (_c = obj_3.return)) _c.call(obj_3);
}
finally { if (e_3) throw e_3.error; }
}
return mapClone;
}
// Handle Object
var objClone = Object.create(Object.getPrototypeOf(obj));
seen.set(obj, objClone);
for (var key in obj) {
if (Object.prototype.hasOwnProperty.call(obj, key)) {
objClone[key] = this.deepClone(obj[key], seen);
}
}
return objClone;
};
/**
* 获取文件后缀
* @param filename string 文件名
* @returns extension
*/
NcCommonService.prototype.getFileExtension = function (filename) {
if (!filename) {
return '';
}
var filenameArr = filename.split('.');
if (filenameArr.length == 0) {
return '';
}
else {
var extension = filenameArr.pop();
return extension.toLowerCase();
}
};
/**
* jsonp封装
* @param obj \{url: '', success: ()=> {}}
*/
NcCommonService.prototype.jsonpFunction = function (obj) {
// 创建一个script标签;
var script = document.createElement("script");
// 给函数起名字,定义为全局函数;
var fnName = "jsonp" + new Date().getTime();
// window.aaa就是把aaa设置为全局变量!
window[fnName] = obj.success;
// 改变src,添加到head中
if (obj.url.includes('?')) {
script.src = obj.url + "&callback=" + fnName;
}
else {
script.src = obj.url + "?callback=" + fnName;
}
// 把script标签添加到head标签中,就会发送src的请求了
document.head.appendChild(script);
// 代码执行完毕,把script标签删除
script.onload = function () {
document.head.removeChild(script);
window[fnName] = undefined;
};
};
/**
* 生成随机颜色
* @returns HEX
*/
NcCommonService.prototype.generateRandomColor = function () {
return '#' + Math.floor(Math.random() * 16777215).toString(16).padStart(6, '0');
};
/**
* 生成UUID
* @returns UUID
*/
NcCommonService.prototype.generateUUID = function () {
return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function (c) {
var r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8);
return v.toString(16);
});
};
/**
* 验证密码强度(必须包含大、小写字母、数字、特殊字符至少三类,长度8-16位)
* @param password 待验证的密码
* @returns 密码是否符合要求
*/
NcCommonService.prototype.passwordValidate = function (password) {
// 检查密码长度是否在8到16位之间
if (password.length < 8 || password.length > 16) {
return false;
}
// 定义正则表达式规则
var rC = {
lW: '[a-z]',
uW: '[A-Z]',
nW: '[0-9]',
sW: '[`~!@$%\^\&\(\)\-_\+=\{\}\[\]|\\:;\"\'<>,\.\?\/_]' // 特殊字符
};
/**
* 检查字符串是否匹配正则表达式
* @param str 待检查的字符串
* @param rStr 正则表达式字符串
* @returns 是否匹配
*/
function Reg(str, rStr) {
var reg = new RegExp(rStr);
return reg.test(str);
}
// 检查密码是否包含各种字符类型
var tR = {
l: Reg(password, rC.lW),
u: Reg(password, rC.uW),
n: Reg(password, rC.nW),
s: Reg(password, rC.sW) // 是否包含特殊字符
};
// 密码必须包含以下四种组合之一:
// 1. 小写字母 + 大写字母 + 数字
// 2. 小写字母 + 大写字母 + 特殊字符
// 3. 特殊字符 + 大写字母 + 数字
// 4. 特殊字符 + 小写字母 + 数字
return (tR.l && tR.u && tR.n) || (tR.l && tR.u && tR.s) || (tR.s && tR.u && tR.n) || (tR.s && tR.l && tR.n);
};
return NcCommonService;
}());
NcCommonService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.1.5", ngImport: i0__namespace, type: NcCommonService, deps: [{ token: i0.PLATFORM_ID }, { token: i0__namespace.RendererFactory2 }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
NcCommonService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.1.5", ngImport: i0__namespace, type: NcCommonService });
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.1.5", ngImport: i0__namespace, type: NcCommonService, decorators: [{
type: i0.Injectable
}], ctorParameters: function () {
return [{ type: Object, decorators: [{
type: i0.Inject,
args: [i0.PLATFORM_ID]
}] }, { type: i0__namespace.RendererFactory2 }];
} });
var NcCommonServiceModule = /** @class */ (function () {
function NcCommonServiceModule() {
}
return NcCommonServiceModule;
}());
NcCommonServiceModule.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.1.5", ngImport: i0__namespace, type: NcCommonServiceModule, deps: [], target: i0__namespace.ɵɵFactoryTarget.NgModule });
NcCommonServiceModule.ɵmod = i0__namespace.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.1.5", ngImport: i0__namespace, type: NcCommonServiceModule });
NcCommonServiceModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.1.5", ngImport: i0__namespace, type: NcCommonServiceModule, providers: [NcCommonService] });
i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.1.5", ngImport: i0__namespace, type: NcCommonServiceModule, decorators: [{
type: i0.NgModule,
args: [{
providers: [NcCommonService]
}]
}] });
/**
* Generated bundle index. Do not edit.
*/
exports.NcCommonService = NcCommonService;
exports.NcCommonServiceModule = NcCommonServiceModule;
Object.defineProperty(exports, '__esModule', { value: true });
}));
//# sourceMappingURL=ng-cw-v12-common-service.umd.js.map