feat: refs #6123 update VnCheckbox and VnLv components for improved info
This commit is contained in:
parent
80baecdd9e
commit
85e8bca89d
|
@ -34,7 +34,7 @@ const checkboxModel = computed({
|
||||||
/>
|
/>
|
||||||
<QIcon
|
<QIcon
|
||||||
v-if="info"
|
v-if="info"
|
||||||
v-bind="$attrs"
|
v-bind="$attrs.infoAttrs"
|
||||||
class="cursor-info q-ml-sm"
|
class="cursor-info q-ml-sm"
|
||||||
name="info"
|
name="info"
|
||||||
size="sm"
|
size="sm"
|
||||||
|
|
|
@ -3,6 +3,7 @@ import { dashIfEmpty } from 'src/filters';
|
||||||
import { useI18n } from 'vue-i18n';
|
import { useI18n } from 'vue-i18n';
|
||||||
import { useClipboard } from 'src/composables/useClipboard';
|
import { useClipboard } from 'src/composables/useClipboard';
|
||||||
import { computed } from 'vue';
|
import { computed } from 'vue';
|
||||||
|
import VnCheckbox from '../common/VnCheckbox.vue';
|
||||||
|
|
||||||
const $props = defineProps({
|
const $props = defineProps({
|
||||||
label: { type: String, default: null },
|
label: { type: String, default: null },
|
||||||
|
@ -30,10 +31,11 @@ const val = computed(() => $props.value);
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
<div class="vn-label-value" :data-cy="`${$attrs['data-cy'] ?? 'vnLv'}${label ?? ''}`">
|
<div class="vn-label-value" :data-cy="`${$attrs['data-cy'] ?? 'vnLv'}${label ?? ''}`">
|
||||||
<QCheckbox
|
<VnCheckbox
|
||||||
v-if="typeof value === 'boolean'"
|
v-if="typeof value === 'boolean'"
|
||||||
v-model="val"
|
v-model="val"
|
||||||
:label="label"
|
:label="label"
|
||||||
|
:info="info"
|
||||||
disable
|
disable
|
||||||
dense
|
dense
|
||||||
size="sm"
|
size="sm"
|
||||||
|
|
|
@ -180,7 +180,7 @@ select:-webkit-autofill {
|
||||||
|
|
||||||
.disabled {
|
.disabled {
|
||||||
& .q-checkbox__label {
|
& .q-checkbox__label {
|
||||||
color: var(--vn-text-color);
|
color: var(--vn-label-color);
|
||||||
}
|
}
|
||||||
& .q-checkbox__inner {
|
& .q-checkbox__inner {
|
||||||
color: var(--vn-label-color);
|
color: var(--vn-label-color);
|
||||||
|
|
|
@ -104,6 +104,14 @@ function setFooter(data) {
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<template>
|
<template>
|
||||||
|
<FetchData
|
||||||
|
ref="fetchDataRef"
|
||||||
|
url="ProductionConfigs"
|
||||||
|
:filter="{
|
||||||
|
fields: ['isZoneClosedByExpeditionActivated', 'minTicketsToCloseZone'],
|
||||||
|
}"
|
||||||
|
@on-fetch="(data) => (productionConfig = data[0])"
|
||||||
|
/>
|
||||||
<QDialog v-model="productionConfigDialogRef" :class="['vn-row', 'wrap']">
|
<QDialog v-model="productionConfigDialogRef" :class="['vn-row', 'wrap']">
|
||||||
<FormModelPopup
|
<FormModelPopup
|
||||||
url-update="ProductionConfigs/1"
|
url-update="ProductionConfigs/1"
|
||||||
|
@ -148,17 +156,6 @@ function setFooter(data) {
|
||||||
auto-load
|
auto-load
|
||||||
>
|
>
|
||||||
<template #top-left>
|
<template #top-left>
|
||||||
<FetchData
|
|
||||||
ref="fetchDataRef"
|
|
||||||
url="ProductionConfigs"
|
|
||||||
:filter="{
|
|
||||||
fields: [
|
|
||||||
'isZoneClosedByExpeditionActivated',
|
|
||||||
'minTicketsToCloseZone',
|
|
||||||
],
|
|
||||||
}"
|
|
||||||
@on-fetch="(data) => (productionConfig = data[0])"
|
|
||||||
/>
|
|
||||||
<VnRow>
|
<VnRow>
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('minTicketsToCloseZone')"
|
:label="t('minTicketsToCloseZone')"
|
||||||
|
@ -168,7 +165,7 @@ function setFooter(data) {
|
||||||
<VnLv
|
<VnLv
|
||||||
:label="t('isZoneClosedByExpeditionActivated')"
|
:label="t('isZoneClosedByExpeditionActivated')"
|
||||||
:value="productionConfig?.isZoneClosedByExpeditionActivated"
|
:value="productionConfig?.isZoneClosedByExpeditionActivated"
|
||||||
style="max-width: 100%"
|
style="color: red !important"
|
||||||
info="test"
|
info="test"
|
||||||
/>
|
/>
|
||||||
<QBtn
|
<QBtn
|
||||||
|
|
Loading…
Reference in New Issue