@npm_leadtech/legal-contracts-ui 0.44.19 → 0.44.21
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/dist/components/Button.js +113 -14
- package/dist/components/FaqTeaserSection.d.ts +9 -10
- package/dist/components/FaqTeaserSection.js +9 -9
- package/dist/components/HomeTemplate.d.ts +1 -10
- package/package.json +1 -9
- package/dist/components/Link.d.ts +0 -20
- package/dist/components/Link.js +0 -21
- package/dist/components/atoms/Button.utils.js +0 -105
|
@@ -1,19 +1,118 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as g } from "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
3
|
+
const p = {
|
|
4
|
+
"primary-green": {
|
|
5
|
+
base: "bg-primary-700 text-white border border-transparent font-semibold",
|
|
6
|
+
hover: "hover:bg-primary-500",
|
|
7
|
+
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:cursor-not-allowed"
|
|
8
|
+
},
|
|
9
|
+
"primary-darkgreen": {
|
|
10
|
+
base: "bg-primary-900 text-white border border-transparent font-semibold",
|
|
11
|
+
hover: "hover:bg-primary-800",
|
|
12
|
+
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:cursor-not-allowed"
|
|
13
|
+
},
|
|
14
|
+
"primary-yellow": {
|
|
15
|
+
base: "bg-secondary-500 text-neutral-900 border border-transparent font-semibold",
|
|
16
|
+
hover: "hover:bg-secondary-400",
|
|
17
|
+
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:cursor-not-allowed"
|
|
18
|
+
},
|
|
19
|
+
"primary-white": {
|
|
20
|
+
base: "bg-white text-neutral-900 font-semibold border border-transparent",
|
|
21
|
+
hover: "hover:bg-neutral-50",
|
|
22
|
+
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:cursor-not-allowed"
|
|
23
|
+
},
|
|
24
|
+
"secondary-green": {
|
|
25
|
+
base: "bg-white text-primary-700 border-2 border-primary-700 font-semibold",
|
|
26
|
+
hover: "hover:bg-primary-100 hover:text-primary-800",
|
|
27
|
+
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:border-neutral-200 disabled:cursor-not-allowed"
|
|
28
|
+
},
|
|
29
|
+
"secondary-yellow": {
|
|
30
|
+
base: "bg-transparent text-neutral-900 border-2 border-secondary-500 font-semibold",
|
|
31
|
+
hover: "hover:bg-secondary-100 hover:border-secondary-600",
|
|
32
|
+
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:border-neutral-200 disabled:cursor-not-allowed"
|
|
33
|
+
},
|
|
34
|
+
"secondary-red": {
|
|
35
|
+
base: "bg-transparent text-error-500 border-2 border-error-500 font-semibold",
|
|
36
|
+
hover: "hover:bg-error-25",
|
|
37
|
+
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:border-neutral-200 disabled:cursor-not-allowed"
|
|
38
|
+
},
|
|
39
|
+
"secondary-black": {
|
|
40
|
+
base: "bg-transparent text-neutral-800 border-2 border-neutral-600 font-semibold",
|
|
41
|
+
hover: "hover:bg-neutral-200",
|
|
42
|
+
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:border-neutral-200 disabled:cursor-not-allowed"
|
|
43
|
+
},
|
|
44
|
+
"tertiary-bold": {
|
|
45
|
+
base: "bg-transparent text-primary-700 font-semibold border border-transparent font-semibold p-1.5!",
|
|
46
|
+
hover: "hover:text-primary-500 hover:bg-primary-200",
|
|
47
|
+
disabled: "disabled:text-neutral-400 disabled:cursor-not-allowed disabled:bg-white"
|
|
48
|
+
},
|
|
49
|
+
"tertiary-thin": {
|
|
50
|
+
base: "bg-transparent text-neutral-800 font-normal border border-transparent p-1.5!",
|
|
51
|
+
hover: " hover:bg-primary-100",
|
|
52
|
+
disabled: "disabled:text-neutral-400 disabled:cursor-not-allowed disabled:bg-white"
|
|
53
|
+
},
|
|
54
|
+
"tertiary-icon": {
|
|
55
|
+
base: "bg-transparent text-neutral-800 font-medium border border-transparent p-1.5!",
|
|
56
|
+
hover: "hover:bg-primary-100",
|
|
57
|
+
disabled: "disabled:text-neutral-400 disabled:cursor-not-allowed disabled:bg-white"
|
|
58
|
+
},
|
|
59
|
+
"tertiary-link": {
|
|
60
|
+
base: "bg-transparent text-primary-700 underline underline-offset-2 border border-transparent",
|
|
61
|
+
hover: "",
|
|
62
|
+
disabled: "disabled:text-neutral-400 disabled:cursor-not-allowed disabled:bg-white"
|
|
63
|
+
},
|
|
64
|
+
"icon-black": {
|
|
65
|
+
base: "bg-black text-white border border-transparent font-semibold",
|
|
66
|
+
hover: "hover:bg-neutral-800",
|
|
67
|
+
disabled: "disabled:bg-neutral-400 disabled:cursor-not-allowed"
|
|
68
|
+
},
|
|
69
|
+
"icon-grey": {
|
|
70
|
+
base: "bg-transparent text-neutral-800 border-2 border-neutral-600 font-semibold",
|
|
71
|
+
hover: "hover:bg-neutral-200",
|
|
72
|
+
disabled: "disabled:text-neutral-400 disabled:border-neutral-400 disabled:bg-white disabled:cursor-not-allowed"
|
|
73
|
+
},
|
|
74
|
+
"icon-mobile": {
|
|
75
|
+
base: "bg-transparent text-primary-700 border border-neutral-200 border-2 px-8 rounded-sm",
|
|
76
|
+
hover: "hover:bg-neutral-50",
|
|
77
|
+
disabled: "disabled:text-neutral-400 disabled:border-neutral-400 disabled:bg-white disabled:cursor-not-allowed"
|
|
78
|
+
}
|
|
79
|
+
}, m = {
|
|
80
|
+
small: "px-3 py-1.5 text-small",
|
|
81
|
+
default: "px-4 py-2.5 text-medium",
|
|
82
|
+
large: "px-6 py-3 text-big"
|
|
83
|
+
}, x = ({
|
|
84
|
+
children: a,
|
|
85
|
+
type: d = "button",
|
|
86
|
+
size: o = "default",
|
|
87
|
+
variant: l = "primary-green",
|
|
88
|
+
iconPosition: t = "left",
|
|
89
|
+
className: b,
|
|
90
|
+
disabled: e = !1,
|
|
91
|
+
ref: s,
|
|
92
|
+
...n
|
|
14
93
|
}) => {
|
|
15
|
-
const
|
|
16
|
-
|
|
94
|
+
const r = p[l], i = () => t === "top" ? "flex-col" : t === "right" ? "flex-row-reverse" : "flex-row", u = [
|
|
95
|
+
"inline-flex items-center justify-center gap-2 rounded-sm font-medium transition-all duration-200",
|
|
96
|
+
"focus:outline-none focus-visible:ring-2 focus-visible:ring-primary-500 focus-visible:ring-offset-2",
|
|
97
|
+
e ? "" : "cursor-pointer",
|
|
98
|
+
r.base,
|
|
99
|
+
r.hover,
|
|
100
|
+
r.disabled,
|
|
101
|
+
m[o],
|
|
102
|
+
i()
|
|
103
|
+
].join(" ");
|
|
104
|
+
return /* @__PURE__ */ g(
|
|
105
|
+
"button",
|
|
106
|
+
{
|
|
107
|
+
ref: s,
|
|
108
|
+
type: d,
|
|
109
|
+
disabled: e,
|
|
110
|
+
"aria-disabled": e,
|
|
111
|
+
className: `${u} ${b ?? ""}`,
|
|
112
|
+
...n,
|
|
113
|
+
children: a
|
|
114
|
+
}
|
|
115
|
+
);
|
|
17
116
|
};
|
|
18
117
|
export {
|
|
19
118
|
x as Button
|
|
@@ -1,7 +1,14 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ComponentPropsWithRef } from 'react';
|
|
2
2
|
import { FC } from 'react';
|
|
3
3
|
import { ReactNode } from 'react';
|
|
4
4
|
|
|
5
|
+
export interface ButtonProps extends Omit<ComponentPropsWithRef<'button'>, 'children'> {
|
|
6
|
+
children: ReactNode;
|
|
7
|
+
size?: ButtonSize;
|
|
8
|
+
variant?: ButtonVariant;
|
|
9
|
+
iconPosition?: IconPosition;
|
|
10
|
+
}
|
|
11
|
+
|
|
5
12
|
export type ButtonSize = 'small' | 'default' | 'large';
|
|
6
13
|
|
|
7
14
|
export type ButtonVariant = 'primary-green' | 'primary-darkgreen' | 'primary-yellow' | 'primary-white' | 'secondary-green' | 'secondary-yellow' | 'secondary-red' | 'secondary-black' | 'tertiary-bold' | 'tertiary-thin' | 'tertiary-icon' | 'tertiary-link' | 'icon-black' | 'icon-grey' | 'icon-mobile';
|
|
@@ -14,20 +21,12 @@ export declare interface FaqTeaserSectionProps {
|
|
|
14
21
|
id: string;
|
|
15
22
|
content: ReactNode;
|
|
16
23
|
}[];
|
|
17
|
-
cta:
|
|
24
|
+
cta: ButtonProps;
|
|
18
25
|
bgImage: ReactNode;
|
|
19
26
|
}
|
|
20
27
|
|
|
21
28
|
export type IconPosition = 'left' | 'right' | 'top';
|
|
22
29
|
|
|
23
|
-
export interface LinkProps extends ComponentPropsWithoutRef<'a'> {
|
|
24
|
-
children: ReactNode;
|
|
25
|
-
asChild?: boolean;
|
|
26
|
-
size?: ButtonSize;
|
|
27
|
-
variant?: ButtonVariant;
|
|
28
|
-
iconPosition?: IconPosition;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
30
|
export interface SectionHeadingProps {
|
|
32
31
|
title: string;
|
|
33
32
|
description?: string;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as l, jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
import {
|
|
4
|
-
import { SectionHeading as c } from "./SectionHeading.js";
|
|
3
|
+
import { SectionHeading as n } from "./SectionHeading.js";
|
|
5
4
|
import { ChevronRightIcon as d } from "./ChevronRightIcon.js";
|
|
6
|
-
|
|
5
|
+
import { Button as s } from "./Button.js";
|
|
6
|
+
const g = ({ header: o, questions: r, cta: t, bgImage: a }) => r.length === 0 ? null : /* @__PURE__ */ l("section", { className: "bg-neutral-25 relative overflow-hidden px-6 py-10 lg:px-8 lg:py-12 xl:px-55", children: [
|
|
7
7
|
/* @__PURE__ */ e("div", { className: "pointer-events-none absolute -bottom-17 -left-16 hidden xl:block", children: a }),
|
|
8
|
-
/* @__PURE__ */
|
|
9
|
-
/* @__PURE__ */ e(
|
|
10
|
-
/* @__PURE__ */
|
|
11
|
-
/* @__PURE__ */ e("ul", { className: "flex flex-col gap-6", children:
|
|
8
|
+
/* @__PURE__ */ l("div", { className: "relative z-2 flex flex-col justify-center gap-6 md:flex-row md:items-center xl:gap-10", children: [
|
|
9
|
+
/* @__PURE__ */ e(n, { className: "xl:max-w-120", align: "start", ...o }),
|
|
10
|
+
/* @__PURE__ */ l("div", { className: "flex flex-col gap-10 rounded-lg bg-white p-8 shadow md:min-w-87 lg:min-w-117 xl:max-w-120 xl:min-w-120", children: [
|
|
11
|
+
/* @__PURE__ */ e("ul", { className: "flex flex-col gap-6", children: r.map((i) => /* @__PURE__ */ l(
|
|
12
12
|
"li",
|
|
13
13
|
{
|
|
14
14
|
className: "text-medium group hover:bg-primary-100 flex w-fit cursor-pointer items-center rounded-sm p-2 font-bold text-neutral-800 transition duration-300",
|
|
@@ -19,7 +19,7 @@ const g = ({ header: o, questions: l, cta: t, bgImage: a }) => l.length === 0 ?
|
|
|
19
19
|
},
|
|
20
20
|
i.id
|
|
21
21
|
)) }),
|
|
22
|
-
/* @__PURE__ */ e(
|
|
22
|
+
/* @__PURE__ */ e(s, { className: "w-fit", size: "default", variant: "primary-yellow", ...t })
|
|
23
23
|
] })
|
|
24
24
|
] })
|
|
25
25
|
] });
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { ComponentPropsWithoutRef } from 'react';
|
|
2
1
|
import { ComponentPropsWithRef } from 'react';
|
|
3
2
|
import { FC } from 'react';
|
|
4
3
|
import { ReactNode } from 'react';
|
|
@@ -42,7 +41,7 @@ export interface FaqTeaserSectionProps {
|
|
|
42
41
|
id: string;
|
|
43
42
|
content: ReactNode;
|
|
44
43
|
}[];
|
|
45
|
-
cta:
|
|
44
|
+
cta: ButtonProps;
|
|
46
45
|
bgImage: ReactNode;
|
|
47
46
|
}
|
|
48
47
|
|
|
@@ -105,14 +104,6 @@ export interface LawGeniusSectionProps {
|
|
|
105
104
|
image: ReactNode;
|
|
106
105
|
}
|
|
107
106
|
|
|
108
|
-
export interface LinkProps extends ComponentPropsWithoutRef<'a'> {
|
|
109
|
-
children: ReactNode;
|
|
110
|
-
asChild?: boolean;
|
|
111
|
-
size?: ButtonSize;
|
|
112
|
-
variant?: ButtonVariant;
|
|
113
|
-
iconPosition?: IconPosition;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
107
|
export interface PopularDocumentsProps {
|
|
117
108
|
header: SectionHeadingProps;
|
|
118
109
|
moreDocuments?: ItemProps[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@npm_leadtech/legal-contracts-ui",
|
|
3
|
-
"version": "0.44.
|
|
3
|
+
"version": "0.44.21",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -22,10 +22,6 @@
|
|
|
22
22
|
"import": "./dist/components/Button.js",
|
|
23
23
|
"types": "./dist/components/Button.d.ts"
|
|
24
24
|
},
|
|
25
|
-
"./components/Button.utils.ts": {
|
|
26
|
-
"import": "./dist/components/Button.utils.ts.js",
|
|
27
|
-
"types": "./dist/components/Button.utils.ts.d.ts"
|
|
28
|
-
},
|
|
29
25
|
"./components/Card": {
|
|
30
26
|
"import": "./dist/components/Card.js",
|
|
31
27
|
"types": "./dist/components/Card.d.ts"
|
|
@@ -46,10 +42,6 @@
|
|
|
46
42
|
"import": "./dist/components/Item.js",
|
|
47
43
|
"types": "./dist/components/Item.d.ts"
|
|
48
44
|
},
|
|
49
|
-
"./components/Link": {
|
|
50
|
-
"import": "./dist/components/Link.js",
|
|
51
|
-
"types": "./dist/components/Link.d.ts"
|
|
52
|
-
},
|
|
53
45
|
"./components/Markdown": {
|
|
54
46
|
"import": "./dist/components/Markdown.js",
|
|
55
47
|
"types": "./dist/components/Markdown.d.ts"
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { ComponentPropsWithoutRef } from 'react';
|
|
2
|
-
import { JSX } from 'react/jsx-runtime';
|
|
3
|
-
import { ReactNode } from 'react';
|
|
4
|
-
|
|
5
|
-
export type ButtonSize = 'small' | 'default' | 'large';
|
|
6
|
-
|
|
7
|
-
export type ButtonVariant = 'primary-green' | 'primary-darkgreen' | 'primary-yellow' | 'primary-white' | 'secondary-green' | 'secondary-yellow' | 'secondary-red' | 'secondary-black' | 'tertiary-bold' | 'tertiary-thin' | 'tertiary-icon' | 'tertiary-link' | 'icon-black' | 'icon-grey' | 'icon-mobile';
|
|
8
|
-
|
|
9
|
-
export type IconPosition = 'left' | 'right' | 'top';
|
|
10
|
-
|
|
11
|
-
export declare const Link: ({ children, asChild, size, variant, iconPosition, className, ...props }: LinkProps) => JSX.Element;
|
|
12
|
-
|
|
13
|
-
export declare interface LinkProps extends ComponentPropsWithoutRef<'a'> {
|
|
14
|
-
children: ReactNode;
|
|
15
|
-
asChild?: boolean;
|
|
16
|
-
size?: ButtonSize;
|
|
17
|
-
variant?: ButtonVariant;
|
|
18
|
-
iconPosition?: IconPosition;
|
|
19
|
-
}
|
|
20
|
-
|
package/dist/components/Link.js
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { jsx as f } from "react/jsx-runtime";
|
|
2
|
-
import { isValidElement as n, cloneElement as i } from "react";
|
|
3
|
-
import { getButtonStyles as p } from "./atoms/Button.utils.js";
|
|
4
|
-
const g = ({
|
|
5
|
-
children: t,
|
|
6
|
-
asChild: m = !1,
|
|
7
|
-
size: a = "default",
|
|
8
|
-
variant: r = "primary-green",
|
|
9
|
-
iconPosition: o = "left",
|
|
10
|
-
className: l,
|
|
11
|
-
...e
|
|
12
|
-
}) => {
|
|
13
|
-
const s = p({ variant: r, size: a, iconPosition: o, className: l });
|
|
14
|
-
return m && n(t) ? i(t, {
|
|
15
|
-
...e,
|
|
16
|
-
className: `${s} ${t.props.className ?? ""}`.trim()
|
|
17
|
-
}) : /* @__PURE__ */ f("a", { className: s, ...e, children: t });
|
|
18
|
-
};
|
|
19
|
-
export {
|
|
20
|
-
g as Link
|
|
21
|
-
};
|
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
import "react/jsx-runtime";
|
|
2
|
-
import "react";
|
|
3
|
-
const b = {
|
|
4
|
-
"primary-green": {
|
|
5
|
-
base: "bg-primary-700 text-white border border-transparent font-semibold",
|
|
6
|
-
hover: "hover:bg-primary-500",
|
|
7
|
-
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:cursor-not-allowed"
|
|
8
|
-
},
|
|
9
|
-
"primary-darkgreen": {
|
|
10
|
-
base: "bg-primary-900 text-white border border-transparent font-semibold",
|
|
11
|
-
hover: "hover:bg-primary-800",
|
|
12
|
-
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:cursor-not-allowed"
|
|
13
|
-
},
|
|
14
|
-
"primary-yellow": {
|
|
15
|
-
base: "bg-secondary-500 text-neutral-900 border border-transparent font-semibold",
|
|
16
|
-
hover: "hover:bg-secondary-400",
|
|
17
|
-
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:cursor-not-allowed"
|
|
18
|
-
},
|
|
19
|
-
"primary-white": {
|
|
20
|
-
base: "bg-white text-neutral-900 font-semibold border border-transparent",
|
|
21
|
-
hover: "hover:bg-neutral-50",
|
|
22
|
-
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:cursor-not-allowed"
|
|
23
|
-
},
|
|
24
|
-
"secondary-green": {
|
|
25
|
-
base: "bg-white text-primary-700 border-2 border-primary-700 font-semibold",
|
|
26
|
-
hover: "hover:bg-primary-100 hover:text-primary-800",
|
|
27
|
-
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:border-neutral-200 disabled:cursor-not-allowed"
|
|
28
|
-
},
|
|
29
|
-
"secondary-yellow": {
|
|
30
|
-
base: "bg-transparent text-neutral-900 border-2 border-secondary-500 font-semibold",
|
|
31
|
-
hover: "hover:bg-secondary-100 hover:border-secondary-600",
|
|
32
|
-
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:border-neutral-200 disabled:cursor-not-allowed"
|
|
33
|
-
},
|
|
34
|
-
"secondary-red": {
|
|
35
|
-
base: "bg-transparent text-error-500 border-2 border-error-500 font-semibold",
|
|
36
|
-
hover: "hover:bg-error-25",
|
|
37
|
-
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:border-neutral-200 disabled:cursor-not-allowed"
|
|
38
|
-
},
|
|
39
|
-
"secondary-black": {
|
|
40
|
-
base: "bg-transparent text-neutral-800 border-2 border-neutral-600 font-semibold",
|
|
41
|
-
hover: "hover:bg-neutral-200",
|
|
42
|
-
disabled: "disabled:bg-neutral-200 disabled:text-neutral-400 disabled:border-neutral-200 disabled:cursor-not-allowed"
|
|
43
|
-
},
|
|
44
|
-
"tertiary-bold": {
|
|
45
|
-
base: "bg-transparent text-primary-700 font-semibold border border-transparent font-semibold p-1.5!",
|
|
46
|
-
hover: "hover:text-primary-500 hover:bg-primary-200",
|
|
47
|
-
disabled: "disabled:text-neutral-400 disabled:cursor-not-allowed disabled:bg-white"
|
|
48
|
-
},
|
|
49
|
-
"tertiary-thin": {
|
|
50
|
-
base: "bg-transparent text-neutral-800 font-normal border border-transparent p-1.5!",
|
|
51
|
-
hover: " hover:bg-primary-100",
|
|
52
|
-
disabled: "disabled:text-neutral-400 disabled:cursor-not-allowed disabled:bg-white"
|
|
53
|
-
},
|
|
54
|
-
"tertiary-icon": {
|
|
55
|
-
base: "bg-transparent text-neutral-800 font-medium border border-transparent p-1.5!",
|
|
56
|
-
hover: "hover:bg-primary-100",
|
|
57
|
-
disabled: "disabled:text-neutral-400 disabled:cursor-not-allowed disabled:bg-white"
|
|
58
|
-
},
|
|
59
|
-
"tertiary-link": {
|
|
60
|
-
base: "bg-transparent text-primary-700 underline underline-offset-2 border border-transparent",
|
|
61
|
-
hover: "",
|
|
62
|
-
disabled: "disabled:text-neutral-400 disabled:cursor-not-allowed disabled:bg-white"
|
|
63
|
-
},
|
|
64
|
-
"icon-black": {
|
|
65
|
-
base: "bg-black text-white border border-transparent font-semibold",
|
|
66
|
-
hover: "hover:bg-neutral-800",
|
|
67
|
-
disabled: "disabled:bg-neutral-400 disabled:cursor-not-allowed"
|
|
68
|
-
},
|
|
69
|
-
"icon-grey": {
|
|
70
|
-
base: "bg-transparent text-neutral-800 border-2 border-neutral-600 font-semibold",
|
|
71
|
-
hover: "hover:bg-neutral-200",
|
|
72
|
-
disabled: "disabled:text-neutral-400 disabled:border-neutral-400 disabled:bg-white disabled:cursor-not-allowed"
|
|
73
|
-
},
|
|
74
|
-
"icon-mobile": {
|
|
75
|
-
base: "bg-transparent text-primary-700 border border-neutral-200 border-2 px-8 rounded-sm",
|
|
76
|
-
hover: "hover:bg-neutral-50",
|
|
77
|
-
disabled: "disabled:text-neutral-400 disabled:border-neutral-400 disabled:bg-white disabled:cursor-not-allowed"
|
|
78
|
-
}
|
|
79
|
-
}, s = {
|
|
80
|
-
small: "px-3 py-1.5 text-small",
|
|
81
|
-
default: "px-4 py-2.5 text-medium",
|
|
82
|
-
large: "px-6 py-3 text-big"
|
|
83
|
-
}, u = ({
|
|
84
|
-
variant: t,
|
|
85
|
-
size: a,
|
|
86
|
-
iconPosition: r,
|
|
87
|
-
disabled: d = !1,
|
|
88
|
-
className: o = ""
|
|
89
|
-
}) => {
|
|
90
|
-
const e = b[t], l = () => r === "top" ? "flex-col" : r === "right" ? "flex-row-reverse" : "flex-row";
|
|
91
|
-
return [
|
|
92
|
-
"inline-flex items-center justify-center gap-2 rounded-sm font-medium transition-all duration-200",
|
|
93
|
-
"focus:outline-none focus-visible:ring-2 focus-visible:ring-primary-500 focus-visible:ring-offset-2",
|
|
94
|
-
d ? "" : "cursor-pointer",
|
|
95
|
-
e.base,
|
|
96
|
-
e.hover,
|
|
97
|
-
e.disabled,
|
|
98
|
-
s[a],
|
|
99
|
-
l(),
|
|
100
|
-
o
|
|
101
|
-
].filter(Boolean).join(" ");
|
|
102
|
-
};
|
|
103
|
-
export {
|
|
104
|
-
u as getButtonStyles
|
|
105
|
-
};
|