igniteui-react-core
Version:
Ignite UI React Core.
69 lines (68 loc) • 3.03 kB
JavaScript
/*
THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE AGREEMENT ("AGREEMENT") LOCATED HERE:
https://www.infragistics.com/legal/license/igultimate-la
https://www.infragistics.com/legal/license/igultimate-eula
GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE: you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company.
*/
import { Base, fromEnum, EnumUtil, markType } from "./type";
import { CodeGenerationTargetPlatforms_$type } from "./CodeGenerationTargetPlatforms";
import { stringContains, stringEndsWith, stringStartsWith } from "./string";
/**
* @hidden
*/
export let WebImportsHalper = /*@__PURE__*/ (() => {
class WebImportsHalper extends Base {
static d(a, b, c, d, e, f, g) {
for (let h of fromEnum(f)) {
let i = h;
let j = h;
let k = null;
if (stringContains(i, ":")) {
let l = i.split(':');
i = l[0];
k = l[1];
j = i;
}
if (stringEndsWith(i, "Component")) {
i = i.substr(0, i.length - ("Component").length);
}
if (stringStartsWith(i, d)) {
i = i.substr(d.length);
}
k = (((m) => m != null ? m : k)(WebImportsHalper.c(i, e, a)));
if (k != null) {
g.addPackageImport(k, j);
}
else {
g.addPackageImport("igniteui-" + b + "-" + c, j);
}
}
}
static c(a, b, c) {
let d = null;
if (b.getMetadata(a, "__importTypes" + EnumUtil.getName(CodeGenerationTargetPlatforms_$type, c.platform)) != null) {
d = b.getMetadata(a, "__importTypes" + EnumUtil.getName(CodeGenerationTargetPlatforms_$type, c.platform)).specificExternalType;
}
else if (b.getMetadata("Web" + a, "__importTypes" + EnumUtil.getName(CodeGenerationTargetPlatforms_$type, c.platform)) != null) {
d = b.getMetadata("Web" + a, "__importTypes" + EnumUtil.getName(CodeGenerationTargetPlatforms_$type, c.platform)).specificExternalType;
}
return d;
}
static b(a, b) {
let c = WebImportsHalper.c(a.b.owningType, a.b.owningContext, b);
if (c != null) {
return a.b.specificType + ":" + c;
}
return a.b.specificType;
}
a(a, b) {
let c = false;
if (b.getMetadata(a, "__isPlainObject") != null && b.getMetadata(a, "__marshalByValue") == null) {
c = true;
}
return c;
}
}
WebImportsHalper.$t = /*@__PURE__*/ markType(WebImportsHalper, 'WebImportsHalper');
return WebImportsHalper;
})();