funuicss 2.5.8 → 2.5.9

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 (214) hide show
  1. package/dist/assets/colors/colors.d.ts +347 -0
  2. package/dist/assets/colors/colors.js +348 -0
  3. package/dist/index.d.ts +37 -0
  4. package/dist/index.js +80 -0
  5. package/dist/js/Fun.d.ts +38 -0
  6. package/dist/js/Fun.js +235 -0
  7. package/dist/js/Theme.d.ts +2 -0
  8. package/dist/js/Theme.js +42 -0
  9. package/dist/tsconfig.tsbuildinfo +1 -0
  10. package/dist/ui/alert/Alert.d.ts +24 -0
  11. package/dist/ui/alert/Alert.js +48 -0
  12. package/dist/ui/aos/AOS.d.ts +9 -0
  13. package/dist/ui/aos/AOS.js +30 -0
  14. package/dist/ui/appbar/AppBar.d.ts +17 -0
  15. package/dist/ui/appbar/AppBar.js +43 -0
  16. package/dist/ui/appbar/Hamburger.d.ts +7 -0
  17. package/dist/ui/appbar/Hamburger.js +20 -0
  18. package/dist/ui/avatar/Avatar.d.ts +10 -0
  19. package/dist/ui/avatar/Avatar.js +12 -0
  20. package/dist/ui/blob/Blob.d.ts +10 -0
  21. package/dist/ui/blob/Blob.js +16 -0
  22. package/dist/ui/breadcrumb/BreadCrumb.d.ts +7 -0
  23. package/dist/ui/breadcrumb/BreadCrumb.js +10 -0
  24. package/dist/ui/button/Button.d.ts +39 -0
  25. package/dist/ui/button/Button.js +66 -0
  26. package/dist/ui/card/Card.d.ts +32 -0
  27. package/dist/ui/card/Card.js +39 -0
  28. package/dist/ui/card/CardBody.d.ts +7 -0
  29. package/dist/ui/card/CardBody.js +30 -0
  30. package/dist/ui/card/CardFab.d.ts +8 -0
  31. package/dist/ui/card/CardFab.js +31 -0
  32. package/dist/ui/card/CardFooter.d.ts +7 -0
  33. package/dist/ui/card/CardFooter.js +30 -0
  34. package/dist/ui/card/CardHeader.d.ts +7 -0
  35. package/dist/ui/card/CardHeader.js +30 -0
  36. package/dist/ui/container/Container.d.ts +11 -0
  37. package/dist/ui/container/Container.js +31 -0
  38. package/dist/ui/div/Div.d.ts +19 -0
  39. package/dist/ui/div/Div.js +31 -0
  40. package/dist/ui/drop/Action.d.ts +7 -0
  41. package/dist/ui/drop/Action.js +8 -0
  42. package/dist/ui/drop/Down.d.ts +9 -0
  43. package/dist/ui/drop/Down.js +8 -0
  44. package/dist/ui/drop/Dropdown.d.ts +18 -0
  45. package/dist/ui/drop/Dropdown.js +31 -0
  46. package/dist/ui/drop/Item.d.ts +8 -0
  47. package/dist/ui/drop/Item.js +8 -0
  48. package/dist/ui/drop/Menu.d.ts +12 -0
  49. package/dist/ui/drop/Menu.js +11 -0
  50. package/dist/ui/drop/Up.d.ts +9 -0
  51. package/dist/ui/drop/Up.js +8 -0
  52. package/dist/ui/grid/Col.d.ts +14 -0
  53. package/dist/ui/grid/Col.js +40 -0
  54. package/dist/ui/grid/Grid.d.ts +12 -0
  55. package/dist/ui/grid/Grid.js +34 -0
  56. package/dist/ui/input/Iconic.d.ts +11 -0
  57. package/dist/ui/input/Iconic.js +15 -0
  58. package/dist/ui/input/Input.d.ts +35 -0
  59. package/dist/ui/input/Input.js +110 -0
  60. package/dist/ui/list/Item.d.ts +7 -0
  61. package/dist/ui/list/Item.js +30 -0
  62. package/dist/ui/list/List.d.ts +14 -0
  63. package/dist/ui/list/List.js +30 -0
  64. package/dist/ui/loader/Loader.d.ts +10 -0
  65. package/dist/ui/loader/Loader.js +37 -0
  66. package/dist/ui/modal/Action.d.ts +7 -0
  67. package/dist/ui/modal/Action.js +30 -0
  68. package/dist/ui/modal/Close.d.ts +6 -0
  69. package/dist/ui/modal/Close.js +31 -0
  70. package/dist/ui/modal/Content.d.ts +7 -0
  71. package/dist/ui/modal/Content.js +8 -0
  72. package/dist/ui/modal/Header.d.ts +9 -0
  73. package/dist/ui/modal/Header.js +30 -0
  74. package/dist/ui/modal/Modal.d.ts +32 -0
  75. package/dist/ui/modal/Modal.js +61 -0
  76. package/dist/ui/notification/Content.d.ts +7 -0
  77. package/dist/ui/notification/Content.js +8 -0
  78. package/dist/ui/notification/Footer.d.ts +7 -0
  79. package/dist/ui/notification/Footer.js +8 -0
  80. package/dist/ui/notification/Header.d.ts +7 -0
  81. package/dist/ui/notification/Header.js +8 -0
  82. package/dist/ui/notification/Notification.d.ts +15 -0
  83. package/dist/ui/notification/Notification.js +23 -0
  84. package/dist/ui/page/NotFound.d.ts +9 -0
  85. package/dist/ui/page/NotFound.js +23 -0
  86. package/dist/ui/page/UnAuthorized.d.ts +9 -0
  87. package/dist/ui/page/UnAuthorized.js +21 -0
  88. package/dist/ui/progress/Bar.d.ts +17 -0
  89. package/dist/ui/progress/Bar.js +87 -0
  90. package/dist/ui/sidebar/SideBar.d.ts +14 -0
  91. package/dist/ui/sidebar/SideBar.js +42 -0
  92. package/dist/ui/sidebar/SideContent.d.ts +6 -0
  93. package/dist/ui/sidebar/SideContent.js +8 -0
  94. package/dist/ui/snackbar/SnackBar.d.ts +16 -0
  95. package/dist/ui/snackbar/SnackBar.js +53 -0
  96. package/dist/ui/specials/Circle.d.ts +15 -0
  97. package/dist/ui/specials/Circle.js +34 -0
  98. package/dist/ui/specials/FullCenteredPage.d.ts +8 -0
  99. package/dist/ui/specials/FullCenteredPage.js +30 -0
  100. package/dist/ui/specials/Hr.d.ts +7 -0
  101. package/dist/ui/specials/Hr.js +8 -0
  102. package/dist/ui/specials/RowFlex.d.ts +14 -0
  103. package/dist/ui/specials/RowFlex.js +34 -0
  104. package/dist/ui/specials/Section.d.ts +8 -0
  105. package/dist/ui/specials/Section.js +30 -0
  106. package/dist/ui/step/Container.d.ts +9 -0
  107. package/dist/ui/step/Container.js +8 -0
  108. package/dist/ui/step/Header.d.ts +7 -0
  109. package/dist/ui/step/Header.js +8 -0
  110. package/dist/ui/step/Line.d.ts +7 -0
  111. package/dist/ui/step/Line.js +9 -0
  112. package/dist/ui/step/Step.d.ts +7 -0
  113. package/dist/ui/step/Step.js +9 -0
  114. package/dist/ui/table/Body.d.ts +7 -0
  115. package/dist/ui/table/Body.js +8 -0
  116. package/dist/ui/table/Data.d.ts +8 -0
  117. package/dist/ui/table/Data.js +8 -0
  118. package/dist/ui/table/Head.d.ts +7 -0
  119. package/dist/ui/table/Head.js +8 -0
  120. package/dist/ui/table/Row.d.ts +9 -0
  121. package/dist/ui/table/Row.js +8 -0
  122. package/dist/ui/table/Table.d.ts +33 -0
  123. package/dist/ui/table/Table.js +133 -0
  124. package/dist/ui/text/Text.d.ts +44 -0
  125. package/dist/ui/text/Text.js +63 -0
  126. package/dist/ui/theme/dark.d.ts +5 -0
  127. package/dist/ui/theme/dark.js +34 -0
  128. package/dist/ui/theme/theme.d.ts +7 -0
  129. package/dist/ui/theme/theme.js +34 -0
  130. package/dist/ui/tooltip/Tip.d.ts +12 -0
  131. package/dist/ui/tooltip/Tip.js +31 -0
  132. package/dist/ui/tooltip/ToolTip.d.ts +7 -0
  133. package/dist/ui/tooltip/ToolTip.js +30 -0
  134. package/dist/ui/video/FunPlayer.d.ts +0 -0
  135. package/dist/ui/video/FunPlayer.js +203 -0
  136. package/dist/webpack.config.d.ts +23 -0
  137. package/package.json +13 -12
  138. package/tsconfig.json +12 -10
  139. package/tsconfig.tsbuildinfo +1 -1
  140. package/types/next-env.d.ts +3 -0
  141. package/types/react-easy-export.d.ts +4 -0
  142. package/ui/alert/Alert.js +18 -8
  143. package/ui/alert/Alert.tsx +1 -1
  144. package/ui/aos/AOS.js +18 -8
  145. package/ui/appbar/AppBar.js +23 -19
  146. package/ui/appbar/AppBar.tsx +5 -12
  147. package/ui/appbar/Hamburger.js +17 -7
  148. package/ui/avatar/Avatar.js +19 -8
  149. package/ui/avatar/Avatar.tsx +1 -0
  150. package/ui/blob/Blob.js +17 -7
  151. package/ui/breadcrumb/BreadCrumb.js +19 -8
  152. package/ui/breadcrumb/BreadCrumb.tsx +1 -0
  153. package/ui/button/Button.js +19 -8
  154. package/ui/button/Button.tsx +5 -6
  155. package/ui/card/Card.js +2 -1
  156. package/ui/card/Card.tsx +1 -0
  157. package/ui/card/CardBody.js +1 -1
  158. package/ui/card/CardFab.js +1 -1
  159. package/ui/card/CardFooter.js +1 -1
  160. package/ui/card/CardHeader.js +1 -1
  161. package/ui/container/Container.js +17 -7
  162. package/ui/container/Container.tsx +1 -1
  163. package/ui/div/Div.js +18 -7
  164. package/ui/div/Div.tsx +1 -0
  165. package/ui/drop/Action.js +17 -7
  166. package/ui/drop/Down.js +17 -7
  167. package/ui/drop/Dropdown.js +17 -7
  168. package/ui/drop/Dropdown.tsx +1 -2
  169. package/ui/drop/Item.js +18 -8
  170. package/ui/drop/Menu.js +18 -8
  171. package/ui/drop/Up.js +17 -7
  172. package/ui/grid/Col.js +18 -8
  173. package/ui/grid/Grid.js +18 -8
  174. package/ui/input/Iconic.js +1 -1
  175. package/ui/input/Input.js +17 -7
  176. package/ui/list/Item.js +18 -8
  177. package/ui/list/List.js +18 -8
  178. package/ui/loader/Loader.js +18 -8
  179. package/ui/modal/Action.js +18 -8
  180. package/ui/modal/Close.js +18 -8
  181. package/ui/modal/Content.js +18 -8
  182. package/ui/modal/Header.js +18 -8
  183. package/ui/modal/Modal.js +18 -8
  184. package/ui/notification/Content.js +18 -8
  185. package/ui/notification/Footer.js +18 -8
  186. package/ui/notification/Header.js +18 -8
  187. package/ui/notification/Notification.js +19 -8
  188. package/ui/notification/Notification.tsx +1 -0
  189. package/ui/page/NotFound.js +18 -8
  190. package/ui/page/UnAuthorized.js +18 -8
  191. package/ui/progress/Bar.js +19 -8
  192. package/ui/progress/Bar.tsx +1 -0
  193. package/ui/sidebar/SideBar.js +18 -8
  194. package/ui/sidebar/SideContent.js +1 -1
  195. package/ui/snackbar/SnackBar.js +17 -7
  196. package/ui/specials/Circle.js +18 -8
  197. package/ui/specials/FullCenteredPage.js +17 -7
  198. package/ui/specials/Hr.js +17 -7
  199. package/ui/specials/RowFlex.js +18 -8
  200. package/ui/specials/Section.js +17 -7
  201. package/ui/step/Line.js +1 -0
  202. package/ui/step/Line.tsx +1 -0
  203. package/ui/step/Step.js +1 -0
  204. package/ui/step/Step.tsx +1 -0
  205. package/ui/table/Body.js +18 -8
  206. package/ui/table/Data.js +18 -8
  207. package/ui/table/Head.js +18 -8
  208. package/ui/table/Row.js +18 -8
  209. package/ui/table/Table.js +21 -9
  210. package/ui/table/Table.tsx +4 -1
  211. package/ui/theme/dark.js +1 -1
  212. package/ui/theme/theme.js +17 -7
  213. package/ui/tooltip/Tip.js +18 -8
  214. package/ui/tooltip/ToolTip.js +18 -8
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.default = Grid;
26
+ var jsx_runtime_1 = require("react/jsx-runtime");
27
+ function Grid(_a) {
28
+ var children = _a.children, funcss = _a.funcss, justify = _a.justify, align = _a.align, id = _a.id, direction = _a.direction, rest = __rest(_a, ["children", "funcss", "justify", "align", "id", "direction"]);
29
+ return ((0, jsx_runtime_1.jsx)("div", __assign({ id: id || '', className: "row ".concat(funcss || ''), style: {
30
+ justifyContent: justify || '',
31
+ alignItems: align || '',
32
+ flexDirection: direction || 'row'
33
+ } }, rest, { children: children })));
34
+ }
@@ -0,0 +1,11 @@
1
+ import { ReactNode } from 'react';
2
+ interface IconicInputProps {
3
+ funcss?: string;
4
+ children?: ReactNode;
5
+ input?: ReactNode;
6
+ iconicBg?: string;
7
+ leftIcon?: ReactNode;
8
+ rightIcon?: ReactNode;
9
+ }
10
+ export default function IconicInput({ funcss, children, leftIcon, rightIcon, input, iconicBg, }: IconicInputProps): import("react/jsx-runtime").JSX.Element;
11
+ export {};
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = IconicInput;
4
+ var jsx_runtime_1 = require("react/jsx-runtime");
5
+ function IconicInput(_a) {
6
+ var funcss = _a.funcss, children = _a.children, leftIcon = _a.leftIcon, rightIcon = _a.rightIcon, input = _a.input, iconicBg = _a.iconicBg;
7
+ return ((0, jsx_runtime_1.jsxs)("div", { className: "icon-container ".concat(funcss), children: [leftIcon ?
8
+ (0, jsx_runtime_1.jsx)("div", { className: "leftIcon", style: {
9
+ backgroundColor: iconicBg || '',
10
+ border: iconicBg ? "0.1rem ".concat(iconicBg, " solid") : '',
11
+ }, children: leftIcon ? leftIcon : '' })
12
+ : '', (0, jsx_runtime_1.jsxs)("div", { className: "icon_input_wrapper ".concat(leftIcon ? 'lefticon' : '', " ").concat(rightIcon ? 'righticon' : ''), children: [" ", input] }), rightIcon ?
13
+ (0, jsx_runtime_1.jsx)("div", { className: "rightIcon", style: { backgroundColor: iconicBg || '' }, children: rightIcon ? rightIcon : '' })
14
+ : ''] }));
15
+ }
@@ -0,0 +1,35 @@
1
+ import React from 'react';
2
+ interface InputProps {
3
+ select?: boolean;
4
+ bordered?: boolean;
5
+ borderless?: boolean;
6
+ multiline?: boolean;
7
+ file?: boolean;
8
+ noBorder?: boolean;
9
+ icon?: React.ReactNode;
10
+ extra?: React.ReactNode;
11
+ button?: React.ReactNode;
12
+ id?: string;
13
+ status?: 'success' | 'warning' | 'danger' | '';
14
+ funcss?: string;
15
+ flat?: boolean;
16
+ leftRounded?: boolean;
17
+ rightRounded?: boolean;
18
+ rounded?: boolean;
19
+ fullWidth?: boolean;
20
+ btn?: boolean;
21
+ type?: string;
22
+ label?: string;
23
+ name?: string;
24
+ value?: string;
25
+ defaultValue?: string;
26
+ onChange?: (event: React.ChangeEvent<HTMLInputElement | HTMLSelectElement | HTMLTextAreaElement>) => void;
27
+ options?: {
28
+ value: string;
29
+ text: string;
30
+ }[];
31
+ rows?: number;
32
+ bg?: string;
33
+ }
34
+ declare const Input: React.FC<InputProps>;
35
+ export default Input;
@@ -0,0 +1,110 @@
1
+ "use strict";
2
+ 'use client';
3
+ var __assign = (this && this.__assign) || function () {
4
+ __assign = Object.assign || function(t) {
5
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
6
+ s = arguments[i];
7
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
8
+ t[p] = s[p];
9
+ }
10
+ return t;
11
+ };
12
+ return __assign.apply(this, arguments);
13
+ };
14
+ var __rest = (this && this.__rest) || function (s, e) {
15
+ var t = {};
16
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
17
+ t[p] = s[p];
18
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
19
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
20
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
21
+ t[p[i]] = s[p[i]];
22
+ }
23
+ return t;
24
+ };
25
+ var __importDefault = (this && this.__importDefault) || function (mod) {
26
+ return (mod && mod.__esModule) ? mod : { "default": mod };
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ var jsx_runtime_1 = require("react/jsx-runtime");
30
+ var react_1 = require("react");
31
+ var pi_1 = require("react-icons/pi");
32
+ var Button_1 = __importDefault(require("../button/Button"));
33
+ var Input = function (_a) {
34
+ var select = _a.select, bordered = _a.bordered, borderless = _a.borderless, multiline = _a.multiline, file = _a.file, extra = _a.extra, noBorder = _a.noBorder, icon = _a.icon, btn = _a.btn, button = _a.button, id = _a.id, status = _a.status, funcss = _a.funcss, flat = _a.flat, leftRounded = _a.leftRounded, rightRounded = _a.rightRounded, rounded = _a.rounded, fullWidth = _a.fullWidth, type = _a.type, label = _a.label, name = _a.name, value = _a.value, defaultValue = _a.defaultValue, onChange = _a.onChange, options = _a.options, rows = _a.rows, bg = _a.bg, rest = __rest(_a, ["select", "bordered", "borderless", "multiline", "file", "extra", "noBorder", "icon", "btn", "button", "id", "status", "funcss", "flat", "leftRounded", "rightRounded", "rounded", "fullWidth", "type", "label", "name", "value", "defaultValue", "onChange", "options", "rows", "bg"]);
35
+ var _b = (0, react_1.useState)(''), fileName = _b[0], setFileName = _b[1];
36
+ var handleChange = function (e) {
37
+ var _a;
38
+ var file = (_a = e.target.files) === null || _a === void 0 ? void 0 : _a[0];
39
+ if (file) {
40
+ setFileName(file.name);
41
+ }
42
+ if (onChange)
43
+ onChange(e);
44
+ };
45
+ if (select) {
46
+ if (bordered) {
47
+ return ((0, jsx_runtime_1.jsx)("select", __assign({}, rest, { id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n borderedInput\n "), onChange: onChange, defaultValue: defaultValue, name: name, style: {
48
+ width: "".concat(fullWidth ? '100%' : '')
49
+ }, value: value, children: options
50
+ ? options.map(function (doc) { return ((0, jsx_runtime_1.jsx)("option", { value: doc.value, children: doc.text }, doc.value)); })
51
+ : '' })));
52
+ }
53
+ else if (borderless) {
54
+ return ((0, jsx_runtime_1.jsx)("select", __assign({}, rest, { id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n borderless\n "), onChange: onChange, defaultValue: defaultValue, name: name, value: value, style: {
55
+ width: "".concat(fullWidth ? '100%' : '')
56
+ }, children: options
57
+ ? options.map(function (doc) { return ((0, jsx_runtime_1.jsx)("option", { value: doc.value, children: doc.text }, doc.value)); })
58
+ : '' })));
59
+ }
60
+ else {
61
+ return ((0, jsx_runtime_1.jsx)("select", __assign({}, rest, { id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n "), onChange: onChange, defaultValue: defaultValue, name: name, value: value, style: {
62
+ width: "".concat(fullWidth ? '100%' : '')
63
+ }, children: options
64
+ ? options.map(function (doc) { return ((0, jsx_runtime_1.jsx)("option", { value: doc.value, children: doc.text }, doc.value)); })
65
+ : '' })));
66
+ }
67
+ }
68
+ else if (multiline) {
69
+ if (bordered) {
70
+ return ((0, jsx_runtime_1.jsx)("textarea", __assign({}, rest, { id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n borderedInput\n "), onChange: onChange, defaultValue: defaultValue, placeholder: label, name: name, style: {
71
+ width: "".concat(fullWidth ? '100%' : '')
72
+ }, value: value, rows: rows ? rows : 2 })));
73
+ }
74
+ else if (borderless) {
75
+ return ((0, jsx_runtime_1.jsx)("textarea", __assign({}, rest, { id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n borderless\n "), onChange: onChange, defaultValue: defaultValue, placeholder: label, name: name, value: value, style: {
76
+ width: "".concat(fullWidth ? '100%' : '')
77
+ }, rows: rows ? rows : 2 })));
78
+ }
79
+ else {
80
+ return ((0, jsx_runtime_1.jsx)("textarea", __assign({}, rest, { id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n "), onChange: onChange, defaultValue: defaultValue, placeholder: label, name: name, value: value, style: {
81
+ width: "".concat(fullWidth ? '100%' : '')
82
+ }, rows: rows ? rows : 2 })));
83
+ }
84
+ }
85
+ else if (file) {
86
+ if (btn)
87
+ return ((0, jsx_runtime_1.jsxs)("div", { className: "fileInput", children: [button ? (button) : ((0, jsx_runtime_1.jsx)(Button_1.default, { funcss: " ".concat(funcss, " "), startIcon: icon ? icon : (0, jsx_runtime_1.jsx)(pi_1.PiCloudArrowUp, {}), bg: "primary", fullWidth: true, raised: true, children: fileName || label || 'Upload File' })), (0, jsx_runtime_1.jsx)("input", __assign({ name: name, id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n borderedInput\n filedInput\n "), onChange: handleChange, type: 'file', style: {
88
+ width: "".concat(fullWidth ? '100%' : '')
89
+ }, value: value }, rest))] }));
90
+ return ((0, jsx_runtime_1.jsxs)("div", { className: "_upload_container", children: [(0, jsx_runtime_1.jsxs)("label", { htmlFor: id || "fileInput", className: "_upload_label", children: [(0, jsx_runtime_1.jsx)("div", { className: "_upload_icon", children: icon || (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: "\u21EA" }) }), (0, jsx_runtime_1.jsx)("div", { className: "_upload_text", children: fileName || label || "Upload File" }), (0, jsx_runtime_1.jsx)("div", { className: "text-small opacity-3", children: extra || '' })] }), (0, jsx_runtime_1.jsx)("input", __assign({ onChange: handleChange, type: "file", id: id || "fileInput", className: "_upload_input" }, rest))] }));
91
+ }
92
+ else {
93
+ if (bordered) {
94
+ return ((0, jsx_runtime_1.jsx)("input", __assign({ name: name, id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n borderedInput\n "), onChange: onChange, defaultValue: defaultValue, type: type, placeholder: label, style: {
95
+ width: "".concat(fullWidth ? '100%' : '')
96
+ }, value: value }, rest)));
97
+ }
98
+ else if (borderless) {
99
+ return ((0, jsx_runtime_1.jsx)("input", __assign({ name: name, id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n borderless\n "), onChange: onChange, defaultValue: defaultValue, type: type, placeholder: label, value: value, style: {
100
+ width: "".concat(fullWidth ? '100%' : '')
101
+ } }, rest)));
102
+ }
103
+ else {
104
+ return ((0, jsx_runtime_1.jsx)("input", __assign({ name: name, id: id, className: "\n ".concat(status === 'success' ? 'success-input' : '', "\n ").concat(status === 'warning' ? 'warning-input' : '', "\n ").concat(status === 'danger' ? 'danger-input' : '', "\n input \n ").concat(rounded ? "rounded" : '', "\n ").concat(bg ? bg : '', "\n ").concat(funcss, " ").concat(flat ? 'flat' : '', "\n ").concat(leftRounded ? 'leftRounded' : rightRounded ? 'rightRounded' : '', "\n "), onChange: onChange, defaultValue: defaultValue, type: type, placeholder: label, value: value, style: {
105
+ width: "".concat(fullWidth ? '100%' : '')
106
+ } }, rest)));
107
+ }
108
+ }
109
+ };
110
+ exports.default = Input;
@@ -0,0 +1,7 @@
1
+ import * as React from 'react';
2
+ interface ListItemProps {
3
+ children?: React.ReactNode;
4
+ funcss?: string;
5
+ }
6
+ export default function ListItem({ children, funcss, ...rest }: ListItemProps): import("react/jsx-runtime").JSX.Element;
7
+ export {};
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.default = ListItem;
26
+ var jsx_runtime_1 = require("react/jsx-runtime");
27
+ function ListItem(_a) {
28
+ var children = _a.children, funcss = _a.funcss, rest = __rest(_a, ["children", "funcss"]);
29
+ return ((0, jsx_runtime_1.jsx)("li", __assign({ className: "list ".concat(funcss ? funcss : '') }, rest, { children: children })));
30
+ }
@@ -0,0 +1,14 @@
1
+ import * as React from 'react';
2
+ interface ListProps {
3
+ children?: React.ReactNode;
4
+ funcss?: string;
5
+ dark?: boolean;
6
+ light?: boolean;
7
+ stripped?: boolean;
8
+ bordered?: boolean;
9
+ hoverable?: boolean;
10
+ roundItems?: boolean;
11
+ gap?: number;
12
+ }
13
+ export default function List({ children, funcss, dark, light, stripped, bordered, hoverable, roundItems, gap, ...rest }: ListProps): import("react/jsx-runtime").JSX.Element;
14
+ export {};
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.default = List;
26
+ var jsx_runtime_1 = require("react/jsx-runtime");
27
+ function List(_a) {
28
+ var children = _a.children, funcss = _a.funcss, dark = _a.dark, light = _a.light, stripped = _a.stripped, bordered = _a.bordered, hoverable = _a.hoverable, roundItems = _a.roundItems, gap = _a.gap, rest = __rest(_a, ["children", "funcss", "dark", "light", "stripped", "bordered", "hoverable", "roundItems", "gap"]);
29
+ return ((0, jsx_runtime_1.jsx)("ul", __assign({ className: "list\n ".concat(funcss ? funcss : '', "\n ").concat(dark ? 'dark' : '', "\n ").concat(light ? 'light' : '', "\n ").concat(hoverable ? 'hoverableList' : '', "\n ").concat(stripped ? 'stripped' : '', "\n ").concat(bordered ? 'bordered' : '', "\n ").concat(roundItems ? 'roundItems' : '', "\n "), style: { gap: gap ? gap + "rem" : '' } }, rest, { children: children })));
30
+ }
@@ -0,0 +1,10 @@
1
+ interface FunLoaderProps {
2
+ funcss?: string;
3
+ size?: number;
4
+ fixed?: boolean;
5
+ backdrop?: boolean;
6
+ color?: string;
7
+ variant?: 'simple' | 'duotone' | "circle";
8
+ }
9
+ export default function FunLoader({ funcss, size, fixed, backdrop, color, variant, ...rest }: FunLoaderProps): import("react/jsx-runtime").JSX.Element;
10
+ export {};
@@ -0,0 +1,37 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.default = FunLoader;
26
+ var jsx_runtime_1 = require("react/jsx-runtime");
27
+ var pi_1 = require("react-icons/pi");
28
+ function FunLoader(_a) {
29
+ var funcss = _a.funcss, size = _a.size, fixed = _a.fixed, backdrop = _a.backdrop, color = _a.color, variant = _a.variant, rest = __rest(_a, ["funcss", "size", "fixed", "backdrop", "color", "variant"]);
30
+ return ((0, jsx_runtime_1.jsx)("div", __assign({ style: { lineHeight: "0" }, className: "".concat(fixed ? 'fixedLoader' : '', " ").concat(backdrop && fixed ? 'backdropLoader' : '') }, rest, { children: variant === 'simple' ?
31
+ (0, jsx_runtime_1.jsx)("span", { className: "rotate ".concat(funcss ? funcss : '', " text-").concat(color ? color : ''), children: (0, jsx_runtime_1.jsx)(pi_1.PiSpinnerDuotone, { style: { fontSize: size + "px", display: 'block' } }) })
32
+ : variant === 'duotone' ?
33
+ (0, jsx_runtime_1.jsxs)("span", { className: "rotate ".concat(funcss ? funcss : '', " text-").concat(color ? color : ''), children: [(0, jsx_runtime_1.jsx)(pi_1.PiSpinnerDuotone, { style: { fontSize: size + "px", display: 'block' } }), " "] })
34
+ : variant === 'circle' ?
35
+ (0, jsx_runtime_1.jsx)("span", { className: "rotate ".concat(funcss ? funcss : '', " text-").concat(color ? color : ''), children: (0, jsx_runtime_1.jsx)(pi_1.PiCircleNotch, {}) })
36
+ : (0, jsx_runtime_1.jsx)("span", { className: "rotate ".concat(funcss ? funcss : '', " text-").concat(color ? color : ''), children: (0, jsx_runtime_1.jsx)(pi_1.PiSpinner, { style: { fontSize: size + "px", display: 'block' } }) }) })));
37
+ }
@@ -0,0 +1,7 @@
1
+ import * as React from 'react';
2
+ interface ModalActionProps extends React.HTMLProps<HTMLDivElement> {
3
+ funcss?: string;
4
+ children?: React.ReactNode;
5
+ }
6
+ export default function ModalAction({ funcss, children, ...rest }: ModalActionProps): import("react/jsx-runtime").JSX.Element;
7
+ export {};
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.default = ModalAction;
26
+ var jsx_runtime_1 = require("react/jsx-runtime");
27
+ function ModalAction(_a) {
28
+ var funcss = _a.funcss, children = _a.children, rest = __rest(_a, ["funcss", "children"]);
29
+ return ((0, jsx_runtime_1.jsx)("div", __assign({ className: "".concat(funcss, " modal-action") }, rest, { children: children })));
30
+ }
@@ -0,0 +1,6 @@
1
+ import { HTMLProps } from 'react';
2
+ interface CloseModalProps extends HTMLProps<HTMLDivElement> {
3
+ funcss?: string;
4
+ }
5
+ export default function CloseModal({ funcss, ...rest }: CloseModalProps): import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.default = CloseModal;
26
+ var jsx_runtime_1 = require("react/jsx-runtime");
27
+ var pi_1 = require("react-icons/pi");
28
+ function CloseModal(_a) {
29
+ var funcss = _a.funcss, rest = __rest(_a, ["funcss"]);
30
+ return ((0, jsx_runtime_1.jsx)("div", __assign({ className: "".concat(funcss || '', " closeModal") }, rest, { children: (0, jsx_runtime_1.jsx)(pi_1.PiX, {}) })));
31
+ }
@@ -0,0 +1,7 @@
1
+ import * as React from 'react';
2
+ interface ModalContentProps {
3
+ funcss?: string;
4
+ children?: React.ReactNode;
5
+ }
6
+ export default function ModalContent({ funcss, children, }: ModalContentProps): import("react/jsx-runtime").JSX.Element;
7
+ export {};
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = ModalContent;
4
+ var jsx_runtime_1 = require("react/jsx-runtime");
5
+ function ModalContent(_a) {
6
+ var funcss = _a.funcss, children = _a.children;
7
+ return ((0, jsx_runtime_1.jsx)("div", { className: "modal-body ".concat(funcss), children: children }));
8
+ }
@@ -0,0 +1,9 @@
1
+ import * as React from 'react';
2
+ interface ModalHeaderProps {
3
+ funcss?: string;
4
+ children?: React.ReactNode;
5
+ close?: React.ReactNode | '';
6
+ title?: React.ReactNode;
7
+ }
8
+ export default function ModalHeader({ funcss, children, close, title, ...rest }: ModalHeaderProps): import("react/jsx-runtime").JSX.Element;
9
+ export {};
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ var __rest = (this && this.__rest) || function (s, e) {
14
+ var t = {};
15
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
16
+ t[p] = s[p];
17
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
18
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
19
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
20
+ t[p[i]] = s[p[i]];
21
+ }
22
+ return t;
23
+ };
24
+ Object.defineProperty(exports, "__esModule", { value: true });
25
+ exports.default = ModalHeader;
26
+ var jsx_runtime_1 = require("react/jsx-runtime");
27
+ function ModalHeader(_a) {
28
+ var funcss = _a.funcss, children = _a.children, close = _a.close, title = _a.title, rest = __rest(_a, ["funcss", "children", "close", "title"]);
29
+ return ((0, jsx_runtime_1.jsxs)("div", __assign({ className: "".concat(funcss, " modal-title") }, rest, { children: [(0, jsx_runtime_1.jsx)("div", { className: "fit", children: title ? title : children }), " ", (0, jsx_runtime_1.jsx)("div", { children: close ? close : '' })] })));
30
+ }
@@ -0,0 +1,32 @@
1
+ import * as React from 'react';
2
+ interface ModalProps {
3
+ children?: React.ReactNode;
4
+ funcss?: string;
5
+ animation?: string;
6
+ duration?: number;
7
+ open: boolean;
8
+ setOpen: (val: boolean) => void;
9
+ maxWidth?: string;
10
+ maxHeight?: string;
11
+ height?: string;
12
+ width?: string;
13
+ backdrop?: boolean;
14
+ body?: React.ReactNode;
15
+ bodycss?: string;
16
+ title?: React.ReactNode;
17
+ okIcon?: React.ReactNode;
18
+ titlecss?: string;
19
+ footer?: React.ReactNode;
20
+ footercss?: string;
21
+ close?: React.ReactNode;
22
+ closecss?: string;
23
+ id?: string;
24
+ position?: string;
25
+ flat?: boolean;
26
+ onOk?: () => void;
27
+ onOkText?: string;
28
+ }
29
+ export default function Modal({ children, funcss, animation, duration, open, setOpen, maxWidth, maxHeight, okIcon, height, width, backdrop, title, titlecss, body, bodycss, footer, footercss, close, closecss, position, id, flat, onOk, // 👈 added
30
+ onOkText, // 👈 added
31
+ ...rest }: ModalProps): import("react/jsx-runtime").JSX.Element | null;
32
+ export {};
@@ -0,0 +1,61 @@
1
+ "use strict";
2
+ 'use client';
3
+ var __assign = (this && this.__assign) || function () {
4
+ __assign = Object.assign || function(t) {
5
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
6
+ s = arguments[i];
7
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
8
+ t[p] = s[p];
9
+ }
10
+ return t;
11
+ };
12
+ return __assign.apply(this, arguments);
13
+ };
14
+ var __rest = (this && this.__rest) || function (s, e) {
15
+ var t = {};
16
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
17
+ t[p] = s[p];
18
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
19
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
20
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
21
+ t[p[i]] = s[p[i]];
22
+ }
23
+ return t;
24
+ };
25
+ var __importDefault = (this && this.__importDefault) || function (mod) {
26
+ return (mod && mod.__esModule) ? mod : { "default": mod };
27
+ };
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ exports.default = Modal;
30
+ var jsx_runtime_1 = require("react/jsx-runtime");
31
+ var Header_1 = __importDefault(require("./Header"));
32
+ var Content_1 = __importDefault(require("./Content"));
33
+ var Action_1 = __importDefault(require("./Action"));
34
+ var pi_1 = require("react-icons/pi");
35
+ var Button_1 = __importDefault(require("../button/Button"));
36
+ function Modal(_a) {
37
+ var children = _a.children, funcss = _a.funcss, animation = _a.animation, duration = _a.duration, open = _a.open, setOpen = _a.setOpen, maxWidth = _a.maxWidth, maxHeight = _a.maxHeight, okIcon = _a.okIcon, height = _a.height, width = _a.width, _b = _a.backdrop, backdrop = _b === void 0 ? false : _b, title = _a.title, titlecss = _a.titlecss, body = _a.body, bodycss = _a.bodycss, footer = _a.footer, footercss = _a.footercss, close = _a.close, closecss = _a.closecss, position = _a.position, id = _a.id, flat = _a.flat, onOk = _a.onOk, // 👈 added
38
+ onOkText = _a.onOkText, // 👈 added
39
+ rest = __rest(_a, ["children", "funcss", "animation", "duration", "open", "setOpen", "maxWidth", "maxHeight", "okIcon", "height", "width", "backdrop", "title", "titlecss", "body", "bodycss", "footer", "footercss", "close", "closecss", "position", "id", "flat", "onOk", "onOkText"]);
40
+ var modalId = id || '_mymodal';
41
+ var handleClickOutside = function (e) {
42
+ if (e.target && e.target.id === modalId) {
43
+ setOpen(false);
44
+ }
45
+ };
46
+ var handleOkClick = function () {
47
+ if (onOk)
48
+ onOk();
49
+ else
50
+ setOpen(false); // default behavior if no onOk is provided
51
+ };
52
+ if (!open)
53
+ return null;
54
+ return ((0, jsx_runtime_1.jsx)("div", { className: "modal ".concat(backdrop ? 'backdrop' : '', " ").concat(position || ''), id: modalId, onClick: handleClickOutside, children: (0, jsx_runtime_1.jsxs)("div", __assign({ className: "modal-content ".concat(funcss || '', " ").concat(flat ? 'flat' : ''), style: {
55
+ animation: "".concat(duration || 0.2, "s ").concat(animation || 'ScaleUp'),
56
+ maxWidth: maxWidth || undefined,
57
+ maxHeight: maxHeight || undefined,
58
+ width: width || undefined,
59
+ height: height || undefined,
60
+ } }, rest, { children: [title && ((0, jsx_runtime_1.jsx)(Header_1.default, { funcss: titlecss || '', title: title, close: (0, jsx_runtime_1.jsx)("div", { onClick: function () { return setOpen(false); }, className: "".concat(closecss || '', " pointer hover-text-error"), children: close || (0, jsx_runtime_1.jsx)(pi_1.PiX, { size: 25 }) }) })), body && ((0, jsx_runtime_1.jsx)(Content_1.default, { funcss: bodycss || '', children: body })), footer ? ((0, jsx_runtime_1.jsx)(Action_1.default, { funcss: footercss || '', children: footer })) : ((0, jsx_runtime_1.jsx)(Action_1.default, { funcss: 'text-right', children: (0, jsx_runtime_1.jsx)(Button_1.default, { bg: 'success800', endIcon: okIcon || (0, jsx_runtime_1.jsx)(pi_1.PiPaperPlaneRight, {}), raised: true, onClick: handleOkClick, children: onOkText || 'OK' }) })), children] })) }));
61
+ }
@@ -0,0 +1,7 @@
1
+ import * as React from 'react';
2
+ type NotificationContentProps = {
3
+ funcss?: string;
4
+ children?: React.ReactNode;
5
+ };
6
+ export default function NotificationContent({ funcss, children }: NotificationContentProps): import("react/jsx-runtime").JSX.Element;
7
+ export {};
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = NotificationContent;
4
+ var jsx_runtime_1 = require("react/jsx-runtime");
5
+ function NotificationContent(_a) {
6
+ var funcss = _a.funcss, children = _a.children;
7
+ return ((0, jsx_runtime_1.jsx)("div", { className: "notificationContent ".concat(funcss ? funcss : ''), children: children }));
8
+ }
@@ -0,0 +1,7 @@
1
+ import * as React from 'react';
2
+ type NotificationFooterProps = {
3
+ funcss?: string;
4
+ children?: React.ReactNode;
5
+ };
6
+ export default function NotificationFooter({ funcss, children }: NotificationFooterProps): import("react/jsx-runtime").JSX.Element;
7
+ export {};
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = NotificationFooter;
4
+ var jsx_runtime_1 = require("react/jsx-runtime");
5
+ function NotificationFooter(_a) {
6
+ var funcss = _a.funcss, children = _a.children;
7
+ return ((0, jsx_runtime_1.jsx)("div", { className: "notificationFooter ".concat(funcss ? funcss : ''), children: children }));
8
+ }