@rufous/ui 0.1.39 → 0.1.43
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/Buttons/index.cjs +65 -11
- package/dist/Buttons/index.js +2 -1
- package/dist/Buttons/submitButton.cjs +61 -7
- package/dist/Buttons/submitButton.d.cts +2 -1
- package/dist/Buttons/submitButton.d.ts +2 -1
- package/dist/Buttons/submitButton.js +2 -1
- package/dist/Dialogs/BaseDialog.css +58 -3
- package/dist/Dialogs/BaseDialog.js +9 -8
- package/dist/Dialogs/index.css +58 -3
- package/dist/Dialogs/index.js +9 -8
- package/dist/Progress/circularProgress.cjs +60 -0
- package/dist/Progress/circularProgress.d.cts +9 -0
- package/dist/Progress/circularProgress.d.ts +9 -0
- package/dist/Progress/circularProgress.js +6 -0
- package/dist/chunk-VJUSHVAE.js +53 -0
- package/dist/chunk-YRFUVQDN.js +31 -0
- package/dist/icons/index.js +16 -16
- package/dist/main.cjs +73 -19
- package/dist/main.css +58 -3
- package/dist/main.js +18 -17
- package/dist/style.css +58 -3
- package/dist/styles/button.css +21 -3
- package/dist/styles/progress.css +36 -0
- package/dist/styles/progress.d.cts +2 -0
- package/dist/styles/progress.d.ts +2 -0
- package/package.json +1 -1
- package/dist/chunk-3WUD5EX4.js +0 -25
package/dist/Buttons/index.cjs
CHANGED
|
@@ -44,36 +44,90 @@ var AddButton = ({ children, ...props }) => {
|
|
|
44
44
|
var addButton_default = AddButton;
|
|
45
45
|
|
|
46
46
|
// lib/Buttons/submitButton.tsx
|
|
47
|
+
var React3 = __toESM(require("react"), 1);
|
|
48
|
+
|
|
49
|
+
// lib/Progress/circularProgress.tsx
|
|
47
50
|
var React2 = __toESM(require("react"), 1);
|
|
51
|
+
var CircularProgess = ({
|
|
52
|
+
size = 50,
|
|
53
|
+
color = "#a81c08",
|
|
54
|
+
...props
|
|
55
|
+
}) => {
|
|
56
|
+
return /* @__PURE__ */ React2.createElement(
|
|
57
|
+
"div",
|
|
58
|
+
{
|
|
59
|
+
className: "rufous-loader",
|
|
60
|
+
style: { width: size, height: size },
|
|
61
|
+
...props
|
|
62
|
+
},
|
|
63
|
+
/* @__PURE__ */ React2.createElement("svg", { viewBox: "0 0 100 100" }, /* @__PURE__ */ React2.createElement(
|
|
64
|
+
"circle",
|
|
65
|
+
{
|
|
66
|
+
className: "rufous-loader-circle",
|
|
67
|
+
cx: "50",
|
|
68
|
+
cy: "50",
|
|
69
|
+
r: "45",
|
|
70
|
+
stroke: color
|
|
71
|
+
}
|
|
72
|
+
))
|
|
73
|
+
);
|
|
74
|
+
};
|
|
75
|
+
var circularProgress_default = CircularProgess;
|
|
76
|
+
|
|
77
|
+
// lib/Buttons/submitButton.tsx
|
|
48
78
|
var SubmitButton = ({
|
|
49
79
|
children,
|
|
50
80
|
type = "submit",
|
|
51
81
|
onClick,
|
|
52
|
-
|
|
82
|
+
onDoubleClick,
|
|
83
|
+
isLoading = false,
|
|
53
84
|
bgGradiant = false,
|
|
54
85
|
...props
|
|
55
86
|
}) => {
|
|
87
|
+
const [loading, setLoading] = React3.useState(false);
|
|
88
|
+
const handleClick = async (e) => {
|
|
89
|
+
if (loading) return;
|
|
90
|
+
if (onClick) {
|
|
91
|
+
setLoading(true);
|
|
92
|
+
try {
|
|
93
|
+
await onClick(e);
|
|
94
|
+
} finally {
|
|
95
|
+
setLoading(false);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
};
|
|
99
|
+
const handleDoubleClick = async (e) => {
|
|
100
|
+
if (loading) return;
|
|
101
|
+
if (onDoubleClick) {
|
|
102
|
+
setLoading(true);
|
|
103
|
+
try {
|
|
104
|
+
await onDoubleClick(e);
|
|
105
|
+
} finally {
|
|
106
|
+
setLoading(false);
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
};
|
|
56
110
|
const buttonProps = {
|
|
57
111
|
...props,
|
|
58
|
-
className: `btn submit-btn ${bgGradiant
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
112
|
+
className: `btn submit-btn ${bgGradiant ? "submit-btn-gradiant" : ""} ${props.className ?? ""}`,
|
|
113
|
+
disabled: props.disabled || loading || isLoading,
|
|
114
|
+
...onClick ? {} : { type },
|
|
115
|
+
onClick: handleClick,
|
|
116
|
+
onDoubleClick: handleDoubleClick
|
|
63
117
|
};
|
|
64
|
-
return /* @__PURE__ */
|
|
118
|
+
return /* @__PURE__ */ React3.createElement("button", { ...buttonProps }, /* @__PURE__ */ React3.createElement("span", { className: "btn-content" }, children, (loading || isLoading) && /* @__PURE__ */ React3.createElement("span", { className: "btn-loader" }, /* @__PURE__ */ React3.createElement(circularProgress_default, { size: 18 }))));
|
|
65
119
|
};
|
|
66
120
|
var submitButton_default = SubmitButton;
|
|
67
121
|
|
|
68
122
|
// lib/Buttons/cancelButton.tsx
|
|
69
|
-
var
|
|
70
|
-
var CancelButton = ({ children, ...props }) => /* @__PURE__ */
|
|
123
|
+
var React4 = __toESM(require("react"), 1);
|
|
124
|
+
var CancelButton = ({ children, ...props }) => /* @__PURE__ */ React4.createElement("button", { className: "btn cancel-btn", ...props }, children);
|
|
71
125
|
var cancelButton_default = CancelButton;
|
|
72
126
|
|
|
73
127
|
// lib/Buttons/stdButton.tsx
|
|
74
|
-
var
|
|
128
|
+
var React5 = __toESM(require("react"), 1);
|
|
75
129
|
var StandardButton = ({ children, ...props }) => {
|
|
76
|
-
return /* @__PURE__ */
|
|
130
|
+
return /* @__PURE__ */ React5.createElement("button", { className: "btn standard-btn", ...props }, children);
|
|
77
131
|
};
|
|
78
132
|
var stdButton_default = StandardButton;
|
|
79
133
|
// Annotate the CommonJS export names for ESM import in node:
|
package/dist/Buttons/index.js
CHANGED
|
@@ -10,7 +10,8 @@ import {
|
|
|
10
10
|
} from "../chunk-R3GARAVJ.js";
|
|
11
11
|
import {
|
|
12
12
|
submitButton_default
|
|
13
|
-
} from "../chunk-
|
|
13
|
+
} from "../chunk-VJUSHVAE.js";
|
|
14
|
+
import "../chunk-YRFUVQDN.js";
|
|
14
15
|
export {
|
|
15
16
|
addButton_default as AddButton,
|
|
16
17
|
cancelButton_default as CancelButton,
|
|
@@ -32,23 +32,77 @@ __export(submitButton_exports, {
|
|
|
32
32
|
default: () => submitButton_default
|
|
33
33
|
});
|
|
34
34
|
module.exports = __toCommonJS(submitButton_exports);
|
|
35
|
+
var React2 = __toESM(require("react"), 1);
|
|
36
|
+
|
|
37
|
+
// lib/Progress/circularProgress.tsx
|
|
35
38
|
var React = __toESM(require("react"), 1);
|
|
39
|
+
var CircularProgess = ({
|
|
40
|
+
size = 50,
|
|
41
|
+
color = "#a81c08",
|
|
42
|
+
...props
|
|
43
|
+
}) => {
|
|
44
|
+
return /* @__PURE__ */ React.createElement(
|
|
45
|
+
"div",
|
|
46
|
+
{
|
|
47
|
+
className: "rufous-loader",
|
|
48
|
+
style: { width: size, height: size },
|
|
49
|
+
...props
|
|
50
|
+
},
|
|
51
|
+
/* @__PURE__ */ React.createElement("svg", { viewBox: "0 0 100 100" }, /* @__PURE__ */ React.createElement(
|
|
52
|
+
"circle",
|
|
53
|
+
{
|
|
54
|
+
className: "rufous-loader-circle",
|
|
55
|
+
cx: "50",
|
|
56
|
+
cy: "50",
|
|
57
|
+
r: "45",
|
|
58
|
+
stroke: color
|
|
59
|
+
}
|
|
60
|
+
))
|
|
61
|
+
);
|
|
62
|
+
};
|
|
63
|
+
var circularProgress_default = CircularProgess;
|
|
64
|
+
|
|
65
|
+
// lib/Buttons/submitButton.tsx
|
|
36
66
|
var SubmitButton = ({
|
|
37
67
|
children,
|
|
38
68
|
type = "submit",
|
|
39
69
|
onClick,
|
|
40
|
-
|
|
70
|
+
onDoubleClick,
|
|
71
|
+
isLoading = false,
|
|
41
72
|
bgGradiant = false,
|
|
42
73
|
...props
|
|
43
74
|
}) => {
|
|
75
|
+
const [loading, setLoading] = React2.useState(false);
|
|
76
|
+
const handleClick = async (e) => {
|
|
77
|
+
if (loading) return;
|
|
78
|
+
if (onClick) {
|
|
79
|
+
setLoading(true);
|
|
80
|
+
try {
|
|
81
|
+
await onClick(e);
|
|
82
|
+
} finally {
|
|
83
|
+
setLoading(false);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
const handleDoubleClick = async (e) => {
|
|
88
|
+
if (loading) return;
|
|
89
|
+
if (onDoubleClick) {
|
|
90
|
+
setLoading(true);
|
|
91
|
+
try {
|
|
92
|
+
await onDoubleClick(e);
|
|
93
|
+
} finally {
|
|
94
|
+
setLoading(false);
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
};
|
|
44
98
|
const buttonProps = {
|
|
45
99
|
...props,
|
|
46
|
-
className: `btn submit-btn ${bgGradiant
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
100
|
+
className: `btn submit-btn ${bgGradiant ? "submit-btn-gradiant" : ""} ${props.className ?? ""}`,
|
|
101
|
+
disabled: props.disabled || loading || isLoading,
|
|
102
|
+
...onClick ? {} : { type },
|
|
103
|
+
onClick: handleClick,
|
|
104
|
+
onDoubleClick: handleDoubleClick
|
|
51
105
|
};
|
|
52
|
-
return /* @__PURE__ */
|
|
106
|
+
return /* @__PURE__ */ React2.createElement("button", { ...buttonProps }, /* @__PURE__ */ React2.createElement("span", { className: "btn-content" }, children, (loading || isLoading) && /* @__PURE__ */ React2.createElement("span", { className: "btn-loader" }, /* @__PURE__ */ React2.createElement(circularProgress_default, { size: 18 }))));
|
|
53
107
|
};
|
|
54
108
|
var submitButton_default = SubmitButton;
|
|
@@ -5,7 +5,8 @@ interface SubmitButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement
|
|
|
5
5
|
type?: "button" | "submit" | "reset";
|
|
6
6
|
bgGradiant?: boolean;
|
|
7
7
|
onClick?: React.MouseEventHandler<HTMLButtonElement>;
|
|
8
|
-
|
|
8
|
+
onDoubleClick?: React.MouseEventHandler<HTMLButtonElement>;
|
|
9
|
+
isLoading?: boolean;
|
|
9
10
|
}
|
|
10
11
|
declare const SubmitButton: React.FC<SubmitButtonProps>;
|
|
11
12
|
|
|
@@ -5,7 +5,8 @@ interface SubmitButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement
|
|
|
5
5
|
type?: "button" | "submit" | "reset";
|
|
6
6
|
bgGradiant?: boolean;
|
|
7
7
|
onClick?: React.MouseEventHandler<HTMLButtonElement>;
|
|
8
|
-
|
|
8
|
+
onDoubleClick?: React.MouseEventHandler<HTMLButtonElement>;
|
|
9
|
+
isLoading?: boolean;
|
|
9
10
|
}
|
|
10
11
|
declare const SubmitButton: React.FC<SubmitButtonProps>;
|
|
11
12
|
|
|
@@ -58,16 +58,34 @@
|
|
|
58
58
|
background: #a21b07;
|
|
59
59
|
color: #fff;
|
|
60
60
|
transition: background-color 250ms ease-in-out;
|
|
61
|
+
display: inline-flex;
|
|
62
|
+
align-items: center;
|
|
63
|
+
justify-content: center;
|
|
64
|
+
gap: 8px;
|
|
61
65
|
}
|
|
62
|
-
.submit-btn:hover {
|
|
66
|
+
.submit-btn:hover:not(:disabled) {
|
|
63
67
|
background-color: #9b1906;
|
|
64
68
|
}
|
|
65
69
|
.submit-btn.submit-btn-gradiant {
|
|
66
70
|
background:
|
|
67
|
-
|
|
71
|
+
linear-gradient(
|
|
68
72
|
250deg,
|
|
69
73
|
#9b1906 0%,
|
|
70
|
-
#e62508 100%)
|
|
74
|
+
#e62508 100%);
|
|
75
|
+
}
|
|
76
|
+
.submit-btn:disabled {
|
|
77
|
+
background-color: #e0e0e0;
|
|
78
|
+
color: #9e9e9e;
|
|
79
|
+
cursor: not-allowed;
|
|
80
|
+
}
|
|
81
|
+
.btn-content {
|
|
82
|
+
display: inline-flex;
|
|
83
|
+
align-items: center;
|
|
84
|
+
gap: 8px;
|
|
85
|
+
}
|
|
86
|
+
.btn-loader {
|
|
87
|
+
display: flex;
|
|
88
|
+
align-items: center;
|
|
71
89
|
}
|
|
72
90
|
.add-btn {
|
|
73
91
|
min-width: fit-content;
|
|
@@ -206,6 +224,43 @@
|
|
|
206
224
|
}
|
|
207
225
|
}
|
|
208
226
|
|
|
227
|
+
/* lib/styles/progress.css */
|
|
228
|
+
.rufous-loader {
|
|
229
|
+
position: relative;
|
|
230
|
+
display: inline-block;
|
|
231
|
+
}
|
|
232
|
+
.rufous-loader svg {
|
|
233
|
+
transform: rotate(-45deg);
|
|
234
|
+
}
|
|
235
|
+
.rufous-loader-circle {
|
|
236
|
+
fill: none;
|
|
237
|
+
stroke-width: 9;
|
|
238
|
+
stroke-linecap: round;
|
|
239
|
+
stroke-dasharray: 283;
|
|
240
|
+
stroke-dashoffset: 280;
|
|
241
|
+
transform-origin: 50% 50%;
|
|
242
|
+
animation: rufous-rotate 1.3s linear infinite, rufous-dash 1.3s ease-in-out infinite;
|
|
243
|
+
}
|
|
244
|
+
@keyframes rufous-rotate {
|
|
245
|
+
100% {
|
|
246
|
+
transform: rotate(360deg);
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
@keyframes rufous-dash {
|
|
250
|
+
0% {
|
|
251
|
+
stroke-dasharray: 1, 283;
|
|
252
|
+
stroke-dashoffset: 0;
|
|
253
|
+
}
|
|
254
|
+
50% {
|
|
255
|
+
stroke-dasharray: 180, 283;
|
|
256
|
+
stroke-dashoffset: -70;
|
|
257
|
+
}
|
|
258
|
+
100% {
|
|
259
|
+
stroke-dasharray: 1, 283;
|
|
260
|
+
stroke-dashoffset: -260;
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
|
|
209
264
|
/* lib/style.css */
|
|
210
265
|
.theme-rufous .act-icon svg {
|
|
211
266
|
color: #a81c08 !important;
|
|
@@ -2,10 +2,12 @@ import {
|
|
|
2
2
|
BaseDialog_default
|
|
3
3
|
} from "../chunk-CPLUOEPG.js";
|
|
4
4
|
import "../chunk-IR7ZKMED.js";
|
|
5
|
+
import "../chunk-NMMC4ATV.js";
|
|
5
6
|
import "../chunk-DXJ745NZ.js";
|
|
6
7
|
import "../chunk-BH53P2UM.js";
|
|
7
8
|
import "../chunk-XPRBPIS5.js";
|
|
8
9
|
import "../chunk-QJPQC544.js";
|
|
10
|
+
import "../chunk-QZFGQ5JM.js";
|
|
9
11
|
import "../chunk-CSKTBLQQ.js";
|
|
10
12
|
import "../chunk-ZDVP4SUD.js";
|
|
11
13
|
import "../chunk-5BB3H3YO.js";
|
|
@@ -13,7 +15,7 @@ import "../chunk-ITZTTNM2.js";
|
|
|
13
15
|
import "../chunk-WWAHNTUH.js";
|
|
14
16
|
import "../chunk-6KIFTMUN.js";
|
|
15
17
|
import "../chunk-ZJAV3FEQ.js";
|
|
16
|
-
import "../chunk-
|
|
18
|
+
import "../chunk-C7B23GTE.js";
|
|
17
19
|
import "../chunk-XCLXQOLP.js";
|
|
18
20
|
import "../chunk-ZJYLZ6I6.js";
|
|
19
21
|
import "../chunk-RNA4TTYR.js";
|
|
@@ -21,7 +23,7 @@ import "../chunk-WG3Q6GZN.js";
|
|
|
21
23
|
import "../chunk-RJ43D3XB.js";
|
|
22
24
|
import "../chunk-DE73YGRW.js";
|
|
23
25
|
import "../chunk-DMP72IAP.js";
|
|
24
|
-
import "../chunk-
|
|
26
|
+
import "../chunk-GESVGIAP.js";
|
|
25
27
|
import "../chunk-QIEQRNBE.js";
|
|
26
28
|
import "../chunk-BYJP2WNC.js";
|
|
27
29
|
import "../chunk-GYLL3HRD.js";
|
|
@@ -29,14 +31,14 @@ import "../chunk-WZTZFC36.js";
|
|
|
29
31
|
import "../chunk-QA2AYT4A.js";
|
|
30
32
|
import "../chunk-WHGVO3HV.js";
|
|
31
33
|
import "../chunk-FOUXNPQA.js";
|
|
32
|
-
import "../chunk-
|
|
34
|
+
import "../chunk-WZAU77G7.js";
|
|
33
35
|
import "../chunk-7WNPZ4B7.js";
|
|
34
36
|
import "../chunk-NSW6ZGZF.js";
|
|
35
37
|
import "../chunk-KYJ3475B.js";
|
|
36
38
|
import "../chunk-UTYIBUY2.js";
|
|
37
39
|
import "../chunk-N4EJKMJK.js";
|
|
38
40
|
import "../chunk-MKK7M3BH.js";
|
|
39
|
-
import "../chunk-
|
|
41
|
+
import "../chunk-GL43GPEM.js";
|
|
40
42
|
import "../chunk-IOEQAR2M.js";
|
|
41
43
|
import "../chunk-N26C33E6.js";
|
|
42
44
|
import "../chunk-QONKYAQ5.js";
|
|
@@ -44,7 +46,7 @@ import "../chunk-H372BAXA.js";
|
|
|
44
46
|
import "../chunk-FSRABKKC.js";
|
|
45
47
|
import "../chunk-ZAYWFYP4.js";
|
|
46
48
|
import "../chunk-5UEJAVFK.js";
|
|
47
|
-
import "../chunk-
|
|
49
|
+
import "../chunk-3IBCGGN3.js";
|
|
48
50
|
import "../chunk-MNPAE2ZF.js";
|
|
49
51
|
import "../chunk-WXXJX3FF.js";
|
|
50
52
|
import "../chunk-6FEUS4CQ.js";
|
|
@@ -52,16 +54,15 @@ import "../chunk-PPNZC5ZQ.js";
|
|
|
52
54
|
import "../chunk-JI5XMLWT.js";
|
|
53
55
|
import "../chunk-WXANSSXF.js";
|
|
54
56
|
import "../chunk-XPJVVKOU.js";
|
|
55
|
-
import "../chunk-GL43GPEM.js";
|
|
56
57
|
import "../chunk-BCGCLMKA.js";
|
|
57
58
|
import "../chunk-2FHTGYR4.js";
|
|
58
59
|
import "../chunk-AH6RCYDL.js";
|
|
59
|
-
import "../chunk-3IBCGGN3.js";
|
|
60
60
|
import "../chunk-QPGJCRBS.js";
|
|
61
61
|
import "../chunk-U7SARO5B.js";
|
|
62
62
|
import "../chunk-BMMDUQDJ.js";
|
|
63
63
|
import "../chunk-R3GARAVJ.js";
|
|
64
|
-
import "../chunk-
|
|
64
|
+
import "../chunk-VJUSHVAE.js";
|
|
65
|
+
import "../chunk-YRFUVQDN.js";
|
|
65
66
|
export {
|
|
66
67
|
BaseDialog_default as default
|
|
67
68
|
};
|
package/dist/Dialogs/index.css
CHANGED
|
@@ -58,16 +58,34 @@
|
|
|
58
58
|
background: #a21b07;
|
|
59
59
|
color: #fff;
|
|
60
60
|
transition: background-color 250ms ease-in-out;
|
|
61
|
+
display: inline-flex;
|
|
62
|
+
align-items: center;
|
|
63
|
+
justify-content: center;
|
|
64
|
+
gap: 8px;
|
|
61
65
|
}
|
|
62
|
-
.submit-btn:hover {
|
|
66
|
+
.submit-btn:hover:not(:disabled) {
|
|
63
67
|
background-color: #9b1906;
|
|
64
68
|
}
|
|
65
69
|
.submit-btn.submit-btn-gradiant {
|
|
66
70
|
background:
|
|
67
|
-
|
|
71
|
+
linear-gradient(
|
|
68
72
|
250deg,
|
|
69
73
|
#9b1906 0%,
|
|
70
|
-
#e62508 100%)
|
|
74
|
+
#e62508 100%);
|
|
75
|
+
}
|
|
76
|
+
.submit-btn:disabled {
|
|
77
|
+
background-color: #e0e0e0;
|
|
78
|
+
color: #9e9e9e;
|
|
79
|
+
cursor: not-allowed;
|
|
80
|
+
}
|
|
81
|
+
.btn-content {
|
|
82
|
+
display: inline-flex;
|
|
83
|
+
align-items: center;
|
|
84
|
+
gap: 8px;
|
|
85
|
+
}
|
|
86
|
+
.btn-loader {
|
|
87
|
+
display: flex;
|
|
88
|
+
align-items: center;
|
|
71
89
|
}
|
|
72
90
|
.add-btn {
|
|
73
91
|
min-width: fit-content;
|
|
@@ -206,6 +224,43 @@
|
|
|
206
224
|
}
|
|
207
225
|
}
|
|
208
226
|
|
|
227
|
+
/* lib/styles/progress.css */
|
|
228
|
+
.rufous-loader {
|
|
229
|
+
position: relative;
|
|
230
|
+
display: inline-block;
|
|
231
|
+
}
|
|
232
|
+
.rufous-loader svg {
|
|
233
|
+
transform: rotate(-45deg);
|
|
234
|
+
}
|
|
235
|
+
.rufous-loader-circle {
|
|
236
|
+
fill: none;
|
|
237
|
+
stroke-width: 9;
|
|
238
|
+
stroke-linecap: round;
|
|
239
|
+
stroke-dasharray: 283;
|
|
240
|
+
stroke-dashoffset: 280;
|
|
241
|
+
transform-origin: 50% 50%;
|
|
242
|
+
animation: rufous-rotate 1.3s linear infinite, rufous-dash 1.3s ease-in-out infinite;
|
|
243
|
+
}
|
|
244
|
+
@keyframes rufous-rotate {
|
|
245
|
+
100% {
|
|
246
|
+
transform: rotate(360deg);
|
|
247
|
+
}
|
|
248
|
+
}
|
|
249
|
+
@keyframes rufous-dash {
|
|
250
|
+
0% {
|
|
251
|
+
stroke-dasharray: 1, 283;
|
|
252
|
+
stroke-dashoffset: 0;
|
|
253
|
+
}
|
|
254
|
+
50% {
|
|
255
|
+
stroke-dasharray: 180, 283;
|
|
256
|
+
stroke-dashoffset: -70;
|
|
257
|
+
}
|
|
258
|
+
100% {
|
|
259
|
+
stroke-dasharray: 1, 283;
|
|
260
|
+
stroke-dashoffset: -260;
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
|
|
209
264
|
/* lib/style.css */
|
|
210
265
|
.theme-rufous .act-icon svg {
|
|
211
266
|
color: #a81c08 !important;
|
package/dist/Dialogs/index.js
CHANGED
|
@@ -2,10 +2,12 @@ import {
|
|
|
2
2
|
BaseDialog_default
|
|
3
3
|
} from "../chunk-CPLUOEPG.js";
|
|
4
4
|
import "../chunk-IR7ZKMED.js";
|
|
5
|
+
import "../chunk-NMMC4ATV.js";
|
|
5
6
|
import "../chunk-DXJ745NZ.js";
|
|
6
7
|
import "../chunk-BH53P2UM.js";
|
|
7
8
|
import "../chunk-XPRBPIS5.js";
|
|
8
9
|
import "../chunk-QJPQC544.js";
|
|
10
|
+
import "../chunk-QZFGQ5JM.js";
|
|
9
11
|
import "../chunk-CSKTBLQQ.js";
|
|
10
12
|
import "../chunk-ZDVP4SUD.js";
|
|
11
13
|
import "../chunk-5BB3H3YO.js";
|
|
@@ -13,7 +15,7 @@ import "../chunk-ITZTTNM2.js";
|
|
|
13
15
|
import "../chunk-WWAHNTUH.js";
|
|
14
16
|
import "../chunk-6KIFTMUN.js";
|
|
15
17
|
import "../chunk-ZJAV3FEQ.js";
|
|
16
|
-
import "../chunk-
|
|
18
|
+
import "../chunk-C7B23GTE.js";
|
|
17
19
|
import "../chunk-XCLXQOLP.js";
|
|
18
20
|
import "../chunk-ZJYLZ6I6.js";
|
|
19
21
|
import "../chunk-RNA4TTYR.js";
|
|
@@ -21,7 +23,7 @@ import "../chunk-WG3Q6GZN.js";
|
|
|
21
23
|
import "../chunk-RJ43D3XB.js";
|
|
22
24
|
import "../chunk-DE73YGRW.js";
|
|
23
25
|
import "../chunk-DMP72IAP.js";
|
|
24
|
-
import "../chunk-
|
|
26
|
+
import "../chunk-GESVGIAP.js";
|
|
25
27
|
import "../chunk-QIEQRNBE.js";
|
|
26
28
|
import "../chunk-BYJP2WNC.js";
|
|
27
29
|
import "../chunk-GYLL3HRD.js";
|
|
@@ -29,14 +31,14 @@ import "../chunk-WZTZFC36.js";
|
|
|
29
31
|
import "../chunk-QA2AYT4A.js";
|
|
30
32
|
import "../chunk-WHGVO3HV.js";
|
|
31
33
|
import "../chunk-FOUXNPQA.js";
|
|
32
|
-
import "../chunk-
|
|
34
|
+
import "../chunk-WZAU77G7.js";
|
|
33
35
|
import "../chunk-7WNPZ4B7.js";
|
|
34
36
|
import "../chunk-NSW6ZGZF.js";
|
|
35
37
|
import "../chunk-KYJ3475B.js";
|
|
36
38
|
import "../chunk-UTYIBUY2.js";
|
|
37
39
|
import "../chunk-N4EJKMJK.js";
|
|
38
40
|
import "../chunk-MKK7M3BH.js";
|
|
39
|
-
import "../chunk-
|
|
41
|
+
import "../chunk-GL43GPEM.js";
|
|
40
42
|
import "../chunk-IOEQAR2M.js";
|
|
41
43
|
import "../chunk-N26C33E6.js";
|
|
42
44
|
import "../chunk-QONKYAQ5.js";
|
|
@@ -44,7 +46,7 @@ import "../chunk-H372BAXA.js";
|
|
|
44
46
|
import "../chunk-FSRABKKC.js";
|
|
45
47
|
import "../chunk-ZAYWFYP4.js";
|
|
46
48
|
import "../chunk-5UEJAVFK.js";
|
|
47
|
-
import "../chunk-
|
|
49
|
+
import "../chunk-3IBCGGN3.js";
|
|
48
50
|
import "../chunk-MNPAE2ZF.js";
|
|
49
51
|
import "../chunk-WXXJX3FF.js";
|
|
50
52
|
import "../chunk-6FEUS4CQ.js";
|
|
@@ -52,16 +54,15 @@ import "../chunk-PPNZC5ZQ.js";
|
|
|
52
54
|
import "../chunk-JI5XMLWT.js";
|
|
53
55
|
import "../chunk-WXANSSXF.js";
|
|
54
56
|
import "../chunk-XPJVVKOU.js";
|
|
55
|
-
import "../chunk-GL43GPEM.js";
|
|
56
57
|
import "../chunk-BCGCLMKA.js";
|
|
57
58
|
import "../chunk-2FHTGYR4.js";
|
|
58
59
|
import "../chunk-AH6RCYDL.js";
|
|
59
|
-
import "../chunk-3IBCGGN3.js";
|
|
60
60
|
import "../chunk-QPGJCRBS.js";
|
|
61
61
|
import "../chunk-U7SARO5B.js";
|
|
62
62
|
import "../chunk-BMMDUQDJ.js";
|
|
63
63
|
import "../chunk-R3GARAVJ.js";
|
|
64
|
-
import "../chunk-
|
|
64
|
+
import "../chunk-VJUSHVAE.js";
|
|
65
|
+
import "../chunk-YRFUVQDN.js";
|
|
65
66
|
export {
|
|
66
67
|
BaseDialog_default as BaseDialog
|
|
67
68
|
};
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __export = (target, all) => {
|
|
8
|
+
for (var name in all)
|
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from))
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
21
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
22
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
23
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
24
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
25
|
+
mod
|
|
26
|
+
));
|
|
27
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
28
|
+
|
|
29
|
+
// lib/Progress/circularProgress.tsx
|
|
30
|
+
var circularProgress_exports = {};
|
|
31
|
+
__export(circularProgress_exports, {
|
|
32
|
+
default: () => circularProgress_default
|
|
33
|
+
});
|
|
34
|
+
module.exports = __toCommonJS(circularProgress_exports);
|
|
35
|
+
var React = __toESM(require("react"), 1);
|
|
36
|
+
var CircularProgess = ({
|
|
37
|
+
size = 50,
|
|
38
|
+
color = "#a81c08",
|
|
39
|
+
...props
|
|
40
|
+
}) => {
|
|
41
|
+
return /* @__PURE__ */ React.createElement(
|
|
42
|
+
"div",
|
|
43
|
+
{
|
|
44
|
+
className: "rufous-loader",
|
|
45
|
+
style: { width: size, height: size },
|
|
46
|
+
...props
|
|
47
|
+
},
|
|
48
|
+
/* @__PURE__ */ React.createElement("svg", { viewBox: "0 0 100 100" }, /* @__PURE__ */ React.createElement(
|
|
49
|
+
"circle",
|
|
50
|
+
{
|
|
51
|
+
className: "rufous-loader-circle",
|
|
52
|
+
cx: "50",
|
|
53
|
+
cy: "50",
|
|
54
|
+
r: "45",
|
|
55
|
+
stroke: color
|
|
56
|
+
}
|
|
57
|
+
))
|
|
58
|
+
);
|
|
59
|
+
};
|
|
60
|
+
var circularProgress_default = CircularProgess;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
interface CircularProgessProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
4
|
+
size?: number;
|
|
5
|
+
color?: string;
|
|
6
|
+
}
|
|
7
|
+
declare const CircularProgess: React.FC<CircularProgessProps>;
|
|
8
|
+
|
|
9
|
+
export { type CircularProgessProps, CircularProgess as default };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
|
|
3
|
+
interface CircularProgessProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
4
|
+
size?: number;
|
|
5
|
+
color?: string;
|
|
6
|
+
}
|
|
7
|
+
declare const CircularProgess: React.FC<CircularProgessProps>;
|
|
8
|
+
|
|
9
|
+
export { type CircularProgessProps, CircularProgess as default };
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import {
|
|
2
|
+
circularProgress_default
|
|
3
|
+
} from "./chunk-YRFUVQDN.js";
|
|
4
|
+
|
|
5
|
+
// lib/Buttons/submitButton.tsx
|
|
6
|
+
import * as React from "react";
|
|
7
|
+
var SubmitButton = ({
|
|
8
|
+
children,
|
|
9
|
+
type = "submit",
|
|
10
|
+
onClick,
|
|
11
|
+
onDoubleClick,
|
|
12
|
+
isLoading = false,
|
|
13
|
+
bgGradiant = false,
|
|
14
|
+
...props
|
|
15
|
+
}) => {
|
|
16
|
+
const [loading, setLoading] = React.useState(false);
|
|
17
|
+
const handleClick = async (e) => {
|
|
18
|
+
if (loading) return;
|
|
19
|
+
if (onClick) {
|
|
20
|
+
setLoading(true);
|
|
21
|
+
try {
|
|
22
|
+
await onClick(e);
|
|
23
|
+
} finally {
|
|
24
|
+
setLoading(false);
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
const handleDoubleClick = async (e) => {
|
|
29
|
+
if (loading) return;
|
|
30
|
+
if (onDoubleClick) {
|
|
31
|
+
setLoading(true);
|
|
32
|
+
try {
|
|
33
|
+
await onDoubleClick(e);
|
|
34
|
+
} finally {
|
|
35
|
+
setLoading(false);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
const buttonProps = {
|
|
40
|
+
...props,
|
|
41
|
+
className: `btn submit-btn ${bgGradiant ? "submit-btn-gradiant" : ""} ${props.className ?? ""}`,
|
|
42
|
+
disabled: props.disabled || loading || isLoading,
|
|
43
|
+
...onClick ? {} : { type },
|
|
44
|
+
onClick: handleClick,
|
|
45
|
+
onDoubleClick: handleDoubleClick
|
|
46
|
+
};
|
|
47
|
+
return /* @__PURE__ */ React.createElement("button", { ...buttonProps }, /* @__PURE__ */ React.createElement("span", { className: "btn-content" }, children, (loading || isLoading) && /* @__PURE__ */ React.createElement("span", { className: "btn-loader" }, /* @__PURE__ */ React.createElement(circularProgress_default, { size: 18 }))));
|
|
48
|
+
};
|
|
49
|
+
var submitButton_default = SubmitButton;
|
|
50
|
+
|
|
51
|
+
export {
|
|
52
|
+
submitButton_default
|
|
53
|
+
};
|