@7365admin1/layer-common 3.2.2-staging.123 → 3.2.2-staging.124
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/EntryPass/QrTemplatePreview.vue +27 -16
- package/components/Feedback/Form.vue +26 -12
- package/components/HygieneUpdateMoreAction.vue +44 -44
- package/components/IncidentReport/affectedEntities.vue +41 -20
- package/components/NumberSettingField.vue +9 -2
- package/components/Signature.vue +40 -34
- package/components/UnitPersonCard.vue +42 -13
- package/package.json +1 -1
|
@@ -6,24 +6,28 @@
|
|
|
6
6
|
persistent
|
|
7
7
|
@update:model-value="emit('update:modelValue', $event)"
|
|
8
8
|
>
|
|
9
|
-
<v-card>
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
9
|
+
<v-card class="screen-modal">
|
|
10
|
+
<!-- Was a 12px-tall `v-toolbar` themed by hand (`white` / `grey-darken-4`)
|
|
11
|
+
carrying a `grey-darken-1` icon button. The design's modal close is a
|
|
12
|
+
borderless 32px square on `--muted`, so the whole bar goes and the
|
|
13
|
+
close sits on the card's own surface. -->
|
|
14
|
+
<div class="d-flex justify-end pa-2">
|
|
15
15
|
<v-btn
|
|
16
|
-
|
|
16
|
+
variant="text"
|
|
17
17
|
icon="mdi-close"
|
|
18
|
+
class="screen-modal__close"
|
|
19
|
+
aria-label="Close preview"
|
|
18
20
|
@click="emit('update:modelValue', false)"
|
|
19
21
|
></v-btn>
|
|
20
|
-
</
|
|
22
|
+
</div>
|
|
21
23
|
|
|
22
|
-
<v-card-text
|
|
24
|
+
<v-card-text class="screen-modal__body pa-0">
|
|
23
25
|
<v-container>
|
|
24
26
|
<v-row no-gutters class="text-center">
|
|
25
27
|
<v-col cols="12">
|
|
26
|
-
|
|
28
|
+
<!-- `text-h5` is Vuetify's 24px/400 Roboto scale. The design's
|
|
29
|
+
modal title token is `--fs-card-title` / `--fw-card-title`. -->
|
|
30
|
+
<p class="qr-preview__title mb-3">{{ header }}</p>
|
|
27
31
|
<p>{{ subText }}</p>
|
|
28
32
|
</v-col>
|
|
29
33
|
|
|
@@ -53,8 +57,8 @@
|
|
|
53
57
|
</v-col>
|
|
54
58
|
|
|
55
59
|
<v-col cols="12" class="mt-5">
|
|
56
|
-
<p class="
|
|
57
|
-
<p class="
|
|
60
|
+
<p class="qr-preview__title mb-2">Company Name</p>
|
|
61
|
+
<p class="qr-preview__title mb-3">BL 01/03/24</p>
|
|
58
62
|
<p class="mb-1">{{ `Date: ${dateStr} ${timeStr}` }}</p>
|
|
59
63
|
<p class="mb-1">Access: Door</p>
|
|
60
64
|
<p>Scan and press level 1. One time use.</p>
|
|
@@ -67,7 +71,6 @@
|
|
|
67
71
|
</template>
|
|
68
72
|
|
|
69
73
|
<script lang="ts" setup>
|
|
70
|
-
import { useTheme } from "vuetify";
|
|
71
74
|
import QRCode from "qrcode";
|
|
72
75
|
|
|
73
76
|
defineProps({
|
|
@@ -87,9 +90,6 @@ defineProps({
|
|
|
87
90
|
|
|
88
91
|
const emit = defineEmits(["update:modelValue"]);
|
|
89
92
|
|
|
90
|
-
const { global: themeGlobal } = useTheme();
|
|
91
|
-
const isDark = computed(() => themeGlobal.current.value.dark);
|
|
92
|
-
|
|
93
93
|
const qrSmall = ref<string>("");
|
|
94
94
|
const qrLarge = ref<string>("");
|
|
95
95
|
|
|
@@ -102,3 +102,14 @@ const now = new Date();
|
|
|
102
102
|
const dateStr = now.toLocaleDateString();
|
|
103
103
|
const timeStr = now.toLocaleTimeString();
|
|
104
104
|
</script>
|
|
105
|
+
|
|
106
|
+
<style scoped>
|
|
107
|
+
/* The pass body is a printed artefact, so its own sizes stay. Only the two
|
|
108
|
+
heading lines move off Vuetify's Roboto display scale onto the design's
|
|
109
|
+
modal-title token. */
|
|
110
|
+
.qr-preview__title {
|
|
111
|
+
font-size: var(--fs-card-title);
|
|
112
|
+
font-weight: var(--fw-card-title);
|
|
113
|
+
color: var(--text);
|
|
114
|
+
}
|
|
115
|
+
</style>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<FormDialog v-model="dialog" @close="closeDialog">
|
|
3
3
|
<template #title>
|
|
4
|
-
<span class="
|
|
4
|
+
<span class="screen-card-title pt-1 text-capitalize">
|
|
5
5
|
{{ isEditMode ? "Edit Feedback" : "Create Feedback" }}
|
|
6
6
|
</span>
|
|
7
7
|
</template>
|
|
@@ -22,13 +22,13 @@
|
|
|
22
22
|
item-value="value"
|
|
23
23
|
item-props
|
|
24
24
|
variant="outlined"
|
|
25
|
-
density="
|
|
26
|
-
class="mb-2"
|
|
25
|
+
density="comfortable"
|
|
26
|
+
class="mb-2 filter-field"
|
|
27
27
|
clearable
|
|
28
28
|
:custom-filter="customFilter"
|
|
29
29
|
:rules="[requiredRule]"
|
|
30
30
|
>
|
|
31
|
-
<template #label> Subject <span class="
|
|
31
|
+
<template #label> Subject <span class="feedback-form__required">*</span> </template>
|
|
32
32
|
</v-autocomplete>
|
|
33
33
|
|
|
34
34
|
<!-- <v-autocomplete
|
|
@@ -44,37 +44,43 @@
|
|
|
44
44
|
clearable
|
|
45
45
|
:rules="[requiredRule]"
|
|
46
46
|
>
|
|
47
|
-
<template #label> Category <span class="
|
|
47
|
+
<template #label> Category <span class="feedback-form__required">*</span> </template>
|
|
48
48
|
</v-autocomplete> -->
|
|
49
49
|
|
|
50
50
|
<v-text-field
|
|
51
51
|
label="Location"
|
|
52
52
|
variant="outlined"
|
|
53
|
-
density="
|
|
53
|
+
density="comfortable"
|
|
54
|
+
class="mb-2 filter-field"
|
|
54
55
|
v-model="localFeedback.location"
|
|
55
56
|
:rules="[requiredRule]"
|
|
56
57
|
>
|
|
57
|
-
<template #label> Location <span class="
|
|
58
|
+
<template #label> Location <span class="feedback-form__required">*</span> </template>
|
|
58
59
|
</v-text-field>
|
|
59
60
|
|
|
60
61
|
<v-textarea
|
|
61
62
|
label="Description"
|
|
62
63
|
variant="outlined"
|
|
63
|
-
density="
|
|
64
|
+
density="comfortable"
|
|
65
|
+
class="filter-field"
|
|
64
66
|
auto-grow
|
|
65
67
|
rows="4"
|
|
66
68
|
v-model="localFeedback.description"
|
|
67
69
|
:rules="[requiredRule]"
|
|
68
70
|
>
|
|
69
|
-
<template #label> Description <span class="
|
|
71
|
+
<template #label> Description <span class="feedback-form__required">*</span> </template>
|
|
70
72
|
</v-textarea>
|
|
71
73
|
|
|
72
74
|
<template #footer>
|
|
75
|
+
<!-- `color="primary-button"` was already the right token (the FILL, not
|
|
76
|
+
the `primary` foreground) and `height="40"` already the right number,
|
|
77
|
+
but both were stated by hand. `.screen-btn-primary` is where the
|
|
78
|
+
layer says that once, and it wins over Vuetify's `--v-btn-height`
|
|
79
|
+
without an `!important`. -->
|
|
73
80
|
<v-btn
|
|
74
|
-
|
|
75
|
-
|
|
81
|
+
class="text-capitalize mb-4 screen-btn-primary"
|
|
82
|
+
variant="flat"
|
|
76
83
|
block
|
|
77
|
-
height="40"
|
|
78
84
|
:loading="loading"
|
|
79
85
|
:disabled="loading || !isFormValid"
|
|
80
86
|
@click="submitFeedback"
|
|
@@ -171,3 +177,11 @@ const customFilter = (value: string, query: string, item: any) => {
|
|
|
171
177
|
return title.includes(search) || subtitle.includes(search);
|
|
172
178
|
};
|
|
173
179
|
</script>
|
|
180
|
+
|
|
181
|
+
<style scoped>
|
|
182
|
+
/* Was `text-red`, a fixed Vuetify red that is the same red on both themes.
|
|
183
|
+
`--err` is the theme's error ink and follows it. */
|
|
184
|
+
.feedback-form__required {
|
|
185
|
+
color: var(--err);
|
|
186
|
+
}
|
|
187
|
+
</style>
|
|
@@ -1,55 +1,46 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
</v-toolbar>
|
|
15
|
-
|
|
16
|
-
<v-card-text style="max-height: 100vh; overflow-y: auto" class="pb-0">
|
|
2
|
+
<!-- The hygiene twin of `Dialog/UpdateMoreAction`, converted to the same
|
|
3
|
+
shape on staging. Its title row and its footer were both `v-toolbar`s -
|
|
4
|
+
fixed grey slabs that stay grey on the dark theme - and the footer's
|
|
5
|
+
action was a hardcoded `color="black"` fill, i.e. the same black on the
|
|
6
|
+
dark theme as on the light one. -->
|
|
7
|
+
<v-card class="screen-modal" width="100%">
|
|
8
|
+
<template v-if="$slots.header">
|
|
9
|
+
<slot name="header" :title="title" :onClose="onClose" />
|
|
10
|
+
</template>
|
|
11
|
+
<v-card-title v-else class="text-capitalize">{{ title }}</v-card-title>
|
|
12
|
+
|
|
13
|
+
<v-card-text class="screen-modal__body pb-0">
|
|
17
14
|
<slot name="content" />
|
|
18
15
|
</v-card-text>
|
|
19
16
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
Close
|
|
32
|
-
</v-btn>
|
|
33
|
-
</v-col>
|
|
34
|
-
|
|
35
|
-
<v-col v-if="showMoreActions" cols="6" class="pa-0">
|
|
36
|
-
<v-menu>
|
|
17
|
+
<!-- The design's footer strip: equal-width buttons, ghost then primary. -->
|
|
18
|
+
<div class="screen-modal__footer">
|
|
19
|
+
<v-btn
|
|
20
|
+
variant="outlined"
|
|
21
|
+
class="text-none screen-btn-ghost"
|
|
22
|
+
@click="emit('close')"
|
|
23
|
+
>
|
|
24
|
+
Close
|
|
25
|
+
</v-btn>
|
|
26
|
+
|
|
27
|
+
<v-menu v-if="showMoreActions" contained>
|
|
37
28
|
<template #activator="{ props }">
|
|
38
29
|
<v-btn
|
|
39
|
-
block
|
|
40
30
|
variant="flat"
|
|
41
|
-
|
|
42
|
-
class="text-none"
|
|
43
|
-
height="48"
|
|
31
|
+
class="text-none screen-btn-primary"
|
|
44
32
|
:disabled="disabled"
|
|
45
33
|
v-bind="props"
|
|
46
|
-
tile
|
|
47
34
|
>
|
|
48
35
|
More actions
|
|
49
36
|
</v-btn>
|
|
50
37
|
</template>
|
|
51
38
|
|
|
52
|
-
|
|
39
|
+
<!-- The dropdown itself is left as Vuetify draws it, exactly as the
|
|
40
|
+
converted twin left it: the handoff gives a per-row menu no
|
|
41
|
+
shape, and this menu opens on a click the harness cannot drive,
|
|
42
|
+
so it could not be render-verified either. -->
|
|
43
|
+
<v-list class="pa-0 hyg-more__list">
|
|
53
44
|
<v-list-item
|
|
54
45
|
v-if="showQrButton && qrButtonLabel"
|
|
55
46
|
@click="emit('showqr')"
|
|
@@ -110,20 +101,22 @@
|
|
|
110
101
|
</v-list-item-title>
|
|
111
102
|
</v-list-item>
|
|
112
103
|
|
|
104
|
+
<!-- `text-red` was Vuetify's fixed #f44336, the same red on both
|
|
105
|
+
themes. `text-error` is Vuetify's own class over
|
|
106
|
+
`--v-theme-error`, which IS the design's `--err` - the same
|
|
107
|
+
substitution the converted twin made. -->
|
|
113
108
|
<v-list-item
|
|
114
109
|
v-if="canDelete"
|
|
115
110
|
@click="emit('delete')"
|
|
116
|
-
class="text-
|
|
111
|
+
class="text-error"
|
|
117
112
|
>
|
|
118
113
|
<v-list-item-title class="text-subtitle-2">
|
|
119
114
|
{{ deleteButtonLabel }}
|
|
120
115
|
</v-list-item-title>
|
|
121
116
|
</v-list-item>
|
|
122
117
|
</v-list>
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
</v-row>
|
|
126
|
-
</v-toolbar>
|
|
118
|
+
</v-menu>
|
|
119
|
+
</div>
|
|
127
120
|
</v-card>
|
|
128
121
|
</template>
|
|
129
122
|
|
|
@@ -240,4 +233,11 @@ const {
|
|
|
240
233
|
} = prop;
|
|
241
234
|
</script>
|
|
242
235
|
|
|
243
|
-
<style scoped
|
|
236
|
+
<style scoped>
|
|
237
|
+
/* `text-subtitle-2` is Vuetify's 0.875rem/500; the handoff names no type for a
|
|
238
|
+
menu row, so it takes the established cell type - same rule as the twin. */
|
|
239
|
+
.hyg-more__list :deep(.v-list-item-title) {
|
|
240
|
+
font-size: var(--fs-cell);
|
|
241
|
+
font-weight: var(--fw-cell);
|
|
242
|
+
}
|
|
243
|
+
</style>
|
|
@@ -2,18 +2,22 @@
|
|
|
2
2
|
<v-row no-gutters class="px-5 pt-4">
|
|
3
3
|
<!-- Anyone affected/injured -->
|
|
4
4
|
<v-col cols="12" class="border-b pb-5 mb-5 mt-1">
|
|
5
|
-
|
|
5
|
+
<!-- Same shape as this report's `Authorities.vue` sibling, already on
|
|
6
|
+
staging: a `.screen-card-title` question, a `.report-answer` line
|
|
7
|
+
when the answer is "no", and the table inside an `AppCard` instead of
|
|
8
|
+
a `border` class Vuetify draws from its own fixed grey. -->
|
|
9
|
+
<p class="screen-card-title mb-2">
|
|
6
10
|
Anyone affected/injured?
|
|
7
11
|
</p>
|
|
8
12
|
<p
|
|
9
13
|
v-if="affectedEntities?.anyoneAffectedValue == 'no'"
|
|
10
|
-
class="
|
|
14
|
+
class="report-answer mt-2 text-capitalize"
|
|
11
15
|
>
|
|
12
16
|
{{ affectedEntities?.anyoneAffectedValue }}
|
|
13
17
|
</p>
|
|
14
18
|
|
|
19
|
+
<AppCard v-else class="table-card mt-5">
|
|
15
20
|
<v-data-table
|
|
16
|
-
v-else
|
|
17
21
|
:headers="injuredTableHeader"
|
|
18
22
|
:items="affectedEntities?.affectedInjured"
|
|
19
23
|
fixed-header
|
|
@@ -21,16 +25,17 @@
|
|
|
21
25
|
:hide-default-header="false"
|
|
22
26
|
items-per-page="100"
|
|
23
27
|
style="max-height: calc(100vh - (200px))"
|
|
24
|
-
class="border mt-5"
|
|
25
28
|
>
|
|
26
29
|
<template #header.nric>
|
|
27
30
|
<div class="d-flex align-center">
|
|
28
31
|
NRIC
|
|
32
|
+
<!-- `color="blue"` is a fixed Vuetify blue, the same on both
|
|
33
|
+
themes. `--accent-text` is the design's interactive ink. -->
|
|
29
34
|
<v-icon
|
|
30
35
|
v-if="isShowEyeIcon"
|
|
31
|
-
class="cursor-pointer ml-1"
|
|
36
|
+
class="cursor-pointer ml-1 affected__eye"
|
|
32
37
|
size="18"
|
|
33
|
-
|
|
38
|
+
:aria-label="isShowNRIC ? 'Hide NRIC' : 'Show NRIC'"
|
|
34
39
|
@click="isShowNRIC = !isShowNRIC"
|
|
35
40
|
>
|
|
36
41
|
{{ isShowNRIC ? "mdi-eye-off-outline" : "mdi-eye-outline" }}
|
|
@@ -45,36 +50,52 @@
|
|
|
45
50
|
</tr>
|
|
46
51
|
</template>
|
|
47
52
|
</v-data-table>
|
|
53
|
+
</AppCard>
|
|
48
54
|
</v-col>
|
|
49
55
|
|
|
50
56
|
<!-- Anyone damage to property -->
|
|
51
57
|
<v-col cols="12" class="pb-5 mb-5 mt-1">
|
|
52
|
-
<p class="
|
|
58
|
+
<p class="screen-card-title mb-2">
|
|
53
59
|
Anyone damage to property?
|
|
54
60
|
</p>
|
|
55
61
|
<p
|
|
56
62
|
v-if="affectedEntities?.anyUnitAffectedValue == 'no'"
|
|
57
|
-
class="
|
|
63
|
+
class="report-answer mt-2 text-capitalize"
|
|
58
64
|
>
|
|
59
65
|
{{ affectedEntities?.anyUnitAffectedValue }}
|
|
60
66
|
</p>
|
|
61
67
|
|
|
62
|
-
<v-
|
|
63
|
-
v-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
</
|
|
68
|
+
<AppCard v-else class="table-card mt-5">
|
|
69
|
+
<v-data-table
|
|
70
|
+
:headers="damagePropertyTableHeader"
|
|
71
|
+
:items="affectedEntities?.anyoneDamageToProperty"
|
|
72
|
+
fixed-header
|
|
73
|
+
hide-default-footer
|
|
74
|
+
:hide-default-header="false"
|
|
75
|
+
items-per-page="100"
|
|
76
|
+
style="max-height: calc(100vh - (200px))"
|
|
77
|
+
>
|
|
78
|
+
</v-data-table>
|
|
79
|
+
</AppCard>
|
|
74
80
|
</v-col>
|
|
75
81
|
</v-row>
|
|
76
82
|
</template>
|
|
77
83
|
|
|
84
|
+
<style scoped>
|
|
85
|
+
/* Same two rules as this report's `Authorities.vue` sibling: the prototype
|
|
86
|
+
states no size for a plain answer line, so it takes the body row's type
|
|
87
|
+
rather than Vuetify's `text-h6`. */
|
|
88
|
+
.report-answer {
|
|
89
|
+
font-size: var(--fs-cell);
|
|
90
|
+
font-weight: var(--fw-cell);
|
|
91
|
+
color: var(--text);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.affected__eye {
|
|
95
|
+
color: var(--accent-text);
|
|
96
|
+
}
|
|
97
|
+
</style>
|
|
98
|
+
|
|
78
99
|
<script lang="ts" setup>
|
|
79
100
|
definePageMeta({
|
|
80
101
|
middleware: ["01-auth", "02-org"],
|
|
@@ -4,11 +4,18 @@
|
|
|
4
4
|
<v-row>
|
|
5
5
|
<v-col cols="6">
|
|
6
6
|
<InputLabel class="text-capitalize font-weight-bold" :title="title" :required="required" />
|
|
7
|
-
<v-text-field v-model.number="count" type="number" density="comfortable" :rules="rules" :readonly="readOnly" />
|
|
7
|
+
<v-text-field v-model.number="count" type="number" class="filter-field" density="comfortable" :rules="rules" :readonly="readOnly" />
|
|
8
8
|
</v-col>
|
|
9
9
|
|
|
10
10
|
<v-col cols="6">
|
|
11
|
-
|
|
11
|
+
<!-- Was `color="primary" size="large"`. On a `v-btn`,
|
|
12
|
+
`primary` is this theme's FOREGROUND token (links,
|
|
13
|
+
icons, text buttons) - the fill is `primary-button`, so
|
|
14
|
+
a flat button asking for `primary` painted itself with
|
|
15
|
+
an ink colour. `.screen-btn-primary` is the design's
|
|
16
|
+
40px primary and carries the correct fill, so the
|
|
17
|
+
colour prop and the Vuetify size both go. -->
|
|
18
|
+
<v-btn v-if="!readOnly" class="text-none mt-6 screen-btn-primary" variant="flat"
|
|
12
19
|
:disabled="!valid || disabled" :loading="loading || updating" text="Save" @click="handleSave" />
|
|
13
20
|
</v-col>
|
|
14
21
|
</v-row>
|
package/components/Signature.vue
CHANGED
|
@@ -1,16 +1,28 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<v-dialog v-model="dialogModel" max-width="700" persistent>
|
|
3
|
-
<v-card>
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
<v-card class="screen-modal">
|
|
4
|
+
<!-- Was a bare `v-toolbar`, which Vuetify paints from its own `surface`:
|
|
5
|
+
a grey slab across the top of the card, visibly lighter than the card
|
|
6
|
+
on the dark theme. A `v-card-title` is the same row on the card's own
|
|
7
|
+
surface, and the close is the design's borderless 32px square. -->
|
|
8
|
+
<v-card-title class="d-flex align-center">
|
|
9
|
+
Signature
|
|
6
10
|
<v-spacer />
|
|
7
|
-
<v-btn
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
+
<v-btn
|
|
12
|
+
variant="text"
|
|
13
|
+
icon="mdi-close"
|
|
14
|
+
class="screen-modal__close"
|
|
15
|
+
aria-label="Close signature"
|
|
16
|
+
@click="hideModal"
|
|
17
|
+
/>
|
|
18
|
+
</v-card-title>
|
|
19
|
+
|
|
20
|
+
<v-card-text class="screen-modal__body">
|
|
11
21
|
<v-row no-gutters>
|
|
12
22
|
<v-col cols="12">
|
|
13
|
-
|
|
23
|
+
<!-- `text-medium-emphasis` is Vuetify's 60%-alpha ink; `--muted` is
|
|
24
|
+
the design's sub-line and follows the theme. -->
|
|
25
|
+
<div class="screen-hint ml-2 mb-2">
|
|
14
26
|
Your signature here
|
|
15
27
|
</div>
|
|
16
28
|
|
|
@@ -23,34 +35,28 @@
|
|
|
23
35
|
class="border"
|
|
24
36
|
/>
|
|
25
37
|
</v-col>
|
|
26
|
-
|
|
27
|
-
<v-col cols="12" class="text-center">
|
|
28
|
-
<v-row class="d-flex">
|
|
29
|
-
<v-col class="w-50 px-3">
|
|
30
|
-
<v-btn
|
|
31
|
-
text="clear"
|
|
32
|
-
color="warning"
|
|
33
|
-
class="my-4 w-100 rounded-lg"
|
|
34
|
-
height="40px"
|
|
35
|
-
@click="clear"
|
|
36
|
-
/>
|
|
37
|
-
</v-col>
|
|
38
|
-
|
|
39
|
-
<v-col class="w-50 px-3">
|
|
40
|
-
<v-btn
|
|
41
|
-
text="submit"
|
|
42
|
-
color="#1867C0"
|
|
43
|
-
class="my-4 w-100 rounded-lg"
|
|
44
|
-
height="40px"
|
|
45
|
-
:loading="loading"
|
|
46
|
-
:disabled="loading"
|
|
47
|
-
@click="submit"
|
|
48
|
-
/>
|
|
49
|
-
</v-col>
|
|
50
|
-
</v-row>
|
|
51
|
-
</v-col>
|
|
52
38
|
</v-row>
|
|
53
39
|
</v-card-text>
|
|
40
|
+
|
|
41
|
+
<!-- The design's modal footer: two equal-width buttons on a bordered
|
|
42
|
+
strip, ghost then primary. Was a hand-built `v-row` of two 50%
|
|
43
|
+
columns, one `color="warning"` and one a LITERAL `#1867C0` - a fixed
|
|
44
|
+
hex that is the same blue on both themes and is not the theme's
|
|
45
|
+
accent either. Both colours go; the shape is the shared one. -->
|
|
46
|
+
<div class="screen-modal__footer">
|
|
47
|
+
<v-btn class="text-none screen-btn-ghost" variant="outlined" @click="clear">
|
|
48
|
+
Clear
|
|
49
|
+
</v-btn>
|
|
50
|
+
<v-btn
|
|
51
|
+
class="text-none screen-btn-primary"
|
|
52
|
+
variant="flat"
|
|
53
|
+
:loading="loading"
|
|
54
|
+
:disabled="loading"
|
|
55
|
+
@click="submit"
|
|
56
|
+
>
|
|
57
|
+
Submit
|
|
58
|
+
</v-btn>
|
|
59
|
+
</div>
|
|
54
60
|
</v-card>
|
|
55
61
|
</v-dialog>
|
|
56
62
|
</template>
|
|
@@ -3,26 +3,26 @@
|
|
|
3
3
|
<v-row>
|
|
4
4
|
<v-col cols="12" md="4" class="mt-2">
|
|
5
5
|
<InputLabel class="font-weight-bold" title="Name" />
|
|
6
|
-
<v-text-field :model-value="person.name"
|
|
7
|
-
:class="{ 'no-pointer': readOnly }" />
|
|
6
|
+
<v-text-field :model-value="person.name" class="filter-field" density="comfortable"
|
|
7
|
+
:readonly="readOnly" :class="{ 'no-pointer': readOnly }" />
|
|
8
8
|
</v-col>
|
|
9
9
|
|
|
10
10
|
<v-col cols="12" md="4" class="mt-2">
|
|
11
11
|
<InputLabel class="font-weight-bold" title="Email Address" />
|
|
12
|
-
<v-text-field :model-value="person.email"
|
|
13
|
-
:class="{ 'no-pointer': readOnly }" />
|
|
12
|
+
<v-text-field :model-value="person.email" class="filter-field" density="comfortable"
|
|
13
|
+
:readonly="readOnly" :class="{ 'no-pointer': readOnly }" />
|
|
14
14
|
</v-col>
|
|
15
15
|
|
|
16
16
|
<v-col cols="12" md="4" class="mt-2">
|
|
17
17
|
<InputLabel class="font-weight-bold" title="NRIC" />
|
|
18
|
-
<v-text-field :model-value="person.nric"
|
|
19
|
-
:class="{ 'no-pointer': readOnly }" />
|
|
18
|
+
<v-text-field :model-value="person.nric" class="filter-field" density="comfortable"
|
|
19
|
+
:readonly="readOnly" :class="{ 'no-pointer': readOnly }" />
|
|
20
20
|
</v-col>
|
|
21
21
|
|
|
22
22
|
<v-col cols="12" md="4" class="mt-2">
|
|
23
23
|
<InputLabel class="font-weight-bold" title="Mobile Number" />
|
|
24
|
-
<v-text-field :model-value="person.contact"
|
|
25
|
-
:class="{ 'no-pointer': readOnly }" />
|
|
24
|
+
<v-text-field :model-value="person.contact" class="filter-field" density="comfortable"
|
|
25
|
+
:readonly="readOnly" :class="{ 'no-pointer': readOnly }" />
|
|
26
26
|
</v-col>
|
|
27
27
|
</v-row>
|
|
28
28
|
|
|
@@ -30,11 +30,14 @@
|
|
|
30
30
|
<v-col cols="12" md="4" class="mt-2">
|
|
31
31
|
<InputLabel class="font-weight-bold" title="Other Documents and Files" :viewMode="readOnly" />
|
|
32
32
|
|
|
33
|
-
|
|
33
|
+
<!-- Was `text-blue-darken-2`, a fixed Vuetify blue that stays the same
|
|
34
|
+
on the dark theme. An empty note is `--muted`; a file link is
|
|
35
|
+
`--accent-text`, the design's link ink. -->
|
|
36
|
+
<p v-if="!person.files?.length" class="screen-hint unit-person__empty ml-2 mt-5">
|
|
34
37
|
**No documents to display**
|
|
35
38
|
</p>
|
|
36
|
-
<v-list v-else dense nav class="mt-2">
|
|
37
|
-
<v-list-item v-for="file in person.files" :key="file.id" class="
|
|
39
|
+
<v-list v-else dense nav class="mt-2 unit-person__files">
|
|
40
|
+
<v-list-item v-for="file in person.files" :key="file.id" class="unit-person__file"
|
|
38
41
|
:href="getFileUrl(file.id)" target="_blank">
|
|
39
42
|
<v-list-item-content>
|
|
40
43
|
<v-list-item-title class="d-flex align-center">
|
|
@@ -53,11 +56,14 @@
|
|
|
53
56
|
<v-col v-if="prop.showOwnerOption" cols="12" md="4">
|
|
54
57
|
<v-checkbox :model-value="person.isOwner" readonly hide-details density="compact" @click="handleClick">
|
|
55
58
|
<template #label>
|
|
56
|
-
<span class="
|
|
59
|
+
<span class="unit-person__check-label ml-2">Is Owner?</span>
|
|
57
60
|
</template>
|
|
58
61
|
</v-checkbox>
|
|
59
62
|
|
|
60
|
-
|
|
63
|
+
<!-- `text-gray-5` is not a Vuetify class and not a token - it resolved
|
|
64
|
+
to nothing, so this sat on the body ink. `.screen-hint` is the
|
|
65
|
+
design's sub-line. -->
|
|
66
|
+
<span class="d-flex screen-hint ml-7">As owner, you will be receiving emails and updates
|
|
61
67
|
related to this unit.</span>
|
|
62
68
|
</v-col>
|
|
63
69
|
</v-row>
|
|
@@ -120,4 +126,27 @@ const handleClick = () => {
|
|
|
120
126
|
.no-pointer {
|
|
121
127
|
pointer-events: none;
|
|
122
128
|
}
|
|
129
|
+
|
|
130
|
+
/* `.screen-hint` carries the ink; only the size is stated here, and it is the
|
|
131
|
+
cell size, not Vuetify's `text-caption` (12px/400 Roboto). */
|
|
132
|
+
.unit-person__empty {
|
|
133
|
+
font-size: var(--fs-cell);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/* A `v-list` paints Vuetify's own `surface` - a square-cornered lighter slab
|
|
137
|
+
sitting on the card, measured on the dark theme. The files are links on the
|
|
138
|
+
card, so the list carries no surface of its own. */
|
|
139
|
+
.unit-person__files {
|
|
140
|
+
background: transparent;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.unit-person__file {
|
|
144
|
+
color: var(--accent-text);
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.unit-person__check-label {
|
|
148
|
+
font-size: var(--fs-cell);
|
|
149
|
+
font-weight: var(--fw-cell);
|
|
150
|
+
color: var(--text);
|
|
151
|
+
}
|
|
123
152
|
</style>
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@7365admin1/layer-common",
|
|
3
3
|
"license": "MIT",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"version": "3.2.2-staging.
|
|
5
|
+
"version": "3.2.2-staging.124",
|
|
6
6
|
"author": "7365admin1",
|
|
7
7
|
"main": "./nuxt.config.ts",
|
|
8
8
|
"//files": "What a consumer extending this layer actually loads. Without this npm ships the whole working tree - the changesets, the CI workflows, the render harness in tools/ and any scratch directory that happened to exist at publish time. Nuxt resolves a layer by directory, so every runtime directory below has to stay listed; adding a new top-level runtime directory means adding it here too.",
|