update prompt
This commit is contained in:
1 parent
e4bd995e6c
commit
80bafd4c8d
20 files changed
+231
-33
No files matched your search
@@ -1,20 +1,22 @@
|
||||
<template>
|
||||
<div class="field">
|
||||
<h2 class="title">高级模式</h2>
|
||||
<el-switch v-model="value" class="ml-2" />
|
||||
<h2 class="title">{{ $t('midjourney.name.advanced') }}</h2>
|
||||
<el-switch v-model="value" class="value" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { defineComponent } from 'vue';
|
||||
import { ElSwitch } from 'element-plus';
|
||||
import InfoIcon from '@/components/common/InfoIcon.vue';
|
||||
|
||||
const DEFAULT_ADVANCED = false;
|
||||
|
||||
export default defineComponent({
|
||||
name: 'AdvancedSelector',
|
||||
components: {
|
||||
ElSwitch
|
||||
ElSwitch,
|
||||
InfoIcon
|
||||
},
|
||||
props: {
|
||||
modelValue: {
|
||||
@@ -61,5 +63,8 @@ export default defineComponent({
|
||||
.value {
|
||||
flex: 1;
|
||||
}
|
||||
.info {
|
||||
width: 20px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -1,19 +1,23 @@
|
||||
<template>
|
||||
<div class="field">
|
||||
<h2 class="title">变异度</h2>
|
||||
<h2 class="title">{{ $t('midjourney.name.chaos') }}</h2>
|
||||
<el-slider v-model="value" :min="0" :max="100" :step="1" class="value" />
|
||||
<info-icon :content="$t('midjourney.description.chaos')" class="info" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { defineComponent } from 'vue';
|
||||
import { ElSlider } from 'element-plus';
|
||||
import InfoIcon from '@/components/common/InfoIcon.vue';
|
||||
|
||||
const DEFAULT_CHAOS = 0;
|
||||
|
||||
export default defineComponent({
|
||||
name: 'ChaosSelector',
|
||||
components: {
|
||||
ElSlider
|
||||
ElSlider,
|
||||
InfoIcon
|
||||
},
|
||||
props: {
|
||||
modelValue: {
|
||||
|
||||
@@ -1,19 +1,23 @@
|
||||
<template>
|
||||
<div class="field">
|
||||
<h2 class="title">图片权重</h2>
|
||||
<h2 class="title">{{ $t('midjourney.name.imageWeight') }}</h2>
|
||||
<el-slider v-model="value" :min="0" :max="2" :step="0.1" class="value" />
|
||||
<info-icon :content="$t('midjourney.description.imageWeight')" class="info" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { defineComponent } from 'vue';
|
||||
import { ElSlider } from 'element-plus';
|
||||
import InfoIcon from '@/components/common/InfoIcon.vue';
|
||||
|
||||
const DEFAULT_IW = 1;
|
||||
|
||||
export default defineComponent({
|
||||
name: 'ImageWeightSelector',
|
||||
components: {
|
||||
ElSlider
|
||||
ElSlider,
|
||||
InfoIcon
|
||||
},
|
||||
props: {
|
||||
modelValue: {
|
||||
|
||||
@@ -0,0 +1,68 @@
|
||||
<template>
|
||||
<div class="field">
|
||||
<h2 class="title">{{ $t('midjourney.name.niji') }}</h2>
|
||||
<el-switch v-model="value" class="value" />
|
||||
<info-icon :content="$t('midjourney.description.niji')" class="info" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { defineComponent } from 'vue';
|
||||
import { ElSwitch } from 'element-plus';
|
||||
import InfoIcon from '@/components/common/InfoIcon.vue';
|
||||
|
||||
const DEFAULT_NIJI = false;
|
||||
|
||||
export default defineComponent({
|
||||
name: 'RawSelector',
|
||||
components: {
|
||||
ElSwitch,
|
||||
InfoIcon
|
||||
},
|
||||
props: {
|
||||
modelValue: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
}
|
||||
},
|
||||
emits: ['update:modelValue'],
|
||||
data() {
|
||||
return {
|
||||
value: this.modelValue
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
modelValue(val) {
|
||||
if (val !== this.value) {
|
||||
this.value = val;
|
||||
}
|
||||
},
|
||||
value(val) {
|
||||
this.$emit('update:modelValue', val);
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
if (this.value === undefined) {
|
||||
this.value = DEFAULT_NIJI;
|
||||
}
|
||||
this.$emit('update:modelValue', this.value);
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.field {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
|
||||
.title {
|
||||
font-size: 14px;
|
||||
margin-bottom: 0;
|
||||
width: 30%;
|
||||
}
|
||||
.value {
|
||||
flex: 1;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -1,19 +1,23 @@
|
||||
<template>
|
||||
<div class="field">
|
||||
<h2 class="title">艺术化</h2>
|
||||
<h2 class="title">{{ $t('midjourney.name.stylize') }}</h2>
|
||||
<el-slider v-model="value" :min="0" :max="1000" :step="1" class="value" />
|
||||
<info-icon :content="$t('midjourney.description.stylize')" class="info" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { defineComponent } from 'vue';
|
||||
import { ElSlider } from 'element-plus';
|
||||
import InfoIcon from '@/components/common/InfoIcon.vue';
|
||||
|
||||
const DEFAULT_STYLIZE = 100;
|
||||
|
||||
export default defineComponent({
|
||||
name: 'StylizeSelector',
|
||||
components: {
|
||||
ElSlider
|
||||
ElSlider,
|
||||
InfoIcon
|
||||
},
|
||||
props: {
|
||||
modelValue: {
|
||||
|
||||
@@ -1,25 +1,28 @@
|
||||
<template>
|
||||
<div class="field">
|
||||
<h2 class="title">自动翻译</h2>
|
||||
<el-switch v-model="value" class="ml-2" />
|
||||
<h2 class="title">{{ $t('midjourney.name.translation') }}</h2>
|
||||
<el-switch v-model="value" class="value" />
|
||||
<info-icon :content="$t('midjourney.description.translation')" class="info" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { defineComponent } from 'vue';
|
||||
import { ElSwitch } from 'element-plus';
|
||||
import InfoIcon from '@/components/common/InfoIcon.vue';
|
||||
|
||||
const DEFAULT_ADVANCED = false;
|
||||
const DEFAULT_TRANSLATION = true;
|
||||
|
||||
export default defineComponent({
|
||||
name: 'TranslationSelector',
|
||||
components: {
|
||||
ElSwitch
|
||||
ElSwitch,
|
||||
InfoIcon
|
||||
},
|
||||
props: {
|
||||
modelValue: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
default: DEFAULT_TRANSLATION
|
||||
}
|
||||
},
|
||||
emits: ['update:modelValue'],
|
||||
@@ -40,7 +43,7 @@ export default defineComponent({
|
||||
},
|
||||
mounted() {
|
||||
if (this.value === undefined) {
|
||||
this.value = DEFAULT_ADVANCED;
|
||||
this.value = DEFAULT_TRANSLATION;
|
||||
}
|
||||
this.$emit('update:modelValue', this.value);
|
||||
}
|
||||
|
||||
+9
-5
@@ -1,19 +1,23 @@
|
||||
<template>
|
||||
<div class="field">
|
||||
<h2 class="title">怪异度</h2>
|
||||
<h2 class="title">{{ $t('midjourney.name.weird') }}</h2>
|
||||
<el-slider v-model="value" :min="0" :max="1000" :step="1" class="value" />
|
||||
<info-icon :content="$t('midjourney.description.weird')" class="info" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { defineComponent } from 'vue';
|
||||
import { ElSlider } from 'element-plus';
|
||||
const DEFAULT_WIRED = 0;
|
||||
import InfoIcon from '@/components/common/InfoIcon.vue';
|
||||
|
||||
const DEFAULT_WEIRD = 0;
|
||||
|
||||
export default defineComponent({
|
||||
name: 'WiredSelector',
|
||||
name: 'WeirdSelector',
|
||||
components: {
|
||||
ElSlider
|
||||
ElSlider,
|
||||
InfoIcon
|
||||
},
|
||||
props: {
|
||||
modelValue: {
|
||||
@@ -39,7 +43,7 @@ export default defineComponent({
|
||||
},
|
||||
mounted() {
|
||||
if (!this.value) {
|
||||
this.value = DEFAULT_WIRED;
|
||||
this.value = DEFAULT_WEIRD;
|
||||
}
|
||||
this.$emit('update:modelValue', this.value);
|
||||
}
|
||||
Reference in new issue
Block a user