@layers-app/shared 0.4.6 → 0.4.7

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 (229) hide show
  1. package/dist/components/AnimatedFigurePage/AnimatedFigurePage.module.css.js +13 -13
  2. package/dist/components/AppContainer/AppContainer.d.ts.map +1 -1
  3. package/dist/components/AppContainer/AppContainer.js +79 -72
  4. package/dist/components/AppContainer/AppContainer.module.css.js +20 -10
  5. package/dist/components/AppContainer/components/AppsSidebar/DesktopUpdateButton.d.ts +6 -0
  6. package/dist/components/AppContainer/components/AppsSidebar/DesktopUpdateButton.d.ts.map +1 -0
  7. package/dist/components/AppContainer/components/AppsSidebar/DesktopUpdateButton.js +161 -0
  8. package/dist/components/AppContainer/components/AppsSidebar/UserSection.d.ts.map +1 -1
  9. package/dist/components/AppContainer/components/AppsSidebar/UserSection.js +238 -105
  10. package/dist/components/AppContainer/components/Main.js +4 -4
  11. package/dist/components/AppContainer/components/SlideAnimation.js +4 -4
  12. package/dist/components/AppContainer/components/ToolSidebar.js +9 -9
  13. package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.d.ts +62 -1
  14. package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.d.ts.map +1 -1
  15. package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.js +1107 -137
  16. package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.module.css.js +158 -6
  17. package/dist/components/AppShell/AppShell.module.css.js +5 -5
  18. package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.d.ts +2 -0
  19. package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.d.ts.map +1 -1
  20. package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.js +22 -17
  21. package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.d.ts +15 -0
  22. package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.d.ts.map +1 -0
  23. package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.js +36 -0
  24. package/dist/components/AttachmentsGalleryModal/components/GallerySlide.js +22 -22
  25. package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.d.ts +14 -0
  26. package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.d.ts.map +1 -0
  27. package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.js +31 -0
  28. package/dist/components/AttachmentsGalleryModal/components/ModalHeader.d.ts.map +1 -1
  29. package/dist/components/AttachmentsGalleryModal/components/ModalHeader.js +172 -120
  30. package/dist/components/AttachmentsGalleryModal/components/ShakePlayer/ShakaPlayer.module.css.js +4 -4
  31. package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.d.ts +18 -0
  32. package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.d.ts.map +1 -0
  33. package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.js +35 -0
  34. package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.d.ts +33 -0
  35. package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.d.ts.map +1 -0
  36. package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.js +70 -0
  37. package/dist/components/AttachmentsGalleryModal/styles.module.css.js +32 -28
  38. package/dist/components/AttachmentsPreview/AttachmentsPreview.module.css.js +12 -12
  39. package/dist/components/BouncingLogo/BouncingLogo.module.css.js +4 -4
  40. package/dist/components/Chat/CallMessage/CallMessage.module.css.js +8 -8
  41. package/dist/components/Chat/ChatBubble/ChatBubble.module.css.js +1 -1
  42. package/dist/components/Chat/ChatHeader/ChatHeader.module.css.js +1 -1
  43. package/dist/components/Chat/ChatInput/ChatInput.module.css.js +44 -44
  44. package/dist/components/Chat/ChatLayout/ChatLayout.module.css.js +4 -4
  45. package/dist/components/Chat/ChatMessage/ChatMessage.module.css.js +10 -10
  46. package/dist/components/Chat/ChatPill/ChatPill.module.css.js +1 -1
  47. package/dist/components/Chat/DialogItem/DialogItem.module.css.js +4 -4
  48. package/dist/components/Chat/DialogList/DialogList.module.css.js +1 -1
  49. package/dist/components/Chat/MediaDocument/MediaDocument.module.css.js +4 -4
  50. package/dist/components/Chat/MessageActions/MessageActions.module.css.js +1 -1
  51. package/dist/components/Chat/MessageActions/index.d.ts.map +1 -1
  52. package/dist/components/Chat/MessageActions/index.js +38 -37
  53. package/dist/components/Chat/MessageForward/MessageForward.module.css.js +1 -1
  54. package/dist/components/Chat/MessageList/MessageList.module.css.js +5 -5
  55. package/dist/components/Chat/MessageMeta/MessageMeta.module.css.js +3 -3
  56. package/dist/components/Chat/MessageMeta/index.d.ts.map +1 -1
  57. package/dist/components/Chat/MessageMeta/index.js +21 -19
  58. package/dist/components/Chat/MessageReactions/MessageReactions.module.css.js +12 -12
  59. package/dist/components/Chat/MessageReply/MessageReply.module.css.js +7 -7
  60. package/dist/components/Chat/MessageStatus/MessageStatus.module.css.js +8 -8
  61. package/dist/components/Chat/ServiceMessage/ServiceMessage.module.css.js +1 -1
  62. package/dist/components/CollapsibleContainer/CollapsibleContainer.module.css.js +1 -1
  63. package/dist/components/ColorPicker/ColorPicker.d.ts +3 -0
  64. package/dist/components/ColorPicker/ColorPicker.d.ts.map +1 -1
  65. package/dist/components/ColorPicker/ColorPicker.js +81 -76
  66. package/dist/components/ColorPicker/ColorPicker.module.css.js +26 -32
  67. package/dist/components/ColorPicker/ColorPickerList.d.ts.map +1 -1
  68. package/dist/components/ColorPicker/ColorPickerList.js +72 -83
  69. package/dist/components/ColorPicker/ColorPickerToolbar.d.ts.map +1 -1
  70. package/dist/components/ColorPicker/ColorPickerToolbar.js +64 -67
  71. package/dist/components/ColorPicker/icons.js +5 -5
  72. package/dist/components/ColorPicker/types.d.ts +0 -6
  73. package/dist/components/ColorPicker/types.d.ts.map +1 -1
  74. package/dist/components/ColorPicker/types.js +11 -53
  75. package/dist/components/ColorPicker/useRecentColors.d.ts +1 -3
  76. package/dist/components/ColorPicker/useRecentColors.d.ts.map +1 -1
  77. package/dist/components/ColorPicker/useRecentColors.js +20 -43
  78. package/dist/components/CommentComposer/CommentComposer.module.css.js +4 -4
  79. package/dist/components/CommunitiesDialog/styles.module.css.js +1 -1
  80. package/dist/components/Copyright/Copyright.module.css.js +1 -1
  81. package/dist/components/CustomKBD/CustomKBD.module.css.js +1 -1
  82. package/dist/components/EmojiPicker/EmojiPicker.module.css.js +8 -8
  83. package/dist/components/EntityTitle/EntityTitle.module.css.js +1 -1
  84. package/dist/components/ErrorPage/components/Error404.d.ts.map +1 -1
  85. package/dist/components/FeatureProgress/FeatureProgress.module.css.js +49 -49
  86. package/dist/components/FilePicker/FilePicker.module.css.js +7 -7
  87. package/dist/components/FormViewer/FormViewer.module.css.js +20 -20
  88. package/dist/components/FormViewer/components/fields/DragOptions/DragOptions.module.css.js +1 -1
  89. package/dist/components/FormViewer/components/fields/DropdownField/DropdownField.module.css.js +1 -1
  90. package/dist/components/FormViewer/components/fields/EditableContent/EditableContent.module.css.js +1 -1
  91. package/dist/components/FormViewer/components/fields/SelectableCard/SelectableCard.module.css.js +8 -8
  92. package/dist/components/FormViewer/components/fields/UploadField/UploadFile/UploadFile.module.css.js +4 -4
  93. package/dist/components/FormViewer/store/formStore.d.ts.map +1 -1
  94. package/dist/components/ImageCropper/ImageCropper.module.css.js +38 -38
  95. package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.d.ts +3 -1
  96. package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.d.ts.map +1 -1
  97. package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.js +26 -25
  98. package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.module.css.js +11 -11
  99. package/dist/components/LanguagePicker/LanguagePicker.module.css.js +1 -1
  100. package/dist/components/Loaders/styles.module.css.js +6 -6
  101. package/dist/components/MediaLibrary/MediaLibrary.module.css.js +2 -2
  102. package/dist/components/MusicPlayerBar/MusicPlayerBar.module.css.js +23 -23
  103. package/dist/components/NavMenu/NavMenu.module.css.js +12 -12
  104. package/dist/components/NavbarResizer/NavbarResizer.module.css.js +2 -2
  105. package/dist/components/NewToolbar/utils.d.ts +12 -0
  106. package/dist/components/NewToolbar/utils.d.ts.map +1 -0
  107. package/dist/components/NotPublicPanel/NotPublicPanel.module.css.js +11 -11
  108. package/dist/components/Notification/Notification.module.css.js +1 -1
  109. package/dist/components/OnboardingTour/index.d.ts +1 -1
  110. package/dist/components/OnboardingTour/index.d.ts.map +1 -1
  111. package/dist/components/OnboardingTour/useOnboardingTour.d.ts +2 -0
  112. package/dist/components/OnboardingTour/useOnboardingTour.d.ts.map +1 -1
  113. package/dist/components/OnboardingTour/useOnboardingTour.js +63 -51
  114. package/dist/components/PillTabs/PillTabs.module.css.js +1 -1
  115. package/dist/components/SearchFilters/SearchFilters.module.css.js +1 -1
  116. package/dist/components/SettingsSection/styles.module.css.js +1 -1
  117. package/dist/components/StorageUsageProgress/StorageUsageProgress.module.css.js +1 -1
  118. package/dist/components/TreeIndent/TreeIndent.module.css.js +4 -4
  119. package/dist/components/VideoPlayer/VideoPlayer.d.ts +24 -0
  120. package/dist/components/VideoPlayer/VideoPlayer.d.ts.map +1 -0
  121. package/dist/components/VideoPlayer/VideoPlayer.js +727 -0
  122. package/dist/components/VideoPlayer/components/MobileDrawer/index.d.ts +8 -0
  123. package/dist/components/VideoPlayer/components/MobileDrawer/index.d.ts.map +1 -0
  124. package/dist/components/VideoPlayer/components/MobileDrawer/index.js +67 -0
  125. package/dist/components/VideoPlayer/components/SelectListOptionButton.d.ts +7 -0
  126. package/dist/components/VideoPlayer/components/SelectListOptionButton.d.ts.map +1 -0
  127. package/dist/components/VideoPlayer/components/SelectListOptionButton.js +44 -0
  128. package/dist/components/VideoPlayer/components/StoryboardPreview.d.ts +9 -0
  129. package/dist/components/VideoPlayer/components/StoryboardPreview.d.ts.map +1 -0
  130. package/dist/components/VideoPlayer/components/StoryboardPreview.js +38 -0
  131. package/dist/components/VideoPlayer/components/VideoCustomControls.d.ts +33 -0
  132. package/dist/components/VideoPlayer/components/VideoCustomControls.d.ts.map +1 -0
  133. package/dist/components/VideoPlayer/components/VideoCustomControls.js +601 -0
  134. package/dist/components/VideoPlayer/components/VideoIcons.d.ts +25 -0
  135. package/dist/components/VideoPlayer/components/VideoIcons.d.ts.map +1 -0
  136. package/dist/components/VideoPlayer/components/VideoIcons.js +145 -0
  137. package/dist/components/VideoPlayer/components/VideoMenu.d.ts +27 -0
  138. package/dist/components/VideoPlayer/components/VideoMenu.d.ts.map +1 -0
  139. package/dist/components/VideoPlayer/components/VideoMenu.js +77 -0
  140. package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.d.ts +17 -0
  141. package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.d.ts.map +1 -0
  142. package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.js +289 -0
  143. package/dist/components/VideoPlayer/components/VideoQualityMenu/index.d.ts +10 -0
  144. package/dist/components/VideoPlayer/components/VideoQualityMenu/index.d.ts.map +1 -0
  145. package/dist/components/VideoPlayer/components/VideoQualityMenu/index.js +55 -0
  146. package/dist/components/VideoPlayer/components/VideoSelect.d.ts +10 -0
  147. package/dist/components/VideoPlayer/components/VideoSelect.d.ts.map +1 -0
  148. package/dist/components/VideoPlayer/components/VideoSelect.js +168 -0
  149. package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.d.ts +12 -0
  150. package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.d.ts.map +1 -0
  151. package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.js +48 -0
  152. package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.d.ts +25 -0
  153. package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.d.ts.map +1 -0
  154. package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.js +384 -0
  155. package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.d.ts +21 -0
  156. package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.d.ts.map +1 -0
  157. package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.js +264 -0
  158. package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.d.ts +10 -0
  159. package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.d.ts.map +1 -0
  160. package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.js +39 -0
  161. package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.d.ts +14 -0
  162. package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.d.ts.map +1 -0
  163. package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.js +360 -0
  164. package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitleTrackRow.d.ts +16 -0
  165. package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitleTrackRow.d.ts.map +1 -0
  166. package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitlesSection.d.ts +14 -0
  167. package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitlesSection.d.ts.map +1 -0
  168. package/dist/components/VideoPlayer/components/VideoSettingsModal/context.d.ts +4 -0
  169. package/dist/components/VideoPlayer/components/VideoSettingsModal/context.d.ts.map +1 -0
  170. package/dist/components/VideoPlayer/components/VideoSettingsModal/context.js +14 -0
  171. package/dist/components/VideoPlayer/components/VideoSettingsModal/index.d.ts +22 -0
  172. package/dist/components/VideoPlayer/components/VideoSettingsModal/index.d.ts.map +1 -0
  173. package/dist/components/VideoPlayer/components/VideoSettingsModal/index.js +211 -0
  174. package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.d.ts +11 -0
  175. package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.d.ts.map +1 -0
  176. package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.js +41 -0
  177. package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.d.ts +10 -0
  178. package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.d.ts.map +1 -0
  179. package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.js +69 -0
  180. package/dist/components/VideoPlayer/hooks/useStoryboard.d.ts +21 -0
  181. package/dist/components/VideoPlayer/hooks/useStoryboard.d.ts.map +1 -0
  182. package/dist/components/VideoPlayer/hooks/useStoryboard.js +91 -0
  183. package/dist/components/VideoPlayer/index.d.ts +11 -0
  184. package/dist/components/VideoPlayer/index.d.ts.map +1 -0
  185. package/dist/components/VideoPlayer/types.d.ts +101 -0
  186. package/dist/components/VideoPlayer/types.d.ts.map +1 -0
  187. package/dist/components/VideoPlayer/utils/chapters.d.ts +8 -0
  188. package/dist/components/VideoPlayer/utils/chapters.d.ts.map +1 -0
  189. package/dist/components/VideoPlayer/utils/chapters.js +38 -0
  190. package/dist/components/VideoPlayer/utils/storyboard.d.ts +5 -0
  191. package/dist/components/VideoPlayer/utils/storyboard.d.ts.map +1 -0
  192. package/dist/components/VideoPlayer/utils/storyboard.js +47 -0
  193. package/dist/components/VideoPlayer/utils/subtitles.d.ts +18 -0
  194. package/dist/components/VideoPlayer/utils/subtitles.d.ts.map +1 -0
  195. package/dist/components/VideoPlayer/utils/subtitles.js +23 -0
  196. package/dist/components/VideoPlayer/utils/touch.d.ts +3 -0
  197. package/dist/components/VideoPlayer/utils/touch.d.ts.map +1 -0
  198. package/dist/components/VideoPlayer/utils/touch.js +5 -0
  199. package/dist/components/VideoPlayer/utils/videoPlayerUtils.d.ts +10 -0
  200. package/dist/components/VideoPlayer/utils/videoPlayerUtils.d.ts.map +1 -0
  201. package/dist/components/VideoPlayer/utils/videoPlayerUtils.js +22 -0
  202. package/dist/components/VideoPlayer/utils/videoSettings.d.ts +69 -0
  203. package/dist/components/VideoPlayer/utils/videoSettings.d.ts.map +1 -0
  204. package/dist/components/VideoPlayer/utils/videoSettings.js +90 -0
  205. package/dist/components/table/FrontTable.d.ts.map +1 -1
  206. package/dist/components/table/hooks/useColumnsResizing.d.ts.map +1 -1
  207. package/dist/config/brand.d.ts.map +1 -1
  208. package/dist/config/brand.js +29 -29
  209. package/dist/config/envConfig.d.ts +2 -0
  210. package/dist/config/envConfig.d.ts.map +1 -1
  211. package/dist/helpers/showFeatureFeedback.module.css.js +4 -4
  212. package/dist/helpers/showNotifications.d.ts +8 -14
  213. package/dist/helpers/showNotifications.d.ts.map +1 -1
  214. package/dist/helpers/showNotifications.js +107 -111
  215. package/dist/helpers/showNotifications.module.css.js +4 -16
  216. package/dist/hooks/useDateUtils.d.ts.map +1 -1
  217. package/dist/hooks/useDateUtils.js +19 -23
  218. package/dist/index.css +1 -1
  219. package/dist/index.d.ts +2 -0
  220. package/dist/index.d.ts.map +1 -1
  221. package/dist/index.js +589 -575
  222. package/dist/lang/locales/ui_en.json.js +1 -1
  223. package/dist/lang/locales/ui_es.json.js +1 -1
  224. package/dist/lang/locales/ui_ru.json.js +1 -1
  225. package/dist/videoSettings/createVideoSettingsDataSource.d.ts +19 -0
  226. package/dist/videoSettings/createVideoSettingsDataSource.d.ts.map +1 -0
  227. package/dist/videoSettings/createVideoSettingsDataSource.js +127 -0
  228. package/docs/README.md +499 -499
  229. package/package.json +79 -78
@@ -1,35 +1,37 @@
1
- import { jsx as e, jsxs as b } from "react/jsx-runtime";
2
- import { forwardRef as k, useState as g } from "react";
3
- import { useTranslation as j } from "react-i18next";
4
- import { Tick02Icon as A } from "@hugeicons/core-free-icons";
5
- import { HugeiconsIcon as E } from "@hugeicons/react";
6
- import { useMantineTheme as z, getThemeColor as R, Flex as x, Tooltip as D, ColorSwatch as F, parseThemeColor as H, ColorInput as M, ActionIcon as y } from "@mantine/core";
7
- import { IconPalette as U, IconPencil as V } from "@tabler/icons-react";
8
- import q from "styled-components";
9
- import { DEFAULT_VALUES as w } from "../../constants.js";
10
- import { ColorPickerList as _ } from "./ColorPickerList.js";
11
- import { ColorPickerToolbar as B } from "./ColorPickerToolbar.js";
12
- import { resolveColorLabel as G, normalizeColorItem as J } from "./types.js";
13
- const K = k(
1
+ import { jsx as e, jsxs as v } from "react/jsx-runtime";
2
+ import { forwardRef as z, useState as y } from "react";
3
+ import { useTranslation as E } from "react-i18next";
4
+ import { Tick02Icon as R } from "@hugeicons/core-free-icons";
5
+ import { HugeiconsIcon as D } from "@hugeicons/react";
6
+ import { useMantineTheme as I, getThemeColor as F, Flex as x, Tooltip as H, ColorSwatch as M, parseThemeColor as U, ColorInput as V, ActionIcon as w } from "@mantine/core";
7
+ import { IconPalette as q, IconPencil as _ } from "@tabler/icons-react";
8
+ import B from "styled-components";
9
+ import { DEFAULT_VALUES as k } from "../../constants.js";
10
+ import { ColorPickerList as G } from "./ColorPickerList.js";
11
+ import { ColorPickerToolbar as J } from "./ColorPickerToolbar.js";
12
+ import { resolveColorLabel as K, normalizeColorItem as N } from "./types.js";
13
+ const Q = z(
14
14
  ({
15
15
  value: o,
16
16
  onChange: l,
17
17
  allowCustomColor: n,
18
18
  colors: s,
19
- swatchShape: c = "circle",
20
- swatchVariant: m = "filled",
21
- withTick: d = !1,
22
- fullWidth: p = !1,
23
- swatchSize: i = 30,
24
- ...u
25
- }, f) => {
26
- const h = z(), r = H({
27
- color: o || w.COLORS[0],
28
- theme: h
29
- }), [t, C] = g(r.value), [L, v] = g(!1);
30
- return L ? /* @__PURE__ */ b(x, { align: "center", mih: 30, children: [
19
+ swatchShape: m = "circle",
20
+ swatchVariant: d = "filled",
21
+ withTick: p = !1,
22
+ fullWidth: u = !1,
23
+ swatchSize: f = 30,
24
+ wrapperHeight: i,
25
+ customSizes: a,
26
+ ...h
27
+ }, C) => {
28
+ const r = I(), t = U({
29
+ color: o || k.COLORS[0],
30
+ theme: r
31
+ }), [b, O] = y(t.value), [T, g] = y(!1);
32
+ return T ? /* @__PURE__ */ v(x, { align: "center", mih: 30, children: [
31
33
  /* @__PURE__ */ e(
32
- M,
34
+ V,
33
35
  {
34
36
  w: "100%",
35
37
  popoverProps: {
@@ -39,62 +41,64 @@ const K = k(
39
41
  maxLength: 7,
40
42
  withEyeDropper: !1,
41
43
  size: "xs",
42
- value: t,
43
- onChange: C,
44
+ value: b,
45
+ onChange: O,
44
46
  onChangeEnd: l,
45
47
  placeholder: "Select custom color"
46
48
  }
47
49
  ),
48
50
  /* @__PURE__ */ e(
49
- y,
51
+ w,
50
52
  {
51
53
  radius: "xl",
52
54
  variant: "default",
53
55
  color: "gray",
54
- onClick: () => v(!1),
55
- children: /* @__PURE__ */ e(U, { size: 16 })
56
+ onClick: () => g(!1),
57
+ children: /* @__PURE__ */ e(q, { size: 16 })
56
58
  }
57
59
  )
58
- ] }, 1) : /* @__PURE__ */ b(
60
+ ] }, 1) : /* @__PURE__ */ v(
59
61
  x,
60
62
  {
61
- ref: f,
62
- ...u,
63
- justify: p ? "space-between" : "flex-start",
63
+ ref: C,
64
+ ...h,
65
+ justify: u ? "space-between" : "flex-start",
64
66
  align: "center",
67
+ mih: a && i || 32,
65
68
  children: [
66
- (s || w.COLORS).map((O, T) => {
69
+ (s || k.COLORS).map((P, S) => {
67
70
  const {
68
- value: a,
69
- border: P,
70
- bg: S,
71
- label: $
72
- } = J(O);
71
+ value: c,
72
+ border: $,
73
+ bg: j,
74
+ label: A
75
+ } = N(P);
73
76
  return /* @__PURE__ */ e(
74
- N,
77
+ W,
75
78
  {
76
- value: a,
77
- label: $,
78
- isActive: a === o,
79
- size: i - 4,
80
- swatchShape: c,
81
- swatchVariant: m,
82
- withTick: d,
83
- borderColor: P,
84
- bgColor: S,
85
- onClick: () => l?.(a)
79
+ value: c,
80
+ label: A,
81
+ isActive: c === o,
82
+ size: f - 4,
83
+ swatchShape: m,
84
+ swatchVariant: d,
85
+ withTick: p,
86
+ borderColor: $,
87
+ bgColor: j,
88
+ onClick: () => l?.(c),
89
+ swatchSize: a ? f : void 0
86
90
  },
87
- a || T
91
+ c || S
88
92
  );
89
93
  }),
90
94
  n && /* @__PURE__ */ e(
91
- y,
95
+ w,
92
96
  {
93
97
  radius: "xl",
94
98
  variant: "default",
95
99
  color: "gray",
96
- onClick: () => v(!0),
97
- children: /* @__PURE__ */ e(V, { size: 16 })
100
+ onClick: () => g(!0),
101
+ children: /* @__PURE__ */ e(_, { size: 16 })
98
102
  }
99
103
  )
100
104
  ]
@@ -102,19 +106,20 @@ const K = k(
102
106
  2
103
107
  );
104
108
  }
105
- ), I = k(
109
+ ), L = z(
106
110
  ({
107
111
  value: o,
108
112
  label: l,
109
113
  isActive: n,
110
114
  swatchShape: s,
111
- swatchVariant: c = "filled",
112
- withTick: m,
113
- borderColor: d,
114
- bgColor: p,
115
+ swatchVariant: m = "filled",
116
+ withTick: d,
117
+ borderColor: p,
118
+ bgColor: u,
119
+ swatchSize: f,
115
120
  ...i
116
- }, u) => {
117
- const f = z(), { t: h } = j("ui"), r = o ? R(o, f) : "", t = c === "outline", C = G(h, o, l);
121
+ }, a) => {
122
+ const h = I(), { t: C } = E("ui"), r = o ? F(o, h) : "", t = m === "outline", b = K(C, o, l);
118
123
  return /* @__PURE__ */ e(
119
124
  x,
120
125
  {
@@ -123,10 +128,10 @@ const K = k(
123
128
  justify: "center",
124
129
  align: "center",
125
130
  style: { position: "relative" },
126
- children: /* @__PURE__ */ e(D, { label: C, withArrow: !0, zIndex: 300, children: /* @__PURE__ */ b(
127
- F,
131
+ children: /* @__PURE__ */ e(H, { label: b, withArrow: !0, children: /* @__PURE__ */ v(
132
+ M,
128
133
  {
129
- ref: u,
134
+ ref: a,
130
135
  color: t ? "transparent" : r,
131
136
  radius: s === "circle" ? "xl" : "sm",
132
137
  styles: t ? {
@@ -136,8 +141,8 @@ const K = k(
136
141
  style: {
137
142
  cursor: "pointer",
138
143
  color: "var(--mantine-color-white)",
139
- background: t ? p || `var(--mantine-color-${o}-light, ${r}20)` : void 0,
140
- border: t ? `2px solid ${d || `var(--mantine-color-${o}-outline, ${r})`}` : void 0
144
+ background: t ? u || `var(--mantine-color-${o}-light, ${r}20)` : void 0,
145
+ border: t ? `2px solid ${p || `var(--mantine-color-${o}-outline, ${r})`}` : void 0
141
146
  },
142
147
  ...i,
143
148
  children: [
@@ -157,23 +162,23 @@ const K = k(
157
162
  }
158
163
  }
159
164
  ),
160
- m && n && /* @__PURE__ */ e(E, { size: 20, icon: A })
165
+ d && n && /* @__PURE__ */ e(D, { size: 20, icon: R })
161
166
  ]
162
167
  }
163
168
  ) })
164
169
  }
165
170
  );
166
171
  }
167
- ), N = q(I)`
172
+ ), W = B(L)`
168
173
  .mantine-ColorSwatch-colorOverlay {
169
174
  border-radius: ${({ swatchShape: o }) => o === "square" ? "3px" : "50%"};
170
175
  }
171
- `, ao = Object.assign(K, {
172
- ColorCircle: I,
173
- List: _,
174
- Toolbar: B
176
+ `, mo = Object.assign(Q, {
177
+ ColorCircle: L,
178
+ List: G,
179
+ Toolbar: J
175
180
  });
176
181
  export {
177
- I as ColorCircle,
178
- ao as ColorPicker
182
+ L as ColorCircle,
183
+ mo as ColorPicker
179
184
  };
@@ -1,37 +1,31 @@
1
- const i = "_section_1go5u_3", n = "_sectionLabel_1go5u_29", t = "_listItemCaption_1go5u_45", e = "_listItem_1go5u_45", o = "_listItemActive_1go5u_155", c = "_listItemLabel_1go5u_163", l = "_listItemSwatch_1go5u_179", _ = "_grid_1go5u_195", s = "_inlineSection_1go5u_335", a = "_inlineSectionLabel_1go5u_355", S = "_inlineSectionLabelRow_1go5u_371", u = "_inlineSectionCaption_1go5u_383", g = "_inlineRow_1go5u_395", w = "_inlineSwatch_1go5u_413", m = "_inlineSwatchActive_1go5u_465", I = "_inlineSwatchRound_1go5u_485", b = {
1
+ const i = "_section_lidow_2", t = "_sectionLabel_lidow_15", n = "_listItem_lidow_46", e = "_listItemActive_lidow_72", l = "_listItemLabel_lidow_76", o = "_listItemSwatch_lidow_84", c = "_grid_lidow_92", _ = "_inlineSection_lidow_162", s = "_inlineSectionLabel_lidow_172", w = "_inlineRow_lidow_180", a = "_inlineSwatch_lidow_189", d = "_inlineSwatchActive_lidow_215", S = "_inlineSwatchRound_lidow_225", h = {
2
2
  section: i,
3
- sectionLabel: n,
4
- listItemCaption: t,
5
- listItem: e,
6
- listItemActive: o,
7
- listItemLabel: c,
8
- listItemSwatch: l,
9
- grid: _,
10
- inlineSection: s,
11
- inlineSectionLabel: a,
12
- inlineSectionLabelRow: S,
13
- inlineSectionCaption: u,
14
- inlineRow: g,
15
- inlineSwatch: w,
16
- inlineSwatchActive: m,
17
- inlineSwatchRound: I
3
+ sectionLabel: t,
4
+ listItem: n,
5
+ listItemActive: e,
6
+ listItemLabel: l,
7
+ listItemSwatch: o,
8
+ grid: c,
9
+ inlineSection: _,
10
+ inlineSectionLabel: s,
11
+ inlineRow: w,
12
+ inlineSwatch: a,
13
+ inlineSwatchActive: d,
14
+ inlineSwatchRound: S
18
15
  };
19
16
  export {
20
- b as default,
21
- _ as grid,
22
- g as inlineRow,
23
- s as inlineSection,
24
- u as inlineSectionCaption,
25
- a as inlineSectionLabel,
26
- S as inlineSectionLabelRow,
27
- w as inlineSwatch,
28
- m as inlineSwatchActive,
29
- I as inlineSwatchRound,
30
- e as listItem,
31
- o as listItemActive,
32
- t as listItemCaption,
33
- c as listItemLabel,
34
- l as listItemSwatch,
17
+ h as default,
18
+ c as grid,
19
+ w as inlineRow,
20
+ _ as inlineSection,
21
+ s as inlineSectionLabel,
22
+ a as inlineSwatch,
23
+ d as inlineSwatchActive,
24
+ S as inlineSwatchRound,
25
+ n as listItem,
26
+ e as listItemActive,
27
+ l as listItemLabel,
28
+ o as listItemSwatch,
35
29
  i as section,
36
- n as sectionLabel
30
+ t as sectionLabel
37
31
  };
@@ -1 +1 @@
1
- {"version":3,"file":"ColorPickerList.d.ts","sourceRoot":"","sources":["../../../src/components/ColorPicker/ColorPickerList.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,oBAAoB,EAAgB,MAAM,SAAS,CAAC;AAiIlE;;oEAEoE;AACpE,wBAAgB,eAAe,CAAC,EAC9B,QAAQ,EACR,MAAM,EACN,KAAK,EACL,QAAQ,EACR,OAAW,EACX,gBAAgB,GACjB,EAAE,oBAAoB,2CAkEtB"}
1
+ {"version":3,"file":"ColorPickerList.d.ts","sourceRoot":"","sources":["../../../src/components/ColorPicker/ColorPickerList.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,oBAAoB,EAAgB,MAAM,SAAS,CAAC;AAqHlE;;oEAEoE;AACpE,wBAAgB,eAAe,CAAC,EAC9B,QAAQ,EACR,MAAM,EACN,KAAK,EACL,QAAQ,EACR,OAAW,EACX,gBAAgB,GACjB,EAAE,oBAAoB,2CA8CtB"}
@@ -1,32 +1,32 @@
1
- import { jsxs as C, jsx as r } from "react/jsx-runtime";
2
- import { useTranslation as x } from "react-i18next";
3
- import { Tick02Icon as L } from "@hugeicons/core-free-icons";
4
- import { HugeiconsIcon as T } from "@hugeicons/react";
5
- import { useComputedColorScheme as S, Box as F, useMantineTheme as E, getThemeColor as O, ColorSwatch as R } from "@mantine/core";
6
- import { TextColorIcon as w } from "./icons.js";
7
- import { normalizeColorItem as I, RECENT_COLOR_HOTKEY as z, resolveRecentKind as D, colorsEqual as K, resolveColorLabel as $, isDefaultColor as N } from "./types.js";
8
- import { useRecentColors as M } from "./useRecentColors.js";
9
- import s from "./ColorPicker.module.css.js";
1
+ import { jsxs as y, jsx as r } from "react/jsx-runtime";
2
+ import { useTranslation as g } from "react-i18next";
3
+ import { Tick02Icon as k } from "@hugeicons/core-free-icons";
4
+ import { HugeiconsIcon as x } from "@hugeicons/react";
5
+ import { useComputedColorScheme as L, Box as S, useMantineTheme as F, getThemeColor as N, ColorSwatch as T } from "@mantine/core";
6
+ import { TextColorIcon as z } from "./icons.js";
7
+ import { resolveColorLabel as D, isDefaultColor as b, normalizeColorItem as $ } from "./types.js";
8
+ import { useRecentColors as w } from "./useRecentColors.js";
9
+ import i from "./ColorPicker.module.css.js";
10
10
  function j({
11
11
  type: e,
12
- colorValue: n,
13
- resolvedColor: i,
14
- border: c,
15
- bg: m
12
+ colorValue: l,
13
+ resolvedColor: n,
14
+ border: s,
15
+ bg: c
16
16
  }) {
17
17
  if (e === "text")
18
- return /* @__PURE__ */ r(w, { size: 16, color: i, showBorder: !0 });
19
- const a = N(n);
18
+ return /* @__PURE__ */ r(z, { size: 16, color: n, showBorder: !0 });
19
+ const a = b(l);
20
20
  return /* @__PURE__ */ r(
21
- R,
21
+ T,
22
22
  {
23
- color: a ? "var(--mantine-color-body)" : m || c || n,
23
+ color: a ? "var(--mantine-color-body)" : c || s || l,
24
24
  size: 16,
25
25
  radius: "xl",
26
- className: s.listItemSwatch,
26
+ className: i.listItemSwatch,
27
27
  styles: {
28
28
  root: {
29
- border: `1.5px solid ${a ? "var(--mantine-color-default-border)" : c || i}`
29
+ border: `1.5px solid ${a ? "var(--mantine-color-default-border)" : s || n}`
30
30
  },
31
31
  alphaOverlay: { display: "none" },
32
32
  shadowOverlay: { display: "none" }
@@ -34,113 +34,102 @@ function j({
34
34
  }
35
35
  );
36
36
  }
37
- function g({
37
+ function v({
38
38
  section: e,
39
- columns: n,
40
- onChange: i,
41
- isDark: c,
42
- itemCaption: m
39
+ columns: l,
40
+ onChange: n,
41
+ isDark: s
43
42
  }) {
44
- const a = E(), { t: v } = x("ui"), y = n > 1;
45
- return /* @__PURE__ */ C("div", { className: s.section, children: [
46
- e.label && /* @__PURE__ */ r("div", { className: s.sectionLabel, children: e.label }),
43
+ const c = F(), { t: a } = g("ui"), p = l > 1;
44
+ return /* @__PURE__ */ y("div", { className: i.section, children: [
45
+ e.label && /* @__PURE__ */ r("div", { className: i.sectionLabel, children: e.label }),
47
46
  /* @__PURE__ */ r(
48
47
  "div",
49
48
  {
50
- className: y ? s.grid : void 0,
51
- style: y ? { gridTemplateColumns: `repeat(${n}, minmax(0, 1fr))` } : void 0,
52
- children: e.colors.map((u) => {
49
+ className: p ? i.grid : void 0,
50
+ style: p ? { gridTemplateColumns: `repeat(${l}, minmax(0, 1fr))` } : void 0,
51
+ children: e.colors.map((d) => {
53
52
  const {
54
- value: l,
55
- label: b,
56
- border: p,
57
- bg: f
58
- } = I(u), t = N(l), d = K(l, e.value), h = t ? c ? "#FFFFFF" : "#000000" : O(l, a), o = $(v, l, b);
59
- return /* @__PURE__ */ C(
53
+ value: o,
54
+ label: f,
55
+ border: u,
56
+ bg: h
57
+ } = $(d), t = b(o), m = o === e.value, C = t ? s ? "#FFFFFF" : "#000000" : N(o, c), I = D(a, o, f);
58
+ return /* @__PURE__ */ y(
60
59
  "button",
61
60
  {
62
61
  type: "button",
63
- className: `${s.listItem} ${d ? s.listItemActive : ""}`,
64
- onClick: () => i(l, e.key),
62
+ className: `${i.listItem} ${m ? i.listItemActive : ""}`,
63
+ onClick: () => n(o, e.key),
65
64
  children: [
66
65
  /* @__PURE__ */ r(
67
66
  j,
68
67
  {
69
68
  type: e.type,
70
- colorValue: l,
71
- resolvedColor: h,
72
- border: p,
73
- bg: f
69
+ colorValue: o,
70
+ resolvedColor: C,
71
+ border: u,
72
+ bg: h
74
73
  }
75
74
  ),
76
- /* @__PURE__ */ r("span", { className: s.listItemLabel, children: o }),
77
- m && /* @__PURE__ */ r("span", { className: s.listItemCaption, children: m }),
78
- d && /* @__PURE__ */ r(
79
- T,
75
+ /* @__PURE__ */ r("span", { className: i.listItemLabel, children: I }),
76
+ m && /* @__PURE__ */ r(
77
+ x,
80
78
  {
81
79
  size: 16,
82
- icon: L,
80
+ icon: k,
83
81
  color: "var(--mantine-primary-color-filled)"
84
82
  }
85
83
  )
86
84
  ]
87
85
  },
88
- l
86
+ o
89
87
  );
90
88
  })
91
89
  }
92
90
  )
93
91
  ] });
94
92
  }
95
- function J({
93
+ function P({
96
94
  sections: e,
97
- colors: n,
98
- value: i,
99
- onChange: c,
100
- columns: m = 1,
95
+ colors: l,
96
+ value: n,
97
+ onChange: s,
98
+ columns: c = 1,
101
99
  withRecentColors: a
102
100
  }) {
103
- const { t: v } = x("ui"), u = S("light", {
101
+ const d = L("light", {
104
102
  getInitialValueInEffect: !0
105
- }) === "dark", { recentColors: l, addRecent: b } = M(), p = (o, k) => {
106
- a && b(o, k), c?.(o, k);
107
- }, f = e || (n ? [{ key: "default", label: "", colors: n, value: i }] : []), t = l[0], d = t ? f.find((o) => o.key === t.sectionKey)?.colors.find(
108
- (o) => I(o).value === t.value
109
- ) : void 0, h = d ? I(d) : void 0;
110
- return /* @__PURE__ */ C(F, { w: "100%", children: [
111
- a && t && /* @__PURE__ */ r(
112
- g,
103
+ }) === "dark", { recentColors: o, addRecent: f } = w(), u = (t, m) => {
104
+ a && f(t, m), s?.(t, m);
105
+ }, h = e || (l ? [{ key: "default", label: "", colors: l, value: n }] : []);
106
+ return /* @__PURE__ */ y(S, { children: [
107
+ a && o.length > 0 && /* @__PURE__ */ r(
108
+ v,
113
109
  {
114
110
  section: {
115
- key: t.sectionKey ?? "",
116
- label: v("colorPicker.recentlyUsed"),
117
- type: D(t.sectionKey),
118
- colors: [
119
- {
120
- value: t.value,
121
- label: h?.label,
122
- border: t.border ?? h?.border
123
- }
124
- ]
111
+ key: "__recent",
112
+ label: "Recently used",
113
+ colors: o.map((t) => t.value),
114
+ value: n
125
115
  },
126
116
  columns: 1,
127
- itemCaption: z,
128
- onChange: p,
129
- isDark: u
117
+ onChange: u,
118
+ isDark: d
130
119
  }
131
120
  ),
132
- f.map((o) => /* @__PURE__ */ r(
133
- g,
121
+ h.map((t) => /* @__PURE__ */ r(
122
+ v,
134
123
  {
135
- section: o,
136
- columns: m,
137
- onChange: p,
138
- isDark: u
124
+ section: t,
125
+ columns: c,
126
+ onChange: u,
127
+ isDark: d
139
128
  },
140
- o.key
129
+ t.key
141
130
  ))
142
131
  ] });
143
132
  }
144
133
  export {
145
- J as ColorPickerList
134
+ P as ColorPickerList
146
135
  };
@@ -1 +1 @@
1
- {"version":3,"file":"ColorPickerToolbar.d.ts","sourceRoot":"","sources":["../../../src/components/ColorPicker/ColorPickerToolbar.tsx"],"names":[],"mappings":"AAYA,OAAO,KAAK,EAAE,mBAAmB,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAYjE;6DAC6D;AAC7D,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,YAAY,EAAE,CAAC;IACzB,QAAQ,EAAE,mBAAmB,CAAC;IAC9B,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAsCD,eAAO,MAAM,kBAAkB,oHA0M9B,CAAC"}
1
+ {"version":3,"file":"ColorPickerToolbar.d.ts","sourceRoot":"","sources":["../../../src/components/ColorPicker/ColorPickerToolbar.tsx"],"names":[],"mappings":"AAYA,OAAO,KAAK,EAAE,mBAAmB,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAMjE;6DAC6D;AAC7D,MAAM,WAAW,uBAAuB;IACtC,QAAQ,EAAE,YAAY,EAAE,CAAC;IACzB,QAAQ,EAAE,mBAAmB,CAAC;IAC9B,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAsCD,eAAO,MAAM,kBAAkB,oHAiM9B,CAAC"}