@layers-app/shared 0.0.28 → 0.0.30

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 (67) hide show
  1. package/dist/KanbanLayout-fxFPIQAt.js +287 -0
  2. package/dist/TimeLine-Cv82PyoW.js +198 -0
  3. package/dist/assets/jsons/emoji-categorized.json.d.ts +3 -0
  4. package/dist/assets/jsons/icons.min.json.d.ts +3 -0
  5. package/dist/components/AppContainer/AppContainer.d.ts +6 -0
  6. package/dist/components/AppContainer/components/DesktopNavbar.d.ts +5 -0
  7. package/dist/components/AppContainer/hooks/useHideHeader.d.ts +1 -1
  8. package/dist/components/AppContainer/hooks/useHideSidebar.d.ts +1 -0
  9. package/dist/components/CommentsPanel/components/CommentsThreadReplyControls.d.ts +3 -2
  10. package/dist/components/CommentsPanel/index.d.ts +2 -1
  11. package/dist/components/CommentsPanel/types.d.ts +1 -0
  12. package/dist/components/EmojiPicker/EmojiPanel.d.ts +1 -1
  13. package/dist/components/EmojiPicker/IconsPanel.d.ts +2 -2
  14. package/dist/components/EmojiPicker/constants.d.ts +2 -0
  15. package/dist/components/EmojiPicker/types.d.ts +13 -0
  16. package/dist/components/{ImagePicker/ImagePicker.d.ts → FilePicker/FilePicker.d.ts} +6 -4
  17. package/dist/components/{ImagePicker/ImagePickerGallery.d.ts → FilePicker/FilePickerGallery.d.ts} +1 -1
  18. package/dist/components/FilePicker/FilePickerGiphy.d.ts +6 -0
  19. package/dist/components/FilePicker/FilePickerLink.d.ts +7 -0
  20. package/dist/components/FilePicker/FilePickerSkeletonLoader.d.ts +1 -0
  21. package/dist/components/FilePicker/FilePickerUnsplash.d.ts +6 -0
  22. package/dist/components/{ImagePicker/ImagePickerUpload.d.ts → FilePicker/FilePickerUpload.d.ts} +3 -3
  23. package/dist/components/FilePicker/index.d.ts +1 -0
  24. package/dist/components/{ImagePicker → FilePicker}/types.d.ts +2 -1
  25. package/dist/components/LanguagePicker/LanguagePicker.d.ts +6 -0
  26. package/dist/components/NoData/NoData.d.ts +3 -0
  27. package/dist/components/OnBoarding/steps/DifferentLayouts/TimeLine.d.ts +1 -1
  28. package/dist/components/PaymentCancel/PaymentCancel.d.ts +1 -0
  29. package/dist/components/PaymentError/PaymentError.d.ts +1 -0
  30. package/dist/components/PaymentSuccess/PaymentSuccess.d.ts +1 -0
  31. package/dist/components/StorageUsageProgress/index.d.ts +15 -0
  32. package/dist/components/WorkspaceMenu/WorkspaceMenu.d.ts +9 -2
  33. package/dist/emoji-categorized-DAOdcF53.js +4 -0
  34. package/dist/helpers/getFileType.d.ts +1 -1
  35. package/dist/helpers/pickRandomIcon.d.ts +1 -1
  36. package/dist/helpers/validation.d.ts +2 -0
  37. package/dist/hooks/useDisableWindowScroll.d.ts +1 -0
  38. package/dist/hooks/useNumberQueryParam.d.ts +9 -0
  39. package/dist/icons.min-Chyr-bjL.js +4 -0
  40. package/dist/index-D2ft5hZL.js +38868 -0
  41. package/dist/index.d.ts +12 -3
  42. package/dist/index.esm-BzYOVL-j.js +6814 -0
  43. package/dist/index.js +111 -94
  44. package/dist/index.umd.cjs +87 -993
  45. package/dist/store/pageUpdateCount.d.ts +18 -0
  46. package/dist/store/plansModal.d.ts +7 -0
  47. package/dist/store/timezoneStore.d.ts +1 -1
  48. package/dist/utils/formatStorage.d.ts +6 -0
  49. package/package.json +1 -1
  50. package/dist/components/EmojiPicker/icons.json.d.ts +0 -80399
  51. package/dist/components/ErrorAlert/ErrorAlert.story.d.ts +0 -8
  52. package/dist/components/ImagePicker/ImagePickerGiphy.d.ts +0 -6
  53. package/dist/components/ImagePicker/ImagePickerLink.d.ts +0 -5
  54. package/dist/components/ImagePicker/ImagePickerSkeletonLoader.d.ts +0 -1
  55. package/dist/components/ImagePicker/ImagePickerUnsplash.d.ts +0 -6
  56. package/dist/components/ImagePicker/index.d.ts +0 -1
  57. package/dist/components/LanguagePicker/index.d.ts +0 -11
  58. package/dist/components/NewColorPicker/NewColorPicker.story.d.ts +0 -6
  59. package/dist/icons-DayTtENI.js +0 -5658
  60. package/dist/index-Bz8Yenv3.js +0 -75975
  61. package/dist/layers.C5oAiCeN-DZQs9zcO.js +0 -288
  62. package/dist/layers.CovbS90x-CThbTGYw.js +0 -52
  63. package/dist/layers.CsuN1Q94-BT7000dw.js +0 -170
  64. package/dist/layers.DETHwCxI-BvdKGW_B.js +0 -281
  65. package/dist/layers.vNINlb5t-Bef3Moef.js +0 -289
  66. /package/dist/components/{ImagePicker → FilePicker}/api/giphyApi.d.ts +0 -0
  67. /package/dist/components/{ImagePicker → FilePicker}/api/unsplashApi.d.ts +0 -0
@@ -1,4 +1,10 @@
1
1
  import { AppContainerProps } from './types';
2
+ declare global {
3
+ interface Window {
4
+ publicMode?: boolean;
5
+ preSignMode?: boolean;
6
+ }
7
+ }
2
8
  export declare const AppContainer: (({ header, content, navbar, navbarTitle, }: AppContainerProps) => import("react/jsx-runtime").JSX.Element) & {
3
9
  NavbarContent: ({ children }: {
4
10
  children?: import('react').ReactNode;
@@ -1,2 +1,7 @@
1
1
  import { AppContainerProps } from '../types';
2
+ declare global {
3
+ interface Window {
4
+ openTemplatesModal?: () => void;
5
+ }
6
+ }
2
7
  export declare const DesktopNavbar: (props: Pick<AppContainerProps, 'navbar' | 'navbarTitle'>) => import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- export declare const useHideHeader: () => void;
1
+ export declare const useHideHeader: (enabled?: boolean) => void;
@@ -0,0 +1 @@
1
+ export declare const useHideSidebar: (enabled?: boolean) => void;
@@ -2,9 +2,10 @@ import * as React from 'react';
2
2
  interface CommentsThreadReplyControlsProps {
3
3
  onSubmit: () => void;
4
4
  handleFileChange: (files: File[]) => void;
5
- disabled: boolean;
5
+ disabledSubmitButton: boolean;
6
+ disabledUploadButton: boolean;
6
7
  isSubmitting: boolean;
7
8
  setIsSubmitting: React.Dispatch<React.SetStateAction<boolean>>;
8
9
  }
9
- export declare const CommentsThreadReplyControls: ({ onSubmit, handleFileChange, disabled, setIsSubmitting, isSubmitting, }: CommentsThreadReplyControlsProps) => import("react/jsx-runtime").JSX.Element;
10
+ export declare const CommentsThreadReplyControls: ({ onSubmit, handleFileChange, disabledSubmitButton, disabledUploadButton, setIsSubmitting, isSubmitting, }: CommentsThreadReplyControlsProps) => import("react/jsx-runtime").JSX.Element;
10
11
  export {};
@@ -16,6 +16,7 @@ interface CommentsPanelProps extends Omit<SharedCommentProps, 'commentOrThread'>
16
16
  current: null | HTMLUListElement;
17
17
  };
18
18
  getEditor: GetEditorFn;
19
+ clipPath?: string;
19
20
  }
20
- export declare function CommentsPanel({ activeIDs, deleteCommentOrThread, comments, submitAddComment, markNodeMap, storeOptions, deleteCommentImage, addCommentReaction, removeCommentReactions, updateCommentTextOrImage, listRef, resolveThreat, updateThreadId, getEditor, }: CommentsPanelProps): ReactElement;
21
+ export declare function CommentsPanel({ activeIDs, deleteCommentOrThread, comments, submitAddComment, markNodeMap, storeOptions, deleteCommentImage, addCommentReaction, removeCommentReactions, updateCommentTextOrImage, listRef, resolveThreat, updateThreadId, getEditor, clipPath }: CommentsPanelProps): ReactElement;
21
22
  export {};
@@ -189,6 +189,7 @@ interface ISubmitCommentParams {
189
189
  text: string;
190
190
  parentType: string;
191
191
  parentId: string;
192
+ commentType: string;
192
193
  onSuccess?: (data: any) => void;
193
194
  }
194
195
  export interface IGetReactionsParams {
@@ -1,4 +1,4 @@
1
- import { EmojiPickerProps } from './EmojiPicker';
1
+ import { EmojiPickerProps } from '../..';
2
2
  export declare const EmojiPanel: ({ locales, onChange, onClose, setRandomIcon, }: Pick<EmojiPickerProps, 'locales' | 'value' | 'onChange'> & {
3
3
  onClose: () => void;
4
4
  setRandomIcon: (icon: string) => void;
@@ -1,4 +1,4 @@
1
1
  import { EmojiPickerProps } from './EmojiPicker';
2
- export declare const IconsPanel: ({ showColors, locales, onChange, value, onClose, }: Pick<EmojiPickerProps, 'locales' | 'showColors' | 'value' | 'onChange'> & {
2
+ export declare const IconsPanel: import('react').MemoExoticComponent<({ showColors, locales, onChange, value, onClose, }: Pick<EmojiPickerProps, 'locales' | 'showColors' | 'value' | 'onChange'> & {
3
3
  onClose: () => void;
4
- }) => import("react/jsx-runtime").JSX.Element;
4
+ }) => import("react/jsx-runtime").JSX.Element>;
@@ -0,0 +1,2 @@
1
+ export declare const excludeCategories: string[];
2
+ export declare const frequentEmoji: string[];
@@ -0,0 +1,13 @@
1
+ export interface IEmojiItem {
2
+ i: string;
3
+ e: {
4
+ e: string;
5
+ n: string;
6
+ k: string;
7
+ }[];
8
+ }
9
+ export interface IEmoji {
10
+ e: string;
11
+ n: string;
12
+ k: string;
13
+ }
@@ -1,10 +1,10 @@
1
1
  import { PropsWithChildren } from 'react';
2
2
  import { FloatingPosition, PopoverProps } from '@mantine/core';
3
3
  import { DropzoneProps, FileWithPath } from '@mantine/dropzone';
4
- import { ImagePickerGalleryCollection, ImagePickerLocales } from './types';
4
+ import { FilePickerLocales, FileType, ImagePickerGalleryCollection } from './types';
5
5
  declare const baseTabsList: readonly ["gallery", "upload", "link", "unsplash", "giphy"];
6
6
  type TabType = (typeof baseTabsList)[number];
7
- export type ImagePickerProps = PropsWithChildren<{
7
+ export type FilePickerProps = PropsWithChildren<{
8
8
  onChange?: (v: string) => void;
9
9
  onRemove?: () => void;
10
10
  onUpload?: (files: FileWithPath[], setOpened: (state: boolean) => void) => void;
@@ -19,7 +19,9 @@ export type ImagePickerProps = PropsWithChildren<{
19
19
  galleryCollection?: ImagePickerGalleryCollection[];
20
20
  popoverProps?: PopoverProps;
21
21
  dropZoneProps?: Omit<DropzoneProps, 'onDrop'>;
22
- locales?: ImagePickerLocales;
22
+ locales?: FilePickerLocales;
23
+ type?: FileType;
24
+ isValidMediaUrl?: (url: string) => boolean;
23
25
  }>;
24
- export declare const ImagePicker: ({ onChange, onRemove, onUpload, uploading, showTabs, children, width, position, readOnly, hasImage, giphyToken, unsplashClientId, galleryCollection, popoverProps, dropZoneProps, locales, }: PropsWithChildren<ImagePickerProps>) => import("react/jsx-runtime").JSX.Element;
26
+ export declare const FilePicker: ({ onChange, onRemove, onUpload, uploading, showTabs, children, width, position, readOnly, hasImage, giphyToken, unsplashClientId, type, galleryCollection, isValidMediaUrl, popoverProps, dropZoneProps, locales, }: PropsWithChildren<FilePickerProps>) => import("react/jsx-runtime").JSX.Element;
25
27
  export {};
@@ -1,5 +1,5 @@
1
1
  import { ImagePickerGalleryCollection } from './types';
2
- export declare const ImagePickerGallery: ({ galleryCollection, onChange, }: {
2
+ export declare const FilePickerGallery: ({ galleryCollection, onChange, }: {
3
3
  galleryCollection: ImagePickerGalleryCollection[];
4
4
  onChange?: (v: string) => void;
5
5
  }) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import { FilePickerLocales } from './types';
2
+ export declare const FilePickerGiphy: ({ locales, token, onChange, }: {
3
+ locales: FilePickerLocales;
4
+ token?: string;
5
+ onChange?: (v: string) => void;
6
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,7 @@
1
+ import { FilePickerLocales, FileType } from './types';
2
+ export declare const FilePickerLink: ({ locales, onChange, type, isValidMediaUrl, }: {
3
+ locales: FilePickerLocales;
4
+ onChange?: (v: string) => void;
5
+ type: FileType;
6
+ isValidMediaUrl?: (url: string) => boolean;
7
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare const FilePickerSkeletonLoader: () => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,6 @@
1
+ import { FilePickerLocales } from './types';
2
+ export declare const FilePickerUnsplash: ({ locales, onChange, clientId, }: {
3
+ locales: FilePickerLocales;
4
+ clientId?: string;
5
+ onChange?: (v: string) => void;
6
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -1,7 +1,7 @@
1
1
  import { DropzoneProps, FileWithPath } from '@mantine/dropzone';
2
- import { ImagePickerLocales } from './types';
3
- export declare const ImagePickerUpload: ({ locales, uploading, dropZoneProps, onUpload, }: {
4
- locales: ImagePickerLocales;
2
+ import { FilePickerLocales } from './types';
3
+ export declare const FilePickerUpload: ({ locales, uploading, dropZoneProps, onUpload, }: {
4
+ locales: FilePickerLocales;
5
5
  uploading: boolean;
6
6
  dropZoneProps?: Omit<DropzoneProps, 'onDrop'>;
7
7
  onUpload: (files: FileWithPath[]) => void;
@@ -0,0 +1 @@
1
+ export * from './FilePicker';
@@ -5,7 +5,7 @@ export type ImagePickerGalleryCollection = {
5
5
  url: string;
6
6
  items: string[];
7
7
  };
8
- export type ImagePickerLocales = {
8
+ export type FilePickerLocales = {
9
9
  gallery?: string;
10
10
  link?: string;
11
11
  error?: string;
@@ -27,3 +27,4 @@ export type ImagePickerLocales = {
27
27
  invalidLink?: string;
28
28
  };
29
29
  };
30
+ export type FileType = 'file' | 'image' | 'audio' | 'video';
@@ -0,0 +1,6 @@
1
+ interface LanguagePickerProps {
2
+ value: string;
3
+ onChange: (value: string) => void;
4
+ }
5
+ export declare const LanguagePicker: ({ value, onChange }: LanguagePickerProps) => import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -16,6 +16,9 @@ export declare const illustrationMap: {
16
16
  noGroups: FC<import('react').SVGProps<SVGSVGElement>>;
17
17
  noNotifications: FC<import('react').SVGProps<SVGSVGElement>>;
18
18
  noWorkspaces: FC<import('react').SVGProps<SVGSVGElement>>;
19
+ paymentSuccess: FC<import('react').SVGProps<SVGSVGElement>>;
20
+ notSuccessMan: FC<import('react').SVGProps<SVGSVGElement>>;
21
+ alertMan: FC<import('react').SVGProps<SVGSVGElement>>;
19
22
  '404': FC<import('react').SVGProps<SVGSVGElement>>;
20
23
  '500': FC<import('react').SVGProps<SVGSVGElement>>;
21
24
  };
@@ -1,2 +1,2 @@
1
- declare const TimeLine: () => import("react/jsx-runtime").JSX.Element;
1
+ declare const TimeLine: () => import("react/jsx-runtime").JSX.Element | null;
2
2
  export default TimeLine;
@@ -0,0 +1 @@
1
+ export declare const PaymentCancel: () => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare const PaymentError: () => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export declare const PaymentSuccess: () => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,15 @@
1
+ import { default as React } from 'react';
2
+ export type StorageCategory = 'archives' | 'documents' | 'audio' | 'images' | 'other' | 'code' | 'videos';
3
+ export interface StorageItem {
4
+ type: StorageCategory;
5
+ usedKb: number;
6
+ }
7
+ interface StorageUsageProgressProps {
8
+ simple?: boolean;
9
+ color?: string;
10
+ storageByCategory: StorageItem[];
11
+ totalStorageKb: number;
12
+ size?: number;
13
+ }
14
+ export declare const StorageUsageProgress: React.FC<StorageUsageProgressProps>;
15
+ export {};
@@ -1,10 +1,17 @@
1
1
  import { FC, PropsWithChildren } from 'react';
2
- export type MenuWorkspace = {
2
+ export interface MenuWorkspace {
3
3
  workspaceId: string;
4
4
  workspaceName: string;
5
5
  workspaceIcon: string;
6
6
  invitation?: string | null;
7
- };
7
+ storageLimitKb?: number;
8
+ storageUsedKb?: number;
9
+ storageAvailableKb?: number;
10
+ storageByCategory?: Array<{
11
+ type: 'videos' | 'documents' | 'images' | 'other' | 'audio' | 'archives' | 'code';
12
+ usedKb: number;
13
+ }>;
14
+ }
8
15
  export type RightSectionProps = {
9
16
  isActive: boolean;
10
17
  workspace: MenuWorkspace;