@spacego/fe-components 0.0.1-alpha.3 → 0.0.1-alpha.4
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/lib/assets/svg/chrome-bg-after.svg.js +3 -2
- package/lib/assets/svg/chrome-bg-before.svg.js +2 -1
- package/lib/assets/svg/icon-arrows-right.svg.js +3 -2
- package/lib/assets/svg/icon-bell.svg.js +3 -2
- package/lib/assets/svg/icon-custom.svg.js +3 -2
- package/lib/assets/svg/icon-sun-moon.svg.js +3 -2
- package/lib/assets/svg/icon-system.svg.js +3 -2
- package/lib/assets/svg/login-view.svg.js +871 -2
- package/lib/fe-layouts/auth-layout/index.js +8 -8
- package/lib/fe-layouts/basics-layout/components/basics-layout/tabs.js +5 -5
- package/package.json +1 -1
|
@@ -16,9 +16,9 @@ import "antd";
|
|
|
16
16
|
import { useGlobal as C } from "../context/context.js";
|
|
17
17
|
/* empty css */
|
|
18
18
|
import "../basics-layout/index.js";
|
|
19
|
-
function
|
|
20
|
-
const { appName: s, logo: n } = C(), { theme: o, themeColor: c, TOGGLE_THEME: m, SET_THEME_COLOR: f } = T(p(["theme", "themeColor", "TOGGLE_THEME", "SET_THEME_COLOR"])), [a,
|
|
21
|
-
const
|
|
19
|
+
function q() {
|
|
20
|
+
const { appName: s, logo: n } = C(), { theme: o, themeColor: c, TOGGLE_THEME: m, SET_THEME_COLOR: f } = T(p(["theme", "themeColor", "TOGGLE_THEME", "SET_THEME_COLOR"])), [a, i] = u(!1), d = (r) => {
|
|
21
|
+
const l = r.currentTarget.getBoundingClientRect(), h = l.left + l.width / 2, x = l.top + l.height / 2;
|
|
22
22
|
k(o === "light" ? "dark" : "light", h, x).then(() => {
|
|
23
23
|
m();
|
|
24
24
|
});
|
|
@@ -40,8 +40,8 @@ function A() {
|
|
|
40
40
|
opacity: a ? 1 : 0,
|
|
41
41
|
transition: "transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1), width 0.3s cubic-bezier(0.4, 0, 0.2, 1)"
|
|
42
42
|
},
|
|
43
|
-
onMouseEnter: () =>
|
|
44
|
-
onMouseLeave: () =>
|
|
43
|
+
onMouseEnter: () => i(!0),
|
|
44
|
+
onMouseLeave: () => i(!1),
|
|
45
45
|
children: E.map((r) => /* @__PURE__ */ e(
|
|
46
46
|
"div",
|
|
47
47
|
{
|
|
@@ -59,8 +59,8 @@ function A() {
|
|
|
59
59
|
"div",
|
|
60
60
|
{
|
|
61
61
|
className: "w-8 h-8 flex items-center justify-center cursor-pointer hover-scale-animation",
|
|
62
|
-
onMouseEnter: () =>
|
|
63
|
-
onMouseLeave: () =>
|
|
62
|
+
onMouseEnter: () => i(!0),
|
|
63
|
+
onMouseLeave: () => i(!1),
|
|
64
64
|
children: /* @__PURE__ */ e(N, { className: "h-[16px] w-[16px] text-(--color-primary)" })
|
|
65
65
|
}
|
|
66
66
|
),
|
|
@@ -91,5 +91,5 @@ function A() {
|
|
|
91
91
|
] });
|
|
92
92
|
}
|
|
93
93
|
export {
|
|
94
|
-
|
|
94
|
+
q as default
|
|
95
95
|
};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { jsx as r, jsxs as i, Fragment as u } from "react/jsx-runtime";
|
|
2
2
|
import { classnames as s } from "@spacego/turbo-utils";
|
|
3
3
|
import { Divider as x } from "antd";
|
|
4
|
-
import { useRef as
|
|
5
|
-
import { MdClear as
|
|
4
|
+
import { useRef as v, useState as b, useEffect as g } from "react";
|
|
5
|
+
import { MdClear as k } from "react-icons/md";
|
|
6
6
|
import y from "../../../../assets/svg/chrome-bg-after.svg.js";
|
|
7
7
|
import w from "../../../../assets/svg/chrome-bg-before.svg.js";
|
|
8
8
|
function z(c) {
|
|
9
|
-
const { tabs: o, activeKey: d, onChange: f, onClose: h } = c, n =
|
|
9
|
+
const { tabs: o, activeKey: d, onChange: f, onClose: h } = c, n = v(null), [l, m] = b(!1), a = () => {
|
|
10
10
|
const e = n.current;
|
|
11
11
|
if (e) {
|
|
12
12
|
const t = e.scrollWidth > e.clientWidth;
|
|
13
13
|
m(t);
|
|
14
14
|
}
|
|
15
15
|
};
|
|
16
|
-
return
|
|
16
|
+
return g(() => (a(), window.addEventListener("resize", a), () => {
|
|
17
17
|
window.removeEventListener("resize", a);
|
|
18
18
|
}), [o]), /* @__PURE__ */ r(
|
|
19
19
|
"div",
|
|
@@ -43,7 +43,7 @@ function z(c) {
|
|
|
43
43
|
onClick: (p) => {
|
|
44
44
|
p.stopPropagation(), h(e.key);
|
|
45
45
|
},
|
|
46
|
-
children: /* @__PURE__ */ r(
|
|
46
|
+
children: /* @__PURE__ */ r(k, { className: "text-xs text-[#333333] dark:text-[#cfd0d0] hover:text-black dark:hover:text-white transition-all" })
|
|
47
47
|
}
|
|
48
48
|
)
|
|
49
49
|
]
|