hazo_ui 6.12.0 → 6.12.4

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/index.js CHANGED
@@ -112,8 +112,8 @@ var require_extends = __commonJS({
112
112
  function _extends11() {
113
113
  return module.exports = _extends11 = Object.assign ? Object.assign.bind() : function(n) {
114
114
  for (var e = 1; e < arguments.length; e++) {
115
- var t4 = arguments[e];
116
- for (var r in t4) ({}).hasOwnProperty.call(t4, r) && (n[r] = t4[r]);
115
+ var t22 = arguments[e];
116
+ for (var r in t22) ({}).hasOwnProperty.call(t22, r) && (n[r] = t22[r]);
117
117
  }
118
118
  return n;
119
119
  }, module.exports.__esModule = true, module.exports["default"] = module.exports, _extends11.apply(null, arguments);
@@ -127,12 +127,12 @@ var require_objectWithoutPropertiesLoose = __commonJS({
127
127
  "../node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js"(exports, module) {
128
128
  function _objectWithoutPropertiesLoose10(r, e) {
129
129
  if (null == r) return {};
130
- var t4 = {};
130
+ var t22 = {};
131
131
  for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
132
132
  if (-1 !== e.indexOf(n)) continue;
133
- t4[n] = r[n];
133
+ t22[n] = r[n];
134
134
  }
135
- return t4;
135
+ return t22;
136
136
  }
137
137
  module.exports = _objectWithoutPropertiesLoose10, module.exports.__esModule = true, module.exports["default"] = module.exports;
138
138
  }
@@ -715,7 +715,70 @@ var en_default = {
715
715
  "filter.no_fields_available": "No fields available.",
716
716
  "filter.clear_all": "Clear all",
717
717
  "filter.cancel": "Cancel",
718
- "filter.apply": "Apply"
718
+ "filter.apply": "Apply",
719
+ "sort.title": "Sort",
720
+ "sort.description": "Add fields to sort by, drag to reorder, toggle ascending or descending.",
721
+ "sort.search_fields": "Search fields...",
722
+ "sort.open_dialog_aria": "Open sort dialog",
723
+ "sort.clear_all": "Clear all",
724
+ "sort.cancel": "Cancel",
725
+ "sort.apply": "Apply",
726
+ "canvas_toolbar.bold": "Bold",
727
+ "canvas_toolbar.italic": "Italic",
728
+ "canvas_toolbar.underline": "Underline",
729
+ "canvas_toolbar.align_left": "Align left",
730
+ "canvas_toolbar.align_center": "Align center",
731
+ "canvas_toolbar.align_right": "Align right",
732
+ "canvas_toolbar.text_color": "Text color",
733
+ "canvas_toolbar.font_family": "Font family",
734
+ "canvas_toolbar.align_top": "Align top",
735
+ "canvas_toolbar.align_middle": "Align middle",
736
+ "canvas_toolbar.align_bottom": "Align bottom",
737
+ "canvas_toolbar.bullet_list": "Bullet list",
738
+ "toast.permission_required": "Permission required",
739
+ "toast.permission_denied_message": "You do not have permission to perform this action.",
740
+ "error.something_went_wrong": "Something went wrong",
741
+ "error.dismiss": "Dismiss",
742
+ "loading.taking_longer": "This is taking longer than expected",
743
+ "notification.loading": "Loading notifications",
744
+ "notification.mark_all_read": "Mark all as read",
745
+ "notification.unread": "Unread",
746
+ "confirm.cancel": "Cancel",
747
+ "icon_picker.search_placeholder": "Search icons...",
748
+ "common.loading": "Loading...",
749
+ "common.cancel": "Cancel",
750
+ "common.search": "Search...",
751
+ "dialog.default_title": "Action required",
752
+ "dialog.cancel": "Cancel",
753
+ "dialog.ok": "OK",
754
+ "dialog.confirm": "Confirm",
755
+ "dialog.close": "Close",
756
+ "kanban.status_label": "Status",
757
+ "kanban.edit_fallback": "Edit {{id}}",
758
+ "kanban.update_description": "Update card details below.",
759
+ "kanban.saving": "Saving\u2026",
760
+ "kanban.save": "Save",
761
+ "kanban.cancel": "Cancel",
762
+ "kanban.select_placeholder": "Select {{label}}\u2026",
763
+ "kanban.select_priority": "Select priority\u2026",
764
+ "kanban.select_status": "Select status\u2026",
765
+ "markdown.placeholder": "Write in Markdown\u2026",
766
+ "markdown.upload_failed": "Upload failed.",
767
+ "markdown.loading_editor": "Loading editor\u2026",
768
+ "markdown.uploading_image": "Uploading image\u2026",
769
+ "cropper.title": "Crop photo",
770
+ "cropper.save": "Save",
771
+ "cropper.cancel": "Cancel",
772
+ "cropper.zoom": "Zoom",
773
+ "memory.search_placeholder": "Search history\u2026",
774
+ "memory.no_history": "No history yet",
775
+ "memory.remove_aria": "Remove {{label}} from history",
776
+ "celebration.close": "Close celebration",
777
+ "celebration.download_png": "Download PNG",
778
+ "celebration.share": "Share",
779
+ "celebration.copy_image": "Copy image",
780
+ "celebration.dismiss": "Dismiss",
781
+ "charts.date_range": "Date range"
719
782
  };
720
783
  var t = createPackageT("hazo_ui", en_default);
721
784
  function FilterFieldItem({
@@ -1164,6 +1227,7 @@ function HazoUiMultiFilterDialog({
1164
1227
  ] })
1165
1228
  ] });
1166
1229
  }
1230
+ var t2 = createPackageT("hazo_ui", en_default);
1167
1231
  function SortableSortFieldItem({
1168
1232
  sortConfig,
1169
1233
  fieldLabel,
@@ -1274,8 +1338,8 @@ function HazoUiMultiSortDialog({
1274
1338
  availableFields,
1275
1339
  onSortChange,
1276
1340
  initialSortFields = [],
1277
- title = "Sort",
1278
- description = "Add fields to sort by, drag to reorder, toggle ascending or descending.",
1341
+ title = t2("sort.title"),
1342
+ description = t2("sort.description"),
1279
1343
  headerBackgroundColor,
1280
1344
  headerTextColor,
1281
1345
  submitButtonBackgroundColor,
@@ -1393,7 +1457,7 @@ function HazoUiMultiSortDialog({
1393
1457
  variant: "outline",
1394
1458
  size: "sm",
1395
1459
  className: "cls_sort_button",
1396
- "aria-label": "Open sort dialog",
1460
+ "aria-label": t2("sort.open_dialog_aria"),
1397
1461
  children: [
1398
1462
  /* @__PURE__ */ jsx(
1399
1463
  ArrowUpDown,
@@ -1466,7 +1530,7 @@ function HazoUiMultiSortDialog({
1466
1530
  }
1467
1531
  ) }),
1468
1532
  /* @__PURE__ */ jsx(PopoverContent, { className: "cls_combobox_popover w-[var(--radix-popover-trigger-width)] p-0", align: "start", children: /* @__PURE__ */ jsxs(Command, { children: [
1469
- /* @__PURE__ */ jsx(CommandInput, { placeholder: "Search fields...", className: "cls_command_input" }),
1533
+ /* @__PURE__ */ jsx(CommandInput, { placeholder: t2("sort.search_fields"), className: "cls_command_input" }),
1470
1534
  /* @__PURE__ */ jsx(CommandList, { children: availableFieldsToAdd.length === 0 ? /* @__PURE__ */ jsx(CommandEmpty, { children: "No fields available." }) : /* @__PURE__ */ jsx(CommandGroup, { children: availableFieldsToAdd.map((field) => /* @__PURE__ */ jsx(
1471
1535
  CommandItem,
1472
1536
  {
@@ -1489,7 +1553,7 @@ function HazoUiMultiSortDialog({
1489
1553
  onClick: handleClearAll,
1490
1554
  className: "cls_clear_all_btn text-muted-foreground hover:text-foreground",
1491
1555
  style: clearButtonStyles,
1492
- children: "Clear all"
1556
+ children: t2("sort.clear_all")
1493
1557
  }
1494
1558
  ) }),
1495
1559
  /* @__PURE__ */ jsxs("div", { className: "cls_footer_right flex items-center gap-2", children: [
@@ -1501,7 +1565,7 @@ function HazoUiMultiSortDialog({
1501
1565
  onClick: handleCancel,
1502
1566
  className: "cls_cancel_btn",
1503
1567
  style: cancelButtonStyles,
1504
- children: "Cancel"
1568
+ children: t2("sort.cancel")
1505
1569
  }
1506
1570
  ),
1507
1571
  /* @__PURE__ */ jsx(
@@ -1511,7 +1575,7 @@ function HazoUiMultiSortDialog({
1511
1575
  onClick: handleApply,
1512
1576
  className: "cls_apply_btn",
1513
1577
  style: submitButtonStyles,
1514
- children: "Apply"
1578
+ children: t2("sort.apply")
1515
1579
  }
1516
1580
  )
1517
1581
  ] })
@@ -1930,6 +1994,7 @@ var TabsContent = React27.forwardRef(({ className, ...props }, ref) => /* @__PUR
1930
1994
  }
1931
1995
  ));
1932
1996
  TabsContent.displayName = TabsPrimitive.Content.displayName;
1997
+ var t3 = createPackageT("hazo_ui", en_default);
1933
1998
  function isLucideValue(value) {
1934
1999
  return value.startsWith("lucide:");
1935
2000
  }
@@ -2195,7 +2260,7 @@ function HazoUiIconPicker({
2195
2260
  type: "text",
2196
2261
  value: search,
2197
2262
  onChange: (e) => set_search(e.target.value),
2198
- placeholder: "Search icons...",
2263
+ placeholder: t3("icon_picker.search_placeholder"),
2199
2264
  className: cn(
2200
2265
  "cls_hazo_ui_icon_picker_search",
2201
2266
  "mb-2 flex h-9 w-full rounded-md border border-input bg-background px-3 py-1 text-sm",
@@ -3641,10 +3706,10 @@ var BLOCK_TYPE_LABEL_KEYS = {
3641
3706
  "code-block": "rte.block_type.code_block",
3642
3707
  blockquote: "rte.block_type.blockquote"
3643
3708
  };
3644
- function get_translated_block_types(t4) {
3709
+ function get_translated_block_types(t22) {
3645
3710
  return BLOCK_TYPES.map((type) => ({
3646
3711
  ...type,
3647
- label: t4(BLOCK_TYPE_LABEL_KEYS[type.value])
3712
+ label: t22(BLOCK_TYPE_LABEL_KEYS[type.value])
3648
3713
  }));
3649
3714
  }
3650
3715
 
@@ -3691,7 +3756,7 @@ function get_file_extension(filename) {
3691
3756
  function is_image_file(mime_type) {
3692
3757
  return mime_type.startsWith("image/");
3693
3758
  }
3694
- var t2 = createPackageT("hazo_ui", en_default);
3759
+ var t4 = createPackageT("hazo_ui", en_default);
3695
3760
  var ALL_ON = {
3696
3761
  undo_redo: true,
3697
3762
  block_type: true,
@@ -3746,7 +3811,7 @@ var Toolbar = ({
3746
3811
  }
3747
3812
  const tb = { ...ALL_ON, ...toolbar };
3748
3813
  const font_family_options = font_families && font_families.length > 0 ? font_families : FONT_FAMILIES;
3749
- const block_type_options = get_translated_block_types(t2);
3814
+ const block_type_options = get_translated_block_types(t4);
3750
3815
  const get_current_font_size = () => {
3751
3816
  const attrs = editor.getAttributes("textStyle");
3752
3817
  return attrs.fontSize || FONT_SIZE_CONFIG.default;
@@ -3890,7 +3955,7 @@ var Toolbar = ({
3890
3955
  {
3891
3956
  onClick: () => editor.chain().focus().undo().run(),
3892
3957
  disabled: !editor.can().undo(),
3893
- tooltip: t2("rte.undo"),
3958
+ tooltip: t4("rte.undo"),
3894
3959
  children: /* @__PURE__ */ jsx(LuUndo2, { className: "h-4 w-4" })
3895
3960
  },
3896
3961
  "undo"
@@ -3900,7 +3965,7 @@ var Toolbar = ({
3900
3965
  {
3901
3966
  onClick: () => editor.chain().focus().redo().run(),
3902
3967
  disabled: !editor.can().redo(),
3903
- tooltip: t2("rte.redo"),
3968
+ tooltip: t4("rte.redo"),
3904
3969
  children: /* @__PURE__ */ jsx(LuRedo2, { className: "h-4 w-4" })
3905
3970
  },
3906
3971
  "redo"
@@ -3941,7 +4006,7 @@ var Toolbar = ({
3941
4006
  ToolbarButton,
3942
4007
  {
3943
4008
  onClick: () => handle_font_size_change(-2),
3944
- tooltip: t2("rte.decrease_font_size"),
4009
+ tooltip: t4("rte.decrease_font_size"),
3945
4010
  children: /* @__PURE__ */ jsx(LuMinus, { className: "h-3 w-3" })
3946
4011
  }
3947
4012
  ),
@@ -3950,7 +4015,7 @@ var Toolbar = ({
3950
4015
  ToolbarButton,
3951
4016
  {
3952
4017
  onClick: () => handle_font_size_change(FONT_SIZE_CONFIG.step),
3953
- tooltip: t2("rte.increase_font_size"),
4018
+ tooltip: t4("rte.increase_font_size"),
3954
4019
  children: /* @__PURE__ */ jsx(LuPlus, { className: "h-3 w-3" })
3955
4020
  }
3956
4021
  )
@@ -3968,7 +4033,7 @@ var Toolbar = ({
3968
4033
  {
3969
4034
  onClick: () => editor.chain().focus().toggleBold().run(),
3970
4035
  is_active: editor.isActive("bold"),
3971
- tooltip: t2("rte.bold"),
4036
+ tooltip: t4("rte.bold"),
3972
4037
  children: /* @__PURE__ */ jsx(LuBold, { className: "h-4 w-4" })
3973
4038
  },
3974
4039
  "bold"
@@ -3982,7 +4047,7 @@ var Toolbar = ({
3982
4047
  {
3983
4048
  onClick: () => editor.chain().focus().toggleItalic().run(),
3984
4049
  is_active: editor.isActive("italic"),
3985
- tooltip: t2("rte.italic"),
4050
+ tooltip: t4("rte.italic"),
3986
4051
  children: /* @__PURE__ */ jsx(LuItalic, { className: "h-4 w-4" })
3987
4052
  },
3988
4053
  "italic"
@@ -3996,7 +4061,7 @@ var Toolbar = ({
3996
4061
  {
3997
4062
  onClick: () => editor.chain().focus().toggleUnderline().run(),
3998
4063
  is_active: editor.isActive("underline"),
3999
- tooltip: t2("rte.underline"),
4064
+ tooltip: t4("rte.underline"),
4000
4065
  children: /* @__PURE__ */ jsx(LuUnderline, { className: "h-4 w-4" })
4001
4066
  },
4002
4067
  "underline"
@@ -4010,7 +4075,7 @@ var Toolbar = ({
4010
4075
  {
4011
4076
  onClick: () => editor.chain().focus().toggleStrike().run(),
4012
4077
  is_active: editor.isActive("strike"),
4013
- tooltip: t2("rte.strikethrough"),
4078
+ tooltip: t4("rte.strikethrough"),
4014
4079
  children: /* @__PURE__ */ jsx(LuStrikethrough, { className: "h-4 w-4" })
4015
4080
  },
4016
4081
  "strike"
@@ -4024,7 +4089,7 @@ var Toolbar = ({
4024
4089
  {
4025
4090
  onClick: () => editor.chain().focus().toggleSubscript().run(),
4026
4091
  is_active: editor.isActive("subscript"),
4027
- tooltip: t2("rte.subscript"),
4092
+ tooltip: t4("rte.subscript"),
4028
4093
  children: /* @__PURE__ */ jsx(LuSubscript, { className: "h-4 w-4" })
4029
4094
  },
4030
4095
  "sub"
@@ -4038,7 +4103,7 @@ var Toolbar = ({
4038
4103
  {
4039
4104
  onClick: () => editor.chain().focus().toggleSuperscript().run(),
4040
4105
  is_active: editor.isActive("superscript"),
4041
- tooltip: t2("rte.superscript"),
4106
+ tooltip: t4("rte.superscript"),
4042
4107
  children: /* @__PURE__ */ jsx(LuSuperscript, { className: "h-4 w-4" })
4043
4108
  },
4044
4109
  "super"
@@ -4052,7 +4117,7 @@ var Toolbar = ({
4052
4117
  if (tb.link) {
4053
4118
  items.push(
4054
4119
  /* @__PURE__ */ jsxs(Popover, { open: link_popover_open, onOpenChange: set_link_popover_open, children: [
4055
- /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(ToolbarButton, { is_active: editor.isActive("link"), tooltip: t2("rte.link"), children: /* @__PURE__ */ jsx(LuLink, { className: "h-4 w-4" }) }) }),
4120
+ /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(ToolbarButton, { is_active: editor.isActive("link"), tooltip: t4("rte.link"), children: /* @__PURE__ */ jsx(LuLink, { className: "h-4 w-4" }) }) }),
4056
4121
  /* @__PURE__ */ jsx(PopoverContent, { className: "w-80 p-3", children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2", children: [
4057
4122
  /* @__PURE__ */ jsx(
4058
4123
  Input,
@@ -4088,7 +4153,7 @@ var Toolbar = ({
4088
4153
  ToolbarButton,
4089
4154
  {
4090
4155
  onClick: () => editor.chain().focus().unsetAllMarks().clearNodes().run(),
4091
- tooltip: t2("rte.clear_formatting"),
4156
+ tooltip: t4("rte.clear_formatting"),
4092
4157
  children: /* @__PURE__ */ jsx(LuRemoveFormatting, { className: "h-4 w-4" })
4093
4158
  },
4094
4159
  "clear"
@@ -4102,7 +4167,7 @@ var Toolbar = ({
4102
4167
  if (tb.text_color) {
4103
4168
  items.push(
4104
4169
  /* @__PURE__ */ jsxs(Popover, { open: text_color_open, onOpenChange: set_text_color_open, children: [
4105
- /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(ToolbarButton, { tooltip: t2("rte.text_color"), children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center", children: [
4170
+ /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(ToolbarButton, { tooltip: t4("rte.text_color"), children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center", children: [
4106
4171
  /* @__PURE__ */ jsx(LuPalette, { className: "h-4 w-4" }),
4107
4172
  /* @__PURE__ */ jsx(
4108
4173
  "div",
@@ -4145,7 +4210,7 @@ var Toolbar = ({
4145
4210
  if (tb.highlight_color) {
4146
4211
  items.push(
4147
4212
  /* @__PURE__ */ jsxs(Popover, { open: highlight_color_open, onOpenChange: set_highlight_color_open, children: [
4148
- /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(ToolbarButton, { tooltip: t2("rte.highlight_color"), children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center", children: [
4213
+ /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(ToolbarButton, { tooltip: t4("rte.highlight_color"), children: /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center", children: [
4149
4214
  /* @__PURE__ */ jsx(LuHighlighter, { className: "h-4 w-4" }),
4150
4215
  /* @__PURE__ */ jsx(
4151
4216
  "div",
@@ -4188,7 +4253,7 @@ var Toolbar = ({
4188
4253
  {
4189
4254
  onClick: () => editor.chain().focus().setTextAlign("left").run(),
4190
4255
  is_active: editor.isActive({ textAlign: "left" }),
4191
- tooltip: t2("rte.align_left"),
4256
+ tooltip: t4("rte.align_left"),
4192
4257
  children: /* @__PURE__ */ jsx(LuAlignLeft, { className: "h-4 w-4" })
4193
4258
  },
4194
4259
  "align-left"
@@ -4198,7 +4263,7 @@ var Toolbar = ({
4198
4263
  {
4199
4264
  onClick: () => editor.chain().focus().setTextAlign("center").run(),
4200
4265
  is_active: editor.isActive({ textAlign: "center" }),
4201
- tooltip: t2("rte.align_center"),
4266
+ tooltip: t4("rte.align_center"),
4202
4267
  children: /* @__PURE__ */ jsx(LuAlignCenter, { className: "h-4 w-4" })
4203
4268
  },
4204
4269
  "align-center"
@@ -4208,7 +4273,7 @@ var Toolbar = ({
4208
4273
  {
4209
4274
  onClick: () => editor.chain().focus().setTextAlign("right").run(),
4210
4275
  is_active: editor.isActive({ textAlign: "right" }),
4211
- tooltip: t2("rte.align_right"),
4276
+ tooltip: t4("rte.align_right"),
4212
4277
  children: /* @__PURE__ */ jsx(LuAlignRight, { className: "h-4 w-4" })
4213
4278
  },
4214
4279
  "align-right"
@@ -4218,7 +4283,7 @@ var Toolbar = ({
4218
4283
  {
4219
4284
  onClick: () => editor.chain().focus().setTextAlign("justify").run(),
4220
4285
  is_active: editor.isActive({ textAlign: "justify" }),
4221
- tooltip: t2("rte.justify"),
4286
+ tooltip: t4("rte.justify"),
4222
4287
  children: /* @__PURE__ */ jsx(LuAlignJustify, { className: "h-4 w-4" })
4223
4288
  },
4224
4289
  "align-justify"
@@ -4234,7 +4299,7 @@ var Toolbar = ({
4234
4299
  {
4235
4300
  onClick: () => editor.chain().focus().toggleBulletList().run(),
4236
4301
  is_active: editor.isActive("bulletList"),
4237
- tooltip: t2("rte.bullet_list"),
4302
+ tooltip: t4("rte.bullet_list"),
4238
4303
  children: /* @__PURE__ */ jsx(LuList, { className: "h-4 w-4" })
4239
4304
  },
4240
4305
  "bullet"
@@ -4248,7 +4313,7 @@ var Toolbar = ({
4248
4313
  {
4249
4314
  onClick: () => editor.chain().focus().toggleOrderedList().run(),
4250
4315
  is_active: editor.isActive("orderedList"),
4251
- tooltip: t2("rte.ordered_list"),
4316
+ tooltip: t4("rte.ordered_list"),
4252
4317
  children: /* @__PURE__ */ jsx(LuListOrdered, { className: "h-4 w-4" })
4253
4318
  },
4254
4319
  "ordered"
@@ -4262,7 +4327,7 @@ var Toolbar = ({
4262
4327
  {
4263
4328
  onClick: () => editor.chain().focus().toggleTaskList().run(),
4264
4329
  is_active: editor.isActive("taskList"),
4265
- tooltip: t2("rte.checklist"),
4330
+ tooltip: t4("rte.checklist"),
4266
4331
  children: /* @__PURE__ */ jsx(LuListChecks, { className: "h-4 w-4" })
4267
4332
  },
4268
4333
  "task"
@@ -4284,7 +4349,7 @@ var Toolbar = ({
4284
4349
  }
4285
4350
  },
4286
4351
  disabled: !editor.can().liftListItem("listItem") && !editor.can().liftListItem("taskItem"),
4287
- tooltip: t2("rte.decrease_indent"),
4352
+ tooltip: t4("rte.decrease_indent"),
4288
4353
  children: /* @__PURE__ */ jsx(LuIndentDecrease, { className: "h-4 w-4" })
4289
4354
  },
4290
4355
  "indent-dec"
@@ -4300,7 +4365,7 @@ var Toolbar = ({
4300
4365
  }
4301
4366
  },
4302
4367
  disabled: !editor.can().sinkListItem("listItem") && !editor.can().sinkListItem("taskItem"),
4303
- tooltip: t2("rte.increase_indent"),
4368
+ tooltip: t4("rte.increase_indent"),
4304
4369
  children: /* @__PURE__ */ jsx(LuIndentIncrease, { className: "h-4 w-4" })
4305
4370
  },
4306
4371
  "indent-inc"
@@ -4311,7 +4376,7 @@ var Toolbar = ({
4311
4376
  const items = [];
4312
4377
  if (tb.horizontal_rule) {
4313
4378
  items.push(
4314
- /* @__PURE__ */ jsx(ToolbarButton, { onClick: handle_hr_insert, tooltip: t2("rte.horizontal_rule"), children: /* @__PURE__ */ jsx(RxDividerHorizontal, { className: "h-4 w-4" }) }, "hr")
4379
+ /* @__PURE__ */ jsx(ToolbarButton, { onClick: handle_hr_insert, tooltip: t4("rte.horizontal_rule"), children: /* @__PURE__ */ jsx(RxDividerHorizontal, { className: "h-4 w-4" }) }, "hr")
4315
4380
  );
4316
4381
  }
4317
4382
  if (tb.image) {
@@ -4320,7 +4385,7 @@ var Toolbar = ({
4320
4385
  ToolbarButton,
4321
4386
  {
4322
4387
  onClick: () => image_input_ref.current?.click(),
4323
- tooltip: t2("rte.insert_image"),
4388
+ tooltip: t4("rte.insert_image"),
4324
4389
  children: /* @__PURE__ */ jsx(LuImage, { className: "h-4 w-4" })
4325
4390
  },
4326
4391
  "image"
@@ -4334,7 +4399,7 @@ var Toolbar = ({
4334
4399
  ToolbarButton,
4335
4400
  {
4336
4401
  is_active: editor.isActive("table"),
4337
- tooltip: t2("rte.table"),
4402
+ tooltip: t4("rte.table"),
4338
4403
  children: /* @__PURE__ */ jsx(LuTable, { className: "h-4 w-4" })
4339
4404
  }
4340
4405
  ) }),
@@ -4506,7 +4571,7 @@ var Toolbar = ({
4506
4571
  if (tb.variables && variables.length > 0) {
4507
4572
  items.push(
4508
4573
  /* @__PURE__ */ jsxs(Popover, { open: variables_menu_open, onOpenChange: set_variables_menu_open, children: [
4509
- /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(ToolbarButton, { tooltip: t2("rte.insert_variable"), children: /* @__PURE__ */ jsx(LuVariable, { className: "h-4 w-4" }) }) }),
4574
+ /* @__PURE__ */ jsx(PopoverTrigger, { asChild: true, children: /* @__PURE__ */ jsx(ToolbarButton, { tooltip: t4("rte.insert_variable"), children: /* @__PURE__ */ jsx(LuVariable, { className: "h-4 w-4" }) }) }),
4510
4575
  /* @__PURE__ */ jsx(PopoverContent, { className: "w-64 p-0", align: "start", children: /* @__PURE__ */ jsxs(Command, { children: [
4511
4576
  /* @__PURE__ */ jsx(CommandInput, { placeholder: "Search variables...", className: "h-8 text-xs" }),
4512
4577
  /* @__PURE__ */ jsxs(CommandList, { children: [
@@ -4535,7 +4600,7 @@ var Toolbar = ({
4535
4600
  ToolbarButton,
4536
4601
  {
4537
4602
  onClick: () => file_input_ref.current?.click(),
4538
- tooltip: t2("rte.attach_file"),
4603
+ tooltip: t4("rte.attach_file"),
4539
4604
  children: /* @__PURE__ */ jsx(LuPaperclip, { className: "h-4 w-4" })
4540
4605
  },
4541
4606
  "attach"
@@ -5056,6 +5121,7 @@ var HazoUiRte = ({
5056
5121
  );
5057
5122
  };
5058
5123
  HazoUiRte.displayName = "HazoUiRte";
5124
+ var t5 = createPackageT("hazo_ui", en_default);
5059
5125
  function CanvasTextToolbar({
5060
5126
  bold,
5061
5127
  italic,
@@ -5086,14 +5152,14 @@ function CanvasTextToolbar({
5086
5152
  ),
5087
5153
  style,
5088
5154
  children: [
5089
- /* @__PURE__ */ jsx(ToolbarButton, { is_active: bold, onClick: onBold, tooltip: "Bold", children: /* @__PURE__ */ jsx(LuBold, { className: "h-4 w-4" }) }),
5090
- /* @__PURE__ */ jsx(ToolbarButton, { is_active: italic, onClick: onItalic, tooltip: "Italic", children: /* @__PURE__ */ jsx(LuItalic, { className: "h-4 w-4" }) }),
5155
+ /* @__PURE__ */ jsx(ToolbarButton, { is_active: bold, onClick: onBold, tooltip: t5("canvas_toolbar.bold"), children: /* @__PURE__ */ jsx(LuBold, { className: "h-4 w-4" }) }),
5156
+ /* @__PURE__ */ jsx(ToolbarButton, { is_active: italic, onClick: onItalic, tooltip: t5("canvas_toolbar.italic"), children: /* @__PURE__ */ jsx(LuItalic, { className: "h-4 w-4" }) }),
5091
5157
  /* @__PURE__ */ jsx(
5092
5158
  ToolbarButton,
5093
5159
  {
5094
5160
  is_active: underline,
5095
5161
  onClick: onUnderline,
5096
- tooltip: "Underline",
5162
+ tooltip: t5("canvas_toolbar.underline"),
5097
5163
  children: /* @__PURE__ */ jsx(LuUnderline, { className: "h-4 w-4" })
5098
5164
  }
5099
5165
  ),
@@ -5103,7 +5169,7 @@ function CanvasTextToolbar({
5103
5169
  {
5104
5170
  is_active: align === "left",
5105
5171
  onClick: () => onAlign?.("left"),
5106
- tooltip: "Align left",
5172
+ tooltip: t5("canvas_toolbar.align_left"),
5107
5173
  children: /* @__PURE__ */ jsx(LuAlignLeft, { className: "h-4 w-4" })
5108
5174
  }
5109
5175
  ),
@@ -5112,7 +5178,7 @@ function CanvasTextToolbar({
5112
5178
  {
5113
5179
  is_active: align === "center",
5114
5180
  onClick: () => onAlign?.("center"),
5115
- tooltip: "Align center",
5181
+ tooltip: t5("canvas_toolbar.align_center"),
5116
5182
  children: /* @__PURE__ */ jsx(LuAlignCenter, { className: "h-4 w-4" })
5117
5183
  }
5118
5184
  ),
@@ -5121,7 +5187,7 @@ function CanvasTextToolbar({
5121
5187
  {
5122
5188
  is_active: align === "right",
5123
5189
  onClick: () => onAlign?.("right"),
5124
- tooltip: "Align right",
5190
+ tooltip: t5("canvas_toolbar.align_right"),
5125
5191
  children: /* @__PURE__ */ jsx(LuAlignRight, { className: "h-4 w-4" })
5126
5192
  }
5127
5193
  ),
@@ -5130,7 +5196,7 @@ function CanvasTextToolbar({
5130
5196
  "label",
5131
5197
  {
5132
5198
  className: "relative flex h-8 w-8 cursor-pointer items-center justify-center rounded-md hover:bg-accent",
5133
- title: "Text color",
5199
+ title: t5("canvas_toolbar.text_color"),
5134
5200
  children: [
5135
5201
  /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center", children: [
5136
5202
  /* @__PURE__ */ jsx("span", { className: "text-xs font-bold text-muted-foreground", children: "A" }),
@@ -5160,7 +5226,7 @@ function CanvasTextToolbar({
5160
5226
  {
5161
5227
  is_active: verticalAlign === "top",
5162
5228
  onClick: () => onVerticalAlign?.("top"),
5163
- tooltip: "Align top",
5229
+ tooltip: t5("canvas_toolbar.align_top"),
5164
5230
  children: /* @__PURE__ */ jsx(LuAlignVerticalJustifyStart, { className: "h-4 w-4" })
5165
5231
  }
5166
5232
  ),
@@ -5169,7 +5235,7 @@ function CanvasTextToolbar({
5169
5235
  {
5170
5236
  is_active: verticalAlign === "middle",
5171
5237
  onClick: () => onVerticalAlign?.("middle"),
5172
- tooltip: "Align middle",
5238
+ tooltip: t5("canvas_toolbar.align_middle"),
5173
5239
  children: /* @__PURE__ */ jsx(LuAlignVerticalJustifyCenter, { className: "h-4 w-4" })
5174
5240
  }
5175
5241
  ),
@@ -5178,7 +5244,7 @@ function CanvasTextToolbar({
5178
5244
  {
5179
5245
  is_active: verticalAlign === "bottom",
5180
5246
  onClick: () => onVerticalAlign?.("bottom"),
5181
- tooltip: "Align bottom",
5247
+ tooltip: t5("canvas_toolbar.align_bottom"),
5182
5248
  children: /* @__PURE__ */ jsx(LuAlignVerticalJustifyEnd, { className: "h-4 w-4" })
5183
5249
  }
5184
5250
  ),
@@ -5189,7 +5255,7 @@ function CanvasTextToolbar({
5189
5255
  value: font,
5190
5256
  onChange: (e) => onFont?.(e.target.value),
5191
5257
  className: "h-8 text-xs rounded-md border border-border bg-background px-1 text-foreground focus:outline-none",
5192
- title: "Font family",
5258
+ title: t5("canvas_toolbar.font_family"),
5193
5259
  children: [
5194
5260
  /* @__PURE__ */ jsx("option", { value: "sans-serif", children: "Sans" }),
5195
5261
  /* @__PURE__ */ jsx("option", { value: "serif", children: "Serif" }),
@@ -5201,18 +5267,19 @@ function CanvasTextToolbar({
5201
5267
  }
5202
5268
  ),
5203
5269
  /* @__PURE__ */ jsx("div", { className: "mx-1 h-6 w-px bg-border" }),
5204
- /* @__PURE__ */ jsx(ToolbarButton, { is_active: bullet, onClick: onBullet, tooltip: "Bullet list", children: /* @__PURE__ */ jsx(LuList, { className: "h-4 w-4" }) })
5270
+ /* @__PURE__ */ jsx(ToolbarButton, { is_active: bullet, onClick: onBullet, tooltip: t5("canvas_toolbar.bullet_list"), children: /* @__PURE__ */ jsx(LuList, { className: "h-4 w-4" }) })
5205
5271
  ]
5206
5272
  }
5207
5273
  ) });
5208
5274
  }
5275
+ var t6 = createPackageT("hazo_ui", en_default);
5209
5276
  var MdEditorLazy = lazy(() => import('@uiw/react-md-editor'));
5210
5277
  var EDITOR_TEXTAREA_SELECTOR = ".w-md-editor-text-input";
5211
5278
  function MarkdownEditor({
5212
5279
  value,
5213
5280
  onChange,
5214
5281
  height = 600,
5215
- placeholder = "Write in Markdown\u2026",
5282
+ placeholder,
5216
5283
  className,
5217
5284
  colorMode = "light",
5218
5285
  preview = "edit",
@@ -5295,13 +5362,13 @@ function MarkdownEditor({
5295
5362
  try {
5296
5363
  const url = await onImageUpload(file);
5297
5364
  if (!url) {
5298
- setError("Upload failed.");
5365
+ setError(t6("markdown.upload_failed"));
5299
5366
  onChange(before + after);
5300
5367
  return;
5301
5368
  }
5302
5369
  onChange(before + `![](${url})` + after);
5303
5370
  } catch {
5304
- setError("Upload failed.");
5371
+ setError(t6("markdown.upload_failed"));
5305
5372
  onChange(before + after);
5306
5373
  } finally {
5307
5374
  setUploading(false);
@@ -5325,7 +5392,7 @@ function MarkdownEditor({
5325
5392
  {
5326
5393
  className: "flex items-center justify-center rounded-md border border-border bg-muted/30 text-sm text-muted-foreground",
5327
5394
  style: { height },
5328
- children: "Loading editor\u2026"
5395
+ children: t6("markdown.loading_editor")
5329
5396
  }
5330
5397
  ),
5331
5398
  children: /* @__PURE__ */ jsx(
@@ -5337,7 +5404,7 @@ function MarkdownEditor({
5337
5404
  preview: effectivePreview,
5338
5405
  visibleDragbar: false,
5339
5406
  commands: editorCommands,
5340
- textareaProps: { placeholder, onPaste: handlePaste }
5407
+ textareaProps: { placeholder: placeholder ?? t6("markdown.placeholder"), onPaste: handlePaste }
5341
5408
  }
5342
5409
  )
5343
5410
  }
@@ -5346,7 +5413,7 @@ function MarkdownEditor({
5346
5413
  {
5347
5414
  className: "flex items-center justify-center rounded-md border border-border bg-muted/30 text-sm text-muted-foreground",
5348
5415
  style: { height },
5349
- children: "Loading editor\u2026"
5416
+ children: t6("markdown.loading_editor")
5350
5417
  }
5351
5418
  ) }),
5352
5419
  useCustomPreview && showPreview && /* @__PURE__ */ jsx(
@@ -5360,7 +5427,7 @@ function MarkdownEditor({
5360
5427
  ]
5361
5428
  }
5362
5429
  ),
5363
- uploading && /* @__PURE__ */ jsx("p", { className: "mt-2 text-xs text-muted-foreground", children: "Uploading image\u2026" }),
5430
+ uploading && /* @__PURE__ */ jsx("p", { className: "mt-2 text-xs text-muted-foreground", children: t6("markdown.uploading_image") }),
5364
5431
  error && /* @__PURE__ */ jsx("p", { className: "mt-2 text-xs text-destructive", children: error })
5365
5432
  ] });
5366
5433
  }
@@ -7148,6 +7215,7 @@ function resolve_animation_classes(open_anim = "zoom", close_anim = "zoom") {
7148
7215
  const close_classes = close_anim in ANIMATION_PRESETS ? ANIMATION_PRESETS[close_anim].close : close_anim;
7149
7216
  return `${open_classes} ${close_classes}`;
7150
7217
  }
7218
+ var t7 = createPackageT("hazo_ui", en_default);
7151
7219
  var VARIANT_PRESETS = {
7152
7220
  info: {
7153
7221
  header_background_color: "var(--dialog-info-bg)",
@@ -7197,11 +7265,11 @@ function HazoUiDialog({
7197
7265
  children,
7198
7266
  onConfirm,
7199
7267
  onCancel,
7200
- title = "Action required",
7268
+ title,
7201
7269
  description,
7202
7270
  actionButtonText: actionButtonTextProp,
7203
7271
  actionButtonVariant,
7204
- cancelButtonText = "Cancel",
7272
+ cancelButtonText,
7205
7273
  showCancelButton: showCancelButtonProp,
7206
7274
  showActionButton = true,
7207
7275
  closeOnConfirm: closeOnConfirmProp,
@@ -7241,9 +7309,11 @@ function HazoUiDialog({
7241
7309
  const cancel_ref = React27.useRef(null);
7242
7310
  const variant_preset = variant !== "default" ? VARIANT_PRESETS[variant] : is_status_kind || is_confirm_kind ? NEUTRAL_VARIANT_PRESET : void 0;
7243
7311
  const resolved_action_button_variant = actionButtonVariant ?? variant_preset?.action_button_variant ?? "default";
7312
+ const resolved_title = title ?? t7("dialog.default_title");
7313
+ const resolved_cancel_text = cancelButtonText ?? t7("dialog.cancel");
7244
7314
  const showCancelButton = showCancelButtonProp ?? (is_status_kind ? false : true);
7245
7315
  const closeOnConfirm = closeOnConfirmProp ?? (is_status_kind || is_confirm_kind ? true : false);
7246
- const actionButtonText = actionButtonTextProp ?? (is_status_kind ? "OK" : is_confirm_kind ? showCancelButton ? "Confirm" : "OK" : "Confirm");
7316
+ const actionButtonText = actionButtonTextProp ?? (is_status_kind ? t7("dialog.ok") : is_confirm_kind ? showCancelButton ? t7("dialog.confirm") : t7("dialog.ok") : t7("dialog.confirm"));
7247
7317
  const actionButtonLoading = actionButtonLoadingProp ?? (is_confirm_kind ? internal_confirm_loading : false);
7248
7318
  const handleConfirm = () => {
7249
7319
  if (is_confirm_kind) {
@@ -7378,7 +7448,7 @@ function HazoUiDialog({
7378
7448
  },
7379
7449
  children: [
7380
7450
  /* @__PURE__ */ jsxs("div", { className: "cls_confirm_dialog_body px-6 pt-7 pb-5", children: [
7381
- /* @__PURE__ */ jsx(DialogPrimitive.Title, { className: "cls_confirm_dialog_title text-[17px] font-semibold text-foreground mb-2.5", children: title }),
7451
+ /* @__PURE__ */ jsx(DialogPrimitive.Title, { className: "cls_confirm_dialog_title text-[17px] font-semibold text-foreground mb-2.5", children: resolved_title }),
7382
7452
  children ? /* @__PURE__ */ jsx(DialogPrimitive.Description, { asChild: true, children: /* @__PURE__ */ jsx("div", { className: "cls_confirm_dialog_children text-sm text-muted-foreground leading-relaxed", children }) }) : description ? /* @__PURE__ */ jsx(DialogPrimitive.Description, { className: "cls_confirm_dialog_description text-sm text-muted-foreground leading-relaxed", children: description }) : null
7383
7453
  ] }),
7384
7454
  /* @__PURE__ */ jsx("div", { className: "cls_confirm_dialog_separator border-t border-border" }),
@@ -7393,7 +7463,7 @@ function HazoUiDialog({
7393
7463
  onClick: handleCancel,
7394
7464
  disabled: actionButtonLoading,
7395
7465
  style: cancelButtonStyles,
7396
- children: cancelButtonText
7466
+ children: resolved_cancel_text
7397
7467
  }
7398
7468
  ),
7399
7469
  showActionButton && /* @__PURE__ */ jsxs(
@@ -7459,7 +7529,7 @@ function HazoUiDialog({
7459
7529
  ...finalHeaderBackgroundColor && { backgroundColor: finalHeaderBackgroundColor },
7460
7530
  ...finalHeaderTextColor && { color: finalHeaderTextColor }
7461
7531
  },
7462
- children: /* @__PURE__ */ jsx(DialogTitle, { className: titleClassName, children: title })
7532
+ children: /* @__PURE__ */ jsx(DialogTitle, { className: titleClassName, children: resolved_title })
7463
7533
  }
7464
7534
  ),
7465
7535
  /* @__PURE__ */ jsx(
@@ -7490,7 +7560,7 @@ function HazoUiDialog({
7490
7560
  ),
7491
7561
  style: headerStyles,
7492
7562
  children: [
7493
- /* @__PURE__ */ jsx(DialogTitle, { className: titleClassName, children: title }),
7563
+ /* @__PURE__ */ jsx(DialogTitle, { className: titleClassName, children: resolved_title }),
7494
7564
  description && /* @__PURE__ */ jsx(
7495
7565
  DialogDescription,
7496
7566
  {
@@ -7541,7 +7611,7 @@ function HazoUiDialog({
7541
7611
  variant: "outline",
7542
7612
  onClick: handleCancel,
7543
7613
  style: cancelButtonStyles,
7544
- children: cancelButtonText
7614
+ children: resolved_cancel_text
7545
7615
  }
7546
7616
  ),
7547
7617
  showActionButton && /* @__PURE__ */ jsxs(
@@ -7570,7 +7640,7 @@ function HazoUiDialog({
7570
7640
  style: headerBar ? { color: "var(--dialog-header-bar-fg)" } : finalHeaderTextColor ? { color: finalHeaderTextColor } : void 0,
7571
7641
  children: [
7572
7642
  /* @__PURE__ */ jsx(X, { className: "h-4 w-4" }),
7573
- /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Close" })
7643
+ /* @__PURE__ */ jsx("span", { className: "sr-only", children: t7("dialog.close") })
7574
7644
  ]
7575
7645
  }
7576
7646
  )
@@ -7579,6 +7649,7 @@ function HazoUiDialog({
7579
7649
  )
7580
7650
  ] }) });
7581
7651
  }
7652
+ var t8 = createPackageT("hazo_ui", en_default);
7582
7653
  function HazoUiConfirmDialog({
7583
7654
  open,
7584
7655
  onOpenChange,
@@ -7587,7 +7658,7 @@ function HazoUiConfirmDialog({
7587
7658
  children,
7588
7659
  variant = "default",
7589
7660
  confirmLabel,
7590
- cancelLabel = "Cancel",
7661
+ cancelLabel = t8("confirm.cancel"),
7591
7662
  showCancelButton = true,
7592
7663
  onConfirm,
7593
7664
  onCancel,
@@ -7636,6 +7707,7 @@ var Slider = React27.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
7636
7707
  }
7637
7708
  ));
7638
7709
  Slider.displayName = SliderPrimitive.Root.displayName;
7710
+ var t9 = createPackageT("hazo_ui", en_default);
7639
7711
  async function getCroppedImg(imageSrc, areaPixels, outputSize, quality) {
7640
7712
  const img = await new Promise((resolve, reject) => {
7641
7713
  const image = new Image();
@@ -7681,7 +7753,7 @@ var HazoUiImageCropper = React27.forwardRef(function HazoUiImageCropper2({
7681
7753
  onCropped,
7682
7754
  outputSize = 512,
7683
7755
  quality = 0.9,
7684
- zoomLabel = "Zoom",
7756
+ zoomLabel,
7685
7757
  className
7686
7758
  }, ref) {
7687
7759
  const [crop, set_crop] = React27.useState({
@@ -7689,6 +7761,7 @@ var HazoUiImageCropper = React27.forwardRef(function HazoUiImageCropper2({
7689
7761
  y: 0
7690
7762
  });
7691
7763
  const [zoom, set_zoom] = React27.useState(1);
7764
+ const resolved_zoom_label = zoomLabel ?? t9("cropper.zoom");
7692
7765
  const cropped_area_pixels_ref = React27.useRef(null);
7693
7766
  const handle_crop_complete = React27.useCallback(
7694
7767
  (_croppedArea, croppedAreaPixels) => {
@@ -7745,7 +7818,7 @@ var HazoUiImageCropper = React27.forwardRef(function HazoUiImageCropper2({
7745
7818
  {
7746
7819
  className: "cls_zoom_label text-sm font-medium text-foreground",
7747
7820
  id: "hazo-cropper-zoom-label",
7748
- children: zoomLabel
7821
+ children: resolved_zoom_label
7749
7822
  }
7750
7823
  ),
7751
7824
  /* @__PURE__ */ jsx(
@@ -7763,19 +7836,24 @@ var HazoUiImageCropper = React27.forwardRef(function HazoUiImageCropper2({
7763
7836
  ] });
7764
7837
  });
7765
7838
  HazoUiImageCropper.displayName = "HazoUiImageCropper";
7839
+ var t10 = createPackageT("hazo_ui", en_default);
7766
7840
  function HazoUiImageCropperDialog({
7767
7841
  open,
7768
7842
  onOpenChange,
7769
7843
  file,
7770
7844
  onConfirm,
7771
7845
  onCancel,
7772
- title = "Crop photo",
7773
- confirmLabel = "Save",
7774
- cancelLabel = "Cancel",
7775
- zoomLabel = "Zoom",
7846
+ title,
7847
+ confirmLabel,
7848
+ cancelLabel,
7849
+ zoomLabel,
7776
7850
  outputSize = 512,
7777
7851
  quality = 0.9
7778
7852
  }) {
7853
+ const resolved_title = title ?? t10("cropper.title");
7854
+ const resolved_confirm_label = confirmLabel ?? t10("cropper.save");
7855
+ const resolved_cancel_label = cancelLabel ?? t10("cropper.cancel");
7856
+ const resolved_zoom_label = zoomLabel ?? t10("cropper.zoom");
7779
7857
  const cropper_ref = React27.useRef(null);
7780
7858
  const [image_src, set_image_src] = React27.useState(null);
7781
7859
  const [is_confirming, set_is_confirming] = React27.useState(false);
@@ -7806,9 +7884,9 @@ function HazoUiImageCropperDialog({
7806
7884
  {
7807
7885
  open,
7808
7886
  onOpenChange,
7809
- title,
7810
- actionButtonText: confirmLabel,
7811
- cancelButtonText: cancelLabel,
7887
+ title: resolved_title,
7888
+ actionButtonText: resolved_confirm_label,
7889
+ cancelButtonText: resolved_cancel_label,
7812
7890
  onConfirm: handle_confirm,
7813
7891
  onCancel,
7814
7892
  actionButtonLoading: is_confirming,
@@ -7821,7 +7899,7 @@ function HazoUiImageCropperDialog({
7821
7899
  imageSrc: image_src,
7822
7900
  outputSize,
7823
7901
  quality,
7824
- zoomLabel
7902
+ zoomLabel: resolved_zoom_label
7825
7903
  }
7826
7904
  )
7827
7905
  }
@@ -8492,6 +8570,7 @@ function EmptyState({
8492
8570
  }
8493
8571
  );
8494
8572
  }
8573
+ var t11 = createPackageT("hazo_ui", en_default);
8495
8574
  function ErrorBanner({
8496
8575
  severity = "error",
8497
8576
  title,
@@ -8526,7 +8605,7 @@ function ErrorBanner({
8526
8605
  {
8527
8606
  type: "button",
8528
8607
  onClick: onDismiss,
8529
- "aria-label": "Dismiss",
8608
+ "aria-label": t11("error.dismiss"),
8530
8609
  className: "flex-shrink-0 rounded p-1 hover:bg-black/5 focus:outline-none focus:ring-2 focus:ring-offset-2 dark:hover:bg-white/5",
8531
8610
  children: /* @__PURE__ */ jsx(X, { className: "h-4 w-4", "aria-hidden": "true" })
8532
8611
  }
@@ -8535,8 +8614,9 @@ function ErrorBanner({
8535
8614
  }
8536
8615
  );
8537
8616
  }
8617
+ var t12 = createPackageT("hazo_ui", en_default);
8538
8618
  function ErrorPage({
8539
- title = "Something went wrong",
8619
+ title = t12("error.something_went_wrong"),
8540
8620
  description,
8541
8621
  errorCode,
8542
8622
  correlationId,
@@ -8567,6 +8647,7 @@ function ErrorPage({
8567
8647
  }
8568
8648
  );
8569
8649
  }
8650
+ var t13 = createPackageT("hazo_ui", en_default);
8570
8651
  function LoadingTimeout({
8571
8652
  active,
8572
8653
  children,
@@ -8576,7 +8657,7 @@ function LoadingTimeout({
8576
8657
  label = "content",
8577
8658
  className
8578
8659
  }) {
8579
- const t4 = {
8660
+ const timeouts = {
8580
8661
  gentle: thresholds?.gentle ?? 5e3,
8581
8662
  firm: thresholds?.firm ?? 15e3,
8582
8663
  expired: thresholds?.expired ?? 3e4
@@ -8588,15 +8669,15 @@ function LoadingTimeout({
8588
8669
  return;
8589
8670
  }
8590
8671
  setPhase("silent");
8591
- const gentleTimer = window.setTimeout(() => setPhase("gentle"), t4.gentle);
8592
- const firmTimer = window.setTimeout(() => setPhase("firm"), t4.firm);
8593
- const expiredTimer = window.setTimeout(() => setPhase("expired"), t4.expired);
8672
+ const gentleTimer = window.setTimeout(() => setPhase("gentle"), timeouts.gentle);
8673
+ const firmTimer = window.setTimeout(() => setPhase("firm"), timeouts.firm);
8674
+ const expiredTimer = window.setTimeout(() => setPhase("expired"), timeouts.expired);
8594
8675
  return () => {
8595
8676
  window.clearTimeout(gentleTimer);
8596
8677
  window.clearTimeout(firmTimer);
8597
8678
  window.clearTimeout(expiredTimer);
8598
8679
  };
8599
- }, [active, t4.gentle, t4.firm, t4.expired]);
8680
+ }, [active, timeouts.gentle, timeouts.firm, timeouts.expired]);
8600
8681
  if (!active) {
8601
8682
  return /* @__PURE__ */ jsx(Fragment$1, { children });
8602
8683
  }
@@ -8605,7 +8686,7 @@ function LoadingTimeout({
8605
8686
  ErrorBanner,
8606
8687
  {
8607
8688
  severity: "error",
8608
- title: "This is taking longer than expected",
8689
+ title: t13("loading.taking_longer"),
8609
8690
  message: `We're still trying to load the ${label}. The connection may be slow.`,
8610
8691
  action: onRetry ? /* @__PURE__ */ jsx(
8611
8692
  "button",
@@ -8707,6 +8788,7 @@ function NotificationCountBadge({
8707
8788
  }
8708
8789
  );
8709
8790
  }
8791
+ var t14 = createPackageT("hazo_ui", en_default);
8710
8792
  function NotificationItem({
8711
8793
  isRead,
8712
8794
  timestamp,
@@ -8737,7 +8819,7 @@ function NotificationItem({
8737
8819
  /* @__PURE__ */ jsx("div", { className: "cls_notification_item_dot_col flex-shrink-0 pt-1.5", children: !isRead ? /* @__PURE__ */ jsx(
8738
8820
  "span",
8739
8821
  {
8740
- "aria-label": "Unread",
8822
+ "aria-label": t14("notification.unread"),
8741
8823
  className: "cls_notification_item_dot block w-2 h-2 rounded-full bg-primary"
8742
8824
  }
8743
8825
  ) : /* @__PURE__ */ jsx("span", { className: "block w-2 h-2", "aria-hidden": "true" }) }),
@@ -8761,12 +8843,13 @@ function NotificationItem({
8761
8843
  }
8762
8844
  );
8763
8845
  }
8846
+ var t15 = createPackageT("hazo_ui", en_default);
8764
8847
  function LoadingSkeletons() {
8765
8848
  return /* @__PURE__ */ jsx(
8766
8849
  "div",
8767
8850
  {
8768
8851
  "aria-busy": "true",
8769
- "aria-label": "Loading notifications",
8852
+ "aria-label": t15("notification.loading"),
8770
8853
  className: "cls_notification_panel_loading space-y-0",
8771
8854
  children: [0, 1, 2].map((i) => /* @__PURE__ */ jsxs(
8772
8855
  "div",
@@ -8825,6 +8908,7 @@ function NotificationPanel({
8825
8908
  }
8826
8909
  );
8827
8910
  }
8911
+ var t16 = createPackageT("hazo_ui", en_default);
8828
8912
  function HazoUiToaster({
8829
8913
  position = "bottom-right",
8830
8914
  closeButton = true,
@@ -8870,12 +8954,12 @@ function permissionToast({
8870
8954
  action,
8871
8955
  duration = 5e3
8872
8956
  }) {
8873
- const description = missingPermissions.length === 0 ? "You do not have permission to perform this action." : `Missing: ${missingPermissions.map((key) => {
8957
+ const description = missingPermissions.length === 0 ? t16("toast.permission_denied_message") : `Missing: ${missingPermissions.map((key) => {
8874
8958
  const label = descriptions?.[key];
8875
8959
  return label ? `\`${key}\` \u2014 ${label}` : `\`${key}\``;
8876
8960
  }).join("; ")}`;
8877
8961
  return errorToast({
8878
- title: "Permission required",
8962
+ title: t16("toast.permission_required"),
8879
8963
  description,
8880
8964
  action,
8881
8965
  duration
@@ -9070,41 +9154,55 @@ function useWakeLock() {
9070
9154
  }
9071
9155
  function useFullscreen(elementRef) {
9072
9156
  const [is_fullscreen, set_is_fullscreen] = useState(false);
9157
+ const supported = typeof document !== "undefined" && typeof document.documentElement.requestFullscreen === "function";
9073
9158
  useEffect(() => {
9074
- if (typeof document === "undefined") return;
9159
+ if (typeof document === "undefined" || !supported) return;
9075
9160
  const handle_change = () => {
9076
9161
  set_is_fullscreen(!!document.fullscreenElement);
9077
9162
  };
9078
9163
  document.addEventListener("fullscreenchange", handle_change);
9079
9164
  set_is_fullscreen(!!document.fullscreenElement);
9080
9165
  return () => document.removeEventListener("fullscreenchange", handle_change);
9081
- }, []);
9166
+ }, [supported]);
9082
9167
  const get_target = useCallback(() => {
9083
9168
  return elementRef?.current ?? document.documentElement;
9084
9169
  }, [elementRef]);
9085
9170
  const enter = useCallback(async () => {
9086
- if (typeof document === "undefined" || !document.documentElement.requestFullscreen) return;
9171
+ if (typeof document === "undefined") return;
9172
+ if (!supported) {
9173
+ set_is_fullscreen(true);
9174
+ return;
9175
+ }
9087
9176
  if (document.fullscreenElement) return;
9088
9177
  try {
9089
9178
  await get_target().requestFullscreen();
9090
9179
  } catch {
9091
9180
  }
9092
- }, [get_target]);
9181
+ }, [supported, get_target]);
9093
9182
  const exit = useCallback(async () => {
9094
9183
  if (typeof document === "undefined") return;
9184
+ if (!supported) {
9185
+ set_is_fullscreen(false);
9186
+ return;
9187
+ }
9095
9188
  if (!document.fullscreenElement) return;
9096
9189
  try {
9097
9190
  await document.exitFullscreen();
9098
9191
  } catch {
9099
9192
  }
9100
- }, []);
9193
+ }, [supported]);
9101
9194
  const toggle = useCallback(async () => {
9195
+ if (!supported) {
9196
+ if (is_fullscreen) await exit();
9197
+ else await enter();
9198
+ return;
9199
+ }
9102
9200
  if (document.fullscreenElement) {
9103
9201
  await exit();
9104
9202
  } else {
9105
9203
  await enter();
9106
9204
  }
9107
- }, [enter, exit]);
9205
+ }, [supported, is_fullscreen, enter, exit]);
9108
9206
  return { isFullscreen: is_fullscreen, enter, exit, toggle };
9109
9207
  }
9110
9208
  function use_wake_lock(active) {
@@ -9505,6 +9603,7 @@ function KanbanLaneStrip({
9505
9603
  }
9506
9604
  );
9507
9605
  }
9606
+ var t17 = createPackageT("hazo_ui", en_default);
9508
9607
  var DEFAULT_PRIORITIES = ["P0", "P1", "P2", "P3"];
9509
9608
  function humanize(key) {
9510
9609
  return key.replace(/[_\-]+/g, " ").replace(/([a-z])([A-Z])/g, "$1 $2").replace(/\s+/g, " ").trim().split(" ").map((w) => w ? w[0].toUpperCase() + w.slice(1) : w).join(" ");
@@ -9519,7 +9618,7 @@ function auto_detect_fields(item, columns) {
9519
9618
  }
9520
9619
  }
9521
9620
  if (columns.length > 0) {
9522
- out.push({ key: "columnKey", type: "status", label: "Status" });
9621
+ out.push({ key: "columnKey", type: "status", label: t17("kanban.status_label") });
9523
9622
  }
9524
9623
  return out;
9525
9624
  }
@@ -9616,7 +9715,7 @@ function KanbanEditor({
9616
9715
  isDirty: is_dirty
9617
9716
  };
9618
9717
  const open = item !== null;
9619
- const title = item && titleFn ? titleFn(item) : item ? `Edit ${item.id}` : "";
9718
+ const title = item && titleFn ? titleFn(item) : item ? t17("kanban.edit_fallback", { id: item.id }) : "";
9620
9719
  const priority_var = item?.priority ? `--hazo-kanban-priority-${String(item.priority).toLowerCase()}` : null;
9621
9720
  const header_bar_color = priority_var ? `hsl(var(${priority_var}))` : void 0;
9622
9721
  const use_default_footer = !(renderBody && hideFooter);
@@ -9628,18 +9727,18 @@ function KanbanEditor({
9628
9727
  if (!o && !saving) onClose();
9629
9728
  },
9630
9729
  title,
9631
- description: "Update card details below.",
9730
+ description: t17("kanban.update_description"),
9632
9731
  sizeWidth: "min(90vw, 480px)",
9633
9732
  openAnimation: "none",
9634
9733
  closeAnimation: "none",
9635
9734
  headerBar: !!priority_var,
9636
9735
  headerBarColor: header_bar_color,
9637
9736
  contentClassName: cn("cls_hazo_kanban_editor", priority_var && "pt-0"),
9638
- actionButtonText: saving ? "Saving\u2026" : "Save",
9737
+ actionButtonText: saving ? t17("kanban.saving") : t17("kanban.save"),
9639
9738
  actionButtonIcon: saving ? void 0 : /* @__PURE__ */ jsx(Check, { className: "h-4 w-4 mr-2" }),
9640
9739
  actionButtonLoading: saving,
9641
9740
  actionButtonDisabled: !is_dirty || !all_required_filled || saving,
9642
- cancelButtonText: "Cancel",
9741
+ cancelButtonText: t17("kanban.cancel"),
9643
9742
  showCancelButton: true,
9644
9743
  onConfirm: handle_save,
9645
9744
  onCancel: onClose,
@@ -9744,7 +9843,7 @@ function KanbanEditorFieldRow({
9744
9843
  /* @__PURE__ */ jsx(SelectTrigger, { id, children: /* @__PURE__ */ jsx(
9745
9844
  SelectValue,
9746
9845
  {
9747
- placeholder: field.placeholder ?? `Select ${label}\u2026`
9846
+ placeholder: field.placeholder ?? t17("kanban.select_placeholder", { label })
9748
9847
  }
9749
9848
  ) }),
9750
9849
  /* @__PURE__ */ jsx(SelectContent, { children: (field.options ?? []).map((opt) => /* @__PURE__ */ jsx(SelectItem, { value: opt, children: opt }, opt)) })
@@ -9760,7 +9859,7 @@ function KanbanEditorFieldRow({
9760
9859
  /* @__PURE__ */ jsx(SelectTrigger, { id, children: /* @__PURE__ */ jsx(
9761
9860
  SelectValue,
9762
9861
  {
9763
- placeholder: field.placeholder ?? "Select priority\u2026"
9862
+ placeholder: field.placeholder ?? t17("kanban.select_priority")
9764
9863
  }
9765
9864
  ) }),
9766
9865
  /* @__PURE__ */ jsx(SelectContent, { children: priorities.map((p) => /* @__PURE__ */ jsx(SelectItem, { value: p, children: p }, p)) })
@@ -9776,7 +9875,7 @@ function KanbanEditorFieldRow({
9776
9875
  /* @__PURE__ */ jsx(SelectTrigger, { id, children: /* @__PURE__ */ jsx(
9777
9876
  SelectValue,
9778
9877
  {
9779
- placeholder: field.placeholder ?? "Select status\u2026"
9878
+ placeholder: field.placeholder ?? t17("kanban.select_status")
9780
9879
  }
9781
9880
  ) }),
9782
9881
  /* @__PURE__ */ jsx(SelectContent, { children: columns.map((col) => /* @__PURE__ */ jsx(SelectItem, { value: col.key, children: col.title }, col.key)) })
@@ -10724,7 +10823,7 @@ function serializeFilter(filter) {
10724
10823
  const fields = (filter.fields ?? []).map((f) => `${f.field}:${f.operator ?? ""}:${String(f.value)}`).join(",");
10725
10824
  return `${filter.search ?? ""}|${fields}`;
10726
10825
  }
10727
- var t3 = createPackageT("hazo_ui", en_default);
10826
+ var t18 = createPackageT("hazo_ui", en_default);
10728
10827
  function HazoUiTable(props) {
10729
10828
  const state = useTableState(props);
10730
10829
  const { columns, rows, getRowKey, className, caption } = props;
@@ -10759,12 +10858,12 @@ function HazoUiTable(props) {
10759
10858
  ) }) : state.serverError != null ? /* @__PURE__ */ jsx("div", { className: "cls_hazo_ui_table_mobile_error py-6", children: renderErrorState(props.error, state.serverError) }) : state.displayed.length === 0 ? /* @__PURE__ */ jsx("div", { className: "cls_hazo_ui_table_mobile_empty py-6", children: noActiveFilters(state.filter) && rows.length === 0 ? typeof props.empty === "string" || props.empty === void 0 ? /* @__PURE__ */ jsx(
10760
10859
  EmptyState,
10761
10860
  {
10762
- title: typeof props.empty === "string" && props.empty || t3("table.empty")
10861
+ title: typeof props.empty === "string" && props.empty || t18("table.empty")
10763
10862
  }
10764
10863
  ) : props.empty : typeof props.noResults === "string" || props.noResults === void 0 ? /* @__PURE__ */ jsx(
10765
10864
  EmptyState,
10766
10865
  {
10767
- title: typeof props.noResults === "string" && props.noResults || t3("table.no_results")
10866
+ title: typeof props.noResults === "string" && props.noResults || t18("table.no_results")
10768
10867
  }
10769
10868
  ) : props.noResults }) : /* @__PURE__ */ jsx(
10770
10869
  TableMobileCards,
@@ -10787,7 +10886,7 @@ function HazoUiTable(props) {
10787
10886
  {
10788
10887
  type: "button",
10789
10888
  onClick: (e) => state.cycleHeaderSort(c.key, e.shiftKey),
10790
- title: t3("table.sort_tooltip"),
10889
+ title: t18("table.sort_tooltip"),
10791
10890
  className: "cls_hazo_ui_table_sort_btn inline-flex items-center gap-1 hover:text-foreground",
10792
10891
  children: [
10793
10892
  /* @__PURE__ */ jsx("span", { children: c.label }),
@@ -10819,12 +10918,12 @@ function HazoUiTable(props) {
10819
10918
  children: noActiveFilters(state.filter) && rows.length === 0 ? /* @__PURE__ */ jsx("div", { className: "cls_hazo_ui_table_empty_wrap py-6", children: typeof props.empty === "string" || props.empty === void 0 ? /* @__PURE__ */ jsx(
10820
10919
  EmptyState,
10821
10920
  {
10822
- title: typeof props.empty === "string" && props.empty || t3("table.empty")
10921
+ title: typeof props.empty === "string" && props.empty || t18("table.empty")
10823
10922
  }
10824
10923
  ) : props.empty }) : /* @__PURE__ */ jsx("div", { className: "cls_hazo_ui_table_no_results_wrap py-6", children: typeof props.noResults === "string" || props.noResults === void 0 ? /* @__PURE__ */ jsx(
10825
10924
  EmptyState,
10826
10925
  {
10827
- title: typeof props.noResults === "string" && props.noResults || t3("table.no_results")
10926
+ title: typeof props.noResults === "string" && props.noResults || t18("table.no_results")
10828
10927
  }
10829
10928
  ) : props.noResults })
10830
10929
  }
@@ -10938,7 +11037,7 @@ function PaginationFooter({
10938
11037
  const end = Math.min((page + 1) * pageSize, total);
10939
11038
  const lastPage = Math.max(0, Math.ceil(total / pageSize) - 1);
10940
11039
  return /* @__PURE__ */ jsxs("div", { className: "cls_hazo_ui_table_pagination flex items-center justify-between gap-3 pt-2 text-sm", children: [
10941
- /* @__PURE__ */ jsx("span", { className: "cls_hazo_ui_table_page_counter text-muted-foreground", children: t3("table.showing", {
11040
+ /* @__PURE__ */ jsx("span", { className: "cls_hazo_ui_table_page_counter text-muted-foreground", children: t18("table.showing", {
10942
11041
  start: String(start),
10943
11042
  end: String(end),
10944
11043
  total: String(total)
@@ -10951,8 +11050,8 @@ function PaginationFooter({
10951
11050
  size: "sm",
10952
11051
  onClick: () => onPageChange(Math.max(0, page - 1)),
10953
11052
  disabled: page === 0,
10954
- "aria-label": t3("table.prev_aria"),
10955
- children: t3("table.prev")
11053
+ "aria-label": t18("table.prev_aria"),
11054
+ children: t18("table.prev")
10956
11055
  }
10957
11056
  ),
10958
11057
  /* @__PURE__ */ jsx(
@@ -10962,8 +11061,8 @@ function PaginationFooter({
10962
11061
  size: "sm",
10963
11062
  onClick: () => onPageChange(Math.min(lastPage, page + 1)),
10964
11063
  disabled: page >= lastPage,
10965
- "aria-label": t3("table.next_aria"),
10966
- children: t3("table.next")
11064
+ "aria-label": t18("table.next_aria"),
11065
+ children: t18("table.next")
10967
11066
  }
10968
11067
  )
10969
11068
  ] })
@@ -11007,7 +11106,7 @@ function Toolbar2(props) {
11007
11106
  setSearchValue(v);
11008
11107
  onSearchChange(v);
11009
11108
  },
11010
- placeholder: searchPlaceholder ?? t3("table.search_placeholder"),
11109
+ placeholder: searchPlaceholder ?? t18("table.search_placeholder"),
11011
11110
  className: "cls_hazo_ui_table_search w-full sm:max-w-xs"
11012
11111
  }
11013
11112
  ) : /* @__PURE__ */ jsx("div", {}),
@@ -11055,8 +11154,8 @@ function renderErrorState(error, serverError) {
11055
11154
  return /* @__PURE__ */ jsx(
11056
11155
  EmptyState,
11057
11156
  {
11058
- title: t3("table.error_title"),
11059
- description: msg || t3("table.error_description")
11157
+ title: t18("table.error_title"),
11158
+ description: msg || t18("table.error_description")
11060
11159
  }
11061
11160
  );
11062
11161
  }
@@ -11292,18 +11391,20 @@ function StackedBars({
11292
11391
  }
11293
11392
  );
11294
11393
  }
11394
+ var t19 = createPackageT("hazo_ui", en_default);
11295
11395
  function DateRangeSelector({
11296
11396
  value,
11297
11397
  onChange,
11298
11398
  options,
11299
11399
  className,
11300
- ariaLabel = "Date range"
11400
+ ariaLabel
11301
11401
  }) {
11402
+ const resolved_aria = ariaLabel ?? t19("charts.date_range");
11302
11403
  return /* @__PURE__ */ jsx(
11303
11404
  "div",
11304
11405
  {
11305
11406
  role: "group",
11306
- "aria-label": ariaLabel,
11407
+ "aria-label": resolved_aria,
11307
11408
  className: cn(
11308
11409
  "cls_hazo_date_range_selector inline-flex items-center gap-0 rounded-md border bg-background p-0.5",
11309
11410
  className
@@ -11546,6 +11647,7 @@ function FunnelChart({
11546
11647
 
11547
11648
  // src/assets/celebration-chime.mp3
11548
11649
  var celebration_chime_default = "data:text/plain;charset=utf-8,";
11650
+ var t20 = createPackageT("hazo_ui", en_default);
11549
11651
  var CELEBRATION_GRADIENT = "linear-gradient(135deg, #667eea 0%, #764ba2 100%)";
11550
11652
  var CARD_SIZE = 1080;
11551
11653
  var PREVIEW_SIZE = 400;
@@ -11743,7 +11845,7 @@ function CelebrationModalInner({
11743
11845
  {
11744
11846
  className: "cls_celebration_close_btn absolute top-3 right-3 z-10 p-1.5 rounded-full hover:bg-black/10 transition-colors",
11745
11847
  onClick: close_modal,
11746
- "aria-label": "Close celebration",
11848
+ "aria-label": t20("celebration.close"),
11747
11849
  children: /* @__PURE__ */ jsx(X, { className: "h-4 w-4 text-gray-600" })
11748
11850
  }
11749
11851
  ),
@@ -11806,21 +11908,21 @@ function CelebrationModalInner({
11806
11908
  disabled: is_downloading,
11807
11909
  children: [
11808
11910
  is_downloading ? /* @__PURE__ */ jsx(Loader2, { className: "h-3.5 w-3.5 mr-1.5 animate-spin" }) : /* @__PURE__ */ jsx(Download, { className: "h-3.5 w-3.5 mr-1.5" }),
11809
- "Download PNG"
11911
+ t20("celebration.download_png")
11810
11912
  ]
11811
11913
  }
11812
11914
  ),
11813
11915
  can_share && /* @__PURE__ */ jsxs(Button, { variant: "outline", size: "sm", onClick: handle_share, children: [
11814
11916
  /* @__PURE__ */ jsx(Share2, { className: "h-3.5 w-3.5 mr-1.5" }),
11815
- "Share"
11917
+ t20("celebration.share")
11816
11918
  ] }),
11817
11919
  /* @__PURE__ */ jsxs(Button, { variant: "outline", size: "sm", onClick: handle_copy, children: [
11818
11920
  /* @__PURE__ */ jsx(Copy, { className: "h-3.5 w-3.5 mr-1.5" }),
11819
- "Copy image"
11921
+ t20("celebration.copy_image")
11820
11922
  ] })
11821
11923
  ] })
11822
11924
  ] }),
11823
- !shareableCard && /* @__PURE__ */ jsx("div", { className: "cls_celebration_footer pb-8", children: /* @__PURE__ */ jsx(Button, { size: "sm", onClick: close_modal, children: "Dismiss" }) })
11925
+ !shareableCard && /* @__PURE__ */ jsx("div", { className: "cls_celebration_footer pb-8", children: /* @__PURE__ */ jsx(Button, { size: "sm", onClick: close_modal, children: t20("celebration.dismiss") }) })
11824
11926
  ]
11825
11927
  }
11826
11928
  )
@@ -11842,8 +11944,8 @@ function computeEta(durationWindow, unitCount, concurrency = 1, fallbackUnitMs =
11842
11944
  }
11843
11945
  function easeToward(elapsed, eta, maxCap = 0.95) {
11844
11946
  if (eta <= 0 || elapsed <= 0) return 0;
11845
- const t4 = elapsed / eta;
11846
- return maxCap * (1 - Math.exp(-1.5 * t4));
11947
+ const t22 = elapsed / eta;
11948
+ return maxCap * (1 - Math.exp(-1.5 * t22));
11847
11949
  }
11848
11950
  function HazoUiProgressBar({
11849
11951
  value,
@@ -11874,7 +11976,7 @@ function HazoUiProgressBar({
11874
11976
  children: /* @__PURE__ */ jsx(
11875
11977
  "div",
11876
11978
  {
11877
- className: "h-full rounded-full bg-accent transition-[width] duration-200 ease-out motion-reduce:transition-none",
11979
+ className: "h-full rounded-full bg-primary transition-[width] duration-200 ease-out motion-reduce:transition-none",
11878
11980
  style: { width: `${pct}%` }
11879
11981
  }
11880
11982
  )
@@ -11961,6 +12063,8 @@ function HazoUiEtaProgress({
11961
12063
  fallbackUnitMs = 5e3,
11962
12064
  level = "global",
11963
12065
  label,
12066
+ showPercent,
12067
+ size,
11964
12068
  endpoint,
11965
12069
  handleRef,
11966
12070
  className
@@ -11995,6 +12099,8 @@ function HazoUiEtaProgress({
11995
12099
  {
11996
12100
  value: handle.value,
11997
12101
  label,
12102
+ showPercent,
12103
+ size,
11998
12104
  className
11999
12105
  }
12000
12106
  );
@@ -12015,13 +12121,16 @@ function upsertEntry(entries, entry) {
12015
12121
  function removeEntry(entries, id) {
12016
12122
  return entries.filter((e) => e.id !== id);
12017
12123
  }
12124
+ var t21 = createPackageT("hazo_ui", en_default);
12018
12125
  function HazoUiMemoryDropdown({
12019
12126
  history_key,
12020
- placeholder = "Search history\u2026",
12127
+ placeholder,
12021
12128
  on_select,
12022
12129
  add_entry,
12023
- empty_label = "No history yet"
12130
+ empty_label
12024
12131
  }) {
12132
+ const resolved_placeholder = placeholder ?? t21("memory.search_placeholder");
12133
+ const resolved_empty_label = empty_label ?? t21("memory.no_history");
12025
12134
  const { value: stored, setValue } = useHazoState(history_key, {
12026
12135
  level: "scope",
12027
12136
  fallback: []
@@ -12059,7 +12168,7 @@ function HazoUiMemoryDropdown({
12059
12168
  type: "text",
12060
12169
  value: query,
12061
12170
  onChange: (e) => setQuery(e.target.value),
12062
- placeholder,
12171
+ placeholder: resolved_placeholder,
12063
12172
  style: {
12064
12173
  width: "100%",
12065
12174
  background: "#FFFFFF",
@@ -12089,7 +12198,7 @@ function HazoUiMemoryDropdown({
12089
12198
  fontStyle: "italic",
12090
12199
  fontSize: 13
12091
12200
  },
12092
- children: empty_label
12201
+ children: resolved_empty_label
12093
12202
  }
12094
12203
  ) : filtered.map((entry) => /* @__PURE__ */ jsx(
12095
12204
  EntryRow,
@@ -12146,7 +12255,7 @@ function EntryRow({ entry, on_select, onDelete }) {
12146
12255
  onClick: (e) => onDelete(entry.id, e),
12147
12256
  onMouseEnter: () => setDeleteHovered(true),
12148
12257
  onMouseLeave: () => setDeleteHovered(false),
12149
- "aria-label": `Remove ${entry.label} from history`,
12258
+ "aria-label": t21("memory.remove_aria", { label: entry.label }),
12150
12259
  style: {
12151
12260
  flexShrink: 0,
12152
12261
  background: "none",