@feedmepos/mf-hrm-portal 2.2.5-dev.6 → 2.2.5-dev.8
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/dist/{ApprovalCodeList-CtCpcbAC.js → ApprovalCodeList-BzL73nqc.js} +2 -2
- package/dist/{AuditLogList-BYOvk3l4.js → AuditLogList-BEZoHLsX.js} +3 -3
- package/dist/{ConditionBuilderForm.vue_vue_type_script_setup_true_lang-DS4_vkTG.js → ConditionBuilderForm.vue_vue_type_script_setup_true_lang-DDrP7ywR.js} +2 -2
- package/dist/{EmployeeList-B_sTjkdO.js → EmployeeList-s4FYw1ZF.js} +5 -5
- package/dist/{GrantUserList-_nRUyHYM.js → GrantUserList-Ci_ElhHZ.js} +3 -3
- package/dist/{Main-CloHiemF.js → Main-BojQuzZI.js} +5 -5
- package/dist/{Main-DoLU6s-8.js → Main-CKr3RGvf.js} +2 -2
- package/dist/{Main-DqY2oGAM.js → Main-N1CNGDAy.js} +9 -9
- package/dist/{PermissionSetList-uL-0fN9H.js → PermissionSetList-DLknSOzA.js} +5 -5
- package/dist/{PortalPermissionEditor.vue_vue_type_script_setup_true_lang-dCgJ2s08.js → PortalPermissionEditor.vue_vue_type_script_setup_true_lang-DK2Bx8Aw.js} +1066 -1066
- package/dist/{RoleList-CwrDYFXz.js → RoleList-Cm7_q5l9.js} +7 -7
- package/dist/ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-DrJ1vA88.js +426 -0
- package/dist/ScheduleButton.vue_vue_type_script_setup_true_lang-DX5JR7bi.js +600 -0
- package/dist/ScheduleGeneralPage-CmR4BZAp.js +323 -0
- package/dist/SchedulePage-CN3ZsQ9E.js +13905 -0
- package/dist/SchedulePositionPage-Bv3zraaF.js +293 -0
- package/dist/ScheduleSelect.vue_vue_type_script_setup_true_lang-Buu8NEQf.js +221 -0
- package/dist/{TeamMemberList-qyKCeSsW.js → TeamMemberList-D2OfkfJP.js} +6 -6
- package/dist/{TimesheetList-D1EJG90Z.js → TimesheetList-DEdLpYuM.js} +4 -4
- package/dist/{TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-Car-HXjq.js → TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-BfMkNvCz.js} +1 -1
- package/dist/{app-By1O6mq8.js → app-Dmmpy4k-.js} +127 -127
- package/dist/app.js +1 -1
- package/dist/{dayjs.min-_ZoZF_Ra.js → dayjs.min-DcfKURXN.js} +1 -1
- package/dist/{employee-BC7QM1dX.js → employee-D3ZpYH4j.js} +3 -3
- package/dist/{index-u10uXqFM.js → index-BxkisKEs.js} +1 -1
- package/dist/{index-CHf8MAN1.js → index-D-VlxJu9.js} +1 -1
- package/dist/{lodash-BsAtPIfh.js → lodash-p40sRkqQ.js} +1 -1
- package/dist/{role-PShfEEXE.js → role-CM1urkJZ.js} +1 -1
- package/dist/{rule-RU8uWecT.js → rule-BPApyMJY.js} +2 -2
- package/dist/src/api/schedule/index.d.ts +0 -3
- package/dist/src/views/scheduling/ScheduleGeneralPage.vue.d.ts +1 -2
- package/dist/src/views/scheduling/SchedulePage.vue.d.ts +1 -2
- package/dist/src/views/scheduling/SchedulePositionPage.vue.d.ts +1 -2
- package/dist/src/views/scheduling/components/ScheduleAddEmployeeModal.vue.d.ts +5 -1
- package/dist/src/views/scheduling/components/ScheduleAddEmployeePositionsSection.vue.d.ts +5 -1
- package/dist/src/views/scheduling/components/ScheduleAddPositionModal.vue.d.ts +6 -0
- package/dist/src/views/scheduling/components/ScheduleButton.vue.d.ts +23 -0
- package/dist/src/views/scheduling/components/ScheduleConfirmModal.vue.d.ts +1 -1
- package/dist/src/views/scheduling/components/ScheduleEmployeeMenu.vue.d.ts +6 -0
- package/dist/src/views/scheduling/components/ScheduleLeaveEditModal.vue.d.ts +4 -2
- package/dist/src/views/scheduling/components/ScheduleOnboardingWizard.vue.d.ts +3 -0
- package/dist/src/views/scheduling/components/ScheduleSelect.vue.d.ts +14 -0
- package/dist/src/views/scheduling/components/ScheduleShiftHeadcountEditor.vue.d.ts +5 -1
- package/dist/src/views/scheduling/components/ScheduleShiftPopover.vue.d.ts +2 -0
- package/dist/src/views/scheduling/components/ScheduleStaffRail.vue.d.ts +4 -2
- package/dist/src/views/scheduling/components/ScheduleStaffRows.vue.d.ts +4 -2
- package/dist/src/views/scheduling/components/ScheduleTopbar.vue.d.ts +2 -4
- package/dist/src/views/scheduling/composables/schedule-add-employee-form.d.ts +1 -0
- package/dist/src/views/scheduling/composables/schedule-popover-position.d.ts +16 -0
- package/dist/src/views/scheduling/composables/useCollapsedList.d.ts +9 -0
- package/dist/src/views/scheduling/composables/useScheduleAddEmployee.d.ts +1 -0
- package/dist/src/views/scheduling/composables/useScheduleAddPick.d.ts +14 -7
- package/dist/src/views/scheduling/composables/useScheduleAssign.d.ts +11 -2
- package/dist/src/views/scheduling/composables/useScheduleAutoSchedule.d.ts +8 -0
- package/dist/src/views/scheduling/composables/useScheduleBoard.d.ts +11 -0
- package/dist/src/views/scheduling/composables/useScheduleDayTimeline.d.ts +0 -5
- package/dist/src/views/scheduling/composables/useScheduleDemand.d.ts +5 -3
- package/dist/src/views/scheduling/composables/useScheduleDemandSheet.d.ts +7 -1
- package/dist/src/views/scheduling/composables/useScheduleEmployeeMenu.d.ts +35 -0
- package/dist/src/views/scheduling/composables/useScheduleLeave.d.ts +53 -3
- package/dist/src/views/scheduling/composables/useScheduleOnboardingWizard.d.ts +1181 -55
- package/dist/src/views/scheduling/composables/useSchedulePositionModal.d.ts +50 -0
- package/dist/src/views/scheduling/composables/useSchedulePublish.d.ts +2 -0
- package/dist/src/views/scheduling/composables/useScheduleRangeCalendar.d.ts +10 -1
- package/dist/src/views/scheduling/composables/useScheduleRoster.d.ts +6 -0
- package/dist/src/views/scheduling/composables/useScheduleSetupBanner.d.ts +5 -5
- package/dist/src/views/scheduling/composables/useScheduleShiftActions.d.ts +6 -0
- package/dist/src/views/scheduling/composables/useScheduleShiftPopover.d.ts +7 -0
- package/dist/src/views/scheduling/composables/useScheduleTimePicker.d.ts +6 -1
- package/dist/src/views/scheduling/composables/useScheduleViewportFit.d.ts +9 -0
- package/dist/src/views/scheduling/data.d.ts +6 -1
- package/dist/src/views/scheduling/schedule-store.d.ts +11 -1
- package/dist/src/views/scheduling/types.d.ts +9 -1
- package/dist/style.css +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{useReportPermissions-Bu-l3ebR.js → useReportPermissions-5EhPvVT9.js} +3 -3
- package/package.json +1 -1
- package/dist/ScheduleGeneralPage-CgQOHHb8.js +0 -242
- package/dist/SchedulePage-C7q1IL70.js +0 -10761
- package/dist/SchedulePositionPage-Dys7X035.js +0 -220
- package/dist/ScheduleSelect.vue_vue_type_script_setup_true_lang-Cm2VWp8s.js +0 -201
- package/dist/useScheduleOutlet-BOmEn1hr.js +0 -546
- package/dist/useSchedulePositions-upgaNffa.js +0 -103
|
@@ -0,0 +1,293 @@
|
|
|
1
|
+
import { defineComponent as $, ref as D, onMounted as N, createElementBlock as l, openBlock as d, createElementVNode as i, createVNode as o, withCtx as r, toDisplayString as v, unref as e, createTextVNode as u, normalizeClass as g, createCommentVNode as E, withDirectives as b, withKeys as m, vModelText as h, Fragment as p, renderList as z, withModifiers as f } from "vue";
|
|
2
|
+
import { useRouter as M } from "vue-router";
|
|
3
|
+
import { R as x } from "./app-Dmmpy4k-.js";
|
|
4
|
+
import { z as A, B as S, D as P, _ as c } from "./ScheduleButton.vue_vue_type_script_setup_true_lang-DX5JR7bi.js";
|
|
5
|
+
import { u as V, a as B, _ as F } from "./ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-DrJ1vA88.js";
|
|
6
|
+
import { _ as I } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
7
|
+
const K = { class: "main" }, L = {
|
|
8
|
+
id: "viewPositions",
|
|
9
|
+
class: "view"
|
|
10
|
+
}, R = { class: "sp-head" }, U = { class: "sp-body" }, j = { class: "sp-content" }, T = { class: "sp-panel" }, W = { class: "cfg-head" }, q = { class: "cfg-count" }, H = { id: "skList" }, O = {
|
|
11
|
+
key: 0,
|
|
12
|
+
class: "cfg-empty"
|
|
13
|
+
}, G = {
|
|
14
|
+
key: 1,
|
|
15
|
+
class: "cfg-list"
|
|
16
|
+
}, J = {
|
|
17
|
+
key: 0,
|
|
18
|
+
class: "cfg-row"
|
|
19
|
+
}, Q = { class: "cfg-main" }, X = {
|
|
20
|
+
key: 0,
|
|
21
|
+
class: "cfg-row"
|
|
22
|
+
}, Y = { class: "cfg-main" }, Z = ["onKeyup"], ee = ["onClick"], se = { class: "cfg-main" }, te = { class: "cfg-name" }, ie = {
|
|
23
|
+
key: 0,
|
|
24
|
+
class: "cfg-confirm"
|
|
25
|
+
}, ne = { class: "q" }, oe = /* @__PURE__ */ $({
|
|
26
|
+
__name: "SchedulePositionPage",
|
|
27
|
+
setup(ae) {
|
|
28
|
+
const y = D(null);
|
|
29
|
+
A(y);
|
|
30
|
+
const C = M(), s = V(), _ = S(), k = B();
|
|
31
|
+
N(async () => {
|
|
32
|
+
await _.resolve() && await P(/* @__PURE__ */ new Date());
|
|
33
|
+
});
|
|
34
|
+
function w() {
|
|
35
|
+
C.push({ name: x.SCHEDULE });
|
|
36
|
+
}
|
|
37
|
+
return (le, t) => (d(), l("div", {
|
|
38
|
+
ref_key: "rootEl",
|
|
39
|
+
ref: y,
|
|
40
|
+
class: "sch"
|
|
41
|
+
}, [
|
|
42
|
+
i("div", K, [
|
|
43
|
+
i("div", L, [
|
|
44
|
+
i("div", R, [
|
|
45
|
+
o(c, {
|
|
46
|
+
hierarchy: "ghost",
|
|
47
|
+
size: "sm",
|
|
48
|
+
class: "sp-back",
|
|
49
|
+
type: "button",
|
|
50
|
+
onClick: w
|
|
51
|
+
}, {
|
|
52
|
+
default: r(() => [...t[10] || (t[10] = [
|
|
53
|
+
i("svg", {
|
|
54
|
+
width: "12",
|
|
55
|
+
height: "12",
|
|
56
|
+
viewBox: "0 0 16 16",
|
|
57
|
+
fill: "none",
|
|
58
|
+
"aria-hidden": "true"
|
|
59
|
+
}, [
|
|
60
|
+
i("path", {
|
|
61
|
+
d: "M10 3.5L5.5 8l4.5 4.5",
|
|
62
|
+
stroke: "currentColor",
|
|
63
|
+
"stroke-width": "1.7",
|
|
64
|
+
"stroke-linecap": "round",
|
|
65
|
+
"stroke-linejoin": "round"
|
|
66
|
+
})
|
|
67
|
+
], -1),
|
|
68
|
+
i("span", null, "Back to schedule", -1)
|
|
69
|
+
])]),
|
|
70
|
+
_: 1
|
|
71
|
+
}),
|
|
72
|
+
t[11] || (t[11] = i("div", { class: "sp-title" }, "Position", -1)),
|
|
73
|
+
t[12] || (t[12] = i("div", { class: "sp-sub" }, "What your staff can do — the same catalogue across every outlet.", -1))
|
|
74
|
+
]),
|
|
75
|
+
i("div", U, [
|
|
76
|
+
i("div", j, [
|
|
77
|
+
i("div", T, [
|
|
78
|
+
i("div", W, [
|
|
79
|
+
t[14] || (t[14] = i("div", { class: "cfg-title" }, "Configured positions", -1)),
|
|
80
|
+
i("span", q, v(e(s).count.value), 1),
|
|
81
|
+
t[15] || (t[15] = i("span", { class: "cfg-spacer" }, null, -1)),
|
|
82
|
+
o(c, {
|
|
83
|
+
hierarchy: "primary",
|
|
84
|
+
size: "sm",
|
|
85
|
+
class: "am-btn am-btn-primary",
|
|
86
|
+
type: "button",
|
|
87
|
+
onClick: t[0] || (t[0] = (n) => e(k).openNew())
|
|
88
|
+
}, {
|
|
89
|
+
default: r(() => [...t[13] || (t[13] = [
|
|
90
|
+
u(" + Add position ", -1)
|
|
91
|
+
])]),
|
|
92
|
+
_: 1
|
|
93
|
+
})
|
|
94
|
+
]),
|
|
95
|
+
i("div", {
|
|
96
|
+
class: g(["ce-err", { show: e(s).error.value }])
|
|
97
|
+
}, v(e(s).error.value), 3),
|
|
98
|
+
i("div", H, [
|
|
99
|
+
!e(s).positions.value.length && !e(s).isAdding.value ? (d(), l("div", O, [...t[16] || (t[16] = [
|
|
100
|
+
u(" No positions yet.", -1),
|
|
101
|
+
i("br", null, null, -1),
|
|
102
|
+
u(" Add one and it becomes assignable on every employee. ", -1)
|
|
103
|
+
])])) : (d(), l("div", G, [
|
|
104
|
+
e(s).isAdding.value ? (d(), l("div", J, [
|
|
105
|
+
i("div", Q, [
|
|
106
|
+
b(i("input", {
|
|
107
|
+
"onUpdate:modelValue": t[1] || (t[1] = (n) => e(s).newName.value = n),
|
|
108
|
+
type: "text",
|
|
109
|
+
class: "cfg-name-input",
|
|
110
|
+
placeholder: "New position name",
|
|
111
|
+
autofocus: "",
|
|
112
|
+
onKeyup: [
|
|
113
|
+
t[2] || (t[2] = m((n) => e(s).confirmAdd(), ["enter"])),
|
|
114
|
+
t[3] || (t[3] = m((n) => e(s).cancelAdd(), ["esc"]))
|
|
115
|
+
]
|
|
116
|
+
}, null, 544), [
|
|
117
|
+
[h, e(s).newName.value]
|
|
118
|
+
])
|
|
119
|
+
]),
|
|
120
|
+
o(c, {
|
|
121
|
+
hierarchy: "secondary",
|
|
122
|
+
size: "sm",
|
|
123
|
+
class: "cfg-btn",
|
|
124
|
+
type: "button",
|
|
125
|
+
disabled: !e(s).newName.value.trim() || e(s).saving.value,
|
|
126
|
+
onClick: t[4] || (t[4] = (n) => e(s).confirmAdd())
|
|
127
|
+
}, {
|
|
128
|
+
default: r(() => [
|
|
129
|
+
u(v(e(s).saving.value ? "Adding…" : "Add"), 1)
|
|
130
|
+
]),
|
|
131
|
+
_: 1
|
|
132
|
+
}, 8, ["disabled"]),
|
|
133
|
+
o(c, {
|
|
134
|
+
hierarchy: "secondary",
|
|
135
|
+
size: "sm",
|
|
136
|
+
class: "cfg-btn",
|
|
137
|
+
type: "button",
|
|
138
|
+
disabled: e(s).saving.value,
|
|
139
|
+
onClick: t[5] || (t[5] = (n) => e(s).cancelAdd())
|
|
140
|
+
}, {
|
|
141
|
+
default: r(() => [...t[17] || (t[17] = [
|
|
142
|
+
u(" Cancel ", -1)
|
|
143
|
+
])]),
|
|
144
|
+
_: 1
|
|
145
|
+
}, 8, ["disabled"])
|
|
146
|
+
])) : E("", !0),
|
|
147
|
+
(d(!0), l(p, null, z(e(s).positions.value, (n) => (d(), l(p, {
|
|
148
|
+
key: n.id
|
|
149
|
+
}, [
|
|
150
|
+
e(s).editingId.value === n.id ? (d(), l("div", X, [
|
|
151
|
+
i("div", Y, [
|
|
152
|
+
b(i("input", {
|
|
153
|
+
"onUpdate:modelValue": t[6] || (t[6] = (a) => e(s).editingName.value = a),
|
|
154
|
+
type: "text",
|
|
155
|
+
class: "cfg-name-input",
|
|
156
|
+
autofocus: "",
|
|
157
|
+
onKeyup: [
|
|
158
|
+
m((a) => e(s).saveEdit(n.id), ["enter"]),
|
|
159
|
+
t[7] || (t[7] = m((a) => e(s).cancelEdit(), ["esc"]))
|
|
160
|
+
]
|
|
161
|
+
}, null, 40, Z), [
|
|
162
|
+
[h, e(s).editingName.value]
|
|
163
|
+
])
|
|
164
|
+
]),
|
|
165
|
+
o(c, {
|
|
166
|
+
hierarchy: "secondary",
|
|
167
|
+
size: "sm",
|
|
168
|
+
class: "cfg-btn",
|
|
169
|
+
type: "button",
|
|
170
|
+
disabled: !e(s).editingName.value.trim() || e(s).saving.value,
|
|
171
|
+
onClick: (a) => e(s).saveEdit(n.id)
|
|
172
|
+
}, {
|
|
173
|
+
default: r(() => [
|
|
174
|
+
u(v(e(s).saving.value ? "Saving…" : "Save"), 1)
|
|
175
|
+
]),
|
|
176
|
+
_: 1
|
|
177
|
+
}, 8, ["disabled", "onClick"]),
|
|
178
|
+
o(c, {
|
|
179
|
+
hierarchy: "secondary",
|
|
180
|
+
size: "sm",
|
|
181
|
+
class: "cfg-btn",
|
|
182
|
+
type: "button",
|
|
183
|
+
disabled: e(s).saving.value,
|
|
184
|
+
onClick: t[8] || (t[8] = (a) => e(s).cancelEdit())
|
|
185
|
+
}, {
|
|
186
|
+
default: r(() => [...t[18] || (t[18] = [
|
|
187
|
+
u(" Cancel ", -1)
|
|
188
|
+
])]),
|
|
189
|
+
_: 1
|
|
190
|
+
}, 8, ["disabled"])
|
|
191
|
+
])) : (d(), l("div", {
|
|
192
|
+
key: 1,
|
|
193
|
+
class: g(["cfg-row", { "is-clickable": e(s).pendingDeleteId.value !== n.id }]),
|
|
194
|
+
onClick: (a) => e(s).pendingDeleteId.value !== n.id && e(s).startEdit(n.id)
|
|
195
|
+
}, [
|
|
196
|
+
i("div", se, [
|
|
197
|
+
i("div", te, v(n.name), 1)
|
|
198
|
+
]),
|
|
199
|
+
e(s).pendingDeleteId.value === n.id ? (d(), l("div", ie, [
|
|
200
|
+
i("span", ne, v(e(s).usageCountFor(n.name) ? `Remove from ${e(s).usageCountFor(n.name)} staff?` : "Delete?"), 1),
|
|
201
|
+
o(c, {
|
|
202
|
+
hierarchy: "danger",
|
|
203
|
+
size: "sm",
|
|
204
|
+
class: "cfg-yes",
|
|
205
|
+
type: "button",
|
|
206
|
+
disabled: e(s).saving.value,
|
|
207
|
+
onClick: f((a) => e(s).confirmDelete(n.id), ["stop"])
|
|
208
|
+
}, {
|
|
209
|
+
default: r(() => [
|
|
210
|
+
u(v(e(s).saving.value ? "Deleting…" : "Delete"), 1)
|
|
211
|
+
]),
|
|
212
|
+
_: 1
|
|
213
|
+
}, 8, ["disabled", "onClick"]),
|
|
214
|
+
o(c, {
|
|
215
|
+
hierarchy: "secondary",
|
|
216
|
+
size: "sm",
|
|
217
|
+
class: "cfg-no",
|
|
218
|
+
type: "button",
|
|
219
|
+
disabled: e(s).saving.value,
|
|
220
|
+
onClick: t[9] || (t[9] = f((a) => e(s).cancelDelete(), ["stop"]))
|
|
221
|
+
}, {
|
|
222
|
+
default: r(() => [...t[19] || (t[19] = [
|
|
223
|
+
u(" Keep ", -1)
|
|
224
|
+
])]),
|
|
225
|
+
_: 1
|
|
226
|
+
}, 8, ["disabled"])
|
|
227
|
+
])) : (d(), l(p, { key: 1 }, [
|
|
228
|
+
i("span", {
|
|
229
|
+
class: g(["cfg-used", { none: !e(s).usageCountFor(n.name) }])
|
|
230
|
+
}, v(e(s).usageCountFor(n.name) ? `${e(s).usageCountFor(n.name)} staff` : "unused"), 3),
|
|
231
|
+
o(c, {
|
|
232
|
+
hierarchy: "secondary",
|
|
233
|
+
size: "sm",
|
|
234
|
+
class: "cfg-btn",
|
|
235
|
+
type: "button",
|
|
236
|
+
onClick: f((a) => e(s).startEdit(n.id), ["stop"])
|
|
237
|
+
}, {
|
|
238
|
+
default: r(() => [...t[20] || (t[20] = [
|
|
239
|
+
u(" Edit ", -1)
|
|
240
|
+
])]),
|
|
241
|
+
_: 1
|
|
242
|
+
}, 8, ["onClick"]),
|
|
243
|
+
o(c, {
|
|
244
|
+
hierarchy: "ghost",
|
|
245
|
+
size: "sm",
|
|
246
|
+
"icon-only": "",
|
|
247
|
+
class: "cfg-del",
|
|
248
|
+
type: "button",
|
|
249
|
+
"aria-label": `Delete ${n.name}`,
|
|
250
|
+
onClick: f((a) => e(s).askDelete(n.id), ["stop"])
|
|
251
|
+
}, {
|
|
252
|
+
default: r(() => [...t[21] || (t[21] = [
|
|
253
|
+
i("svg", {
|
|
254
|
+
width: "14",
|
|
255
|
+
height: "14",
|
|
256
|
+
viewBox: "0 0 16 16",
|
|
257
|
+
fill: "none",
|
|
258
|
+
"aria-hidden": "true"
|
|
259
|
+
}, [
|
|
260
|
+
i("path", {
|
|
261
|
+
d: "M2.5 4.5h11M6 4.5V3a.8.8 0 0 1 .8-.8h2.4a.8.8 0 0 1 .8.8v1.5M4 4.5l.6 8.2a1 1 0 0 0 1 .93h4.8a1 1 0 0 0 1-.93l.6-8.2",
|
|
262
|
+
stroke: "currentColor",
|
|
263
|
+
"stroke-width": "1.4",
|
|
264
|
+
"stroke-linecap": "round",
|
|
265
|
+
"stroke-linejoin": "round"
|
|
266
|
+
}),
|
|
267
|
+
i("path", {
|
|
268
|
+
d: "M6.6 7v4M9.4 7v4",
|
|
269
|
+
stroke: "currentColor",
|
|
270
|
+
"stroke-width": "1.3",
|
|
271
|
+
"stroke-linecap": "round"
|
|
272
|
+
})
|
|
273
|
+
], -1)
|
|
274
|
+
])]),
|
|
275
|
+
_: 1
|
|
276
|
+
}, 8, ["aria-label", "onClick"])
|
|
277
|
+
], 64))
|
|
278
|
+
], 10, ee))
|
|
279
|
+
], 64))), 128))
|
|
280
|
+
]))
|
|
281
|
+
])
|
|
282
|
+
])
|
|
283
|
+
])
|
|
284
|
+
])
|
|
285
|
+
])
|
|
286
|
+
]),
|
|
287
|
+
o(F, { modal: e(k) }, null, 8, ["modal"])
|
|
288
|
+
], 512));
|
|
289
|
+
}
|
|
290
|
+
}), fe = /* @__PURE__ */ I(oe, [["__scopeId", "data-v-5285df68"]]);
|
|
291
|
+
export {
|
|
292
|
+
fe as default
|
|
293
|
+
};
|
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
import { defineComponent as Y, useAttrs as Z, computed as h, ref as m, watch as ee, nextTick as N, onBeforeUnmount as te, createElementBlock as a, openBlock as l, normalizeClass as C, createElementVNode as f, createBlock as ne, mergeProps as oe, toDisplayString as v, Teleport as le, createCommentVNode as g, withDirectives as ie, vModelText as ae, Fragment as D, renderList as se, createTextVNode as ue } from "vue";
|
|
2
|
+
const re = ["disabled", "aria-expanded"], ce = { class: "sch" }, de = {
|
|
3
|
+
key: 0,
|
|
4
|
+
class: "fx-pop-head"
|
|
5
|
+
}, fe = {
|
|
6
|
+
key: 1,
|
|
7
|
+
class: "fx-pop-search"
|
|
8
|
+
}, pe = {
|
|
9
|
+
key: 2,
|
|
10
|
+
class: "fx-opt is-off"
|
|
11
|
+
}, he = {
|
|
12
|
+
key: 0,
|
|
13
|
+
class: "fx-grp"
|
|
14
|
+
}, me = ["aria-selected", "onClick"], ve = {
|
|
15
|
+
key: 0,
|
|
16
|
+
class: "fx-opt-text"
|
|
17
|
+
}, ye = { key: 0 }, ke = /* @__PURE__ */ Y({
|
|
18
|
+
inheritAttrs: !1,
|
|
19
|
+
__name: "ScheduleSelect",
|
|
20
|
+
props: {
|
|
21
|
+
modelValue: {},
|
|
22
|
+
options: {},
|
|
23
|
+
disabled: { type: Boolean },
|
|
24
|
+
menuTitle: {},
|
|
25
|
+
searchable: { type: Boolean }
|
|
26
|
+
},
|
|
27
|
+
emits: ["update:modelValue"],
|
|
28
|
+
setup(c, { emit: z }) {
|
|
29
|
+
const i = c, L = z, P = Z(), U = h(() => P.class ?? ""), u = m(!1), $ = m(null), y = m(null), b = m(null), I = h(
|
|
30
|
+
() => {
|
|
31
|
+
var e;
|
|
32
|
+
return ((e = i.options.find((n) => n.value === i.modelValue)) == null ? void 0 : e.label) ?? "";
|
|
33
|
+
}
|
|
34
|
+
), B = h(() => !!i.menuTitle || i.options.some((e) => e.hint)), p = m(""), H = m(null), S = h(() => {
|
|
35
|
+
const e = p.value.trim().toLowerCase();
|
|
36
|
+
return !i.searchable || !e ? i.options : i.options.filter((n) => `${n.label} ${n.hint ?? ""}`.toLowerCase().includes(e));
|
|
37
|
+
}), T = h(() => {
|
|
38
|
+
const e = [];
|
|
39
|
+
let n;
|
|
40
|
+
for (const t of S.value)
|
|
41
|
+
t.group !== n && (n = t.group, n && e.push({ heading: n })), e.push({ option: t });
|
|
42
|
+
return e;
|
|
43
|
+
}), k = 5, r = 8;
|
|
44
|
+
function w() {
|
|
45
|
+
const e = b.value, n = y.value;
|
|
46
|
+
if (!e || !n) return;
|
|
47
|
+
const t = n.getBoundingClientRect(), o = window.innerWidth || document.documentElement.clientWidth, s = window.innerHeight || document.documentElement.clientHeight;
|
|
48
|
+
e.style.minWidth = `${Math.round(t.width)}px`, e.style.maxWidth = `${Math.max(180, Math.round(o - r * 2))}px`;
|
|
49
|
+
const x = s - t.bottom - k - r, J = t.top - k - r;
|
|
50
|
+
e.style.maxHeight = `${Math.max(120, Math.min(320, Math.max(x, J)))}px`;
|
|
51
|
+
const E = e.offsetHeight, Q = e.offsetWidth;
|
|
52
|
+
let V = t.bottom + k;
|
|
53
|
+
V + E > s - r && (V = t.top - k - E >= r ? t.top - k - E : Math.max(r, s - E - r));
|
|
54
|
+
const X = Math.min(Math.max(r, t.left), Math.max(r, o - Q - r));
|
|
55
|
+
e.style.top = `${Math.round(V)}px`, e.style.left = `${Math.round(X)}px`, e.style.visibility = "visible";
|
|
56
|
+
}
|
|
57
|
+
function _(e) {
|
|
58
|
+
var t, o;
|
|
59
|
+
const n = e.target;
|
|
60
|
+
n && ((t = $.value) != null && t.contains(n) || (o = b.value) != null && o.contains(n)) || d();
|
|
61
|
+
}
|
|
62
|
+
function A(e) {
|
|
63
|
+
const n = b.value, t = e.target;
|
|
64
|
+
if (n && t && t !== document && n.contains(t)) return;
|
|
65
|
+
const o = y.value;
|
|
66
|
+
if (!o) return;
|
|
67
|
+
const s = o.getBoundingClientRect(), x = window.innerHeight || document.documentElement.clientHeight;
|
|
68
|
+
if (s.bottom < 0 || s.top > x) {
|
|
69
|
+
d();
|
|
70
|
+
return;
|
|
71
|
+
}
|
|
72
|
+
w();
|
|
73
|
+
}
|
|
74
|
+
function R() {
|
|
75
|
+
document.addEventListener("click", _), document.addEventListener("scroll", A, !0), window.addEventListener("resize", d);
|
|
76
|
+
}
|
|
77
|
+
function W() {
|
|
78
|
+
document.removeEventListener("click", _), document.removeEventListener("scroll", A, !0), window.removeEventListener("resize", d);
|
|
79
|
+
}
|
|
80
|
+
async function M() {
|
|
81
|
+
var e, n, t;
|
|
82
|
+
i.disabled || u.value || (p.value = "", u.value = !0, await N(), w(), (e = H.value) == null || e.focus(), (t = (n = b.value) == null ? void 0 : n.querySelector(".fx-opt.is-on")) == null || t.scrollIntoView({ block: "nearest" }), R());
|
|
83
|
+
}
|
|
84
|
+
function d() {
|
|
85
|
+
u.value && (u.value = !1, p.value = "", W());
|
|
86
|
+
}
|
|
87
|
+
ee(p, async () => {
|
|
88
|
+
u.value && (await N(), w());
|
|
89
|
+
});
|
|
90
|
+
function j(e) {
|
|
91
|
+
var n;
|
|
92
|
+
if (e.key === "Escape")
|
|
93
|
+
e.preventDefault(), d(), (n = y.value) == null || n.focus();
|
|
94
|
+
else if (e.key === "Enter") {
|
|
95
|
+
e.preventDefault();
|
|
96
|
+
const t = S.value.find((o) => !o.disabled);
|
|
97
|
+
t && K(t);
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
function q() {
|
|
101
|
+
u.value ? d() : M();
|
|
102
|
+
}
|
|
103
|
+
function K(e) {
|
|
104
|
+
e.disabled || (d(), e.value !== i.modelValue && L("update:modelValue", e.value));
|
|
105
|
+
}
|
|
106
|
+
const F = h(() => i.options.filter((e) => !e.disabled));
|
|
107
|
+
function G(e) {
|
|
108
|
+
const n = F.value;
|
|
109
|
+
if (!n.length) {
|
|
110
|
+
M();
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
113
|
+
const t = n.findIndex((x) => x.value === i.modelValue), o = e === "Home" ? 0 : e === "End" ? n.length - 1 : e === "ArrowDown" ? Math.min(n.length - 1, (t < 0 ? -1 : t) + 1) : Math.max(0, (t < 0 ? 1 : t) - 1), s = n[o];
|
|
114
|
+
s && s.value !== i.modelValue ? L("update:modelValue", s.value) : M();
|
|
115
|
+
}
|
|
116
|
+
function O(e) {
|
|
117
|
+
var n;
|
|
118
|
+
if (e.key === "Escape") {
|
|
119
|
+
if (!u.value) return;
|
|
120
|
+
e.preventDefault(), d(), (n = y.value) == null || n.focus();
|
|
121
|
+
return;
|
|
122
|
+
}
|
|
123
|
+
if (e.key === "Enter" || e.key === " ") {
|
|
124
|
+
e.preventDefault(), q();
|
|
125
|
+
return;
|
|
126
|
+
}
|
|
127
|
+
e.key !== "ArrowDown" && e.key !== "ArrowUp" && e.key !== "Home" && e.key !== "End" || (e.preventDefault(), G(e.key));
|
|
128
|
+
}
|
|
129
|
+
return te(W), (e, n) => (l(), a("div", {
|
|
130
|
+
ref_key: "rootEl",
|
|
131
|
+
ref: $,
|
|
132
|
+
class: C(["fx-sel", U.value])
|
|
133
|
+
}, [
|
|
134
|
+
f("button", oe({
|
|
135
|
+
ref_key: "btnEl",
|
|
136
|
+
ref: y
|
|
137
|
+
}, e.$attrs, {
|
|
138
|
+
type: "button",
|
|
139
|
+
class: ["rebus-input fx-btn", { "is-open": u.value }],
|
|
140
|
+
disabled: c.disabled,
|
|
141
|
+
"aria-haspopup": "listbox",
|
|
142
|
+
"aria-expanded": u.value,
|
|
143
|
+
onClick: n[0] || (n[0] = (t) => q()),
|
|
144
|
+
onKeydown: O
|
|
145
|
+
}), v(I.value), 17, re),
|
|
146
|
+
(l(), ne(le, { to: "body" }, [
|
|
147
|
+
f("div", ce, [
|
|
148
|
+
u.value ? (l(), a("div", {
|
|
149
|
+
key: 0,
|
|
150
|
+
ref_key: "popEl",
|
|
151
|
+
ref: b,
|
|
152
|
+
class: C(["fx-pop", { "fx-pop-rich": B.value }]),
|
|
153
|
+
role: "listbox",
|
|
154
|
+
style: { visibility: "hidden" }
|
|
155
|
+
}, [
|
|
156
|
+
c.menuTitle ? (l(), a("div", de, v(c.menuTitle), 1)) : g("", !0),
|
|
157
|
+
c.searchable ? (l(), a("div", fe, [
|
|
158
|
+
ie(f("input", {
|
|
159
|
+
ref_key: "searchEl",
|
|
160
|
+
ref: H,
|
|
161
|
+
"onUpdate:modelValue": n[1] || (n[1] = (t) => p.value = t),
|
|
162
|
+
class: "rebus-input fx-pop-q",
|
|
163
|
+
type: "search",
|
|
164
|
+
placeholder: "Search",
|
|
165
|
+
autocomplete: "off",
|
|
166
|
+
spellcheck: "false",
|
|
167
|
+
"aria-label": "Search",
|
|
168
|
+
onKeydown: j
|
|
169
|
+
}, null, 544), [
|
|
170
|
+
[ae, p.value]
|
|
171
|
+
])
|
|
172
|
+
])) : g("", !0),
|
|
173
|
+
c.searchable && !T.value.length ? (l(), a("div", pe, "No matches")) : g("", !0),
|
|
174
|
+
(l(!0), a(D, null, se(T.value, (t, o) => (l(), a(D, { key: o }, [
|
|
175
|
+
"heading" in t ? (l(), a("div", he, v(t.heading), 1)) : (l(), a("div", {
|
|
176
|
+
key: 1,
|
|
177
|
+
class: C(["fx-opt", {
|
|
178
|
+
"is-on": t.option.value === c.modelValue,
|
|
179
|
+
"is-off": t.option.disabled,
|
|
180
|
+
"is-new": t.option.command
|
|
181
|
+
}]),
|
|
182
|
+
role: "option",
|
|
183
|
+
"aria-selected": t.option.value === c.modelValue,
|
|
184
|
+
onClick: (s) => K(t.option)
|
|
185
|
+
}, [
|
|
186
|
+
n[2] || (n[2] = f("span", {
|
|
187
|
+
class: "fx-tick",
|
|
188
|
+
"aria-hidden": "true"
|
|
189
|
+
}, [
|
|
190
|
+
f("svg", {
|
|
191
|
+
width: "11",
|
|
192
|
+
height: "11",
|
|
193
|
+
viewBox: "0 0 16 16",
|
|
194
|
+
fill: "none"
|
|
195
|
+
}, [
|
|
196
|
+
f("path", {
|
|
197
|
+
d: "m3.5 8.4 3 3 6-7",
|
|
198
|
+
stroke: "currentColor",
|
|
199
|
+
"stroke-width": "2.2",
|
|
200
|
+
"stroke-linecap": "round",
|
|
201
|
+
"stroke-linejoin": "round"
|
|
202
|
+
})
|
|
203
|
+
])
|
|
204
|
+
], -1)),
|
|
205
|
+
B.value ? (l(), a("span", ve, [
|
|
206
|
+
f("b", null, v(t.option.label), 1),
|
|
207
|
+
t.option.hint ? (l(), a("small", ye, v(t.option.hint), 1)) : g("", !0)
|
|
208
|
+
])) : (l(), a(D, { key: 1 }, [
|
|
209
|
+
ue(v(t.option.label), 1)
|
|
210
|
+
], 64))
|
|
211
|
+
], 10, me))
|
|
212
|
+
], 64))), 128))
|
|
213
|
+
], 2)) : g("", !0)
|
|
214
|
+
])
|
|
215
|
+
]))
|
|
216
|
+
], 2));
|
|
217
|
+
}
|
|
218
|
+
});
|
|
219
|
+
export {
|
|
220
|
+
ke as _
|
|
221
|
+
};
|
|
@@ -3,20 +3,20 @@ import { useI18n as Ve, useCoreStore as Ze } from "@feedmepos/mf-common";
|
|
|
3
3
|
import { useSnackbar as Le, useDialog as Qe, useBreakpoints as Ye, components as Oe } from "@feedmepos/ui-library";
|
|
4
4
|
import { u as ps } from "./useDebounce-B8ZPVS5C.js";
|
|
5
5
|
import { S as ye } from "./SelectFilter-CG13h83-.js";
|
|
6
|
-
import { v as Te, m as vs, O as fs, _ as bs, a as hs } from "./app-
|
|
6
|
+
import { v as Te, m as vs, O as fs, _ as bs, a as hs } from "./app-Dmmpy4k-.js";
|
|
7
7
|
import { u as ys, _ as gs } from "./useDiscardConfirm-DPhEV6v0.js";
|
|
8
8
|
import { _ as _s } from "./TableEmptyState.vue_vue_type_script_setup_true_lang-IfAZmWr0.js";
|
|
9
9
|
import { s as Us, _ as Ss, a as xs, b as Fs, c as Ps } from "./PasscodePinField.vue_vue_type_script_setup_true_lang-CqG0v0Sz.js";
|
|
10
10
|
import { u as He } from "./useLoading-CXzTpIVv.js";
|
|
11
11
|
import { n as es } from "./string-VNuQNweN.js";
|
|
12
|
-
import { l as Pe } from "./lodash-
|
|
13
|
-
import "./index-
|
|
14
|
-
import { t as _e, u as ss, c as Ae, b as qe, m as $e, d as ts, p as Ge, i as Is, j as Ke, k as ws, l as Vs, n as ks, o as Rs, q as Cs } from "./rule-
|
|
15
|
-
import { u as as } from "./role-
|
|
12
|
+
import { l as Pe } from "./lodash-p40sRkqQ.js";
|
|
13
|
+
import "./index-BxkisKEs.js";
|
|
14
|
+
import { t as _e, u as ss, c as Ae, b as qe, m as $e, d as ts, p as Ge, i as Is, j as Ke, k as ws, l as Vs, n as ks, o as Rs, q as Cs } from "./rule-BPApyMJY.js";
|
|
15
|
+
import { u as as } from "./role-CM1urkJZ.js";
|
|
16
16
|
import { u as ls, i as $s } from "./PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-XHuHin8t.js";
|
|
17
17
|
import "./useAppStore-DCwd8GWN.js";
|
|
18
18
|
import { g as ze, b as We, u as os } from "./restaurant-BTpBmfBV.js";
|
|
19
|
-
import { _ as Ms } from "./PortalPermissionEditor.vue_vue_type_script_setup_true_lang-
|
|
19
|
+
import { _ as Ms } from "./PortalPermissionEditor.vue_vue_type_script_setup_true_lang-DK2Bx8Aw.js";
|
|
20
20
|
import { _ as Ns } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
21
21
|
import { c as he } from "./iteration-CcXrOMQe.js";
|
|
22
22
|
var Ue = /* @__PURE__ */ ((o) => (o.Update = "Update", o.Remove = "Remove", o))(Ue || {});
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import { ref as d, computed as g, defineComponent as pe, onMounted as fe, watch as Z, resolveComponent as u, createElementBlock as P, openBlock as E, Fragment as ee, createVNode as l, createElementVNode as i, unref as r, withCtx as b, createCommentVNode as ve, toDisplayString as O, createTextVNode as he, isRef as ge, renderList as we, createBlock as te, nextTick as ye } from "vue";
|
|
2
|
-
import { d as v } from "./dayjs.min-
|
|
2
|
+
import { d as v } from "./dayjs.min-DcfKURXN.js";
|
|
3
3
|
import { useI18n as _e } from "@feedmepos/mf-common";
|
|
4
4
|
import { useSnackbar as be, components as xe } from "@feedmepos/ui-library";
|
|
5
5
|
import { S as De } from "./SelectFilter-CG13h83-.js";
|
|
6
|
-
import { _ as Se } from "./app-
|
|
6
|
+
import { _ as Se } from "./app-Dmmpy4k-.js";
|
|
7
7
|
import { _ as Ve } from "./TableEmptyState.vue_vue_type_script_setup_true_lang-IfAZmWr0.js";
|
|
8
8
|
import { u as ke } from "./useLoading-CXzTpIVv.js";
|
|
9
9
|
import { g as Ce, s as Fe } from "./iteration-CcXrOMQe.js";
|
|
10
10
|
import { f as Ye } from "./utils-BZkjJbju.js";
|
|
11
11
|
import { n as Le } from "./string-VNuQNweN.js";
|
|
12
|
-
import { u as Me } from "./employee-
|
|
12
|
+
import { u as Me } from "./employee-D3ZpYH4j.js";
|
|
13
13
|
import { u as Te } from "./restaurant-BTpBmfBV.js";
|
|
14
|
-
import { u as Ie } from "./TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-
|
|
14
|
+
import { u as Ie } from "./TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-BfMkNvCz.js";
|
|
15
15
|
import { _ as Re } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
16
16
|
function $e(x, a) {
|
|
17
17
|
return ["years", "months"].find((S) => {
|