@npm_leadtech/legal-contracts-ui 0.145.2 → 0.145.3
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/Anchor.d.ts +3 -1
- package/dist/components/Anchor.js +8 -7
- package/dist/components/Blockquote.d.ts +3 -1
- package/dist/components/Header2.d.ts +3 -1
- package/dist/components/Markdown.d.ts +3 -1
- package/dist/components/Modal.js +31 -54
- package/dist/components/OrderedList.d.ts +3 -1
- package/dist/components/Paragraph.d.ts +3 -1
- package/dist/components/SaveIcon.js +7 -24
- package/dist/components/UiComponents.d.ts +8 -6
- package/dist/components/UnorderedList.d.ts +3 -1
- package/dist/components/UnsubscribeTemplate.d.ts +3 -1
- package/package.json +1 -1
- package/dist/components/index.d.ts +0 -1342
|
@@ -3,6 +3,8 @@ import { JSX } from 'react/jsx-runtime';
|
|
|
3
3
|
export declare const Anchor: ({ children, variant, className, ...props }: AnchorProps) => JSX.Element;
|
|
4
4
|
|
|
5
5
|
export interface AnchorProps extends React.ComponentProps<'a'> {
|
|
6
|
-
variant?:
|
|
6
|
+
variant?: MarkdownVariants;
|
|
7
7
|
}
|
|
8
|
+
|
|
9
|
+
export type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
8
10
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as h } from "react/jsx-runtime";
|
|
2
2
|
import p from "clsx";
|
|
3
|
-
const b = ({ children: a, variant:
|
|
3
|
+
const b = ({ children: a, variant: l = "default", className: c = "", ...r }) => {
|
|
4
4
|
const t = r.href || "", n = t.toLowerCase(), u = n.startsWith("mailto:"), o = n.startsWith("tel:"), e = "cursor-pointer text-primary-700", s = {
|
|
5
5
|
default: "text-neutral-900 underline",
|
|
6
6
|
legal: e,
|
|
@@ -8,8 +8,9 @@ const b = ({ children: a, variant: c = "default", className: l = "", ...r }) =>
|
|
|
8
8
|
"about-us": e,
|
|
9
9
|
pricing: "cursor-pointer text-neutral-900",
|
|
10
10
|
unsubscribe: e,
|
|
11
|
-
cookies: "text-white"
|
|
12
|
-
|
|
11
|
+
cookies: "text-white",
|
|
12
|
+
story: "text-neutral-800 underline"
|
|
13
|
+
}, d = s[l] ?? s.default, i = t.startsWith("http") && !o && !u, f = (() => {
|
|
13
14
|
if (!o) return t;
|
|
14
15
|
try {
|
|
15
16
|
return decodeURIComponent(t).replace(/\s/g, "");
|
|
@@ -17,12 +18,12 @@ const b = ({ children: a, variant: c = "default", className: l = "", ...r }) =>
|
|
|
17
18
|
return t.replace(/%20/g, "").replace(/\s/g, "");
|
|
18
19
|
}
|
|
19
20
|
})();
|
|
20
|
-
return /* @__PURE__ */
|
|
21
|
+
return /* @__PURE__ */ h(
|
|
21
22
|
"a",
|
|
22
23
|
{
|
|
23
24
|
...r,
|
|
24
|
-
href:
|
|
25
|
-
className: p(
|
|
25
|
+
href: f,
|
|
26
|
+
className: p(c, d),
|
|
26
27
|
target: i ? "_blank" : void 0,
|
|
27
28
|
rel: i ? "noopener noreferrer" : void 0,
|
|
28
29
|
children: a
|
|
@@ -3,6 +3,8 @@ import { JSX } from 'react/jsx-runtime';
|
|
|
3
3
|
export declare const Blockquote: ({ children, variant }: BlockquoteProps) => JSX.Element;
|
|
4
4
|
|
|
5
5
|
export interface BlockquoteProps extends React.ComponentProps<'blockquote'> {
|
|
6
|
-
variant?:
|
|
6
|
+
variant?: MarkdownVariants;
|
|
7
7
|
}
|
|
8
|
+
|
|
9
|
+
export type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
8
10
|
|
|
@@ -3,6 +3,8 @@ import { JSX } from 'react/jsx-runtime';
|
|
|
3
3
|
export declare const Header2: ({ children, variant }: Header2Props) => JSX.Element;
|
|
4
4
|
|
|
5
5
|
export interface Header2Props extends React.ComponentProps<'h2'> {
|
|
6
|
-
variant?:
|
|
6
|
+
variant?: MarkdownVariants;
|
|
7
7
|
}
|
|
8
|
+
|
|
9
|
+
export type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
8
10
|
|
|
@@ -6,6 +6,8 @@ export declare interface MarkdownProps {
|
|
|
6
6
|
content: string;
|
|
7
7
|
className?: string;
|
|
8
8
|
useCustom?: boolean;
|
|
9
|
-
variant?:
|
|
9
|
+
variant?: MarkdownVariants;
|
|
10
10
|
}
|
|
11
|
+
|
|
12
|
+
export declare type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
11
13
|
|
package/dist/components/Modal.js
CHANGED
|
@@ -1,64 +1,41 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsxs as
|
|
3
|
-
import { useEffect as
|
|
4
|
-
import { createPortal as
|
|
2
|
+
import { jsxs as s, Fragment as f, jsx as e } from "react/jsx-runtime";
|
|
3
|
+
import { useEffect as d } from "react";
|
|
4
|
+
import { createPortal as m } from "react-dom";
|
|
5
5
|
import { CloseIcon as y } from "./CloseIcon.js";
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
},
|
|
10
|
-
|
|
11
|
-
}, u = (e) => {
|
|
12
|
-
e.target === e.currentTarget && n();
|
|
6
|
+
const x = ({ trigger: l, children: a, isOpen: o, setIsOpen: c, showClose: i, onTrigger: n }) => {
|
|
7
|
+
const r = () => {
|
|
8
|
+
n && n(), c(!o);
|
|
9
|
+
}, u = (t) => {
|
|
10
|
+
t.target === t.currentTarget && r();
|
|
13
11
|
};
|
|
14
|
-
return
|
|
15
|
-
if (!
|
|
16
|
-
const
|
|
12
|
+
return d(() => {
|
|
13
|
+
if (!o) return;
|
|
14
|
+
const t = document.body.style.overflow;
|
|
17
15
|
return document.body.style.overflow = "hidden", () => {
|
|
18
|
-
document.body.style.overflow =
|
|
16
|
+
document.body.style.overflow = t;
|
|
19
17
|
};
|
|
20
|
-
}, [
|
|
21
|
-
!!
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
"aria-label": "zoom",
|
|
26
|
-
onClick: d,
|
|
27
|
-
className: "flex w-full cursor-pointer justify-center",
|
|
28
|
-
children: r
|
|
29
|
-
}
|
|
30
|
-
),
|
|
31
|
-
t && p(
|
|
32
|
-
/* @__PURE__ */ o(
|
|
33
|
-
"div",
|
|
18
|
+
}, [o]), /* @__PURE__ */ s(f, { children: [
|
|
19
|
+
!!l && /* @__PURE__ */ e("button", { "aria-label": "zoom", onClick: r, className: "flex w-full cursor-pointer justify-center", children: l }),
|
|
20
|
+
o && m(
|
|
21
|
+
/* @__PURE__ */ e(
|
|
22
|
+
"button",
|
|
34
23
|
{
|
|
35
|
-
role: "dialog",
|
|
36
|
-
"aria-modal": "true",
|
|
37
|
-
"data-testid": "modal-backdrop",
|
|
38
24
|
className: "bg-primary-900/80 fixed inset-0 z-1001 flex items-center justify-center",
|
|
39
25
|
onClick: u,
|
|
40
|
-
children: /* @__PURE__ */
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
onClick: n,
|
|
54
|
-
"aria-label": "Close",
|
|
55
|
-
children: /* @__PURE__ */ o(y, {})
|
|
56
|
-
}
|
|
57
|
-
),
|
|
58
|
-
i
|
|
59
|
-
]
|
|
60
|
-
}
|
|
61
|
-
) })
|
|
26
|
+
children: /* @__PURE__ */ e("div", { className: "pointer-events-none relative flex max-h-screen w-full items-start justify-center overflow-y-auto px-6 py-24", children: /* @__PURE__ */ s("div", { className: "pointer-events-auto relative", children: [
|
|
27
|
+
i && /* @__PURE__ */ e(
|
|
28
|
+
"button",
|
|
29
|
+
{
|
|
30
|
+
type: "button",
|
|
31
|
+
className: "absolute top-4 right-4 z-10 cursor-pointer rounded-full p-2 transition-colors hover:bg-neutral-100 focus:outline-none",
|
|
32
|
+
onClick: r,
|
|
33
|
+
"aria-label": "Close",
|
|
34
|
+
children: /* @__PURE__ */ e(y, {})
|
|
35
|
+
}
|
|
36
|
+
),
|
|
37
|
+
a
|
|
38
|
+
] }) })
|
|
62
39
|
}
|
|
63
40
|
),
|
|
64
41
|
document.body
|
|
@@ -66,5 +43,5 @@ const w = ({ trigger: r, children: i, isOpen: t, setIsOpen: l, showClose: s, onT
|
|
|
66
43
|
] });
|
|
67
44
|
};
|
|
68
45
|
export {
|
|
69
|
-
|
|
46
|
+
x as Modal
|
|
70
47
|
};
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { JSX } from 'react/jsx-runtime';
|
|
2
2
|
|
|
3
|
+
export type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
4
|
+
|
|
3
5
|
export declare const OrderedList: ({ variant, children }: OrderedListProps) => JSX.Element;
|
|
4
6
|
|
|
5
7
|
export interface OrderedListProps extends React.ComponentProps<'ol'> {
|
|
6
|
-
variant?:
|
|
8
|
+
variant?: MarkdownVariants;
|
|
7
9
|
}
|
|
8
10
|
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { JSX } from 'react/jsx-runtime';
|
|
2
2
|
|
|
3
|
+
export type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
4
|
+
|
|
3
5
|
export declare const Paragraph: ({ variant, children }: ParagraphProps) => JSX.Element;
|
|
4
6
|
|
|
5
7
|
export interface ParagraphProps extends React.ComponentProps<'p'> {
|
|
6
|
-
variant?:
|
|
8
|
+
variant?: MarkdownVariants;
|
|
7
9
|
}
|
|
8
10
|
|
|
@@ -1,31 +1,14 @@
|
|
|
1
1
|
import { jsx as l } from "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
|
-
const i = ({
|
|
4
|
-
|
|
5
|
-
width: e = 16,
|
|
6
|
-
height: o = 16,
|
|
7
|
-
...n
|
|
8
|
-
}) => /* @__PURE__ */ l(
|
|
9
|
-
"svg",
|
|
3
|
+
const i = (e) => /* @__PURE__ */ l("svg", { xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", fill: "none", viewBox: "0 0 16 16", ...e, children: /* @__PURE__ */ l(
|
|
4
|
+
"path",
|
|
10
5
|
{
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
fill: "none",
|
|
16
|
-
viewBox: "0 0 16 16",
|
|
17
|
-
...n,
|
|
18
|
-
children: /* @__PURE__ */ l(
|
|
19
|
-
"path",
|
|
20
|
-
{
|
|
21
|
-
fill: a,
|
|
22
|
-
fillRule: "evenodd",
|
|
23
|
-
d: "m10.028 7.423-1.306 1.45V1.806a.722.722 0 0 0-1.444 0v7.067l-1.306-1.45a.759.759 0 0 0-1.129 1.014l2.412 2.691a1 1 0 0 0 1.49 0l2.412-2.69a.76.76 0 0 0-1.13-1.015m3.028 1.633a.722.722 0 1 1 1.444 0v5.528a1 1 0 0 1-1 1h-11a1 1 0 0 1-1-1V9.056a.722.722 0 0 1 1.444 0v4.916h10.112z",
|
|
24
|
-
clipRule: "evenodd"
|
|
25
|
-
}
|
|
26
|
-
)
|
|
6
|
+
fill: "var(--color-neutral-900)",
|
|
7
|
+
fillRule: "evenodd",
|
|
8
|
+
d: "m10.028 7.423-1.306 1.45V1.806a.722.722 0 0 0-1.444 0v7.067l-1.306-1.45a.759.759 0 0 0-1.129 1.014l2.412 2.691a1 1 0 0 0 1.49 0l2.412-2.69a.76.76 0 0 0-1.13-1.015m3.028 1.633a.722.722 0 1 1 1.444 0v5.528a1 1 0 0 1-1 1h-11a1 1 0 0 1-1-1V9.056a.722.722 0 0 1 1.444 0v4.916h10.112z",
|
|
9
|
+
clipRule: "evenodd"
|
|
27
10
|
}
|
|
28
|
-
);
|
|
11
|
+
) });
|
|
29
12
|
export {
|
|
30
13
|
i as SaveIcon
|
|
31
14
|
};
|
|
@@ -4,13 +4,13 @@ import { JSX } from 'react/jsx-runtime';
|
|
|
4
4
|
export declare const Anchor: ({ children, variant, className, ...props }: AnchorProps) => JSX.Element;
|
|
5
5
|
|
|
6
6
|
export interface AnchorProps extends React.ComponentProps<'a'> {
|
|
7
|
-
variant?:
|
|
7
|
+
variant?: MarkdownVariants;
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
export declare const Blockquote: ({ children, variant }: BlockquoteProps) => JSX.Element;
|
|
11
11
|
|
|
12
12
|
export interface BlockquoteProps extends React.ComponentProps<'blockquote'> {
|
|
13
|
-
variant?:
|
|
13
|
+
variant?: MarkdownVariants;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
export declare const Code: ({ children, className }: React.ComponentProps<"code">) => JSX.Element;
|
|
@@ -22,23 +22,25 @@ export declare const Header1: ({ children }: React.ComponentProps<"h1">) => JSX.
|
|
|
22
22
|
export declare const Header2: ({ children, variant }: Header2Props) => JSX.Element;
|
|
23
23
|
|
|
24
24
|
export interface Header2Props extends React.ComponentProps<'h2'> {
|
|
25
|
-
variant?:
|
|
25
|
+
variant?: MarkdownVariants;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
28
|
export declare const Header3: ({ children }: React.ComponentProps<"h3">) => JSX.Element;
|
|
29
29
|
|
|
30
30
|
export declare const Header4: ({ children }: React.ComponentProps<"h4">) => JSX.Element;
|
|
31
31
|
|
|
32
|
+
export type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
33
|
+
|
|
32
34
|
export declare const OrderedList: ({ variant, children }: OrderedListProps) => JSX.Element;
|
|
33
35
|
|
|
34
36
|
export interface OrderedListProps extends React.ComponentProps<'ol'> {
|
|
35
|
-
variant?:
|
|
37
|
+
variant?: MarkdownVariants;
|
|
36
38
|
}
|
|
37
39
|
|
|
38
40
|
export declare const Paragraph: ({ variant, children }: ParagraphProps) => JSX.Element;
|
|
39
41
|
|
|
40
42
|
export interface ParagraphProps extends React.ComponentProps<'p'> {
|
|
41
|
-
variant?:
|
|
43
|
+
variant?: MarkdownVariants;
|
|
42
44
|
}
|
|
43
45
|
|
|
44
46
|
export declare const Table: ({ children }: React.ComponentProps<"table">) => JSX.Element;
|
|
@@ -52,7 +54,7 @@ export declare const TableRow: ({ children }: React.ComponentProps<"tr">) => JSX
|
|
|
52
54
|
export declare const UnorderedList: ({ variant, children }: UnorderedListProps) => JSX.Element;
|
|
53
55
|
|
|
54
56
|
export interface UnorderedListProps extends React.ComponentProps<'ul'> {
|
|
55
|
-
variant?:
|
|
57
|
+
variant?: MarkdownVariants;
|
|
56
58
|
}
|
|
57
59
|
|
|
58
60
|
export declare const Video: ({ children }: React.ComponentProps<"video">) => JSX.Element;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
import { JSX } from 'react/jsx-runtime';
|
|
2
2
|
|
|
3
|
+
export type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
4
|
+
|
|
3
5
|
export declare const UnorderedList: ({ variant, children }: UnorderedListProps) => JSX.Element;
|
|
4
6
|
|
|
5
7
|
export interface UnorderedListProps extends React.ComponentProps<'ul'> {
|
|
6
|
-
variant?:
|
|
8
|
+
variant?: MarkdownVariants;
|
|
7
9
|
}
|
|
8
10
|
|
|
@@ -10,9 +10,11 @@ export interface MarkdownProps {
|
|
|
10
10
|
content: string;
|
|
11
11
|
className?: string;
|
|
12
12
|
useCustom?: boolean;
|
|
13
|
-
variant?:
|
|
13
|
+
variant?: MarkdownVariants;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
+
export type MarkdownVariants = 'default' | 'legal' | 'ratafia' | 'tooltip' | 'about-us' | 'pricing' | 'unsubscribe' | 'cookies' | 'story';
|
|
17
|
+
|
|
16
18
|
export declare const UnsubscribeTemplate: FC<UnsubscribeTemplateProps>;
|
|
17
19
|
|
|
18
20
|
export declare interface UnsubscribeTemplateProps {
|