@inceptionbg/iui 1.0.4 → 1.0.6

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 (107) hide show
  1. package/dist/index.css +1 -0
  2. package/dist/index.d.ts +407 -0
  3. package/dist/index.js +269 -0
  4. package/dist/index.js.map +1 -0
  5. package/package.json +6 -6
  6. package/src/index.ts +42 -42
  7. package/src/Elements/Accordions/Accordions.tsx +0 -63
  8. package/src/Elements/Alert/Alert.tsx +0 -31
  9. package/src/Elements/Alert/alert.scss +0 -36
  10. package/src/Elements/Button/Button.tsx +0 -55
  11. package/src/Elements/Button/IconButton.tsx +0 -42
  12. package/src/Elements/Button/button.scss +0 -97
  13. package/src/Elements/Dialog/Dialog.tsx +0 -175
  14. package/src/Elements/Helper/Collapse.tsx +0 -39
  15. package/src/Elements/Helper/NoAccessInfo.tsx +0 -195
  16. package/src/Elements/Tooltip/Tooltip.tsx +0 -116
  17. package/src/Elements/Tooltip/tooltip.scss +0 -46
  18. package/src/Elements/Wrappers/ConditionalWrapper.tsx +0 -10
  19. package/src/Elements/Wrappers/FormWrapper.tsx +0 -67
  20. package/src/Elements/Wrappers/FullPageWrapper.tsx +0 -87
  21. package/src/icons/duotone/faArrowLeftFromLine.ts +0 -17
  22. package/src/icons/duotone/faArrowRightToLine.ts +0 -17
  23. package/src/icons/duotone/faBell.ts +0 -17
  24. package/src/icons/duotone/faEye.ts +0 -17
  25. package/src/icons/duotone/faEyeSlash.ts +0 -17
  26. package/src/icons/duotone/faHouseHeart.ts +0 -17
  27. package/src/icons/duotone/faPlusCircle.ts +0 -18
  28. package/src/icons/duotone/faUser.ts +0 -18
  29. package/src/icons/duotone/index.ts +0 -19
  30. package/src/icons/light/faAngleDown.ts +0 -15
  31. package/src/icons/light/faArrowDownShortWide.ts +0 -15
  32. package/src/icons/light/faArrowDownWideShort.ts +0 -15
  33. package/src/icons/light/faArrowsToLine.ts +0 -15
  34. package/src/icons/light/faArrowsUpDown.ts +0 -15
  35. package/src/icons/light/faBell.ts +0 -15
  36. package/src/icons/light/faCheck.ts +0 -15
  37. package/src/icons/light/faClockRotateLeft.ts +0 -15
  38. package/src/icons/light/faEllipsisVertical.ts +0 -15
  39. package/src/icons/light/faXmark.ts +0 -15
  40. package/src/icons/light/index.ts +0 -23
  41. package/src/icons/regular/faArrowRightArrowLeft.ts +0 -15
  42. package/src/icons/regular/faCalendar.ts +0 -15
  43. package/src/icons/regular/faCircleCheck.ts +0 -15
  44. package/src/icons/regular/faCircleExclamation.ts +0 -15
  45. package/src/icons/regular/faCircleInfo.ts +0 -15
  46. package/src/icons/regular/faFileArrowDown.ts +0 -15
  47. package/src/icons/regular/faFilterCircleXmark.ts +0 -15
  48. package/src/icons/regular/faTriangleExclamation.ts +0 -15
  49. package/src/icons/solid/faAngleLeft.ts +0 -15
  50. package/src/icons/solid/faAngleRight.ts +0 -15
  51. package/src/icons/solid/faArrowDownWideShort.ts +0 -15
  52. package/src/icons/solid/faArrowLeft.ts +0 -15
  53. package/src/icons/solid/faEllipsisVertical.ts +0 -15
  54. package/src/icons/solid/faFilter.ts +0 -15
  55. package/src/icons/solid/faGripDotsVertical.ts +0 -15
  56. package/src/icons/solid/faListUl.ts +0 -15
  57. package/src/icons/solid/faMagnifyingGlass.ts +0 -15
  58. package/src/icons/solid/faPrint.ts +0 -15
  59. package/src/icons/solid/faRotateRight.ts +0 -15
  60. package/src/icons/solid/faXmark.ts +0 -15
  61. package/src/styles/App.scss +0 -25
  62. package/src/styles/iui/common/_animations.scss +0 -56
  63. package/src/styles/iui/common/_typography.scss +0 -76
  64. package/src/styles/iui/common/_variables.scss +0 -56
  65. package/src/styles/iui/common/helpers/_base.scss +0 -32
  66. package/src/styles/iui/common/helpers/_color.scss +0 -7
  67. package/src/styles/iui/common/helpers/_display.scss +0 -54
  68. package/src/styles/iui/common/helpers/_size.scss +0 -17
  69. package/src/styles/iui/common/maps/_align.scss +0 -24
  70. package/src/styles/iui/common/maps/_spacing.scss +0 -78
  71. package/src/styles/iui/components/_accordions.scss +0 -47
  72. package/src/styles/iui/components/_badge.scss +0 -52
  73. package/src/styles/iui/components/_card.scss +0 -24
  74. package/src/styles/iui/components/_dialog.scss +0 -75
  75. package/src/styles/iui/components/_header.scss +0 -22
  76. package/src/styles/iui/components/_input.scss +0 -225
  77. package/src/styles/iui/components/_loader.scss +0 -93
  78. package/src/styles/iui/components/_menu.scss +0 -44
  79. package/src/styles/iui/components/_notifications.scss +0 -86
  80. package/src/styles/iui/components/_page.scss +0 -50
  81. package/src/styles/iui/components/_pagePrelogin.scss +0 -66
  82. package/src/styles/iui/components/_portal.scss +0 -8
  83. package/src/styles/iui/components/_print.scss +0 -92
  84. package/src/styles/iui/components/_scrollbar.scss +0 -18
  85. package/src/styles/iui/components/_selectInput.scss +0 -15
  86. package/src/styles/iui/components/_sidebar.scss +0 -171
  87. package/src/styles/iui/components/_smallComponents.scss +0 -24
  88. package/src/styles/iui/components/_table.scss +0 -207
  89. package/src/styles/iui/components/_tabs.scss +0 -94
  90. package/src/styles/iui.scss +0 -28
  91. package/src/styles/red-variables.scss +0 -9
  92. package/src/types/IBasic.ts +0 -31
  93. package/src/types/IError.ts +0 -4
  94. package/src/types/IHeaderAction.ts +0 -12
  95. package/src/types/ISelect.ts +0 -6
  96. package/src/types/ISidebar.ts +0 -29
  97. package/src/types/ITab.ts +0 -10
  98. package/src/types/ITable.ts +0 -210
  99. package/src/types/custom.d.ts +0 -9
  100. package/src/utils/DateUtils.ts +0 -30
  101. package/src/utils/NumberUtils.ts +0 -21
  102. package/src/utils/ObjectUtils.ts +0 -49
  103. package/src/utils/StringUtils.ts +0 -2
  104. package/src/utils/Toasts.ts +0 -6
  105. package/src/utils/icons.ts +0 -11
  106. package/src/utils/index.ts +0 -41
  107. package/tsconfig.json +0 -20
@@ -1,207 +0,0 @@
1
- table {
2
- border-spacing: 0px;
3
- border-collapse: collapse;
4
- }
5
- .iui-table {
6
- overflow-x: auto;
7
- padding-top: 10px;
8
-
9
- //// Header ////
10
-
11
- th {
12
- border-bottom: $table-border;
13
- font-size: $fs-m;
14
- &:last-child {
15
- .vertical-separator {
16
- display: none;
17
- }
18
- }
19
- }
20
- .vertical-separator {
21
- height: 14px;
22
- width: 2px;
23
- background-color: #00000030;
24
- }
25
-
26
- //// Body ////
27
-
28
- tbody.no-last-border tr:last-child td {
29
- border: none;
30
- }
31
- // Row
32
- tr {
33
- margin-bottom: 2px;
34
- &.clickable:hover,
35
- &.selected {
36
- background-color: rgba(0, 0, 0, 0.05);
37
- }
38
- &.loading {
39
- opacity: 0.5;
40
- pointer-events: none;
41
- }
42
- }
43
- // Cell
44
- td {
45
- height: 52px;
46
- padding: 7px 16px;
47
- font-size: $fs-m;
48
- box-sizing: border-box;
49
- border-bottom: $table-border;
50
- }
51
- .clickable-column:hover {
52
- background-color: var(--primary-o10) !important;
53
- }
54
-
55
- //// Footer ////
56
-
57
- .table-footer {
58
- display: flex;
59
- align-items: center;
60
- width: 100%;
61
- }
62
- .pagination {
63
- display: flex;
64
- align-items: center;
65
- color: rgba(0, 0, 0, 0.8);
66
- @media screen and (max-width: 850px) {
67
- flex-direction: column;
68
- align-items: end;
69
- }
70
- select {
71
- color: rgba(0, 0, 0, 0.8);
72
- background: none;
73
- border: none;
74
- text-align: right;
75
- cursor: pointer;
76
- padding: 0 8px;
77
- user-select: none;
78
- margin-left: 8px;
79
- margin-right: 16px;
80
- }
81
- .offset-button {
82
- margin: 0 4px;
83
- padding: 10px;
84
- svg {
85
- height: 15px;
86
- width: 15px;
87
- }
88
- }
89
- .offset-input {
90
- width: 30px;
91
- border: none;
92
- border-bottom: 1px solid rgba(0, 0, 0, 0.3);
93
- background: none;
94
- text-align: center;
95
- padding: 5px 0;
96
- }
97
- }
98
-
99
- @media #{$portrait} {
100
- tbody,
101
- tr {
102
- display: block;
103
- }
104
- tr {
105
- padding: 20px 0;
106
- }
107
- td {
108
- display: flex;
109
- align-items: center;
110
- height: unset !important;
111
- text-align: left;
112
- }
113
- thead {
114
- display: none;
115
- }
116
- tbody tr td {
117
- &:before {
118
- content: attr(data-th);
119
- font-weight: bold;
120
- text-align: left;
121
- padding-right: 10px;
122
- }
123
- }
124
- }
125
- }
126
-
127
- .iui-table-filter {
128
- .iui-dialog-content {
129
- padding: 0;
130
- margin: 8px 0;
131
- }
132
- .table-filter-item {
133
- display: flex;
134
- align-items: center;
135
- justify-content: space-between;
136
- padding: 8px 16px;
137
- .label {
138
- width: 150px;
139
- }
140
- .field {
141
- display: inline-flex;
142
- margin: 0 8px;
143
- width: 100%;
144
- }
145
- }
146
- }
147
-
148
- .dual-list-container {
149
- .dual-list-content {
150
- display: grid;
151
- grid-template-columns: 1fr auto 1fr;
152
- }
153
- .list-box {
154
- border: $table-border;
155
- border-radius: 16px;
156
- padding: 10px;
157
- user-select: none;
158
- & > .item {
159
- display: flex;
160
- justify-content: space-between;
161
- align-items: center;
162
- padding: 8px;
163
- svg {
164
- color: rgba(0, 0, 0, 0.6);
165
- margin-left: 1rem;
166
- }
167
- &:hover {
168
- background-color: var(--primary-o10);
169
- }
170
- &:active {
171
- background-color: var(--primary-o25);
172
- }
173
- }
174
- }
175
- .exchange-icon {
176
- display: flex;
177
- align-items: center;
178
- margin: 0 10px;
179
- svg {
180
- height: 20px;
181
- width: 20px;
182
- }
183
- }
184
- }
185
-
186
- .edit-row {
187
- background: #3d497714;
188
- td {
189
- padding: 0 3px !important;
190
- }
191
- input {
192
- background: white;
193
- }
194
- }
195
-
196
- .table-options-btn {
197
- background: var(--background-dark);
198
- border-radius: 4px;
199
- font-weight: 700;
200
- &:hover {
201
- background-color: #dfe1eb !important;
202
- }
203
- svg {
204
- height: 12px;
205
- width: 12px;
206
- }
207
- }
@@ -1,94 +0,0 @@
1
- .iui-tabs {
2
- display: flex;
3
- overflow: auto;
4
- &::-webkit-scrollbar {
5
- height: 5px;
6
- }
7
- }
8
- .iui-tab {
9
- display: flex;
10
- align-items: center;
11
- user-select: none;
12
- color: rgba(0, 0, 0, 0.87);
13
- font-size: 13px;
14
- font-weight: 500;
15
- padding: 15px 12px;
16
- margin-bottom: 2px;
17
- &.selected,
18
- &:hover:not(.disabled) {
19
- border-bottom: 7px solid var(--primary);
20
- padding-bottom: 8px;
21
- svg {
22
- color: var(--primary);
23
- }
24
- }
25
- svg {
26
- margin-right: 6px;
27
- font-size: 15px;
28
- }
29
- }
30
- .iui-tab-content {
31
- background: #fff;
32
- box-shadow: $container-shadow;
33
- border-radius: $container-radius-bottom;
34
- padding: 8px;
35
- }
36
-
37
- // .iui-tabs {
38
- // display: flex;
39
- // overflow: auto;
40
- // padding: 0 5px;
41
- // // transform: rotateX(180deg);
42
- // &::-webkit-scrollbar {
43
- // height: 5px;
44
- // }
45
- // }
46
- // .iui-tab-content {
47
- // background-color: rgb(255, 255, 255);
48
- // box-shadow: $container-shadow;
49
- // border-radius: $container-radius-bottom;
50
- // padding: 24px;
51
- // margin: -1px 5px 0 5px;
52
- // }
53
- // .iui-tab {
54
- // // transform: rotateX(180deg);
55
- // display: flex;
56
- // align-items: center;
57
- // user-select: none;
58
- // color: rgba(0, 0, 0, 0.87);
59
- // font-size: 13px;
60
- // font-weight: 500;
61
- // padding: 15px 12px;
62
- // opacity: 0.6;
63
- // box-sizing: border-box;
64
- // // background-color: #fff;
65
- // &.selected {
66
- // opacity: 1;
67
- // background-color: #fff;
68
- // box-shadow: 0px 0px 5px rgba(180, 177, 177, 0.5);
69
- // // border-left: 1px solid #ddd;
70
- // // border-right: 1px solid #ddd;
71
- // border-top: 4px solid var(--primary);
72
- // border-bottom: none;
73
- // // border-top-left-radius: 10px;
74
- // // border-top-right-radius: 10px;
75
- // }
76
- // &:hover:not(.disabled):not(.selected) {
77
- // opacity: 1;
78
- // border-top: 4px solid var(--primary);
79
- // padding: 11px 12px 15px;
80
- // // border-bottom: 7px solid var(--primary);
81
- // // padding-bottom: 8px;
82
- // svg {
83
- // color: var(--primary);
84
- // }
85
- // }
86
- // &.disabled {
87
- // background-color: #ddd;
88
- // }
89
- // svg {
90
- // color: var(--primary);
91
- // margin-right: 6px;
92
- // font-size: 15px;
93
- // }
94
- // }
@@ -1,28 +0,0 @@
1
- @import "./iui/common/variables";
2
- @import "./iui/common/typography";
3
- @import "./iui/common/animations";
4
- @import "./iui/common/maps/align";
5
- @import "./iui/common/maps/spacing";
6
- @import "./iui/common/helpers/base";
7
- @import "./iui/common/helpers/color";
8
- @import "./iui/common/helpers/display";
9
- @import "./iui/common/helpers/size";
10
-
11
- @import "./iui/components/accordions";
12
- @import "./iui/components/badge";
13
- @import "./iui/components/card";
14
- @import "./iui/components/dialog";
15
- @import "./iui/components/header";
16
- @import "./iui/components/input";
17
- @import "./iui/components/loader";
18
- @import "./iui/components/menu";
19
- @import "./iui/components/notifications";
20
- @import "./iui/components/page";
21
- @import "./iui/components/portal";
22
- @import "./iui/components/print";
23
- @import "./iui/components/scrollbar";
24
- @import "./iui/components/selectInput";
25
- @import "./iui/components/sidebar";
26
- @import "./iui/components/smallComponents";
27
- @import "./iui/components/table";
28
- @import "./iui/components/tabs";
@@ -1,9 +0,0 @@
1
- :root {
2
- --primary: rgb(var(--primary-rgb));
3
- --primary-rgb: 237, 26, 59;
4
- --primary-light: #ef314f;
5
- // --primary-light25: #f1536c;
6
- --primary-dark10: #c50f2c;
7
- --primary-dark: #b60e28;
8
- --secondary: #ff9500;
9
- }
@@ -1,31 +0,0 @@
1
- export interface IAnyObject {
2
- [id: string]: any;
3
- }
4
-
5
- export interface IStringObject {
6
- [id: string]: string;
7
- }
8
-
9
- export interface IBooleanObject {
10
- [id: string]: boolean;
11
- }
12
-
13
- export interface ISimpleObject {
14
- uuid: string;
15
- name: string;
16
- }
17
-
18
- export interface ISimpleObjectWithCode extends ISimpleObject {
19
- code: string;
20
- }
21
-
22
- export interface ISimpleObjectWithCodeNew {
23
- uuid?: string;
24
- name?: string;
25
- code?: string;
26
- }
27
-
28
- export interface IValueLabel {
29
- value: any;
30
- label: string;
31
- }
@@ -1,4 +0,0 @@
1
- export interface IError {
2
- errorMessage: string;
3
- errorCode?: string;
4
- }
@@ -1,12 +0,0 @@
1
- import { IconDefinition, RotateProp } from "@fortawesome/fontawesome-svg-core";
2
-
3
- export interface IHeaderAction {
4
- label: string;
5
- icon?: IconDefinition;
6
- iconRotation?: RotateProp;
7
- to?: string;
8
- onClick?: () => void;
9
- primary?: boolean;
10
- disabled?: boolean;
11
- hidden?: boolean;
12
- }
@@ -1,6 +0,0 @@
1
- import { IValueLabel } from "./IBasic";
2
-
3
- export interface ISelectData extends IValueLabel {
4
- disabled?: boolean;
5
- [id: string]: any;
6
- }
@@ -1,29 +0,0 @@
1
- import { IconDefinition } from "@fortawesome/fontawesome-svg-core";
2
-
3
- export interface ISidebarItem {
4
- label: string;
5
- icon: IconDefinition;
6
- to?: string;
7
- content?: ISidebarSubItem[];
8
- menu?: {
9
- content: ISidebarSubItem[];
10
- openedMenu: string;
11
- setOpenedMenu: (label: string) => void;
12
- };
13
- hidden?: boolean;
14
- badge?: number;
15
- addUrl?: string;
16
- collapsed?: boolean;
17
- }
18
-
19
- export interface ISidebarSubItem {
20
- label: string;
21
- to?: string;
22
- content?: ISidebarItem[];
23
- hidden?: boolean;
24
- tooltip?: string;
25
- badge?: number;
26
- addUrl?: string;
27
- primary?: boolean;
28
- collapsed?: boolean;
29
- }
package/src/types/ITab.ts DELETED
@@ -1,10 +0,0 @@
1
- import { ReactNode } from "react";
2
-
3
- export interface ITab {
4
- value: string;
5
- label: string;
6
- icon?: any;
7
- component: ReactNode;
8
- disabled?: boolean;
9
- hidden?: boolean;
10
- }
@@ -1,210 +0,0 @@
1
- import {
2
- Dispatch,
3
- FunctionComponent,
4
- MouseEventHandler,
5
- ReactElement,
6
- ReactNode,
7
- RefObject,
8
- SetStateAction,
9
- } from 'react';
10
- import { IconDefinition } from '@fortawesome/fontawesome-svg-core';
11
- import { IAnyObject } from './IBasic';
12
-
13
- export interface ITable {
14
- columns: ITableColumn[];
15
- setColumns?: (data: ITableColumn[]) => void;
16
- firstHeaderRow?: ITableColumn[];
17
- secondHeaderRow?: ITableColumn[];
18
- data: ITableDataItem[];
19
- totals?: ITableDataItem;
20
- isLoading?: boolean;
21
- loaderLogo?: string;
22
- serverSidePagination?: IServerSidePagination;
23
- customPagination?: {
24
- defaultLimit?: number;
25
- customLimit?: number[];
26
- };
27
- selectedRowUuid?: string;
28
- footerAction?: {
29
- icon?: IconDefinition;
30
- onClick: () => void;
31
- };
32
- headerWrap?: boolean;
33
- hideFooter?: boolean;
34
- showLastBorder?: boolean;
35
- filterData?: ITableFilterData;
36
- sortData?: ITableSortData;
37
- printData?: IPrintData;
38
- additionsalOptions?: ReactNode;
39
- selectedOptions?: ReactNode;
40
- translations?: ITableTranslations;
41
- className?: string;
42
- editable?: {
43
- selectedItem: any;
44
- setSelectedItem: (item: any) => void;
45
- defaultDataValue?: any;
46
- EditableRow?: FunctionComponent<ITableEditRow>;
47
- onSubmit: (data: any, onSubmitCallback?: () => void) => void;
48
- disabled?: boolean;
49
- inputFocusRef?: RefObject<any>;
50
- };
51
- }
52
-
53
- export interface ITableColumn {
54
- id: string;
55
- label?: string;
56
- align?: 'center' | 'left' | 'right' | 'justify' | undefined;
57
- hidden?: boolean;
58
- unavailable?: boolean;
59
- width?: string;
60
- minWidth?: string;
61
- colSpan?: number;
62
- rowSpan?: number;
63
- break?: boolean;
64
- sortOptions?: {
65
- asc: string;
66
- desc: string;
67
- label: string;
68
- };
69
- }
70
-
71
- export interface ITableDataItem {
72
- uuid: string;
73
- onRowClick?: MouseEventHandler<HTMLTableRowElement>;
74
- className?: string;
75
- cells: {
76
- [id: string]: {
77
- value: any;
78
- align?: ITableColumn['align'];
79
- className?: string;
80
- onClick?: MouseEventHandler<HTMLTableCellElement>;
81
- link?: boolean;
82
- tooltip?: string;
83
- span?: number;
84
- unclickable?: boolean;
85
- };
86
- };
87
- extendable?: {
88
- element: ReactElement;
89
- isLoading?: boolean;
90
- };
91
- }
92
-
93
- export interface ITableFilterData {
94
- columns: string[];
95
- filters: ITableFilter;
96
- activeFilterNo?: number;
97
- additionalFilters?: ReactElement;
98
- search: IAnyObject;
99
- searchData: IAnyObject;
100
- setSearchData: (search: IAnyObject) => void;
101
- onSubmit: (search: IAnyObject) => void;
102
- resetData?: IAnyObject;
103
- excludeFromSearch?: string[];
104
- }
105
-
106
- export interface ITableFilterItem {
107
- label: string;
108
- field: ReactElement;
109
- resetField: () => void;
110
- }
111
- export interface ITableFilter {
112
- [id: string]: ITableFilterItem;
113
- }
114
-
115
- export interface ITableSortData {
116
- sort: string;
117
- setSort: (sort: string) => void;
118
- sortOptions: ITableSort;
119
- menuSize?: 's' | 'm' | 'l';
120
- }
121
- export interface ITableSort {
122
- [id: string]: {
123
- label: string;
124
- asc: string;
125
- desc: string;
126
- };
127
- }
128
-
129
- export interface ITableColumnsData {
130
- columns: ITableColumn[];
131
- setColumns: (data: any) => void;
132
- }
133
- export interface IPrintData {
134
- label: string;
135
- organization?: {
136
- name?: string;
137
- taxId?: string;
138
- registrationNumber?: string;
139
- jbkjs?: string;
140
- email?: string;
141
- };
142
- filters?: {
143
- basic?: { label: string; value?: string }[];
144
- date?: { label: string; from?: string; to?: string }[];
145
- };
146
- getPrintData: (pagination: IPagination) => Promise<IAnyObject>;
147
- formatPrintData: (data: any) => ITableDataItem[];
148
- saveXlsx?: () => void;
149
- totals?: ITableDataItem;
150
- }
151
-
152
- export interface IPagination {
153
- limit: number;
154
- offset: number;
155
- }
156
- export interface IServerSidePagination {
157
- limit: number;
158
- offset: number;
159
- setLimit: Dispatch<SetStateAction<number>>;
160
- setOffset: Dispatch<SetStateAction<number>>;
161
- totalRows: number;
162
- }
163
-
164
- export interface ITableEditRow {
165
- columns: ITableColumn[];
166
- data: any;
167
- setData: (data: any) => void;
168
- item?: any;
169
- clearItem: () => void;
170
- defaultDataValue?: any;
171
- inputFocusRef?: RefObject<any>;
172
- }
173
-
174
- export interface ITableTranslations {
175
- noDataText?: string;
176
- pagination?: {
177
- rowsPerPage: string;
178
- of: string;
179
- allResults: string;
180
- page: string;
181
- };
182
- Sort?: string;
183
- filter?: {
184
- Filter?: string;
185
- ResetFilter?: string;
186
- Search?: string;
187
- Delete?: string;
188
- };
189
- print?: {
190
- Print?: string;
191
- PrintExport?: string;
192
- TaxId?: string;
193
- RegistrationNumber?: string;
194
- PrintDate?: string;
195
- from?: string;
196
- to?: string;
197
- SaveXlsx?: string;
198
- };
199
- Cancel?: string;
200
- Confirm?: string;
201
- columns?: {
202
- Columns?: string;
203
- DragDropListsInfo?: string;
204
- HiddenColumns?: string;
205
- SelectedColumns?: string;
206
- };
207
- editable?: {
208
- Actions?: string;
209
- };
210
- }
@@ -1,9 +0,0 @@
1
- declare module "*.png" {
2
- const value: string;
3
- export = value;
4
- }
5
-
6
- declare module "*.svg" {
7
- const value: string;
8
- export = value;
9
- }
@@ -1,30 +0,0 @@
1
- import moment from 'moment/moment';
2
-
3
- export const formatDate = (date?: string) =>
4
- date ? moment(date).format(`DD.MM.YYYY.`) : '/';
5
- export const formatDateYMD = (date: string | Date) => moment(date).format(`yyyy-MM-DD`);
6
-
7
- export const formatDateAndTime = (date?: string, withSeconds?: boolean) =>
8
- date ? moment(date).format(`DD.MM.YYYY. HH:mm${withSeconds ? ':ss' : ''}`) : '/';
9
-
10
- export const formatTime = (date?: string, withSeconds?: boolean) =>
11
- date ? moment(date).format(`HH:mm${withSeconds ? ':ss' : ''}`) : '/';
12
-
13
- export const dateAddDays = (date: string, addDays: number) =>
14
- moment(date).add(addDays, 'days').toISOString();
15
-
16
- export const checkIfExpired = (date?: string) =>
17
- date ? moment(new Date()) > moment(date) : true;
18
-
19
- export const getCurrentDateFormatted = () => moment().format('DD.MM.YYYY.').toString();
20
- export const getCurrentDateFormattedYMD = () => moment().format('yyyy-MM-DD').toString();
21
-
22
- export const getDaysLeft = (date?: string) => moment(date).diff(new Date(), 'days');
23
-
24
- export const formatYearMonth = (year: number, month: number) =>
25
- `${year}-${month < 10 ? `0${month}` : month}`;
26
-
27
- // export const getDayInputRegex = (max: number) =>
28
- // `(0[1-9]|1[0-9]|2[0-${max === 28 ? "8" : "9"}]${
29
- // max > 29 && `|3[0${max > 30 && "-1"}]`
30
- // })`;