@kubohiroya/turbowarp-extension-data-editor 0.8.1 → 0.9.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/README.ja.md +1 -0
- package/README.md +1 -0
- package/dist/build-info.json +3 -3
- package/dist/fixed-input-view.js +12 -1
- package/dist/form-presentation.d.ts +1 -1
- package/dist/form-presentation.js +2 -0
- package/dist/react.js +3 -0
- package/dist/session.d.ts +5 -0
- package/dist/session.js +17 -0
- package/dist/types.d.ts +5 -0
- package/dist/view.js +4 -0
- package/dist/webpack4/index.js +1 -1
- package/dist/webpack4/metafile.json +21 -21
- package/dist/webpack4/react.js +1 -0
- package/dist/webpack4/react.js.map +2 -2
- package/dist/webpack4/rjsf.js +14 -2
- package/dist/webpack4/rjsf.js.map +3 -3
- package/dist/webpack4/{shared-FW4MRLXW.js → shared-S623S2PV.js} +21 -1
- package/dist/webpack4/shared-S623S2PV.js.map +7 -0
- package/dist/webpack4/turbowarp.js +1 -1
- package/docs/fixed-input-contracts.md +1 -1
- package/package.json +4 -2
- package/dist/webpack4/shared-FW4MRLXW.js.map +0 -7
package/dist/webpack4/rjsf.js
CHANGED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
EditorRegistry,
|
|
3
3
|
cloneJson,
|
|
4
4
|
createFixedInputEditor
|
|
5
|
-
} from "./shared-
|
|
5
|
+
} from "./shared-S623S2PV.js";
|
|
6
6
|
import {
|
|
7
7
|
EDITOR_API_VERSION
|
|
8
8
|
} from "./shared-BKTRZUZH.js";
|
|
@@ -5066,9 +5066,11 @@ var formStyles = `
|
|
|
5066
5066
|
[data-editor-form] .editor-form-section>legend,[data-editor-form] .rjsf fieldset>legend{font-size:15px;font-weight:650;padding:0;margin:0 0 10px;color:inherit}
|
|
5067
5067
|
[data-editor-form] .editor-form-field,[data-editor-form] .rjsf .form-group{margin:0 0 14px;min-width:0}
|
|
5068
5068
|
[data-editor-form] .editor-form-field>label,[data-editor-form] .rjsf .control-label{display:block;font-size:13px;font-weight:600;margin:0 0 6px;color:inherit}
|
|
5069
|
+
[data-editor-form] [data-block-editor-pair-row] label,[data-editor-form] .rjsf [data-block-editor-pair-row] .control-label{margin-bottom:0}
|
|
5069
5070
|
[data-editor-form] .required{color:var(--editor-accent);margin-left:3px}
|
|
5070
5071
|
[data-editor-form] input:not([type=checkbox]):not([type=radio]),[data-editor-form] select,[data-editor-form] textarea{display:block;width:100%;min-height:38px;margin:0;padding:8px 11px;border:1px solid var(--editor-line);border-radius:7px;background:var(--block-editor-input,white);color:inherit;font:inherit;box-shadow:0 1px 2px #172b4d05}
|
|
5071
5072
|
[data-editor-form] textarea{min-height:76px;resize:vertical}
|
|
5073
|
+
[data-editor-form] input:not([type=checkbox]):not([type=radio])[data-block-editor-invalid="true"],[data-editor-form] select[data-block-editor-invalid="true"],[data-editor-form] textarea[data-block-editor-invalid="true"]{border-color:var(--block-editor-error-border,#c62828);box-shadow:0 0 0 1px var(--block-editor-error-border,#c62828);background:linear-gradient(var(--block-editor-error-tint,rgba(198,40,40,0.08)),var(--block-editor-error-tint,rgba(198,40,40,0.08))),var(--block-editor-input,white)}
|
|
5072
5074
|
[data-editor-form] input:focus-visible,[data-editor-form] select:focus-visible,[data-editor-form] textarea:focus-visible,[data-editor-form] button:focus-visible,[data-editor-form] summary:focus-visible{outline:2px solid var(--editor-accent);outline-offset:2px}
|
|
5073
5075
|
[data-editor-form] input[readonly]{background:var(--block-editor-subtle,var(--block-editor-background,#f5f7fb));color:var(--editor-muted)}
|
|
5074
5076
|
[data-editor-form] input[type=checkbox]{width:17px;height:17px;margin:0;accent-color:var(--editor-accent)}
|
|
@@ -13034,6 +13036,16 @@ function describe(context) {
|
|
|
13034
13036
|
throw new TypeError("A fixed form requires a fixed session.");
|
|
13035
13037
|
return result;
|
|
13036
13038
|
}
|
|
13039
|
+
function liveIssues2(context) {
|
|
13040
|
+
var _a;
|
|
13041
|
+
const issues = [...describe(context).issues];
|
|
13042
|
+
const checked = typeof context.checkFixedInput === "function" ? (_a = context.checkFixedInput()) !== null && _a !== void 0 ? _a : [] : [];
|
|
13043
|
+
for (const issue2 of checked) {
|
|
13044
|
+
if (!issues.some((item) => item.message === issue2.message && item.path === issue2.path))
|
|
13045
|
+
issues.push(issue2);
|
|
13046
|
+
}
|
|
13047
|
+
return issues;
|
|
13048
|
+
}
|
|
13037
13049
|
var nextFixedViewId = 0;
|
|
13038
13050
|
function FixedInputView({ context, messages }) {
|
|
13039
13051
|
const [, redraw] = React4.useState(0);
|
|
@@ -13068,7 +13080,7 @@ function FixedInputView({ context, messages }) {
|
|
|
13068
13080
|
entry.repair = true;
|
|
13069
13081
|
Object.defineProperty(next.inputs, argument, { value: entry, enumerable: true, configurable: true, writable: true });
|
|
13070
13082
|
context.setDraft(next);
|
|
13071
|
-
context.setValidationIssues(
|
|
13083
|
+
context.setValidationIssues(liveIssues2(context));
|
|
13072
13084
|
};
|
|
13073
13085
|
const hasInactiveEdits = Object.entries(description.inputs).some(([argument, input]) => input.state === "hidden" && record4(inputs[argument]) && inputs[argument].changed === true);
|
|
13074
13086
|
return React4.createElement(
|