@webx-ui/module-tariffs 0.1.16 → 0.2.1
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/TariffsPage-Trs7f5Rf.js +330 -0
- package/dist/TariffsPage-Trs7f5Rf.js.map +1 -0
- package/dist/index-Cg_PgXDL.js +384 -0
- package/dist/index-Cg_PgXDL.js.map +1 -0
- package/dist/index.d.ts +7 -1
- package/dist/index.js +10 -691
- package/dist/index.js.map +1 -1
- package/package.json +4 -4
|
@@ -0,0 +1,330 @@
|
|
|
1
|
+
import { defineComponent as le, ref as z, computed as n, watch as O, onBeforeUnmount as ie, openBlock as i, createBlock as f, unref as r, withCtx as s, createVNode as c, createCommentVNode as p, createElementVNode as _, createElementBlock as T, normalizeClass as B, createTextVNode as L, toDisplayString as g, Fragment as j, resolveDynamicComponent as oe, renderList as ne } from "vue";
|
|
2
|
+
import { useRoute as se, useRouter as ue } from "vue-router";
|
|
3
|
+
import { WxCard as fe, WxListDetail as ce, WxEmpty as G, WxInput as de, WxIcon as R, WxSelect as ve, WxSkeleton as pe, WxSortableList as me, WxBadge as H, WxAlert as ye, toast as b, confirm as we } from "@webx-ui/core";
|
|
4
|
+
import { useAdmin as _e, useTranslate as ge, useErrorText as be, useItemOrder as xe, WxListScreen as he, WxRowMenu as ke } from "@webx-ui/module-admin";
|
|
5
|
+
import { c as qe, u as Te, T as We, a as Se, p as Ve, _ as Ce } from "./index-Cg_PgXDL.js";
|
|
6
|
+
const ze = { class: "wx-tariffs__bar" }, Be = { class: "wx-tariff-row__body" }, Ie = { class: "wx-tariff-row__who" }, Ne = { class: "wx-tariff-row__name" }, Ue = ["aria-label"], Ae = { class: "wx-tariff-row__facts" }, Le = {
|
|
7
|
+
key: 1,
|
|
8
|
+
class: "wx-tariff-row__badge"
|
|
9
|
+
}, Re = /* @__PURE__ */ le({
|
|
10
|
+
__name: "TariffsPage",
|
|
11
|
+
props: {
|
|
12
|
+
base: { default: "/tariffs" }
|
|
13
|
+
},
|
|
14
|
+
setup(Ee) {
|
|
15
|
+
const W = _e(), I = qe(W), u = se(), x = ue();
|
|
16
|
+
Te();
|
|
17
|
+
const t = ge("webx-tariffs"), S = be(), m = z([]), E = z([]), V = z(!0), y = n(() => W.can("tariffs.manage")), J = n(
|
|
18
|
+
() => W.state.manifest?.modules.find((e) => e.id === "tariffs")?.title ?? t("module.tariffs")
|
|
19
|
+
), C = n({
|
|
20
|
+
get: () => u.query.view === "trashed" ? "trashed" : "",
|
|
21
|
+
set: (e) => {
|
|
22
|
+
const l = {
|
|
23
|
+
...u.query,
|
|
24
|
+
view: e === "" ? void 0 : String(e)
|
|
25
|
+
};
|
|
26
|
+
delete l.tariff, x.replace({ query: l });
|
|
27
|
+
}
|
|
28
|
+
}), o = n(() => C.value === "trashed"), h = n(() => {
|
|
29
|
+
const e = u.query.category;
|
|
30
|
+
return typeof e == "string" && e !== "" && Number(e) || null;
|
|
31
|
+
}), w = n(() => typeof u.query.q == "string" ? u.query.q : ""), N = z(w.value), d = n(() => {
|
|
32
|
+
const e = u.query.tariff;
|
|
33
|
+
return e === "new" ? y.value ? "new" : null : typeof e == "string" && e !== "" && Number(e) || null;
|
|
34
|
+
}), F = n({
|
|
35
|
+
get: () => d.value !== null,
|
|
36
|
+
set: (e) => {
|
|
37
|
+
e || P();
|
|
38
|
+
}
|
|
39
|
+
}), K = n(() => [
|
|
40
|
+
{ value: "", label: t("tariff.all") },
|
|
41
|
+
{ value: "trashed", label: t("tariff.trashed"), icon: "trash" }
|
|
42
|
+
]), k = xe(We, () => ({
|
|
43
|
+
q: w.value,
|
|
44
|
+
category: h.value,
|
|
45
|
+
filtered: o.value
|
|
46
|
+
})), M = n(() => y.value && k.sortable.value), Q = n(() => k.mode.value === "category" ? t("tariff.order-group") : k.mode.value === "all" ? t("tariff.order") : k.hint.value), X = n(() => w.value !== "" ? t("tariff.empty-search") : o.value ? t("tariff.empty-bin") : t("tariff.empty"));
|
|
47
|
+
async function v() {
|
|
48
|
+
V.value = !0;
|
|
49
|
+
try {
|
|
50
|
+
const e = await I.list({
|
|
51
|
+
search: w.value,
|
|
52
|
+
category: o.value ? null : h.value,
|
|
53
|
+
trashed: o.value
|
|
54
|
+
});
|
|
55
|
+
m.value = e.data, E.value = e.filters.categories;
|
|
56
|
+
} catch (e) {
|
|
57
|
+
b.danger(S(e));
|
|
58
|
+
} finally {
|
|
59
|
+
V.value = !1;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
O(
|
|
63
|
+
() => [C.value, h.value, w.value],
|
|
64
|
+
() => {
|
|
65
|
+
v();
|
|
66
|
+
}
|
|
67
|
+
), v();
|
|
68
|
+
let U;
|
|
69
|
+
O(N, (e) => {
|
|
70
|
+
clearTimeout(U), U = setTimeout(() => {
|
|
71
|
+
x.replace({ query: { ...u.query, q: e.trim() === "" ? void 0 : e } });
|
|
72
|
+
}, 300);
|
|
73
|
+
}), ie(() => clearTimeout(U));
|
|
74
|
+
function Y(e) {
|
|
75
|
+
x.replace({
|
|
76
|
+
query: { ...u.query, category: typeof e == "number" ? String(e) : void 0 }
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
function A(e) {
|
|
80
|
+
x.replace({ query: { ...u.query, tariff: String(e) } });
|
|
81
|
+
}
|
|
82
|
+
function P() {
|
|
83
|
+
const e = { ...u.query };
|
|
84
|
+
delete e.tariff, x.replace({ query: e });
|
|
85
|
+
}
|
|
86
|
+
function Z(e) {
|
|
87
|
+
A(e.id), v();
|
|
88
|
+
}
|
|
89
|
+
async function ee() {
|
|
90
|
+
try {
|
|
91
|
+
await k.move(m.value.map((e) => e.id));
|
|
92
|
+
} catch (e) {
|
|
93
|
+
b.danger(S(e, t("tariff.reorder-failed"))), await v();
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
function ae(e) {
|
|
97
|
+
return y.value ? o.value ? [
|
|
98
|
+
{
|
|
99
|
+
key: "restore",
|
|
100
|
+
icon: "refresh",
|
|
101
|
+
label: t("tariff.restore"),
|
|
102
|
+
run: () => {
|
|
103
|
+
re(e);
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
] : [
|
|
107
|
+
{
|
|
108
|
+
key: "delete",
|
|
109
|
+
icon: "trash",
|
|
110
|
+
label: t("tariff.delete"),
|
|
111
|
+
danger: !0,
|
|
112
|
+
run: () => {
|
|
113
|
+
te(e);
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
] : [];
|
|
117
|
+
}
|
|
118
|
+
async function te(e) {
|
|
119
|
+
if (await we({
|
|
120
|
+
title: t("tariff.delete-title", { name: e.name }),
|
|
121
|
+
message: t("tariff.delete-text"),
|
|
122
|
+
confirmText: t("tariff.delete"),
|
|
123
|
+
cancelText: t("tariff.cancel"),
|
|
124
|
+
tone: "danger"
|
|
125
|
+
}))
|
|
126
|
+
try {
|
|
127
|
+
await I.remove(e.id), b.success(t("tariff.deleted")), D(e.id);
|
|
128
|
+
} catch (a) {
|
|
129
|
+
b.danger(S(a));
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
function D(e) {
|
|
133
|
+
d.value === e && P(), v();
|
|
134
|
+
}
|
|
135
|
+
async function re(e) {
|
|
136
|
+
try {
|
|
137
|
+
await I.restore(e.id), b.success(t("tariff.restored"));
|
|
138
|
+
} catch (l) {
|
|
139
|
+
b.danger(S(l));
|
|
140
|
+
} finally {
|
|
141
|
+
await v();
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
function $(e) {
|
|
145
|
+
return Ve(e, W.i18n.state.locale);
|
|
146
|
+
}
|
|
147
|
+
return (e, l) => (i(), f(r(he), {
|
|
148
|
+
view: C.value,
|
|
149
|
+
"onUpdate:view": l[4] || (l[4] = (a) => C.value = a),
|
|
150
|
+
title: J.value,
|
|
151
|
+
views: K.value,
|
|
152
|
+
card: !1
|
|
153
|
+
}, {
|
|
154
|
+
default: s(() => [
|
|
155
|
+
c(r(fe), {
|
|
156
|
+
class: "wx-tariffs",
|
|
157
|
+
padding: "none"
|
|
158
|
+
}, {
|
|
159
|
+
default: s(() => [
|
|
160
|
+
c(r(ce), {
|
|
161
|
+
open: F.value,
|
|
162
|
+
"onUpdate:open": l[3] || (l[3] = (a) => F.value = a),
|
|
163
|
+
class: "wx-tariffs__panes",
|
|
164
|
+
"list-width": 360,
|
|
165
|
+
"detail-min": 460,
|
|
166
|
+
"detail-label": r(t)("module.tariffs")
|
|
167
|
+
}, {
|
|
168
|
+
list: s(() => [
|
|
169
|
+
_("div", ze, [
|
|
170
|
+
c(r(de), {
|
|
171
|
+
modelValue: N.value,
|
|
172
|
+
"onUpdate:modelValue": l[0] || (l[0] = (a) => N.value = a),
|
|
173
|
+
class: "wx-tariffs__search",
|
|
174
|
+
size: "sm",
|
|
175
|
+
clearable: "",
|
|
176
|
+
placeholder: r(t)("tariff.search"),
|
|
177
|
+
"aria-label": r(t)("tariff.search")
|
|
178
|
+
}, {
|
|
179
|
+
prefix: s(() => [
|
|
180
|
+
c(r(R), {
|
|
181
|
+
name: "search",
|
|
182
|
+
size: "sm"
|
|
183
|
+
})
|
|
184
|
+
]),
|
|
185
|
+
_: 1
|
|
186
|
+
}, 8, ["modelValue", "placeholder", "aria-label"]),
|
|
187
|
+
o.value ? p("", !0) : (i(), f(r(ve), {
|
|
188
|
+
key: 0,
|
|
189
|
+
"model-value": h.value,
|
|
190
|
+
options: E.value.map((a) => ({ value: a.id, label: a.title })),
|
|
191
|
+
placeholder: r(t)("tariff.any-category"),
|
|
192
|
+
"aria-label": r(t)("tariff.filter-category"),
|
|
193
|
+
clearable: "",
|
|
194
|
+
size: "sm",
|
|
195
|
+
"onUpdate:modelValue": Y
|
|
196
|
+
}, null, 8, ["model-value", "options", "placeholder", "aria-label"]))
|
|
197
|
+
]),
|
|
198
|
+
y.value && !o.value ? (i(), T("button", {
|
|
199
|
+
key: 0,
|
|
200
|
+
type: "button",
|
|
201
|
+
class: B(["wx-tariffs__new", { "is-current": d.value === "new" }]),
|
|
202
|
+
onClick: l[1] || (l[1] = (a) => A("new"))
|
|
203
|
+
}, [
|
|
204
|
+
c(r(R), {
|
|
205
|
+
name: "plus",
|
|
206
|
+
size: "sm"
|
|
207
|
+
}),
|
|
208
|
+
L(" " + g(r(t)("tariff.new")), 1)
|
|
209
|
+
], 2)) : p("", !0),
|
|
210
|
+
V.value && m.value.length === 0 ? (i(), f(r(pe), {
|
|
211
|
+
key: 1,
|
|
212
|
+
class: "wx-tariffs__loading",
|
|
213
|
+
rows: 5
|
|
214
|
+
})) : m.value.length === 0 ? (i(), f(r(G), {
|
|
215
|
+
key: 2,
|
|
216
|
+
title: X.value,
|
|
217
|
+
description: !o.value && w.value === "" ? r(t)("tariff.empty-help") : void 0
|
|
218
|
+
}, null, 8, ["title", "description"])) : (i(), T(j, { key: 3 }, [
|
|
219
|
+
c(r(me), {
|
|
220
|
+
modelValue: m.value,
|
|
221
|
+
"onUpdate:modelValue": l[2] || (l[2] = (a) => m.value = a),
|
|
222
|
+
class: B(["wx-tariffs__list", { "is-loading": V.value }]),
|
|
223
|
+
plain: "",
|
|
224
|
+
"item-key": "id",
|
|
225
|
+
handle: M.value ? "grip" : "row",
|
|
226
|
+
"item-label": (a) => a.name,
|
|
227
|
+
disabled: !M.value,
|
|
228
|
+
onMove: ee
|
|
229
|
+
}, {
|
|
230
|
+
default: s(({ item: a }) => [
|
|
231
|
+
(i(), f(oe(o.value ? "div" : "button"), {
|
|
232
|
+
type: o.value ? void 0 : "button",
|
|
233
|
+
class: B(["wx-tariff-row", { "is-current": d.value === a.id }]),
|
|
234
|
+
onClick: (q) => o.value ? void 0 : A(a.id)
|
|
235
|
+
}, {
|
|
236
|
+
default: s(() => [
|
|
237
|
+
_("span", Be, [
|
|
238
|
+
_("span", Ie, [
|
|
239
|
+
_("span", Ne, g(a.name), 1),
|
|
240
|
+
a.featured ? (i(), T("span", {
|
|
241
|
+
key: 0,
|
|
242
|
+
class: "wx-tariff-row__star",
|
|
243
|
+
role: "img",
|
|
244
|
+
"aria-label": r(t)("tariff.featured")
|
|
245
|
+
}, [
|
|
246
|
+
c(r(R), {
|
|
247
|
+
name: "star",
|
|
248
|
+
size: "sm"
|
|
249
|
+
})
|
|
250
|
+
], 8, Ue)) : p("", !0)
|
|
251
|
+
]),
|
|
252
|
+
_("span", {
|
|
253
|
+
class: B(["wx-tariff-row__price", { "is-missing": $(a) === "" }])
|
|
254
|
+
}, g($(a) || r(t)("tariff.no-price")), 3),
|
|
255
|
+
_("span", Ae, [
|
|
256
|
+
a.published ? p("", !0) : (i(), f(r(H), {
|
|
257
|
+
key: 0,
|
|
258
|
+
dot: "",
|
|
259
|
+
size: "sm"
|
|
260
|
+
}, {
|
|
261
|
+
default: s(() => [
|
|
262
|
+
L(g(r(t)("tariff.not-published")), 1)
|
|
263
|
+
]),
|
|
264
|
+
_: 1
|
|
265
|
+
})),
|
|
266
|
+
a.badge ? (i(), T("span", Le, g(a.badge), 1)) : p("", !0),
|
|
267
|
+
(i(!0), T(j, null, ne(a.categories, (q) => (i(), f(r(H), {
|
|
268
|
+
key: q.id,
|
|
269
|
+
size: "sm",
|
|
270
|
+
round: ""
|
|
271
|
+
}, {
|
|
272
|
+
default: s(() => [
|
|
273
|
+
L(g(q.title), 1)
|
|
274
|
+
]),
|
|
275
|
+
_: 2
|
|
276
|
+
}, 1024))), 128))
|
|
277
|
+
])
|
|
278
|
+
])
|
|
279
|
+
]),
|
|
280
|
+
_: 2
|
|
281
|
+
}, 1032, ["type", "class", "onClick"]))
|
|
282
|
+
]),
|
|
283
|
+
actions: s(({ item: a }) => [
|
|
284
|
+
c(r(ke), {
|
|
285
|
+
actions: ae(a),
|
|
286
|
+
label: a.name
|
|
287
|
+
}, null, 8, ["actions", "label"])
|
|
288
|
+
]),
|
|
289
|
+
_: 1
|
|
290
|
+
}, 8, ["modelValue", "class", "handle", "item-label", "disabled"]),
|
|
291
|
+
y.value && !o.value ? (i(), f(r(ye), {
|
|
292
|
+
key: 0,
|
|
293
|
+
class: "wx-tariffs__note",
|
|
294
|
+
type: "info",
|
|
295
|
+
description: Q.value
|
|
296
|
+
}, null, 8, ["description"])) : p("", !0)
|
|
297
|
+
], 64))
|
|
298
|
+
]),
|
|
299
|
+
detail: s(({ inline: a, back: q }) => [
|
|
300
|
+
d.value !== null ? (i(), f(Se, {
|
|
301
|
+
id: d.value === "new" ? null : d.value,
|
|
302
|
+
key: String(d.value),
|
|
303
|
+
category: h.value,
|
|
304
|
+
inline: a,
|
|
305
|
+
onBack: q,
|
|
306
|
+
onSaved: v,
|
|
307
|
+
onCreated: Z,
|
|
308
|
+
onRemoved: D
|
|
309
|
+
}, null, 8, ["id", "category", "inline", "onBack"])) : p("", !0)
|
|
310
|
+
]),
|
|
311
|
+
empty: s(() => [
|
|
312
|
+
c(r(G), {
|
|
313
|
+
title: r(t)("tariff.choose"),
|
|
314
|
+
description: y.value ? r(t)("tariff.choose-help") : void 0
|
|
315
|
+
}, null, 8, ["title", "description"])
|
|
316
|
+
]),
|
|
317
|
+
_: 1
|
|
318
|
+
}, 8, ["open", "detail-label"])
|
|
319
|
+
]),
|
|
320
|
+
_: 1
|
|
321
|
+
})
|
|
322
|
+
]),
|
|
323
|
+
_: 1
|
|
324
|
+
}, 8, ["view", "title", "views"]));
|
|
325
|
+
}
|
|
326
|
+
}), Oe = /* @__PURE__ */ Ce(Re, [["__scopeId", "data-v-d86b91c1"]]);
|
|
327
|
+
export {
|
|
328
|
+
Oe as default
|
|
329
|
+
};
|
|
330
|
+
//# sourceMappingURL=TariffsPage-Trs7f5Rf.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TariffsPage-Trs7f5Rf.js","sources":["../src/TariffsPage.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { computed, onBeforeUnmount, ref, watch } from 'vue'\nimport { useRoute, useRouter, type LocationQueryRaw } from 'vue-router'\nimport {\n confirm,\n toast,\n WxAlert,\n WxBadge,\n WxCard,\n WxEmpty,\n WxIcon,\n WxInput,\n WxListDetail,\n WxSelect,\n WxSkeleton,\n WxSortableList,\n type TabItem,\n type TabValue,\n} from '@webx-ui/core'\nimport {\n useAdmin,\n useErrorText,\n useItemOrder,\n useTranslate,\n WxListScreen,\n WxRowMenu,\n type RowAction,\n} from '@webx-ui/module-admin'\nimport { createTariffsApi, TARIFFS_API } from './api'\nimport { useTariffsMessages } from './i18n'\nimport { priceLine } from './price'\nimport TariffPane from './TariffPane.vue'\nimport type { TariffGroupRef, TariffRow, TariffSummary } from './types'\n\n/**\n * The tariffs: all of them on the left, the one being written on the right (§5.2).\n *\n * The shape of the reviews, for the same reason: a price card is short, and the one next to edit\n * is usually the one beside it — \"Growth\" is priced against \"Starter\". On a phone the form is the\n * whole screen, in the drawer `WxListDetail` raises, and draws its own way back.\n *\n * Two orders, as with the reviews: without a filter a drag moves the common order; narrowed to\n * one group, the group's own; a search or the bin shows a selection, so the grips go away and the\n * line under the list says why. The query keeps the shared code's name, `category` (decision 14).\n *\n * Everything the screen is looking at lives in the address — the view, the group, the search and\n * the open tariff — so a link to a tariff is a link to it in its list.\n */\nwithDefaults(defineProps<{ base?: string }>(), { base: '/tariffs' })\n\nconst context = useAdmin()\nconst api = createTariffsApi(context)\nconst route = useRoute()\nconst router = useRouter()\nuseTariffsMessages()\n\nconst t = useTranslate('webx-tariffs')\n/* Not the server's `message`: the panel says how a request failed in its own words. */\nconst message = useErrorText()\n\nconst rows = ref<TariffRow[]>([])\nconst categories = ref<TariffGroupRef[]>([])\nconst loading = ref(true)\n\nconst canManage = computed(() => context.can('tariffs.manage'))\n\nconst title = computed(\n () =>\n context.state.manifest?.modules.find((module) => module.id === 'tariffs')?.title ??\n t('module.tariffs'),\n)\n\nconst view = computed<TabValue>({\n get: () => (route.query.view === 'trashed' ? 'trashed' : ''),\n set: (value) => {\n const query: LocationQueryRaw = {\n ...route.query,\n view: value === '' ? undefined : String(value),\n }\n\n // A tariff from the list is not a tariff from the bin: the form closes with the view.\n delete query.tariff\n void router.replace({ query })\n },\n})\n\nconst inBin = computed(() => view.value === 'trashed')\n\nconst category = computed<number | null>(() => {\n const raw = route.query.category\n\n return typeof raw === 'string' && raw !== '' ? Number(raw) || null : null\n})\n\nconst q = computed(() => (typeof route.query.q === 'string' ? route.query.q : ''))\n\n/* What is typed, ahead of the address: the address follows it after a pause. */\nconst typed = ref(q.value)\n\n/** The open tariff: a number, `'new'` for one not yet saved, or nothing. */\nconst selected = computed<number | 'new' | null>(() => {\n const raw = route.query.tariff\n\n if (raw === 'new') return canManage.value ? 'new' : null\n\n return typeof raw === 'string' && raw !== '' ? Number(raw) || null : null\n})\n\n/*\n * Open is \"a tariff is chosen\", and closing is un-choosing it — so the address, the list's\n * highlight and the drawer on a phone can never disagree about it.\n */\nconst open = computed({\n get: () => selected.value !== null,\n set: (value) => {\n if (!value) close()\n },\n})\n\nconst views = computed<TabItem[]>(() => [\n { value: '', label: t('tariff.all') },\n { value: 'trashed', label: t('tariff.trashed'), icon: 'trash' },\n])\n\nconst order = useItemOrder(TARIFFS_API, () => ({\n q: q.value,\n category: category.value,\n filtered: inBin.value,\n}))\n\n/* Dragged only by somebody who may write, and only in a list that is a whole order. */\nconst sortable = computed(() => canManage.value && order.sortable.value)\n\n/*\n * The panel's shared lines say \"category\" and \"items\"; here the editor reads \"group\" and \"cards\"\n * (decision 14). A locked list keeps the shared line: it explains why nothing moves.\n */\nconst hint = computed(() => {\n if (order.mode.value === 'category') return t('tariff.order-group')\n if (order.mode.value === 'all') return t('tariff.order')\n\n return order.hint.value\n})\n\nconst emptyText = computed(() => {\n if (q.value !== '') return t('tariff.empty-search')\n\n return inBin.value ? t('tariff.empty-bin') : t('tariff.empty')\n})\n\nasync function load(): Promise<void> {\n loading.value = true\n\n try {\n const answer = await api.list({\n search: q.value,\n category: inBin.value ? null : category.value,\n trashed: inBin.value,\n })\n\n rows.value = answer.data\n categories.value = answer.filters.categories\n } catch (error) {\n toast.danger(message(error))\n } finally {\n loading.value = false\n }\n}\n\nwatch(\n () => [view.value, category.value, q.value] as const,\n () => void load(),\n)\nvoid load()\n\nlet pause: ReturnType<typeof setTimeout> | undefined\n\nwatch(typed, (value) => {\n clearTimeout(pause)\n pause = setTimeout(() => {\n void router.replace({ query: { ...route.query, q: value.trim() === '' ? undefined : value } })\n }, 300)\n})\n\nonBeforeUnmount(() => clearTimeout(pause))\n\nfunction narrow(value: unknown): void {\n void router.replace({\n query: { ...route.query, category: typeof value === 'number' ? String(value) : undefined },\n })\n}\n\n/* `replace` and not `push`: going through twenty tariffs is not twenty steps of history. */\nfunction choose(id: number | 'new'): void {\n void router.replace({ query: { ...route.query, tariff: String(id) } })\n}\n\nfunction close(): void {\n const query = { ...route.query }\n\n delete query.tariff\n void router.replace({ query })\n}\n\n/** A new tariff was saved: it is a record now, and the list has it. */\nfunction created(tariff: TariffSummary): void {\n choose(tariff.id)\n void load()\n}\n\n/**\n * The order on screen, written as a whole — the list or the category's, whichever this is. The\n * list is already in its new order (`WxSortableList` reorders the model before it says so), so a\n * failure has to put it back rather than leave the screen disagreeing with the database.\n */\nasync function reorder(): Promise<void> {\n try {\n await order.move(rows.value.map((row) => row.id))\n } catch (error) {\n toast.danger(message(error, t('tariff.reorder-failed')))\n await load()\n }\n}\n\nfunction actionsFor(row: TariffRow): RowAction[] {\n if (!canManage.value) return []\n\n if (inBin.value) {\n return [\n {\n key: 'restore',\n icon: 'refresh',\n label: t('tariff.restore'),\n run: () => void restore(row),\n },\n ]\n }\n\n return [\n {\n key: 'delete',\n icon: 'trash',\n label: t('tariff.delete'),\n danger: true,\n run: () => void remove(row),\n },\n ]\n}\n\nasync function remove(row: TariffRow): Promise<void> {\n const agreed = await confirm({\n title: t('tariff.delete-title', { name: row.name }),\n message: t('tariff.delete-text'),\n confirmText: t('tariff.delete'),\n cancelText: t('tariff.cancel'),\n tone: 'danger',\n })\n\n if (!agreed) return\n\n try {\n await api.remove(row.id)\n toast.success(t('tariff.deleted'))\n removed(row.id)\n } catch (error) {\n toast.danger(message(error))\n }\n}\n\n/** Gone from the list; and if it was the open one, the form goes with it. */\nfunction removed(id: number): void {\n if (selected.value === id) close()\n\n void load()\n}\n\nasync function restore(row: TariffRow): Promise<void> {\n try {\n await api.restore(row.id)\n toast.success(t('tariff.restored'))\n } catch (error) {\n toast.danger(message(error))\n } finally {\n await load()\n }\n}\n\n/* The price as the site would print it — the language of the panel only decides the separators. */\nfunction price(row: TariffRow): string {\n return priceLine(row, context.i18n.state.locale)\n}\n</script>\n\n<template>\n <wx-list-screen v-model:view=\"view\" :title=\"title\" :views=\"views\" :card=\"false\">\n <wx-card class=\"wx-tariffs\" padding=\"none\">\n <wx-list-detail\n v-model:open=\"open\"\n class=\"wx-tariffs__panes\"\n :list-width=\"360\"\n :detail-min=\"460\"\n :detail-label=\"t('module.tariffs')\"\n >\n <template #list>\n <div class=\"wx-tariffs__bar\">\n <wx-input\n v-model=\"typed\"\n class=\"wx-tariffs__search\"\n size=\"sm\"\n clearable\n :placeholder=\"t('tariff.search')\"\n :aria-label=\"t('tariff.search')\"\n >\n <template #prefix><wx-icon name=\"search\" size=\"sm\" /></template>\n </wx-input>\n\n <!-- Always in sight rather than behind a funnel: it is the one filter that decides\n which order a drag writes, and the list says so right under it. -->\n <wx-select\n v-if=\"!inBin\"\n :model-value=\"category\"\n :options=\"categories.map((item) => ({ value: item.id, label: item.title }))\"\n :placeholder=\"t('tariff.any-category')\"\n :aria-label=\"t('tariff.filter-category')\"\n clearable\n size=\"sm\"\n @update:model-value=\"narrow\"\n />\n </div>\n\n <!--\n A line of the list rather than a button in the head: the new tariff is written where\n it will stand, beside the ones it joins — and the form opens the same way any other\n tariff's does.\n -->\n <button\n v-if=\"canManage && !inBin\"\n type=\"button\"\n class=\"wx-tariffs__new\"\n :class=\"{ 'is-current': selected === 'new' }\"\n @click=\"choose('new')\"\n >\n <wx-icon name=\"plus\" size=\"sm\" />\n {{ t('tariff.new') }}\n </button>\n\n <wx-skeleton v-if=\"loading && rows.length === 0\" class=\"wx-tariffs__loading\" :rows=\"5\" />\n\n <wx-empty\n v-else-if=\"rows.length === 0\"\n :title=\"emptyText\"\n :description=\"!inBin && q === '' ? t('tariff.empty-help') : undefined\"\n />\n\n <template v-else>\n <!-- A grip and not the whole row: the row opens a tariff, and a row that both opens\n and drags is one where one of the two happens by accident. -->\n <wx-sortable-list\n v-model=\"rows\"\n class=\"wx-tariffs__list\"\n :class=\"{ 'is-loading': loading }\"\n plain\n item-key=\"id\"\n :handle=\"sortable ? 'grip' : 'row'\"\n :item-label=\"(item: TariffRow) => item.name\"\n :disabled=\"!sortable\"\n @move=\"reorder\"\n >\n <template #default=\"{ item }\">\n <component\n :is=\"inBin ? 'div' : 'button'\"\n :type=\"inBin ? undefined : 'button'\"\n class=\"wx-tariff-row\"\n :class=\"{ 'is-current': selected === item.id }\"\n @click=\"inBin ? undefined : choose(item.id)\"\n >\n <span class=\"wx-tariff-row__body\">\n <span class=\"wx-tariff-row__who\">\n <span class=\"wx-tariff-row__name\">{{ item.name }}</span>\n <!-- A mark and not a control: the switch is in the form. -->\n <span\n v-if=\"item.featured\"\n class=\"wx-tariff-row__star\"\n role=\"img\"\n :aria-label=\"t('tariff.featured')\"\n >\n <wx-icon name=\"star\" size=\"sm\" />\n </span>\n </span>\n\n <span\n class=\"wx-tariff-row__price\"\n :class=\"{ 'is-missing': price(item) === '' }\"\n >\n {{ price(item) || t('tariff.no-price') }}\n </span>\n\n <span class=\"wx-tariff-row__facts\">\n <wx-badge v-if=\"!item.published\" dot size=\"sm\">\n {{ t('tariff.not-published') }}\n </wx-badge>\n\n <span v-if=\"item.badge\" class=\"wx-tariff-row__badge\">{{ item.badge }}</span>\n\n <wx-badge v-for=\"chip in item.categories\" :key=\"chip.id\" size=\"sm\" round>\n {{ chip.title }}\n </wx-badge>\n </span>\n </span>\n </component>\n </template>\n\n <template #actions=\"{ item }\">\n <wx-row-menu :actions=\"actionsFor(item)\" :label=\"item.name\" />\n </template>\n </wx-sortable-list>\n\n <!-- What a drag does here, or why there is nothing to drag. -->\n <wx-alert\n v-if=\"canManage && !inBin\"\n class=\"wx-tariffs__note\"\n type=\"info\"\n :description=\"hint\"\n />\n </template>\n </template>\n\n <template #detail=\"{ inline, back }\">\n <tariff-pane\n v-if=\"selected !== null\"\n :id=\"selected === 'new' ? null : selected\"\n :key=\"String(selected)\"\n :category=\"category\"\n :inline=\"inline\"\n @back=\"back\"\n @saved=\"load\"\n @created=\"created\"\n @removed=\"removed\"\n />\n </template>\n\n <template #empty>\n <wx-empty\n :title=\"t('tariff.choose')\"\n :description=\"canManage ? t('tariff.choose-help') : undefined\"\n />\n </template>\n </wx-list-detail>\n </wx-card>\n </wx-list-screen>\n</template>\n\n<style>\n/*\n * What scrolls here is the page, the way it does on every other list of the panel. The card's\n * corners are the screen's, and the panes paint their own background to the edge: `clip`, not\n * `hidden`, which would make this a scroll container and pin everything sticky inside to a box\n * that never moves (CLAUDE.md §4).\n */\n.wx-tariffs > .wx-card__body {\n display: flex;\n flex-direction: column;\n overflow: clip;\n border-radius: inherit;\n}\n</style>\n\n<style scoped>\n.wx-tariffs__bar {\n display: flex;\n flex-wrap: wrap;\n gap: var(--wx-space-8);\n padding: var(--wx-space-12) var(--wx-space-12) var(--wx-space-8);\n}\n\n.wx-tariffs__search {\n flex: 1 1 180px;\n min-width: 0;\n}\n\n/* The select is a fragment (it carries its dropdown beside it), so our scope attribute never\n reaches it: styled from our own wrapper (CLAUDE.md §4). */\n.wx-tariffs__bar > :deep(.wx-select) {\n flex: 1 1 140px;\n min-width: 0;\n}\n\n.wx-tariffs__new {\n display: flex;\n align-items: center;\n gap: var(--wx-space-8);\n width: calc(100% - 2 * var(--wx-space-8));\n margin: 0 var(--wx-space-8) var(--wx-space-4);\n padding: var(--wx-space-8);\n border: 1px dashed var(--wx-border-default);\n border-radius: var(--wx-radius-sm);\n background: none;\n font: inherit;\n color: var(--wx-color-primary);\n text-align: start;\n cursor: pointer;\n}\n\n.wx-tariffs__new:hover,\n.wx-tariffs__new.is-current {\n background: var(--wx-bg-subtle);\n}\n\n.wx-tariffs__loading {\n padding: var(--wx-space-12);\n}\n\n.wx-tariffs__list {\n padding-inline: var(--wx-space-8);\n}\n\n.wx-tariffs__list.is-loading {\n opacity: 0.6;\n}\n\n.wx-tariffs__list :deep(.wx-sortable-list__row) {\n gap: var(--wx-space-4);\n padding-inline: var(--wx-space-4);\n border-radius: var(--wx-radius-sm);\n}\n\n.wx-tariffs__list :deep(.wx-sortable-list__row:hover),\n.wx-tariffs__list :deep(.wx-sortable-list__row:has(.is-current)) {\n background: var(--wx-bg-subtle);\n}\n\n.wx-tariffs__note {\n margin: var(--wx-space-8);\n}\n\n.wx-tariff-row {\n display: flex;\n align-items: flex-start;\n gap: var(--wx-space-10);\n /* The row is the target: a short name should not leave half the line dead — and a button,\n unlike a link, is only as wide as what is in it until it is told otherwise. */\n flex: 1 1 auto;\n width: 100%;\n min-width: 0;\n padding-block: var(--wx-space-8);\n padding-inline: 0;\n border: 0;\n background: none;\n font: inherit;\n color: inherit;\n text-align: start;\n}\n\nbutton.wx-tariff-row {\n cursor: pointer;\n}\n\n.wx-tariff-row__body {\n display: flex;\n flex: 1 1 auto;\n flex-direction: column;\n gap: var(--wx-space-2);\n min-width: 0;\n}\n\n.wx-tariff-row__who {\n display: flex;\n flex-wrap: wrap;\n align-items: baseline;\n column-gap: var(--wx-space-8);\n min-width: 0;\n}\n\n.wx-tariff-row__name {\n min-width: 0;\n overflow: hidden;\n font-weight: var(--wx-font-weight-medium);\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.wx-tariff-row.is-current .wx-tariff-row__name {\n color: var(--wx-color-primary);\n}\n\n.wx-tariff-row__star {\n display: inline-flex;\n flex: none;\n align-self: center;\n color: var(--wx-color-warning);\n}\n\n/* The price is what tells two cards apart in the list, so it is the second line, not a chip. */\n.wx-tariff-row__price {\n overflow: hidden;\n font-size: var(--wx-font-size-sm);\n font-variant-numeric: tabular-nums;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.wx-tariff-row__price.is-missing {\n color: var(--wx-text-muted);\n font-style: italic;\n}\n\n.wx-tariff-row__facts {\n display: flex;\n flex-wrap: wrap;\n align-items: center;\n gap: var(--wx-space-4);\n min-width: 0;\n margin-top: var(--wx-space-2);\n}\n\n.wx-tariff-row__facts:empty {\n display: none;\n}\n\n.wx-tariff-row__badge {\n min-width: 0;\n overflow: hidden;\n color: var(--wx-text-muted);\n font-size: var(--wx-font-size-xs);\n text-overflow: ellipsis;\n text-transform: uppercase;\n white-space: nowrap;\n}\n</style>\n"],"names":["context","useAdmin","api","createTariffsApi","route","useRoute","router","useRouter","useTariffsMessages","useTranslate","message","useErrorText","rows","ref","categories","loading","canManage","computed","title","module","view","value","query","inBin","category","raw","q","typed","selected","open","close","views","order","useItemOrder","TARIFFS_API","sortable","hint","emptyText","load","answer","error","toast","watch","pause","onBeforeUnmount","narrow","choose","id","created","tariff","reorder","row","actionsFor","restore","remove","confirm","removed","price","priceLine","_createBlock","_unref","WxListScreen","$event","_createVNode","WxCard","WxListDetail","_createElementVNode","_hoisted_1","WxInput","WxIcon","WxSelect","item","_createElementBlock","_normalizeClass","_createTextVNode","WxSkeleton","WxEmpty","_Fragment","WxSortableList","_withCtx","_openBlock","_resolveDynamicComponent","_hoisted_2","_hoisted_3","_hoisted_4","_toDisplayString","_hoisted_6","WxBadge","_hoisted_7","_renderList","chip","WxRowMenu","WxAlert","inline","back","TariffPane"],"mappings":";;;;;;;;;;;;;;AAkDA,UAAMA,IAAUC,GAAA,GACVC,IAAMC,GAAiBH,CAAO,GAC9BI,IAAQC,GAAA,GACRC,IAASC,GAAA;AACf,IAAAC,GAAA;AAEA,UAAM,IAAIC,GAAa,cAAc,GAE/BC,IAAUC,GAAA,GAEVC,IAAOC,EAAiB,EAAE,GAC1BC,IAAaD,EAAsB,EAAE,GACrCE,IAAUF,EAAI,EAAI,GAElBG,IAAYC,EAAS,MAAMjB,EAAQ,IAAI,gBAAgB,CAAC,GAExDkB,IAAQD;AAAA,MACZ,MACEjB,EAAQ,MA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