@layers-app/shared 0.4.7 → 0.4.8

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 (378) hide show
  1. package/dist/assets/default-workspace-avatar.jpg.js +1 -1
  2. package/dist/components/AliasTextInput/AliasTextInput.d.ts.map +1 -1
  3. package/dist/components/AliasTextInput/AliasTextInput.js +32 -32
  4. package/dist/components/AnimatedFigurePage/AnimatedFigurePage.module.css.js +13 -13
  5. package/dist/components/AppContainer/AppContainer.d.ts +1 -1
  6. package/dist/components/AppContainer/AppContainer.d.ts.map +1 -1
  7. package/dist/components/AppContainer/AppContainer.js +76 -71
  8. package/dist/components/AppContainer/AppContainer.module.css.js +14 -14
  9. package/dist/components/AppContainer/components/AppsSidebar/TopSection.d.ts.map +1 -1
  10. package/dist/components/AppContainer/components/AppsSidebar/TopSection.js +77 -49
  11. package/dist/components/AppContainer/components/NavbarContent.d.ts.map +1 -1
  12. package/dist/components/AppContainer/components/NavbarContent.js +16 -2
  13. package/dist/components/AppContainer/components/ToolSidebar.d.ts +5 -0
  14. package/dist/components/AppContainer/components/ToolSidebar.d.ts.map +1 -1
  15. package/dist/components/AppContainer/components/ToolSidebar.js +42 -30
  16. package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.module.css.js +90 -90
  17. package/dist/components/AppContainer/types.d.ts +12 -0
  18. package/dist/components/AppContainer/types.d.ts.map +1 -1
  19. package/dist/components/AppShell/AppShell.module.css.js +5 -5
  20. package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.d.ts +0 -2
  21. package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.d.ts.map +1 -1
  22. package/dist/components/AttachmentsGalleryModal/AttachmentsGalleryContext.js +17 -22
  23. package/dist/components/AttachmentsGalleryModal/components/GallerySlide.js +22 -22
  24. package/dist/components/AttachmentsGalleryModal/components/ModalHeader.d.ts.map +1 -1
  25. package/dist/components/AttachmentsGalleryModal/components/ModalHeader.js +120 -172
  26. package/dist/components/AttachmentsGalleryModal/components/ShakePlayer/ShakaPlayer.module.css.js +4 -4
  27. package/dist/components/AttachmentsGalleryModal/styles.module.css.js +28 -32
  28. package/dist/components/AttachmentsPreview/AttachmentsPreview.d.ts +3 -1
  29. package/dist/components/AttachmentsPreview/AttachmentsPreview.d.ts.map +1 -1
  30. package/dist/components/AttachmentsPreview/AttachmentsPreview.js +237 -93
  31. package/dist/components/AttachmentsPreview/AttachmentsPreview.module.css.js +22 -20
  32. package/dist/components/BouncingLogo/BouncingLogo.module.css.js +4 -4
  33. package/dist/components/Chat/CallMessage/CallMessage.module.css.js +8 -8
  34. package/dist/components/Chat/ChatBubble/ChatBubble.module.css.js +1 -1
  35. package/dist/components/Chat/ChatHeader/ChatHeader.module.css.js +1 -1
  36. package/dist/components/Chat/ChatInput/ChatInput.module.css.js +44 -44
  37. package/dist/components/Chat/ChatInput/index.d.ts +13 -1
  38. package/dist/components/Chat/ChatInput/index.d.ts.map +1 -1
  39. package/dist/components/Chat/ChatInput/index.js +264 -164
  40. package/dist/components/Chat/ChatInput/useVoiceRecorder.d.ts +16 -0
  41. package/dist/components/Chat/ChatInput/useVoiceRecorder.d.ts.map +1 -0
  42. package/dist/components/Chat/ChatInput/useVoiceRecorder.js +83 -0
  43. package/dist/components/Chat/ChatLayout/ChatLayout.module.css.js +4 -4
  44. package/dist/components/Chat/ChatMessage/ChatMessage.module.css.js +20 -16
  45. package/dist/components/Chat/ChatMessage/index.d.ts +16 -0
  46. package/dist/components/Chat/ChatMessage/index.d.ts.map +1 -1
  47. package/dist/components/Chat/ChatMessage/index.js +153 -118
  48. package/dist/components/Chat/ChatPill/ChatPill.module.css.js +1 -1
  49. package/dist/components/Chat/DialogItem/DialogItem.module.css.js +4 -4
  50. package/dist/components/Chat/DialogList/DialogList.module.css.js +1 -1
  51. package/dist/components/Chat/MediaDocument/MediaDocument.module.css.js +4 -4
  52. package/dist/components/Chat/MessageActions/MessageActions.module.css.js +1 -1
  53. package/dist/components/Chat/MessageActions/index.d.ts +2 -0
  54. package/dist/components/Chat/MessageActions/index.d.ts.map +1 -1
  55. package/dist/components/Chat/MessageActions/index.js +188 -50
  56. package/dist/components/Chat/MessageAuthor/index.d.ts +7 -1
  57. package/dist/components/Chat/MessageAuthor/index.d.ts.map +1 -1
  58. package/dist/components/Chat/MessageAuthor/index.js +39 -25
  59. package/dist/components/Chat/MessageForward/MessageForward.module.css.js +1 -1
  60. package/dist/components/Chat/MessageList/MessageList.module.css.js +14 -12
  61. package/dist/components/Chat/MessageList/index.d.ts +17 -25
  62. package/dist/components/Chat/MessageList/index.d.ts.map +1 -1
  63. package/dist/components/Chat/MessageList/index.js +201 -149
  64. package/dist/components/Chat/MessageMeta/MessageMeta.module.css.js +3 -3
  65. package/dist/components/Chat/MessageReactions/MessageReactions.module.css.js +12 -12
  66. package/dist/components/Chat/MessageReply/MessageReply.module.css.js +7 -7
  67. package/dist/components/Chat/MessageStatus/MessageStatus.module.css.js +8 -8
  68. package/dist/components/Chat/ServiceMessage/ServiceMessage.module.css.js +1 -1
  69. package/dist/components/CollapsibleContainer/CollapsibleContainer.module.css.js +1 -1
  70. package/dist/components/ColorPicker/ColorPicker.module.css.js +32 -26
  71. package/dist/components/ColorPicker/ColorPickerList.d.ts.map +1 -1
  72. package/dist/components/ColorPicker/ColorPickerList.js +83 -72
  73. package/dist/components/ColorPicker/ColorPickerToolbar.d.ts +1 -0
  74. package/dist/components/ColorPicker/ColorPickerToolbar.d.ts.map +1 -1
  75. package/dist/components/ColorPicker/ColorPickerToolbar.js +94 -85
  76. package/dist/components/ColorPicker/icons.js +5 -5
  77. package/dist/components/ColorPicker/types.d.ts +6 -0
  78. package/dist/components/ColorPicker/types.d.ts.map +1 -1
  79. package/dist/components/ColorPicker/types.js +53 -11
  80. package/dist/components/ColorPicker/useRecentColors.d.ts +3 -1
  81. package/dist/components/ColorPicker/useRecentColors.d.ts.map +1 -1
  82. package/dist/components/ColorPicker/useRecentColors.js +43 -20
  83. package/dist/components/CommentComposer/CommentComposer.module.css.js +4 -4
  84. package/dist/components/CommentComposer/CommentEditorHotkeys.d.ts +2 -1
  85. package/dist/components/CommentComposer/CommentEditorHotkeys.d.ts.map +1 -1
  86. package/dist/components/CommentComposer/CommentEditorHotkeys.js +29 -26
  87. package/dist/components/CommentComposer/index.d.ts +1 -1
  88. package/dist/components/CommentComposer/index.d.ts.map +1 -1
  89. package/dist/components/CommentComposer/index.js +70 -68
  90. package/dist/components/CommentComposer/types.d.ts +6 -0
  91. package/dist/components/CommentComposer/types.d.ts.map +1 -1
  92. package/dist/components/CommunitiesDialog/styles.module.css.js +1 -1
  93. package/dist/components/Copyright/Copyright.module.css.js +1 -1
  94. package/dist/components/CustomKBD/CustomKBD.module.css.js +1 -1
  95. package/dist/components/CustomKBD/index.js +21 -22
  96. package/dist/components/EmojiPicker/EmojiPicker.d.ts +1 -0
  97. package/dist/components/EmojiPicker/EmojiPicker.d.ts.map +1 -1
  98. package/dist/components/EmojiPicker/EmojiPicker.js +129 -121
  99. package/dist/components/EmojiPicker/EmojiPicker.module.css.js +8 -8
  100. package/dist/components/EntityTitle/EntityTitle.d.ts +3 -4
  101. package/dist/components/EntityTitle/EntityTitle.d.ts.map +1 -1
  102. package/dist/components/EntityTitle/EntityTitle.js +81 -80
  103. package/dist/components/EntityTitle/EntityTitle.module.css.js +1 -1
  104. package/dist/components/ErrorPage/components/Error404.d.ts.map +1 -1
  105. package/dist/components/FeatureProgress/FeatureProgress.module.css.js +49 -49
  106. package/dist/components/FilePicker/FilePicker.module.css.js +7 -7
  107. package/dist/components/FormViewer/FormViewer.module.css.js +20 -20
  108. package/dist/components/FormViewer/components/fields/DragOptions/DragOptions.module.css.js +1 -1
  109. package/dist/components/FormViewer/components/fields/DropdownField/DropdownField.module.css.js +1 -1
  110. package/dist/components/FormViewer/components/fields/EditableContent/EditableContent.module.css.js +1 -1
  111. package/dist/components/FormViewer/components/fields/SelectableCard/SelectableCard.module.css.js +8 -8
  112. package/dist/components/FormViewer/components/fields/UploadField/UploadFile/UploadFile.module.css.js +4 -4
  113. package/dist/components/FormViewer/helpers/conditions.d.ts.map +1 -1
  114. package/dist/components/FormViewer/helpers/conditions.js +33 -17
  115. package/dist/components/FormViewer/store/formStore.d.ts.map +1 -1
  116. package/dist/components/ImageCropper/ImageCropper.module.css.js +38 -38
  117. package/dist/components/IntegrationFlowAnimation/IntegrationFlowAnimation.module.css.js +11 -11
  118. package/dist/components/LanguagePicker/LanguagePicker.module.css.js +1 -1
  119. package/dist/components/Loaders/styles.module.css.js +6 -6
  120. package/dist/components/MediaLibrary/MediaLibrary.module.css.js +2 -2
  121. package/dist/components/MusicPlayerBar/MusicPlayerBar.module.css.js +23 -23
  122. package/dist/components/NavMenu/NavMenu.module.css.js +12 -12
  123. package/dist/components/NavbarResizer/NavbarResizer.module.css.js +2 -2
  124. package/dist/components/NotPublicPanel/NotPublicPanel.module.css.js +11 -11
  125. package/dist/components/Notification/InfiniteScroll.d.ts +12 -0
  126. package/dist/components/Notification/InfiniteScroll.d.ts.map +1 -0
  127. package/dist/components/Notification/InfiniteScroll.js +42 -0
  128. package/dist/components/Notification/Notification.d.ts +4 -1
  129. package/dist/components/Notification/Notification.d.ts.map +1 -1
  130. package/dist/components/Notification/Notification.module.css.js +28 -4
  131. package/dist/components/Notification/atoms/ActionBadge.d.ts +11 -0
  132. package/dist/components/Notification/atoms/ActionBadge.d.ts.map +1 -0
  133. package/dist/components/Notification/atoms/ActionBadge.js +53 -0
  134. package/dist/components/Notification/atoms/ArchiveIcon.d.ts +7 -0
  135. package/dist/components/Notification/atoms/ArchiveIcon.d.ts.map +1 -0
  136. package/dist/components/Notification/atoms/ArchiveIcon.js +40 -0
  137. package/dist/components/Notification/atoms/InboxIcon.d.ts +7 -0
  138. package/dist/components/Notification/atoms/InboxIcon.d.ts.map +1 -0
  139. package/dist/components/Notification/atoms/InboxIcon.js +33 -0
  140. package/dist/components/Notification/atoms/MarkReadIcon.d.ts +7 -0
  141. package/dist/components/Notification/atoms/MarkReadIcon.d.ts.map +1 -0
  142. package/dist/components/Notification/atoms/MarkReadIcon.js +33 -0
  143. package/dist/components/Notification/atoms/ResourceIcon.d.ts +7 -0
  144. package/dist/components/Notification/atoms/ResourceIcon.d.ts.map +1 -0
  145. package/dist/components/Notification/atoms/TabBadge.d.ts +7 -0
  146. package/dist/components/Notification/atoms/TabBadge.d.ts.map +1 -0
  147. package/dist/components/Notification/atoms/TabBadge.js +32 -0
  148. package/dist/components/Notification/atoms/UnreadDot.d.ts +6 -0
  149. package/dist/components/Notification/atoms/UnreadDot.d.ts.map +1 -0
  150. package/dist/components/Notification/atoms/UnreadDot.js +23 -0
  151. package/dist/components/Notification/atoms/index.d.ts +5 -0
  152. package/dist/components/Notification/atoms/index.d.ts.map +1 -0
  153. package/dist/components/Notification/hooks/index.d.ts +8 -0
  154. package/dist/components/Notification/hooks/index.d.ts.map +1 -0
  155. package/dist/components/Notification/hooks/useInboxActions.d.ts +12 -0
  156. package/dist/components/Notification/hooks/useInboxActions.d.ts.map +1 -0
  157. package/dist/components/Notification/hooks/useInboxActions.js +58 -0
  158. package/dist/components/Notification/hooks/useInboxLoader.d.ts +8 -0
  159. package/dist/components/Notification/hooks/useInboxLoader.d.ts.map +1 -0
  160. package/dist/components/Notification/hooks/useInboxLoader.js +49 -0
  161. package/dist/components/Notification/hooks/useNotificationItem.d.ts +26 -0
  162. package/dist/components/Notification/hooks/useNotificationItem.d.ts.map +1 -0
  163. package/dist/components/Notification/hooks/useNotificationItem.js +51 -0
  164. package/dist/components/Notification/hooks/useNotificationStore.d.ts +49 -0
  165. package/dist/components/Notification/hooks/useNotificationStore.d.ts.map +1 -0
  166. package/dist/components/Notification/hooks/useNotificationStore.js +139 -0
  167. package/dist/components/Notification/hooks/useNotificationStream.d.ts +2 -0
  168. package/dist/components/Notification/hooks/useNotificationStream.d.ts.map +1 -0
  169. package/dist/components/Notification/hooks/useNotificationStream.js +86 -0
  170. package/dist/components/Notification/hooks/useNotificationTime.d.ts +2 -0
  171. package/dist/components/Notification/hooks/useNotificationTime.d.ts.map +1 -0
  172. package/dist/components/Notification/hooks/useNotificationTime.js +23 -0
  173. package/dist/components/Notification/hooks/useNotificationsApi.d.ts +25 -0
  174. package/dist/components/Notification/hooks/useNotificationsApi.d.ts.map +1 -0
  175. package/dist/components/Notification/hooks/useNotificationsApi.js +64 -0
  176. package/dist/components/Notification/lib/api.d.ts +4 -0
  177. package/dist/components/Notification/lib/api.d.ts.map +1 -0
  178. package/dist/components/Notification/lib/api.js +19 -0
  179. package/dist/components/Notification/lib/index.d.ts +5 -0
  180. package/dist/components/Notification/lib/index.d.ts.map +1 -0
  181. package/dist/components/Notification/lib/notificationText.d.ts +10 -0
  182. package/dist/components/Notification/lib/notificationText.d.ts.map +1 -0
  183. package/dist/components/Notification/lib/notificationText.js +131 -0
  184. package/dist/components/Notification/lib/stripHtml.d.ts +2 -0
  185. package/dist/components/Notification/lib/stripHtml.d.ts.map +1 -0
  186. package/dist/components/Notification/lib/stripHtml.js +6 -0
  187. package/dist/components/Notification/lib/types.d.ts +45 -0
  188. package/dist/components/Notification/lib/types.d.ts.map +1 -0
  189. package/dist/components/Notification/lib/types.js +9 -0
  190. package/dist/components/Notification/molecules/InboxEmpty.d.ts +8 -0
  191. package/dist/components/Notification/molecules/InboxEmpty.d.ts.map +1 -0
  192. package/dist/components/Notification/molecules/InboxEmpty.js +21 -0
  193. package/dist/components/Notification/molecules/InboxHeader.d.ts +17 -0
  194. package/dist/components/Notification/molecules/InboxHeader.d.ts.map +1 -0
  195. package/dist/components/Notification/molecules/InboxHeader.js +73 -0
  196. package/dist/components/Notification/molecules/InboxTabs.d.ts +15 -0
  197. package/dist/components/Notification/molecules/InboxTabs.d.ts.map +1 -0
  198. package/dist/components/Notification/molecules/InboxTabs.js +60 -0
  199. package/dist/components/Notification/molecules/NotificationActions.d.ts +9 -0
  200. package/dist/components/Notification/molecules/NotificationActions.d.ts.map +1 -0
  201. package/dist/components/Notification/molecules/NotificationActions.js +64 -0
  202. package/dist/components/Notification/molecules/NotificationAvatar.d.ts +17 -0
  203. package/dist/components/Notification/molecules/NotificationAvatar.d.ts.map +1 -0
  204. package/dist/components/Notification/molecules/NotificationAvatar.js +38 -0
  205. package/dist/components/Notification/molecules/NotificationContent.d.ts +22 -0
  206. package/dist/components/Notification/molecules/NotificationContent.d.ts.map +1 -0
  207. package/dist/components/Notification/molecules/NotificationContent.js +183 -0
  208. package/dist/components/Notification/molecules/index.d.ts +7 -0
  209. package/dist/components/Notification/molecules/index.d.ts.map +1 -0
  210. package/dist/components/Notification/organisms/InboxItem.d.ts +14 -0
  211. package/dist/components/Notification/organisms/InboxItem.d.ts.map +1 -0
  212. package/dist/components/Notification/organisms/InboxItem.js +100 -0
  213. package/dist/components/Notification/organisms/InboxPanel.d.ts +4 -0
  214. package/dist/components/Notification/organisms/InboxPanel.d.ts.map +1 -0
  215. package/dist/components/Notification/organisms/InboxPanel.js +99 -0
  216. package/dist/components/Notification/organisms/index.d.ts +3 -0
  217. package/dist/components/Notification/organisms/index.d.ts.map +1 -0
  218. package/dist/components/PillTabs/PillTabs.module.css.js +1 -1
  219. package/dist/components/SearchFilters/SearchFilters.module.css.js +1 -1
  220. package/dist/components/SettingsSection/styles.module.css.js +1 -1
  221. package/dist/components/StorageUsageProgress/StorageUsageProgress.module.css.js +1 -1
  222. package/dist/components/TreeIndent/TreeIndent.module.css.js +4 -4
  223. package/dist/components/modals/RemoveConfirmModal.d.ts.map +1 -1
  224. package/dist/components/modals/RemoveConfirmModal.js +27 -26
  225. package/dist/components/table/FrontTable.d.ts.map +1 -1
  226. package/dist/components/table/hooks/useColumnsResizing.d.ts.map +1 -1
  227. package/dist/config/envConfig.d.ts +2 -0
  228. package/dist/config/envConfig.d.ts.map +1 -1
  229. package/dist/config/envConfig.js +29 -28
  230. package/dist/helpers/getFileIcons.js +5 -5
  231. package/dist/helpers/getFileType.d.ts.map +1 -1
  232. package/dist/helpers/getFileType.js +11 -2
  233. package/dist/helpers/platform.d.ts +1 -1
  234. package/dist/helpers/platform.d.ts.map +1 -1
  235. package/dist/helpers/platform.js +1 -0
  236. package/dist/helpers/showFeatureFeedback.module.css.js +4 -4
  237. package/dist/helpers/showNotifications.module.css.js +1 -1
  238. package/dist/index.css +1 -1
  239. package/dist/index.d.ts +0 -2
  240. package/dist/index.d.ts.map +1 -1
  241. package/dist/index.js +560 -571
  242. package/dist/lang/locales/ui_en.json.js +1 -1
  243. package/dist/lang/locales/ui_es.json.js +1 -1
  244. package/dist/lang/locales/ui_ru.json.js +1 -1
  245. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/Audio.context.js +15 -0
  246. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/Audio.js +228 -0
  247. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/Audio.module.css.js +4 -0
  248. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioControls.js +19 -0
  249. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioMuteButton.js +30 -0
  250. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioPlayButton.js +40 -0
  251. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioSkipButton.js +28 -0
  252. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioSpectrum.js +137 -0
  253. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioSpeedControl.js +31 -0
  254. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioTimeDisplay.js +44 -0
  255. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioTimeline.js +71 -0
  256. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioVolumeSlider.js +43 -0
  257. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/components/AudioWaveform.js +166 -0
  258. package/dist/node_modules/@gfazioli/mantine-audio/dist/esm/use-audio.js +201 -0
  259. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/Video.context.js +15 -0
  260. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/Video.js +272 -0
  261. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/Video.module.css.js +4 -0
  262. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoCaptionsButton.js +55 -0
  263. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoControls.js +30 -0
  264. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoFullscreenButton.js +31 -0
  265. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoMuteButton.js +29 -0
  266. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoPiPButton.js +29 -0
  267. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoPlayButton.js +28 -0
  268. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoSkipButton.js +27 -0
  269. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoTimeDisplay.js +44 -0
  270. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/components/VideoTimeline.js +70 -0
  271. package/dist/node_modules/@gfazioli/mantine-video/dist/esm/use-video.js +170 -0
  272. package/docs/README.md +499 -499
  273. package/package.json +80 -79
  274. package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.d.ts +0 -15
  275. package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.d.ts.map +0 -1
  276. package/dist/components/AttachmentsGalleryModal/components/AttachmentVideoPlayer.js +0 -36
  277. package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.d.ts +0 -14
  278. package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.d.ts.map +0 -1
  279. package/dist/components/AttachmentsGalleryModal/components/LegacyAttachmentVideoPlayer.js +0 -31
  280. package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.d.ts +0 -18
  281. package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.d.ts.map +0 -1
  282. package/dist/components/AttachmentsGalleryModal/components/StatusVideoPlayer.js +0 -35
  283. package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.d.ts +0 -33
  284. package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.d.ts.map +0 -1
  285. package/dist/components/AttachmentsGalleryModal/components/useAttachmentVideoStatus.js +0 -70
  286. package/dist/components/Notification/Notification.js +0 -119
  287. package/dist/components/Notification/NotificationCard.d.ts +0 -10
  288. package/dist/components/Notification/NotificationCard.d.ts.map +0 -1
  289. package/dist/components/Notification/NotificationCard.js +0 -93
  290. package/dist/components/VideoPlayer/VideoPlayer.d.ts +0 -24
  291. package/dist/components/VideoPlayer/VideoPlayer.d.ts.map +0 -1
  292. package/dist/components/VideoPlayer/VideoPlayer.js +0 -727
  293. package/dist/components/VideoPlayer/components/MobileDrawer/index.d.ts +0 -8
  294. package/dist/components/VideoPlayer/components/MobileDrawer/index.d.ts.map +0 -1
  295. package/dist/components/VideoPlayer/components/MobileDrawer/index.js +0 -67
  296. package/dist/components/VideoPlayer/components/SelectListOptionButton.d.ts +0 -7
  297. package/dist/components/VideoPlayer/components/SelectListOptionButton.d.ts.map +0 -1
  298. package/dist/components/VideoPlayer/components/SelectListOptionButton.js +0 -44
  299. package/dist/components/VideoPlayer/components/StoryboardPreview.d.ts +0 -9
  300. package/dist/components/VideoPlayer/components/StoryboardPreview.d.ts.map +0 -1
  301. package/dist/components/VideoPlayer/components/StoryboardPreview.js +0 -38
  302. package/dist/components/VideoPlayer/components/VideoCustomControls.d.ts +0 -33
  303. package/dist/components/VideoPlayer/components/VideoCustomControls.d.ts.map +0 -1
  304. package/dist/components/VideoPlayer/components/VideoCustomControls.js +0 -601
  305. package/dist/components/VideoPlayer/components/VideoIcons.d.ts +0 -25
  306. package/dist/components/VideoPlayer/components/VideoIcons.d.ts.map +0 -1
  307. package/dist/components/VideoPlayer/components/VideoIcons.js +0 -145
  308. package/dist/components/VideoPlayer/components/VideoMenu.d.ts +0 -27
  309. package/dist/components/VideoPlayer/components/VideoMenu.d.ts.map +0 -1
  310. package/dist/components/VideoPlayer/components/VideoMenu.js +0 -77
  311. package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.d.ts +0 -17
  312. package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.d.ts.map +0 -1
  313. package/dist/components/VideoPlayer/components/VideoMobileSettingsDrawer.js +0 -289
  314. package/dist/components/VideoPlayer/components/VideoQualityMenu/index.d.ts +0 -10
  315. package/dist/components/VideoPlayer/components/VideoQualityMenu/index.d.ts.map +0 -1
  316. package/dist/components/VideoPlayer/components/VideoQualityMenu/index.js +0 -55
  317. package/dist/components/VideoPlayer/components/VideoSelect.d.ts +0 -10
  318. package/dist/components/VideoPlayer/components/VideoSelect.d.ts.map +0 -1
  319. package/dist/components/VideoPlayer/components/VideoSelect.js +0 -168
  320. package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.d.ts +0 -12
  321. package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.d.ts.map +0 -1
  322. package/dist/components/VideoPlayer/components/VideoSettingsMenu/index.js +0 -48
  323. package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.d.ts +0 -25
  324. package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.d.ts.map +0 -1
  325. package/dist/components/VideoPlayer/components/VideoSettingsModal/ChaptersSection.js +0 -384
  326. package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.d.ts +0 -21
  327. package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.d.ts.map +0 -1
  328. package/dist/components/VideoPlayer/components/VideoSettingsModal/CoverSection.js +0 -264
  329. package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.d.ts +0 -10
  330. package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.d.ts.map +0 -1
  331. package/dist/components/VideoPlayer/components/VideoSettingsModal/FooterActions.js +0 -39
  332. package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.d.ts +0 -14
  333. package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.d.ts.map +0 -1
  334. package/dist/components/VideoPlayer/components/VideoSettingsModal/ManualSubtitlesPanel.js +0 -360
  335. package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitleTrackRow.d.ts +0 -16
  336. package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitleTrackRow.d.ts.map +0 -1
  337. package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitlesSection.d.ts +0 -14
  338. package/dist/components/VideoPlayer/components/VideoSettingsModal/SubtitlesSection.d.ts.map +0 -1
  339. package/dist/components/VideoPlayer/components/VideoSettingsModal/context.d.ts +0 -4
  340. package/dist/components/VideoPlayer/components/VideoSettingsModal/context.d.ts.map +0 -1
  341. package/dist/components/VideoPlayer/components/VideoSettingsModal/context.js +0 -14
  342. package/dist/components/VideoPlayer/components/VideoSettingsModal/index.d.ts +0 -22
  343. package/dist/components/VideoPlayer/components/VideoSettingsModal/index.d.ts.map +0 -1
  344. package/dist/components/VideoPlayer/components/VideoSettingsModal/index.js +0 -211
  345. package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.d.ts +0 -11
  346. package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.d.ts.map +0 -1
  347. package/dist/components/VideoPlayer/components/VideoSpeedMenu/index.js +0 -41
  348. package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.d.ts +0 -10
  349. package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.d.ts.map +0 -1
  350. package/dist/components/VideoPlayer/components/VideoSubtitlesMenu/index.js +0 -69
  351. package/dist/components/VideoPlayer/hooks/useStoryboard.d.ts +0 -21
  352. package/dist/components/VideoPlayer/hooks/useStoryboard.d.ts.map +0 -1
  353. package/dist/components/VideoPlayer/hooks/useStoryboard.js +0 -91
  354. package/dist/components/VideoPlayer/index.d.ts +0 -11
  355. package/dist/components/VideoPlayer/index.d.ts.map +0 -1
  356. package/dist/components/VideoPlayer/types.d.ts +0 -101
  357. package/dist/components/VideoPlayer/types.d.ts.map +0 -1
  358. package/dist/components/VideoPlayer/utils/chapters.d.ts +0 -8
  359. package/dist/components/VideoPlayer/utils/chapters.d.ts.map +0 -1
  360. package/dist/components/VideoPlayer/utils/chapters.js +0 -38
  361. package/dist/components/VideoPlayer/utils/storyboard.d.ts +0 -5
  362. package/dist/components/VideoPlayer/utils/storyboard.d.ts.map +0 -1
  363. package/dist/components/VideoPlayer/utils/storyboard.js +0 -47
  364. package/dist/components/VideoPlayer/utils/subtitles.d.ts +0 -18
  365. package/dist/components/VideoPlayer/utils/subtitles.d.ts.map +0 -1
  366. package/dist/components/VideoPlayer/utils/subtitles.js +0 -23
  367. package/dist/components/VideoPlayer/utils/touch.d.ts +0 -3
  368. package/dist/components/VideoPlayer/utils/touch.d.ts.map +0 -1
  369. package/dist/components/VideoPlayer/utils/touch.js +0 -5
  370. package/dist/components/VideoPlayer/utils/videoPlayerUtils.d.ts +0 -10
  371. package/dist/components/VideoPlayer/utils/videoPlayerUtils.d.ts.map +0 -1
  372. package/dist/components/VideoPlayer/utils/videoPlayerUtils.js +0 -22
  373. package/dist/components/VideoPlayer/utils/videoSettings.d.ts +0 -69
  374. package/dist/components/VideoPlayer/utils/videoSettings.d.ts.map +0 -1
  375. package/dist/components/VideoPlayer/utils/videoSettings.js +0 -90
  376. package/dist/videoSettings/createVideoSettingsDataSource.d.ts +0 -19
  377. package/dist/videoSettings/createVideoSettingsDataSource.d.ts.map +0 -1
  378. package/dist/videoSettings/createVideoSettingsDataSource.js +0 -127
@@ -0,0 +1,272 @@
1
+ import { factory as ge, useProps as pe, useStyles as ye, Box as ke, createVarsResolver as be, getThemeColor as ve, getRadius as he } from "@mantine/core";
2
+ import u, { useRef as V, useEffect as I, useCallback as k, useState as Te } from "react";
3
+ import { VideoCaptionsButton as Ce } from "./components/VideoCaptionsButton.js";
4
+ import { VideoControls as N } from "./components/VideoControls.js";
5
+ import { VideoFullscreenButton as Ve } from "./components/VideoFullscreenButton.js";
6
+ import { VideoMuteButton as x } from "./components/VideoMuteButton.js";
7
+ import { VideoPiPButton as Pe } from "./components/VideoPiPButton.js";
8
+ import { VideoPlayButton as Re } from "./components/VideoPlayButton.js";
9
+ import { VideoSkipButton as Be } from "./components/VideoSkipButton.js";
10
+ import { VideoTimeDisplay as De } from "./components/VideoTimeDisplay.js";
11
+ import { VideoTimeline as we } from "./components/VideoTimeline.js";
12
+ import { useVideo as Ee } from "./use-video.js";
13
+ import { VideoProvider as Ae } from "./Video.context.js";
14
+ import L from "./Video.module.css.js";
15
+ const Me = {
16
+ color: "blue",
17
+ radius: "md",
18
+ size: "md",
19
+ variant: "overlay",
20
+ preload: "metadata",
21
+ playsInline: !0,
22
+ fit: "contain",
23
+ backgroundMuteButton: !0
24
+ }, Fe = be(
25
+ (l, { color: f, radius: n, fit: d, asBackground: c }) => {
26
+ const a = ve(f, l);
27
+ return {
28
+ root: {
29
+ "--video-color": a,
30
+ "--video-radius": n === void 0 ? void 0 : he(n),
31
+ "--video-bg": "black",
32
+ "--video-controls-bg": "linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.35) 60%, transparent 100%)",
33
+ "--video-controls-height": "44px",
34
+ "--video-controls-text-color": "white",
35
+ "--video-timeline-color": a,
36
+ "--video-timeline-thumb-color": a,
37
+ "--video-object-fit": c ? "cover" : d ?? "contain"
38
+ }
39
+ };
40
+ }
41
+ ), t = ge((l) => {
42
+ const f = pe("Video", Me, l), {
43
+ ref: n,
44
+ src: d,
45
+ sources: c,
46
+ fallbackSrc: a,
47
+ poster: _,
48
+ controls: Se,
49
+ autoPlay: P,
50
+ muted: R,
51
+ loop: B,
52
+ playsInline: H,
53
+ preload: j,
54
+ playing: K,
55
+ onPlayChange: z,
56
+ currentTime: U,
57
+ onCurrentTimeChange: q,
58
+ volume: J,
59
+ onVolumeChange: O,
60
+ playbackRate: X,
61
+ onPlaybackRateChange: G,
62
+ color: Ie,
63
+ radius: Ne,
64
+ aspectRatio: g,
65
+ size: Q,
66
+ variant: b,
67
+ onEnded: W,
68
+ onError: Y,
69
+ onEnterPictureInPicture: Z,
70
+ onLeavePictureInPicture: $,
71
+ onFullscreenChange: ee,
72
+ fit: xe,
73
+ // Pulled out so they don't leak onto the root DOM element via `...others`.
74
+ // The effective values are derived from `_props.*` below (background mode
75
+ // flips their defaults), so the destructured copies are intentionally unused.
76
+ shortcuts: Le,
77
+ clickToToggle: _e,
78
+ doubleClickToFullscreen: He,
79
+ autoHideControls: je,
80
+ asBackground: i,
81
+ backgroundMuteButton: oe,
82
+ children: te,
83
+ classNames: re,
84
+ style: D,
85
+ styles: le,
86
+ unstyled: ne,
87
+ vars: ae,
88
+ className: ie,
89
+ mod: ce,
90
+ ...se
91
+ } = f, ue = l.controls ?? !i, v = l.shortcuts ?? !i, w = l.clickToToggle ?? !i, E = l.doubleClickToFullscreen ?? !i, s = l.autoHideControls ?? (i ? 0 : 3e3), p = ye({
92
+ name: "Video",
93
+ props: f,
94
+ classes: L,
95
+ className: ie,
96
+ style: D,
97
+ classNames: re,
98
+ styles: le,
99
+ unstyled: ne,
100
+ vars: ae,
101
+ varsResolver: Fe
102
+ }), o = Ee({
103
+ src: d,
104
+ autoPlay: P,
105
+ muted: R,
106
+ loop: B,
107
+ playing: K,
108
+ onPlayChange: z,
109
+ currentTime: U,
110
+ onCurrentTimeChange: q,
111
+ volume: J,
112
+ onVolumeChange: O,
113
+ playbackRate: X,
114
+ onPlaybackRateChange: G,
115
+ onEnded: W,
116
+ onError: Y,
117
+ onEnterPictureInPicture: Z,
118
+ onLeavePictureInPicture: $,
119
+ onFullscreenChange: ee
120
+ }), A = Array.isArray(c) && c.length > 0, h = V(!1);
121
+ I(() => {
122
+ h.current = !1;
123
+ }, [d, c, a]);
124
+ const de = k(() => {
125
+ if (!a || h.current)
126
+ return;
127
+ const e = o.videoRef.current;
128
+ e && (h.current = !0, e.removeAttribute("src"), e.querySelectorAll("source").forEach((r) => r.remove()), e.src = a, e.load());
129
+ }, [a, o.videoRef]), [M, T] = Te(!0), m = V(null), y = k(() => {
130
+ T(!0), m.current && clearTimeout(m.current), s && s > 0 && o.playing && (m.current = setTimeout(() => T(!1), s));
131
+ }, [s, o.playing]);
132
+ I(() => (y(), () => {
133
+ m.current && clearTimeout(m.current);
134
+ }), [y, o.playing]);
135
+ const C = V(0), me = k(
136
+ (e) => {
137
+ if (e.target !== e.currentTarget && e.target.tagName !== "VIDEO")
138
+ return;
139
+ const r = Date.now(), S = r - C.current < 300;
140
+ if (C.current = r, S && E) {
141
+ o.toggleFullscreen();
142
+ return;
143
+ }
144
+ w && !S && setTimeout(() => {
145
+ Date.now() - C.current >= 250 && o.toggle();
146
+ }, 260);
147
+ },
148
+ [w, E, o]
149
+ ), fe = k(
150
+ (e) => {
151
+ if (!v) return;
152
+ const r = e.target;
153
+ if (!(r.tagName === "INPUT" || r.tagName === "TEXTAREA"))
154
+ switch (e.key) {
155
+ case " ":
156
+ case "k":
157
+ case "K":
158
+ e.preventDefault(), o.toggle();
159
+ break;
160
+ case "ArrowLeft":
161
+ case "j":
162
+ case "J":
163
+ e.preventDefault(), o.seekBy(e.key === "ArrowLeft" ? -5 : -10);
164
+ break;
165
+ case "ArrowRight":
166
+ case "l":
167
+ case "L":
168
+ e.preventDefault(), o.seekBy(e.key === "ArrowRight" ? 5 : 10);
169
+ break;
170
+ case "ArrowUp":
171
+ e.preventDefault(), o.setVolume(Math.min(1, o.volume + 0.05));
172
+ break;
173
+ case "ArrowDown":
174
+ e.preventDefault(), o.setVolume(Math.max(0, o.volume - 0.05));
175
+ break;
176
+ case "m":
177
+ case "M":
178
+ e.preventDefault(), o.toggleMute();
179
+ break;
180
+ case "f":
181
+ case "F":
182
+ e.preventDefault(), o.toggleFullscreen();
183
+ break;
184
+ case "p":
185
+ case "P":
186
+ e.preventDefault(), o.togglePiP();
187
+ break;
188
+ }
189
+ },
190
+ [v, o]
191
+ ), F = b === "minimal" || b === "bordered";
192
+ return /* @__PURE__ */ u.createElement(
193
+ Ae,
194
+ {
195
+ value: {
196
+ ...o,
197
+ getStyles: p,
198
+ controlsVisible: M,
199
+ showControls: y
200
+ }
201
+ },
202
+ /* @__PURE__ */ u.createElement(
203
+ ke,
204
+ {
205
+ ...p("root", {
206
+ style: [
207
+ g && !F ? { aspectRatio: String(g) } : void 0,
208
+ D
209
+ ]
210
+ }),
211
+ ...se,
212
+ ref: (e) => {
213
+ o.containerRef.current = e, typeof n == "function" ? n(e) : n && typeof n == "object" && (n.current = e);
214
+ },
215
+ mod: [
216
+ {
217
+ variant: b,
218
+ size: Q,
219
+ playing: o.playing,
220
+ paused: o.paused && !o.ended,
221
+ ended: o.ended,
222
+ fullscreen: o.fullscreen,
223
+ "controls-visible": M,
224
+ "as-background": i
225
+ },
226
+ ce
227
+ ],
228
+ tabIndex: v ? 0 : void 0,
229
+ onMouseMove: y,
230
+ onMouseLeave: () => {
231
+ s && s > 0 && o.playing && T(!1);
232
+ },
233
+ onClick: me,
234
+ onKeyDown: fe
235
+ },
236
+ /* @__PURE__ */ u.createElement(
237
+ "video",
238
+ {
239
+ ...p("video", {
240
+ style: g && F ? { aspectRatio: String(g) } : void 0
241
+ }),
242
+ ref: o.videoRef,
243
+ src: A ? void 0 : d,
244
+ poster: _,
245
+ autoPlay: P,
246
+ muted: R,
247
+ loop: B,
248
+ playsInline: H,
249
+ preload: j,
250
+ onError: de
251
+ },
252
+ A ? c.map((e, r) => /* @__PURE__ */ u.createElement("source", { key: r, src: e.src, type: e.type, media: e.media })) : null
253
+ ),
254
+ i && oe && /* @__PURE__ */ u.createElement(x, { ...p("backgroundMuteButton") }),
255
+ te ?? (ue && /* @__PURE__ */ u.createElement(N, null))
256
+ )
257
+ );
258
+ });
259
+ t.classes = L;
260
+ t.displayName = "Video";
261
+ t.Controls = N;
262
+ t.PlayButton = Re;
263
+ t.Timeline = we;
264
+ t.TimeDisplay = De;
265
+ t.MuteButton = x;
266
+ t.FullscreenButton = Ve;
267
+ t.PiPButton = Pe;
268
+ t.CaptionsButton = Ce;
269
+ t.SkipButton = Be;
270
+ export {
271
+ t as Video
272
+ };
@@ -0,0 +1,4 @@
1
+ var e = { root: "me_93a1ff14", video: "me_e0d35c89", backgroundMuteButton: "me_c06a98ab", controls: "me_cdf35be8", controlBar: "me_1e8b5628", playButton: "me_39f8f838", muteButton: "me_273e3f5d", fullscreenButton: "me_3d7259ff", pipButton: "me_1d5188b7", captionsButton: "me_c8163091", skipButton: "me_e5822e43", iconButton: "me_bdfae1bd", timeline: "me_73f6e973", timelineBuffered: "me_aaddbb72", timeDisplay: "me_a6bc92c3" };
2
+ export {
3
+ e as default
4
+ };
@@ -0,0 +1,55 @@
1
+ import { Tooltip as g, ActionIcon as h } from "@mantine/core";
2
+ import { IconBadgeCcFilled as b, IconBadgeCc as y } from "@tabler/icons-react";
3
+ import s, { forwardRef as L, useState as d, useEffect as T } from "react";
4
+ import { useVideoContext as w } from "../Video.context.js";
5
+ const x = L(
6
+ ({ enableLabel: l = "Enable captions", disableLabel: f = "Disable captions", ...m }, u) => {
7
+ const o = w(), [r, v] = d(!1), [p, k] = d(!1);
8
+ if (T(() => {
9
+ const n = o.videoRef.current;
10
+ if (!n) return;
11
+ const t = () => {
12
+ const c = Array.from(n.textTracks).filter(
13
+ (a) => a.kind === "captions" || a.kind === "subtitles"
14
+ );
15
+ k(c.length > 0), v(c.some((a) => a.mode === "showing"));
16
+ };
17
+ t();
18
+ const e = n.textTracks;
19
+ if (typeof e.addEventListener == "function")
20
+ return e.addEventListener("change", t), e.addEventListener("addtrack", t), e.addEventListener("removetrack", t), () => {
21
+ e.removeEventListener?.("change", t), e.removeEventListener?.("addtrack", t), e.removeEventListener?.("removetrack", t);
22
+ };
23
+ }, [o.videoRef]), !p) return null;
24
+ const E = () => {
25
+ const n = o.videoRef.current;
26
+ if (!n) return;
27
+ const t = Array.from(n.textTracks).filter(
28
+ (e) => e.kind === "captions" || e.kind === "subtitles"
29
+ );
30
+ t.length !== 0 && (r ? t.forEach((e) => {
31
+ e.mode = "disabled";
32
+ }) : t[0].mode = "showing");
33
+ }, i = r ? f : l;
34
+ return /* @__PURE__ */ s.createElement(g, { label: i, withArrow: !0, openDelay: 400 }, /* @__PURE__ */ s.createElement(
35
+ h,
36
+ {
37
+ ref: u,
38
+ variant: "transparent",
39
+ color: "white",
40
+ size: "lg",
41
+ "aria-label": i,
42
+ "aria-pressed": r,
43
+ onClick: E,
44
+ "data-state": r ? "on" : "off",
45
+ ...o.getStyles("captionsButton"),
46
+ ...m
47
+ },
48
+ r ? /* @__PURE__ */ s.createElement(b, { size: 20 }) : /* @__PURE__ */ s.createElement(y, { size: 20 })
49
+ ));
50
+ }
51
+ );
52
+ x.displayName = "VideoCaptionsButton";
53
+ export {
54
+ x as VideoCaptionsButton
55
+ };
@@ -0,0 +1,30 @@
1
+ import { Box as o } from "@mantine/core";
2
+ import e, { forwardRef as i } from "react";
3
+ import { useVideoContext as a } from "../Video.context.js";
4
+ import { VideoCaptionsButton as c } from "./VideoCaptionsButton.js";
5
+ import { VideoFullscreenButton as u } from "./VideoFullscreenButton.js";
6
+ import { VideoMuteButton as p } from "./VideoMuteButton.js";
7
+ import { VideoPiPButton as s } from "./VideoPiPButton.js";
8
+ import { VideoPlayButton as d } from "./VideoPlayButton.js";
9
+ import { VideoTimeDisplay as f } from "./VideoTimeDisplay.js";
10
+ import { VideoTimeline as V } from "./VideoTimeline.js";
11
+ const E = i(
12
+ ({ children: r, ...l }, n) => {
13
+ const t = a();
14
+ return /* @__PURE__ */ e.createElement(
15
+ o,
16
+ {
17
+ ref: n,
18
+ ...t.getStyles("controls"),
19
+ mod: { visible: t.controlsVisible },
20
+ onClick: (m) => m.stopPropagation(),
21
+ ...l
22
+ },
23
+ /* @__PURE__ */ e.createElement(o, { ...t.getStyles("controlBar") }, r ?? /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement(d, null), /* @__PURE__ */ e.createElement(V, null), /* @__PURE__ */ e.createElement(f, null), /* @__PURE__ */ e.createElement(p, null), /* @__PURE__ */ e.createElement(c, null), /* @__PURE__ */ e.createElement(s, null), /* @__PURE__ */ e.createElement(u, null)))
24
+ );
25
+ }
26
+ );
27
+ E.displayName = "VideoControls";
28
+ export {
29
+ E as VideoControls
30
+ };
@@ -0,0 +1,31 @@
1
+ import { Tooltip as i, ActionIcon as a } from "@mantine/core";
2
+ import { IconMinimize as s, IconMaximize as u } from "@tabler/icons-react";
3
+ import t, { forwardRef as f } from "react";
4
+ import { useVideoContext as m } from "../Video.context.js";
5
+ const p = f(
6
+ ({ enterLabel: r = "Enter fullscreen", exitLabel: n = "Exit fullscreen", ...o }, c) => {
7
+ const e = m();
8
+ if (!e.canFullscreen) return null;
9
+ const l = e.fullscreen ? n : r;
10
+ return /* @__PURE__ */ t.createElement(i, { label: l, withArrow: !0, openDelay: 400 }, /* @__PURE__ */ t.createElement(
11
+ a,
12
+ {
13
+ ref: c,
14
+ variant: "transparent",
15
+ color: "white",
16
+ size: "lg",
17
+ "aria-label": l,
18
+ "aria-pressed": e.fullscreen,
19
+ onClick: e.toggleFullscreen,
20
+ "data-state": e.fullscreen ? "on" : "off",
21
+ ...e.getStyles("fullscreenButton"),
22
+ ...o
23
+ },
24
+ e.fullscreen ? /* @__PURE__ */ t.createElement(s, { size: 20 }) : /* @__PURE__ */ t.createElement(u, { size: 20 })
25
+ ));
26
+ }
27
+ );
28
+ p.displayName = "VideoFullscreenButton";
29
+ export {
30
+ p as VideoFullscreenButton
31
+ };
@@ -0,0 +1,29 @@
1
+ import { Tooltip as i, ActionIcon as c } from "@mantine/core";
2
+ import { IconVolume3 as s, IconVolume2 as d, IconVolume as p } from "@tabler/icons-react";
3
+ import o, { forwardRef as f } from "react";
4
+ import { useVideoContext as V } from "../Video.context.js";
5
+ const I = f(
6
+ ({ muteLabel: r = "Mute", unmuteLabel: u = "Unmute", ...a }, m) => {
7
+ const e = V(), t = e.muted || e.volume === 0, n = t ? u : r, l = t ? s : e.volume < 0.5 ? d : p;
8
+ return /* @__PURE__ */ o.createElement(i, { label: n, withArrow: !0, openDelay: 400 }, /* @__PURE__ */ o.createElement(
9
+ c,
10
+ {
11
+ ref: m,
12
+ variant: "transparent",
13
+ color: "white",
14
+ size: "lg",
15
+ "aria-label": n,
16
+ "aria-pressed": t,
17
+ onClick: e.toggleMute,
18
+ "data-state": t ? "muted" : "unmuted",
19
+ ...e.getStyles("muteButton"),
20
+ ...a
21
+ },
22
+ /* @__PURE__ */ o.createElement(l, { size: 20 })
23
+ ));
24
+ }
25
+ );
26
+ I.displayName = "VideoMuteButton";
27
+ export {
28
+ I as VideoMuteButton
29
+ };
@@ -0,0 +1,29 @@
1
+ import { Tooltip as n, ActionIcon as a } from "@mantine/core";
2
+ import { IconPictureInPicture as c } from "@tabler/icons-react";
3
+ import e, { forwardRef as p } from "react";
4
+ import { useVideoContext as l } from "../Video.context.js";
5
+ const u = p(
6
+ ({ label: o = "Picture-in-Picture", ...r }, i) => {
7
+ const t = l();
8
+ return t.canPiP ? /* @__PURE__ */ e.createElement(n, { label: o, withArrow: !0, openDelay: 400 }, /* @__PURE__ */ e.createElement(
9
+ a,
10
+ {
11
+ ref: i,
12
+ variant: "transparent",
13
+ color: "white",
14
+ size: "lg",
15
+ "aria-label": o,
16
+ "aria-pressed": t.pip,
17
+ onClick: t.togglePiP,
18
+ "data-state": t.pip ? "on" : "off",
19
+ ...t.getStyles("pipButton"),
20
+ ...r
21
+ },
22
+ /* @__PURE__ */ e.createElement(c, { size: 20 })
23
+ )) : null;
24
+ }
25
+ );
26
+ u.displayName = "VideoPiPButton";
27
+ export {
28
+ u as VideoPiPButton
29
+ };
@@ -0,0 +1,28 @@
1
+ import { Tooltip as i, ActionIcon as c } from "@mantine/core";
2
+ import { IconPlayerPauseFilled as p, IconPlayerPlayFilled as s } from "@tabler/icons-react";
3
+ import t, { forwardRef as y } from "react";
4
+ import { useVideoContext as m } from "../Video.context.js";
5
+ const d = y(
6
+ ({ playLabel: l = "Play", pauseLabel: o = "Pause", ...r }, n) => {
7
+ const e = m(), a = e.playing ? o : l;
8
+ return /* @__PURE__ */ t.createElement(i, { label: a, withArrow: !0, openDelay: 400 }, /* @__PURE__ */ t.createElement(
9
+ c,
10
+ {
11
+ ref: n,
12
+ variant: "transparent",
13
+ color: "white",
14
+ size: "lg",
15
+ "aria-label": a,
16
+ onClick: e.toggle,
17
+ "data-state": e.playing ? "playing" : "paused",
18
+ ...e.getStyles("playButton"),
19
+ ...r
20
+ },
21
+ e.playing ? /* @__PURE__ */ t.createElement(p, { size: 20 }) : /* @__PURE__ */ t.createElement(s, { size: 20 })
22
+ ));
23
+ }
24
+ );
25
+ d.displayName = "VideoPlayButton";
26
+ export {
27
+ d as VideoPlayButton
28
+ };
@@ -0,0 +1,27 @@
1
+ import { Tooltip as p, ActionIcon as d } from "@mantine/core";
2
+ import { IconRewindForward10 as s, IconRewindBackward10 as w } from "@tabler/icons-react";
3
+ import e, { forwardRef as f } from "react";
4
+ import { useVideoContext as k } from "../Video.context.js";
5
+ const u = f(
6
+ ({ seconds: t = 10, icon: n, label: i, ...c }, l) => {
7
+ const o = k(), r = t >= 0, a = i ?? `${r ? "Forward" : "Back"} ${Math.abs(t)}s`, m = n ?? (r ? /* @__PURE__ */ e.createElement(s, { size: 20 }) : /* @__PURE__ */ e.createElement(w, { size: 20 }));
8
+ return /* @__PURE__ */ e.createElement(p, { label: a, withArrow: !0, openDelay: 400 }, /* @__PURE__ */ e.createElement(
9
+ d,
10
+ {
11
+ ref: l,
12
+ variant: "transparent",
13
+ color: "white",
14
+ size: "lg",
15
+ "aria-label": a,
16
+ onClick: () => o.seekBy(t),
17
+ ...o.getStyles("skipButton"),
18
+ ...c
19
+ },
20
+ m
21
+ ));
22
+ }
23
+ );
24
+ u.displayName = "VideoSkipButton";
25
+ export {
26
+ u as VideoSkipButton
27
+ };
@@ -0,0 +1,44 @@
1
+ import { Text as s } from "@mantine/core";
2
+ import c, { forwardRef as f } from "react";
3
+ import { useVideoContext as u } from "../Video.context.js";
4
+ const l = f(
5
+ ({ format: r = "current/duration", ...t }, e) => {
6
+ const o = u(), n = p(r, o.currentTime, o.duration);
7
+ return /* @__PURE__ */ c.createElement(
8
+ s,
9
+ {
10
+ ref: e,
11
+ size: "sm",
12
+ c: "white",
13
+ ff: "monospace",
14
+ ta: "center",
15
+ ...o.getStyles("timeDisplay"),
16
+ ...t
17
+ },
18
+ n
19
+ );
20
+ }
21
+ );
22
+ l.displayName = "VideoTimeDisplay";
23
+ function a(r) {
24
+ if (!Number.isFinite(r) || r < 0) return "0:00";
25
+ const t = Math.floor(r), e = Math.floor(t / 3600), o = Math.floor(t % 3600 / 60), n = t % 60, i = e > 0 ? String(o).padStart(2, "0") : String(o), m = String(n).padStart(2, "0");
26
+ return e > 0 ? `${e}:${i}:${m}` : `${i}:${m}`;
27
+ }
28
+ function p(r, t, e) {
29
+ switch (r) {
30
+ case "current":
31
+ return a(t);
32
+ case "duration":
33
+ return a(e);
34
+ case "remaining":
35
+ return a(Math.max(e - t, 0));
36
+ case "current/-remaining":
37
+ return `${a(t)} / -${a(Math.max(e - t, 0))}`;
38
+ default:
39
+ return `${a(t)} / ${a(e)}`;
40
+ }
41
+ }
42
+ export {
43
+ l as VideoTimeDisplay
44
+ };
@@ -0,0 +1,70 @@
1
+ import { Box as h, Slider as y } from "@mantine/core";
2
+ import b, { forwardRef as v, useState as x, useRef as m, useEffect as R, useCallback as p } from "react";
3
+ import { useVideoContext as E } from "../Video.context.js";
4
+ const $ = v(
5
+ ({ sliderProps: o, liveScrub: t = !0, ...l }, u) => {
6
+ const e = E(), [c, i] = x(null), f = m(!1), d = m(!1), r = m(null), a = m(null), s = Number.isFinite(e.duration) && e.duration > 0 ? e.duration : 0, g = c ?? e.currentTime, S = s > 0 ? e.buffered / s * 100 : 0;
7
+ R(
8
+ () => () => {
9
+ r.current !== null && cancelAnimationFrame(r.current);
10
+ },
11
+ []
12
+ );
13
+ const C = p(
14
+ (n) => {
15
+ f.current || (f.current = !0, d.current = e.playing, t && e.playing && e.pause()), i(n), t && (a.current = n, r.current === null && (r.current = requestAnimationFrame(() => {
16
+ r.current = null, a.current !== null && (e.seek(a.current), a.current = null);
17
+ })));
18
+ },
19
+ [e, t]
20
+ ), k = p(
21
+ (n) => {
22
+ r.current !== null && (cancelAnimationFrame(r.current), r.current = null), a.current = null, e.seek(n), i(null), f.current = !1, d.current && (d.current = !1, e.play());
23
+ },
24
+ [e]
25
+ );
26
+ return /* @__PURE__ */ b.createElement(h, { ref: u, ...e.getStyles("timeline"), ...l }, /* @__PURE__ */ b.createElement(
27
+ h,
28
+ {
29
+ ...e.getStyles("timelineBuffered"),
30
+ style: { width: `${S}%` },
31
+ "aria-hidden": !0
32
+ }
33
+ ), /* @__PURE__ */ b.createElement(
34
+ y,
35
+ {
36
+ value: Math.min(g, s || g),
37
+ onChange: C,
38
+ onChangeEnd: k,
39
+ min: 0,
40
+ max: s || 1e-4,
41
+ step: 0.01,
42
+ label: (n) => w(n),
43
+ showLabelOnHover: !0,
44
+ color: "var(--video-timeline-color)",
45
+ thumbSize: 12,
46
+ size: "xs",
47
+ "aria-label": "Seek",
48
+ styles: {
49
+ root: { flex: 1, width: "100%" },
50
+ track: { backgroundColor: "rgba(255, 255, 255, 0.25)" },
51
+ bar: { backgroundColor: "var(--video-timeline-color)" },
52
+ thumb: {
53
+ backgroundColor: "var(--video-timeline-thumb-color)",
54
+ borderColor: "var(--video-timeline-thumb-color)"
55
+ }
56
+ },
57
+ ...o
58
+ }
59
+ ));
60
+ }
61
+ );
62
+ $.displayName = "VideoTimeline";
63
+ function w(o) {
64
+ if (!Number.isFinite(o) || o < 0) return "0:00";
65
+ const t = Math.floor(o), l = Math.floor(t / 3600), u = Math.floor(t % 3600 / 60), e = t % 60, c = l > 0 ? String(u).padStart(2, "0") : String(u), i = String(e).padStart(2, "0");
66
+ return l > 0 ? `${l}:${c}:${i}` : `${c}:${i}`;
67
+ }
68
+ export {
69
+ $ as VideoTimeline
70
+ };