@gct-paas/word 0.2.31-beta.2 → 0.2.32-beta.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/index.es.js +11 -10
- package/dist/runtime/interface/computed.d.ts +2 -1
- package/dist/word.css +6 -6
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! @gct-paas/word v0.2.
|
|
1
|
+
/*! @gct-paas/word v0.2.32-beta.0 */
|
|
2
2
|
import { Fragment, Suspense, Teleport, Transition, TransitionGroup, cloneVNode, computed, createApp, createBlock, createCommentVNode, createElementBlock, createElementVNode, createSlots, createStaticVNode, createTextVNode, createVNode, defineAsyncComponent, defineComponent, getCurrentInstance, getCurrentScope, guardReactiveProps, h, inject, isRef, isVNode, markRaw, mergeModels, mergeProps, nextTick, normalizeClass, normalizeProps, normalizeStyle, onBeforeMount, onBeforeUnmount, onMounted, onScopeDispose, onUnmounted, openBlock, provide, reactive, readonly, ref, render, renderList, renderSlot, resolveComponent, resolveDynamicComponent, shallowReactive, shallowRef, toDisplayString, toHandlers, toRaw, toRef, toValue, unref, useAttrs, useCssVars, useModel, useSlots, vModelRadio, vModelSelect, vModelText, vShow, watch, watchEffect, withCtx, withDirectives, withKeys, withModifiers } from "vue";
|
|
3
3
|
import fa, { PopperWrapper } from "floating-vue";
|
|
4
4
|
import VueKonva from "vue-konva";
|
|
@@ -119009,7 +119009,7 @@ function applyAutofillRules(record, autofillRules, opts) {
|
|
|
119009
119009
|
const normalizedRule = normalizeAutofillRule(ruleItem, opts);
|
|
119010
119010
|
const templatePath = buildAutofillTargetTemplatePath(normalizedRule);
|
|
119011
119011
|
if (!templatePath) continue;
|
|
119012
|
-
const value = resolveAutofillSourceValue(record, fromField);
|
|
119012
|
+
const value = resolveAutofillSourceValue(record, fromField) ?? null;
|
|
119013
119013
|
for (const runtimeValuePath of resolveAutofillRuntimeValuePaths(templatePath, normalizedRule, opts)) result[runtimeValuePath] = value;
|
|
119014
119014
|
}
|
|
119015
119015
|
return result;
|
|
@@ -119306,12 +119306,13 @@ async function loadDefaultValueByAutofillRules(instances, autofillRules, field,
|
|
|
119306
119306
|
});
|
|
119307
119307
|
}
|
|
119308
119308
|
/** 选择值-数据填充 */
|
|
119309
|
-
function loadDataValuesByAutofillRules(record, autofillRules, sourceValuePath, autofillEnabled, doc) {
|
|
119310
|
-
|
|
119309
|
+
function loadDataValuesByAutofillRules(record, autofillRules, sourceValuePath, autofillEnabled, doc, sourceUpdates) {
|
|
119310
|
+
const sourceCleared = sourceUpdates != null && Object.prototype.hasOwnProperty.call(sourceUpdates, sourceValuePath) && isEmptyValue$1(sourceUpdates[sourceValuePath]);
|
|
119311
|
+
if (!record && !sourceCleared || !resolveAutofillEnabled({
|
|
119311
119312
|
autofillEnabled,
|
|
119312
119313
|
autofillRules
|
|
119313
119314
|
})) return {};
|
|
119314
|
-
return applyAutofillRules(
|
|
119315
|
+
return applyAutofillRules(sourceCleared ? {} : record, autofillRules ?? [], {
|
|
119315
119316
|
needReplacePathIndexPlaceholder: true,
|
|
119316
119317
|
sourceValuePath,
|
|
119317
119318
|
rawData: (doc === null || doc === void 0 ? void 0 : doc.dataManager.getRawData()) ?? {},
|
|
@@ -169525,7 +169526,7 @@ var init_overlay_render_vue_vue_type_script_setup_true_lang = __esmMin((() => {
|
|
|
169525
169526
|
}
|
|
169526
169527
|
async function onChange(data, record) {
|
|
169527
169528
|
var _widgetProps$value2, _widgetProps$value3, _props$widget$widgetM, _props$widget$dataSlo, _fieldMeta$value6, _fieldMeta$value7, _fieldMeta$value8, _fieldMeta$value9, _fieldMeta$value12, _fieldMeta$value13;
|
|
169528
|
-
const dataValues = loadDataValuesByAutofillRules(record, (_widgetProps$value2 = widgetProps.value) === null || _widgetProps$value2 === void 0 ? void 0 : _widgetProps$value2.autofillRules, runtimeValuePath.value, (_widgetProps$value3 = widgetProps.value) === null || _widgetProps$value3 === void 0 ? void 0 : _widgetProps$value3.autofillEnabled, props.doc);
|
|
169529
|
+
const dataValues = loadDataValuesByAutofillRules(record, (_widgetProps$value2 = widgetProps.value) === null || _widgetProps$value2 === void 0 ? void 0 : _widgetProps$value2.autofillRules, runtimeValuePath.value, (_widgetProps$value3 = widgetProps.value) === null || _widgetProps$value3 === void 0 ? void 0 : _widgetProps$value3.autofillEnabled, props.doc, data);
|
|
169529
169530
|
const subFieldValuePath = (_props$widget$widgetM = props.widget.widgetMeta) === null || _props$widget$widgetM === void 0 || (_props$widget$widgetM = _props$widget$widgetM.field) === null || _props$widget$widgetM === void 0 ? void 0 : _props$widget$widgetM.valuePath;
|
|
169530
169531
|
const dataIndex = (_props$widget$dataSlo = props.widget.dataSlotIndex) === null || _props$widget$dataSlo === void 0 ? void 0 : _props$widget$dataSlo.dataIndex;
|
|
169531
169532
|
const tableRuntime = new TableRuntime(props.doc);
|
|
@@ -169738,8 +169739,8 @@ var init_overlay_render_vue_vue_type_script_setup_true_lang = __esmMin((() => {
|
|
|
169738
169739
|
//#region src/runtime/canvas/__common__/widget-container/overlay-render.vue?vue&type=style&index=0&lang.less
|
|
169739
169740
|
var init_overlay_render_vue_vue_type_style_index_0_lang = __esmMin((() => {}));
|
|
169740
169741
|
//#endregion
|
|
169741
|
-
//#region src/runtime/canvas/__common__/widget-container/overlay-render.vue?vue&type=style&index=1&scoped=
|
|
169742
|
-
var
|
|
169742
|
+
//#region src/runtime/canvas/__common__/widget-container/overlay-render.vue?vue&type=style&index=1&scoped=b206a36a&lang.less
|
|
169743
|
+
var init_overlay_render_vue_vue_type_style_index_1_scoped_b206a36a_lang = __esmMin((() => {}));
|
|
169743
169744
|
//#endregion
|
|
169744
169745
|
//#region src/runtime/canvas/__common__/widget-container/overlay-render.vue
|
|
169745
169746
|
var overlay_render_default;
|
|
@@ -169747,9 +169748,9 @@ var init_overlay_render = __esmMin((() => {
|
|
|
169747
169748
|
init_overlay_render_vue_vue_type_script_setup_true_lang();
|
|
169748
169749
|
init_overlay_render_vue_vue_type_script_setup_true_lang();
|
|
169749
169750
|
init_overlay_render_vue_vue_type_style_index_0_lang();
|
|
169750
|
-
|
|
169751
|
+
init_overlay_render_vue_vue_type_style_index_1_scoped_b206a36a_lang();
|
|
169751
169752
|
init__plugin_vue_export_helper();
|
|
169752
|
-
overlay_render_default = /*#__PURE__*/ _plugin_vue_export_helper_default(overlay_render_vue_vue_type_script_setup_true_lang_default, [["__scopeId", "data-v-
|
|
169753
|
+
overlay_render_default = /*#__PURE__*/ _plugin_vue_export_helper_default(overlay_render_vue_vue_type_script_setup_true_lang_default, [["__scopeId", "data-v-b206a36a"]]);
|
|
169753
169754
|
}));
|
|
169754
169755
|
//#endregion
|
|
169755
169756
|
//#region src/utils/composables/useHoverDelay.ts
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { FIELD_TYPE } from '../../domain/field/field-type';
|
|
2
|
+
import { AutofillRule } from '../../suites/shared/panel/config/editor/ref-autofill-editor/types';
|
|
2
3
|
import { Doc } from '../../core';
|
|
3
4
|
import { ComputedRule, FieldComputedConfig } from '../../domain/field/field-props-schema-type';
|
|
4
5
|
import { FieldDataBindingMeta } from '../../core/widget';
|
|
@@ -38,4 +39,4 @@ export declare function fetchAutofillSource(field: FieldDataBindingMeta, context
|
|
|
38
39
|
/** 默认值-数据填充 */
|
|
39
40
|
export declare function loadDefaultValueByAutofillRules(instances: any[], autofillRules: any[], field: FieldDataBindingMeta, context: Record<string, unknown>, autofillEnabled?: boolean, rawData?: Record<string, unknown>): Promise<Record<string, unknown>>;
|
|
40
41
|
/** 选择值-数据填充 */
|
|
41
|
-
export declare function loadDataValuesByAutofillRules(record: Record<string, unknown> | null | undefined, autofillRules:
|
|
42
|
+
export declare function loadDataValuesByAutofillRules(record: Record<string, unknown> | null | undefined, autofillRules: AutofillRule[] | undefined, sourceValuePath: string, autofillEnabled?: boolean, doc?: Doc, sourceUpdates?: Record<string, unknown>): Record<string, unknown>;
|
package/dist/word.css
CHANGED
|
@@ -10128,7 +10128,7 @@ to {
|
|
|
10128
10128
|
/**
|
|
10129
10129
|
* 字段态配色 —— DOM 控件子集(input / select / overlay)
|
|
10130
10130
|
*/
|
|
10131
|
-
.widget-container-action[data-v-
|
|
10131
|
+
.widget-container-action[data-v-b206a36a] {
|
|
10132
10132
|
position: absolute;
|
|
10133
10133
|
inset: 0;
|
|
10134
10134
|
z-index: 999;
|
|
@@ -10136,7 +10136,7 @@ to {
|
|
|
10136
10136
|
height: 0;
|
|
10137
10137
|
pointer-events: all;
|
|
10138
10138
|
}
|
|
10139
|
-
.picker-trigger[data-v-
|
|
10139
|
+
.picker-trigger[data-v-b206a36a] {
|
|
10140
10140
|
display: flex;
|
|
10141
10141
|
box-sizing: border-box;
|
|
10142
10142
|
align-items: center;
|
|
@@ -10148,19 +10148,19 @@ to {
|
|
|
10148
10148
|
outline: none;
|
|
10149
10149
|
background-color: #fff;
|
|
10150
10150
|
}
|
|
10151
|
-
.picker-trigger.disabled[data-v-
|
|
10151
|
+
.picker-trigger.disabled[data-v-b206a36a] {
|
|
10152
10152
|
border: 1px solid rgba(13, 13, 13, 0.12);
|
|
10153
10153
|
cursor: not-allowed;
|
|
10154
10154
|
}
|
|
10155
|
-
.picker-trigger.disabled .gct-icon[data-v-
|
|
10155
|
+
.picker-trigger.disabled .gct-icon[data-v-b206a36a] {
|
|
10156
10156
|
color: rgba(0, 0, 0, 0.25);
|
|
10157
10157
|
}
|
|
10158
|
-
.picker-trigger.readonly[data-v-
|
|
10158
|
+
.picker-trigger.readonly[data-v-b206a36a] {
|
|
10159
10159
|
border-color: #d9d9d9;
|
|
10160
10160
|
background-color: #f5f6f8;
|
|
10161
10161
|
cursor: default;
|
|
10162
10162
|
}
|
|
10163
|
-
.picker-trigger.readonly .gct-icon[data-v-
|
|
10163
|
+
.picker-trigger.readonly .gct-icon[data-v-b206a36a] {
|
|
10164
10164
|
color: rgba(0, 0, 0, 0.65);
|
|
10165
10165
|
}
|
|
10166
10166
|
.resize-box[data-v-788ab62c] {
|