update styles

This commit is contained in:
AceDataCloud committed 2023-12-18 02:02:14 +08:00
1 parent f6b119f34f
commit 80abc61b80
17 files changed
+91 -24

No files matched your search

@@ -1,6 +1,6 @@
<template>
<div>
<h2 class="title">模型</h2>
<h2 class="title">{{ $t('midjourney.name.model') }}</h2>
<div class="items">
<div
v-for="(option, optionKey) in options"
@@ -41,12 +41,12 @@ export default defineComponent({
active: 0,
options: [
{
value: 'MJ',
value: '',
label: '通用',
image: 'https://cdn.zhishuyun.com/2023-10-06-174633.png'
},
{
value: 'NIJI',
value: 'niji',
label: '动漫',
image: 'https://cdn.zhishuyun.com/2023-10-06-174008.png'
}
@@ -1,6 +1,6 @@
<template>
<div class="field">
<h2 class="title">画质</h2>
<h2 class="title">{{ $t('midjourney.name.quality') }}</h2>
<el-radio-group v-model="value">
<el-radio-button v-for="item in options" :key="item.value" :label="item.value">
{{ item.label }}
@@ -1,6 +1,6 @@
<template>
<div>
<h2 class="title">图片比例</h2>
<h2 class="title">{{ $t('midjourney.name.ratio') }}</h2>
<div class="items">
<div
v-for="(option, optionKey) in options"
@@ -39,7 +39,6 @@ export default defineComponent({
data() {
return {
value: this.modelValue,
active: 0,
options: [
{
value: '1:1',
@@ -74,6 +73,11 @@ export default defineComponent({
]
};
},
computed: {
active() {
return this.options.findIndex((option) => option.value === this.value);
}
},
watch: {
modelValue(val) {
if (val !== this.value) {
@@ -85,8 +89,10 @@ export default defineComponent({
}
},
mounted() {
if (!this.value) {
if (!this.modelValue) {
this.value = DEFAULT_RATIO;
} else {
this.value = this.modelValue;
}
this.$emit('update:modelValue', this.value);
}
@@ -1,6 +1,6 @@
<template>
<div class="field">
<h2 class="title">版本</h2>
<h2 class="title">{{ $t('midjourney.name.version') }}</h2>
<el-select v-model="value" class="value" placeholder="Select">
<el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value" />
</el-select>