@factorearth/component-library 2.0.1-alpha.0 → 3.0.0-alpha.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.
@@ -1,2 +1,7 @@
1
- import React from 'react';
2
- export declare const MoreHorizonButton: () => React.JSX.Element;
1
+ import React from "react";
2
+ import { Colors } from "@../../Theme/types";
3
+ interface MoreHorizonButtonProps {
4
+ colorPalette: Colors;
5
+ }
6
+ export declare const MoreHorizonButton: ({ colorPalette }: MoreHorizonButtonProps) => React.JSX.Element;
7
+ export {};
@@ -1,5 +1,111 @@
1
- import React from 'react';
2
- export const MoreHorizonButton = () => {
3
- return (React.createElement("div", null, "MoreHorizonButton"));
1
+ import React, { useState, useRef, useEffect } from "react";
2
+ import styled from "@emotion/styled";
3
+ import { FiClock, FiMoreVertical, FiRefreshCw } from "react-icons/fi";
4
+ const MoreHorizonPipe = styled.div `
5
+ color: ${({ colorPalette }) => colorPalette.text.primary};
6
+ display: flex;
7
+ align-items: center;
8
+ justify-content: center;
9
+ font-family: Arial;
10
+ font-size: 12px;
11
+ font-style: normal;
12
+ font-weight: 700;
13
+ line-height: normal;
14
+ `;
15
+ const MoreHorizonIcon = styled.div `
16
+ position: relative;
17
+ left: ${({ menuOpen }) => (menuOpen ? "95px" : "0px")};
18
+ `;
19
+ const MoreHorizonContainer = styled.div `
20
+ display: flex;
21
+ height: 14px;
22
+ width: 16px;
23
+ padding: 12px 8px;
24
+ align-items: center;
25
+ justify-content: center;
26
+ flex-shrink: 0;
27
+ border-radius: 0px 4px 4px 0px;
28
+ border-color: ${({ colorPalette }) => colorPalette.border.primary};
29
+ border-style: solid;
30
+ border-width: 1px;
31
+ border-left: none;
32
+ background-color: ${({ colorPalette }) => colorPalette.background.primary};
33
+ `;
34
+ const MoreHorizonOption = styled.div `
35
+ padding: 6px 12px;
36
+ display: flex;
37
+ align-items: center;
38
+ justify-content: center;
39
+ gap: 4px;
40
+ width: 69px;
41
+ height: 21px;
42
+ font-size: 14px;
43
+ font-style: normal;
44
+ font-weight: 700;
45
+ line-height: 150%;
46
+ cursor: pointer;
47
+ color: ${({ colorPalette }) => colorPalette.text.primary};
48
+ `;
49
+ const MoreHorizonMenu = styled.div `
50
+ display: ${({ menuOpen }) => (menuOpen ? "flex" : "none")};
51
+ position: relative;
52
+ top: ${({ yPosition }) => (yPosition === "down" ? "40px " : "-40px")};
53
+ left: ${({ xPosition }) => xPosition === "center" ? "-8px !important" : xPosition === "right" ? "70px" : "-85px"};
54
+ flex-direction: row;
55
+ background-color: ${({ colorPalette }) => colorPalette.highlight.secondary};
56
+ border-radius: 4px;
57
+ box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.1);
58
+ z-index: 1000;
59
+ transform-origin: top left;
60
+ `;
61
+ export const MoreHorizonButton = ({ colorPalette }) => {
62
+ const [menuOpen, setMenuOpen] = useState(false);
63
+ const [yPosition, setYPosition] = useState("up");
64
+ const [xPosition, setXPosition] = useState("center");
65
+ const menuRef = useRef(null);
66
+ const buttonRef = useRef(null);
67
+ useEffect(() => {
68
+ const handleMenuPosition = () => {
69
+ if (menuRef.current && buttonRef.current) {
70
+ const menuRect = menuRef.current.getBoundingClientRect();
71
+ const buttonRect = buttonRef.current.getBoundingClientRect();
72
+ const windowWidth = window.innerWidth;
73
+ if (menuRect.height + buttonRect.height > buttonRect.y) {
74
+ setYPosition("down");
75
+ }
76
+ else {
77
+ setYPosition("up");
78
+ }
79
+ if (buttonRect.width > buttonRect.x) {
80
+ setXPosition("right");
81
+ }
82
+ if (buttonRect.x + menuRect.width > windowWidth) {
83
+ setXPosition("left");
84
+ }
85
+ else {
86
+ setXPosition("center");
87
+ }
88
+ }
89
+ };
90
+ handleMenuPosition();
91
+ window.addEventListener("resize", handleMenuPosition);
92
+ return () => {
93
+ window.removeEventListener("resize", handleMenuPosition);
94
+ };
95
+ }, [menuOpen]);
96
+ const toggleMenu = () => {
97
+ setMenuOpen(!menuOpen);
98
+ };
99
+ return (React.createElement(MoreHorizonContainer, { colorPalette: colorPalette, ref: buttonRef, onClick: toggleMenu },
100
+ React.createElement(MoreHorizonIcon, { menuOpen: menuOpen },
101
+ React.createElement(FiMoreVertical, { color: colorPalette.text.primary })),
102
+ React.createElement(MoreHorizonMenu, { menuOpen: menuOpen, colorPalette: colorPalette, ref: menuRef, yPosition: yPosition, xPosition: xPosition },
103
+ React.createElement(MoreHorizonOption, { colorPalette: colorPalette },
104
+ React.createElement(FiClock, null),
105
+ "History"),
106
+ React.createElement(MoreHorizonPipe, { colorPalette: colorPalette }, "|"),
107
+ React.createElement(MoreHorizonOption, { colorPalette: colorPalette },
108
+ React.createElement(FiRefreshCw, null),
109
+ "Refresh"))));
4
110
  };
5
111
  //# sourceMappingURL=MoreHorizonButton.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MoreHorizonButton.js","sourceRoot":"","sources":["../../../lib/Atoms/MoreHorizonButton/MoreHorizonButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAI,EAAE;IACrC,OAAO,CACL,qDAA4B,CAC7B,CAAA;AACH,CAAC,CAAA"}
1
+ {"version":3,"file":"MoreHorizonButton.js","sourceRoot":"","sources":["../../../lib/Atoms/MoreHorizonButton/MoreHorizonButton.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAC3D,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAErC,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAEtE,MAAM,eAAe,GAAG,MAAM,CAAC,GAAG,CAA0B;UAClD,CAAC,EAAE,YAAY,EAAE,EAAE,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,OAAO;;;;;;;;;CASxD,CAAC;AAEF,MAAM,eAAe,GAAG,MAAM,CAAC,GAA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QAAQ,EAAE,kBAAkB,CAAC,CAAC;QAEtD,OAAO,GAAG,EAAE;YACX,MAAM,CAAC,mBAAmB,CAAC,QAAQ,EAAE,kBAAkB,CAAC,CAAC;QAC1D,CAAC,CAAC;IACH,CAAC,EAAE,CAAC,QAAQ,CAAC,CAAC,CAAC;IAEf,MAAM,UAAU,GAAG,GAAG,EAAE;QACvB,WAAW,CAAC,CAAC,QAAQ,CAAC,CAAC;IACxB,CAAC,CAAC;IACF,OAAO,CACN,oBAAC,oBAAoB,IACpB,YAAY,EAAE,YAAY,EAC1B,GAAG,EAAE,SAAS,EACd,OAAO,EAAE,UAAU;QAEnB,oBAAC,eAAe,IAAC,QAAQ,EAAE,QAAQ;YAClC,oBAAC,cAAc,IAAC,KAAK,EAAE,YAAY,CAAC,IAAI,CAAC,OAAO,GAAI,CACnC;QAClB,oBAAC,eAAe,IACf,QAAQ,EAAE,QAAQ,EAClB,YAAY,EAAE,YAAY,EAC1B,GAAG,EAAE,OAAO,EACZ,SAAS,EAAE,SAAS,EACpB,SAAS,EAAE,SAAS;YAEpB,oBAAC,iBAAiB,IAAC,YAAY,EAAE,YAAY;gBAC5C,oBAAC,OAAO,OAAG;0BAEQ;YACpB,oBAAC,eAAe,IAAC,YAAY,EAAE,YAAY,QAAqB;YAChE,oBAAC,iBAAiB,IAAC,YAAY,EAAE,YAAY;gBAC5C,oBAAC,WAAW,OAAG;0BAEI,CACH,CACI,CACvB,CAAC;AACH,CAAC,CAAC"}
@@ -1,2 +1,10 @@
1
- import React from 'react';
2
- export declare const NumberField: () => React.JSX.Element;
1
+ import React from "react";
2
+ import { Colors } from "Theme/types";
3
+ interface NumberFieldProps {
4
+ colorPalette: Colors & string;
5
+ handleChange: (event: React.ChangeEvent<HTMLInputElement>) => void;
6
+ handleBlur: () => void;
7
+ fromTable?: boolean;
8
+ }
9
+ export declare const NumberField: ({ colorPalette, handleChange, handleBlur, fromTable }: NumberFieldProps) => React.JSX.Element;
10
+ export {};
@@ -1,5 +1,90 @@
1
- import React from 'react';
2
- export const NumberField = () => {
3
- return (React.createElement("div", null, "NumberField"));
1
+ import React, { useState, useRef } from "react";
2
+ import styled from "@emotion/styled";
3
+ import { FiPlus, FiMinus } from "react-icons/fi";
4
+ import { MoreHorizonButton } from "../MoreHorizonButton/MoreHorizonButton";
5
+ const NumberFieldContainer = styled.div `
6
+ display: flex;
7
+ min-width: 180px;
8
+ align-items: center;
9
+ gap: -0.5px;
10
+ `;
11
+ const NumberInput = styled.input `
12
+ display: flex;
13
+ justify-content: center;
14
+ align-items: center;
15
+ text-align: center;
16
+ gap: 10px;
17
+ align-self: stretch;
18
+ color: ${({ color }) => color.text.primary};
19
+ background: ${({ color }) => color.background.primary};
20
+ border-width: 1px;
21
+ border-style: solid;
22
+ border-color: ${({ color }) => color.border.primary};
23
+ border-right: none;
24
+ border-left: none;
25
+ &::-webkit-inner-spin-button,
26
+ ::-webkit-outer-spin-button {
27
+ -webkit-appearance: none;
28
+ margin: 0;
29
+ }
30
+ `;
31
+ const DecrementButton = styled.div `
32
+ cursor: pointer;
33
+ display: flex;
34
+ width: 16px;
35
+ height: 22px;
36
+ padding: 8px 16px;
37
+ justify-content: center;
38
+ align-items: center;
39
+ border-radius: 4px 0px 0px 4px;
40
+ border-width: 1px;
41
+ border-style: solid;
42
+ border-color: ${({ color }) => color.border.primary};
43
+ background: ${({ color }) => color.background.primary};
44
+ color: ${({ color }) => color.text.primary};
45
+ `;
46
+ const IncrementButton = styled.div `
47
+ cursor: pointer;
48
+ display: flex;
49
+ width: 16px;
50
+ height: 22px;
51
+ padding: 8px 16px;
52
+ justify-content: center;
53
+ align-items: center;
54
+ border-width: 1px;
55
+ border-style: solid;
56
+ border-color: ${({ color }) => color.border.primary};
57
+ background: ${({ color }) => color.background.primary};
58
+ color: ${({ color }) => color.text.primary};
59
+ `;
60
+ export const NumberField = ({ colorPalette, handleChange, handleBlur, fromTable }) => {
61
+ const [value, setValue] = useState();
62
+ const ref = useRef(null);
63
+ const handleIncrement = () => {
64
+ if (value === undefined) {
65
+ setValue(1);
66
+ return;
67
+ }
68
+ setValue(value + 1);
69
+ };
70
+ const handleDecrement = () => {
71
+ if (value === undefined) {
72
+ setValue(1);
73
+ return;
74
+ }
75
+ setValue(value - 1);
76
+ };
77
+ const handleFocus = () => {
78
+ if (fromTable) {
79
+ ref.current?.scrollIntoView({ block: "center", behavior: "smooth", inline: "center" });
80
+ }
81
+ };
82
+ return (React.createElement(NumberFieldContainer, { color: colorPalette },
83
+ React.createElement(DecrementButton, { color: colorPalette, onClick: handleDecrement },
84
+ React.createElement(FiMinus, null)),
85
+ React.createElement(NumberInput, { value: value, onChange: handleChange, onBlur: handleBlur, type: "number", color: colorPalette, ref: ref, onFocus: handleFocus }),
86
+ React.createElement(IncrementButton, { color: colorPalette, onClick: handleIncrement },
87
+ React.createElement(FiPlus, null)),
88
+ React.createElement(MoreHorizonButton, { colorPalette: colorPalette })));
4
89
  };
5
90
  //# sourceMappingURL=NumberField.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"NumberField.js","sourceRoot":"","sources":["../../../lib/Atoms/NumberField/NumberField.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,MAAM,CAAC,MAAM,WAAW,GAAG,GAAI,EAAE;IAC/B,OAAO,CACL,+CAAsB,CACvB,CAAA;AACH,CAAC,CAAA"}
1
+ {"version":3,"file":"NumberField.js","sourceRoot":"","sources":["../../../lib/Atoms/NumberField/NumberField.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAChD,OAAO,MAAM,MAAM,iBAAiB,CAAC;AACrC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AACjD,OAAO,EAAE,iBAAiB,EAAE,MAAM,wCAAwC,CAAC;AAG3E,MAAM,oBAAoB,GAAG,MAAM,CAAC,GAAG,CAAmB;;;;;CAKzD,C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,KAAK,KAAK,SAAS,EAAE,CAAC;YACzB,QAAQ,CAAC,CAAC,CAAC,CAAC;YACZ,OAAO;QACR,CAAC;QACD,QAAQ,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC;IACrB,CAAC,CAAC;IAEF,MAAM,eAAe,GAAG,GAAG,EAAE;QAC5B,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;YACzB,QAAQ,CAAC,CAAC,CAAC,CAAC;YACZ,OAAO;QACR,CAAC;QACD,QAAQ,CAAC,KAAK,GAAG,CAAC,CAAC,CAAC;IACrB,CAAC,CAAC;IAEF,MAAM,WAAW,GAAG,GAAG,EAAE;QACxB,IAAI,SAAS,EAAE,CAAC;YACf,GAAG,CAAC,OAAO,EAAE,cAAc,CAAC,EAAE,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,CAAC;QACxF,CAAC;IACF,CAAC,CAAA;IAED,OAAO,CACN,oBAAC,oBAAoB,IAAC,KAAK,EAAE,YAAY;QACxC,oBAAC,eAAe,IAAC,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,eAAe;YAC7D,oBAAC,OAAO,OAAG,CACM;QAClB,oBAAC,WAAW,IACX,KAAK,EAAE,KAAK,EACZ,QAAQ,EAAE,YAAY,EACtB,MAAM,EAAE,UAAU,EAClB,IAAI,EAAC,QAAQ,EACb,KAAK,EAAE,YAAY,EACnB,GAAG,EAAE,GAAG,EACR,OAAO,EAAE,WAAW,GACnB;QACF,oBAAC,eAAe,IAAC,KAAK,EAAE,YAAY,EAAE,OAAO,EAAE,eAAe;YAC7D,oBAAC,MAAM,OAAG,CACO;QAClB,oBAAC,iBAAiB,IAAE,YAAY,EAAE,YAAY,GAAG,CAC3B,CACvB,CAAC;AACH,CAAC,CAAC"}
@@ -1,2 +1,11 @@
1
- import React from 'react';
2
- export declare const Pagination: () => React.JSX.Element;
1
+ import React, { Dispatch, SetStateAction } from "react";
2
+ import { Colors } from "Theme/types";
3
+ import "./styles.css";
4
+ interface PaginationProps {
5
+ totalPages: number;
6
+ currentPage: number;
7
+ setCurrentPage: Dispatch<SetStateAction<number>>;
8
+ colorPalette: Colors;
9
+ }
10
+ export declare const Pagination: ({ totalPages, currentPage, setCurrentPage, colorPalette, }: PaginationProps) => React.JSX.Element;
11
+ export {};
@@ -1,5 +1,95 @@
1
- import React from 'react';
2
- export const Pagination = () => {
3
- return (React.createElement("div", null, "Pagination"));
1
+ import React from "react";
2
+ import styled from "@emotion/styled";
3
+ import { FiChevronLeft, FiChevronRight } from "react-icons/fi";
4
+ import "./styles.css";
5
+ const PaginationContainer = styled.div `
6
+ display: flex;
7
+ align-items: center;
8
+ justify-content: center;
9
+ gap: 16px;
10
+ background: ${({ colorPalette }) => colorPalette.background.primary};
11
+ `;
12
+ const PageNumber = styled.div(({ isActive, colorPalette, }) => ({
13
+ height: "14px",
14
+ display: "flex",
15
+ padding: "8px 12px",
16
+ justifyContent: "center",
17
+ alignItems: "center",
18
+ background: isActive ? colorPalette.text.secondary : "transparent",
19
+ color: isActive
20
+ ? colorPalette.text.badge
21
+ : colorPalette.theme === "dark"
22
+ ? colorPalette.text.primary
23
+ : colorPalette.text.primary,
24
+ borderRadius: "32px",
25
+ cursor: "pointer",
26
+ fontSize: "14px",
27
+ fontStyle: "normal",
28
+ fontWeight: 600,
29
+ lineHeight: "100%",
30
+ }));
31
+ const Ellipsis = styled.span `
32
+ height: 35px;
33
+ display: flex;
34
+ align-items: center;
35
+ justify-content: center;
36
+ color: ${({ colorPalette }) => colorPalette.text.primary};
37
+ `;
38
+ const getMinAndMax = (number, maxVisiblePages) => {
39
+ const min = Math.floor(number / maxVisiblePages) * maxVisiblePages + 1;
40
+ const max = Math.floor(number / maxVisiblePages) * maxVisiblePages + (maxVisiblePages - 1);
41
+ return { min, max };
42
+ };
43
+ export const Pagination = ({ totalPages, currentPage, setCurrentPage, colorPalette, }) => {
44
+ const maxVisiblePages = 5;
45
+ const getVisiblePages = () => {
46
+ const pages = [];
47
+ const ellipsis = "...";
48
+ if (totalPages <= maxVisiblePages) {
49
+ for (let i = 1; i <= totalPages; i++) {
50
+ pages.push(i);
51
+ }
52
+ }
53
+ else if (totalPages === currentPage) {
54
+ pages.push(ellipsis);
55
+ for (let i = totalPages - (maxVisiblePages - 1); i <= totalPages; i++) {
56
+ pages.push(i);
57
+ }
58
+ }
59
+ else {
60
+ pages.push(1);
61
+ const { min, max } = getMinAndMax(currentPage, maxVisiblePages);
62
+ const endPage = max + 1;
63
+ const startPage = min === 1 ? 2 : min - 1;
64
+ if (startPage > 2)
65
+ pages.push(ellipsis);
66
+ for (let i = startPage; i <= endPage; i++) {
67
+ pages.push(i);
68
+ }
69
+ if (endPage < totalPages - 1)
70
+ pages.push(ellipsis);
71
+ if (endPage !== totalPages)
72
+ pages.push(totalPages);
73
+ }
74
+ return pages;
75
+ };
76
+ const visiblePages = getVisiblePages();
77
+ const handlePrevious = () => {
78
+ if (currentPage === 1)
79
+ return;
80
+ setCurrentPage(currentPage - 1);
81
+ };
82
+ const handleNext = () => {
83
+ if (currentPage === totalPages)
84
+ return;
85
+ setCurrentPage(currentPage + 1);
86
+ };
87
+ const handleSkipToPage = (page) => {
88
+ setCurrentPage(page);
89
+ };
90
+ return (React.createElement(PaginationContainer, { colorPalette: colorPalette },
91
+ React.createElement(FiChevronLeft, { color: colorPalette.text.primary, className: "navigate_button", onClick: handlePrevious }),
92
+ visiblePages.map((page, index) => page === "..." ? (React.createElement(Ellipsis, { colorPalette: colorPalette, key: index }, page)) : (React.createElement(PageNumber, { key: index, isActive: page === currentPage, onClick: () => handleSkipToPage(Number(page)), colorPalette: colorPalette }, page))),
93
+ React.createElement(FiChevronRight, { color: colorPalette.text.primary, className: "navigate_button", onClick: handleNext })));
4
94
  };
5
95
  //# sourceMappingURL=Pagination.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"Pagination.js","sourceRoot":"","sources":["../../../lib/Atoms/Pagination/Pagination.tsx"],"names":[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;IACtB,CAAC,CAAC;IAEF,OAAO,CACN,oBAAC,mBAAmB,IAAC,YAAY,EAAE,YAAY;QAC9C,oBAAC,aAAa,IACb,KAAK,EAAE,YAAY,CAAC,IAAI,CAAC,OAAO,EAChC,SAAS,EAAC,iBAAiB,EAC3B,OAAO,EAAE,cAAc,GACtB;QAED,YAAY,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,CACjC,IAAI,KAAK,KAAK,CAAC,CAAC,CAAC,CAChB,oBAAC,QAAQ,IAAC,YAAY,EAAE,YAAY,EAAE,GAAG,EAAE,KAAK,IAAG,IAAI,CAAY,CACnE,CAAC,CAAC,CAAC,CACH,oBAAC,UAAU,IACV,GAAG,EAAE,KAAK,EACV,QAAQ,EAAE,IAAI,KAAK,WAAW,EAC9B,OAAO,EAAE,GAAG,EAAE,CAAC,gBAAgB,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,EAC7C,YAAY,EAAE,YAAY,IAEzB,IAAI,CACO,CACb,CACD;QACD,oBAAC,cAAc,IACd,KAAK,EAAE,YAAY,CAAC,IAAI,CAAC,OAAO,EAChC,SAAS,EAAC,iBAAiB,EAC3B,OAAO,EAAE,UAAU,GAClB,CACmB,CACtB,CAAC;AACH,CAAC,CAAC"}
@@ -1,5 +1,38 @@
1
- import React from 'react';
1
+ import React, { useState } from 'react';
2
+ import styled from '@emotion/styled';
3
+ import Select from 'react-select';
4
+ const PhoneNumberContainer = styled.div `
5
+ display: flex;
6
+ align-items: center;
7
+ gap: 8px;
8
+ `;
9
+ const CountryCodeSelect = styled(Select) `
10
+ width: 100px;
11
+ `;
12
+ const NumberInput = styled.input `
13
+ padding: 8px;
14
+ border: 1px solid #ccc;
15
+ border-radius: 4px;
16
+ width: 100%;
17
+ `;
18
+ const countryOptions = [
19
+ { label: '+1 (US)', value: '+1' },
20
+ { label: '+44 (UK)', value: '+44' },
21
+ { label: '+91 (IN)', value: '+91' },
22
+ { label: '+61 (AU)', value: '+61' },
23
+ // Add more country codes as needed
24
+ ];
2
25
  export const PhoneNumberField = () => {
3
- return (React.createElement("div", null, "PhoneNumberField"));
26
+ const [selectedCountry, setSelectedCountry] = useState(countryOptions[0]);
27
+ const [phoneNumber, setPhoneNumber] = useState('');
28
+ const handleCountryChange = (option) => {
29
+ setSelectedCountry(option);
30
+ };
31
+ const handlePhoneNumberChange = (e) => {
32
+ setPhoneNumber(e.target.value);
33
+ };
34
+ return (React.createElement(PhoneNumberContainer, null,
35
+ React.createElement(CountryCodeSelect, { options: countryOptions, value: selectedCountry, isSearchable: false, placeholder: "Code" }),
36
+ React.createElement(NumberInput, { type: "tel", value: phoneNumber, onChange: handlePhoneNumberChange, placeholder: "Phone Number" })));
4
37
  };
5
38
  //# sourceMappingURL=PhoneNumberField.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"PhoneNumberField.js","sourceRoot":"","sources":["../../../lib/Atoms/PhoneNumberField/PhoneNumberField.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAI,EAAE;IACpC,OAAO,CACL,oDAA2B,CAC5B,CAAA;AACH,CAAC,CAAA"}
1
+ {"version":3,"file":"PhoneNumberField.js","sourceRoot":"","sources":["../../../lib/Atoms/PhoneNumberField/PhoneNumberField.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,MAAM,MAAM,iBAAiB,CAAC;AACrC,OAAO,MAAM,MAAM,cAAc,CAAC;AAElC,MAAM,oBAAoB,GAAG,MAAM,CAAC,GAAG,CAAA;;;;CAItC,CAAC;AAEF,MAAM,iBAAiB,GAAG,MAAM,CAAC,MAAM,CAAC,CAAA;;CAEvC,CAAC;AAEF,MAAM,WAAW,GAAG,MAAM,CAAC,KAAK,CAAA;;;;;CAK/B,CAAC;AAOF,MAAM,cAAc,GAAoB;IACtC,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,EAAE,IAAI,EAAE;IACjC,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,EAAE;IACnC,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,EAAE;IACnC,EAAE,KAAK,EAAE,UAAU,EAAE,KAAK,EAAE,KAAK,EAAE;IACnC,mCAAmC;CACpC,CAAC;AAEF,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAAG,EAAE;IACnC,MAAM,CAAC,eAAe,EAAE,kBAAkB,CAAC,GAAG,QAAQ,CAAuB,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC;IAChG,MAAM,CAAC,WAAW,EAAE,cAAc,CAAC,GAAG,QAAQ,CAAC,EAAE,CAAC,CAAC;IAEnD,MAAM,mBAAmB,GAAG,CAAC,MAA4B,EAAE,EAAE;QAC3D,kBAAkB,CAAC,MAAM,CAAC,CAAC;IAC7B,CAAC,CAAC;IAEF,MAAM,uBAAuB,GAAG,CAAC,CAAsC,EAAE,EAAE;QACzE,cAAc,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IACjC,CAAC,CAAC;IAEF,OAAO,CACL,oBAAC,oBAAoB;QACnB,oBAAC,iBAAiB,IAChB,OAAO,EAAE,cAAc,EACvB,KAAK,EAAE,eAAe,EACtB,YAAY,EAAE,KAAK,EACnB,WAAW,EAAC,MAAM,GAClB;QACF,oBAAC,WAAW,IACV,IAAI,EAAC,KAAK,EACV,KAAK,EAAE,WAAW,EAClB,QAAQ,EAAE,uBAAuB,EACjC,WAAW,EAAC,cAAc,GAC1B,CACmB,CACxB,CAAC;AACJ,CAAC,CAAC"}
@@ -1,5 +1,84 @@
1
- import React from 'react';
1
+ import React, { useState, useRef, useEffect } from 'react';
2
+ import styled from '@emotion/styled';
3
+ import { GoSortAsc, GoSortDesc } from "react-icons/go";
4
+ import { TiMinus } from "react-icons/ti";
5
+ const DropdownContainer = styled.div `
6
+ position: relative;
7
+ display: inline-block;
8
+ `;
9
+ const DropdownButton = styled.button `
10
+ background-color: #f0f0f0;
11
+ border: none;
12
+ padding: 10px;
13
+ border-radius: 4px;
14
+ cursor: pointer;
15
+ display: flex;
16
+ align-items: center;
17
+ `;
18
+ const Menu = styled.div `
19
+ display: ${({ isOpen }) => (isOpen ? 'block' : 'none')};
20
+ position: absolute;
21
+ top: 100%;
22
+ left: 0;
23
+ background-color: #fff;
24
+ border: 1px solid #ccc;
25
+ border-radius: 4px;
26
+ box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.1);
27
+ min-width: 200px;
28
+ z-index: 1000;
29
+ `;
30
+ const MenuItem = styled.button `
31
+ background: none;
32
+ border: none;
33
+ padding: 10px;
34
+ width: 100%;
35
+ display: flex;
36
+ align-items: center;
37
+ cursor: pointer;
38
+ transition: background-color 0.2s;
39
+
40
+ &:hover {
41
+ background-color: #f0f0f0;
42
+ }
43
+ `;
44
+ const IconContainer = styled.span `
45
+ margin-right: 8px;
46
+ display: flex;
47
+ align-items: center;
48
+ `;
2
49
  export const SortDropdown = () => {
3
- return (React.createElement("div", null, "SortDropdown"));
50
+ const [isOpen, setIsOpen] = useState(false);
51
+ const dropdownRef = useRef(null);
52
+ const toggleDropdown = () => {
53
+ setIsOpen(!isOpen);
54
+ };
55
+ const closeDropdown = (e) => {
56
+ if (dropdownRef.current && !dropdownRef.current.contains(e.target)) {
57
+ setIsOpen(false);
58
+ }
59
+ };
60
+ useEffect(() => {
61
+ document.addEventListener('mousedown', closeDropdown);
62
+ return () => {
63
+ document.removeEventListener('mousedown', closeDropdown);
64
+ };
65
+ }, []);
66
+ return (React.createElement(DropdownContainer, { ref: dropdownRef },
67
+ React.createElement(DropdownButton, { onClick: toggleDropdown },
68
+ "Menu",
69
+ React.createElement(GoSortDesc, null)),
70
+ React.createElement(Menu, { isOpen: isOpen },
71
+ React.createElement(MenuItem, { onClick: () => setIsOpen(false) },
72
+ React.createElement(IconContainer, null,
73
+ React.createElement(TiMinus, null)),
74
+ "None"),
75
+ React.createElement(MenuItem, { onClick: () => setIsOpen(false) },
76
+ React.createElement(IconContainer, null,
77
+ React.createElement(GoSortAsc, null)),
78
+ "Ascending"),
79
+ React.createElement(MenuItem, { onClick: () => setIsOpen(false) },
80
+ React.createElement(IconContainer, null,
81
+ React.createElement(GoSortDesc, null)),
82
+ "Descending"))));
4
83
  };
5
84
  //# sourceMappingURL=SortDropdown.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"SortDropdown.js","sourceRoot":"","sources":["../../../lib/Atoms/SortDropdown/SortDropdown.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,MAAM,CAAC,MAAM,YAAY,GAAG,GAAI,EAAE;IAChC,OAAO,CACL,gDAAuB,CACxB,CAAA;AACH,CAAC,CAAA"}
1
+ {"version":3,"file":"SortDropdown.js","sourceRoot":"","sources":["../../../lib/Atoms/SortDropdown/SortDropdown.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAC3D,OAAO,MAAM,MAAM,iBAAiB,CAAC;AAErC,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AACvD,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAEzC,MAAM,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAAA;;;CAGnC,CAAC;AAEF,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,CAAA;;;;;;;;CAQnC,CAAC;AAGF,MAAM,IAAI,GAAG,MAAM,CAAC,GAAG,CAAqB;aAC/B,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC;;;;;;;;;;CAUvD,CAAC;AAEF,MAAM,QAAQ,GAAG,MAAM,CAAC,MAAM,CAAA;;;;;;;;;;;;;CAa7B,C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oBACZ,oBAAC,SAAS,OAAG,CACC;4BAEP;YACX,oBAAC,QAAQ,IAAC,OAAO,EAAE,GAAG,EAAE,CAAC,SAAS,CAAC,KAAK,CAAC;gBACvC,oBAAC,aAAa;oBACZ,oBAAC,UAAU,OAAG,CACA;6BAEP,CACN,CACW,CACrB,CAAC;AACJ,CAAC,CAAC"}
@@ -0,0 +1,99 @@
1
+ import React from "react";
2
+ import { Colors } from "Theme/types";
3
+ export declare const lightTheme: {
4
+ text: {
5
+ primary: string;
6
+ secondary: string;
7
+ tertiary: string;
8
+ badge: string;
9
+ };
10
+ background: {
11
+ primary: string;
12
+ secondary: string;
13
+ tertiary: string;
14
+ tableRow: string;
15
+ };
16
+ border: {
17
+ primary: string;
18
+ secondary: string;
19
+ tertiary: string;
20
+ };
21
+ highlight: {
22
+ primary: string;
23
+ secondary: string;
24
+ };
25
+ utils: {
26
+ success: string;
27
+ error: string;
28
+ icon: string;
29
+ disabled: string;
30
+ };
31
+ theme: string;
32
+ };
33
+ export declare const darkTheme: {
34
+ text: {
35
+ primary: string;
36
+ secondary: string;
37
+ tertiary: string;
38
+ badge: string;
39
+ };
40
+ background: {
41
+ primary: string;
42
+ secondary: string;
43
+ tertiary: string;
44
+ tableRow: string;
45
+ };
46
+ border: {
47
+ primary: string;
48
+ secondary: string;
49
+ tertiary: string;
50
+ };
51
+ highlight: {
52
+ primary: string;
53
+ secondary: string;
54
+ };
55
+ utils: {
56
+ success: string;
57
+ error: string;
58
+ icon: string;
59
+ disabled: string;
60
+ };
61
+ theme: string;
62
+ };
63
+ export declare const useTheme: () => {
64
+ theme: {
65
+ text: {
66
+ primary: string;
67
+ secondary: string;
68
+ tertiary: string;
69
+ badge: string;
70
+ };
71
+ background: {
72
+ primary: string;
73
+ secondary: string;
74
+ tertiary: string;
75
+ tableRow: string;
76
+ };
77
+ border: {
78
+ primary: string;
79
+ secondary: string;
80
+ tertiary: string;
81
+ };
82
+ highlight: {
83
+ primary: string;
84
+ secondary: string;
85
+ };
86
+ utils: {
87
+ success: string;
88
+ error: string;
89
+ icon: string;
90
+ disabled: string;
91
+ };
92
+ theme: string;
93
+ };
94
+ setTheme: (themeName: "light" | "dark") => void;
95
+ };
96
+ export declare const ThemeProvider: ({ children, themeValue }: {
97
+ children: React.ReactNode;
98
+ themeValue: Colors;
99
+ }) => React.JSX.Element;
@@ -0,0 +1,103 @@
1
+ import React, { createContext, useContext, useState } from "react";
2
+ import tokens from "./tokens.json";
3
+ const { grey, blue, green, red } = {
4
+ grey: {
5
+ 200: tokens.global["Base Colors"]["200-white-grey"].value,
6
+ 300: tokens.global["Base Colors"]["300-French-grey"].value,
7
+ 400: tokens.global["Base Colors"]["400-cadet-grey"].value,
8
+ 500: tokens.global["Base Colors"]["500-slate-grey"].value,
9
+ 600: tokens.global["Base Colors"]["600-space-grey"].value,
10
+ 700: tokens.global["Base Colors"]["700-grey"].value,
11
+ },
12
+ blue: {
13
+ 300: tokens.global["Base Colors"]["300-light-blue"].value,
14
+ 700: tokens.global["Base Colors"]["700-blue"].value,
15
+ },
16
+ green: {
17
+ 500: tokens.global["Base Colors"]["500-green"].value,
18
+ },
19
+ red: {
20
+ 500: tokens.global["Base Colors"]["500-red"].value,
21
+ },
22
+ };
23
+ export const lightTheme = {
24
+ text: {
25
+ primary: grey["600"],
26
+ secondary: grey["400"],
27
+ tertiary: blue["700"],
28
+ badge: grey["700"],
29
+ },
30
+ background: {
31
+ primary: grey["200"],
32
+ secondary: grey["300"],
33
+ tertiary: blue["300"],
34
+ tableRow: blue["300"],
35
+ },
36
+ border: {
37
+ primary: grey["500"],
38
+ secondary: grey["600"],
39
+ tertiary: blue["300"],
40
+ },
41
+ highlight: {
42
+ primary: blue["700"],
43
+ secondary: blue["300"],
44
+ },
45
+ utils: {
46
+ success: green["500"],
47
+ error: red["500"],
48
+ icon: grey["700"],
49
+ disabled: grey["500"],
50
+ },
51
+ theme: "light",
52
+ };
53
+ export const darkTheme = {
54
+ text: {
55
+ primary: grey["200"],
56
+ secondary: grey["400"],
57
+ tertiary: blue["300"],
58
+ badge: grey["700"],
59
+ },
60
+ background: {
61
+ primary: grey["700"],
62
+ secondary: grey["600"],
63
+ tertiary: blue["700"],
64
+ tableRow: grey["600"],
65
+ },
66
+ border: {
67
+ primary: grey["500"],
68
+ secondary: grey["500"],
69
+ tertiary: blue["700"],
70
+ },
71
+ highlight: {
72
+ primary: grey["200"],
73
+ secondary: blue["700"],
74
+ },
75
+ utils: {
76
+ success: green["500"],
77
+ error: red["500"],
78
+ icon: grey["200"],
79
+ disabled: grey["700"],
80
+ },
81
+ theme: "dark",
82
+ };
83
+ const ThemeContext = createContext({
84
+ theme: lightTheme,
85
+ setTheme: (themeName) => { },
86
+ });
87
+ export const useTheme = () => useContext(ThemeContext);
88
+ export const ThemeProvider = ({ children, themeValue }) => {
89
+ const [theme, setTheme] = useState(lightTheme);
90
+ const toggleTheme = (themeName) => {
91
+ if (themeName === "light") {
92
+ setTheme(lightTheme);
93
+ return;
94
+ }
95
+ setTheme(darkTheme);
96
+ };
97
+ return (React.createElement(ThemeContext.Provider, { value: { theme: themeValue, setTheme: toggleTheme } },
98
+ React.createElement("div", { style: {
99
+ backgroundColor: theme.background.primary,
100
+ color: theme.text.primary,
101
+ } }, children)));
102
+ };
103
+ //# sourceMappingURL=ThemeProvider.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ThemeProvider.js","sourceRoot":"","sources":["../../lib/Theme/ThemeProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,aAAa,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACnE,OAAO,MAAM,MAAM,eAAe,CAAC;AAInC,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,GAAG,EAAE,GAAoB;IACnD,IAAI,EAAE;QACL,GAAG,EAAE,MAAM,CAAC,MAAM,CAAC,aAAa,CAAC,CAAC,gBAAgB,CAAC,CAAC,KAAK;QACzD,GAAG,EAAE,M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"parent": "Collection 1/Mode 1"
12
+ },
13
+ "300-French-grey": {
14
+ "value": "#d0d8dc",
15
+ "type": "color",
16
+ "parent": "Collection 1/Mode 1",
17
+ "description": ""
18
+ },
19
+ "400-cadet-grey": {
20
+ "value": "#9aa3ac",
21
+ "type": "color",
22
+ "parent": "Collection 1/Mode 1",
23
+ "description": ""
24
+ },
25
+ "500-slate-grey": {
26
+ "value": "#6e7a87",
27
+ "type": "color",
28
+ "parent": "Collection 1/Mode 1",
29
+ "description": ""
30
+ },
31
+ "600-space-grey": {
32
+ "value": "#2f3034",
33
+ "type": "color",
34
+ "parent": "Collection 1/Mode 1",
35
+ "description": ""
36
+ },
37
+ "700-grey": {
38
+ "value": "#1b1b1e",
39
+ "type": "color",
40
+ "parent": "Collection 1/Mode 1",
41
+ "description": ""
42
+ },
43
+ "300-light-blue": {
44
+ "value": "#ebf7ff",
45
+ "type": "color",
46
+ "parent": "Collection 1/Mode 1",
47
+ "description": ""
48
+ },
49
+ "700-blue": {
50
+ "value": "#0065a3",
51
+ "type": "color",
52
+ "parent": "Collection 1/Mode 1",
53
+ "description": ""
54
+ },
55
+ "500-green": {
56
+ "value": "#428c74",
57
+ "type": "color",
58
+ "parent": "Collection 1/Mode 1",
59
+ "description": ""
60
+ },
61
+ "500-red": {
62
+ "value": "#e8504f",
63
+ "type": "color",
64
+ "parent": "Collection 1/Mode 1",
65
+ "description": ""
66
+ }
67
+ },
68
+ "border-radius-sm": {
69
+ "value": "4",
70
+ "type": "borderRadius",
71
+ "description": "Input fields and buttons."
72
+ },
73
+ "border-radius-lg": {
74
+ "value": "20",
75
+ "type": "borderRadius"
76
+ },
77
+ "Jumbo": {
78
+ "value": {
79
+ "fontWeight": "Bold",
80
+ "fontSize": "61",
81
+ "letterSpacing": "0",
82
+ "paragraphSpacing": "0",
83
+ "fontFamily": "{System .SF Compact}",
84
+ "lineHeight": "{133}"
85
+ },
86
+ "type": "typography"
87
+ },
88
+ "System ": {
89
+ "SF Compact": {
90
+ "value": ".SF Compact",
91
+ "type": "fontFamilies"
92
+ }
93
+ },
94
+ "Thin": {
95
+ "value": ".5",
96
+ "type": "borderWidth"
97
+ },
98
+ "Heading 1": {
99
+ "value": {
100
+ "fontFamily": "{System .SF Compact}",
101
+ "fontWeight": "Bold",
102
+ "fontSize": "47",
103
+ "lineHeight": "{133}",
104
+ "letterSpacing": "0",
105
+ "paragraphSpacing": "0"
106
+ },
107
+ "type": "typography"
108
+ },
109
+ "Heading 2": {
110
+ "value": {
111
+ "fontFamily": "{System .SF Compact}",
112
+ "fontWeight": "Bold",
113
+ "fontSize": "36",
114
+ "lineHeight": "{133}",
115
+ "letterSpacing": "0",
116
+ "paragraphSpacing": "0"
117
+ },
118
+ "type": "typography"
119
+ },
120
+ "Heading 3": {
121
+ "value": {
122
+ "fontFamily": "{System .SF Compact}",
123
+ "fontWeight": "Bold",
124
+ "fontSize": "27",
125
+ "lineHeight": "{133}",
126
+ "letterSpacing": "0",
127
+ "paragraphSpacing": "0"
128
+ },
129
+ "type": "typography"
130
+ },
131
+ "Heading 4": {
132
+ "value": {
133
+ "fontFamily": "{System .SF Compact}",
134
+ "fontWeight": "Bold",
135
+ "fontSize": "21",
136
+ "lineHeight": "{133}",
137
+ "letterSpacing": "0",
138
+ "paragraphSpacing": "0"
139
+ },
140
+ "type": "typography"
141
+ },
142
+ "Paragraphy Body": {
143
+ "value": {
144
+ "fontFamily": "{System .SF Compact}",
145
+ "fontWeight": "Regular",
146
+ "fontSize": "16",
147
+ "lineHeight": "{133}",
148
+ "letterSpacing": "0",
149
+ "paragraphSpacing": "0"
150
+ },
151
+ "type": "typography"
152
+ },
153
+ "Small": {
154
+ "value": {
155
+ "fontFamily": "{System .SF Compact}",
156
+ "fontWeight": "Regular",
157
+ "fontSize": "14",
158
+ "lineHeight": "{133}",
159
+ "letterSpacing": "0",
160
+ "paragraphSpacing": "0"
161
+ },
162
+ "type": "typography"
163
+ },
164
+ "Label": {
165
+ "value": {
166
+ "fontFamily": "{System .SF Compact}",
167
+ "fontWeight": "Bold",
168
+ "fontSize": "12",
169
+ "lineHeight": "{133}",
170
+ "letterSpacing": "0",
171
+ "paragraphSpacing": "0"
172
+ },
173
+ "type": "typography"
174
+ },
175
+ "Legal": {
176
+ "value": {
177
+ "fontFamily": "{System .SF Compact}",
178
+ "fontWeight": "Regular",
179
+ "fontSize": "9",
180
+ "lineHeight": "{133}",
181
+ "paragraphSpacing": "0",
182
+ "paragraphIndent": "0"
183
+ },
184
+ "type": "typography"
185
+ }
186
+ },
187
+ "$themes": [],
188
+ "$metadata": {
189
+ "tokenSetOrder": [
190
+ "global"
191
+ ]
192
+ }
193
+ }
@@ -0,0 +1,60 @@
1
+ interface GreyColorMapping {
2
+ 200: string;
3
+ 300: string;
4
+ 400: string;
5
+ 500: string;
6
+ 600: string;
7
+ 700: string;
8
+ }
9
+ interface BlueColorMapping {
10
+ 300: string;
11
+ 700: string;
12
+ }
13
+ interface GreenColorMapping {
14
+ 500: string;
15
+ }
16
+ interface RedColorMapping {
17
+ 500: string;
18
+ }
19
+ export interface ThemeBaseColors {
20
+ grey: GreyColorMapping;
21
+ blue: BlueColorMapping;
22
+ green: GreenColorMapping;
23
+ red: RedColorMapping;
24
+ }
25
+ export interface Colors {
26
+ text: {
27
+ primary: string;
28
+ secondary: string;
29
+ tertiary: string;
30
+ badge: string;
31
+ };
32
+ background: {
33
+ primary: string;
34
+ secondary: string;
35
+ tertiary: string;
36
+ tableRow: string;
37
+ };
38
+ border: {
39
+ primary: string;
40
+ secondary: string;
41
+ tertiary: string;
42
+ };
43
+ button: {
44
+ primary: string;
45
+ secondary: string;
46
+ tertiary: string;
47
+ };
48
+ highlight: {
49
+ primary: string;
50
+ secondary: string;
51
+ };
52
+ utils: {
53
+ success: string;
54
+ error: string;
55
+ icon: string;
56
+ disabled: string;
57
+ };
58
+ theme: "light" | "dark";
59
+ }
60
+ export {};
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../lib/Theme/types.ts"],"names":[],"mappings":""}
package/dist/index.d.ts CHANGED
@@ -1,5 +1 @@
1
1
  export * from "./Atoms/MoreHorizonButton/MoreHorizonButton";
2
- export * from "./Atoms/NumberField/NumberField";
3
- export * from "./Atoms/PhoneNumberField/PhoneNumberField";
4
- export * from "./Atoms/Pagination/Pagination";
5
- export * from "./Atoms/SortDropdown/SortDropdown";
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  export * from "./Atoms/MoreHorizonButton/MoreHorizonButton";
2
- export * from "./Atoms/NumberField/NumberField";
3
- export * from "./Atoms/PhoneNumberField/PhoneNumberField";
4
- export * from "./Atoms/Pagination/Pagination";
5
- export * from "./Atoms/SortDropdown/SortDropdown";
2
+ // export * from "./Atoms/NumberField/NumberField";
3
+ // export * from "./Atoms/PhoneNumberField/PhoneNumberField";
4
+ // export * from "./Atoms/Pagination/Pagination";
5
+ // export * from "./Atoms/SortDropdown/SortDropdown";
6
6
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../lib/index.ts"],"names":[],"mappings":"AAAA,cAAc,6CAA6C,CAAC;AAC5D,cAAc,iCAAiC,CAAC;AAChD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,+BAA+B,CAAC;AAC9C,cAAc,mCAAmC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../lib/index.ts"],"names":[],"mappings":"AAAA,cAAc,6CAA6C,CAAC;AAC5D,mDAAmD;AACnD,6DAA6D;AAC7D,iDAAiD;AACjD,qDAAqD"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@factorearth/component-library",
3
- "version": "2.0.1-alpha.0",
3
+ "version": "3.0.0-alpha.0",
4
4
  "description": " A storybook component library for FactorEarth",
5
5
  "author": "madtrx <marlin.makori@gmail.com>",
6
6
  "homepage": "https://github.com/FactorEarth/RecordMiddleware#readme",
@@ -25,11 +25,13 @@
25
25
  },
26
26
  "devDependencies": {
27
27
  "@chromatic-com/storybook": "^1.6.1",
28
+ "@storybook/addon-backgrounds": "^8.2.9",
28
29
  "@storybook/addon-designs": "^8.0.3",
29
30
  "@storybook/addon-essentials": "^8.2.9",
30
31
  "@storybook/addon-interactions": "^8.2.9",
31
32
  "@storybook/addon-links": "^8.2.9",
32
33
  "@storybook/addon-onboarding": "^8.2.9",
34
+ "@storybook/addon-themes": "^8.2.9",
33
35
  "@storybook/blocks": "^8.2.9",
34
36
  "@storybook/react": "^8.2.9",
35
37
  "@storybook/react-vite": "^8.2.9",
@@ -43,5 +45,11 @@
43
45
  "access": "public",
44
46
  "registry": "https://registry.npmjs.org/"
45
47
  },
46
- "gitHead": "b4f1e5eddb2d9cc619abb2dc6f8df1dec78cf4bf"
48
+ "gitHead": "35406ad5c9d8449d02ff56f43719b10543b9ea01",
49
+ "dependencies": {
50
+ "@emotion/react": "^11.13.0",
51
+ "@emotion/styled": "^11.13.0",
52
+ "react-icons": "^5.3.0",
53
+ "react-select": "^5.8.0"
54
+ }
47
55
  }