@burdenoff/microfe-support 2026.830.1 → 2026.830.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 (77) hide show
  1. package/dist/index.js +2 -1
  2. package/dist/support/SupportAdminRoot.js +31 -34
  3. package/dist/support/SupportAdminRoot.js.map +1 -1
  4. package/dist/support/SupportUserRoot.js +19 -22
  5. package/dist/support/SupportUserRoot.js.map +1 -1
  6. package/dist/support/components/PageLayout.d.ts +1 -1
  7. package/dist/support/components/PageLayout.js +46 -44
  8. package/dist/support/components/PageLayout.js.map +1 -1
  9. package/dist/support/components/analytics/CategoryBreakdown.js +24 -23
  10. package/dist/support/components/analytics/CategoryBreakdown.js.map +1 -1
  11. package/dist/support/components/analytics/PriorityBreakdown.js +27 -26
  12. package/dist/support/components/analytics/PriorityBreakdown.js.map +1 -1
  13. package/dist/support/components/analytics/SLAReport.js +48 -54
  14. package/dist/support/components/analytics/SLAReport.js.map +1 -1
  15. package/dist/support/components/analytics/SatisfactionDistribution.js +56 -59
  16. package/dist/support/components/analytics/SatisfactionDistribution.js.map +1 -1
  17. package/dist/support/components/analytics/TopAgents.js +27 -26
  18. package/dist/support/components/analytics/TopAgents.js.map +1 -1
  19. package/dist/support/components/analytics/TrendChart.js +23 -21
  20. package/dist/support/components/analytics/TrendChart.js.map +1 -1
  21. package/dist/support/components/kb/ArticleForm.js +145 -132
  22. package/dist/support/components/kb/ArticleForm.js.map +1 -1
  23. package/dist/support/components/settings/CannedResponsesSettings.js +104 -103
  24. package/dist/support/components/settings/CannedResponsesSettings.js.map +1 -1
  25. package/dist/support/components/settings/SLAPoliciesSettings.js +120 -123
  26. package/dist/support/components/settings/SLAPoliciesSettings.js.map +1 -1
  27. package/dist/support/components/settings/TicketCategoriesSettings.js +175 -180
  28. package/dist/support/components/settings/TicketCategoriesSettings.js.map +1 -1
  29. package/dist/support/components/tickets/AttachmentList.js +21 -20
  30. package/dist/support/components/tickets/AttachmentList.js.map +1 -1
  31. package/dist/support/components/tickets/MessageComposer.js +35 -35
  32. package/dist/support/components/tickets/MessageThread.js +55 -54
  33. package/dist/support/components/tickets/MessageThread.js.map +1 -1
  34. package/dist/support/components/tickets/TicketDetailHeader.js +62 -57
  35. package/dist/support/components/tickets/TicketDetailHeader.js.map +1 -1
  36. package/dist/support/components/tickets/TicketHeader.js +47 -47
  37. package/dist/support/components/tickets/TicketSidebar.js +122 -121
  38. package/dist/support/components/tickets/TicketSidebar.js.map +1 -1
  39. package/dist/support/hooks/index.d.ts +1 -0
  40. package/dist/support/hooks/index.js +1 -0
  41. package/dist/support/hooks/useTr.d.ts +16 -0
  42. package/dist/support/hooks/useTr.js +12 -0
  43. package/dist/support/hooks/useTr.js.map +1 -0
  44. package/dist/support/index.d.ts +1 -0
  45. package/dist/support/index.js +2 -1
  46. package/dist/support/pages/AnalyticsPage.js +151 -145
  47. package/dist/support/pages/AnalyticsPage.js.map +1 -1
  48. package/dist/support/pages/ArticleDetailAdminPage.js +134 -147
  49. package/dist/support/pages/ArticleDetailAdminPage.js.map +1 -1
  50. package/dist/support/pages/ArticleDetailUserPage.js +70 -79
  51. package/dist/support/pages/ArticleDetailUserPage.js.map +1 -1
  52. package/dist/support/pages/ContactInquiriesPage.js +140 -139
  53. package/dist/support/pages/ContactInquiriesPage.js.map +1 -1
  54. package/dist/support/pages/ContactInquiryDetailPage.js +259 -232
  55. package/dist/support/pages/ContactInquiryDetailPage.js.map +1 -1
  56. package/dist/support/pages/CreateArticlePage.js +57 -56
  57. package/dist/support/pages/CreateArticlePage.js.map +1 -1
  58. package/dist/support/pages/CreateTicketPage.js +151 -146
  59. package/dist/support/pages/CreateTicketPage.js.map +1 -1
  60. package/dist/support/pages/EditArticlePage.js +80 -79
  61. package/dist/support/pages/EditArticlePage.js.map +1 -1
  62. package/dist/support/pages/KnowledgeBaseAdminPage.js +92 -99
  63. package/dist/support/pages/KnowledgeBaseAdminPage.js.map +1 -1
  64. package/dist/support/pages/KnowledgeBaseUserPage.js +85 -92
  65. package/dist/support/pages/KnowledgeBaseUserPage.js.map +1 -1
  66. package/dist/support/pages/SettingsPage.js +88 -87
  67. package/dist/support/pages/SettingsPage.js.map +1 -1
  68. package/dist/support/pages/TicketDetailAdminPage.js +91 -90
  69. package/dist/support/pages/TicketDetailAdminPage.js.map +1 -1
  70. package/dist/support/pages/TicketDetailUserPage.js +120 -118
  71. package/dist/support/pages/TicketDetailUserPage.js.map +1 -1
  72. package/dist/support/pages/TicketListPage.js +139 -139
  73. package/dist/support/translations/en.d.ts +814 -0
  74. package/dist/support/translations/en.js +779 -0
  75. package/dist/support/translations/en.js.map +1 -0
  76. package/dist/support/translations/index.d.ts +1 -0
  77. package/package.json +1 -1
@@ -1,377 +1,372 @@
1
- import { CATEGORY_COLOR_OPTIONS as e, getCategoryColorOption as t, getCategorySwatchClass as n } from "../../utils/categoryColors.js";
2
- import { useEffect as r, useRef as ee, useState as i } from "react";
3
- import { AlertCircle as a, CheckCircle as o, Edit2 as s, FolderOpen as c, GripVertical as l, Loader2 as u, Plus as d, ToggleLeft as f, ToggleRight as p, Trash2 as m } from "lucide-react";
4
- import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
5
- import { AlertDialog as v, AlertDialogAction as y, AlertDialogCancel as b, AlertDialogContent as x, AlertDialogDescription as S, AlertDialogFooter as te, AlertDialogHeader as C, AlertDialogTitle as w, ResponsiveDialog as T, ResponsiveDialogContent as E, ResponsiveDialogHeader as D, ResponsiveDialogTitle as O } from "@burdenoff/fe-libs/ui";
1
+ import { useTr as e } from "../../hooks/useTr.js";
2
+ import { CATEGORY_COLOR_OPTIONS as t, getCategoryColorOption as n, getCategorySwatchClass as r } from "../../utils/categoryColors.js";
3
+ import { useEffect as i, useRef as a, useState as o } from "react";
4
+ import { AlertCircle as ee, CheckCircle as s, Edit2 as c, FolderOpen as l, GripVertical as u, Loader2 as d, Plus as f, ToggleLeft as p, ToggleRight as m, Trash2 as h } from "lucide-react";
5
+ import { Fragment as g, jsx as _, jsxs as v } from "react/jsx-runtime";
6
+ import { AlertDialog as y, AlertDialogAction as b, AlertDialogCancel as x, AlertDialogContent as S, AlertDialogDescription as C, AlertDialogFooter as w, AlertDialogHeader as T, AlertDialogTitle as E, ResponsiveDialog as te, ResponsiveDialogContent as ne, ResponsiveDialogHeader as D, ResponsiveDialogTitle as O } from "@burdenoff/fe-libs/ui";
6
7
  //#region src/support/components/settings/TicketCategoriesSettings.tsx
7
8
  var k = (e) => e.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/(^-|-$)/g, ""), A = {
8
9
  name: "",
9
10
  slug: "",
10
11
  description: "",
11
- color: e[0].value,
12
+ color: t[0].value,
12
13
  icon: "",
13
14
  isActive: !0
14
15
  };
15
16
  function j({ categories: j, onCreate: M, onUpdate: N, onDelete: P }) {
16
- let [F, I] = i(!1), [L, R] = i(null), [z, B] = i(A), [V, H] = i(!1), [U, W] = i(null), [G, K] = i(null), [q, J] = i(null), Y = ee(null);
17
- r(() => () => {
18
- Y.current && clearTimeout(Y.current);
17
+ let F = e(), [I, L] = o(!1), [R, z] = o(null), [B, V] = o(A), [H, U] = o(!1), [W, G] = o(null), [K, q] = o(null), [J, Y] = o(null), X = a(null);
18
+ i(() => () => {
19
+ X.current && clearTimeout(X.current);
19
20
  }, []);
20
- let X = (e, t) => {
21
- J({
21
+ let Z = (e, t) => {
22
+ Y({
22
23
  type: e,
23
24
  message: t
24
- }), Y.current && clearTimeout(Y.current), Y.current = setTimeout(() => J(null), 3e3);
25
- }, Z = () => {
26
- R(null), B(A), I(!0);
27
- }, Q = (e) => {
28
- R(e), B({
25
+ }), X.current && clearTimeout(X.current), X.current = setTimeout(() => Y(null), 3e3);
26
+ }, Q = () => {
27
+ z(null), V(A), L(!0);
28
+ }, re = (e) => {
29
+ z(e), V({
29
30
  name: e.name,
30
31
  slug: e.slug,
31
32
  description: e.description || "",
32
- color: t(e.color).value,
33
+ color: n(e.color).value,
33
34
  icon: e.icon || "",
34
35
  isActive: e.isActive ?? !0,
35
36
  parentId: e.parentId
36
- }), I(!0);
37
+ }), L(!0);
37
38
  }, $ = () => {
38
- I(!1), R(null), B(A);
39
- }, ne = (e) => {
40
- B({
41
- ...z,
39
+ L(!1), z(null), V(A);
40
+ }, ie = (e) => {
41
+ V({
42
+ ...B,
42
43
  name: e,
43
- slug: L ? z.slug : k(e)
44
+ slug: R ? B.slug : k(e)
44
45
  });
45
- }, re = async (e) => {
46
- if (e.preventDefault(), !(!z.name.trim() || !z.slug.trim())) {
47
- H(!0);
46
+ }, ae = async (e) => {
47
+ if (e.preventDefault(), !(!B.name.trim() || !B.slug.trim())) {
48
+ U(!0);
48
49
  try {
49
- L?.id ? (await N(L.id, z), X("success", "Category updated successfully!")) : (await M(z), X("success", "Category created successfully!")), $();
50
+ R?.id ? (await N(R.id, B), Z("success", F("support.settings.categories.notifications.updated", "Category updated successfully!"))) : (await M(B), Z("success", F("support.settings.categories.notifications.created", "Category created successfully!"))), $();
50
51
  } catch {
51
- X("error", `Failed to ${L ? "update" : "create"} category.`);
52
+ Z("error", R ? F("support.settings.categories.errors.updateFailed", "Failed to update category.") : F("support.settings.categories.errors.createFailed", "Failed to create category."));
52
53
  } finally {
53
- H(!1);
54
+ U(!1);
54
55
  }
55
56
  }
56
- }, ie = (e, t) => {
57
+ }, oe = (e, t) => {
57
58
  if (t > 0) {
58
- X("error", `Cannot delete category with ${t} articles. Move articles first.`);
59
+ Z("error", F("support.settings.categories.errors.deleteBlocked", "Cannot delete category with {{count}} articles. Move articles first.", { count: t }));
59
60
  return;
60
61
  }
61
- K(e);
62
- }, ae = async () => {
63
- let e = G;
62
+ q(e);
63
+ }, se = async () => {
64
+ let e = K;
64
65
  if (e) {
65
- K(null), W(e);
66
+ q(null), G(e);
66
67
  try {
67
- await P(e), X("success", "Category deleted successfully!");
68
+ await P(e), Z("success", F("support.settings.categories.notifications.deleted", "Category deleted successfully!"));
68
69
  } catch {
69
- X("error", "Failed to delete category.");
70
+ Z("error", F("support.settings.categories.errors.deleteFailed", "Failed to delete category."));
70
71
  } finally {
71
- W(null);
72
+ G(null);
72
73
  }
73
74
  }
74
- }, oe = async (e) => {
75
+ }, ce = async (e) => {
75
76
  if (e.id) try {
76
- await N(e.id, { isActive: !e.isActive }), X("success", `Category ${e.isActive ? "deactivated" : "activated"} successfully!`);
77
+ await N(e.id, { isActive: !e.isActive }), Z("success", e.isActive ? F("support.settings.categories.notifications.deactivated", "Category deactivated.") : F("support.settings.categories.notifications.activated", "Category activated."));
77
78
  } catch {
78
- X("error", "Failed to update category status.");
79
+ Z("error", F("support.settings.categories.errors.statusUpdateFailed", "Failed to update category status."));
79
80
  }
80
- }, se = [...j].sort((e, t) => (e.displayOrder ?? 0) - (t.displayOrder ?? 0));
81
- return /* @__PURE__ */ _("div", {
81
+ }, le = [...j].sort((e, t) => (e.displayOrder ?? 0) - (t.displayOrder ?? 0));
82
+ return /* @__PURE__ */ v("div", {
82
83
  className: "space-y-6",
83
84
  children: [
84
- q && /* @__PURE__ */ _("div", {
85
- className: `fixed right-4 top-[calc(var(--header-height,4rem)+1rem)] z-[200] flex items-center gap-3 px-5 py-3 rounded-xl shadow-2xl border-2 animate-in slide-in-from-top-4 duration-200 ${q.type === "success" ? "bg-status-success-bg-subtle text-status-success-text border-border-subtle" : "bg-status-error-bg-subtle text-status-error-text border-border-subtle"}`,
86
- children: [q.type === "success" ? /* @__PURE__ */ g(o, {
85
+ J && /* @__PURE__ */ v("div", {
86
+ className: `fixed right-4 top-[calc(var(--header-height,4rem)+1rem)] z-[200] flex items-center gap-3 px-5 py-3 rounded-xl shadow-2xl border-2 animate-in slide-in-from-top-4 duration-200 ${J.type === "success" ? "bg-status-success-bg-subtle text-status-success-text border-border-subtle" : "bg-status-error-bg-subtle text-status-error-text border-border-subtle"}`,
87
+ children: [J.type === "success" ? /* @__PURE__ */ _(s, {
87
88
  size: 20,
88
89
  className: "text-status-success-text"
89
- }) : /* @__PURE__ */ g(a, {
90
+ }) : /* @__PURE__ */ _(ee, {
90
91
  size: 20,
91
92
  className: "text-status-error-text"
92
- }), /* @__PURE__ */ g("span", {
93
+ }), /* @__PURE__ */ _("span", {
93
94
  className: "font-medium",
94
- children: q.message
95
+ children: J.message
95
96
  })]
96
97
  }),
97
- /* @__PURE__ */ g(T, {
98
- open: F,
98
+ /* @__PURE__ */ _(te, {
99
+ open: I,
99
100
  onOpenChange: (e) => {
100
101
  e || $();
101
102
  },
102
- children: /* @__PURE__ */ _(E, {
103
+ children: /* @__PURE__ */ v(ne, {
103
104
  className: "w-full max-w-lg max-h-[90vh] overflow-y-auto",
104
- children: [/* @__PURE__ */ g(D, { children: /* @__PURE__ */ g(O, { children: L ? "Edit Category" : "Create Category" }) }), /* @__PURE__ */ _("form", {
105
- onSubmit: re,
105
+ children: [/* @__PURE__ */ _(D, { children: /* @__PURE__ */ _(O, { children: R ? F("support.settings.categories.modal.editTitle", "Edit Category") : F("support.settings.categories.modal.createTitle", "Create Category") }) }), /* @__PURE__ */ v("form", {
106
+ onSubmit: ae,
106
107
  className: "space-y-5",
107
108
  children: [
108
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ _("label", {
109
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ v("label", {
109
110
  htmlFor: "ticket-category-name",
110
111
  className: "block text-sm font-medium text-text-primary mb-2",
111
- children: ["Category Name ", /* @__PURE__ */ g("span", {
112
- className: "text-status-error-text",
113
- children: "*"
114
- })]
115
- }), /* @__PURE__ */ g("input", {
112
+ children: [F("support.settings.categories.form.nameLabel", "Category Name"), " *"]
113
+ }), /* @__PURE__ */ _("input", {
116
114
  id: "ticket-category-name",
117
115
  type: "text",
118
- "aria-label": "Category Name",
119
- value: z.name,
120
- onChange: (e) => ne(e.target.value),
121
- placeholder: "e.g., Technical Support",
116
+ "aria-label": F("support.settings.categories.form.nameLabel", "Category Name"),
117
+ value: B.name,
118
+ onChange: (e) => ie(e.target.value),
119
+ placeholder: F("support.settings.categories.form.namePlaceholder", "e.g., Technical Support"),
122
120
  className: "w-full px-4 py-2.5 rounded-lg border border-border-default bg-bg-surface text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary",
123
121
  required: !0
124
122
  })] }),
125
- /* @__PURE__ */ _("div", { children: [
126
- /* @__PURE__ */ _("label", {
123
+ /* @__PURE__ */ v("div", { children: [
124
+ /* @__PURE__ */ v("label", {
127
125
  htmlFor: "ticket-category-slug",
128
126
  className: "block text-sm font-medium text-text-primary mb-2",
129
- children: ["Slug ", /* @__PURE__ */ g("span", {
130
- className: "text-status-error-text",
131
- children: "*"
132
- })]
127
+ children: [F("support.settings.categories.form.slugLabel", "Slug"), " *"]
133
128
  }),
134
- /* @__PURE__ */ g("input", {
129
+ /* @__PURE__ */ _("input", {
135
130
  id: "ticket-category-slug",
136
131
  type: "text",
137
- "aria-label": "Slug",
138
- value: z.slug,
139
- onChange: (e) => B({
140
- ...z,
132
+ "aria-label": F("support.settings.categories.form.slugLabel", "Slug"),
133
+ value: B.slug,
134
+ onChange: (e) => V({
135
+ ...B,
141
136
  slug: e.target.value
142
137
  }),
143
- placeholder: "technical-support",
138
+ placeholder: F("support.settings.categories.form.slugPlaceholder", "technical-support"),
144
139
  className: "w-full px-4 py-2.5 rounded-lg border border-border-default bg-bg-surface text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary",
145
140
  required: !0
146
141
  }),
147
- /* @__PURE__ */ g("p", {
142
+ /* @__PURE__ */ _("p", {
148
143
  className: "text-xs text-text-secondary mt-1",
149
- children: "URL-friendly identifier (auto-generated from name)"
144
+ children: F("support.settings.categories.form.slugHint", "URL-friendly identifier (auto-generated from name)")
150
145
  })
151
146
  ] }),
152
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
147
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
153
148
  className: "block text-sm font-medium text-text-primary mb-2",
154
149
  htmlFor: "ticketcategoriessettings-description-0",
155
- children: "Description"
156
- }), /* @__PURE__ */ g("textarea", {
150
+ children: F("support.settings.categories.form.descriptionLabel", "Description")
151
+ }), /* @__PURE__ */ _("textarea", {
157
152
  id: "ticketcategoriessettings-description-0",
158
- "aria-label": "Description",
159
- value: z.description,
160
- onChange: (e) => B({
161
- ...z,
153
+ "aria-label": F("support.settings.categories.form.descriptionLabel", "Description"),
154
+ value: B.description,
155
+ onChange: (e) => V({
156
+ ...B,
162
157
  description: e.target.value
163
158
  }),
164
- placeholder: "Brief description of this category...",
159
+ placeholder: F("support.settings.categories.form.descriptionPlaceholder", "Brief description of this category..."),
165
160
  rows: 3,
166
161
  className: "w-full px-4 py-2.5 rounded-lg border border-border-default bg-bg-surface text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary resize-none"
167
162
  })] }),
168
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("span", {
163
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("span", {
169
164
  id: "ticket-category-color-heading",
170
165
  className: "block text-sm font-medium text-text-primary mb-2",
171
- children: "Color"
172
- }), /* @__PURE__ */ _("div", {
166
+ children: F("support.settings.categories.form.colorLabel", "Color")
167
+ }), /* @__PURE__ */ v("div", {
173
168
  className: "flex flex-col gap-3 sm:flex-row sm:items-center",
174
- children: [/* @__PURE__ */ g("div", {
169
+ children: [/* @__PURE__ */ _("div", {
175
170
  className: "flex flex-wrap gap-2",
176
- children: e.map((e) => /* @__PURE__ */ g("button", {
171
+ children: t.map((e) => /* @__PURE__ */ _("button", {
177
172
  type: "button",
178
- onClick: () => B({
179
- ...z,
173
+ onClick: () => V({
174
+ ...B,
180
175
  color: e.value
181
176
  }),
182
- className: `min-h-11 min-w-11 rounded-full border-2 transition-all ${e.swatchClass} ${z.color === e.value ? "border-foreground scale-110" : "border-transparent"}`,
183
- "aria-label": `Use ${e.label} category color`
177
+ className: `min-h-11 min-w-11 rounded-full border-2 transition-all ${e.swatchClass} ${B.color === e.value ? "border-foreground scale-110" : "border-transparent"}`,
178
+ "aria-label": F("support.settings.categories.form.colorAria", "Use {{color}} category color", { color: e.label })
184
179
  }, e.value))
185
- }), /* @__PURE__ */ g("select", {
180
+ }), /* @__PURE__ */ _("select", {
186
181
  "aria-labelledby": "ticket-category-color-heading",
187
- value: z.color,
188
- onChange: (e) => B({
189
- ...z,
182
+ value: B.color,
183
+ onChange: (e) => V({
184
+ ...B,
190
185
  color: e.target.value
191
186
  }),
192
187
  className: "min-h-11 rounded-lg border border-border-default bg-bg-surface px-3 text-sm text-text-primary",
193
- children: e.map((e) => /* @__PURE__ */ g("option", {
188
+ children: t.map((e) => /* @__PURE__ */ _("option", {
194
189
  value: e.value,
195
190
  children: e.label
196
191
  }, e.value))
197
192
  })]
198
193
  })] }),
199
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
194
+ /* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("label", {
200
195
  className: "block text-sm font-medium text-text-primary mb-2",
201
196
  htmlFor: "ticketcategoriessettings-icon-emoji-2",
202
- children: "Icon (emoji)"
203
- }), /* @__PURE__ */ g("input", {
197
+ children: F("support.settings.categories.form.iconLabel", "Icon (emoji)")
198
+ }), /* @__PURE__ */ _("input", {
204
199
  id: "ticketcategoriessettings-icon-emoji-2",
205
200
  type: "text",
206
- "aria-label": "Icon (emoji)",
207
- value: z.icon,
208
- onChange: (e) => B({
209
- ...z,
201
+ "aria-label": F("support.settings.categories.form.iconLabel", "Icon (emoji)"),
202
+ value: B.icon,
203
+ onChange: (e) => V({
204
+ ...B,
210
205
  icon: e.target.value
211
206
  }),
212
- placeholder: "e.g., 🛠️",
207
+ placeholder: F("support.settings.categories.form.iconPlaceholder", "e.g., 🛠️"),
213
208
  className: "w-full px-4 py-2.5 rounded-lg border border-border-default bg-bg-surface text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-primary/20 focus:border-primary",
214
209
  maxLength: 4
215
210
  })] }),
216
- /* @__PURE__ */ _("label", {
211
+ /* @__PURE__ */ v("label", {
217
212
  className: "flex items-center gap-3 cursor-pointer",
218
- children: [/* @__PURE__ */ g("input", {
213
+ children: [/* @__PURE__ */ _("input", {
219
214
  type: "checkbox",
220
- "aria-label": "Active",
221
- checked: z.isActive,
222
- onChange: (e) => B({
223
- ...z,
215
+ "aria-label": F("support.settings.categories.form.activeLabel", "Active"),
216
+ checked: B.isActive,
217
+ onChange: (e) => V({
218
+ ...B,
224
219
  isActive: e.target.checked
225
220
  }),
226
221
  className: "size-4 rounded border-border-default text-primary focus:ring-primary"
227
- }), /* @__PURE__ */ g("span", {
222
+ }), /* @__PURE__ */ _("span", {
228
223
  className: "text-sm text-text-primary",
229
- children: "Active"
224
+ children: F("support.settings.categories.form.activeLabel", "Active")
230
225
  })]
231
226
  }),
232
- /* @__PURE__ */ _("div", {
227
+ /* @__PURE__ */ v("div", {
233
228
  className: "flex flex-col gap-3 pt-4 sm:flex-row",
234
- children: [/* @__PURE__ */ g("button", {
229
+ children: [/* @__PURE__ */ _("button", {
235
230
  type: "submit",
236
- disabled: V || !z.name.trim() || !z.slug.trim(),
231
+ disabled: H || !B.name.trim() || !B.slug.trim(),
237
232
  className: "min-h-11 flex-1 flex items-center justify-center gap-2 px-4 py-2.5 rounded-lg bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-50 disabled:cursor-not-allowed transition-colors",
238
- children: V ? /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g(u, {
233
+ children: H ? /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(d, {
239
234
  size: 18,
240
235
  className: "animate-spin"
241
- }), L ? "Updating..." : "Creating..."] }) : /* @__PURE__ */ g(h, { children: L ? "Update Category" : "Create Category" })
242
- }), /* @__PURE__ */ g("button", {
236
+ }), R ? F("support.settings.categories.actions.updating", "Updating...") : F("support.settings.categories.actions.creating", "Creating...")] }) : /* @__PURE__ */ _(g, { children: R ? F("support.settings.categories.actions.update", "Update Category") : F("support.settings.categories.actions.create", "Create Category") })
237
+ }), /* @__PURE__ */ _("button", {
243
238
  type: "button",
244
239
  onClick: $,
245
240
  className: "min-h-11 px-4 py-2.5 rounded-lg border border-border-default hover:bg-bg-sunken transition-colors",
246
- children: "Cancel"
241
+ children: F("support.settings.categories.actions.cancel", "Cancel")
247
242
  })]
248
243
  })
249
244
  ]
250
245
  })]
251
246
  })
252
247
  }),
253
- /* @__PURE__ */ _("div", {
248
+ /* @__PURE__ */ v("div", {
254
249
  className: "flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",
255
- children: [/* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("h2", {
250
+ children: [/* @__PURE__ */ v("div", { children: [/* @__PURE__ */ _("h2", {
256
251
  className: "text-xl font-semibold mb-2 text-text-primary",
257
- children: "Ticket Categories"
258
- }), /* @__PURE__ */ g("p", {
252
+ children: F("support.settings.categories.title", "Ticket Categories")
253
+ }), /* @__PURE__ */ _("p", {
259
254
  className: "text-sm text-text-secondary",
260
- children: "Organize tickets and knowledge base articles by category"
261
- })] }), /* @__PURE__ */ _("button", {
255
+ children: F("support.settings.categories.subtitle", "Organize tickets and knowledge base articles by category")
256
+ })] }), /* @__PURE__ */ v("button", {
262
257
  type: "button",
263
- onClick: Z,
258
+ onClick: Q,
264
259
  className: "min-h-11 inline-flex items-center justify-center gap-2 px-4 py-2 rounded-lg transition-colors bg-action-primary-bg text-action-primary-text hover:bg-action-primary-bg/90",
265
- children: [/* @__PURE__ */ g(d, { size: 20 }), "New Category"]
260
+ children: [/* @__PURE__ */ _(f, { size: 20 }), F("support.settings.categories.actions.new", "New Category")]
266
261
  })]
267
262
  }),
268
- /* @__PURE__ */ _("div", {
263
+ /* @__PURE__ */ v("div", {
269
264
  className: "space-y-2",
270
- children: [se.map((e) => /* @__PURE__ */ _("div", {
265
+ children: [le.map((e) => /* @__PURE__ */ v("div", {
271
266
  className: `p-4 rounded-lg border bg-bg-surface flex flex-col gap-4 sm:flex-row sm:items-center ${e.isActive === !1 ? "border-border-seam/50 opacity-60" : "border-border-seam"}`,
272
267
  children: [
273
- /* @__PURE__ */ g("div", {
268
+ /* @__PURE__ */ _("div", {
274
269
  className: "text-text-secondary cursor-grab",
275
- children: /* @__PURE__ */ g(l, { size: 20 })
276
- }),
277
- /* @__PURE__ */ g("div", {
278
- className: `size-10 rounded-lg flex items-center justify-center text-on-accent text-xl flex-shrink-0 ${n(e.color)}`,
279
- children: e.icon || /* @__PURE__ */ g(c, { size: 20 })
270
+ children: /* @__PURE__ */ _(u, { size: 20 })
280
271
  }),
281
272
  /* @__PURE__ */ _("div", {
273
+ className: `size-10 rounded-lg flex items-center justify-center text-on-accent text-xl flex-shrink-0 ${r(e.color)}`,
274
+ children: e.icon || /* @__PURE__ */ _(l, { size: 20 })
275
+ }),
276
+ /* @__PURE__ */ v("div", {
282
277
  className: "flex-1 min-w-0",
283
278
  children: [
284
- /* @__PURE__ */ _("div", {
279
+ /* @__PURE__ */ v("div", {
285
280
  className: "flex items-center gap-2",
286
- children: [/* @__PURE__ */ g("h3", {
281
+ children: [/* @__PURE__ */ _("h3", {
287
282
  className: "font-semibold text-text-primary",
288
283
  children: e.name
289
- }), e.isActive === !1 && /* @__PURE__ */ g("span", {
284
+ }), e.isActive === !1 && /* @__PURE__ */ _("span", {
290
285
  className: "text-xs px-2 py-0.5 rounded bg-bg-sunken text-text-secondary",
291
- children: "Inactive"
286
+ children: F("support.settings.categories.inactiveBadge", "Inactive")
292
287
  })]
293
288
  }),
294
- /* @__PURE__ */ _("p", {
289
+ /* @__PURE__ */ v("p", {
295
290
  className: "text-sm text-text-secondary",
296
291
  children: [
297
292
  "/",
298
293
  e.slug,
299
- " • ",
300
- e.articleCount ?? 0,
301
- " articles"
294
+ " •",
295
+ " ",
296
+ F("support.settings.categories.articleCount", "{{count}} articles", { count: e.articleCount ?? 0 })
302
297
  ]
303
298
  }),
304
- e.description && /* @__PURE__ */ g("p", {
299
+ e.description && /* @__PURE__ */ _("p", {
305
300
  className: "text-xs text-text-secondary mt-1 line-clamp-1",
306
301
  children: e.description
307
302
  })
308
303
  ]
309
304
  }),
310
- /* @__PURE__ */ _("div", {
305
+ /* @__PURE__ */ v("div", {
311
306
  className: "flex w-full items-center justify-end gap-1 sm:w-auto",
312
307
  children: [
313
- /* @__PURE__ */ g("button", {
308
+ /* @__PURE__ */ _("button", {
314
309
  type: "button",
315
- onClick: () => oe(e),
310
+ onClick: () => ce(e),
316
311
  className: "min-h-11 min-w-11 p-2 rounded hover:bg-bg-sunken text-text-secondary transition-colors",
317
- title: e.isActive ? "Deactivate" : "Activate",
318
- "aria-label": e.isActive ? "Deactivate category" : "Activate category",
319
- children: e.isActive ? /* @__PURE__ */ g(p, {
312
+ title: e.isActive ? F("support.settings.categories.actions.deactivate", "Deactivate") : F("support.settings.categories.actions.activate", "Activate"),
313
+ "aria-label": e.isActive ? F("support.settings.categories.aria.deactivate", "Deactivate category") : F("support.settings.categories.aria.activate", "Activate category"),
314
+ children: e.isActive ? /* @__PURE__ */ _(m, {
320
315
  size: 20,
321
316
  className: "text-status-success-text"
322
- }) : /* @__PURE__ */ g(f, { size: 20 })
317
+ }) : /* @__PURE__ */ _(p, { size: 20 })
323
318
  }),
324
- /* @__PURE__ */ g("button", {
319
+ /* @__PURE__ */ _("button", {
325
320
  type: "button",
326
- onClick: () => Q(e),
321
+ onClick: () => re(e),
327
322
  className: "min-h-11 min-w-11 p-2 rounded hover:bg-bg-sunken text-text-secondary transition-colors",
328
- title: "Edit category",
329
- "aria-label": "Edit category",
330
- children: /* @__PURE__ */ g(s, { size: 18 })
323
+ title: F("support.settings.categories.actions.edit", "Edit category"),
324
+ "aria-label": F("support.settings.categories.aria.edit", "Edit category"),
325
+ children: /* @__PURE__ */ _(c, { size: 18 })
331
326
  }),
332
- /* @__PURE__ */ g("button", {
327
+ /* @__PURE__ */ _("button", {
333
328
  type: "button",
334
- onClick: () => e.id && ie(e.id, e.articleCount ?? 0),
335
- disabled: U === e.id,
329
+ onClick: () => e.id && oe(e.id, e.articleCount ?? 0),
330
+ disabled: W === e.id,
336
331
  className: "min-h-11 min-w-11 p-2 rounded hover:bg-bg-sunken text-status-error-text transition-colors disabled:opacity-50",
337
- title: "Delete category",
338
- "aria-label": "Delete category",
339
- children: U === e.id ? /* @__PURE__ */ g(u, {
332
+ title: F("support.settings.categories.actions.delete", "Delete category"),
333
+ "aria-label": F("support.settings.categories.aria.delete", "Delete category"),
334
+ children: W === e.id ? /* @__PURE__ */ _(d, {
340
335
  size: 18,
341
336
  className: "animate-spin"
342
- }) : /* @__PURE__ */ g(m, { size: 18 })
337
+ }) : /* @__PURE__ */ _(h, { size: 18 })
343
338
  })
344
339
  ]
345
340
  })
346
341
  ]
347
- }, e.id)), j.length === 0 && /* @__PURE__ */ _("div", {
342
+ }, e.id)), j.length === 0 && /* @__PURE__ */ v("div", {
348
343
  className: "text-center py-12 border border-dashed border-border-subtle rounded-lg",
349
344
  children: [
350
- /* @__PURE__ */ g(c, {
345
+ /* @__PURE__ */ _(l, {
351
346
  size: 48,
352
347
  className: "text-text-secondary mx-auto"
353
348
  }),
354
- /* @__PURE__ */ g("p", {
349
+ /* @__PURE__ */ _("p", {
355
350
  className: "mt-4 text-text-secondary",
356
- children: "No categories configured"
351
+ children: F("support.settings.categories.empty.title", "No categories configured")
357
352
  }),
358
- /* @__PURE__ */ g("button", {
353
+ /* @__PURE__ */ _("button", {
359
354
  type: "button",
360
- onClick: Z,
355
+ onClick: Q,
361
356
  className: "mt-4 text-primary hover:underline",
362
- children: "Create your first category"
357
+ children: F("support.settings.categories.empty.createLink", "Create your first category")
363
358
  })
364
359
  ]
365
360
  })]
366
361
  }),
367
- /* @__PURE__ */ g(v, {
368
- open: G !== null,
362
+ /* @__PURE__ */ _(y, {
363
+ open: K !== null,
369
364
  onOpenChange: (e) => {
370
- e || K(null);
365
+ e || q(null);
371
366
  },
372
- children: /* @__PURE__ */ _(x, { children: [/* @__PURE__ */ _(C, { children: [/* @__PURE__ */ g(w, { children: "Delete category?" }), /* @__PURE__ */ g(S, { children: "Are you sure you want to delete this category? This action cannot be undone." })] }), /* @__PURE__ */ _(te, { children: [/* @__PURE__ */ g(b, { children: "Cancel" }), /* @__PURE__ */ g(y, {
373
- onClick: ae,
374
- children: "Delete"
367
+ children: /* @__PURE__ */ v(S, { children: [/* @__PURE__ */ v(T, { children: [/* @__PURE__ */ _(E, { children: F("support.settings.categories.deleteDialog.title", "Delete category?") }), /* @__PURE__ */ _(C, { children: F("support.settings.categories.deleteDialog.description", "Are you sure you want to delete this category? This action cannot be undone.") })] }), /* @__PURE__ */ v(w, { children: [/* @__PURE__ */ _(x, { children: F("support.settings.categories.deleteDialog.cancel", "Cancel") }), /* @__PURE__ */ _(b, {
368
+ onClick: se,
369
+ children: F("support.settings.categories.deleteDialog.confirm", "Delete")
375
370
  })] })] })
376
371
  })
377
372
  ]