@trii/components 2.0.35 → 2.0.39

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 (92) hide show
  1. package/dist/cjs/index.js +1197 -320
  2. package/dist/cjs/index.js.map +1 -1
  3. package/dist/cjs/types/components/EditContactModal/EditContactModal.d.ts +2 -2
  4. package/dist/cjs/types/components/EditContactModal/components/Header/Header.d.ts +1 -2
  5. package/dist/cjs/types/components/EditContactModal/components/Header/components/AvatarWithActions/AvatarWithActions.d.ts +1 -2
  6. package/dist/cjs/types/components/EditContactModal/components/Header/components/Tags/Tags.d.ts +1 -2
  7. package/dist/cjs/types/components/EditContactModal/components/Section/AddressInformation/AddressInformation.d.ts +1 -2
  8. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/ContactInformation.d.ts +2 -11
  9. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/EditModal.d.ts +0 -1
  10. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Mails/Mails.d.ts +1 -2
  11. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Mails/components/Body/Body.d.ts +1 -2
  12. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Mails/components/Body/components/Mail/Mail.d.ts +1 -2
  13. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/Phones.d.ts +1 -2
  14. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/components/Body/Body.d.ts +1 -2
  15. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/components/Body/components/Phone/Phone.d.ts +1 -2
  16. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/components/Body/components/Phone/components/CountrySelect/CountrySelect.d.ts +1 -4
  17. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/components/Body/components/Phone/components/OptionsMenu/OptionsMenu.d.ts +1 -2
  18. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/RCSs/RCSs.d.ts +1 -2
  19. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/RCSs/components/Body/Body.d.ts +1 -2
  20. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/RCSs/components/Body/components/RCS/RCS.d.ts +1 -2
  21. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Whatsapps/Whatsapps.d.ts +1 -2
  22. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Whatsapps/components/Body/Body.d.ts +1 -2
  23. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Whatsapps/components/Body/components/Whatsapp/Whatsapp.d.ts +1 -2
  24. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/AddressInput/AddressInput.d.ts +1 -2
  25. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/InformationSocialNetworkItem/InformationSocialNetworkItem.d.ts +1 -2
  26. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/InformationSocialNetworkItem/components/Body/Body.d.ts +1 -2
  27. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/InformationSocialNetworkItem/components/Body/components/Ims/Ims.d.ts +1 -2
  28. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/PhoneInput/PhoneInput.d.ts +1 -2
  29. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/SubsectionHeaderWithButton/SubsectionHeaderWithButton.d.ts +1 -2
  30. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/WarningsDisplay/WarningsDisplay.d.ts +1 -2
  31. package/dist/cjs/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/shared/NoteDeleteButton/NoteDeleteButton.d.ts +0 -1
  32. package/dist/cjs/types/components/EditContactModal/components/Section/General/General.d.ts +0 -1
  33. package/dist/cjs/types/components/EditContactModal/components/Section/General/components/BusinessGeneral.d.ts +2 -2
  34. package/dist/cjs/types/components/EditContactModal/components/Section/General/components/ContactGeneral.d.ts +2 -2
  35. package/dist/cjs/types/components/EditContactModal/components/TagsEditor/TagsEditor.d.ts +1 -2
  36. package/dist/cjs/types/components/EditContactModal/context/TranslationContext.d.ts +9 -0
  37. package/dist/cjs/types/components/EditContactModal/hooks/useEntityUpdateSync.d.ts +8 -0
  38. package/dist/cjs/types/components/EditContactModal/hooks/useModalCloseHandler.d.ts +6 -0
  39. package/dist/cjs/types/components/EditContactModal/hooks/useTagsEditorController.d.ts +23 -0
  40. package/dist/cjs/types/components/EditContactModal/shared/ContactInfoLabel/ContactInfoLabel.d.ts +0 -1
  41. package/dist/cjs/types/components/EditContactModal/shared/EntityCustomFieldLabel/EntityCustomFieldLabel.d.ts +1 -2
  42. package/dist/cjs/types/components/EditContactModal/shared/EntityCustomFieldLabel/components/CustomPropertyDateRangePicker/CustomPropertyDateRangePicker.d.ts +1 -2
  43. package/dist/cjs/types/components/EditContactModal/shared/EntityCustomFieldLabel/components/CustomPropertyOptionSelect/CustomPropertyOptionsSelect.d.ts +1 -2
  44. package/dist/cjs/types/components/EditContactModal/shared/EntityCustomFieldLabel/components/CustomPropertyTimeRangePicker/CustomPropertyTimeRangePicker.d.ts +1 -2
  45. package/dist/cjs/types/components/EditContactModal/shared/EntityInfoLabel/EntityInfoLabel.d.ts +0 -1
  46. package/dist/esm/index.js +1199 -322
  47. package/dist/esm/index.js.map +1 -1
  48. package/dist/esm/types/components/EditContactModal/EditContactModal.d.ts +2 -2
  49. package/dist/esm/types/components/EditContactModal/components/Header/Header.d.ts +1 -2
  50. package/dist/esm/types/components/EditContactModal/components/Header/components/AvatarWithActions/AvatarWithActions.d.ts +1 -2
  51. package/dist/esm/types/components/EditContactModal/components/Header/components/Tags/Tags.d.ts +1 -2
  52. package/dist/esm/types/components/EditContactModal/components/Section/AddressInformation/AddressInformation.d.ts +1 -2
  53. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/ContactInformation.d.ts +2 -11
  54. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/EditModal.d.ts +0 -1
  55. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Mails/Mails.d.ts +1 -2
  56. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Mails/components/Body/Body.d.ts +1 -2
  57. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Mails/components/Body/components/Mail/Mail.d.ts +1 -2
  58. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/Phones.d.ts +1 -2
  59. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/components/Body/Body.d.ts +1 -2
  60. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/components/Body/components/Phone/Phone.d.ts +1 -2
  61. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/components/Body/components/Phone/components/CountrySelect/CountrySelect.d.ts +1 -4
  62. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Phones/components/Body/components/Phone/components/OptionsMenu/OptionsMenu.d.ts +1 -2
  63. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/RCSs/RCSs.d.ts +1 -2
  64. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/RCSs/components/Body/Body.d.ts +1 -2
  65. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/RCSs/components/Body/components/RCS/RCS.d.ts +1 -2
  66. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Whatsapps/Whatsapps.d.ts +1 -2
  67. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Whatsapps/components/Body/Body.d.ts +1 -2
  68. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/components/Whatsapps/components/Body/components/Whatsapp/Whatsapp.d.ts +1 -2
  69. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/AddressInput/AddressInput.d.ts +1 -2
  70. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/InformationSocialNetworkItem/InformationSocialNetworkItem.d.ts +1 -2
  71. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/InformationSocialNetworkItem/components/Body/Body.d.ts +1 -2
  72. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/InformationSocialNetworkItem/components/Body/components/Ims/Ims.d.ts +1 -2
  73. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/PhoneInput/PhoneInput.d.ts +1 -2
  74. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/SubsectionHeaderWithButton/SubsectionHeaderWithButton.d.ts +1 -2
  75. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/layout/WarningsDisplay/WarningsDisplay.d.ts +1 -2
  76. package/dist/esm/types/components/EditContactModal/components/Section/ContactInformation/components/EditModal/shared/NoteDeleteButton/NoteDeleteButton.d.ts +0 -1
  77. package/dist/esm/types/components/EditContactModal/components/Section/General/General.d.ts +0 -1
  78. package/dist/esm/types/components/EditContactModal/components/Section/General/components/BusinessGeneral.d.ts +2 -2
  79. package/dist/esm/types/components/EditContactModal/components/Section/General/components/ContactGeneral.d.ts +2 -2
  80. package/dist/esm/types/components/EditContactModal/components/TagsEditor/TagsEditor.d.ts +1 -2
  81. package/dist/esm/types/components/EditContactModal/context/TranslationContext.d.ts +9 -0
  82. package/dist/esm/types/components/EditContactModal/hooks/useEntityUpdateSync.d.ts +8 -0
  83. package/dist/esm/types/components/EditContactModal/hooks/useModalCloseHandler.d.ts +6 -0
  84. package/dist/esm/types/components/EditContactModal/hooks/useTagsEditorController.d.ts +23 -0
  85. package/dist/esm/types/components/EditContactModal/shared/ContactInfoLabel/ContactInfoLabel.d.ts +0 -1
  86. package/dist/esm/types/components/EditContactModal/shared/EntityCustomFieldLabel/EntityCustomFieldLabel.d.ts +1 -2
  87. package/dist/esm/types/components/EditContactModal/shared/EntityCustomFieldLabel/components/CustomPropertyDateRangePicker/CustomPropertyDateRangePicker.d.ts +1 -2
  88. package/dist/esm/types/components/EditContactModal/shared/EntityCustomFieldLabel/components/CustomPropertyOptionSelect/CustomPropertyOptionsSelect.d.ts +1 -2
  89. package/dist/esm/types/components/EditContactModal/shared/EntityCustomFieldLabel/components/CustomPropertyTimeRangePicker/CustomPropertyTimeRangePicker.d.ts +1 -2
  90. package/dist/esm/types/components/EditContactModal/shared/EntityInfoLabel/EntityInfoLabel.d.ts +0 -1
  91. package/dist/index.d.ts +4 -4
  92. package/package.json +11 -1
@@ -1,5 +1,5 @@
1
1
  import { SxProps, Theme } from '@mui/material';
2
- export interface ContactInfoPopupProps {
2
+ export interface Props {
3
3
  open: boolean;
4
4
  onClose: () => void;
5
5
  baseUrl?: string;
@@ -8,5 +8,5 @@ export interface ContactInfoPopupProps {
8
8
  t: (key: string) => string;
9
9
  sx?: SxProps<Theme>;
10
10
  }
11
- declare const EditContactModal: ({ open, onClose, baseUrl, spaceId, contactId, sx, t, }: ContactInfoPopupProps) => import("react/jsx-runtime").JSX.Element;
11
+ declare const EditContactModal: ({ open, onClose, baseUrl, spaceId, contactId, sx, t }: Props) => import("react/jsx-runtime").JSX.Element;
12
12
  export default EditContactModal;
@@ -5,7 +5,6 @@ type HeaderProps = {
5
5
  displayName: string;
6
6
  onError?: (error: Error) => void;
7
7
  tags: IContactTag[];
8
- t: (key: string) => string;
9
8
  onEditTags: () => void;
10
9
  onUploadPhoto: () => void;
11
10
  onPhotoFileChange: (event: ChangeEvent<HTMLInputElement>) => void;
@@ -14,5 +13,5 @@ type HeaderProps = {
14
13
  onDeletePhoto: () => void;
15
14
  isDeletingPhoto: boolean;
16
15
  };
17
- declare const Header: ({ imgUrl, displayName, onError, tags, t, onEditTags, onUploadPhoto, onPhotoFileChange, photoInputRef, isUploadingPhoto, onDeletePhoto, isDeletingPhoto, }: HeaderProps) => import("react/jsx-runtime").JSX.Element;
16
+ declare const Header: ({ imgUrl, displayName, onError, tags, onEditTags, onUploadPhoto, onPhotoFileChange, photoInputRef, isUploadingPhoto, onDeletePhoto, isDeletingPhoto, }: HeaderProps) => import("react/jsx-runtime").JSX.Element;
18
17
  export default Header;
@@ -6,7 +6,6 @@ type AvatarWithActionsProps = {
6
6
  onDelete?: () => void;
7
7
  isUploading?: boolean;
8
8
  isDeleting?: boolean;
9
- t: (key: string) => string;
10
9
  };
11
- declare const AvatarWithActions: ({ src, alt, onError, onUpload, onDelete, isUploading, isDeleting, t, }: AvatarWithActionsProps) => import("react/jsx-runtime").JSX.Element;
10
+ declare const AvatarWithActions: ({ src, alt, onError, onUpload, onDelete, isUploading, isDeleting, }: AvatarWithActionsProps) => import("react/jsx-runtime").JSX.Element;
12
11
  export default AvatarWithActions;
@@ -1,8 +1,7 @@
1
1
  import { IContactTag } from '@trii/types/dist/Contacts';
2
2
  interface TagsProps {
3
3
  tags: IContactTag[];
4
- t: (key: string) => string;
5
4
  onEditTags: () => void;
6
5
  }
7
- declare const Tags: ({ tags, t, onEditTags }: TagsProps) => import("react/jsx-runtime").JSX.Element;
6
+ declare const Tags: ({ tags, onEditTags }: TagsProps) => import("react/jsx-runtime").JSX.Element;
8
7
  export default Tags;
@@ -4,8 +4,7 @@ export type AddressInformationProps = {
4
4
  entityData: IContact | IBusiness;
5
5
  baseUrl?: string;
6
6
  spaceId?: string;
7
- t: (key: string) => string;
8
7
  onEntityUpdated?: (entity: unknown) => void;
9
8
  };
10
- declare const AddressInformation: ({ entityType, entityData, baseUrl, spaceId, t, onEntityUpdated, }: AddressInformationProps) => import("react/jsx-runtime").JSX.Element;
9
+ declare const AddressInformation: ({ entityType, entityData, baseUrl, spaceId, onEntityUpdated, }: AddressInformationProps) => import("react/jsx-runtime").JSX.Element;
11
10
  export default AddressInformation;
@@ -1,16 +1,7 @@
1
- import { IBusiness, IContact, IContactAddress } from '@trii/types/dist/Contacts';
1
+ import type { IBusiness, IContact } from '@trii/types/dist/Contacts/contacts';
2
2
  type OwnerData = IContact | IBusiness;
3
3
  interface Props {
4
- phones: IContactAddress[];
5
- emails: IContactAddress[];
6
- facebook: IContactAddress[];
7
- whatsapp: IContactAddress[];
8
- mercadolibre: IContactAddress[];
9
- webchat: IContactAddress[];
10
- instagram: IContactAddress[];
11
- rcs?: IContactAddress[];
12
4
  ownerData: OwnerData;
13
- t: (key: string) => string;
14
5
  }
15
- declare const ContactInformation: ({ phones, emails, facebook, whatsapp, mercadolibre, webchat, instagram, rcs, ownerData, t, }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const ContactInformation: ({ ownerData }: Props) => import("react/jsx-runtime").JSX.Element;
16
7
  export default ContactInformation;
@@ -3,7 +3,6 @@ interface EditModalProps {
3
3
  open: boolean;
4
4
  onClose: () => void;
5
5
  title: string;
6
- t: (key: string) => string;
7
6
  }
8
7
  declare const EditModal: React.FC<EditModalProps>;
9
8
  export default EditModal;
@@ -3,7 +3,6 @@ import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  emails: Array<NewAddress | IContactAddress>;
5
5
  handleAdd: () => void;
6
- t?: (key: string) => string;
7
6
  };
8
- declare const Mails: ({ emails, handleAdd, t }: Props) => import("react/jsx-runtime").JSX.Element;
7
+ declare const Mails: ({ emails, handleAdd }: Props) => import("react/jsx-runtime").JSX.Element;
9
8
  export default Mails;
@@ -2,7 +2,6 @@ import { NewAddress } from '../../../../../../../../../utils/contactHelper';
2
2
  import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  emails: Array<NewAddress | IContactAddress>;
5
- t?: (key: string) => string;
6
5
  };
7
- declare const Body: ({ emails, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const Body: ({ emails }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default Body;
@@ -2,7 +2,6 @@ import { NewAddress } from '../../../../../../../../../../../utils/contactHelper
2
2
  import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  data: NewAddress | IContactAddress;
5
- t?: (key: string) => string;
6
5
  };
7
- declare const Mail: ({ data, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const Mail: ({ data }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default Mail;
@@ -3,7 +3,6 @@ import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  phoneNumbers: Array<NewAddress | IContactAddress>;
5
5
  handleAdd: () => void;
6
- t?: (key: string) => string;
7
6
  };
8
- declare const Phones: ({ phoneNumbers, handleAdd, t }: Props) => import("react/jsx-runtime").JSX.Element;
7
+ declare const Phones: ({ phoneNumbers, handleAdd }: Props) => import("react/jsx-runtime").JSX.Element;
9
8
  export default Phones;
@@ -2,7 +2,6 @@ import { NewAddress } from '../../../../../../../../../utils/contactHelper';
2
2
  import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  phoneNumbers: Array<NewAddress | IContactAddress>;
5
- t?: (key: string) => string;
6
5
  };
7
- declare const Body: ({ phoneNumbers, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const Body: ({ phoneNumbers }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default Body;
@@ -2,7 +2,6 @@ import { NewAddress } from '../../../../../../../../../../../utils/contactHelper
2
2
  import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  data: NewAddress | IContactAddress;
5
- t?: (key: string) => string;
6
5
  };
7
- declare const Phone: ({ data, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const Phone: ({ data }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default Phone;
@@ -1,5 +1,2 @@
1
- type Props = {
2
- t?: (key: string) => string;
3
- };
4
- declare const CountrySelect: ({ t }: Props) => import("react/jsx-runtime").JSX.Element;
1
+ declare const CountrySelect: () => import("react/jsx-runtime").JSX.Element;
5
2
  export default CountrySelect;
@@ -7,12 +7,11 @@ type OptionsMenuProps = {
7
7
  };
8
8
  handleLinkAccountSave: () => Promise<void>;
9
9
  checked: boolean;
10
- t?: (key: string) => string;
11
10
  onCheckContactAddress?: (type: ChannelType) => Promise<ResultContactAddressCheck | null>;
12
11
  };
13
12
  type ResultContactAddressCheck = {
14
13
  success: boolean;
15
14
  warnings: string[];
16
15
  };
17
- declare const OptionsMenu: ({ onDelete, addressData, handleLinkAccountSave, checked, t, onCheckContactAddress, }: OptionsMenuProps) => import("react/jsx-runtime").JSX.Element;
16
+ declare const OptionsMenu: ({ onDelete, addressData, handleLinkAccountSave, checked, onCheckContactAddress, }: OptionsMenuProps) => import("react/jsx-runtime").JSX.Element;
18
17
  export default OptionsMenu;
@@ -3,7 +3,6 @@ import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  RCSs: Array<NewAddress | IContactAddress>;
5
5
  handleAdd: () => void;
6
- t?: (key: string) => string;
7
6
  };
8
- declare const RCSs: ({ RCSs, handleAdd, t }: Props) => import("react/jsx-runtime").JSX.Element;
7
+ declare const RCSs: ({ RCSs, handleAdd }: Props) => import("react/jsx-runtime").JSX.Element;
9
8
  export default RCSs;
@@ -2,7 +2,6 @@ import { NewAddress } from '../../../../../../../../../utils/contactHelper';
2
2
  import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  RCSs: Array<NewAddress | IContactAddress>;
5
- t?: (key: string) => string;
6
5
  };
7
- declare const Body: ({ RCSs, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const Body: ({ RCSs }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default Body;
@@ -2,7 +2,6 @@ import { NewAddress } from '../../../../../../../../../../../utils/contactHelper
2
2
  import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  data: NewAddress | IContactAddress;
5
- t?: (key: string) => string;
6
5
  };
7
- declare const RCS: ({ data, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const RCS: ({ data }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default RCS;
@@ -3,7 +3,6 @@ import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  whatsapps: Array<NewAddress | IContactAddress>;
5
5
  handleAdd: () => void;
6
- t?: (key: string) => string;
7
6
  };
8
- declare const Whatsapps: ({ whatsapps, handleAdd, t }: Props) => import("react/jsx-runtime").JSX.Element;
7
+ declare const Whatsapps: ({ whatsapps, handleAdd }: Props) => import("react/jsx-runtime").JSX.Element;
9
8
  export default Whatsapps;
@@ -2,7 +2,6 @@ import { NewAddress } from '../../../../../../../../../utils/contactHelper';
2
2
  import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  whatsapps: Array<NewAddress | IContactAddress>;
5
- t?: (key: string) => string;
6
5
  };
7
- declare const Body: ({ whatsapps, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const Body: ({ whatsapps }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default Body;
@@ -2,7 +2,6 @@ import { NewAddress } from '../../../../../../../../../../../utils/contactHelper
2
2
  import type { IContactAddress } from '@trii/types/dist/Contacts';
3
3
  type Props = {
4
4
  data: NewAddress | IContactAddress;
5
- t?: (key: string) => string;
6
5
  };
7
- declare const Whatsapp: ({ data, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const Whatsapp: ({ data }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default Whatsapp;
@@ -8,7 +8,6 @@ interface AddressInputProps {
8
8
  data: NewAddress | IContactAddress;
9
9
  onChange: (e: ChangeEvent<HTMLInputElement | HTMLTextAreaElement>, id: string, channelType: ChannelType) => void;
10
10
  setWarnings: Dispatch<SetStateAction<string[]>>;
11
- t?: (key: string) => string;
12
11
  }
13
- declare const AddressInput: ({ data, onChange, setWarnings, t }: AddressInputProps) => import("react/jsx-runtime").JSX.Element;
12
+ declare const AddressInput: ({ data, onChange, setWarnings }: AddressInputProps) => import("react/jsx-runtime").JSX.Element;
14
13
  export default AddressInput;
@@ -6,7 +6,6 @@ type Props = {
6
6
  editEntity: UseEditBusiness | UseEditContact;
7
7
  title: string;
8
8
  IMSs: IContactAddress[] | NewAddress[];
9
- t?: (key: string) => string;
10
9
  };
11
- declare const InformationSocialNetworkItem: ({ editEntity, title, IMSs, t }: Props) => import("react/jsx-runtime").JSX.Element;
10
+ declare const InformationSocialNetworkItem: ({ editEntity, title, IMSs }: Props) => import("react/jsx-runtime").JSX.Element;
12
11
  export default InformationSocialNetworkItem;
@@ -5,7 +5,6 @@ import { IContactAddress } from '@trii/types/dist/Contacts';
5
5
  type Props = {
6
6
  IMSs: NewAddress[] | IContactAddress[];
7
7
  editEntity: UseEditBusiness | UseEditContact;
8
- t?: (key: string) => string;
9
8
  };
10
- declare const Body: ({ IMSs, editEntity, t }: Props) => import("react/jsx-runtime").JSX.Element;
9
+ declare const Body: ({ IMSs, editEntity }: Props) => import("react/jsx-runtime").JSX.Element;
11
10
  export default Body;
@@ -5,7 +5,6 @@ import { IContactAddress } from '@trii/types/dist/Contacts';
5
5
  type Props = {
6
6
  data: NewAddress | IContactAddress;
7
7
  editEntity: UseEditBusiness | UseEditContact;
8
- t?: (key: string) => string;
9
8
  };
10
- declare const Ims: ({ data, editEntity, t }: Props) => import("react/jsx-runtime").JSX.Element;
9
+ declare const Ims: ({ data, editEntity }: Props) => import("react/jsx-runtime").JSX.Element;
11
10
  export default Ims;
@@ -8,7 +8,6 @@ interface AddressInputProps {
8
8
  data: NewAddress | IContactAddress;
9
9
  onChange: (e: ChangeEvent<HTMLInputElement | HTMLTextAreaElement>, id: string, channelType: ChannelType) => void;
10
10
  setWarnings: Dispatch<SetStateAction<string[]>>;
11
- t?: (key: string) => string;
12
11
  }
13
- declare const PhoneInput: ({ data, onChange, setWarnings, t }: AddressInputProps) => import("react/jsx-runtime").JSX.Element;
12
+ declare const PhoneInput: ({ data, onChange, setWarnings }: AddressInputProps) => import("react/jsx-runtime").JSX.Element;
14
13
  export default PhoneInput;
@@ -1,7 +1,6 @@
1
1
  type Props = {
2
2
  title: string;
3
3
  handleAdd: () => void;
4
- t: (key: string) => string;
5
4
  };
6
- declare const SubsectionHeaderWithButton: ({ title, handleAdd, t }: Props) => import("react/jsx-runtime").JSX.Element;
5
+ declare const SubsectionHeaderWithButton: ({ title, handleAdd }: Props) => import("react/jsx-runtime").JSX.Element;
7
6
  export default SubsectionHeaderWithButton;
@@ -1,6 +1,5 @@
1
1
  type WarningsDisplayProps = {
2
2
  warnings: string[];
3
- t?: (key: string) => string;
4
3
  };
5
- declare const WarningsDisplay: ({ warnings, t }: WarningsDisplayProps) => import("react/jsx-runtime").JSX.Element;
4
+ declare const WarningsDisplay: ({ warnings }: WarningsDisplayProps) => import("react/jsx-runtime").JSX.Element;
6
5
  export default WarningsDisplay;
@@ -7,7 +7,6 @@ type Props = {
7
7
  handleNoteFieldChange: (e: React.ChangeEvent<HTMLInputElement | HTMLTextAreaElement>, addressId: string, addressType: ChannelType) => void;
8
8
  handleDeleteAddress: (addressId: string, addressType: ChannelType) => void;
9
9
  checked?: boolean;
10
- t?: (key: string) => string;
11
10
  entityId?: string;
12
11
  mode?: string;
13
12
  setWarnings?: (warnings: string[]) => void;
@@ -7,7 +7,6 @@ export interface GeneralProps {
7
7
  customContactFields: IContactField[];
8
8
  baseUrl?: string;
9
9
  spaceId?: string;
10
- t: (key: string) => string;
11
10
  currentUser?: UserTrii | null;
12
11
  onEntityUpdated?: (entity: unknown) => void;
13
12
  }
@@ -1,5 +1,5 @@
1
- import { IBusiness } from "@trii/types/dist/Contacts";
2
- import { GeneralProps } from "../General";
1
+ import { IBusiness } from '@trii/types/dist/Contacts';
2
+ import { GeneralProps } from '../General';
3
3
  export type BusinessGeneralProps = Omit<GeneralProps, 'entityData' | 'entityType'> & {
4
4
  entityType: 'business';
5
5
  entityData: IBusiness;
@@ -1,5 +1,5 @@
1
- import { IContact } from "@trii/types/dist/Contacts";
2
- import { GeneralProps } from "../General";
1
+ import { IContact } from '@trii/types/dist/Contacts';
2
+ import { GeneralProps } from '../General';
3
3
  export type ContactGeneralProps = Omit<GeneralProps, 'entityData' | 'entityType'> & {
4
4
  entityType: 'contact';
5
5
  entityData: IContact;
@@ -6,7 +6,6 @@ type TagsEditorProps = {
6
6
  onBack: () => void;
7
7
  onSave: () => void;
8
8
  isSaving: boolean;
9
- t: (key: string) => string;
10
9
  };
11
- declare const TagsEditor: ({ value, options, onChange, onBack, onSave, isSaving, t }: TagsEditorProps) => import("react/jsx-runtime").JSX.Element;
10
+ declare const TagsEditor: ({ value, options, onChange, onBack, onSave, isSaving }: TagsEditorProps) => import("react/jsx-runtime").JSX.Element;
12
11
  export default TagsEditor;
@@ -0,0 +1,9 @@
1
+ import type { ReactNode } from 'react';
2
+ export type TranslationFn = (key: string, ...args: unknown[]) => string;
3
+ interface TranslationProviderProps {
4
+ t: TranslationFn;
5
+ children: ReactNode;
6
+ }
7
+ export declare const TranslationProvider: ({ t, children }: TranslationProviderProps) => import("react/jsx-runtime").JSX.Element;
8
+ export declare const useTranslationContext: () => TranslationFn;
9
+ export {};
@@ -0,0 +1,8 @@
1
+ import type { IBusiness, IContact } from '@trii/types/dist/Contacts/contacts';
2
+ type Entity = IContact | IBusiness | null;
3
+ type UseEntityUpdateSyncArgs = {
4
+ entity: Entity;
5
+ setEntity: (next: IContact | IBusiness | null) => void;
6
+ };
7
+ export declare const useEntityUpdateSync: ({ entity, setEntity }: UseEntityUpdateSyncArgs) => (update: unknown) => void;
8
+ export {};
@@ -0,0 +1,6 @@
1
+ type Reason = 'backdropClick' | 'escapeKeyDown';
2
+ type UseModalCloseHandlerArgs = {
3
+ onClose: () => void;
4
+ };
5
+ export declare const useModalCloseHandler: ({ onClose }: UseModalCloseHandlerArgs) => (event: unknown, reason?: Reason) => void;
6
+ export {};
@@ -0,0 +1,23 @@
1
+ import type { ILabel } from '@trii/types/dist/Contacts';
2
+ import type { IBusiness, IContact, IContactTag } from '@trii/types/dist/Contacts/contacts';
3
+ type ContactType = 'contact' | 'business' | 'unknown';
4
+ type UseTagsEditorControllerArgs = {
5
+ open: boolean;
6
+ baseUrl?: string;
7
+ spaceId?: string;
8
+ contactData: IContact | IBusiness | null;
9
+ contactType: ContactType;
10
+ labels: ILabel[];
11
+ selectedTags: IContactTag[];
12
+ onTagsUpdated: (tags: IContactTag[]) => void;
13
+ };
14
+ type UseTagsEditorControllerReturn = {
15
+ view: 'main' | 'tags';
16
+ setView: (view: 'main' | 'tags') => void;
17
+ draftLabels: ILabel[];
18
+ setDraftLabels: (labels: ILabel[]) => void;
19
+ isSaving: boolean;
20
+ handleSaveTags: () => Promise<void>;
21
+ };
22
+ export declare const useTagsEditorController: ({ open, baseUrl, spaceId, contactData, contactType, labels, selectedTags, onTagsUpdated, }: UseTagsEditorControllerArgs) => UseTagsEditorControllerReturn;
23
+ export {};
@@ -12,7 +12,6 @@ type BaseProps = {
12
12
  baseUrl?: string;
13
13
  spaceId?: string;
14
14
  contactId?: string;
15
- t: (key: string) => string;
16
15
  onEntityUpdated?: (entity: unknown) => void;
17
16
  };
18
17
  type BirthdayProps = BaseProps & {
@@ -12,8 +12,7 @@ type Props = {
12
12
  userTrii?: UserTrii | null;
13
13
  baseUrl?: string;
14
14
  spaceId?: string;
15
- t: (key: string) => string;
16
15
  onEntityUpdated?: (entity: unknown) => void;
17
16
  };
18
- declare const EntityCustomFieldLabel: ({ property, entity, entityType, entityId, customContactFields, userTrii, baseUrl, spaceId, t, onEntityUpdated, }: Props) => import("react/jsx-runtime").JSX.Element;
17
+ declare const EntityCustomFieldLabel: ({ property, entity, entityType, entityId, customContactFields, userTrii, baseUrl, spaceId, onEntityUpdated, }: Props) => import("react/jsx-runtime").JSX.Element;
19
18
  export default EntityCustomFieldLabel;
@@ -4,7 +4,6 @@ type Props = {
4
4
  value: DateRange<Dayjs> | null;
5
5
  handleChange: (newValue: DateRange<Dayjs>) => void;
6
6
  userDateFormat?: string;
7
- t: (key: string) => string;
8
7
  };
9
- declare const CustomPropertyDateRangePicker: ({ value, handleChange, userDateFormat, t }: Props) => import("react/jsx-runtime").JSX.Element;
8
+ declare const CustomPropertyDateRangePicker: ({ value, handleChange, userDateFormat }: Props) => import("react/jsx-runtime").JSX.Element;
10
9
  export default CustomPropertyDateRangePicker;
@@ -2,7 +2,6 @@ type Props = {
2
2
  value: string;
3
3
  handleChange: (value: string) => void;
4
4
  options: string[];
5
- t: (key: string) => string;
6
5
  };
7
- declare const CustomPropertyOptionsSelect: ({ handleChange, value, options, t }: Props) => import("react/jsx-runtime").JSX.Element;
6
+ declare const CustomPropertyOptionsSelect: ({ handleChange, value, options }: Props) => import("react/jsx-runtime").JSX.Element;
8
7
  export default CustomPropertyOptionsSelect;
@@ -4,7 +4,6 @@ type Props = {
4
4
  value: DateRange<Dayjs> | null;
5
5
  handleChange: (newValue: DateRange<Dayjs>) => void;
6
6
  userTimeFormat?: string;
7
- t: (key: string) => string;
8
7
  };
9
- declare const CustomPropertyTimeRangePicker: ({ value, handleChange, userTimeFormat, t, }: Props) => import("react/jsx-runtime").JSX.Element;
8
+ declare const CustomPropertyTimeRangePicker: ({ value, handleChange, userTimeFormat }: Props) => import("react/jsx-runtime").JSX.Element;
10
9
  export default CustomPropertyTimeRangePicker;
@@ -17,7 +17,6 @@ type ContactBaseProps = SharedProps & {
17
17
  options?: Array<UserInfo | IList>;
18
18
  constructUpdateObject?: (value: string | Date | null) => object;
19
19
  businessId?: string;
20
- t: (key: string) => string;
21
20
  };
22
21
  type ContactBirthdayProps = ContactBaseProps & {
23
22
  inputType: 'birthday';