@ni/spright-components 6.0.1 → 6.0.3
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.
|
@@ -11489,6 +11489,9 @@
|
|
|
11489
11489
|
validate() {
|
|
11490
11490
|
super.validate(this.control);
|
|
11491
11491
|
}
|
|
11492
|
+
limitPrecision(value) {
|
|
11493
|
+
return parseFloat(value.toPrecision(15));
|
|
11494
|
+
}
|
|
11492
11495
|
/**
|
|
11493
11496
|
* Sets the internal value to a valid number between the min and max properties
|
|
11494
11497
|
* @param value - user input
|
|
@@ -11496,16 +11499,17 @@
|
|
|
11496
11499
|
* @internal
|
|
11497
11500
|
*/
|
|
11498
11501
|
getValidValue(value) {
|
|
11499
|
-
|
|
11500
|
-
let validValue = parseFloat(parseFloat(value).toPrecision(15));
|
|
11502
|
+
let validValue = this.limitPrecision(parseFloat(value));
|
|
11501
11503
|
if (isNaN(validValue)) {
|
|
11502
|
-
|
|
11504
|
+
return "";
|
|
11503
11505
|
}
|
|
11504
|
-
|
|
11505
|
-
validValue = Math.min(validValue, (
|
|
11506
|
-
validValue = Math.max(validValue, (_b = this.min) !== null && _b !== void 0 ? _b : validValue).toString();
|
|
11506
|
+
if (this.max !== undefined) {
|
|
11507
|
+
validValue = Math.min(validValue, this.limitPrecision(this.max));
|
|
11507
11508
|
}
|
|
11508
|
-
|
|
11509
|
+
if (this.min !== undefined) {
|
|
11510
|
+
validValue = Math.max(validValue, this.limitPrecision(this.min));
|
|
11511
|
+
}
|
|
11512
|
+
return validValue.toString();
|
|
11509
11513
|
}
|
|
11510
11514
|
/**
|
|
11511
11515
|
* Increments the value using the step value
|
|
@@ -15887,7 +15891,7 @@
|
|
|
15887
15891
|
const Pass100LightUi = "#009921";
|
|
15888
15892
|
const Pass100DarkUi = "#00c12b";
|
|
15889
15893
|
const Fail100LightUi = "#c4000c";
|
|
15890
|
-
const Fail100DarkUi = "#
|
|
15894
|
+
const Fail100DarkUi = "#ff4663";
|
|
15891
15895
|
const Black75 = "#818386";
|
|
15892
15896
|
const Black15 = "#f1f1f2";
|
|
15893
15897
|
const Black7 = "#f5f5f5";
|
|
@@ -28015,9 +28019,11 @@ so this becomes the fallback color for the slot */ ''}
|
|
|
28015
28019
|
function insertInto(content, dist, insert, parent) {
|
|
28016
28020
|
let { index, offset } = content.findIndex(dist), child = content.maybeChild(index);
|
|
28017
28021
|
if (offset == dist || child.isText) {
|
|
28022
|
+
if (parent && !parent.canReplace(index, index, insert))
|
|
28023
|
+
return null;
|
|
28018
28024
|
return content.cut(0, dist).append(insert).append(content.cut(dist));
|
|
28019
28025
|
}
|
|
28020
|
-
let inner = insertInto(child.content, dist - offset - 1, insert);
|
|
28026
|
+
let inner = insertInto(child.content, dist - offset - 1, insert, child);
|
|
28021
28027
|
return inner && content.replaceChild(index, child.copy(inner));
|
|
28022
28028
|
}
|
|
28023
28029
|
function replace$1($from, $to, slice) {
|