mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-26 20:07:33 -07:00
feat(client): プラグインの設定にdescriptionを表示できるように
This commit is contained in:
parent
3d7046390c
commit
72824c802c
1 changed files with 16 additions and 4 deletions
|
@ -5,10 +5,22 @@
|
||||||
</template>
|
</template>
|
||||||
<div class="xkpnjxcv">
|
<div class="xkpnjxcv">
|
||||||
<label v-for="item in Object.keys(form).filter(item => !form[item].hidden)" :key="item">
|
<label v-for="item in Object.keys(form).filter(item => !form[item].hidden)" :key="item">
|
||||||
<mk-input v-if="form[item].type === 'number'" v-model="values[item]" type="number" :step="form[item].step || 1"><span v-text="form[item].label || item"></span></mk-input>
|
<mk-input v-if="form[item].type === 'number'" v-model="values[item]" type="number" :step="form[item].step || 1">
|
||||||
<mk-input v-else-if="form[item].type === 'string' && !item.multiline" v-model="values[item]" type="text"><span v-text="form[item].label || item"></span></mk-input>
|
<span v-text="form[item].label || item"></span>
|
||||||
<mk-textarea v-else-if="form[item].type === 'string' && item.multiline" v-model="values[item]"><span v-text="form[item].label || item"></span></mk-textarea>
|
<template v-if="form[item].description" #desc>{{ form[item].description }}</template>
|
||||||
<mk-switch v-else-if="form[item].type === 'boolean'" v-model="values[item]"><span v-text="form[item].label || item"></span></mk-switch>
|
</mk-input>
|
||||||
|
<mk-input v-else-if="form[item].type === 'string' && !item.multiline" v-model="values[item]" type="text">
|
||||||
|
<span v-text="form[item].label || item"></span>
|
||||||
|
<template v-if="form[item].description" #desc>{{ form[item].description }}</template>
|
||||||
|
</mk-input>
|
||||||
|
<mk-textarea v-else-if="form[item].type === 'string' && item.multiline" v-model="values[item]">
|
||||||
|
<span v-text="form[item].label || item"></span>
|
||||||
|
<template v-if="form[item].description" #desc>{{ form[item].description }}</template>
|
||||||
|
</mk-textarea>
|
||||||
|
<mk-switch v-else-if="form[item].type === 'boolean'" v-model="values[item]">
|
||||||
|
<span v-text="form[item].label || item"></span>
|
||||||
|
<template v-if="form[item].description" #desc>{{ form[item].description }}</template>
|
||||||
|
</mk-switch>
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
</x-window>
|
</x-window>
|
||||||
|
|
Loading…
Reference in a new issue