@brightlocal/ui-components 2.0.1 → 2.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.
@@ -28,7 +28,7 @@ type ResizablePanelProps = React.ComponentProps<typeof ResizablePrimitive.Panel>
28
28
  /**
29
29
  * Individual resizable panel within a panel group.
30
30
  */
31
- declare const ResizablePanel: React.ForwardRefExoticComponent<Omit<Omit<React.HTMLAttributes<HTMLElement | HTMLDivElement | HTMLObjectElement | HTMLSlotElement | HTMLStyleElement | HTMLLinkElement | HTMLMapElement | HTMLButtonElement | HTMLDialogElement | HTMLFormElement | HTMLImageElement | HTMLOptionElement | HTMLTableElement | HTMLTimeElement | HTMLVideoElement | HTMLAnchorElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLHeadingElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLInputElement | HTMLLabelElement | HTMLLegendElement | HTMLLIElement | HTMLMetaElement | HTMLMeterElement | HTMLOListElement | HTMLOptGroupElement | HTMLOutputElement | HTMLParagraphElement | HTMLPreElement | HTMLProgressElement | HTMLScriptElement | HTMLSelectElement | HTMLSourceElement | HTMLSpanElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTextAreaElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLUListElement | HTMLTableCaptionElement | HTMLMenuElement | HTMLPictureElement>, "id" | "onResize"> & {
31
+ declare const ResizablePanel: React.ForwardRefExoticComponent<Omit<Omit<React.HTMLAttributes<HTMLElement | HTMLDivElement | HTMLObjectElement | HTMLSlotElement | HTMLStyleElement | HTMLLinkElement | HTMLMapElement | HTMLButtonElement | HTMLDialogElement | HTMLFormElement | HTMLImageElement | HTMLOptionElement | HTMLTableElement | HTMLTimeElement | HTMLVideoElement | HTMLAnchorElement | HTMLAreaElement | HTMLAudioElement | HTMLBaseElement | HTMLQuoteElement | HTMLBodyElement | HTMLBRElement | HTMLCanvasElement | HTMLTableColElement | HTMLDataElement | HTMLDataListElement | HTMLModElement | HTMLDetailsElement | HTMLDListElement | HTMLEmbedElement | HTMLFieldSetElement | HTMLHeadingElement | HTMLHeadElement | HTMLHRElement | HTMLHtmlElement | HTMLIFrameElement | HTMLInputElement | HTMLLabelElement | HTMLLegendElement | HTMLLIElement | HTMLMetaElement | HTMLMeterElement | HTMLOListElement | HTMLOptGroupElement | HTMLOutputElement | HTMLParagraphElement | HTMLPreElement | HTMLProgressElement | HTMLScriptElement | HTMLSelectElement | HTMLSourceElement | HTMLSpanElement | HTMLTemplateElement | HTMLTableSectionElement | HTMLTableCellElement | HTMLTextAreaElement | HTMLTitleElement | HTMLTableRowElement | HTMLTrackElement | HTMLUListElement | HTMLMenuElement | HTMLTableCaptionElement | HTMLPictureElement>, "id" | "onResize"> & {
32
32
  className?: string;
33
33
  collapsedSize?: number | undefined;
34
34
  collapsible?: boolean | undefined;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react/jsx-runtime"),N=require("react"),c=require("@brightlocal/ui-components/lib/utils");function R(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const l=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(a,e,l.get?l:{enumerable:!0,get:()=>t[e]})}}return a.default=t,Object.freeze(a)}const n=R(N),x=n.createContext(!1),j=n.forwardRef(({className:t,dataHook:a,trackingEl:e,trackingLabel:l,left:r,right:u,children:L,...C},S)=>{const d=[],f=[],p=[],m=o=>{if(n.isValidElement(o)){if(o.type===n.Fragment){n.Children.forEach(o.props.children,m);return}o.type===y?d.push(o):o.type===i?p.push(o):f.push(o)}};n.Children.forEach(L,m);const b=r!=null||u!=null,v=f.length>0||p.length>0,g=b&&!v,w=d.length>0;return s.jsxs("div",{ref:S,className:c.cn("flex min-h-screen w-full flex-col lg:flex-row",t),"data-hook":a,"data-slot":"split-layout","data-tracking-el":e||"split-layout","data-tracking-label":l,...C,children:[s.jsx("div",{className:"bg-background flex flex-1 flex-col","data-slot":"split-layout-body",children:s.jsxs(x.Provider,{value:w,children:[d,g?r&&s.jsx(h,{children:r}):f]})}),g?u&&s.jsx(i,{children:u}):p]})});j.displayName="SplitLayout";const y=n.forwardRef(({className:t,children:a,...e},l)=>s.jsx("div",{ref:l,className:c.cn("px-section-sm pt-section-sm flex w-full items-center justify-center lg:justify-start",t),"data-slot":"split-layout-header",...e,children:a}));y.displayName="SplitLayoutHeader";const h=n.forwardRef(({className:t,children:a,...e},l)=>{const r=n.useContext(x);return s.jsx("div",{ref:l,className:c.cn("p-section-sm flex flex-1 items-center justify-center overflow-auto",r&&"pt-2",t),"data-slot":"split-layout-left",...e,children:a})});h.displayName="SplitLayoutContentLeft";const i=n.forwardRef(({className:t,children:a,...e},l)=>s.jsx("div",{ref:l,className:c.cn("bg-card p-section-sm hidden flex-1 items-center justify-center overflow-auto lg:flex",t),"data-slot":"split-layout-right",...e,children:a}));i.displayName="SplitLayoutContentRight";exports.SplitLayout=j;exports.SplitLayoutContentLeft=h;exports.SplitLayoutContentRight=i;exports.SplitLayoutHeader=y;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("react/jsx-runtime"),R=require("react"),c=require("@brightlocal/ui-components/lib/utils");function k(t){const a=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const l=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(a,e,l.get?l:{enumerable:!0,get:()=>t[e]})}}return a.default=t,Object.freeze(a)}const o=k(R),j=o.createContext(!1),C=o.forwardRef(({className:t,dataHook:a,trackingEl:e,trackingLabel:l,left:s,right:i,children:d,...f},p)=>{const y=[],m=[],g=[],L=r=>{if(o.isValidElement(r)){if(r.type===o.Fragment){o.Children.forEach(r.props.children,L);return}r.type===h?y.push(r):r.type===u?g.push(r):m.push(r)}};o.Children.forEach(d,L);const v=s!=null||i!=null,w=m.length>0||g.length>0,S=v&&!w,N=y.length>0;return n.jsxs("div",{ref:p,className:c.cn("flex min-h-screen w-full flex-col lg:flex-row",t),"data-hook":a,"data-slot":"split-layout","data-tracking-el":e||"split-layout","data-tracking-label":l,...f,children:[n.jsx("div",{className:"bg-background flex flex-1 flex-col","data-slot":"split-layout-body",children:n.jsxs(j.Provider,{value:N,children:[y,S?s&&n.jsx(x,{children:s}):m]})}),S?i&&n.jsx(u,{children:i}):g]})});C.displayName="SplitLayout";const h=o.forwardRef(({className:t,children:a,...e},l)=>n.jsx("div",{ref:l,className:c.cn("px-section-sm pt-section-sm flex w-full items-center justify-center lg:justify-start",t),"data-slot":"split-layout-header",...e,children:a}));h.displayName="SplitLayoutHeader";const x=o.forwardRef(({className:t,children:a,...e},l)=>{const s=o.useContext(j);return n.jsx("div",{ref:l,className:c.cn("p-section-sm flex flex-1 items-center justify-center overflow-auto",s&&"pt-2",t),"data-slot":"split-layout-left",...e,children:a})});x.displayName="SplitLayoutContentLeft";const u=o.forwardRef(({className:t,flush:a=!1,children:e,...l},s)=>n.jsx("div",{ref:s,className:c.cn("bg-card hidden",a?"relative h-screen overflow-hidden lg:block lg:w-1/2 lg:shrink-0":"p-section-sm flex-1 items-center justify-center overflow-auto lg:flex",t),"data-slot":"split-layout-right",...l,children:e}));u.displayName="SplitLayoutContentRight";const b=o.forwardRef(({className:t,dataHook:a,src:e,alt:l,objectFit:s="cover",objectPosition:i="center",style:d,...f},p)=>n.jsx("img",{ref:p,alt:l,className:c.cn("absolute inset-0 h-full w-full",t),"data-hook":a,"data-slot":"split-layout-image",src:e,style:{objectFit:s,objectPosition:i,...d},...f}));b.displayName="SplitLayoutImage";exports.SplitLayout=C;exports.SplitLayoutContentLeft=x;exports.SplitLayoutContentRight=u;exports.SplitLayoutHeader=h;exports.SplitLayoutImage=b;
@@ -84,13 +84,64 @@ interface SplitLayoutContentLeftProps extends React.ComponentProps<"div"> {
84
84
  declare const SplitLayoutContentLeft: React.ForwardRefExoticComponent<Omit<SplitLayoutContentLeftProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
85
85
  interface SplitLayoutContentRightProps extends React.ComponentProps<"div"> {
86
86
  children: React.ReactNode;
87
+ /**
88
+ * Removes padding so content can fill edge-to-edge.
89
+ * Use with `SplitLayoutImage` for full-bleed imagery.
90
+ * @default false
91
+ */
92
+ flush?: boolean;
87
93
  }
88
94
  /**
89
95
  * SplitLayoutContentRight - Right/secondary section within a SplitLayout.
90
96
  *
91
97
  * Hidden on mobile/tablet (<1024px), visible on desktop (≥1024px).
92
98
  * Uses bg-card background color.
99
+ *
100
+ * Set `flush` to remove padding for full-bleed content (e.g. images).
93
101
  */
94
102
  declare const SplitLayoutContentRight: React.ForwardRefExoticComponent<Omit<SplitLayoutContentRightProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
95
- export { SplitLayout, SplitLayoutHeader, SplitLayoutContentLeft, SplitLayoutContentRight, type SplitLayoutProps, type SplitLayoutHeaderProps, type SplitLayoutContentLeftProps, type SplitLayoutContentRightProps, };
103
+ interface SplitLayoutImageProps extends React.ComponentProps<"img"> {
104
+ /**
105
+ * Data hook for automated testing (REQUIRED)
106
+ */
107
+ dataHook: string;
108
+ /**
109
+ * Image source URL
110
+ */
111
+ src: string;
112
+ /**
113
+ * Alt text for the image
114
+ */
115
+ alt: string;
116
+ /**
117
+ * How the image fits its container.
118
+ * @default "cover"
119
+ */
120
+ objectFit?: "cover" | "contain";
121
+ /**
122
+ * CSS object-position value controlling the focal point of the image.
123
+ * @default "center"
124
+ * @example "top", "center", "left 30%"
125
+ */
126
+ objectPosition?: string;
127
+ }
128
+ /**
129
+ * SplitLayoutImage — Full-bleed image for the right section of a SplitLayout.
130
+ *
131
+ * Fills the entire right panel with no margins. Uses `object-cover` by default
132
+ * so the image scales and crops naturally as the viewport resizes.
133
+ *
134
+ * Must be used inside `<SplitLayoutContentRight flush>`.
135
+ *
136
+ * @example
137
+ * <SplitLayoutContentRight flush>
138
+ * <SplitLayoutImage
139
+ * dataHook="signup-hero"
140
+ * src="/images/signup-step-1.png"
141
+ * alt="Welcome illustration"
142
+ * />
143
+ * </SplitLayoutContentRight>
144
+ */
145
+ declare const SplitLayoutImage: React.ForwardRefExoticComponent<Omit<SplitLayoutImageProps, "ref"> & React.RefAttributes<HTMLImageElement>>;
146
+ export { SplitLayout, SplitLayoutHeader, SplitLayoutContentLeft, SplitLayoutContentRight, SplitLayoutImage, type SplitLayoutProps, type SplitLayoutHeaderProps, type SplitLayoutContentLeftProps, type SplitLayoutContentRightProps, type SplitLayoutImageProps, };
96
147
  //# sourceMappingURL=split-layout.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"split-layout.d.ts","sourceRoot":"","sources":["../../src/components/split-layout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAa/B,UAAU,gBAAiB,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IAC5D,iDAAiD;IACjD,QAAQ,EAAE,MAAM,CAAC;IACjB,gDAAgD;IAChD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,2CAA2C;IAC3C,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;OAGG;IACH,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB;;;OAGG;IACH,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACzB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH,QAAA,MAAM,WAAW,sGA6EhB,CAAC;AAQF,UAAU,sBAAuB,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IAClE;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;GAIG;AACH,QAAA,MAAM,iBAAiB,4GAiBrB,CAAC;AAQH,UAAU,2BAA4B,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IACvE,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;;GAKG;AACH,QAAA,MAAM,sBAAsB,iHAoB1B,CAAC;AAQH,UAAU,4BAA6B,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IACxE,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;;GAKG;AACH,QAAA,MAAM,uBAAuB,kHAiB3B,CAAC;AAQH,OAAO,EACL,WAAW,EACX,iBAAiB,EACjB,sBAAsB,EACtB,uBAAuB,EACvB,KAAK,gBAAgB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,GAClC,CAAC"}
1
+ {"version":3,"file":"split-layout.d.ts","sourceRoot":"","sources":["../../src/components/split-layout.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAa/B,UAAU,gBAAiB,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IAC5D,iDAAiD;IACjD,QAAQ,EAAE,MAAM,CAAC;IACjB,gDAAgD;IAChD,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,2CAA2C;IAC3C,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;OAGG;IACH,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB;;;OAGG;IACH,KAAK,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACzB;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH,QAAA,MAAM,WAAW,sGA6EhB,CAAC;AAQF,UAAU,sBAAuB,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IAClE;;OAEG;IACH,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;GAIG;AACH,QAAA,MAAM,iBAAiB,4GAiBrB,CAAC;AAQH,UAAU,2BAA4B,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IACvE,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED;;;;;GAKG;AACH,QAAA,MAAM,sBAAsB,iHAoB1B,CAAC;AAQH,UAAU,4BAA6B,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IACxE,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B;;;;OAIG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;;;;;;;GAOG;AACH,QAAA,MAAM,uBAAuB,kHAoB3B,CAAC;AAQH,UAAU,qBAAsB,SAAQ,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC;IACjE;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,GAAG,EAAE,MAAM,CAAC;IACZ;;OAEG;IACH,GAAG,EAAE,MAAM,CAAC;IACZ;;;OAGG;IACH,SAAS,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAChC;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,QAAA,MAAM,gBAAgB,6GA8BrB,CAAC;AAQF,OAAO,EACL,WAAW,EACX,iBAAiB,EACjB,sBAAsB,EACtB,uBAAuB,EACvB,gBAAgB,EAChB,KAAK,gBAAgB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,qBAAqB,GAC3B,CAAC"}
@@ -1,112 +1,139 @@
1
- import { jsxs as h, jsx as n } from "react/jsx-runtime";
1
+ import { jsxs as C, jsx as n } from "react/jsx-runtime";
2
2
  import * as t from "react";
3
- import { cn as i } from "@brightlocal/ui-components/lib/utils";
4
- const x = t.createContext(!1), j = t.forwardRef(
3
+ import { cn as c } from "@brightlocal/ui-components/lib/utils";
4
+ const L = t.createContext(!1), b = t.forwardRef(
5
5
  ({
6
- className: a,
6
+ className: e,
7
7
  dataHook: l,
8
- trackingEl: o,
9
- trackingLabel: s,
10
- left: r,
11
- right: c,
12
- children: L,
13
- ...v
14
- }, w) => {
15
- const d = [], f = [], p = [], y = (e) => {
16
- if (t.isValidElement(e)) {
17
- if (e.type === t.Fragment) {
8
+ trackingEl: a,
9
+ trackingLabel: o,
10
+ left: s,
11
+ right: i,
12
+ children: d,
13
+ ...f
14
+ }, u) => {
15
+ const p = [], y = [], m = [], g = (r) => {
16
+ if (t.isValidElement(r)) {
17
+ if (r.type === t.Fragment) {
18
18
  t.Children.forEach(
19
- e.props.children,
20
- y
19
+ r.props.children,
20
+ g
21
21
  );
22
22
  return;
23
23
  }
24
- e.type === g ? d.push(e) : e.type === u ? p.push(e) : f.push(e);
24
+ r.type === w ? p.push(r) : r.type === h ? m.push(r) : y.push(r);
25
25
  }
26
26
  };
27
- t.Children.forEach(L, y);
28
- const N = r != null || c != null, S = f.length > 0 || p.length > 0, m = N && !S, R = d.length > 0;
29
- return /* @__PURE__ */ h(
27
+ t.Children.forEach(d, g);
28
+ const N = s != null || i != null, S = y.length > 0 || m.length > 0, x = N && !S, R = p.length > 0;
29
+ return /* @__PURE__ */ C(
30
30
  "div",
31
31
  {
32
- ref: w,
33
- className: i(
32
+ ref: u,
33
+ className: c(
34
34
  "flex min-h-screen w-full flex-col lg:flex-row",
35
- a
35
+ e
36
36
  ),
37
37
  "data-hook": l,
38
38
  "data-slot": "split-layout",
39
- "data-tracking-el": o || "split-layout",
40
- "data-tracking-label": s,
41
- ...v,
39
+ "data-tracking-el": a || "split-layout",
40
+ "data-tracking-label": o,
41
+ ...f,
42
42
  children: [
43
43
  /* @__PURE__ */ n(
44
44
  "div",
45
45
  {
46
46
  className: "bg-background flex flex-1 flex-col",
47
47
  "data-slot": "split-layout-body",
48
- children: /* @__PURE__ */ h(x.Provider, { value: R, children: [
49
- d,
50
- m ? r && /* @__PURE__ */ n(C, { children: r }) : f
48
+ children: /* @__PURE__ */ C(L.Provider, { value: R, children: [
49
+ p,
50
+ x ? s && /* @__PURE__ */ n(v, { children: s }) : y
51
51
  ] })
52
52
  }
53
53
  ),
54
- m ? c && /* @__PURE__ */ n(u, { children: c }) : p
54
+ x ? i && /* @__PURE__ */ n(h, { children: i }) : m
55
55
  ]
56
56
  }
57
57
  );
58
58
  }
59
59
  );
60
- j.displayName = "SplitLayout";
61
- const g = t.forwardRef(({ className: a, children: l, ...o }, s) => /* @__PURE__ */ n(
60
+ b.displayName = "SplitLayout";
61
+ const w = t.forwardRef(({ className: e, children: l, ...a }, o) => /* @__PURE__ */ n(
62
62
  "div",
63
63
  {
64
- ref: s,
65
- className: i(
64
+ ref: o,
65
+ className: c(
66
66
  "px-section-sm pt-section-sm flex w-full items-center justify-center lg:justify-start",
67
- a
67
+ e
68
68
  ),
69
69
  "data-slot": "split-layout-header",
70
- ...o,
70
+ ...a,
71
71
  children: l
72
72
  }
73
73
  ));
74
- g.displayName = "SplitLayoutHeader";
75
- const C = t.forwardRef(({ className: a, children: l, ...o }, s) => {
76
- const r = t.useContext(x);
74
+ w.displayName = "SplitLayoutHeader";
75
+ const v = t.forwardRef(({ className: e, children: l, ...a }, o) => {
76
+ const s = t.useContext(L);
77
77
  return /* @__PURE__ */ n(
78
78
  "div",
79
79
  {
80
- ref: s,
81
- className: i(
80
+ ref: o,
81
+ className: c(
82
82
  "p-section-sm flex flex-1 items-center justify-center overflow-auto",
83
- r && "pt-2",
84
- a
83
+ s && "pt-2",
84
+ e
85
85
  ),
86
86
  "data-slot": "split-layout-left",
87
- ...o,
87
+ ...a,
88
88
  children: l
89
89
  }
90
90
  );
91
91
  });
92
- C.displayName = "SplitLayoutContentLeft";
93
- const u = t.forwardRef(({ className: a, children: l, ...o }, s) => /* @__PURE__ */ n(
92
+ v.displayName = "SplitLayoutContentLeft";
93
+ const h = t.forwardRef(({ className: e, flush: l = !1, children: a, ...o }, s) => /* @__PURE__ */ n(
94
94
  "div",
95
95
  {
96
96
  ref: s,
97
- className: i(
98
- "bg-card p-section-sm hidden flex-1 items-center justify-center overflow-auto lg:flex",
99
- a
97
+ className: c(
98
+ "bg-card hidden",
99
+ l ? "relative h-screen overflow-hidden lg:block lg:w-1/2 lg:shrink-0" : "p-section-sm flex-1 items-center justify-center overflow-auto lg:flex",
100
+ e
100
101
  ),
101
102
  "data-slot": "split-layout-right",
102
103
  ...o,
103
- children: l
104
+ children: a
104
105
  }
105
106
  ));
106
- u.displayName = "SplitLayoutContentRight";
107
+ h.displayName = "SplitLayoutContentRight";
108
+ const k = t.forwardRef(
109
+ ({
110
+ className: e,
111
+ dataHook: l,
112
+ src: a,
113
+ alt: o,
114
+ objectFit: s = "cover",
115
+ objectPosition: i = "center",
116
+ style: d,
117
+ ...f
118
+ }, u) => /* @__PURE__ */ n(
119
+ "img",
120
+ {
121
+ ref: u,
122
+ alt: o,
123
+ className: c("absolute inset-0 h-full w-full", e),
124
+ "data-hook": l,
125
+ "data-slot": "split-layout-image",
126
+ src: a,
127
+ style: { objectFit: s, objectPosition: i, ...d },
128
+ ...f
129
+ }
130
+ )
131
+ );
132
+ k.displayName = "SplitLayoutImage";
107
133
  export {
108
- j as SplitLayout,
109
- C as SplitLayoutContentLeft,
110
- u as SplitLayoutContentRight,
111
- g as SplitLayoutHeader
134
+ b as SplitLayout,
135
+ v as SplitLayoutContentLeft,
136
+ h as SplitLayoutContentRight,
137
+ w as SplitLayoutHeader,
138
+ k as SplitLayoutImage
112
139
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brightlocal/ui-components",
3
- "version": "2.0.1",
3
+ "version": "2.1.0",
4
4
  "description": "BrightLocal Design System UI Components",
5
5
  "type": "module",
6
6
  "private": false,