@edu-tosel/design 1.0.180 → 1.0.183

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.
@@ -2,6 +2,7 @@ import Box from "./sign/Box";
2
2
  import Button from "./sign/Button";
3
3
  import Check from "./sign/Check";
4
4
  import Layout from "./sign/Layout";
5
+ import OAuth from "./sign/Oauth";
5
6
  import WithTitle from "./sign/WithTitle";
6
7
  declare const Sign: {
7
8
  Box: typeof Box;
@@ -11,5 +12,6 @@ declare const Sign: {
11
12
  WithTitle: typeof WithTitle;
12
13
  };
13
14
  Layout: typeof Layout;
15
+ OAuth: typeof OAuth;
14
16
  };
15
17
  export default Sign;
@@ -2,6 +2,7 @@ import Box from "./sign/Box";
2
2
  import Button from "./sign/Button";
3
3
  import Check from "./sign/Check";
4
4
  import Layout from "./sign/Layout";
5
+ import OAuth from "./sign/Oauth";
5
6
  import WithTitle from "./sign/WithTitle";
6
7
  const Sign = {
7
8
  Box,
@@ -11,5 +12,6 @@ const Sign = {
11
12
  WithTitle,
12
13
  },
13
14
  Layout,
15
+ OAuth,
14
16
  };
15
17
  export default Sign;
@@ -0,0 +1,6 @@
1
+ type OAuthType = "naver" | "kakaotalk";
2
+ interface OAuthProps {
3
+ type: OAuthType;
4
+ }
5
+ export default function OAuth({ type }: OAuthProps): import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,32 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { cn } from "../../../util";
3
+ import SVG from "../../../asset/SVG";
4
+ export default function OAuth({ type }) {
5
+ const socialBox = {
6
+ display: "flex flex-row",
7
+ sizes: "xs:max-w-[210px] w-full h-15 rounded-lg",
8
+ animations: "duration-300",
9
+ backgrounds: "border-1 border-gray-light",
10
+ styles: type === "naver" ? "hover:bg-[#03C75A] group" : "hover:bg-[#FEE500]",
11
+ };
12
+ const textStyle = {
13
+ sizes: "h-full w-full ",
14
+ displays: "flex justify-center items-center",
15
+ styles: type === "naver" ? " group-hover:text-white" : "",
16
+ };
17
+ return (_jsxs("div", { className: cn(socialBox), onClick: () => { }, children: [_jsx("div", { className: "h-full aspect-square flex justify-center items-center", children: _jsx(SVGProvider, { type: type }) }), _jsx("div", { className: "h-full" }), _jsx("div", { className: cn(textStyle), children: textParser(type) })] }));
18
+ }
19
+ const textParser = (type) => {
20
+ if (type === "naver")
21
+ return "네이버로 로그인";
22
+ if (type === "kakaotalk")
23
+ return "카카오톡으로 로그인";
24
+ return null;
25
+ };
26
+ function SVGProvider({ type }) {
27
+ if (type === "naver")
28
+ return (_jsx(SVG.Collab.Naver, { color: "fill-[#03C75A] group-hover:fill-white", size: "size-5" }));
29
+ if (type === "kakaotalk")
30
+ return _jsx(SVG.Collab.Kakao, {});
31
+ return null;
32
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@edu-tosel/design",
3
- "version": "1.0.180",
3
+ "version": "1.0.183",
4
4
  "description": "UI components for International TOSEL Committee",
5
5
  "keywords": [
6
6
  "jsx",
package/version.txt CHANGED
@@ -1 +1 @@
1
- 1.0.180
1
+ 1.0.183