@raketa-builder/ui 0.7.0 → 0.8.0
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/.turbo/turbo-build.log +3 -3
- package/dist/index.js +47 -0
- package/package.json +1 -1
- package/src/CategoriesMenu.js +53 -0
- package/src/index.js +1 -0
- package/src/styles.css +80 -0
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @raketa-builder/ui@0.
|
|
2
|
+
> @raketa-builder/ui@0.8.0 build
|
|
3
3
|
> tsup src/index.js --format cjs --loader ".js=jsx"
|
|
4
4
|
|
|
5
5
|
CLI Building entry: src/index.js
|
|
@@ -7,5 +7,5 @@ CLI Using tsconfig: tsconfig.json
|
|
|
7
7
|
CLI tsup v6.5.0
|
|
8
8
|
CLI Target: es6
|
|
9
9
|
CJS Build start
|
|
10
|
-
CJS dist/index.js
|
|
11
|
-
CJS ⚡️ Build success in
|
|
10
|
+
CJS dist/index.js 30.99 KB
|
|
11
|
+
CJS ⚡️ Build success in 164ms
|
package/dist/index.js
CHANGED
|
@@ -56,6 +56,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
56
56
|
var src_exports = {};
|
|
57
57
|
__export(src_exports, {
|
|
58
58
|
Button: () => Button_default,
|
|
59
|
+
CategoriesMenu: () => CategoriesMenu_default,
|
|
59
60
|
Col: () => Col,
|
|
60
61
|
Container: () => Container_default,
|
|
61
62
|
DataGrid: () => DataGrid_default,
|
|
@@ -794,9 +795,55 @@ DefaultAvatar.defaultProps = {
|
|
|
794
795
|
initials: "AA"
|
|
795
796
|
};
|
|
796
797
|
var DefaultAvatar_default = DefaultAvatar;
|
|
798
|
+
|
|
799
|
+
// src/CategoriesMenu.js
|
|
800
|
+
var import_react26 = __toESM(require("react"));
|
|
801
|
+
var import_jsx_runtime26 = require("react/jsx-runtime");
|
|
802
|
+
var IconsWrapper = () => /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "r-reset r-categories-icons-wrapper", children: [
|
|
803
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
804
|
+
"img",
|
|
805
|
+
{
|
|
806
|
+
style: {
|
|
807
|
+
color: "#fff",
|
|
808
|
+
width: "24px",
|
|
809
|
+
height: "24px",
|
|
810
|
+
filter: "invert(1)"
|
|
811
|
+
},
|
|
812
|
+
alt: "directions",
|
|
813
|
+
src: "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGNsYXNzPSJmZWF0aGVyIGZlYXRoZXItZ3JpZCI+PHJlY3QgeD0iMyIgeT0iMyIgd2lkdGg9IjciIGhlaWdodD0iNyI+PC9yZWN0PjxyZWN0IHg9IjE0IiB5PSIzIiB3aWR0aD0iNyIgaGVpZ2h0PSI3Ij48L3JlY3Q+PHJlY3QgeD0iMTQiIHk9IjE0IiB3aWR0aD0iNyIgaGVpZ2h0PSI3Ij48L3JlY3Q+PHJlY3QgeD0iMyIgeT0iMTQiIHdpZHRoPSI3IiBoZWlnaHQ9IjciPjwvcmVjdD48L3N2Zz4="
|
|
814
|
+
}
|
|
815
|
+
),
|
|
816
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
|
|
817
|
+
"img",
|
|
818
|
+
{
|
|
819
|
+
className: "r-reset r-category-chevron",
|
|
820
|
+
alt: "directions",
|
|
821
|
+
src: "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIiIGhlaWdodD0iMTMiIHZpZXdCb3g9IjAgMCAyMiAxMyIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTIxIDExLjVMMTEgMS41TDEgMTEuNSIgc3Ryb2tlPSIjMEMwQTA5IiBzdHJva2Utd2lkdGg9IjIiLz4KPC9zdmc+Cg=="
|
|
822
|
+
}
|
|
823
|
+
)
|
|
824
|
+
] });
|
|
825
|
+
var Title2 = () => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "r-categories-title", children: "Categories" });
|
|
826
|
+
var CategoriesInner = (_a) => {
|
|
827
|
+
var props = __objRest(_a, []);
|
|
828
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", __spreadProps(__spreadValues({}, props), { className: "r-reset r-categories-inner" }));
|
|
829
|
+
};
|
|
830
|
+
var CategoriesHiddenMenu = ({ paths }) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "r-reset r-categories-hidden-menu", children: paths.map(({ title, link }) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("a", { href: link, className: "r-reset r-category-link", children: title })) });
|
|
831
|
+
var CategoriesMenuWrapper = (_a) => {
|
|
832
|
+
var props = __objRest(_a, []);
|
|
833
|
+
return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", __spreadValues({ className: "r-reset r-categories-menu" }, props));
|
|
834
|
+
};
|
|
835
|
+
var CategoriesMenu = ({ paths }) => /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(CategoriesMenuWrapper, { children: [
|
|
836
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(CategoriesInner, { children: [
|
|
837
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(IconsWrapper, {}),
|
|
838
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Title2, {})
|
|
839
|
+
] }),
|
|
840
|
+
/* @__PURE__ */ (0, import_jsx_runtime26.jsx)(CategoriesHiddenMenu, { paths })
|
|
841
|
+
] });
|
|
842
|
+
var CategoriesMenu_default = CategoriesMenu;
|
|
797
843
|
// Annotate the CommonJS export names for ESM import in node:
|
|
798
844
|
0 && (module.exports = {
|
|
799
845
|
Button,
|
|
846
|
+
CategoriesMenu,
|
|
800
847
|
Col,
|
|
801
848
|
Container,
|
|
802
849
|
DataGrid,
|
package/package.json
CHANGED
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
const IconsWrapper = () => (
|
|
3
|
+
<div className="r-reset r-categories-icons-wrapper">
|
|
4
|
+
<img
|
|
5
|
+
style={{
|
|
6
|
+
color: "#fff",
|
|
7
|
+
width: "24px",
|
|
8
|
+
height: "24px",
|
|
9
|
+
filter: "invert(1)",
|
|
10
|
+
}}
|
|
11
|
+
alt="directions"
|
|
12
|
+
src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIiBzdHJva2U9ImN1cnJlbnRDb2xvciIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiIGNsYXNzPSJmZWF0aGVyIGZlYXRoZXItZ3JpZCI+PHJlY3QgeD0iMyIgeT0iMyIgd2lkdGg9IjciIGhlaWdodD0iNyI+PC9yZWN0PjxyZWN0IHg9IjE0IiB5PSIzIiB3aWR0aD0iNyIgaGVpZ2h0PSI3Ij48L3JlY3Q+PHJlY3QgeD0iMTQiIHk9IjE0IiB3aWR0aD0iNyIgaGVpZ2h0PSI3Ij48L3JlY3Q+PHJlY3QgeD0iMyIgeT0iMTQiIHdpZHRoPSI3IiBoZWlnaHQ9IjciPjwvcmVjdD48L3N2Zz4="
|
|
13
|
+
/>
|
|
14
|
+
|
|
15
|
+
<img
|
|
16
|
+
className="r-reset r-category-chevron"
|
|
17
|
+
alt="directions"
|
|
18
|
+
src="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjIiIGhlaWdodD0iMTMiIHZpZXdCb3g9IjAgMCAyMiAxMyIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTIxIDExLjVMMTEgMS41TDEgMTEuNSIgc3Ryb2tlPSIjMEMwQTA5IiBzdHJva2Utd2lkdGg9IjIiLz4KPC9zdmc+Cg=="
|
|
19
|
+
/>
|
|
20
|
+
</div>
|
|
21
|
+
);
|
|
22
|
+
const Title = () => <div className="r-categories-title">Categories</div>;
|
|
23
|
+
|
|
24
|
+
const CategoriesInner = ({ ...props }) => (
|
|
25
|
+
<div {...props} className="r-reset r-categories-inner" />
|
|
26
|
+
);
|
|
27
|
+
|
|
28
|
+
const CategoriesHiddenMenu = ({ paths }) => (
|
|
29
|
+
<div className="r-reset r-categories-hidden-menu">
|
|
30
|
+
{paths.map(({ title, link }) => (
|
|
31
|
+
<a href={link} className="r-reset r-category-link">
|
|
32
|
+
{title}
|
|
33
|
+
</a>
|
|
34
|
+
))}
|
|
35
|
+
</div>
|
|
36
|
+
);
|
|
37
|
+
|
|
38
|
+
const CategoriesMenuWrapper = ({ ...props }) => (
|
|
39
|
+
<div className="r-reset r-categories-menu" {...props} />
|
|
40
|
+
);
|
|
41
|
+
|
|
42
|
+
const CategoriesMenu = ({ paths }) => (
|
|
43
|
+
<CategoriesMenuWrapper>
|
|
44
|
+
<CategoriesInner>
|
|
45
|
+
<IconsWrapper />
|
|
46
|
+
|
|
47
|
+
<Title />
|
|
48
|
+
</CategoriesInner>
|
|
49
|
+
<CategoriesHiddenMenu paths={paths} />
|
|
50
|
+
</CategoriesMenuWrapper>
|
|
51
|
+
);
|
|
52
|
+
|
|
53
|
+
export default CategoriesMenu;
|
package/src/index.js
CHANGED
|
@@ -27,3 +27,4 @@ export { default as LanguageSwitcher } from "./LanguageSwitcher";
|
|
|
27
27
|
export { default as ImageAvatar } from "./ImageAvatar";
|
|
28
28
|
export { default as DefaultAvatar } from "./DefaultAvatar";
|
|
29
29
|
export { default as cn } from "./cn";
|
|
30
|
+
export { default as CategoriesMenu } from "./CategoriesMenu";
|
package/src/styles.css
CHANGED
|
@@ -744,6 +744,86 @@
|
|
|
744
744
|
padding-top: 1rem;
|
|
745
745
|
padding-bottom: 1rem;
|
|
746
746
|
}
|
|
747
|
+
|
|
748
|
+
.r-categories-menu {
|
|
749
|
+
position: relative;
|
|
750
|
+
width: 100%;
|
|
751
|
+
padding: 0 0.25rem;
|
|
752
|
+
}
|
|
753
|
+
.r-categories-menu:hover .r-category-chevron {
|
|
754
|
+
transform: rotate(90deg);
|
|
755
|
+
transition: all 0.3s ease-in-out;
|
|
756
|
+
}
|
|
757
|
+
.r-categories-menu:hover .r-categories-hidden-menu {
|
|
758
|
+
transform: translateX(64px);
|
|
759
|
+
transition: all 0.3s ease-in-out;
|
|
760
|
+
}
|
|
761
|
+
.r-categories-menu:hover .r-categories-inner {
|
|
762
|
+
background-color: #4b4b4b;
|
|
763
|
+
}
|
|
764
|
+
|
|
765
|
+
.r-categories-inner {
|
|
766
|
+
position: relative;
|
|
767
|
+
z-index: 100;
|
|
768
|
+
padding: 0.25rem;
|
|
769
|
+
display: flex;
|
|
770
|
+
align-items: center;
|
|
771
|
+
justify-content: center;
|
|
772
|
+
flex-direction: column;
|
|
773
|
+
gap: 0.5rem;
|
|
774
|
+
background-color: #000;
|
|
775
|
+
border-radius: 4px;
|
|
776
|
+
}
|
|
777
|
+
|
|
778
|
+
.r-categories-title {
|
|
779
|
+
color: #fff;
|
|
780
|
+
font-size: 10px;
|
|
781
|
+
}
|
|
782
|
+
|
|
783
|
+
.r-categories-icons-wrapper {
|
|
784
|
+
display: flex;
|
|
785
|
+
align-items: center;
|
|
786
|
+
justify-content: center;
|
|
787
|
+
gap: 0.25rem;
|
|
788
|
+
}
|
|
789
|
+
|
|
790
|
+
.r-category-chevron {
|
|
791
|
+
color: #fff;
|
|
792
|
+
width: 12px;
|
|
793
|
+
height: 12px;
|
|
794
|
+
filter: invert(1);
|
|
795
|
+
transform: rotate(-90deg);
|
|
796
|
+
transition: all 0.3s ease-in-out;
|
|
797
|
+
}
|
|
798
|
+
|
|
799
|
+
.r-categories-hidden-menu {
|
|
800
|
+
position: absolute;
|
|
801
|
+
z-index: 99;
|
|
802
|
+
top: 0;
|
|
803
|
+
left: 0;
|
|
804
|
+
bottom: 0;
|
|
805
|
+
background-color: #000;
|
|
806
|
+
display: flex;
|
|
807
|
+
align-items: center;
|
|
808
|
+
gap: 0.5rem;
|
|
809
|
+
transform: translateX(-100%);
|
|
810
|
+
transition: all 0.3s ease-in-out;
|
|
811
|
+
}
|
|
812
|
+
|
|
813
|
+
.r-category-link {
|
|
814
|
+
padding: 0.25rem 0.5rem;
|
|
815
|
+
display: flex;
|
|
816
|
+
align-items: center;
|
|
817
|
+
height: 100%;
|
|
818
|
+
color: #fff;
|
|
819
|
+
font-size: 13px;
|
|
820
|
+
text-decoration: none;
|
|
821
|
+
white-space: nowrap;
|
|
822
|
+
}
|
|
823
|
+
|
|
824
|
+
.r-category-link:hover {
|
|
825
|
+
background-color: #4b4b4b;
|
|
826
|
+
}
|
|
747
827
|
}
|
|
748
828
|
|
|
749
829
|
:root {
|