@schukai/monster 3.98.3 → 3.99.1
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/CHANGELOG.md +22 -0
- package/package.json +1 -1
- package/source/components/datatable/datatable.mjs +1159 -1139
- package/source/components/form/action-button.mjs +2 -1
- package/source/components/form/api-button.mjs +4 -4
- package/source/components/form/button-bar.mjs +2 -3
- package/source/components/form/button.mjs +1 -0
- package/source/components/form/context-error.mjs +1 -0
- package/source/components/form/field-set.mjs +1 -0
- package/source/components/form/popper-button.mjs +274 -273
- package/source/components/form/reload.mjs +1 -0
- package/source/components/form/toggle-switch.mjs +2 -2
- package/source/components/notify/monitor-attribute-errors.mjs +5 -1
- package/source/dom/customelement.mjs +944 -945
- package/source/dom/error.mjs +106 -0
- package/source/types/version.mjs +1 -1
- package/test/cases/dom/customcontrol.mjs +1 -1
- package/test/cases/dom/customelement.mjs +3 -3
- package/test/cases/monster.mjs +1 -1
- package/test/web/test.html +2 -2
- package/test/web/tests.js +87 -24
@@ -31,6 +31,7 @@ import {
|
|
31
31
|
ATTRIBUTE_ERRORMESSAGE,
|
32
32
|
ATTRIBUTE_ROLE,
|
33
33
|
} from "../../dom/constants.mjs";
|
34
|
+
import {addErrorAttribute} from "../../dom/error.mjs";
|
34
35
|
|
35
36
|
export { ActionButton };
|
36
37
|
|
@@ -163,7 +164,7 @@ function initEventHandler() {
|
|
163
164
|
try {
|
164
165
|
updateButtonsI18n.call(this);
|
165
166
|
} catch (e) {
|
166
|
-
|
167
|
+
addErrorAttribute(this, e.message);
|
167
168
|
}
|
168
169
|
|
169
170
|
memButtons = JSON.stringify(this.getOption("buttons"));
|
@@ -35,7 +35,7 @@ import { ApiButtonStyleSheet } from "./stylesheet/api-button.mjs";
|
|
35
35
|
import { isObject, isFunction } from "../../types/is.mjs";
|
36
36
|
import { getGlobal } from "../../types/global.mjs";
|
37
37
|
import { Formatter } from "../../text/formatter.mjs";
|
38
|
-
|
38
|
+
import {addErrorAttribute} from "../../dom/error.mjs";
|
39
39
|
export { ApiButton };
|
40
40
|
|
41
41
|
/**
|
@@ -189,12 +189,12 @@ class ApiButton extends ActionButton {
|
|
189
189
|
let flag = false;
|
190
190
|
let apiEqualUrl = false;
|
191
191
|
if (labelTemplate === "") {
|
192
|
-
|
192
|
+
addErrorAttribute(this, "empty label template");
|
193
193
|
flag = true;
|
194
194
|
}
|
195
195
|
|
196
196
|
if (apiTemplate === "") {
|
197
|
-
|
197
|
+
addErrorAttribute(this, "empty api template");
|
198
198
|
flag = true;
|
199
199
|
}
|
200
200
|
|
@@ -242,7 +242,7 @@ class ApiButton extends ActionButton {
|
|
242
242
|
try {
|
243
243
|
this.updateI18n();
|
244
244
|
} catch (e) {
|
245
|
-
|
245
|
+
addErrorAttribute(this, e.message);
|
246
246
|
}
|
247
247
|
|
248
248
|
this.setOption("buttons", buttons);
|
@@ -41,7 +41,7 @@ import { STYLE_DISPLAY_MODE_BLOCK } from "./constants.mjs";
|
|
41
41
|
import { ButtonBarStyleSheet } from "./stylesheet/button-bar.mjs";
|
42
42
|
import { positionPopper } from "./util/floating-ui.mjs";
|
43
43
|
import { convertToPixels } from "../../dom/dimension.mjs";
|
44
|
-
|
44
|
+
import {addErrorAttribute} from "../../dom/error.mjs";
|
45
45
|
export { ButtonBar };
|
46
46
|
|
47
47
|
/**
|
@@ -358,9 +358,8 @@ function initEventHandler() {
|
|
358
358
|
try {
|
359
359
|
checkAndRearrangeButtons.call(self);
|
360
360
|
} catch (error) {
|
361
|
-
|
361
|
+
addErrorAttribute(
|
362
362
|
this,
|
363
|
-
ATTRIBUTE_ERRORMESSAGE,
|
364
363
|
error?.message || "An error occurred while rearranging the buttons",
|
365
364
|
);
|
366
365
|
}
|
@@ -30,6 +30,7 @@ import { ATTRIBUTE_BUTTON_CLASS } from "./constants.mjs";
|
|
30
30
|
import { ButtonStyleSheet } from "./stylesheet/button.mjs";
|
31
31
|
import { RippleStyleSheet } from "../stylesheet/ripple.mjs";
|
32
32
|
import { fireCustomEvent } from "../../dom/events.mjs";
|
33
|
+
import {addErrorAttribute} from "../../dom/error.mjs";
|
33
34
|
|
34
35
|
export { Button };
|
35
36
|
|
@@ -29,6 +29,7 @@ import { FieldSetStyleSheet } from "./stylesheet/field-set.mjs";
|
|
29
29
|
import "../layout/collapse.mjs";
|
30
30
|
import "./toggle-switch.mjs";
|
31
31
|
import { getLocaleOfDocument } from "../../dom/locale.mjs";
|
32
|
+
import {addErrorAttribute} from "../../dom/error.mjs";
|
32
33
|
|
33
34
|
export { FieldSet };
|
34
35
|
|