@npm_leadtech/legal-contracts-ui 0.93.4 → 0.93.6

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,6 +1,6 @@
1
1
  import { jsx as e, jsxs as n } from "react/jsx-runtime";
2
2
  import "react";
3
- import { useScroll as r } from "../hooks/useScroll.js";
3
+ import { useScroll as r } from "../shared/hooks/useScroll.js";
4
4
  import { SinglePhoneIcon as d } from "./SinglePhoneIcon.js";
5
5
  const f = ({ contactText: s, phoneNumber: l, contactHoursText: t, contactHours: a }) => {
6
6
  const i = r(10);
@@ -23,6 +23,7 @@ export declare interface ElectronicSignatureTemplateProps {
23
23
  trustPilot: ReactNode;
24
24
  signAndSend: BannerTagSectionProps;
25
25
  faq: FaqSectionProps;
26
+ toast?: ToastProps;
26
27
  }
27
28
 
28
29
  export interface FaqItemProps {
@@ -108,6 +109,15 @@ export interface TagProps {
108
109
  className?: string;
109
110
  }
110
111
 
112
+ export interface ToastProps {
113
+ show: boolean;
114
+ title: string;
115
+ message: string;
116
+ type?: 'success' | 'error' | 'default';
117
+ onClose: () => void;
118
+ duration?: number;
119
+ }
120
+
111
121
  export interface UploadZoneProps {
112
122
  uploadPromptText: string;
113
123
  addDocumentLabel: string;
@@ -1,28 +1,30 @@
1
- import { jsx as o, jsxs as l } from "react/jsx-runtime";
2
- import { ToastProvider as s } from "../hooks/useToast.js";
3
- import { Hero2Section as c } from "./Hero2Section.js";
4
- import { HowItWorksSection as p } from "./HowItWorksSection.js";
1
+ import { jsxs as p, jsx as o } from "react/jsx-runtime";
2
+ import { Hero2Section as s } from "./Hero2Section.js";
3
+ import { HowItWorksSection as c } from "./HowItWorksSection.js";
5
4
  import { FastAndSimpleSection as x } from "./FastAndSimpleSection.js";
6
5
  import { FeaturesSection as f } from "./FeaturesSection.js";
7
- import { BannerTagSection as d } from "./BannerTagSection.js";
8
- import { FaqSection as g } from "./FaqSection.js";
9
- const T = ({
6
+ import { BannerTagSection as g } from "./BannerTagSection.js";
7
+ import { Toast as S } from "./Toast.js";
8
+ import { FaqSection as u } from "./FaqSection.js";
9
+ const b = ({
10
10
  hero: r,
11
- howItWorks: e,
12
- fastAndSimple: i,
11
+ howItWorks: i,
12
+ fastAndSimple: m,
13
13
  benefits: t,
14
- trustPilot: m,
15
- signAndSend: a,
16
- faq: n
17
- }) => /* @__PURE__ */ o(s, { children: /* @__PURE__ */ l("main", { className: "bg-neutral-25 w-full flex-1", children: [
18
- /* @__PURE__ */ o(c, { ...r, variant: "esign" }),
19
- /* @__PURE__ */ o(p, { ...e }),
20
- /* @__PURE__ */ o(x, { ...i, variant: "esign" }),
14
+ trustPilot: a,
15
+ signAndSend: n,
16
+ faq: l,
17
+ toast: e
18
+ }) => /* @__PURE__ */ p("main", { className: "bg-neutral-25 w-full flex-1", children: [
19
+ /* @__PURE__ */ o(s, { ...r, variant: "esign" }),
20
+ /* @__PURE__ */ o(c, { ...i }),
21
+ /* @__PURE__ */ o(x, { ...m, variant: "esign" }),
21
22
  /* @__PURE__ */ o(f, { ...t }),
22
- /* @__PURE__ */ o("section", { className: "bg-white px-6 py-8 lg:px-8 lg:py-12 xl:px-0", children: /* @__PURE__ */ o("div", { className: "mx-auto w-full max-w-254 md:h-34", children: m }) }),
23
- /* @__PURE__ */ o(d, { ...a }),
24
- /* @__PURE__ */ o(g, { ...n, className: "mx-auto max-w-4xl px-4 py-16" })
25
- ] }) });
23
+ /* @__PURE__ */ o("section", { className: "bg-white px-6 py-8 lg:px-8 lg:py-12 xl:px-0", children: /* @__PURE__ */ o("div", { className: "mx-auto w-full max-w-254 md:h-34", children: a }) }),
24
+ /* @__PURE__ */ o(g, { ...n }),
25
+ /* @__PURE__ */ o(u, { ...l, className: "mx-auto max-w-4xl px-4 py-16" }),
26
+ e && /* @__PURE__ */ o(S, { ...e })
27
+ ] });
26
28
  export {
27
- T as ElectronicSignatureTemplate
29
+ b as ElectronicSignatureTemplate
28
30
  };
@@ -1,7 +1,7 @@
1
1
  import { jsxs as r, jsx as e } from "react/jsx-runtime";
2
2
  import "react";
3
3
  import { MobileMenu as o } from "./MobileMenu.js";
4
- import { useScroll as c } from "../hooks/useScroll.js";
4
+ import { useScroll as c } from "../shared/hooks/useScroll.js";
5
5
  import { NavMenu as s } from "./NavMenu.js";
6
6
  import { LanguageSelector as p } from "./LanguageSelector.js";
7
7
  import { ScalatorIcon as x } from "./ScalatorIcon.js";
@@ -16,25 +16,31 @@ const g = {
16
16
  icon: /* @__PURE__ */ e(c, { fill: "white", width: 24, height: 24 }),
17
17
  bg: "bg-neutral-500"
18
18
  }
19
- }, N = ({ show: l, title: n, message: s, type: m = "default", onClose: i, duration: t = 3e3 }) => {
19
+ }, N = ({ show: l, title: n, message: s, type: h = "default", onClose: i, duration: t = 3e3 }) => {
20
20
  a(() => {
21
- const h = setTimeout(() => {
21
+ const m = setTimeout(() => {
22
22
  i();
23
23
  }, t);
24
24
  return () => {
25
- clearTimeout(h);
25
+ clearTimeout(m);
26
26
  };
27
27
  }, [i, t]);
28
- const r = g[m];
28
+ const r = g[h];
29
29
  if (l)
30
- return /* @__PURE__ */ o("div", { className: `animate-slide-in flex min-w-75 items-center gap-4 rounded px-4 py-2 shadow-lg ${r.bg}`, children: [
31
- /* @__PURE__ */ e("div", { className: "shrink-0", children: r.icon }),
32
- /* @__PURE__ */ o("div", { className: "flex grow flex-col text-sm text-white", children: [
33
- /* @__PURE__ */ e("p", { className: "font-bold", children: n }),
34
- /* @__PURE__ */ e("p", { children: s })
35
- ] }),
36
- /* @__PURE__ */ e("button", { onClick: i, className: "cursor-pointer", children: /* @__PURE__ */ e(d, { fill: "white", className: "h-4 w-4" }) })
37
- ] });
30
+ return /* @__PURE__ */ o(
31
+ "div",
32
+ {
33
+ className: `animate-slide-in fixed top-5 right-5 z-9999 flex min-w-75 items-center gap-4 rounded px-4 py-2 shadow-lg ${r.bg}`,
34
+ children: [
35
+ /* @__PURE__ */ e("div", { className: "shrink-0", children: r.icon }),
36
+ /* @__PURE__ */ o("div", { className: "flex grow flex-col text-sm text-white", children: [
37
+ /* @__PURE__ */ e("p", { className: "font-bold", children: n }),
38
+ /* @__PURE__ */ e("p", { children: s })
39
+ ] }),
40
+ /* @__PURE__ */ e("button", { onClick: i, className: "cursor-pointer", children: /* @__PURE__ */ e(d, { fill: "white", className: "h-4 w-4" }) })
41
+ ]
42
+ }
43
+ );
38
44
  };
39
45
  export {
40
46
  N as Toast
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@npm_leadtech/legal-contracts-ui",
3
- "version": "0.93.4",
3
+ "version": "0.93.6",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -9,10 +9,6 @@
9
9
  "license": "ISC",
10
10
  "homepage": "https://bitbucket.org/grupoblidoo/legal-contracts-ui#readme",
11
11
  "exports": {
12
- ".": {
13
- "import": "./dist/index.js",
14
- "types": "./dist/index.d.ts"
15
- },
16
12
  "./globals.css": "./dist/globals.css",
17
13
  "./components/Badge": {
18
14
  "import": "./dist/components/Badge.js",
@@ -633,14 +629,6 @@
633
629
  "./components/UnsubscribeTemplate": {
634
630
  "import": "./dist/components/UnsubscribeTemplate.js",
635
631
  "types": "./dist/components/UnsubscribeTemplate.d.ts"
636
- },
637
- "./hooks/useScroll": {
638
- "import": "./dist/hooks/useScroll.js",
639
- "types": "./dist/hooks/useScroll.d.ts"
640
- },
641
- "./hooks/useToast": {
642
- "import": "./dist/hooks/useToast.js",
643
- "types": "./dist/hooks/useToast.d.ts"
644
632
  }
645
633
  },
646
634
  "files": [