Skip to content

Commit

Permalink
[#639] Fix display of data fields
Browse files Browse the repository at this point in the history
Signed-off-by: Marius David Wieschollek <passwords.public@mdns.eu>
  • Loading branch information
marius-wieschollek committed Feb 17, 2024
1 parent 96d9ca7 commit eda990b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
:class="getSecretClass"
v-if="type === 'secret'"
@click="copyValue">{{ getSecretValue }}</span>
<span v-if="type === 'text'" @click="copyValue">{{ value }}</span>
<span v-if="type === 'text' || type === 'data'" @click="copyValue">{{ value }}</span>
</div>
</template>

Expand Down
7 changes: 6 additions & 1 deletion src/vue/Dialog/CreatePassword/CustomField.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
-->

<template>
<div class="password-form-field-wrapper password-form-custom-field-wrapper" :class="{drag:drag}" @dragenter="dragEnter">
<div class="password-form-field-wrapper password-form-custom-field-wrapper" :class="{drag:drag}" @dragenter="dragEnter" v-if="isVisible">
<div class="area-label">
<icon :icon="icon" @mouseenter="hover = true" @mouseleave="hover = false" @dragstart="dragStart" draggable="true"/>
<input class="field-label" :placeholder="t('Name')" :maxlength="maxlength" v-model="model.label" required/>
Expand Down Expand Up @@ -39,6 +39,7 @@
import DataCustomField from "@vue/Dialog/CreatePassword/CustomFields/DataCustomField";
import FileCustomField from "@vue/Dialog/CreatePassword/CustomFields/FileCustomField";
import PasswordControls from "@vue/Dialog/CreatePassword/PasswordControls";
import SettingsService from "@js/Services/SettingsService";

export default {
components: {PasswordControls, FileCustomField, DataCustomField, UrlCustomField, SecretCustomField, EmailCustomField, TextCustomField, Icon, Translate},
Expand Down Expand Up @@ -71,6 +72,10 @@
},
drag() {
return this.dragService.isCurrent(this.model);
},
isVisible() {
return this.model.type !== 'data' ||
SettingsService.get('client.ui.custom.fields.show.hidden', false);
}
},
methods : {
Expand Down

0 comments on commit eda990b

Please sign in to comment.