mirror of
https://github.com/vbenjs/vue-vben-admin.git
synced 2025-08-26 00:26:20 +08:00
refactor: change the form button field from text to content to prevent conflicts with the frame (#4586)
* refactor: change the form button field from text to content to prevent conflicts with the frame
This commit is contained in:
@@ -16,16 +16,16 @@ const collapsed = defineModel({ default: false });
|
||||
|
||||
const resetButtonOptions = computed(() => {
|
||||
return {
|
||||
content: `${$t.value('reset')}`,
|
||||
show: true,
|
||||
text: `${$t.value('reset')}`,
|
||||
...unref(rootProps).resetButtonOptions,
|
||||
};
|
||||
});
|
||||
|
||||
const submitButtonOptions = computed(() => {
|
||||
return {
|
||||
content: `${$t.value('submit')}`,
|
||||
show: true,
|
||||
text: `${$t.value('submit')}`,
|
||||
...unref(rootProps).submitButtonOptions,
|
||||
};
|
||||
});
|
||||
@@ -91,7 +91,7 @@ watch(
|
||||
@click="handleReset"
|
||||
v-bind="resetButtonOptions"
|
||||
>
|
||||
{{ resetButtonOptions.text }}
|
||||
{{ resetButtonOptions.content }}
|
||||
</component>
|
||||
|
||||
<component
|
||||
@@ -101,7 +101,7 @@ watch(
|
||||
@click="handleSubmit"
|
||||
v-bind="submitButtonOptions"
|
||||
>
|
||||
{{ submitButtonOptions.text }}
|
||||
{{ submitButtonOptions.content }}
|
||||
</component>
|
||||
|
||||
<VbenExpandableArrow
|
||||
|
@@ -289,8 +289,8 @@ export interface FormRenderProps<
|
||||
}
|
||||
|
||||
export interface ActionButtonOptions extends VbenButtonProps {
|
||||
content?: string;
|
||||
show?: boolean;
|
||||
text?: string;
|
||||
}
|
||||
|
||||
export interface VbenFormProps<
|
||||
|
Reference in New Issue
Block a user