@bikdotai/bik-component-library 0.0.679-5 → 0.0.679-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 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),n=require("../../../zeroState/ZeroState.js"),r=require("../../../../hooks/useOutside.js"),s=require("../../hooks/useDropdown.js"),o=require("./description/Description.js"),i=require("./menu/FreeFormMenu.js"),l=require("./menu/MenuList.js"),u=require("./menu/SelectAllMenu.js"),a=require("./multiSelect/MultiSelectDropdownBottomBar.js"),c=require("./OpennedDropdown.styled.js"),d=require("./searchbox/SearchBox.js"),p=require("./searchbox/SearchZeroState.js");const h=304,S=290;exports.OpenedDropdown=f=>{let{options:j,isSearchable:x,isMultiSelect:g,width:b,allowFreeForm:v,height:w,onClose:O,onSelect:m,onSearch:y,version:C,skipSorting:D,headerRef:M,hideSelectAll:q,primaryButtonText:L,onInfiniteScroll:F,onMultiSelectClear:k,onDropdownItemClick:A,buttonOptions:B,isSearchLoading:I,disableSearchOptions:H,disableSearchedOptionExcept:R,useDefaultCursor:T,containerStyle:Z={},zeroState:z}=f;const{dropdownOptions:E,search:P,searchedString:_,searchedOptions:K,onApplyHandler:N,selectAllHandler:W,onMultiSelectClear:G,onFreeFormSelect:J,onMultiSelectApply:Q,latestDropdownOptionsRef:U,getSelectedOptions:V}=s.useDropdown(C,j,m,D,g,y,H,R),[X,Y]=t.useState(null!=b?b:S),[$,ee]=t.useState(null),te=t.useRef(null),ne=t.useRef([]);r.useOutside(te,(()=>{if(ee(null),g&&"2.0"===C){const e=V(U.current);null==O||O(e)}else null==O||O(E)}),[M,ne]);const re=null!=w?w:h,se="number"==typeof re?x&&g?re-96:x&&!g||!x&&g?re-48:re:re;t.useEffect((()=>{const e=null!=b?b:S;if(null===$)Y(e);else if("number"==typeof e)Y(2*e);else if("string"==typeof e&&e.endsWith("px")){const t=2*parseInt(e.replace("px",""));Y(t)}}),[$]);const oe=[],ie=(_&&y?K:E).map((e=>{var t,n;if(_&&!y){if(e.options){const t=Object.assign({},e);return t.options=t.options.filter((e=>{var t;return!!(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(_.toLowerCase()))&&(oe.push(!_||e.label===_),!0)})),t.options.length>0?t:null}return(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(_.toLowerCase()))||(null===(n=e.searchKey)||void 0===n?void 0:n.toLowerCase().includes(_.toLowerCase()))?(oe.push(!_||e.label===_),e):null}return e})).filter((e=>null!==e)),le=!!x&&_&&0===ie.length;return e.jsxs(c.OpennedDropdownContainer,Object.assign({version:C,ref:te,style:Object.assign({width:X},Z)},{children:[e.jsxs("div",Object.assign({style:{width:$?"50%":"100%",display:"flex",flexDirection:"column",background:"white"}},{children:[!!x&&e.jsx(d.SearchBox,{onSearch:P,version:C}),ie.length||_?e.jsxs(c.MenuListContainer,Object.assign({minHeight:re,maxHeight:se},{children:[!!g&&!le&&!q&&e.jsx(u.SelectAllMenu,{version:C,options:_&&y?K:E,onSelect:W}),!v&&le&&e.jsx(p.SearchZeroState,{isLoading:I,height:se,searchedString:_}),v&&(le||!!oe.length&&oe.every((e=>!1===e)))&&e.jsx(i.FreeFormMenu,{version:C,isMultiSelect:g,onSelect:J,searchedString:_}),e.jsx(l.MenuList,{onInfiniteScroll:F,onDropdownItemClick:A,version:C,onSelect:N,showDescription:function(e,t){ee(e&&t?{title:e,description:t}:null)},isMultiSelect:g,options:ie,useDefaultCursor:T,ref:ne})]})):e.jsx("div",Object.assign({style:{height:re,display:"flex"}},{children:e.jsx(n.ZeroState,Object.assign({},z,{title:(null==z?void 0:z.title)||"No results found",subTitle:(null==z?void 0:z.subTitle)||"Please try again later or contact us at support@bik.ai if you require further assistance."}))})),!!g&&!(!ie.length&&!_)&&"2.0"!==C&&e.jsx(a.default,{onClear:()=>{G(),null==k||k()},onApply:Q,list:_&&y?K:E,buttonText:L,buttonOptions:B})]})),!!$&&e.jsx(o.Description,{title:$.title,description:$.description,version:C})]}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),n=require("../../../zeroState/ZeroState.js"),r=require("../../../../hooks/useOutside.js"),o=require("../../hooks/useDropdown.js"),s=require("./description/Description.js"),i=require("./menu/FreeFormMenu.js"),l=require("./menu/MenuList.js"),u=require("./menu/SelectAllMenu.js"),a=require("./multiSelect/MultiSelectDropdownBottomBar.js"),c=require("./OpennedDropdown.styled.js"),d=require("./searchbox/SearchBox.js"),p=require("./searchbox/SearchZeroState.js");const h=304,S=290;exports.OpenedDropdown=f=>{let{options:j,isSearchable:x,isMultiSelect:g,width:b,allowFreeForm:v,height:w,onClose:O,onSelect:m,onSearch:y,version:C,skipSorting:D,headerRef:M,hideSelectAll:q,primaryButtonText:L,onInfiniteScroll:F,onMultiSelectClear:k,onDropdownItemClick:A,buttonOptions:B,isSearchLoading:I,disableSearchOptions:H,disableSearchedOptionExcept:R,useDefaultCursor:T,containerStyle:Z={},zeroState:z}=f;const{dropdownOptions:E,search:P,searchedString:W,searchedOptions:_,onApplyHandler:K,selectAllHandler:N,onMultiSelectClear:G,onFreeFormSelect:J,onMultiSelectApply:Q,latestDropdownOptionsRef:U,getSelectedOptions:V}=o.useDropdown(C,j,m,D,g,y,H,R),[X,Y]=t.useState(null!=b?b:S),[$,ee]=t.useState(null),te=t.useRef(null),ne=t.useRef([]);r.useOutside(te,(()=>{if(ee(null),g&&"2.0"===C){const e=V(U.current);null==O||O(e)}else null==O||O(E)}),[M,ne]);const re=null!=w?w:h,oe="number"==typeof re?x&&g?re-96:x&&!g||!x&&g?re-48:re:re;t.useEffect((()=>{const e=null!=b?b:S;if(null===$)Y(e);else if("number"==typeof e)Y(2*e);else if("string"==typeof e&&e.endsWith("px")){const t=2*parseInt(e.replace("px",""));Y(t)}}),[$]);const se=[],ie=(W&&y?_:E).map((e=>{var t,n;if(W&&!y){if(e.options){const t=Object.assign({},e);return t.options=t.options.filter((e=>{var t;return!!(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(W.toLowerCase()))&&(se.push(!W||e.label===W),!0)})),t.options.length>0?t:null}return(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(W.toLowerCase()))||(null===(n=e.searchKey)||void 0===n?void 0:n.toLowerCase().includes(W.toLowerCase()))?(se.push(!W||e.label===W),e):null}return e})).filter((e=>null!==e)),le=!!x&&W&&0===ie.length;return e.jsxs(c.OpennedDropdownContainer,Object.assign({version:C,ref:te,style:Object.assign({width:X},Z)},{children:[e.jsxs("div",Object.assign({style:{width:$?"50%":"100%",display:"flex",flexDirection:"column",background:"white"}},{children:[!!x&&e.jsx(d.SearchBox,{onSearch:P,version:C}),ie.length||W?e.jsxs(c.MenuListContainer,Object.assign({minHeight:re,maxHeight:oe},{children:[!!g&&!le&&!q&&e.jsx(u.SelectAllMenu,{version:C,options:W&&y?_:E,onSelect:N}),!v&&le&&e.jsx(p.SearchZeroState,{isLoading:I,height:oe,searchedString:W,containerWidth:b}),v&&(le||!!se.length&&se.every((e=>!1===e)))&&e.jsx(i.FreeFormMenu,{version:C,isMultiSelect:g,onSelect:J,searchedString:W}),e.jsx(l.MenuList,{onInfiniteScroll:F,onDropdownItemClick:A,version:C,onSelect:K,showDescription:function(e,t){ee(e&&t?{title:e,description:t}:null)},isMultiSelect:g,options:ie,useDefaultCursor:T,ref:ne})]})):e.jsx("div",Object.assign({style:{height:re,display:"flex"}},{children:e.jsx(n.ZeroState,Object.assign({},z,{title:(null==z?void 0:z.title)||"No results found",subTitle:(null==z?void 0:z.subTitle)||"Please try again later or contact us at support@bik.ai if you require further assistance."}))})),!!g&&!(!ie.length&&!W)&&"2.0"!==C&&e.jsx(a.default,{onClear:()=>{G(),null==k||k()},onApply:Q,list:W&&y?_:E,buttonText:L,buttonOptions:B})]})),!!$&&e.jsx(s.Description,{title:$.title,description:$.description,version:C})]}))};
@@ -3,4 +3,5 @@ export declare const SearchZeroState: React.FC<{
3
3
  searchedString: string;
4
4
  height: number;
5
5
  isLoading?: boolean;
6
+ containerWidth?: string;
6
7
  }>;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../../../zeroState/ZeroState.js");exports.SearchZeroState=r=>{let{searchedString:s,height:i,isLoading:o}=r;return e.jsx("div",Object.assign({style:{height:i,display:"flex",alignItems:"center"}},{children:e.jsx(t.ZeroState,{isLoading:o,title:"No results found",subTitle:`Sorry we could not find any results for "${null!=s?s:""}"`})}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../../../zeroState/ZeroState.js");exports.SearchZeroState=r=>{let{searchedString:i,height:s,isLoading:n,containerWidth:o}=r;return e.jsx("div",Object.assign({style:{height:s,display:"flex",alignItems:"center"}},{children:e.jsx(t.ZeroState,{isLoading:n,title:"No results found",subTitle:`Sorry we could not find any results for "${null!=i?i:""}"`,containerWidth:o})}))};
@@ -9,4 +9,5 @@ export declare const ZeroState: React.FC<{
9
9
  actionButton?: ButtonProps;
10
10
  buttonWidth?: number;
11
11
  Icon?: React.ReactNode;
12
+ containerWidth?: string;
12
13
  }>;
@@ -14,4 +14,4 @@
14
14
  align-items: center;
15
15
  justify-content: center;
16
16
  border-radius: 24px;
17
- `;exports.ZeroState=n=>{var{subTitle:a,title:c,IconHolderStyle:j,style:g,isLoading:y}=n,x=e.__rest(n,["subTitle","title","IconHolderStyle","style","isLoading"]);return t.jsxs(d,Object.assign({style:null!=g?g:{}},{children:[y?t.jsx(i.Spinner,{size:"large",color:s.COLORS.stroke.brand}):t.jsx(u,Object.assign({style:null!=j?j:{}},{children:(null==x?void 0:x.Icon)||t.jsx(l.default,{color:s.COLORS.content.placeholder,height:24,width:24})})),t.jsx(r.TitleRegular,Object.assign({style:{marginTop:8,color:s.COLORS.content.primary}},{children:y?"Loading...":c||"No results found"})),!!a&&!y&&t.jsx(r.BodyCaption,Object.assign({style:{marginTop:4,color:s.COLORS.content.secondary,textAlign:"center",maxWidth:184}},{children:a})),!!(null==x?void 0:x.actionButton)&&t.jsx("div",Object.assign({style:(null==x?void 0:x.buttonWidth)?{width:null==x?void 0:x.buttonWidth,display:"flex"}:{}},{children:t.jsx(o.Button,Object.assign({},null==x?void 0:x.actionButton))}))]}))};
17
+ `;exports.ZeroState=n=>{var{subTitle:a,title:c,IconHolderStyle:j,style:g,isLoading:y,containerWidth:p}=n,x=e.__rest(n,["subTitle","title","IconHolderStyle","style","isLoading","containerWidth"]);let b=r.TitleRegular;const h=p?parseFloat(p):0;return h&&!isNaN(h)&&h<=150&&(b=r.TitleSmall),t.jsxs(d,Object.assign({style:null!=g?g:{}},{children:[y?t.jsx(i.Spinner,{size:"large",color:s.COLORS.stroke.brand}):t.jsx(u,Object.assign({style:null!=j?j:{}},{children:(null==x?void 0:x.Icon)||t.jsx(l.default,{color:s.COLORS.content.placeholder,height:24,width:24})})),t.jsx(b,Object.assign({style:{marginTop:8,color:s.COLORS.content.primary}},{children:y?"Loading...":c||"No results found"})),!!a&&!y&&t.jsx(r.BodyCaption,Object.assign({style:{marginTop:4,color:s.COLORS.content.secondary,textAlign:"center",maxWidth:184}},{children:a})),!!(null==x?void 0:x.actionButton)&&t.jsx("div",Object.assign({style:(null==x?void 0:x.buttonWidth)?{width:null==x?void 0:x.buttonWidth,display:"flex"}:{}},{children:t.jsx(o.Button,Object.assign({},null==x?void 0:x.actionButton))}))]}))};
@@ -1 +1 @@
1
- import{jsxs as e,jsx as t}from"react/jsx-runtime";import{useState as o,useRef as n,useEffect as i}from"react";import{ZeroState as l}from"../../../zeroState/ZeroState.js";import{useOutside as r}from"../../../../hooks/useOutside.js";import{useDropdown as s}from"../../hooks/useDropdown.js";import{Description as c}from"./description/Description.js";import{FreeFormMenu as a}from"./menu/FreeFormMenu.js";import{MenuList as u}from"./menu/MenuList.js";import{SelectAllMenu as p}from"./menu/SelectAllMenu.js";import d from"./multiSelect/MultiSelectDropdownBottomBar.js";import{OpennedDropdownContainer as h,MenuListContainer as m}from"./OpennedDropdown.styled.js";import{SearchBox as f}from"./searchbox/SearchBox.js";import{SearchZeroState as S}from"./searchbox/SearchZeroState.js";const g=304,b=290,v=v=>{let{options:j,isSearchable:w,isMultiSelect:y,width:O,allowFreeForm:x,height:C,onClose:D,onSelect:M,onSearch:L,version:k,skipSorting:A,headerRef:F,hideSelectAll:I,primaryButtonText:B,onInfiniteScroll:H,onMultiSelectClear:T,onDropdownItemClick:z,buttonOptions:R,isSearchLoading:Z,disableSearchOptions:q,disableSearchedOptionExcept:E,useDefaultCursor:K,containerStyle:N={},zeroState:P}=v;const{dropdownOptions:W,search:G,searchedString:J,searchedOptions:Q,onApplyHandler:U,selectAllHandler:V,onMultiSelectClear:X,onFreeFormSelect:Y,onMultiSelectApply:$,latestDropdownOptionsRef:_,getSelectedOptions:ee}=s(k,j,M,A,y,L,q,E),[te,oe]=o(null!=O?O:b),[ne,ie]=o(null),le=n(null),re=n([]);r(le,(()=>{if(ie(null),y&&"2.0"===k){const e=ee(_.current);null==D||D(e)}else null==D||D(W)}),[F,re]);const se=null!=C?C:g,ce="number"==typeof se?w&&y?se-96:w&&!y||!w&&y?se-48:se:se;i((()=>{const e=null!=O?O:b;if(null===ne)oe(e);else if("number"==typeof e)oe(2*e);else if("string"==typeof e&&e.endsWith("px")){const t=2*parseInt(e.replace("px",""));oe(t)}}),[ne]);const ae=[],ue=(J&&L?Q:W).map((e=>{var t,o;if(J&&!L){if(e.options){const t=Object.assign({},e);return t.options=t.options.filter((e=>{var t;return!!(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(J.toLowerCase()))&&(ae.push(!J||e.label===J),!0)})),t.options.length>0?t:null}return(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(J.toLowerCase()))||(null===(o=e.searchKey)||void 0===o?void 0:o.toLowerCase().includes(J.toLowerCase()))?(ae.push(!J||e.label===J),e):null}return e})).filter((e=>null!==e)),pe=!!w&&J&&0===ue.length;return e(h,Object.assign({version:k,ref:le,style:Object.assign({width:te},N)},{children:[e("div",Object.assign({style:{width:ne?"50%":"100%",display:"flex",flexDirection:"column",background:"white"}},{children:[!!w&&t(f,{onSearch:G,version:k}),ue.length||J?e(m,Object.assign({minHeight:se,maxHeight:ce},{children:[!!y&&!pe&&!I&&t(p,{version:k,options:J&&L?Q:W,onSelect:V}),!x&&pe&&t(S,{isLoading:Z,height:ce,searchedString:J}),x&&(pe||!!ae.length&&ae.every((e=>!1===e)))&&t(a,{version:k,isMultiSelect:y,onSelect:Y,searchedString:J}),t(u,{onInfiniteScroll:H,onDropdownItemClick:z,version:k,onSelect:U,showDescription:function(e,t){ie(e&&t?{title:e,description:t}:null)},isMultiSelect:y,options:ue,useDefaultCursor:K,ref:re})]})):t("div",Object.assign({style:{height:se,display:"flex"}},{children:t(l,Object.assign({},P,{title:(null==P?void 0:P.title)||"No results found",subTitle:(null==P?void 0:P.subTitle)||"Please try again later or contact us at support@bik.ai if you require further assistance."}))})),!!y&&!(!ue.length&&!J)&&"2.0"!==k&&t(d,{onClear:()=>{X(),null==T||T()},onApply:$,list:J&&L?Q:W,buttonText:B,buttonOptions:R})]})),!!ne&&t(c,{title:ne.title,description:ne.description,version:k})]}))};export{v as OpenedDropdown};
1
+ import{jsxs as e,jsx as t}from"react/jsx-runtime";import{useState as o,useRef as n,useEffect as i}from"react";import{ZeroState as r}from"../../../zeroState/ZeroState.js";import{useOutside as l}from"../../../../hooks/useOutside.js";import{useDropdown as s}from"../../hooks/useDropdown.js";import{Description as c}from"./description/Description.js";import{FreeFormMenu as a}from"./menu/FreeFormMenu.js";import{MenuList as u}from"./menu/MenuList.js";import{SelectAllMenu as p}from"./menu/SelectAllMenu.js";import d from"./multiSelect/MultiSelectDropdownBottomBar.js";import{OpennedDropdownContainer as h,MenuListContainer as m}from"./OpennedDropdown.styled.js";import{SearchBox as f}from"./searchbox/SearchBox.js";import{SearchZeroState as S}from"./searchbox/SearchZeroState.js";const g=304,b=290,v=v=>{let{options:j,isSearchable:w,isMultiSelect:y,width:O,allowFreeForm:x,height:C,onClose:D,onSelect:M,onSearch:L,version:k,skipSorting:A,headerRef:F,hideSelectAll:I,primaryButtonText:B,onInfiniteScroll:H,onMultiSelectClear:T,onDropdownItemClick:z,buttonOptions:R,isSearchLoading:W,disableSearchOptions:Z,disableSearchedOptionExcept:q,useDefaultCursor:E,containerStyle:K={},zeroState:N}=v;const{dropdownOptions:P,search:G,searchedString:J,searchedOptions:Q,onApplyHandler:U,selectAllHandler:V,onMultiSelectClear:X,onFreeFormSelect:Y,onMultiSelectApply:$,latestDropdownOptionsRef:_,getSelectedOptions:ee}=s(k,j,M,A,y,L,Z,q),[te,oe]=o(null!=O?O:b),[ne,ie]=o(null),re=n(null),le=n([]);l(re,(()=>{if(ie(null),y&&"2.0"===k){const e=ee(_.current);null==D||D(e)}else null==D||D(P)}),[F,le]);const se=null!=C?C:g,ce="number"==typeof se?w&&y?se-96:w&&!y||!w&&y?se-48:se:se;i((()=>{const e=null!=O?O:b;if(null===ne)oe(e);else if("number"==typeof e)oe(2*e);else if("string"==typeof e&&e.endsWith("px")){const t=2*parseInt(e.replace("px",""));oe(t)}}),[ne]);const ae=[],ue=(J&&L?Q:P).map((e=>{var t,o;if(J&&!L){if(e.options){const t=Object.assign({},e);return t.options=t.options.filter((e=>{var t;return!!(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(J.toLowerCase()))&&(ae.push(!J||e.label===J),!0)})),t.options.length>0?t:null}return(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(J.toLowerCase()))||(null===(o=e.searchKey)||void 0===o?void 0:o.toLowerCase().includes(J.toLowerCase()))?(ae.push(!J||e.label===J),e):null}return e})).filter((e=>null!==e)),pe=!!w&&J&&0===ue.length;return e(h,Object.assign({version:k,ref:re,style:Object.assign({width:te},K)},{children:[e("div",Object.assign({style:{width:ne?"50%":"100%",display:"flex",flexDirection:"column",background:"white"}},{children:[!!w&&t(f,{onSearch:G,version:k}),ue.length||J?e(m,Object.assign({minHeight:se,maxHeight:ce},{children:[!!y&&!pe&&!I&&t(p,{version:k,options:J&&L?Q:P,onSelect:V}),!x&&pe&&t(S,{isLoading:W,height:ce,searchedString:J,containerWidth:O}),x&&(pe||!!ae.length&&ae.every((e=>!1===e)))&&t(a,{version:k,isMultiSelect:y,onSelect:Y,searchedString:J}),t(u,{onInfiniteScroll:H,onDropdownItemClick:z,version:k,onSelect:U,showDescription:function(e,t){ie(e&&t?{title:e,description:t}:null)},isMultiSelect:y,options:ue,useDefaultCursor:E,ref:le})]})):t("div",Object.assign({style:{height:se,display:"flex"}},{children:t(r,Object.assign({},N,{title:(null==N?void 0:N.title)||"No results found",subTitle:(null==N?void 0:N.subTitle)||"Please try again later or contact us at support@bik.ai if you require further assistance."}))})),!!y&&!(!ue.length&&!J)&&"2.0"!==k&&t(d,{onClear:()=>{X(),null==T||T()},onApply:$,list:J&&L?Q:P,buttonText:B,buttonOptions:R})]})),!!ne&&t(c,{title:ne.title,description:ne.description,version:k})]}))};export{v as OpenedDropdown};
@@ -3,4 +3,5 @@ export declare const SearchZeroState: React.FC<{
3
3
  searchedString: string;
4
4
  height: number;
5
5
  isLoading?: boolean;
6
+ containerWidth?: string;
6
7
  }>;
@@ -1 +1 @@
1
- import{jsx as e}from"react/jsx-runtime";import{ZeroState as t}from"../../../../zeroState/ZeroState.js";const r=r=>{let{searchedString:i,height:o,isLoading:s}=r;return e("div",Object.assign({style:{height:o,display:"flex",alignItems:"center"}},{children:e(t,{isLoading:s,title:"No results found",subTitle:`Sorry we could not find any results for "${null!=i?i:""}"`})}))};export{r as SearchZeroState};
1
+ import{jsx as t}from"react/jsx-runtime";import{ZeroState as e}from"../../../../zeroState/ZeroState.js";const i=i=>{let{searchedString:r,height:n,isLoading:o,containerWidth:s}=i;return t("div",Object.assign({style:{height:n,display:"flex",alignItems:"center"}},{children:t(e,{isLoading:o,title:"No results found",subTitle:`Sorry we could not find any results for "${null!=r?r:""}"`,containerWidth:s})}))};export{i as SearchZeroState};
@@ -9,4 +9,5 @@ export declare const ZeroState: React.FC<{
9
9
  actionButton?: ButtonProps;
10
10
  buttonWidth?: number;
11
11
  Icon?: React.ReactNode;
12
+ containerWidth?: string;
12
13
  }>;
@@ -1,12 +1,12 @@
1
- import{__rest as t}from"../../_virtual/_tslib.js";import{jsxs as e,jsx as n}from"react/jsx-runtime";import o from"styled-components";import{Spinner as i}from"../spinner/Spinner.js";import{TitleRegular as r,BodyCaption as l}from"../TypographyStyle.js";import{COLORS as s}from"../../constants/Theme.js";import c from"../../assets/icons/alert.svg.js";import{Button as d}from"../button/Button.js";const a=o.div`
2
- background: ${s.surface.standard};
1
+ import{__rest as t}from"../../_virtual/_tslib.js";import{jsxs as e,jsx as n}from"react/jsx-runtime";import i from"styled-components";import{Spinner as o}from"../spinner/Spinner.js";import{BodyCaption as r,TitleRegular as l,TitleSmall as s}from"../TypographyStyle.js";import{COLORS as c}from"../../constants/Theme.js";import a from"../../assets/icons/alert.svg.js";import{Button as d}from"../button/Button.js";const u=i.div`
2
+ background: ${c.surface.standard};
3
3
  display: flex;
4
4
  flex-direction: column;
5
5
  align-items: center;
6
6
  justify-content: center;
7
7
  flex: 1;
8
- `,u=o.div`
9
- background: ${s.background.base};
8
+ `,m=i.div`
9
+ background: ${c.background.base};
10
10
  width: 48px;
11
11
  height: 48px;
12
12
  display: flex;
@@ -14,4 +14,4 @@ import{__rest as t}from"../../_virtual/_tslib.js";import{jsxs as e,jsx as n}from
14
14
  align-items: center;
15
15
  justify-content: center;
16
16
  border-radius: 24px;
17
- `,m=o=>{var{subTitle:m,title:p,IconHolderStyle:g,style:y,isLoading:b}=o,f=t(o,["subTitle","title","IconHolderStyle","style","isLoading"]);return e(a,Object.assign({style:null!=y?y:{}},{children:[b?n(i,{size:"large",color:s.stroke.brand}):n(u,Object.assign({style:null!=g?g:{}},{children:(null==f?void 0:f.Icon)||n(c,{color:s.content.placeholder,height:24,width:24})})),n(r,Object.assign({style:{marginTop:8,color:s.content.primary}},{children:b?"Loading...":p||"No results found"})),!!m&&!b&&n(l,Object.assign({style:{marginTop:4,color:s.content.secondary,textAlign:"center",maxWidth:184}},{children:m})),!!(null==f?void 0:f.actionButton)&&n("div",Object.assign({style:(null==f?void 0:f.buttonWidth)?{width:null==f?void 0:f.buttonWidth,display:"flex"}:{}},{children:n(d,Object.assign({},null==f?void 0:f.actionButton))}))]}))};export{m as ZeroState};
17
+ `,p=i=>{var{subTitle:p,title:g,IconHolderStyle:h,style:y,isLoading:b,containerWidth:f}=i,j=t(i,["subTitle","title","IconHolderStyle","style","isLoading","containerWidth"]);let x=l;const v=f?parseFloat(f):0;return v&&!isNaN(v)&&v<=150&&(x=s),e(u,Object.assign({style:null!=y?y:{}},{children:[b?n(o,{size:"large",color:c.stroke.brand}):n(m,Object.assign({style:null!=h?h:{}},{children:(null==j?void 0:j.Icon)||n(a,{color:c.content.placeholder,height:24,width:24})})),n(x,Object.assign({style:{marginTop:8,color:c.content.primary}},{children:b?"Loading...":g||"No results found"})),!!p&&!b&&n(r,Object.assign({style:{marginTop:4,color:c.content.secondary,textAlign:"center",maxWidth:184}},{children:p})),!!(null==j?void 0:j.actionButton)&&n("div",Object.assign({style:(null==j?void 0:j.buttonWidth)?{width:null==j?void 0:j.buttonWidth,display:"flex"}:{}},{children:n(d,Object.assign({},null==j?void 0:j.actionButton))}))]}))};export{p as ZeroState};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bikdotai/bik-component-library",
3
- "version": "0.0.679-5",
3
+ "version": "0.0.679-6",
4
4
  "description": "Bik Component Library",
5
5
  "repository": {
6
6
  "type": "git",