pref: Optimize the button style for database connection information (#7341)

pull/7342/head
ssongliu 2024-12-12 10:37:49 +08:00 committed by GitHub
parent 013cf21863
commit 0542b39373
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 40 additions and 31 deletions

View File

@ -1,6 +1,6 @@
<template>
<el-button v-if="type == 'icon'" link @click="copyText(content)" icon="DocumentCopy" class="ml-1.5"></el-button>
<el-button type="primary" @click="copyText(content)" v-else>{{ $t('commons.button.copy') }}</el-button>
<el-button @click="copyText(content)" v-else>{{ $t('commons.button.copy') }}</el-button>
</template>
<script lang="ts" setup>

View File

@ -80,16 +80,19 @@
:rules="Rules.paramComplexity"
prop="password"
>
<el-input type="password" show-password clearable v-model="form.password">
<template #suffix>
<CopyButton type="icon" :content="form.password" class="w-30" />
</template>
<template #append>
<el-button @click="random">
{{ $t('commons.button.random') }}
</el-button>
</template>
</el-input>
<el-input
style="width: calc(100% - 147px)"
type="password"
show-password
clearable
v-model="form.password"
/>
<el-button-group>
<CopyButton :content="form.password" />
<el-button @click="random">
{{ $t('commons.button.random') }}
</el-button>
</el-button-group>
</el-form-item>
</div>

View File

@ -81,16 +81,19 @@
:rules="Rules.paramComplexity"
prop="password"
>
<el-input type="password" show-password clearable v-model="form.password">
<template #suffix>
<CopyButton type="icon" :content="form.password" class="w-30" />
</template>
<template #append>
<el-button @click="random">
{{ $t('commons.button.random') }}
</el-button>
</template>
</el-input>
<el-input
style="width: calc(100% - 147px)"
type="password"
show-password
clearable
v-model="form.password"
/>
<el-button-group>
<CopyButton :content="form.password" />
<el-button @click="random">
{{ $t('commons.button.random') }}
</el-button>
</el-button-group>
</el-form-item>
</div>
<div v-if="form.from !== 'local'">

View File

@ -67,16 +67,19 @@
<el-divider border-style="dashed" />
<el-form-item :label="$t('commons.login.password')" v-if="form.from === 'local'" prop="password">
<el-input type="password" show-password clearable v-model="form.password">
<template #suffix>
<CopyButton type="icon" :content="form.password" class="w-30" />
</template>
<template #append>
<el-button @click="random">
{{ $t('commons.button.random') }}
</el-button>
</template>
</el-input>
<el-input
style="width: calc(100% - 147px)"
type="password"
show-password
clearable
v-model="form.password"
/>
<el-button-group>
<CopyButton :content="form.password" />
<el-button @click="random">
{{ $t('commons.button.random') }}
</el-button>
</el-button-group>
</el-form-item>
<div v-if="form.from !== 'local'">