@inceptionbg/iui 2.0.35 → 2.0.36

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 (241) hide show
  1. package/package.json +4 -1
  2. package/idea/GridTable/GridTable.tsx +0 -119
  3. package/idea/GridTable/gridTable.scss +0 -42
  4. package/idea/Menu/Menu.tsx +0 -121
  5. package/idea/Menu/MenuItem.tsx +0 -75
  6. package/idea/Menu/hooks/useMenuControl.ts +0 -13
  7. package/idea/Menu.tsx +0 -133
  8. package/idea/NoAccessInfo.tsx +0 -193
  9. package/idea/Table/Components/Edit/ItemActionsMenu.tsx +0 -85
  10. package/idea/Table/Components/Edit/ItemEditOptionsButtons.tsx +0 -31
  11. package/idea/Table/Components/Edit/TableEditRow.tsx +0 -57
  12. package/idea/Table/Components/FilterItem.tsx +0 -20
  13. package/idea/Table/Components/Header/TableHeader.tsx +0 -46
  14. package/idea/Table/Components/Header/TableHeaderRow.tsx +0 -37
  15. package/idea/Table/Components/Print/CustomTablePrint.tsx +0 -115
  16. package/idea/Table/Components/SetSortList.tsx +0 -30
  17. package/idea/Table/Components/SetTableFilter.tsx +0 -91
  18. package/idea/Table/Components/TableFooter.tsx +0 -137
  19. package/idea/Table/Components/TableOptions.tsx +0 -227
  20. package/idea/Table/Components/Templates/TemplateCreate.tsx +0 -80
  21. package/idea/Table/Components/Templates/TemplateCreateDefault.tsx +0 -45
  22. package/idea/Table/Components/Templates/TemplateList.tsx +0 -167
  23. package/idea/Table/Components/Templates/repo/TemplateRepo.ts +0 -53
  24. package/idea/Table/Table.tsx +0 -528
  25. package/idea/Table/hooks/useDefaultTemplate.ts +0 -20
  26. package/idea/Table/hooks/useTableKeyboard.ts +0 -137
  27. package/idea/Table/hooks/useTableSelect.ts +0 -11
  28. package/rollup.config.js +0 -52
  29. package/src/assets/icons/duotone/faBell.ts +0 -17
  30. package/src/assets/icons/duotone/faCircleUser.ts +0 -17
  31. package/src/assets/icons/regular/faArrowLeft.ts +0 -15
  32. package/src/assets/icons/regular/faArrowRightArrowLeft.ts +0 -15
  33. package/src/assets/icons/regular/faCircleCheck.ts +0 -15
  34. package/src/assets/icons/regular/faCircleExclamation.ts +0 -15
  35. package/src/assets/icons/regular/faCircleInfo.ts +0 -15
  36. package/src/assets/icons/regular/faFileArrowDown.ts +0 -15
  37. package/src/assets/icons/regular/faFilterCircleXmark.ts +0 -15
  38. package/src/assets/icons/regular/faTriangleExclamation.ts +0 -15
  39. package/src/assets/icons/solid/faAngleLeft.ts +0 -15
  40. package/src/assets/icons/solid/faAngleRight.ts +0 -15
  41. package/src/assets/icons/solid/faArrowDownWideShort.ts +0 -15
  42. package/src/assets/icons/solid/faCaretDown.ts +0 -15
  43. package/src/assets/icons/solid/faCheck.ts +0 -15
  44. package/src/assets/icons/solid/faEllipsisVertical.ts +0 -15
  45. package/src/assets/icons/solid/faEnvelopeDot.ts +0 -15
  46. package/src/assets/icons/solid/faFilter.ts +0 -15
  47. package/src/assets/icons/solid/faFloppyDisk.ts +0 -15
  48. package/src/assets/icons/solid/faGripDotsVertical.ts +0 -15
  49. package/src/assets/icons/solid/faListUl.ts +0 -15
  50. package/src/assets/icons/solid/faMinus.ts +0 -15
  51. package/src/assets/icons/solid/faPlus.ts +0 -15
  52. package/src/assets/icons/solid/faPrint.ts +0 -15
  53. package/src/assets/icons/solid/faRotateRight.ts +0 -15
  54. package/src/assets/icons/solid/faXmark.ts +0 -15
  55. package/src/assets/images/logo/inception.svg +0 -22
  56. package/src/assets/images/logo/mts.svg +0 -5703
  57. package/src/assets/images/logo/paperless.svg +0 -21
  58. package/src/assets/images/logo/pismonosa.png +0 -0
  59. package/src/assets/images/not-found.svg +0 -19
  60. package/src/components/Accordions/Accordions.tsx +0 -74
  61. package/src/components/Alert/Alert.tsx +0 -31
  62. package/src/components/Badge/DotBadge.tsx +0 -16
  63. package/src/components/Badge/NotificationBadge.tsx +0 -29
  64. package/src/components/Badge/PillBadge.tsx +0 -13
  65. package/src/components/Button/Button.tsx +0 -56
  66. package/src/components/Button/IconButton.tsx +0 -51
  67. package/src/components/Button/SplitButton.tsx +0 -91
  68. package/src/components/Dashboard/Dashboard.tsx +0 -9
  69. package/src/components/Dashboard/DashboardWidget.tsx +0 -44
  70. package/src/components/Dashboard/FastLinksWidget/FastLinksWidget.tsx +0 -36
  71. package/src/components/Dialog/Dialog.tsx +0 -178
  72. package/src/components/Dialog/components/DialogFooter.tsx +0 -100
  73. package/src/components/Header/Components/EnvBadge.tsx +0 -17
  74. package/src/components/Header/Components/ModuleSelect.tsx +0 -68
  75. package/src/components/Header/Components/Notifications.tsx +0 -204
  76. package/src/components/Header/Components/UserMenu.tsx +0 -52
  77. package/src/components/Header/Header.tsx +0 -45
  78. package/src/components/Helper/Collapse.tsx +0 -53
  79. package/src/components/Inputs/Checkbox.tsx +0 -53
  80. package/src/components/Inputs/CurrencyInput.tsx +0 -124
  81. package/src/components/Inputs/DateInput/DateInput.tsx +0 -184
  82. package/src/components/Inputs/DateInput/components/DatePartInput.tsx +0 -159
  83. package/src/components/Inputs/InputWrapper.tsx +0 -95
  84. package/src/components/Inputs/NumberInput.tsx +0 -86
  85. package/src/components/Inputs/PasswordInput.tsx +0 -39
  86. package/src/components/Inputs/PhoneInput/PhoneInput.tsx +0 -108
  87. package/src/components/Inputs/PhoneInput/utils/countryCode.ts +0 -20
  88. package/src/components/Inputs/Radio.tsx +0 -59
  89. package/src/components/Inputs/RadioGroup.tsx +0 -48
  90. package/src/components/Inputs/RadioLarge.tsx +0 -39
  91. package/src/components/Inputs/SearchInput.tsx +0 -46
  92. package/src/components/Inputs/Selects/Select.tsx +0 -17
  93. package/src/components/Inputs/Selects/components/CustomSelectComponents.tsx +0 -19
  94. package/src/components/Inputs/Selects/components/SelectWrapper.tsx +0 -118
  95. package/src/components/Inputs/Selects/utils/selectStyles.ts +0 -101
  96. package/src/components/Inputs/TextAreaInput.tsx +0 -68
  97. package/src/components/Inputs/TextInput.tsx +0 -100
  98. package/src/components/Inputs/TimeInput/TimeInput.tsx +0 -81
  99. package/src/components/List/List.tsx +0 -21
  100. package/src/components/List/ListItem.tsx +0 -70
  101. package/src/components/Loader/Loader.tsx +0 -66
  102. package/src/components/Loader/ProgressBar.tsx +0 -41
  103. package/src/components/Menu/Menu.tsx +0 -81
  104. package/src/components/Menu/MenuItem.tsx +0 -46
  105. package/src/components/Menu/NewMenu.tsx +0 -63
  106. package/src/components/Menu/hooks/useMenuPosition.tsx +0 -116
  107. package/src/components/PageComponents/ScrollableContent.tsx +0 -11
  108. package/src/components/Pullover/Pullover.tsx +0 -197
  109. package/src/components/Router/Router.tsx +0 -52
  110. package/src/components/Sidebar/AddButton.tsx +0 -22
  111. package/src/components/Sidebar/Sidebar.tsx +0 -85
  112. package/src/components/Sidebar/SidebarItem.tsx +0 -84
  113. package/src/components/Sidebar/types/ISidebar.ts +0 -28
  114. package/src/components/Table/Table.tsx +0 -258
  115. package/src/components/Table/components/columns/ColumnsList.tsx +0 -60
  116. package/src/components/Table/components/columns/TableColumnsEdit.tsx +0 -114
  117. package/src/components/Table/components/edit/TableEditRow.tsx +0 -78
  118. package/src/components/Table/components/filters/FilterItem.tsx +0 -15
  119. package/src/components/Table/components/filters/TableFilters.tsx +0 -126
  120. package/src/components/Table/components/footer/TableFooter.tsx +0 -126
  121. package/src/components/Table/components/header/TableHeader.tsx +0 -40
  122. package/src/components/Table/components/header/TableHeaderRow.tsx +0 -57
  123. package/src/components/Table/components/items/TableItemActions.tsx +0 -78
  124. package/src/components/Table/components/print/TablePrint.tsx +0 -200
  125. package/src/components/Table/components/select/TableSelect.tsx +0 -50
  126. package/src/components/Table/components/sort/TableSort.tsx +0 -75
  127. package/src/components/Table/components/templates/CreateTemplateDialog.tsx +0 -58
  128. package/src/components/Table/components/templates/TableTemplates.tsx +0 -65
  129. package/src/components/Table/components/templates/TemplatesPullover.tsx +0 -88
  130. package/src/components/Table/contexts/TableContext.tsx +0 -117
  131. package/src/components/Table/hooks/localHooks/useLocalTableColumns.tsx +0 -70
  132. package/src/components/Table/hooks/localHooks/useLocalTableData.tsx +0 -82
  133. package/src/components/Table/hooks/localHooks/useLocalTableKeyboard.ts +0 -175
  134. package/src/components/Table/hooks/localHooks/useLocalTablePagination.ts +0 -12
  135. package/src/components/Table/hooks/useTableColumns.ts +0 -34
  136. package/src/components/Table/hooks/useTableEdit.tsx +0 -140
  137. package/src/components/Table/hooks/useTableFilterFields.tsx +0 -150
  138. package/src/components/Table/hooks/useTablePagination.ts +0 -19
  139. package/src/components/Table/hooks/useTablePrint.ts +0 -83
  140. package/src/components/Table/hooks/useTableSearch.ts +0 -31
  141. package/src/components/Table/hooks/useTableSelect.ts +0 -19
  142. package/src/components/Table/hooks/useTableSort.ts +0 -8
  143. package/src/components/Tabs/Tabs.tsx +0 -68
  144. package/src/components/Tooltip/Tooltip.tsx +0 -191
  145. package/src/components/Tree/Tree.tsx +0 -22
  146. package/src/components/Tree/TreeItem.tsx +0 -57
  147. package/src/components/Wrappers/AppLayout.tsx +0 -17
  148. package/src/components/Wrappers/ConditionalWrapper.tsx +0 -10
  149. package/src/components/Wrappers/FormWrapper.tsx +0 -84
  150. package/src/components/Wrappers/PageLayout.tsx +0 -168
  151. package/src/hooks/useBackgroundClose.ts +0 -19
  152. package/src/hooks/useGetFocusableElements.ts +0 -43
  153. package/src/hooks/useIsMenuOpen.ts +0 -11
  154. package/src/hooks/useLocalPopoverControl.ts +0 -63
  155. package/src/hooks/useOnEsc.ts +0 -14
  156. package/src/hooks/usePopupControl.ts +0 -22
  157. package/src/hooks/useZendesk.ts +0 -22
  158. package/src/index.ts +0 -387
  159. package/src/pages/NoAccessPage.tsx +0 -27
  160. package/src/pages/NotFoundPage.tsx +0 -26
  161. package/src/styles/App.scss +0 -47
  162. package/src/styles/common/_animations.scss +0 -58
  163. package/src/styles/common/_typography.scss +0 -91
  164. package/src/styles/common/helpers/_base.scss +0 -55
  165. package/src/styles/common/helpers/_color.scss +0 -10
  166. package/src/styles/common/helpers/_display.scss +0 -85
  167. package/src/styles/common/helpers/_size.scss +0 -25
  168. package/src/styles/common/maps/_align.scss +0 -21
  169. package/src/styles/common/maps/_buttonMaps.scss +0 -42
  170. package/src/styles/common/maps/_info-types.scss +0 -1
  171. package/src/styles/common/maps/_spacing.scss +0 -78
  172. package/src/styles/common/maps/_text.scss +0 -14
  173. package/src/styles/components/_accordions.scss +0 -51
  174. package/src/styles/components/_alert.scss +0 -23
  175. package/src/styles/components/_badge.scss +0 -84
  176. package/src/styles/components/_button.scss +0 -99
  177. package/src/styles/components/_buttonSplit.scss +0 -74
  178. package/src/styles/components/_card.scss +0 -24
  179. package/src/styles/components/_dialog.scss +0 -119
  180. package/src/styles/components/_form.scss +0 -8
  181. package/src/styles/components/_header.scss +0 -157
  182. package/src/styles/components/_input.scss +0 -167
  183. package/src/styles/components/_inputCheckbox.scss +0 -48
  184. package/src/styles/components/_inputDateTime.scss +0 -161
  185. package/src/styles/components/_inputRadio.scss +0 -83
  186. package/src/styles/components/_inputSelect.scss +0 -8
  187. package/src/styles/components/_list.scss +0 -58
  188. package/src/styles/components/_loader.scss +0 -55
  189. package/src/styles/components/_menu-v2.scss +0 -67
  190. package/src/styles/components/_menu.scss +0 -62
  191. package/src/styles/components/_notifications.scss +0 -71
  192. package/src/styles/components/_page.scss +0 -84
  193. package/src/styles/components/_portal.scss +0 -8
  194. package/src/styles/components/_print.scss +0 -77
  195. package/src/styles/components/_progressBar.scss +0 -83
  196. package/src/styles/components/_pullover.scss +0 -95
  197. package/src/styles/components/_scrollbar.scss +0 -18
  198. package/src/styles/components/_sidebar.scss +0 -204
  199. package/src/styles/components/_smallComponents.scss +0 -23
  200. package/src/styles/components/_table.scss +0 -340
  201. package/src/styles/components/_tabs.scss +0 -33
  202. package/src/styles/components/_tooltip.scss +0 -48
  203. package/src/styles/components/_tree.scss +0 -21
  204. package/src/styles/components/_widget.scss +0 -90
  205. package/src/styles/pages/_fullScreenPage.scss +0 -64
  206. package/src/styles/variables/_bp.scss +0 -6
  207. package/src/styles/variables/_variables.scss +0 -142
  208. package/src/types/Base/custom.d.ts +0 -9
  209. package/src/types/IBasic.ts +0 -32
  210. package/src/types/ICountryCode.ts +0 -5
  211. package/src/types/IError.ts +0 -5
  212. package/src/types/IHeader.ts +0 -40
  213. package/src/types/IInfo.ts +0 -1
  214. package/src/types/IKeyboard.ts +0 -33
  215. package/src/types/IMenu.ts +0 -19
  216. package/src/types/INotifications.ts +0 -15
  217. package/src/types/IPopup.ts +0 -17
  218. package/src/types/IRouter.ts +0 -6
  219. package/src/types/ISelect.ts +0 -54
  220. package/src/types/ITab.ts +0 -10
  221. package/src/types/ITable.ts +0 -291
  222. package/src/types/ITree.ts +0 -6
  223. package/src/utils/InputPatternValidation.ts +0 -12
  224. package/src/utils/dateUtils.ts +0 -32
  225. package/src/utils/fileUtils.ts +0 -177
  226. package/src/utils/i18n/i18nIUICyrilic.ts +0 -119
  227. package/src/utils/i18n/i18nIUILatin.ts +0 -120
  228. package/src/utils/i18n/i18nIUIMe.ts +0 -118
  229. package/src/utils/icons.ts +0 -13
  230. package/src/utils/localStorageHelper.ts +0 -24
  231. package/src/utils/logoUtils.ts +0 -7
  232. package/src/utils/numberUtils.ts +0 -21
  233. package/src/utils/objectUtils.ts +0 -114
  234. package/src/utils/popupUtils.ts +0 -82
  235. package/src/utils/rootDir.ts +0 -1
  236. package/src/utils/stringUtils.ts +0 -18
  237. package/src/utils/tableUtils.ts +0 -130
  238. package/src/utils/toasts.ts +0 -6
  239. package/src/utils/urlUtils.ts +0 -4
  240. package/tsconfig.icons.json +0 -5
  241. package/tsconfig.json +0 -22
@@ -1,120 +0,0 @@
1
- export const i18nIUILatin = {
2
- ////// BASIC //////
3
- HomePage: 'Početna',
4
-
5
- // Accept: 'Prihvati',
6
- Actions: 'Akcije',
7
- Active: 'Aktivan',
8
- AddInput: 'Unesi',
9
- Back: 'Nazad',
10
- Cancel: 'Otkaži',
11
- Change: 'Promeni',
12
- Choose: 'Izaberi',
13
- Close: 'Zatvori',
14
- Confirm: 'Potvrdi',
15
- Create: 'Kreiraj',
16
- Delete: 'Obriši',
17
- Edit: 'Izmeni',
18
- FreeText: 'Slobodan unos',
19
- from: 'od',
20
- Group: 'Grupa',
21
- Groups: 'Grupe',
22
- Next: 'Dalje',
23
- No: 'Ne',
24
- Ok: 'U redu',
25
- Options: 'Opcije',
26
- or: 'ili',
27
- Save: 'Sačuvaj',
28
- Search: 'Pretraga',
29
- Selected: 'Označeno',
30
- Send: 'Pošalji',
31
- Sending: 'Slanje',
32
- Title: 'Naslov',
33
- to: 'do',
34
- Yes: 'Da',
35
- LoadingProgress: 'Učitavanje...',
36
-
37
- ////// TABLE //////
38
- RefreshData: 'Osveži podatke',
39
- allResults: 'Svi',
40
- Columns: 'Kolone',
41
- DragDropListsInfo:
42
- 'Odaberite kolone za prikazivanje prevlačenjem sa jedne liste na drugu',
43
- TableSelect: 'Akcije nad izabranim redovima',
44
- Filter: 'Filteri',
45
- ApplyFilters: 'Primeni filtere',
46
- HiddenColumns: 'Sakrivene kolone',
47
- NoResults: 'Nema rezultata',
48
- of: 'od',
49
- page: 'Strana',
50
- Print: 'Odštampaj',
51
- PrintDate: 'Datum izveštaja',
52
- PrintExport: 'Štampa/Izvoz',
53
- ResetFilter: 'Resetuj filtere',
54
- rowsPerPage: 'Broj redova',
55
- SaveXlsx: 'Sačuvaj XLSX',
56
- SelectedColumns: 'Odabrane kolone',
57
- Sort: 'Sortiranje',
58
- AddItem: 'Dodaj stavku',
59
- // TEMPLATES
60
- Templates: 'Šabloni',
61
- ApplyTemplate: 'Primeni šablon',
62
- ResetTemplate: 'Poništi šablon',
63
- DeleteTemplate: 'Obriši šablon',
64
- CreateTemplateLong: 'Sačuvaj trenutni izgled kao šablon',
65
- CreateDefaultTemplate: 'Sačuvaj trenutni izgled kao podrazumevani',
66
- CreateTemplate: 'Kreiraj šablon',
67
- TemplateName: 'Naziv šablona',
68
- NoTemplatesAvailable: `Nema dostupnih šablona.
69
- Kliknite na "Kreiraj šablon" da biste napravili šablon sa trenutno izabranim kolonama, filterima i sortiranjem.`,
70
- // SelectTemplate: 'Izaberi šablon',
71
- // TemplateList: 'Lista šablona',
72
- PublicTemplate: 'Javni šablon',
73
- // PublicTemplates: 'Javni šabloni',
74
- PrivateTemplate: 'Privatni šablon',
75
- // DefaultTemplate: 'Osnovni šabloni',
76
- // RemoveFiltersAndLook: 'Poništi izgled i filtere',
77
- // DeleteTemplateDesc: 'Da li ste sigurni da želite da izbrišete šablon?',
78
- // DeleteTemplateTitle: 'Brisanje šablona',
79
-
80
- FastLinks: 'Brzi pristup',
81
-
82
- ////// INPUTS //////
83
- CharMin: 'Minimalan broj karaktera: {{from}}',
84
- CharRange: 'Broj karaktera od {{from}} do {{-to}}',
85
- CharNumber: 'Broj karaktera {{number}}',
86
- PhoneValidation: 'Neispravan broj telefona',
87
- Serbia: 'Srbija',
88
- Montenegro: 'Crna Gora',
89
-
90
- ////// TOAST //////
91
- Pending: 'U toku',
92
- Successfully: 'Uspešno',
93
- DeletedSuccessfully: 'Uspešno obrisano',
94
- ErrorMessage: 'Došlo je do greške!',
95
- TryAgain: 'Pokušaj ponovo',
96
-
97
- ////// NOTIFICATIONS //////
98
- InApp: 'In-app',
99
- // MarkAsRead: 'Označi kao pročitano',
100
- MarkAllAsRead: 'Označi sve kao pročitano',
101
- NoNewNotifications: 'Nemate nove notifikacije',
102
- Notifications: 'Notifikacije',
103
- NotificationsAll: 'Sve',
104
- NotificationsUnread: 'Nepročitane',
105
- NotificationsRead: 'Pročitane',
106
- NotificationSound: 'Zvuk notifikacije',
107
- // NTitleADD_DOC: 'Dodat je dokument na platformu',
108
- // NContentADD_DOC: 'Dokument sa brojem <documentNumber>{{- documentNumber}}</documentNumber> je dodat na platformu',
109
-
110
- ////// PAGES //////
111
- ReturnToHomepage: 'Povratak na početnu stranu',
112
- FooterText: `Inception CA je akreditovano sertifikaciono telo za kvalifikovanu elektronsku dostavu,
113
- izdavanje vremenskih žigova, validaciju kvalifikovanog potpisa i pečata i kvalifikovano čuvanje dokumenata.`,
114
- PageNotFound: 'Stranica nije pronadjena',
115
- PageNotFoundInfo: `Stranica koju tražite nije pronadjena ili je premeštena.
116
- Možete se vratiti na početnu stranu.`,
117
- NoAccessPage: 'Nemate pristup stranici',
118
- NoAccessPageInfo: `Nemate privilegiju za pristup ovoj stranici.
119
- Za više informacija i dodelu pristupa, obratite se administratoru.`,
120
- };
@@ -1,118 +0,0 @@
1
- export const i18nIUIMe = {
2
- ////// BASIC //////
3
- HomePage: 'Početna',
4
-
5
- Actions: 'Akcije',
6
- Active: 'Aktivan',
7
- AddInput: 'Unesi',
8
- Back: 'Nazad',
9
- Cancel: 'Otkaži',
10
- Change: 'Promijeni',
11
- Choose: 'Izaberi',
12
- Close: 'Zatvori',
13
- Confirm: 'Potvrdi',
14
- Create: 'Kreiraj',
15
- Delete: 'Obriši',
16
- Edit: 'Izmijeni',
17
- FreeText: 'Slobodan unos',
18
- from: 'od',
19
- Group: 'Grupa',
20
- Groups: 'Grupe',
21
- Next: 'Dalje',
22
- No: 'Ne',
23
- Ok: 'U redu',
24
- Options: 'Opcije',
25
- or: 'ili',
26
- Save: 'Sačuvaj',
27
- Search: 'Pretraga',
28
- Selected: 'Odabrano',
29
- Send: 'Pošalji',
30
- Sending: 'Slanje',
31
- Title: 'Naslov',
32
- to: 'do',
33
- Yes: 'Da',
34
- LoadingProgress: 'Učitavanje...',
35
-
36
- ////// TABLE //////
37
- RefreshData: 'Osvježi podatke',
38
- allResults: 'Svi',
39
- Columns: 'Kolone',
40
- DragDropListsInfo: 'Izaberite kolone za prikaz prevlačenjem sa jedne liste na drugu',
41
- TableSelect: 'Akcije nad izabranim redovima',
42
- Filter: 'Filteri',
43
- ApplyFilters: 'Primijeni filtere',
44
- HiddenColumns: 'Skrivene kolone',
45
- NoResults: 'Nema rezultata',
46
- of: 'od',
47
- page: 'Strana',
48
- Print: 'Odštampaj',
49
- PrintDate: 'Datum izvještaja',
50
- PrintExport: 'Štampa/Izvoz',
51
- ResetFilter: 'Resetuj filtere',
52
- rowsPerPage: 'Broj redova',
53
- SaveXlsx: 'Sačuvaj XLSX',
54
- SelectedColumns: 'Odabrane kolone',
55
- Sort: 'Sortiranje',
56
- AddItem: 'Dodaj stavku',
57
-
58
- // TEMPLATES
59
- Templates: 'Šabloni',
60
- ApplyTemplate: 'Primijeni šablon',
61
- ResetTemplate: 'Poništi šablon',
62
- DeleteTemplate: 'Obriši šablon',
63
- CreateTemplateLong: 'Sačuvaj trenutni izgled kao šablon',
64
- CreateDefaultTemplate: 'Sačuvaj trenutni izgled kao podrazumijevani',
65
- CreateTemplate: 'Kreiraj šablon',
66
- TemplateName: 'Naziv šablona',
67
- NoTemplatesAvailable: `Nema dostupnih šablona.
68
- Kliknite na "Kreiraj šablon" da biste napravili šablon sa trenutno izabranim kolonama, filterima i sortiranjem.`,
69
- // SelectTemplate: 'Izaberi šablon',
70
- // TemplateList: 'Lista šablona',
71
- PublicTemplate: 'Javni šablon',
72
- // PublicTemplates: 'Javni šabloni',
73
- PrivateTemplate: 'Privatni šablon',
74
- // DefaultTemplate: 'Osnovni šabloni',
75
- // RemoveFiltersAndLook: 'Poništi izgled i filtere',
76
- // DeleteTemplateDesc: 'Da li ste sigurni da želite da izbrišete šablon?',
77
- // DeleteTemplateTitle: 'Brisanje šablona',
78
-
79
- FastLinks: 'Brzi linkovi',
80
-
81
- ////// INPUTS //////
82
- CharMin: 'Minimalan broj karaktera: {{from}}',
83
- CharRange: 'Broj karaktera od {{from}} do {{-to}}',
84
- CharNumber: 'Broj karaktera {{number}}',
85
- PhoneValidation: 'Neispravan broj telefona',
86
- Serbia: 'Srbija',
87
- Montenegro: 'Crna Gora',
88
-
89
- ////// TOAST //////
90
- Pending: 'U toku',
91
- Successfully: 'Uspješno',
92
- DeletedSuccessfully: 'Uspješno obrisano',
93
- ErrorMessage: 'Došlo je do greške!',
94
- TryAgain: 'Pokušajte ponovo',
95
-
96
- ////// NOTIFICATIONS //////
97
- InApp: 'In-app',
98
- MarkAllAsRead: 'Označi sve kao pročitano',
99
- NoNewNotifications: 'Nemate nove notifikacije',
100
- Notifications: 'Notifikacije',
101
- NotificationsAll: 'Sve',
102
- NotificationsUnread: 'Nepročitane',
103
- NotificationsRead: 'Pročitane',
104
- NotificationSound: 'Zvuk notifikacije',
105
- // NTitleADD_DOC: 'Dodat je dokument na platformu',
106
- // NContentADD_DOC: 'Dokument sa brojem <documentNumber>{{- documentNumber}}</documentNumber> je dodat na platformu',
107
-
108
- ////// PAGES //////
109
- ReturnToHomepage: 'Povratak na početnu stranicu',
110
- FooterText: '',
111
-
112
- PageNotFound: 'Stranica nije pronađena',
113
- PageNotFoundInfo: `Stranica koju tražite nije pronađena ili je premještena.
114
- Možete se vratiti na početnu stranicu.`,
115
- NoAccessPage: 'Nemate pristup stranici',
116
- NoAccessPageInfo: `Nemate privilegiju za pristup ovoj stranici.
117
- Za više informacija i dodjelu pristupa, obratite se administratoru.`,
118
- };
@@ -1,13 +0,0 @@
1
- import type { IconDefinition } from '@fortawesome/fontawesome-svg-core';
2
- import type { IInfoType } from '../types/IInfo';
3
- import { faCircleCheck } from '../assets/icons/regular/faCircleCheck';
4
- import { faCircleExclamation } from '../assets/icons/regular/faCircleExclamation';
5
- import { faCircleInfo } from '../assets/icons/regular/faCircleInfo';
6
- import { faTriangleExclamation } from '../assets/icons/regular/faTriangleExclamation';
7
-
8
- export const infoIcons: Record<IInfoType, IconDefinition> = {
9
- info: faCircleInfo,
10
- success: faCircleCheck,
11
- warning: faTriangleExclamation,
12
- danger: faCircleExclamation,
13
- };
@@ -1,24 +0,0 @@
1
- type LocalStorageItem =
2
- | 'activeUser'
3
- | 'token'
4
- | 'refreshToken'
5
- | 'logInWay'
6
- | 'nextUrl'
7
- | 'codeVerifier'
8
- | 'language';
9
-
10
- export const lsGet = (key: LocalStorageItem) => localStorage.getItem(key);
11
- export const lsSet = (key: LocalStorageItem, value: string) =>
12
- localStorage.setItem(key, value);
13
- export const lsRemove = (key: LocalStorageItem) => localStorage.removeItem(key);
14
-
15
- // Organization
16
-
17
- export const getDefaultOrgUuid = () =>
18
- localStorage.getItem(`${lsGet('activeUser')}-defaultOrg`) as string;
19
- export const setDefaultOrgUuid = (organizationUuid: string) =>
20
- localStorage.setItem(`${lsGet('activeUser')}-defaultOrg`, organizationUuid);
21
- export const getActiveOrgUuid = () =>
22
- localStorage.getItem(`${lsGet('activeUser')}-activeOrg`) as string;
23
- export const setActiveOrgUuid = (organizationUuid: string) =>
24
- localStorage.setItem(`${lsGet('activeUser')}-activeOrg`, organizationUuid);
@@ -1,7 +0,0 @@
1
- import INC from '../assets/images/logo/inception.svg';
2
- import MTS from '../assets/images/logo/mts.svg';
3
- import PPL from '../assets/images/logo/paperless.svg';
4
-
5
- export type IOrgLogo = 'MTS' | 'PPL' | 'INC';
6
-
7
- export const orgLogo: Record<IOrgLogo, string> = { MTS, PPL, INC };
@@ -1,21 +0,0 @@
1
- // export const toNumberOrZero = (value?: string | number) => (!!value ? +value : 0);
2
-
3
- export const formatCurrency = (
4
- number?: string | number,
5
- minimumFractionDigits?: number,
6
- maximumFractionDigits?: number
7
- ) =>
8
- Number(number ?? 0).toLocaleString('sr-RS', {
9
- minimumFractionDigits: minimumFractionDigits ?? 2,
10
- maximumFractionDigits: maximumFractionDigits ?? minimumFractionDigits ?? 2,
11
- });
12
-
13
- export const formatCurrencyNoDecimals = (number?: string | number) =>
14
- // number?.toString().replace(',', '.') ?? 0;
15
- Number(number ?? 0).toLocaleString('sr-RS');
16
-
17
- export const formatDecimalNumber = (number?: string | number) =>
18
- number?.toString().replace('.', ',') ?? 0;
19
-
20
- // export const roundTwoDecimals = (value?: string | number) =>
21
- // !!value ? Math.round(+value * 100) / 100 : 0;
@@ -1,114 +0,0 @@
1
- import type { TFunction } from 'i18next';
2
- import type { IBooleanObject } from '../types/IBasic';
3
- import type { INotification } from '../types/INotifications';
4
- import { formatDate, formatDateAndTime } from './dateUtils';
5
-
6
- export const hasValue = (value: any) => ![null, undefined, ''].includes(value);
7
-
8
- export const deleteProps = <T extends Record<string, any>>(
9
- obj: T,
10
- props: (keyof T)[]
11
- ) => {
12
- const newObj = { ...obj };
13
- props.forEach(prop => delete newObj[prop]);
14
- return newObj as Partial<T>;
15
- };
16
-
17
- export const deletePropsThatEndsWith = <T>(obj: T, endsWith: string) => {
18
- const newObj = { ...obj };
19
- for (const prop in newObj) {
20
- if (prop.endsWith(endsWith)) {
21
- delete newObj[prop];
22
- }
23
- }
24
- return newObj as Partial<T>;
25
- };
26
-
27
- export const deleteEmptyProps = <T extends Record<string, any>>(obj: T): T =>
28
- Object.entries(obj).reduce(
29
- (updatedObj, [key, value]) =>
30
- hasValue(value) ? ((updatedObj[key as keyof T] = value), updatedObj) : updatedObj,
31
- {} as T
32
- );
33
-
34
- export const deleteEmptyPropsIncludingArray = <T extends Record<string, any>>(
35
- obj: T
36
- ): T =>
37
- Object.entries(obj).reduce(
38
- (updatedObj, [key, value]) =>
39
- !hasValue(value) || (Array.isArray(value) && !value.length)
40
- ? updatedObj
41
- : ((updatedObj[key as keyof T] = value), updatedObj),
42
- {} as T
43
- );
44
-
45
- export const convertBooleanObjectToArray = (obj: IBooleanObject) =>
46
- Object.keys(obj).filter(key => obj[key]);
47
-
48
- export const convertArrayToBooleanObject = (arr?: string[]) =>
49
- arr ? arr.reduce((acc: IBooleanObject, item) => ({ ...acc, [item]: true }), {}) : {};
50
-
51
- export const deepCopy = (el: any[] | object) => JSON.parse(JSON.stringify(el));
52
-
53
- export const areStringArraysEqual = (arr1: string[], arr2: string[]) =>
54
- JSON.stringify(arr1) === JSON.stringify(arr2);
55
-
56
- export const compareArrayItemsIndex = <T>(
57
- array: T[] | readonly T[],
58
- item1: T,
59
- comparison: 'greaterThan' | 'greaterThanOrEqualTo' | 'lessThan' | 'lessThanOrEqualTo',
60
- item2: T
61
- ): boolean => {
62
- const index1 = array.indexOf(item1);
63
- const index2 = array.indexOf(item2);
64
- return (
65
- // Check if items exist in array
66
- index1 >= 0 &&
67
- index2 >= 0 &&
68
- // Compare items location in the array
69
- (comparison === 'greaterThan'
70
- ? index1 > index2
71
- : comparison === 'greaterThanOrEqualTo'
72
- ? index1 >= index2
73
- : comparison === 'lessThan'
74
- ? index1 < index2
75
- : index1 <= index2)
76
- );
77
- };
78
-
79
- export const intersectArrays = <T>(
80
- arr1: any[] | readonly T[],
81
- arr2: any[] | readonly T[]
82
- ) => {
83
- const set2 = new Set(arr2);
84
- return (arr1 as T[]).filter(item => set2.has(item));
85
- };
86
-
87
- export const getNotificationValues = (
88
- t: TFunction,
89
- notificationValues?: INotification['values']
90
- ) =>
91
- notificationValues?.reduce((obj, item) => {
92
- let processedValue = item.value;
93
- if (item.format === 'TRANSLATE') {
94
- processedValue = t(processedValue);
95
- } else if (item.format === 'DATE') {
96
- processedValue = formatDate(processedValue);
97
- } else if (item.format === 'DATE_TIME') {
98
- processedValue = formatDateAndTime(processedValue);
99
- }
100
- return { ...obj, [item.key]: processedValue };
101
- }, {});
102
-
103
- export const flattenTreeForSelect = (items: any[], depth = 0, maxDepth = 5): any[] => {
104
- if (!Array.isArray(items)) return [];
105
- const indent = '\u00A0'.repeat(Math.min(depth, maxDepth) * 3);
106
- return items.flatMap(node => [
107
- {
108
- value: node.uuid,
109
- label: `${indent}${node.code ? node.code + ' - ' : ''}${node.name}`,
110
- disabled: node.active === false || node.hasUserAccess === false,
111
- },
112
- ...(node.children ? flattenTreeForSelect(node.children, depth + 1, maxDepth) : []),
113
- ]);
114
- };
@@ -1,82 +0,0 @@
1
- import type { KeyboardEvent } from 'react';
2
- import type { IKeyboardAction } from '../types/IKeyboard';
3
-
4
- export const onPopupKeyDown = (
5
- event: KeyboardEvent<HTMLDivElement>,
6
- {
7
- onClose,
8
- enter,
9
- search,
10
- focusableElements,
11
- }: {
12
- onClose: () => void;
13
- enter?: {
14
- onAction: () => void;
15
- disabled?: boolean;
16
- };
17
- search?: {
18
- onAction: () => void;
19
- disabled?: boolean;
20
- };
21
- focusableElements?: HTMLElement[];
22
- }
23
- ) => {
24
- event.stopPropagation();
25
- const actions: IKeyboardAction[] = [
26
- {
27
- code: 'Enter',
28
- onAction: () => enter?.onAction(),
29
- disabled: !enter || !!enter.disabled,
30
- },
31
- { code: 'Escape', onAction: onClose },
32
- {
33
- code: 'KeyF',
34
- ctrl: true,
35
- onAction: () => {
36
- event.preventDefault();
37
- search?.onAction();
38
- },
39
- disabled: !search || !!search.disabled,
40
- },
41
- {
42
- code: 'Tab',
43
- onAction: () => {
44
- if (focusableElements?.length) {
45
- const first = focusableElements[0];
46
- const last = focusableElements[focusableElements.length - 1];
47
- if (document.activeElement === last) {
48
- event.preventDefault();
49
- first.focus();
50
- }
51
- }
52
- },
53
- disabled: !focusableElements?.length,
54
- },
55
- {
56
- code: 'Tab',
57
- shift: true,
58
- onAction: () => {
59
- if (focusableElements?.length) {
60
- const first = focusableElements[0];
61
- const last = focusableElements[focusableElements.length - 1];
62
- if (document.activeElement === first) {
63
- event.preventDefault();
64
- last.focus();
65
- }
66
- }
67
- },
68
- disabled: !focusableElements?.length,
69
- },
70
- ];
71
-
72
- actions.forEach(item => {
73
- if (
74
- !item.disabled &&
75
- item.code === event.code &&
76
- !!item.shift === event.shiftKey &&
77
- !!item.ctrl === (event.ctrlKey || event.metaKey)
78
- ) {
79
- item.onAction();
80
- }
81
- });
82
- };
@@ -1 +0,0 @@
1
- export const rootDir = (document.getElementById('root') as HTMLElement) ?? document.body;
@@ -1,18 +0,0 @@
1
- export const maxChar = (str = '', maxLength = 30) =>
2
- str.length > maxLength ? `${str.substring(0, maxLength)}...` : str;
3
-
4
- export const getInputHelperText = (
5
- t: any,
6
- min?: string | number,
7
- max?: string | number
8
- ) =>
9
- max
10
- ? min === max
11
- ? t('CharNumber', { number: min })
12
- : t('CharRange', { from: min || 1, to: max })
13
- : min
14
- ? t('CharMin', { from: min })
15
- : undefined;
16
-
17
- export const getInputMinMaxPattern = (min?: string | number, max?: string | number) =>
18
- `^.{${min || 0},${max || ''}}$`;
@@ -1,130 +0,0 @@
1
- import type { IAnyObject } from '../types/IBasic';
2
- import type {
3
- IReportTemplate,
4
- IReportTemplateFilterValue,
5
- ITableColumn,
6
- ITableColumnsData,
7
- } from '../types/ITable';
8
-
9
- // FILTERS
10
- export const getActiveFilterNumber = (obj: IAnyObject) => Object.keys(obj).length;
11
-
12
- // COLUMNS
13
- export const getVisibleColumnsIds = (tableCols: ITableColumn[], isPrint?: boolean) =>
14
- tableCols.reduce(
15
- (arr: string[], col) =>
16
- col.hidden ||
17
- col.unavailable ||
18
- (isPrint && ['select', 'icons', 'actions'].includes(col.id))
19
- ? arr
20
- : arr.concat(col.id),
21
- []
22
- );
23
-
24
- export const getVisibleColumnsFromList = (
25
- tableCols: ITableColumn[],
26
- visibleColumns: string[]
27
- ) =>
28
- tableCols
29
- .map(e =>
30
- visibleColumns.includes(e.id) ? { ...e, hidden: false } : { ...e, hidden: true }
31
- )
32
- .sort((e, f) =>
33
- visibleColumns.indexOf(e.id) < visibleColumns.indexOf(f.id) ? -1 : 1
34
- );
35
-
36
- export const getPrintColumns = (tableCols: ITableColumn[]) =>
37
- tableCols.reduce(
38
- (arr: string[], col) => (col.hidden || col.unavailable ? arr : arr.concat(col.id)),
39
- []
40
- );
41
-
42
- // TEMPLATES
43
- export const convertSearchToReportTemplateFilter = (search: IAnyObject) =>
44
- Object.entries(search)
45
- .map(e =>
46
- typeof e[1] === 'object'
47
- ? Array.isArray(e[1])
48
- ? { filter: e[0], type: 'ARRAY', value: JSON.stringify(e[1]) }
49
- : {
50
- filter: e[0],
51
- type: 'OBJECT',
52
- value: e[1].value,
53
- name: e[1].label as string,
54
- // value: e[1].uuid,
55
- // name: (e[1].label ?? e[1].name) as string,
56
- }
57
- : {
58
- filter: e[0],
59
- type: typeof e[1] === 'boolean' ? 'BOOLEAN' : 'STRING',
60
- value: e[1],
61
- }
62
- )
63
- .filter(
64
- e => ![null, undefined, ''].includes(e.value)
65
- ) as IReportTemplateFilterValue[];
66
-
67
- export const convertReportTemplateFilterToSearch = (
68
- filterValues: IReportTemplateFilterValue[]
69
- ) => {
70
- let search: any = {};
71
- filterValues?.forEach(template => {
72
- search[template.filter] =
73
- template.type === 'OBJECT'
74
- ? {
75
- value: template.value,
76
- label: template.name,
77
- }
78
- : template.type === 'ARRAY'
79
- ? JSON.parse(template.value)
80
- : template.type === 'BOOLEAN'
81
- ? template.value === 'true'
82
- : template.value;
83
- });
84
- return search;
85
- };
86
-
87
- export const setTemplateData = ({
88
- template,
89
- columnData,
90
- setFilters,
91
- setSort,
92
- }: {
93
- template: IReportTemplate;
94
- columnData?: ITableColumnsData;
95
- setFilters?: (filters: IAnyObject) => void;
96
- setSort?: (sort: string) => void;
97
- }) => {
98
- const newFilters =
99
- template.filterValues && convertReportTemplateFilterToSearch(template.filterValues);
100
- newFilters && setFilters?.(newFilters);
101
- columnData &&
102
- columnData.setColumns?.(
103
- getVisibleColumnsFromList(columnData.defaultColumns, template.columns)
104
- );
105
- template.sorts && setSort && setSort(template.sorts[0]);
106
- };
107
-
108
- export const scrollToRow = (uuid: string) => {
109
- const rowElement = document.querySelector(`[data-id="${uuid}"]`) as HTMLTableRowElement;
110
-
111
- if (!rowElement) {
112
- return;
113
- }
114
-
115
- // rowElement.scrollIntoView({
116
- // behavior: 'smooth',
117
- // block: 'nearest',
118
- // });
119
-
120
- const tableContainer = rowElement?.closest('.table-container') as HTMLElement;
121
- const tableHeadHeight =
122
- tableContainer.querySelector('thead')?.getBoundingClientRect().height || 0;
123
- const rowTop = rowElement.offsetTop;
124
- const scrollTopTarget = Math.max(0, rowTop - tableHeadHeight);
125
-
126
- tableContainer.scrollTo({
127
- top: scrollTopTarget,
128
- behavior: 'smooth',
129
- });
130
- };
@@ -1,6 +0,0 @@
1
- import { toast } from 'react-toastify';
2
-
3
- export const toastSuccess = (message: string) => toast.success(message);
4
- export const toastError = (message: string) => toast.error(message, { autoClose: false });
5
- // export const toastInfo = (message: string) => toast.info(message);
6
- // export const toastWarn = (message: string) => toast.warn(message);
@@ -1,4 +0,0 @@
1
- export const parseUrlSearch = (search: string) => {
2
- const urlSearchParams = new URLSearchParams(search);
3
- return Object.fromEntries(urlSearchParams.entries());
4
- };
@@ -1,5 +0,0 @@
1
- {
2
- "extends": "./tsconfig.json",
3
- "include": ["src/assets/icons"],
4
- "exclude": ["node_modules", "dist"]
5
- }