@sanvika/ui 0.1.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/README.md +36 -0
- package/package.json +60 -0
- package/src/components/buttons/Button.jsx +96 -0
- package/src/components/buttons/FavoriteHeartButton.jsx +41 -0
- package/src/components/buttons/ScrollButton.jsx +36 -0
- package/src/components/buttons/ThreeDotButton.jsx +36 -0
- package/src/components/common/Container.jsx +38 -0
- package/src/components/common/Section.jsx +60 -0
- package/src/components/icons/BellIcon.jsx +10 -0
- package/src/components/icons/ChevronDown.jsx +20 -0
- package/src/components/icons/EmailIcon.jsx +9 -0
- package/src/components/icons/FaAngleDown.jsx +9 -0
- package/src/components/icons/FaAngleRight.jsx +9 -0
- package/src/components/icons/FaArrowDown.jsx +9 -0
- package/src/components/icons/FaArrowLeft.jsx +9 -0
- package/src/components/icons/FaArrowUp.jsx +9 -0
- package/src/components/icons/FaBell.jsx +9 -0
- package/src/components/icons/FaBullhorn.jsx +10 -0
- package/src/components/icons/FaCalendarAlt.jsx +9 -0
- package/src/components/icons/FaCheck.jsx +9 -0
- package/src/components/icons/FaCheckCircle.jsx +9 -0
- package/src/components/icons/FaCheckDouble.jsx +9 -0
- package/src/components/icons/FaChevronDown.jsx +9 -0
- package/src/components/icons/FaChevronRight.jsx +9 -0
- package/src/components/icons/FaCircle.jsx +9 -0
- package/src/components/icons/FaComments.jsx +9 -0
- package/src/components/icons/FaEye.jsx +9 -0
- package/src/components/icons/FaEyeSlash.jsx +9 -0
- package/src/components/icons/FaHome.jsx +9 -0
- package/src/components/icons/FaKeyboard.jsx +9 -0
- package/src/components/icons/FaLocationArrow.jsx +9 -0
- package/src/components/icons/FaMapMarkerAlt.jsx +9 -0
- package/src/components/icons/FaMoon.jsx +9 -0
- package/src/components/icons/FaPaperPlane.jsx +9 -0
- package/src/components/icons/FaPaperclip.jsx +9 -0
- package/src/components/icons/FaSignInAlt.jsx +9 -0
- package/src/components/icons/FaSmile.jsx +9 -0
- package/src/components/icons/FaStar.jsx +9 -0
- package/src/components/icons/FaTag.jsx +9 -0
- package/src/components/icons/FaThumbsDown.jsx +9 -0
- package/src/components/icons/FaThumbsUp.jsx +9 -0
- package/src/components/icons/FaTrash.jsx +9 -0
- package/src/components/icons/FaUser.jsx +9 -0
- package/src/components/icons/FaUserCircle.jsx +9 -0
- package/src/components/icons/FacebookIcon.jsx +9 -0
- package/src/components/icons/HalfMoonIcon.jsx +18 -0
- package/src/components/icons/HeartIcon.jsx +9 -0
- package/src/components/icons/InstagramIcon.jsx +9 -0
- package/src/components/icons/LinkedInIcon.jsx +9 -0
- package/src/components/icons/MapMarkerIcon.jsx +9 -0
- package/src/components/icons/MdWbSunny.jsx +9 -0
- package/src/components/icons/ReFreshIcon.jsx +49 -0
- package/src/components/icons/SearchIcon.jsx +20 -0
- package/src/components/icons/StarIcon.jsx +9 -0
- package/src/components/icons/TelegramIcon.jsx +9 -0
- package/src/components/icons/TwitterIcon.jsx +9 -0
- package/src/components/icons/UserIcon.jsx +9 -0
- package/src/components/icons/WhatsappIcon.jsx +9 -0
- package/src/components/icons/YoutubeIcon.jsx +9 -0
- package/src/components/icons/index.js +60 -0
- package/src/components/layout/Footer.jsx +142 -0
- package/src/components/layout/Navbar.jsx +65 -0
- package/src/components/modals/Modal.jsx +74 -0
- package/src/components/progressBar/ProgressBar.jsx +113 -0
- package/src/context/ThemeContext.jsx +91 -0
- package/src/index.js +29 -0
- package/src/styles/base/elements.css +71 -0
- package/src/styles/base/reset.css +52 -0
- package/src/styles/base/typography.css +80 -0
- package/src/styles/components/buttons/Button.module.css +160 -0
- package/src/styles/components/buttons/FavoriteHeartButton.module.css +35 -0
- package/src/styles/components/buttons/ThreeDotButton.module.css +41 -0
- package/src/styles/components/common/Container.module.css +25 -0
- package/src/styles/components/common/Section.module.css +54 -0
- package/src/styles/components/layouts/Footer.module.css +100 -0
- package/src/styles/components/layouts/Layout.module.css +21 -0
- package/src/styles/components/layouts/Navbar.module.css +121 -0
- package/src/styles/components/modals/Modal.module.css +39 -0
- package/src/styles/components/progressBar/ProgressBar.module.css +28 -0
- package/src/styles/fouc-prevention.css +19 -0
- package/src/styles/index.css +27 -0
- package/src/styles/tokens/dark.css +121 -0
- package/src/styles/tokens/light.css +158 -0
- package/src/styles/utilities/colors.css +59 -0
- package/src/styles/utilities/transitions.css +40 -0
package/README.md
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-next-app`](https://nextjs.org/docs/app/api-reference/cli/create-next-app).
|
|
2
|
+
|
|
3
|
+
## Getting Started
|
|
4
|
+
|
|
5
|
+
First, run the development server:
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm run dev
|
|
9
|
+
# or
|
|
10
|
+
yarn dev
|
|
11
|
+
# or
|
|
12
|
+
pnpm dev
|
|
13
|
+
# or
|
|
14
|
+
bun dev
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.
|
|
18
|
+
|
|
19
|
+
You can start editing the page by modifying `app/page.js`. The page auto-updates as you edit the file.
|
|
20
|
+
|
|
21
|
+
This project uses [`next/font`](https://nextjs.org/docs/app/building-your-application/optimizing/fonts) to automatically optimize and load [Geist](https://vercel.com/font), a new font family for Vercel.
|
|
22
|
+
|
|
23
|
+
## Learn More
|
|
24
|
+
|
|
25
|
+
To learn more about Next.js, take a look at the following resources:
|
|
26
|
+
|
|
27
|
+
- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
|
|
28
|
+
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.
|
|
29
|
+
|
|
30
|
+
You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js) - your feedback and contributions are welcome!
|
|
31
|
+
|
|
32
|
+
## Deploy on Vercel
|
|
33
|
+
|
|
34
|
+
The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.
|
|
35
|
+
|
|
36
|
+
Check out our [Next.js deployment documentation](https://nextjs.org/docs/app/building-your-application/deploying) for more details.
|
package/package.json
ADDED
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@sanvika/ui",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"private": false,
|
|
6
|
+
"description": "Sanvika Production — shared UI component library for 50+ projects. Pure JS, CSS Modules, props-driven.",
|
|
7
|
+
"author": "Shyam Bharteey <shyam@sanvikaproduction.com>",
|
|
8
|
+
"license": "MIT",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "https://github.com/sanvika/sanvika-ui"
|
|
12
|
+
},
|
|
13
|
+
"keywords": ["react", "ui", "components", "design-system", "sanvika", "classified-ads"],
|
|
14
|
+
"main": "./src/index.js",
|
|
15
|
+
"exports": {
|
|
16
|
+
".": "./src/index.js",
|
|
17
|
+
"./icons": "./src/components/icons/index.js",
|
|
18
|
+
"./styles": "./src/styles/index.css"
|
|
19
|
+
},
|
|
20
|
+
"files": [
|
|
21
|
+
"src/components",
|
|
22
|
+
"src/context",
|
|
23
|
+
"src/styles",
|
|
24
|
+
"src/index.js",
|
|
25
|
+
"!src/**/*.stories.jsx",
|
|
26
|
+
"!src/**/*.stories.js"
|
|
27
|
+
],
|
|
28
|
+
"peerDependencies": {
|
|
29
|
+
"react": ">=18.0.0",
|
|
30
|
+
"react-dom": ">=18.0.0"
|
|
31
|
+
},
|
|
32
|
+
"scripts": {
|
|
33
|
+
"dev": "next dev",
|
|
34
|
+
"build": "next build",
|
|
35
|
+
"start": "next start",
|
|
36
|
+
"lint": "eslint",
|
|
37
|
+
"storybook": "storybook dev -p 6006",
|
|
38
|
+
"build-storybook": "storybook build",
|
|
39
|
+
"prepublishOnly": "echo 'Publishing @sanvika/ui...'"
|
|
40
|
+
},
|
|
41
|
+
"dependencies": {},
|
|
42
|
+
"pnpm": {
|
|
43
|
+
"onlyBuiltDependencies": [
|
|
44
|
+
"core-js-pure",
|
|
45
|
+
"esbuild"
|
|
46
|
+
]
|
|
47
|
+
},
|
|
48
|
+
"devDependencies": {
|
|
49
|
+
"@storybook/addon-essentials": "^8.6.14",
|
|
50
|
+
"@storybook/addon-interactions": "^8.6.14",
|
|
51
|
+
"@storybook/nextjs": "^10.3.2",
|
|
52
|
+
"babel-plugin-react-compiler": "1.0.0",
|
|
53
|
+
"eslint": "^9",
|
|
54
|
+
"eslint-config-next": "16.2.2",
|
|
55
|
+
"next": "16.2.2",
|
|
56
|
+
"react": "19.2.4",
|
|
57
|
+
"react-dom": "19.2.4",
|
|
58
|
+
"storybook": "^10.3.2"
|
|
59
|
+
}
|
|
60
|
+
}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
// src/components/buttons/Button.jsx
|
|
2
|
+
import React from "react";
|
|
3
|
+
import styles from "@/styles/components/buttons/Button.module.css";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Button — versatile button/link component.
|
|
7
|
+
*
|
|
8
|
+
* @param {object} props
|
|
9
|
+
* @param {React.ReactNode} [props.children]
|
|
10
|
+
* @param {string} [props.text] - button label (fallback if no children)
|
|
11
|
+
* @param {React.ReactNode} [props.icon] - icon rendered before label
|
|
12
|
+
* @param {React.ReactNode} [props.badge] - notification badge
|
|
13
|
+
* @param {"primary"|"secondary"|"danger"|"success"} [props.intent="primary"]
|
|
14
|
+
* @param {"solid"|"outline"|"ghost"} [props.appearance="solid"]
|
|
15
|
+
* @param {"sm"|"md"|"lg"} [props.size="md"]
|
|
16
|
+
* @param {boolean} [props.fullWidth=false]
|
|
17
|
+
* @param {string} [props.href] - renders as <a> when set
|
|
18
|
+
* @param {"button"|"submit"|"reset"} [props.type="button"]
|
|
19
|
+
* @param {boolean} [props.disabled=false]
|
|
20
|
+
*/
|
|
21
|
+
const Button = ({
|
|
22
|
+
children,
|
|
23
|
+
text,
|
|
24
|
+
icon,
|
|
25
|
+
badge,
|
|
26
|
+
intent = "primary",
|
|
27
|
+
appearance = "solid",
|
|
28
|
+
size = "md",
|
|
29
|
+
fullWidth = false,
|
|
30
|
+
href,
|
|
31
|
+
type = "button",
|
|
32
|
+
disabled = false,
|
|
33
|
+
className,
|
|
34
|
+
style,
|
|
35
|
+
onClick,
|
|
36
|
+
...props
|
|
37
|
+
}) => {
|
|
38
|
+
const label = children ?? text;
|
|
39
|
+
|
|
40
|
+
const intentClass = styles[intent] ?? styles.primary;
|
|
41
|
+
|
|
42
|
+
const appearanceClass =
|
|
43
|
+
appearance === "outline"
|
|
44
|
+
? styles.outline
|
|
45
|
+
: appearance === "ghost"
|
|
46
|
+
? styles.ghost
|
|
47
|
+
: "";
|
|
48
|
+
|
|
49
|
+
const sizeClass = size === "sm" ? styles.sm : size === "lg" ? styles.lg : "";
|
|
50
|
+
|
|
51
|
+
const cls = [
|
|
52
|
+
styles.button,
|
|
53
|
+
intentClass,
|
|
54
|
+
appearanceClass,
|
|
55
|
+
sizeClass,
|
|
56
|
+
fullWidth ? styles.full : "",
|
|
57
|
+
className ?? "",
|
|
58
|
+
]
|
|
59
|
+
.filter(Boolean)
|
|
60
|
+
.join(" ");
|
|
61
|
+
|
|
62
|
+
const content = (
|
|
63
|
+
<>
|
|
64
|
+
{icon && (
|
|
65
|
+
<span className={styles.icon} aria-hidden="true">
|
|
66
|
+
{icon}
|
|
67
|
+
</span>
|
|
68
|
+
)}
|
|
69
|
+
{label && <span className={styles.text}>{label}</span>}
|
|
70
|
+
{badge != null && <span className={styles.badge}>{badge}</span>}
|
|
71
|
+
</>
|
|
72
|
+
);
|
|
73
|
+
|
|
74
|
+
if (href) {
|
|
75
|
+
return (
|
|
76
|
+
<a href={href} className={cls} style={style} {...props}>
|
|
77
|
+
{content}
|
|
78
|
+
</a>
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
return (
|
|
83
|
+
<button
|
|
84
|
+
type={type}
|
|
85
|
+
className={cls}
|
|
86
|
+
style={style}
|
|
87
|
+
disabled={disabled}
|
|
88
|
+
onClick={onClick}
|
|
89
|
+
{...props}
|
|
90
|
+
>
|
|
91
|
+
{content}
|
|
92
|
+
</button>
|
|
93
|
+
);
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
export default Button;
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
// src/components/buttons/FavoriteHeartButton.jsx
|
|
2
|
+
import React from "react";
|
|
3
|
+
import HeartIcon from "@/components/icons/HeartIcon";
|
|
4
|
+
import Button from "@/components/buttons/Button";
|
|
5
|
+
import styles from "@/styles/components/buttons/FavoriteHeartButton.module.css";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* FavoriteHeartButton — toggleable heart/favorite button.
|
|
9
|
+
* Returns null when isOwner=true (owners cannot favorite their own items).
|
|
10
|
+
*
|
|
11
|
+
* @param {boolean} isFavorited - current favorite state
|
|
12
|
+
* @param {function} onClick
|
|
13
|
+
* @param {boolean} [disabled=false]
|
|
14
|
+
* @param {boolean} [isOwner=false] - if true, renders nothing
|
|
15
|
+
* @param {string} [className]
|
|
16
|
+
* @param {object} [style]
|
|
17
|
+
*/
|
|
18
|
+
const FavoriteHeartButton = ({
|
|
19
|
+
isFavorited,
|
|
20
|
+
onClick,
|
|
21
|
+
disabled,
|
|
22
|
+
isOwner = false,
|
|
23
|
+
className = "",
|
|
24
|
+
style,
|
|
25
|
+
}) => {
|
|
26
|
+
if (isOwner) return null;
|
|
27
|
+
|
|
28
|
+
return (
|
|
29
|
+
<Button
|
|
30
|
+
onClick={onClick}
|
|
31
|
+
disabled={disabled}
|
|
32
|
+
className={`${styles.favoriteHeartButton} ${isFavorited ? styles.favorited : styles.notFavorited} ${className}`}
|
|
33
|
+
style={style}
|
|
34
|
+
aria-label={isFavorited ? "Unfavorite" : "Favorite"}
|
|
35
|
+
title={isFavorited ? "Unfavorite" : "Favorite"}
|
|
36
|
+
icon={<HeartIcon style={{ width: 20, height: 20 }} />}
|
|
37
|
+
/>
|
|
38
|
+
);
|
|
39
|
+
};
|
|
40
|
+
|
|
41
|
+
export default FavoriteHeartButton;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// src/components/buttons/ScrollButton.jsx
|
|
2
|
+
import React from "react";
|
|
3
|
+
import Button from "@/components/buttons/Button";
|
|
4
|
+
import { FaArrowUp, FaArrowDown } from "@/components/icons";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* ScrollButton — icon-only button for scroll up/down actions.
|
|
8
|
+
*
|
|
9
|
+
* @param {"up"|"down"} [direction="up"]
|
|
10
|
+
* @param {function} onClick
|
|
11
|
+
* @param {string} [className]
|
|
12
|
+
* @param {object} [style]
|
|
13
|
+
*/
|
|
14
|
+
const ScrollButton = ({
|
|
15
|
+
direction = "up",
|
|
16
|
+
onClick,
|
|
17
|
+
className = "",
|
|
18
|
+
style = {},
|
|
19
|
+
}) => {
|
|
20
|
+
const icon = direction === "up" ? <FaArrowUp /> : <FaArrowDown />;
|
|
21
|
+
const label = direction === "up" ? "Scroll to top" : "Scroll to bottom";
|
|
22
|
+
|
|
23
|
+
return (
|
|
24
|
+
<Button
|
|
25
|
+
icon={icon}
|
|
26
|
+
onClick={onClick}
|
|
27
|
+
className={className}
|
|
28
|
+
appearance="ghost"
|
|
29
|
+
aria-label={label}
|
|
30
|
+
title={label}
|
|
31
|
+
style={{ display: "flex", ...style }}
|
|
32
|
+
/>
|
|
33
|
+
);
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export default ScrollButton;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
// src/components/buttons/ThreeDotButton.jsx
|
|
2
|
+
import React from "react";
|
|
3
|
+
import Button from "@/components/buttons/Button";
|
|
4
|
+
import styles from "@/styles/components/buttons/ThreeDotButton.module.css";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* ThreeDotButton — compact vertical three-dot menu trigger.
|
|
8
|
+
* Pure props-driven: all navigation/action logic passed via onClick.
|
|
9
|
+
*
|
|
10
|
+
* @param {function} [onClick]
|
|
11
|
+
* @param {string} [ariaLabel="More options"]
|
|
12
|
+
* @param {string} [className]
|
|
13
|
+
*/
|
|
14
|
+
const ThreeDotButton = ({
|
|
15
|
+
className = "",
|
|
16
|
+
ariaLabel = "More options",
|
|
17
|
+
onClick,
|
|
18
|
+
}) => {
|
|
19
|
+
return (
|
|
20
|
+
<Button
|
|
21
|
+
className={`${styles.threeDotButton} ${className}`}
|
|
22
|
+
onClick={onClick}
|
|
23
|
+
aria-label={ariaLabel}
|
|
24
|
+
title={ariaLabel}
|
|
25
|
+
icon={
|
|
26
|
+
<span className={styles.dotsWrapper} aria-hidden="true">
|
|
27
|
+
<span className={styles.dot} />
|
|
28
|
+
<span className={styles.dot} />
|
|
29
|
+
<span className={styles.dot} />
|
|
30
|
+
</span>
|
|
31
|
+
}
|
|
32
|
+
/>
|
|
33
|
+
);
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export default ThreeDotButton;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
// src/components/common/Container.jsx
|
|
2
|
+
import styles from "@/styles/components/common/Container.module.css";
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Container — a centered max-width wrapper.
|
|
6
|
+
*
|
|
7
|
+
* @param {"default"|"narrow"|"wide"|"full"} [size="default"]
|
|
8
|
+
* @param {React.ElementType} [as="div"]
|
|
9
|
+
*/
|
|
10
|
+
const Container = ({
|
|
11
|
+
children,
|
|
12
|
+
size = "default",
|
|
13
|
+
className,
|
|
14
|
+
style,
|
|
15
|
+
as: Tag = "div",
|
|
16
|
+
...props
|
|
17
|
+
}) => {
|
|
18
|
+
const sizeClass =
|
|
19
|
+
size === "narrow"
|
|
20
|
+
? styles.narrow
|
|
21
|
+
: size === "wide"
|
|
22
|
+
? styles.wide
|
|
23
|
+
: size === "full"
|
|
24
|
+
? styles.full
|
|
25
|
+
: "";
|
|
26
|
+
|
|
27
|
+
const cls = [styles.container, sizeClass, className ?? ""]
|
|
28
|
+
.filter(Boolean)
|
|
29
|
+
.join(" ");
|
|
30
|
+
|
|
31
|
+
return (
|
|
32
|
+
<Tag className={cls} style={style} {...props}>
|
|
33
|
+
{children}
|
|
34
|
+
</Tag>
|
|
35
|
+
);
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
export default Container;
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
// src/components/common/Section.jsx
|
|
2
|
+
import styles from "@/styles/components/common/Section.module.css";
|
|
3
|
+
import Container from "./Container";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Section — a full-width page section with optional title/subtitle.
|
|
7
|
+
*
|
|
8
|
+
* @param {"default"|"alternate"|"card"} [variant="default"]
|
|
9
|
+
* @param {"default"|"tight"|"flush"} [padding="default"]
|
|
10
|
+
* @param {string} [title]
|
|
11
|
+
* @param {string} [subtitle]
|
|
12
|
+
* @param {"default"|"narrow"|"wide"|"full"} [containerSize="default"]
|
|
13
|
+
* @param {React.ElementType} [as="section"]
|
|
14
|
+
*/
|
|
15
|
+
const Section = ({
|
|
16
|
+
children,
|
|
17
|
+
variant = "default",
|
|
18
|
+
padding = "default",
|
|
19
|
+
title,
|
|
20
|
+
subtitle,
|
|
21
|
+
containerSize = "default",
|
|
22
|
+
className,
|
|
23
|
+
style,
|
|
24
|
+
as: Tag = "section",
|
|
25
|
+
...props
|
|
26
|
+
}) => {
|
|
27
|
+
const variantClass =
|
|
28
|
+
variant === "alternate"
|
|
29
|
+
? styles.alternate
|
|
30
|
+
: variant === "card"
|
|
31
|
+
? styles.card
|
|
32
|
+
: "";
|
|
33
|
+
|
|
34
|
+
const paddingClass =
|
|
35
|
+
padding === "tight"
|
|
36
|
+
? styles.tight
|
|
37
|
+
: padding === "flush"
|
|
38
|
+
? styles.flush
|
|
39
|
+
: "";
|
|
40
|
+
|
|
41
|
+
const cls = [styles.section, variantClass, paddingClass, className ?? ""]
|
|
42
|
+
.filter(Boolean)
|
|
43
|
+
.join(" ");
|
|
44
|
+
|
|
45
|
+
return (
|
|
46
|
+
<Tag className={cls} style={style} {...props}>
|
|
47
|
+
<Container size={containerSize}>
|
|
48
|
+
{(title || subtitle) && (
|
|
49
|
+
<div className={styles.header}>
|
|
50
|
+
{title && <h2 className={styles.title}>{title}</h2>}
|
|
51
|
+
{subtitle && <p className={styles.subtitle}>{subtitle}</p>}
|
|
52
|
+
</div>
|
|
53
|
+
)}
|
|
54
|
+
{children}
|
|
55
|
+
</Container>
|
|
56
|
+
</Tag>
|
|
57
|
+
);
|
|
58
|
+
};
|
|
59
|
+
|
|
60
|
+
export default Section;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// src/components/icons/BellIcon.jsx
|
|
2
|
+
import React from "react";
|
|
3
|
+
|
|
4
|
+
export const BellIcon = ({ className, style, title = "Notifications" }) => (
|
|
5
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor" aria-hidden="true" className={className} style={style} role="img">
|
|
6
|
+
<title>{title}</title>
|
|
7
|
+
<path d="M12 2a4 4 0 00-4 4v1.586L6.293 9.293A1 1 0 006 10v2l-1 1v1h14v-1l-1-1v-2a1 1 0 00-.293-.707L16 7.586V6a4 4 0 00-4-4zm0 18a2.5 2.5 0 01-2.45-2h4.9A2.5 2.5 0 0112 20z" />
|
|
8
|
+
</svg>
|
|
9
|
+
);
|
|
10
|
+
export default BellIcon;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
const ChevronDown = ({ className, style, title = "Open" }) => (
|
|
4
|
+
<svg
|
|
5
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
6
|
+
viewBox="0 0 24 24"
|
|
7
|
+
width="1em"
|
|
8
|
+
height="1em"
|
|
9
|
+
fill="currentColor"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
className={className}
|
|
12
|
+
style={style}
|
|
13
|
+
role="img"
|
|
14
|
+
>
|
|
15
|
+
<title>{title}</title>
|
|
16
|
+
<path d="M7.41 8.59 12 13.17l4.59-4.58L18 10l-6 6-6-6z" />
|
|
17
|
+
</svg>
|
|
18
|
+
);
|
|
19
|
+
|
|
20
|
+
export default ChevronDown;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
const EmailIcon = ({ className, style }) => (
|
|
4
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="1em" height="1em" fill="currentColor" className={className} style={style} aria-hidden="true">
|
|
5
|
+
<path d="M20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z" />
|
|
6
|
+
</svg>
|
|
7
|
+
);
|
|
8
|
+
|
|
9
|
+
export default EmailIcon;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaAngleDown(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 320 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M31 192c-9.4-9.4-9.4-24.6 0-33.9l22.6-22.6c9.4-9.4 24.6-9.4 33.9 0L160 259.3 232.5 135.5c9.4-9.4 24.6-9.4 33.9 0L289 158c9.4 9.4 9.4 24.6 0 33.9l-128 128c-9.4 9.4-24.6 9.4-33.9 0z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaAngleRight(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 256 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M64 448c-8.1 0-16.2-3.1-22.4-9.4-12.5-12.5-12.5-32.8 0-45.3L178.7 256 41.6 118.7c-12.5-12.5-12.5-32.8 0-45.3 12.5-12.5 32.8-12.5 45.3 0l160 160c12.5 12.5 12.5 32.8 0 45.3l-160 160C80.2 444.9 72.1 448 64 448z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaArrowDown(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 448 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M413.1 222.5L224 411.7 34.9 222.5c-9.4-9.4-24.6-9.4-33.9 0L-21.6 245.1c-9.4 9.4-9.4 24.6 0 33.9L192.7 512c9.4 9.4 24.6 9.4 34 0L469.6 279c9.4-9.4 9.4-24.6 0-33.9l-22.6-22.6c-9.3-9.4-24.5-9.4-34 0z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaArrowLeft(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 256 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M31.1 239l160-160c9.4-9.4 24.6-9.4 33.9 0l22.6 22.6c9.4 9.4 9.4 24.6 0 33.9L154.9 256l92.7 120.5c9.4 9.4 9.4 24.6 0 33.9L225.1 433c-9.4 9.4-24.6 9.4-33.9 0l-160-160c-9.4-9.4-9.4-24.6 0-33.9z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaArrowUp(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 448 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M34.9 289.5L224 100.3 413.1 289.5c9.4 9.4 24.6 9.4 33.9 0l22.6-22.6c9.4-9.4 9.4-24.6 0-33.9L259.3 7c-9.4-9.4-24.6-9.4-34 0L12.3 233c-9.4 9.4-9.4 24.6 0 33.9l22.6 22.6c9.3 9.4 24.5 9.4 34-0.0z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaBell(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 448 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M224 512a64 64 0 0 0 64-64H160a64 64 0 0 0 64 64zm215.4-149.7C406.4 339 384 288 384 224 384 141 323 76 256 64V48a32 32 0 0 0-64 0v16C129 76 68 141 68 224c0 64-22.4 115-55.4 138.3A31.99 31.99 0 0 0 48 416h352a31.99 31.99 0 0 0 39.4-53.7z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
// src/components/icons/FaBullhorn.jsx
|
|
2
|
+
import React from "react";
|
|
3
|
+
|
|
4
|
+
export default function FaBullhorn(props) {
|
|
5
|
+
return (
|
|
6
|
+
<svg viewBox="0 0 576 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
7
|
+
<path d="M576 240c0-23.63-12.95-44.04-32-55.12V15.99C544 5.6 536.5 0 528 0c-3.999 0-8 1.251-11.5 3.75l-160 112C343 127.4 320 133.6 296 133.6H176C131.8 133.6 96 169.4 96 213.6v52.8c0 44.2 35.8 80 80 80h17.44l-17.36 112.4C173.4 473.3 183.1 480 192 480h80c30.63 0 56.25-21.98 61.63-53.12L354.4 346.6h-.001c-2.75 0-5.25-.62-8.001-.62H248c-4.418 0-8-3.578-8-8v-80c0-4.422 3.582-8 8-8h96.63c2.75 0 5.25-.625 7.999-.625L512 360.2c3.5 2.5 7.5 3.75 11.5 3.75c8.5 0 16-5.6 16-15.99V295.1C563.1 284 576 263.6 576 240zM448 292.7L354.2 230.8c-.75-.5-1.75-.75-2.625-.75H176c-8.836 0-16 7.164-16 16v16c0 8.836 7.164 16 16 16h120c4.418 0 8 3.578 8 8v16c0 4.422-3.582 8-8 8H176c-8.836 0-16 7.164-16 16v16c0 8.836 7.164 16 16 16h120c4.418 0 8 3.578 8 8v16c0 4.422-3.582 8-8 8H200c-4.418 0-8-3.578-8-8v-16c0-4.422 3.582-8 8-8h32v-16H200l-9.375-60.8C175 363.6 176 370.6 176 378.4c0 44.2-35.8 80-80 80H96c8.836 0 16-7.164 16-16V294.4C130.9 313.4 152 320 176 320h170.6c3.5 0 6.748-.875 9.873-2.125L448 374.3V292.7z" />
|
|
8
|
+
</svg>
|
|
9
|
+
);
|
|
10
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaCalendarAlt(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 448 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M400 64h-48V24a24 24 0 0 0-48 0v40H144V24a24 24 0 0 0-48 0v40H48A48 48 0 0 0 0 112v320a48 48 0 0 0 48 48h352a48 48 0 0 0 48-48V112a48 48 0 0 0-48-48zM400 432H48V192h352z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaCheck(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 512 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M173.9 439.4L7 272.5c-9.4-9.4-9.4-24.6 0-33.9l33.9-33.9c9.4-9.4 24.6-9.4 33.9 0L192 312l252.4-252.4c9.4-9.4 24.6-9.4 33.9 0l33.9 33.9c9.4 9.4 9.4 24.6 0 33.9L207.8 439.4c-9.4 9.4-24.6 9.4-33.9 0z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaCheckCircle(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 512 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M256 8C119.03 8 8 119.03 8 256s111.03 248 248 248 248-111.03 248-248S392.97 8 256 8zm123.31 170.69l-138 184c-4.8 6.4-12.8 10.31-20.8 10.31-8 0-16-3.91-20.8-10.31l-69.99-93.33c-9.07-12.09-5.96-29.33 6.13-38.4 12.09-9.07 29.33-5.96 38.4 6.13L234.7 318.7l118.9-158.53c9.07-12.09 26.31-15.2 38.4-6.13 12.09 9.07 15.2 26.31 6.13 38.45z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaCheckDouble(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 512 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M464 64.3L199.4 328.9 97 226.5c-9.4-9.4-24.6-9.4-33.9 0L23 267.6c-9.4 9.4-9.4 24.6 0 33.9l144 144c9.4 9.4 24.6 9.4 33.9 0l304-304c9.4-9.4 9.4-24.6 0-33.9L497.9 64.3c-9.4-9.4-24.6-9.4-33.9 0z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaChevronDown(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 320 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M31 192c-9.4-9.4-9.4-24.6 0-33.9l22.6-22.6c9.4-9.4 24.6-9.4 33.9 0L160 259.3 232.5 135.5c9.4-9.4 24.6-9.4 33.9 0L289 158c9.4 9.4 9.4 24.6 0 33.9l-128 128c-9.4 9.4-24.6 9.4-33.9 0z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaChevronRight(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 256 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M96 448c-12.5 0-25-7.5-31.2-19.3-12.5-24.9-6.1-55.3 15.9-72.2L225.9 256 80.7 155.5c-22-17-28.4-47.3-15.9-72.2C82.9 66.6 95.4 59 108 59s25 7.6 31.2 19.3l160 240C320.4 454.4 297.1 448 96 448z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaCircle(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 512 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M256 8C119.03 8 8 119.03 8 256s111.03 248 248 248 248-111.03 248-248S392.97 8 256 8z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaComments(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 512 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M256 32C114.6 32 0 125.1 0 240c0 49.6 21 95 56 128v88c0 6.6 7.7 10.4 12.9 6.5L152 346.8c24.4 6.8 50.1 10.2 76 10.2 141.4 0 256-93.1 256-208S397.4 32 256 32z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaEye(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 576 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M572.52 241.4C518.29 135.5 407.88 64 288 64 168.12 64 57.71 135.5 3.48 241.4a48.12 48.12 0 0 0 0 29.2C57.71 376.5 168.12 448 288 448c119.88 0 230.29-71.5 284.52-177.4a48.12 48.12 0 0 0 0-29.2zM288 400c-88.22 0-168.44-52.9-210.66-128C119.56 196.9 199.78 144 288 144s168.44 52.9 210.66 128C456.44 347.1 376.22 400 288 400zM288 176a112 112 0 1 0 112 112A112 112 0 0 0 288 176z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaEyeSlash(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 640 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M320 400c-78.8 0-147.1-45.6-180.3-112 19.3-36.2 50.7-64 88.3-79.6L118 85.3C90.7 103.7 63.3 127.6 39.6 156.5 3.4 203.8 0 256 0 256s111.03 248 248 248c29.1 0 56.9-4.6 82.8-13.1L320 400zM633.8 458.1L35.2 3.5A16 16 0 0 0 15.6 6.6L6.3 18.9a16 16 0 0 0 1.5 18l45.9 58.5C86 123.7 142.7 96 208 96c119.9 0 230.3 71.5 284.5 177.4a48.12 48.12 0 0 1 0 29.2c-14.3 27.5-34.2 51.5-57.9 72.9l71.7 91.3a16 16 0 0 0 22.4 2.8l9.3-12.3a16 16 0 0 0-2-22.5z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaHome(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 576 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M280.37 148.26L96 300.11V464a48 48 0 0 0 48 48l96-.3V368a16 16 0 0 1 16-16h64a16 16 0 0 1 16 16v143.7l96 .3a48 48 0 0 0 48-48V300L295.67 148.26a12 12 0 0 0-15.3 0zM571.6 251.5L488 182.6V44a12 12 0 0 0-12-12h-72a12 12 0 0 0-12 12v72.6L318.47 43a48 48 0 0 0-61 0L4.34 251.5c-12 9.7-1.7 31 13.4 31H64V464a48 48 0 0 0 48 48h416a48 48 0 0 0 48-48V282.5h46.3c15.1 0 25.4-21.3 13.3-31z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export default function FaKeyboard(props) {
|
|
4
|
+
return (
|
|
5
|
+
<svg viewBox="0 0 640 512" width="1em" height="1em" fill="currentColor" {...props}>
|
|
6
|
+
<path d="M0 96v320a32 32 0 0 0 32 32h576a32 32 0 0 0 32-32V96a32 32 0 0 0-32-32H32A32 32 0 0 0 0 96zm96 96h64v64H96v-64zm96 0h64v64h-64v-64zm96 0h64v64h-64v-64zm96 0h64v64h-64v-64zm96 0h64v64h-64v-64zM96 256h64v64H96v-64zm96 0h64v64h-64v-64z" />
|
|
7
|
+
</svg>
|
|
8
|
+
);
|
|
9
|
+
}
|