@inceptionbg/iui 1.0.5 → 1.0.7
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.
- package/dist/index.css +1 -0
- package/dist/index.d.ts +407 -0
- package/dist/index.js +269 -0
- package/dist/index.js.map +1 -0
- package/package.json +7 -6
- package/src/Elements/Accordions/Accordions.tsx +0 -63
- package/src/Elements/Alert/Alert.tsx +0 -31
- package/src/Elements/Alert/alert.scss +0 -36
- package/src/Elements/Button/Button.tsx +0 -55
- package/src/Elements/Button/IconButton.tsx +0 -42
- package/src/Elements/Button/button.scss +0 -97
- package/src/Elements/Dialog/Dialog.tsx +0 -175
- package/src/Elements/Helper/Collapse.tsx +0 -39
- package/src/Elements/Helper/NoAccessInfo.tsx +0 -195
- package/src/Elements/Tooltip/Tooltip.tsx +0 -116
- package/src/Elements/Tooltip/tooltip.scss +0 -46
- package/src/Elements/Wrappers/ConditionalWrapper.tsx +0 -10
- package/src/Elements/Wrappers/FormWrapper.tsx +0 -67
- package/src/Elements/Wrappers/FullPageWrapper.tsx +0 -87
- package/src/icons/duotone/faArrowLeftFromLine.ts +0 -17
- package/src/icons/duotone/faArrowRightToLine.ts +0 -17
- package/src/icons/duotone/faBell.ts +0 -17
- package/src/icons/duotone/faEye.ts +0 -17
- package/src/icons/duotone/faEyeSlash.ts +0 -17
- package/src/icons/duotone/faHouseHeart.ts +0 -17
- package/src/icons/duotone/faPlusCircle.ts +0 -18
- package/src/icons/duotone/faUser.ts +0 -18
- package/src/icons/duotone/index.ts +0 -19
- package/src/icons/light/faAngleDown.ts +0 -15
- package/src/icons/light/faArrowDownShortWide.ts +0 -15
- package/src/icons/light/faArrowDownWideShort.ts +0 -15
- package/src/icons/light/faArrowsToLine.ts +0 -15
- package/src/icons/light/faArrowsUpDown.ts +0 -15
- package/src/icons/light/faBell.ts +0 -15
- package/src/icons/light/faCheck.ts +0 -15
- package/src/icons/light/faClockRotateLeft.ts +0 -15
- package/src/icons/light/faEllipsisVertical.ts +0 -15
- package/src/icons/light/faXmark.ts +0 -15
- package/src/icons/light/index.ts +0 -23
- package/src/icons/regular/faArrowRightArrowLeft.ts +0 -15
- package/src/icons/regular/faCalendar.ts +0 -15
- package/src/icons/regular/faCircleCheck.ts +0 -15
- package/src/icons/regular/faCircleExclamation.ts +0 -15
- package/src/icons/regular/faCircleInfo.ts +0 -15
- package/src/icons/regular/faFileArrowDown.ts +0 -15
- package/src/icons/regular/faFilterCircleXmark.ts +0 -15
- package/src/icons/regular/faTriangleExclamation.ts +0 -15
- package/src/icons/solid/faAngleLeft.ts +0 -15
- package/src/icons/solid/faAngleRight.ts +0 -15
- package/src/icons/solid/faArrowDownWideShort.ts +0 -15
- package/src/icons/solid/faArrowLeft.ts +0 -15
- package/src/icons/solid/faEllipsisVertical.ts +0 -15
- package/src/icons/solid/faFilter.ts +0 -15
- package/src/icons/solid/faGripDotsVertical.ts +0 -15
- package/src/icons/solid/faListUl.ts +0 -15
- package/src/icons/solid/faMagnifyingGlass.ts +0 -15
- package/src/icons/solid/faPrint.ts +0 -15
- package/src/icons/solid/faRotateRight.ts +0 -15
- package/src/icons/solid/faXmark.ts +0 -15
- package/src/index.ts +0 -186
- package/src/styles/App.scss +0 -25
- package/src/styles/iui/common/_animations.scss +0 -56
- package/src/styles/iui/common/_typography.scss +0 -76
- package/src/styles/iui/common/_variables.scss +0 -56
- package/src/styles/iui/common/helpers/_base.scss +0 -32
- package/src/styles/iui/common/helpers/_color.scss +0 -7
- package/src/styles/iui/common/helpers/_display.scss +0 -54
- package/src/styles/iui/common/helpers/_size.scss +0 -17
- package/src/styles/iui/common/maps/_align.scss +0 -24
- package/src/styles/iui/common/maps/_spacing.scss +0 -78
- package/src/styles/iui/components/_accordions.scss +0 -47
- package/src/styles/iui/components/_badge.scss +0 -52
- package/src/styles/iui/components/_card.scss +0 -24
- package/src/styles/iui/components/_dialog.scss +0 -75
- package/src/styles/iui/components/_header.scss +0 -22
- package/src/styles/iui/components/_input.scss +0 -225
- package/src/styles/iui/components/_loader.scss +0 -93
- package/src/styles/iui/components/_menu.scss +0 -44
- package/src/styles/iui/components/_notifications.scss +0 -86
- package/src/styles/iui/components/_page.scss +0 -50
- package/src/styles/iui/components/_pagePrelogin.scss +0 -66
- package/src/styles/iui/components/_portal.scss +0 -8
- package/src/styles/iui/components/_print.scss +0 -92
- package/src/styles/iui/components/_scrollbar.scss +0 -18
- package/src/styles/iui/components/_selectInput.scss +0 -15
- package/src/styles/iui/components/_sidebar.scss +0 -171
- package/src/styles/iui/components/_smallComponents.scss +0 -24
- package/src/styles/iui/components/_table.scss +0 -207
- package/src/styles/iui/components/_tabs.scss +0 -94
- package/src/styles/iui.scss +0 -28
- package/src/styles/red-variables.scss +0 -9
- package/src/types/IBasic.ts +0 -31
- package/src/types/IError.ts +0 -4
- package/src/types/IHeaderAction.ts +0 -12
- package/src/types/ISelect.ts +0 -6
- package/src/types/ISidebar.ts +0 -29
- package/src/types/ITab.ts +0 -10
- package/src/types/ITable.ts +0 -210
- package/src/types/custom.d.ts +0 -9
- package/src/utils/DateUtils.ts +0 -30
- package/src/utils/NumberUtils.ts +0 -21
- package/src/utils/ObjectUtils.ts +0 -49
- package/src/utils/StringUtils.ts +0 -2
- package/src/utils/Toasts.ts +0 -6
- package/src/utils/icons.ts +0 -11
- package/src/utils/index.ts +0 -41
- package/tsconfig.json +0 -20
package/src/utils/NumberUtils.ts
DELETED
|
@@ -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 || 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;
|
package/src/utils/ObjectUtils.ts
DELETED
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
import { IAnyObject } from "../types/IBasic";
|
|
2
|
-
import { ITableColumn } from "../types/ITable";
|
|
3
|
-
|
|
4
|
-
export const deleteProps = (obj: any, props: string[]) => {
|
|
5
|
-
let newObj = { ...obj };
|
|
6
|
-
props.forEach((e) => delete newObj[e]);
|
|
7
|
-
return newObj;
|
|
8
|
-
};
|
|
9
|
-
|
|
10
|
-
export const deleteEmptyProps = (obj: IAnyObject) =>
|
|
11
|
-
Object.entries(obj).reduce(
|
|
12
|
-
(a: any, [k, v]) =>
|
|
13
|
-
[null, undefined, ""].includes(v) ? a : ((a[k] = v), a),
|
|
14
|
-
{}
|
|
15
|
-
);
|
|
16
|
-
|
|
17
|
-
export const deleteEmptyPropsIncludingArray = (obj: IAnyObject) =>
|
|
18
|
-
Object.entries(obj).reduce(
|
|
19
|
-
(a: any, [k, v]) =>
|
|
20
|
-
[null, undefined, ""].includes(v) || (Array.isArray(v) && !v.length)
|
|
21
|
-
? a
|
|
22
|
-
: ((a[k] = v), a),
|
|
23
|
-
{}
|
|
24
|
-
);
|
|
25
|
-
|
|
26
|
-
export const getActiveFilterNumber = (obj: any) => Object.keys(obj).length;
|
|
27
|
-
|
|
28
|
-
export const getPrintColumns = (tableCols: ITableColumn[]) =>
|
|
29
|
-
tableCols.reduce(
|
|
30
|
-
(arr: string[], col) =>
|
|
31
|
-
col.hidden || col.unavailable ? arr : arr.concat(col.id),
|
|
32
|
-
[]
|
|
33
|
-
);
|
|
34
|
-
|
|
35
|
-
export const getVisibleColumnsIds = (
|
|
36
|
-
tableCols: ITableColumn[],
|
|
37
|
-
isPrint?: boolean
|
|
38
|
-
) =>
|
|
39
|
-
tableCols.reduce(
|
|
40
|
-
(arr: string[], col) =>
|
|
41
|
-
col.hidden ||
|
|
42
|
-
col.unavailable ||
|
|
43
|
-
(isPrint && ["select", "icons", "actions"].includes(col.id))
|
|
44
|
-
? arr
|
|
45
|
-
: arr.concat(col.id),
|
|
46
|
-
[]
|
|
47
|
-
);
|
|
48
|
-
|
|
49
|
-
export const deepCopy = (el: any[] | object) => JSON.parse(JSON.stringify(el));
|
package/src/utils/StringUtils.ts
DELETED
package/src/utils/Toasts.ts
DELETED
|
@@ -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);
|
package/src/utils/icons.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { faCircleCheck } from "../icons/regular/faCircleCheck";
|
|
2
|
-
import { faCircleExclamation } from "../icons/regular/faCircleExclamation";
|
|
3
|
-
import { faCircleInfo } from "../icons/regular/faCircleInfo";
|
|
4
|
-
import { faTriangleExclamation } from "../icons/regular/faTriangleExclamation";
|
|
5
|
-
|
|
6
|
-
export const infoIcons = {
|
|
7
|
-
error: faCircleExclamation,
|
|
8
|
-
success: faCircleCheck,
|
|
9
|
-
info: faCircleInfo,
|
|
10
|
-
warning: faTriangleExclamation,
|
|
11
|
-
};
|
package/src/utils/index.ts
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
checkIfExpired,
|
|
3
|
-
dateAddDays,
|
|
4
|
-
formatDate,
|
|
5
|
-
formatDateAndTime,
|
|
6
|
-
formatTime,
|
|
7
|
-
formatYearMonth,
|
|
8
|
-
getCurrentDateFormattedYMD,
|
|
9
|
-
getDaysLeft,
|
|
10
|
-
} from "./DateUtils";
|
|
11
|
-
import { formatCurrency, formatCurrencyNoDecimals } from "./NumberUtils";
|
|
12
|
-
import {
|
|
13
|
-
deleteEmptyProps,
|
|
14
|
-
deleteEmptyPropsIncludingArray,
|
|
15
|
-
deleteProps,
|
|
16
|
-
getActiveFilterNumber,
|
|
17
|
-
getVisibleColumnsIds,
|
|
18
|
-
} from "./ObjectUtils";
|
|
19
|
-
import { maxChar } from "./StringUtils";
|
|
20
|
-
|
|
21
|
-
export {
|
|
22
|
-
checkIfExpired,
|
|
23
|
-
dateAddDays,
|
|
24
|
-
formatDate,
|
|
25
|
-
formatDateAndTime,
|
|
26
|
-
formatTime,
|
|
27
|
-
formatYearMonth,
|
|
28
|
-
getCurrentDateFormattedYMD,
|
|
29
|
-
getDaysLeft,
|
|
30
|
-
formatCurrency,
|
|
31
|
-
formatCurrencyNoDecimals,
|
|
32
|
-
deleteEmptyProps,
|
|
33
|
-
deleteEmptyPropsIncludingArray,
|
|
34
|
-
deleteProps,
|
|
35
|
-
getActiveFilterNumber,
|
|
36
|
-
getVisibleColumnsIds,
|
|
37
|
-
// apiResponseHandler,
|
|
38
|
-
// toastError,
|
|
39
|
-
// toastSuccess,
|
|
40
|
-
maxChar,
|
|
41
|
-
};
|
package/tsconfig.json
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"target": "esnext",
|
|
4
|
-
"module": "esnext",
|
|
5
|
-
"strict": true,
|
|
6
|
-
"esModuleInterop": true,
|
|
7
|
-
"jsx": "react-jsx",
|
|
8
|
-
"rootDir": "src",
|
|
9
|
-
"outDir": "dist",
|
|
10
|
-
"sourceMap": true,
|
|
11
|
-
"moduleResolution": "node",
|
|
12
|
-
"forceConsistentCasingInFileNames": true,
|
|
13
|
-
"skipLibCheck": true,
|
|
14
|
-
"emitDeclarationOnly": true,
|
|
15
|
-
"declaration": true,
|
|
16
|
-
"declarationDir": "dist/types"
|
|
17
|
-
},
|
|
18
|
-
"include": ["src"],
|
|
19
|
-
"exclude": ["node_modules"]
|
|
20
|
-
}
|