@feedmepos/mf-hrm-portal 2.4.2-dev → 2.4.2

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.
Files changed (112) hide show
  1. package/dist/{ApprovalCodeList-DpNF0wL7.js → ApprovalCodeList-DGLPcQcv.js} +15 -14
  2. package/dist/{AuditLogList-D2bUFsuK.js → AuditLogList-ahJwTF7N.js} +12 -12
  3. package/dist/ConditionBuilderForm.vue_vue_type_script_setup_true_lang-IPkyxwIF.js +438 -0
  4. package/dist/EmployeeList-B18mlY4V.js +776 -0
  5. package/dist/FormItem.vue_vue_type_script_setup_true_lang-Dvo9AiKf.js +45 -0
  6. package/dist/FormSection.vue_vue_type_script_setup_true_lang-DknXTYiK.js +49 -0
  7. package/dist/{GrantUserList-ClliuQ8h.js → GrantUserList-C8BbP99C.js} +16 -15
  8. package/dist/{Main-CBuOW87D.js → Main-BA29_N_p.js} +2280 -2274
  9. package/dist/{Main-DlPdGefL.js → Main-BN3b_yie.js} +5 -5
  10. package/dist/Main-Clux_qKN.js +96 -0
  11. package/dist/PasscodePinField.vue_vue_type_script_setup_true_lang-CqG0v0Sz.js +243 -0
  12. package/dist/{PermissionSetList-Dd0fkW0L.js → PermissionSetList-BSOJ8ftd.js} +108 -107
  13. package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-Hz_rFmbH.js +4181 -0
  14. package/dist/PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-BwuBk683.js +35 -0
  15. package/dist/RoleList-EnfxydGa.js +740 -0
  16. package/dist/{ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-yJwTtFyF.js → ScheduleAddPositionModal.vue_vue_type_script_setup_true_lang-yIdd8r7y.js} +1 -1
  17. package/dist/{ScheduleGeneralPage-_cqIJY8R.js → ScheduleGeneralPage-CFUqm5-r.js} +2 -2
  18. package/dist/{ScheduleModal.vue_vue_type_script_setup_true_lang-C6M76KUA.js → ScheduleModal.vue_vue_type_script_setup_true_lang-BmPrGRG2.js} +186 -187
  19. package/dist/{SchedulePage-DHkWe1KO.js → SchedulePage-DEFQwipO.js} +16 -16
  20. package/dist/{SchedulePositionPage-5JUJwlJc.js → SchedulePositionPage-CM5NS5-F.js} +3 -3
  21. package/dist/{SelectFilter-DWRvb1Yl.js → SelectFilter-DgjR5o5E.js} +1 -1
  22. package/dist/TeamMemberList-BKvhHLNG.js +1150 -0
  23. package/dist/TimesheetList-EQRMimP7.js +402 -0
  24. package/dist/{TimesheetList.vue_vue_type_style_index_0_scoped_ffd7f807_lang-Co2GtU1N.js → TimesheetList.vue_vue_type_style_index_0_scoped_63294af2_lang-BumkwWvb.js} +7 -7
  25. package/dist/{app-BA3UHSk0.js → app-Bkc0pF3P.js} +3935 -7718
  26. package/dist/app.js +3 -3
  27. package/dist/{approval-code-BR4FD3sx.js → approval-code-BKMu1GDn.js} +1 -1
  28. package/dist/{dayjs.min-JyaQ6PUU.js → dayjs.min-CkI2q2aC.js} +34 -34
  29. package/dist/employee-BfkxCdPL.js +209 -0
  30. package/dist/{grant-user-DKUZdzrY.js → grant-user-ClN_vTOv.js} +1 -1
  31. package/dist/{index-CkC2sfPK.js → iteration-CsNIceUp.js} +558 -573
  32. package/dist/{lodash-BJMVlo9i.js → lodash-BgraJgCc.js} +1 -1
  33. package/dist/restaurant-CRNgiIa4.js +2685 -0
  34. package/dist/role-CZYSdVn2.js +91 -0
  35. package/dist/rule-_4roLZrG.js +780 -0
  36. package/dist/src/components/CollapsibleWrapper.vue.d.ts +3 -11
  37. package/dist/src/helpers/iteration.d.ts +2 -9
  38. package/dist/src/helpers/permission-set.d.ts +102 -1
  39. package/dist/src/helpers/rule.d.ts +2 -2
  40. package/dist/src/helpers/string.d.ts +1 -10
  41. package/dist/src/router/shared.d.ts +1 -3
  42. package/dist/src/stores/restaurant.d.ts +7 -7
  43. package/dist/src/stores/team.d.ts +0 -30
  44. package/dist/src/types/team.d.ts +1 -17
  45. package/dist/src/views/audit-log/locales/index.d.ts +0 -12
  46. package/dist/src/views/hr/locales/index.d.ts +0 -20
  47. package/dist/src/views/hr/role/RoleForm.vue.d.ts +2 -29
  48. package/dist/src/views/scheduling/composables/useScheduleOnboardingAvailability.d.ts +1 -1
  49. package/dist/src/views/scheduling/composables/useScheduleOnboardingWizard.d.ts +1 -1
  50. package/dist/src/views/scheduling/composables/useScheduleShiftDraft.d.ts +1 -1
  51. package/dist/src/views/scheduling/composables/useScheduleShiftPopover.d.ts +1 -1
  52. package/dist/src/views/team/components/BasePermission.vue.d.ts +0 -11
  53. package/dist/src/views/team/components/ConditionPermission.vue.d.ts +0 -11
  54. package/dist/src/views/team/components/PortalPermissionEditor.vue.d.ts +0 -21
  55. package/dist/src/views/team/components/PosRolePermission.vue.d.ts +0 -11
  56. package/dist/src/views/team/locales/index.d.ts +4 -716
  57. package/dist/src/views/team/member/AddMemberForm.vue.d.ts +3 -48
  58. package/dist/src/views/team/{components/MemberStatusBadge.vue.d.ts → member/MemberInfo.vue.d.ts} +2 -2
  59. package/dist/src/views/team/member/TeamMemberList.vue.d.ts +0 -1
  60. package/dist/string-VNuQNweN.js +15 -0
  61. package/dist/style.css +1 -1
  62. package/dist/tsconfig.app.tsbuildinfo +1 -1
  63. package/dist/{useAppStore-DiGaOhje.js → useAppStore-DYmF1kgk.js} +1 -1
  64. package/dist/{useLoading-DOcoObCD.js → useLoading-C2UKuAxD.js} +1 -1
  65. package/dist/{useReportPermissions-c9KGuXQq.js → useReportPermissions-BiaXRc0p.js} +22 -22
  66. package/package.json +2 -2
  67. package/dist/ConditionBuilderForm.vue_vue_type_script_setup_true_lang-BjEJErcL.js +0 -459
  68. package/dist/EmployeeList-CBYU0R2j.js +0 -896
  69. package/dist/FormSection.vue_vue_type_script_setup_true_lang-DsPLbLwQ.js +0 -90
  70. package/dist/Main-D9MQo2l1.js +0 -101
  71. package/dist/MyPosProfile-IAPSqlBP.js +0 -360
  72. package/dist/PasscodePinField.vue_vue_type_script_setup_true_lang-TXPEqa46.js +0 -126
  73. package/dist/PortalPermissionEditor.vue_vue_type_script_setup_true_lang-CjQCbJRu.js +0 -4212
  74. package/dist/PortalUserSearcher.vue_vue_type_style_index_0_scoped_827dfd60_lang-DJnIFlKq.js +0 -1797
  75. package/dist/RoleForm.vue_vue_type_script_setup_true_lang-hE2OZwfO.js +0 -547
  76. package/dist/RoleList-zZHpt079.js +0 -274
  77. package/dist/TeamMemberList-C_4f5Djs.js +0 -2082
  78. package/dist/TimesheetList-B3Yx8cwt.js +0 -408
  79. package/dist/employee-n31b7QEp.js +0 -237
  80. package/dist/member-grant-B1V9g0Sb.js +0 -54
  81. package/dist/restaurant-BbSg6yOm.js +0 -49
  82. package/dist/role-iTqgtFqf.js +0 -91
  83. package/dist/rule-BJhti6BZ.js +0 -845
  84. package/dist/src/api/my-pos-profile/index.d.ts +0 -3
  85. package/dist/src/api/sso-provider/index.d.ts +0 -5
  86. package/dist/src/api/staff-invite/index.d.ts +0 -16
  87. package/dist/src/components/form/SegmentedTabs.vue.d.ts +0 -23
  88. package/dist/src/composables/useMenuAccess.d.ts +0 -56
  89. package/dist/src/composables/useSsoProviders.d.ts +0 -19
  90. package/dist/src/composables/useStaffInviteProviders.d.ts +0 -8
  91. package/dist/src/helpers/employee-merge.d.ts +0 -33
  92. package/dist/src/helpers/member-grant.d.ts +0 -36
  93. package/dist/src/helpers/my-pos-profile.d.ts +0 -37
  94. package/dist/src/helpers/pos-assignment-rows.d.ts +0 -28
  95. package/dist/src/helpers/restaurant-lookup.d.ts +0 -19
  96. package/dist/src/helpers/role-merge.d.ts +0 -11
  97. package/dist/src/helpers/staff-invite.d.ts +0 -54
  98. package/dist/src/router/menu-access-guard.d.ts +0 -17
  99. package/dist/src/types/my-pos-profile.d.ts +0 -24
  100. package/dist/src/types/sso-provider.d.ts +0 -10
  101. package/dist/src/types/staff-invite.d.ts +0 -100
  102. package/dist/src/views/hr/timesheet/timesheet-view.d.ts +0 -29
  103. package/dist/src/views/my-pos-profile/MyPosProfile.vue.d.ts +0 -2
  104. package/dist/src/views/my-pos-profile/components/PasscodeChangedDialog.vue.d.ts +0 -4
  105. package/dist/src/views/my-pos-profile/locales/index.d.ts +0 -236
  106. package/dist/src/views/team/components/MemberGrantFields.vue.d.ts +0 -51
  107. package/dist/src/views/team/components/PosAssignmentRows.vue.d.ts +0 -44
  108. package/dist/src/views/team/member/ExistingMemberNotice.vue.d.ts +0 -11
  109. package/dist/src/views/team/member/MemberDetailsCard.vue.d.ts +0 -35
  110. package/dist/src/views/team/member/MemberHeaderCard.vue.d.ts +0 -19
  111. package/dist/string-DZQ1uNjn.js +0 -22
  112. package/dist/useSsoProviders-CkhHtzRQ.js +0 -41
@@ -1,236 +0,0 @@
1
- import * as enUS from './en-US.json';
2
- export type AppMessagesSchema = typeof enUS;
3
- export declare const i18nMessages: {
4
- 'en-US': {
5
- myPosProfile: {
6
- title: string;
7
- subtitle: string;
8
- table: {
9
- columns: {
10
- name: string;
11
- contact: string;
12
- restaurant: string;
13
- role: string;
14
- };
15
- };
16
- passcode: {
17
- title: string;
18
- updated: string;
19
- updatedJustNow: string;
20
- show: string;
21
- hide: string;
22
- change: string;
23
- empty: string;
24
- emptyHint: string;
25
- generate: string;
26
- };
27
- change: {
28
- title: string;
29
- message: string;
30
- failed: string;
31
- exhausted: string;
32
- inProgress: string;
33
- incomplete: string;
34
- };
35
- generate: {
36
- failed: string;
37
- };
38
- changed: {
39
- title: string;
40
- message: string;
41
- done: string;
42
- };
43
- generated: {
44
- title: string;
45
- message: string;
46
- };
47
- manageAccount: {
48
- message: string;
49
- link: string;
50
- failed: string;
51
- };
52
- noPosUser: {
53
- title: string;
54
- description: string;
55
- };
56
- loadFailed: string;
57
- shared: {
58
- message: string;
59
- };
60
- };
61
- };
62
- 'zh-CN': {
63
- myPosProfile: {
64
- title: string;
65
- subtitle: string;
66
- table: {
67
- columns: {
68
- name: string;
69
- contact: string;
70
- restaurant: string;
71
- role: string;
72
- };
73
- };
74
- passcode: {
75
- title: string;
76
- updated: string;
77
- updatedJustNow: string;
78
- show: string;
79
- hide: string;
80
- change: string;
81
- empty: string;
82
- emptyHint: string;
83
- generate: string;
84
- };
85
- change: {
86
- title: string;
87
- message: string;
88
- failed: string;
89
- exhausted: string;
90
- inProgress: string;
91
- incomplete: string;
92
- };
93
- generate: {
94
- failed: string;
95
- };
96
- changed: {
97
- title: string;
98
- message: string;
99
- done: string;
100
- };
101
- generated: {
102
- title: string;
103
- message: string;
104
- };
105
- manageAccount: {
106
- message: string;
107
- link: string;
108
- failed: string;
109
- };
110
- noPosUser: {
111
- title: string;
112
- description: string;
113
- };
114
- loadFailed: string;
115
- shared: {
116
- message: string;
117
- };
118
- };
119
- };
120
- 'th-TH': {
121
- myPosProfile: {
122
- title: string;
123
- subtitle: string;
124
- table: {
125
- columns: {
126
- name: string;
127
- contact: string;
128
- restaurant: string;
129
- role: string;
130
- };
131
- };
132
- passcode: {
133
- title: string;
134
- updated: string;
135
- updatedJustNow: string;
136
- show: string;
137
- hide: string;
138
- change: string;
139
- empty: string;
140
- emptyHint: string;
141
- generate: string;
142
- };
143
- change: {
144
- title: string;
145
- message: string;
146
- failed: string;
147
- exhausted: string;
148
- inProgress: string;
149
- incomplete: string;
150
- };
151
- generate: {
152
- failed: string;
153
- };
154
- changed: {
155
- title: string;
156
- message: string;
157
- done: string;
158
- };
159
- generated: {
160
- title: string;
161
- message: string;
162
- };
163
- manageAccount: {
164
- message: string;
165
- link: string;
166
- failed: string;
167
- };
168
- noPosUser: {
169
- title: string;
170
- description: string;
171
- };
172
- loadFailed: string;
173
- shared: {
174
- message: string;
175
- };
176
- };
177
- };
178
- 'zh-Hant': {
179
- myPosProfile: {
180
- title: string;
181
- subtitle: string;
182
- table: {
183
- columns: {
184
- name: string;
185
- contact: string;
186
- restaurant: string;
187
- role: string;
188
- };
189
- };
190
- passcode: {
191
- title: string;
192
- updated: string;
193
- updatedJustNow: string;
194
- show: string;
195
- hide: string;
196
- change: string;
197
- empty: string;
198
- emptyHint: string;
199
- generate: string;
200
- };
201
- change: {
202
- title: string;
203
- message: string;
204
- failed: string;
205
- exhausted: string;
206
- inProgress: string;
207
- incomplete: string;
208
- };
209
- generate: {
210
- failed: string;
211
- };
212
- changed: {
213
- title: string;
214
- message: string;
215
- done: string;
216
- };
217
- generated: {
218
- title: string;
219
- message: string;
220
- };
221
- manageAccount: {
222
- message: string;
223
- link: string;
224
- failed: string;
225
- };
226
- noPosUser: {
227
- title: string;
228
- description: string;
229
- };
230
- loadFailed: string;
231
- shared: {
232
- message: string;
233
- };
234
- };
235
- };
236
- };
@@ -1,51 +0,0 @@
1
- import type { RawRule } from '@casl/ability';
2
- import { type PropType } from 'vue';
3
- import { FdoPermissionRule } from '@feedmepos/core/entity';
4
- import { type MemberGrantPayload } from '@/helpers/member-grant';
5
- import { type IFdtoPermissionPosUser } from '@/types/team';
6
- /** The saved grant being edited. A new `id` resets the form. */
7
- export interface MemberGrantInitialValue {
8
- id: string;
9
- isOwner?: boolean;
10
- name: string;
11
- permissions: RawRule[] | FdoPermissionRule[];
12
- permissionSetIds: string[];
13
- posUser?: IFdtoPermissionPosUser;
14
- posUserId?: string;
15
- }
16
- declare function isModified(): boolean;
17
- declare function readGrantData(): MemberGrantPayload;
18
- declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
19
- initialValue: {
20
- type: PropType<MemberGrantInitialValue | null>;
21
- };
22
- /** Name to fall back on when neither the saved grant nor the POS user has one. */
23
- fallbackName: {
24
- type: StringConstructor;
25
- default: string;
26
- };
27
- loading: {
28
- type: BooleanConstructor;
29
- default: boolean;
30
- };
31
- }>, {
32
- readGrantData: typeof readGrantData;
33
- isModified: typeof isModified;
34
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
35
- initialValue: {
36
- type: PropType<MemberGrantInitialValue | null>;
37
- };
38
- /** Name to fall back on when neither the saved grant nor the POS user has one. */
39
- fallbackName: {
40
- type: StringConstructor;
41
- default: string;
42
- };
43
- loading: {
44
- type: BooleanConstructor;
45
- default: boolean;
46
- };
47
- }>> & Readonly<{}>, {
48
- loading: boolean;
49
- fallbackName: string;
50
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
51
- export default _default;
@@ -1,44 +0,0 @@
1
- import { type PropType } from 'vue';
2
- import type { HrmRestaurant } from '@/types/restaurant';
3
- import type { Role } from '@/types/role';
4
- import type { IFdtoPermissionPosUserRole } from '@/types/team';
5
- declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
6
- modelValue: {
7
- type: PropType<IFdtoPermissionPosUserRole[]>;
8
- required: true;
9
- };
10
- restaurants: {
11
- type: PropType<HrmRestaurant[]>;
12
- required: true;
13
- };
14
- roles: {
15
- type: PropType<Role[]>;
16
- required: true;
17
- };
18
- isRoleUsable: {
19
- type: PropType<(role: Role) => boolean>;
20
- required: true;
21
- };
22
- }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
23
- "update:modelValue": (roles: IFdtoPermissionPosUserRole[]) => any;
24
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
25
- modelValue: {
26
- type: PropType<IFdtoPermissionPosUserRole[]>;
27
- required: true;
28
- };
29
- restaurants: {
30
- type: PropType<HrmRestaurant[]>;
31
- required: true;
32
- };
33
- roles: {
34
- type: PropType<Role[]>;
35
- required: true;
36
- };
37
- isRoleUsable: {
38
- type: PropType<(role: Role) => boolean>;
39
- required: true;
40
- };
41
- }>> & Readonly<{
42
- "onUpdate:modelValue"?: ((roles: IFdtoPermissionPosUserRole[]) => any) | undefined;
43
- }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
44
- export default _default;
@@ -1,11 +0,0 @@
1
- import type { IFdtoStaffInviteLookup, StaffInviteMatch } from '@/types/staff-invite';
2
- type __VLS_Props = {
3
- existing: IFdtoStaffInviteLookup;
4
- match: StaffInviteMatch;
5
- };
6
- declare const _default: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
7
- update: () => any;
8
- }, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{
9
- onUpdate?: (() => any) | undefined;
10
- }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
11
- export default _default;
@@ -1,35 +0,0 @@
1
- import { type PropType } from 'vue';
2
- import type { IFdtoStaffInviteLookup, IFdtoStaffInviteProvider, StaffInviteMatch } from '@/types/staff-invite';
3
- /** What the Member details card contributes to an invite. */
4
- export interface MemberDetails {
5
- provider: string;
6
- match: StaffInviteMatch;
7
- mobile?: string;
8
- email?: string;
9
- displayName: string;
10
- employeeId?: string;
11
- }
12
- declare function readDetails(): MemberDetails;
13
- declare function isModified(): boolean;
14
- declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
15
- providers: {
16
- type: PropType<IFdtoStaffInviteProvider[]>;
17
- required: true;
18
- };
19
- }>, {
20
- readDetails: typeof readDetails;
21
- isModified: typeof isModified;
22
- /** Add is blocked while the key belongs to someone already. */
23
- hasExisting: import("vue").ComputedRef<boolean>;
24
- providerLabel: import("vue").ComputedRef<string>;
25
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
26
- "update-existing": (existing: IFdtoStaffInviteLookup) => any;
27
- }, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
28
- providers: {
29
- type: PropType<IFdtoStaffInviteProvider[]>;
30
- required: true;
31
- };
32
- }>> & Readonly<{
33
- "onUpdate-existing"?: ((existing: IFdtoStaffInviteLookup) => any) | undefined;
34
- }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
35
- export default _default;
@@ -1,19 +0,0 @@
1
- import type { TeamMemberStatus } from '@/types/team';
2
- type __VLS_Props = {
3
- name: string;
4
- status: TeamMemberStatus;
5
- email?: string;
6
- phoneNumber?: string;
7
- };
8
- declare var __VLS_4: {};
9
- type __VLS_Slots = {} & {
10
- default?: (props: typeof __VLS_4) => any;
11
- };
12
- declare const __VLS_component: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<__VLS_Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
13
- declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
14
- export default _default;
15
- type __VLS_WithSlots<T, S> = T & {
16
- new (): {
17
- $slots: S;
18
- };
19
- };
@@ -1,22 +0,0 @@
1
- function a(r, t) {
2
- let n = "", e = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
3
- const l = e.length;
4
- for (let i = 0; i < r; i++)
5
- n += e.charAt(Math.floor(Math.random() * l));
6
- return n;
7
- }
8
- function c(r, t, n = 2) {
9
- if (r === null) return t.all;
10
- if (r.length === 0) return t.none;
11
- const e = r.slice(0, n).join(", ");
12
- return r.length > n ? `${e} ${t.more(r.length - n)}` : e;
13
- }
14
- function o(r) {
15
- const t = (r ?? "").trim().split(/\s+/).filter(Boolean);
16
- return t.length === 0 ? "" : t.length === 1 ? t[0].slice(0, 2) : t[0].charAt(0) + t[1].charAt(0);
17
- }
18
- export {
19
- o as n,
20
- a as r,
21
- c as s
22
- };
@@ -1,41 +0,0 @@
1
- import { computed as v, ref as u } from "vue";
2
- import { useCoreStore as f } from "@feedmepos/mf-common";
3
- import { g as p, b as m } from "./app-BA3UHSk0.js";
4
- const P = {
5
- async readProviders() {
6
- return p(await m("sso-providers").get(""));
7
- }
8
- }, n = u([]), t = u(null);
9
- let s = null;
10
- function g() {
11
- const i = f();
12
- async function a() {
13
- var r, o;
14
- const e = (r = i.currentBusiness.value) == null ? void 0 : r.id;
15
- if (!(!e || s === e)) {
16
- s = e, n.value = [], t.value = null;
17
- try {
18
- const c = await P.readProviders();
19
- s === e && (n.value = c);
20
- } catch {
21
- s === e && (s = null);
22
- } finally {
23
- ((o = i.currentBusiness.value) == null ? void 0 : o.id) === e && (t.value = e);
24
- }
25
- }
26
- }
27
- const l = v(
28
- () => {
29
- var e;
30
- return !!t.value && t.value === ((e = i.currentBusiness.value) == null ? void 0 : e.id);
31
- }
32
- );
33
- function d(e) {
34
- var r;
35
- return ((r = n.value.find((o) => o.slug === e)) == null ? void 0 : r.label) ?? e;
36
- }
37
- return { providers: n, isLoaded: l, loadProviders: a, providerLabel: d };
38
- }
39
- export {
40
- g as u
41
- };