@schukai/monster 3.51.1 → 3.51.2
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/package.json
CHANGED
@@ -64,8 +64,12 @@ function initOptionsFromAttributes(element, options, mapping = {}, prefix = "dat
|
|
64
64
|
value = mapping[optionName](value);
|
65
65
|
}
|
66
66
|
|
67
|
-
const
|
68
|
-
|
67
|
+
const optionValue = finder.getVia(optionName);
|
68
|
+
|
69
|
+
const typeOfOptionValue = typeof optionValue;
|
70
|
+
if (optionValue === null || optionValue === undefined) {
|
71
|
+
value = null;
|
72
|
+
} else if (typeOfOptionValue === "boolean") {
|
69
73
|
value = value === "true";
|
70
74
|
} else if (typeOfOptionValue === "number") {
|
71
75
|
value = Number(value);
|
package/source/types/version.mjs
CHANGED
package/test/cases/monster.mjs
CHANGED