@wcardinal/wcardinal-ui 0.208.0 → 0.209.0
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/dist/types/wcardinal/ui/shape/e-shape-data-mapper-impl.d.ts +1 -1
- package/dist/wcardinal/ui/shape/e-shape-data-mapper-impl.js +4 -3
- package/dist/wcardinal/ui/shape/e-shape-data-mapper-impl.js.map +1 -1
- package/dist/wcardinal-ui-theme-dark.js +1 -1
- package/dist/wcardinal-ui-theme-dark.min.js +1 -1
- package/dist/wcardinal-ui-theme-white.js +1 -1
- package/dist/wcardinal-ui-theme-white.min.js +1 -1
- package/dist/wcardinal-ui.cjs.js +5 -4
- package/dist/wcardinal-ui.js +5 -4
- package/dist/wcardinal-ui.min.js +2 -2
- package/dist/wcardinal-ui.min.js.map +1 -1
- package/package.json +1 -1
|
@@ -5,7 +5,7 @@ export declare class EShapeDataMapperImpl implements EShapeDataMapper {
|
|
|
5
5
|
protected static SPANS: number[];
|
|
6
6
|
protected _sources: string[] | null;
|
|
7
7
|
constructor(source?: string | null);
|
|
8
|
-
map(value: EShapeDataValue, destinations: string[] | null, initial: string):
|
|
8
|
+
map(value: EShapeDataValue, destinations: string[] | null, initial: string): boolean;
|
|
9
9
|
protected newSources(source?: string | null): string[] | null;
|
|
10
10
|
static split(target?: string | null): string[] | null;
|
|
11
11
|
}
|
|
@@ -9,14 +9,14 @@ var EShapeDataMapperImpl = /** @class */ (function () {
|
|
|
9
9
|
EShapeDataMapperImpl.prototype.map = function (value, destinations, initial) {
|
|
10
10
|
var sources = this._sources;
|
|
11
11
|
if (sources == null) {
|
|
12
|
-
return;
|
|
12
|
+
return false;
|
|
13
13
|
}
|
|
14
14
|
var valueId = value.id;
|
|
15
15
|
var target = valueId.toLowerCase();
|
|
16
16
|
var first = sources[0];
|
|
17
17
|
var firstLength = first.length;
|
|
18
18
|
if (firstLength !== 0 && target.indexOf(first) !== 0) {
|
|
19
|
-
return;
|
|
19
|
+
return false;
|
|
20
20
|
}
|
|
21
21
|
var spans = EShapeDataMapperImpl.SPANS;
|
|
22
22
|
spans[0] = 0;
|
|
@@ -34,7 +34,7 @@ var EShapeDataMapperImpl = /** @class */ (function () {
|
|
|
34
34
|
else {
|
|
35
35
|
var index = target.indexOf(source, spans[ispan - 1]);
|
|
36
36
|
if (index < 0) {
|
|
37
|
-
return;
|
|
37
|
+
return false;
|
|
38
38
|
}
|
|
39
39
|
spans[ispan] = index;
|
|
40
40
|
spans[ispan + 1] = index + sourceLength;
|
|
@@ -58,6 +58,7 @@ var EShapeDataMapperImpl = /** @class */ (function () {
|
|
|
58
58
|
if (0 < initial.length) {
|
|
59
59
|
value.initial = initial;
|
|
60
60
|
}
|
|
61
|
+
return true;
|
|
61
62
|
};
|
|
62
63
|
EShapeDataMapperImpl.prototype.newSources = function (source) {
|
|
63
64
|
if (source == null) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"e-shape-data-mapper-impl.js","sourceRoot":"","sources":["../../../../src/main/typescript/wcardinal/ui/shape/e-shape-data-mapper-impl.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAKH;IAKC,8BAAY,MAAsB;QACjC,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;IACzC,CAAC;IAED,kCAAG,GAAH,UAAI,KAAsB,EAAE,YAA6B,EAAE,OAAe;QACzE,IAAM,OAAO,GAAG,IAAI,CAAC,QAAQ,CAAC;QAC9B,IAAI,OAAO,IAAI,IAAI,EAAE;YACpB,OAAO;
|
|
1
|
+
{"version":3,"file":"e-shape-data-mapper-impl.js","sourceRoot":"","sources":["../../../../src/main/typescript/wcardinal/ui/shape/e-shape-data-mapper-impl.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAKH;IAKC,8BAAY,MAAsB;QACjC,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC;IACzC,CAAC;IAED,kC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nB,OAAO,IAAI,CAAC;SACZ;QACD,IAAM,OAAO,GAAG,MAAM,CAAC,IAAI,EAAE,CAAC;QAC9B,IAAI,OAAO,CAAC,MAAM,IAAI,CAAC,EAAE;YACxB,OAAO,IAAI,CAAC;SACZ;QACD,OAAO,OAAO,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,oBAAoB,CAAC,QAAQ,CAAC,CAAC;IACnE,CAAC;IAEa,0BAAK,GAAnB,UAAoB,MAAsB;QACzC,IAAI,MAAM,IAAI,IAAI,EAAE;YACnB,OAAO,IAAI,CAAC;SACZ;QACD,IAAM,OAAO,GAAG,MAAM,CAAC,IAAI,EAAE,CAAC;QAC9B,IAAI,OAAO,CAAC,MAAM,IAAI,CAAC,EAAE;YACxB,OAAO,IAAI,CAAC;SACZ;QACD,OAAO,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IACrC,CAAC;IAtFgB,6BAAQ,GAAG,GAAG,CAAC;IACf,0BAAK,GAAa,EAAE,CAAC;IAsFvC,2BAAC;CAAA,AAxFD,IAwFC;SAxFY,oBAAoB","sourcesContent":["/*\n * Copyright (C) 2019 Toshiba Corporation\n * SPDX-License-Identifier: Apache-2.0\n */\n\nimport { EShapeDataMapper } from \"./e-shape-data-mapper\";\nimport { EShapeDataValue } from \"./e-shape-data-value\";\n\nexport class EShapeDataMapperImpl implements EShapeDataMapper {\n\tprotected static WILDCARD = \"*\";\n\tprotected static SPANS: number[] = [];\n\tprotected _sources: string[] | null;\n\n\tconstructor(source?: string | null) {\n\t\tthis._sources = this.newSources(source);\n\t}\n\n\tmap(value: EShapeDataValue, destinations: string[] | null, initial: string): boolean {\n\t\tconst sources = this._sources;\n\t\tif (sources == null) {\n\t\t\treturn false;\n\t\t}\n\n\t\tconst valueId = value.id;\n\t\tconst target = valueId.toLowerCase();\n\t\tconst first = sources[0];\n\t\tconst firstLength = first.length;\n\t\tif (firstLength !== 0 && target.indexOf(first) !== 0) {\n\t\t\treturn false;\n\t\t}\n\n\t\tconst spans = EShapeDataMapperImpl.SPANS;\n\t\tspans[0] = 0;\n\t\tspans[1] = firstLength;\n\t\tconst sourcesLength = sources.length;\n\t\tconst targetLength = target.length;\n\t\tfor (let i = 1; i < sourcesLength; ++i) {\n\t\t\tconst ispan = i << 1;\n\t\t\tconst source = sources[i];\n\t\t\tconst sourceLength = source.length;\n\t\t\tif (sourceLength === 0) {\n\t\t\t\tspans[ispan] = targetLength;\n\t\t\t\tspans[ispan + 1] = targetLength;\n\t\t\t} else {\n\t\t\t\tconst index = target.indexOf(source, spans[ispan - 1]);\n\t\t\t\tif (index < 0) {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t\tspans[ispan] = index;\n\t\t\t\tspans[ispan + 1] = index + sourceLength;\n\t\t\t}\n\t\t}\n\n\t\t// Update the ID\n\t\tif (destinations != null) {\n\t\t\tconst destinationsLength = destinations.length;\n\t\t\tlet id = \"\";\n\t\t\tfor (let i = 0, imax = sourcesLength; i < imax; ++i) {\n\t\t\t\tconst id0 = i < destinationsLength ? destinations[i] : sources[i];\n\t\t\t\tconst ispan = i << 1;\n\t\t\t\tconst s0 = spans[ispan + 1];\n\t\t\t\tconst s1 = spans[ispan + 2];\n\t\t\t\tconst id1 = target.substring(s0, i + 1 < imax ? s1 : targetLength);\n\t\t\t\tid += id0 + id1;\n\t\t\t}\n\t\t\tvalue.id = id;\n\t\t}\n\n\t\t// Update the initial value\n\t\tif (0 < initial.length) {\n\t\t\tvalue.initial = initial;\n\t\t}\n\t\treturn true;\n\t}\n\n\tprotected newSources(source?: string | null): string[] | null {\n\t\tif (source == null) {\n\t\t\treturn null;\n\t\t}\n\t\tconst trimmed = source.trim();\n\t\tif (trimmed.length <= 0) {\n\t\t\treturn null;\n\t\t}\n\t\treturn trimmed.toLowerCase().split(EShapeDataMapperImpl.WILDCARD);\n\t}\n\n\tpublic static split(target?: string | null): string[] | null {\n\t\tif (target == null) {\n\t\t\treturn null;\n\t\t}\n\t\tconst trimmed = target.trim();\n\t\tif (trimmed.length <= 0) {\n\t\t\treturn null;\n\t\t}\n\t\treturn trimmed.split(this.WILDCARD);\n\t}\n}\n"]}
|
package/dist/wcardinal-ui.cjs.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
Winter Cardinal UI v0.
|
|
2
|
+
Winter Cardinal UI v0.209.0
|
|
3
3
|
Copyright (C) 2019 Toshiba Corporation
|
|
4
4
|
SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
|
|
@@ -15528,14 +15528,14 @@ var EShapeDataMapperImpl = /** @class */ (function () {
|
|
|
15528
15528
|
EShapeDataMapperImpl.prototype.map = function (value, destinations, initial) {
|
|
15529
15529
|
var sources = this._sources;
|
|
15530
15530
|
if (sources == null) {
|
|
15531
|
-
return;
|
|
15531
|
+
return false;
|
|
15532
15532
|
}
|
|
15533
15533
|
var valueId = value.id;
|
|
15534
15534
|
var target = valueId.toLowerCase();
|
|
15535
15535
|
var first = sources[0];
|
|
15536
15536
|
var firstLength = first.length;
|
|
15537
15537
|
if (firstLength !== 0 && target.indexOf(first) !== 0) {
|
|
15538
|
-
return;
|
|
15538
|
+
return false;
|
|
15539
15539
|
}
|
|
15540
15540
|
var spans = EShapeDataMapperImpl.SPANS;
|
|
15541
15541
|
spans[0] = 0;
|
|
@@ -15553,7 +15553,7 @@ var EShapeDataMapperImpl = /** @class */ (function () {
|
|
|
15553
15553
|
else {
|
|
15554
15554
|
var index = target.indexOf(source, spans[ispan - 1]);
|
|
15555
15555
|
if (index < 0) {
|
|
15556
|
-
return;
|
|
15556
|
+
return false;
|
|
15557
15557
|
}
|
|
15558
15558
|
spans[ispan] = index;
|
|
15559
15559
|
spans[ispan + 1] = index + sourceLength;
|
|
@@ -15577,6 +15577,7 @@ var EShapeDataMapperImpl = /** @class */ (function () {
|
|
|
15577
15577
|
if (0 < initial.length) {
|
|
15578
15578
|
value.initial = initial;
|
|
15579
15579
|
}
|
|
15580
|
+
return true;
|
|
15580
15581
|
};
|
|
15581
15582
|
EShapeDataMapperImpl.prototype.newSources = function (source) {
|
|
15582
15583
|
if (source == null) {
|
package/dist/wcardinal-ui.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
Winter Cardinal UI v0.
|
|
2
|
+
Winter Cardinal UI v0.209.0
|
|
3
3
|
Copyright (C) 2019 Toshiba Corporation
|
|
4
4
|
SPDX-License-Identifier: Apache-2.0
|
|
5
5
|
|
|
@@ -15525,14 +15525,14 @@
|
|
|
15525
15525
|
EShapeDataMapperImpl.prototype.map = function (value, destinations, initial) {
|
|
15526
15526
|
var sources = this._sources;
|
|
15527
15527
|
if (sources == null) {
|
|
15528
|
-
return;
|
|
15528
|
+
return false;
|
|
15529
15529
|
}
|
|
15530
15530
|
var valueId = value.id;
|
|
15531
15531
|
var target = valueId.toLowerCase();
|
|
15532
15532
|
var first = sources[0];
|
|
15533
15533
|
var firstLength = first.length;
|
|
15534
15534
|
if (firstLength !== 0 && target.indexOf(first) !== 0) {
|
|
15535
|
-
return;
|
|
15535
|
+
return false;
|
|
15536
15536
|
}
|
|
15537
15537
|
var spans = EShapeDataMapperImpl.SPANS;
|
|
15538
15538
|
spans[0] = 0;
|
|
@@ -15550,7 +15550,7 @@
|
|
|
15550
15550
|
else {
|
|
15551
15551
|
var index = target.indexOf(source, spans[ispan - 1]);
|
|
15552
15552
|
if (index < 0) {
|
|
15553
|
-
return;
|
|
15553
|
+
return false;
|
|
15554
15554
|
}
|
|
15555
15555
|
spans[ispan] = index;
|
|
15556
15556
|
spans[ispan + 1] = index + sourceLength;
|
|
@@ -15574,6 +15574,7 @@
|
|
|
15574
15574
|
if (0 < initial.length) {
|
|
15575
15575
|
value.initial = initial;
|
|
15576
15576
|
}
|
|
15577
|
+
return true;
|
|
15577
15578
|
};
|
|
15578
15579
|
EShapeDataMapperImpl.prototype.newSources = function (source) {
|
|
15579
15580
|
if (source == null) {
|