@bikdotai/bik-component-library 0.0.513-beta.0 → 0.0.513-beta.1

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,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  export declare const Menus: ({
2
3
  displayName: string;
3
4
  key: number;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../_virtual/_tslib.js"),s=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_back.svg.js"),i=require("../../assets/icons/plus.svg.js"),a=require("../../assets/icons/triangle_error.svg.js"),r=require("react"),l=require("../../constants/Theme.js"),n=require("../accordion/Accordion.js"),o=require("../icon-button/IconButton.js"),c=require("../input/Input.js"),d=require("../list-item/ListItem.js"),h=require("../switch/Switch.js"),u=require("../tooltips/Tooltip.js"),j=require("../TypographyStyle.js"),b=require("./context.js"),g=require("./NoResult.js"),p=require("./recommendVaribles.js"),x=require("./searchVariables.js"),y=require("./styles.js"),m=require("./SubHeaderItems.js");exports.VariablePickerContent=O=>{const{data:v,onSelect:S,showHeader:f,showBackButton:C,onBackButtonClick:R}=O,[w,k]=r.useState(v),[q,B]=r.useState(""),[V,I]=r.useState([]),[L,N]=r.useState(""),[T,_]=r.useState(!1),[P,H]=r.useState([]);r.useEffect((()=>{V.length>0?H([V[V.length-1]]):H(v)}),[V]);const A=e=>{let s=104;return V.length>0&&(s+=54),`calc(${e}px - ${s}px)`};return s.jsx(b.VariablePickerContext.Provider,Object.assign({value:{variables:w,searchText:q,subHeaderStack:V,showRecommended:T,setSubHeaderStack:I,setSearchText:B,setVariables:k,setShowRecommended:_}},{children:s.jsxs("div",Object.assign({tabIndex:-1,id:"variable-picker-v3",style:{backgroundColor:"white",borderRadius:4},onClick:e=>e.stopPropagation()},{children:[(f||C)&&s.jsxs(y.HeaderWrapper,{children:[C&&s.jsx(o.IconButton,{Icon:()=>s.jsx(t.default,{width:16,height:16,style:{display:"flex",color:l.COLORS.content.primary}}),onClick:R}),f&&s.jsx(j.TitleRegular,{children:"Select Variable"})]}),s.jsx("div",Object.assign({style:{padding:"0 16px",paddingTop:12,backgroundColor:l.COLORS.surface.subdued}},{children:s.jsx(c.Input,{id:"search-bar-v3-picker",onBlur:e=>{O.onSearchBlur&&O.onSearchBlur(e)},value:q,noKeyDownChange:!0,placeholder:"Search",onChangeText:e=>{e||N("");const s=x.searchVariables(e,P,V);if(T){const e=p.showOnlyRecommendedVariables(s,V);k(e)}else k(s);B(e);const t=V.length>0?V[V.length-1].displayName:"home";N(t)}})})),s.jsxs(y.RecommendWrapper,{children:[s.jsx(j.BodySecondary,Object.assign({style:{color:l.COLORS.content.secondary}},{children:"Only Recommended"})),s.jsx(h.Switch,{value:T,onValueChange:s=>e.__awaiter(void 0,void 0,void 0,(function*(){yield(s=>e.__awaiter(void 0,void 0,void 0,(function*(){if(_(s),s){const e=p.showOnlyRecommendedVariables(w,V);k(e)}else if(V.length>0){const e=L==V[V.length-1].displayName;if(q.length>0&&e){const e=x.searchVariables(q,P,V);k(e)}else k([V[V.length-1].variables])}else if(q.length>0){const e=x.searchVariables(q,P,V);k(e)}else k(v)})))(s)}))})]}),V.length>0&&s.jsxs(y.BackHeader,{children:[s.jsx("div",Object.assign({style:{position:"absolute",left:16}},{children:s.jsx(o.IconButton,{id:"back-btn-v3",style:{display:"flex"},Icon:()=>s.jsx(t.default,{width:12,height:12,style:{color:l.COLORS.content.secondary}}),onClick:e=>{e.stopPropagation();let s=q;const t=[...V],i=t.pop();if(I(t),i.displayName===L&&(B(""),s=""),s.length>0){const e=t.length>0?[t[t.length-1]]:v,i=x.searchVariables(s,e,t);if(T){const e=p.showOnlyRecommendedVariables(i,t);k(e)}else k(i)}else if(t.length>0)if(T){const e=p.showOnlyRecommendedVariables([t[t.length-1].variables],t);k(e)}else k([t[t.length-1].variables]);else if(T){const e=p.showOnlyRecommendedVariables(v,V);k(e)}else k(v)}})})),s.jsx(j.BodyCaption,Object.assign({style:{color:l.COLORS.content.secondary}},{children:V[V.length-1].displayName}))]}),s.jsx(s.Fragment,{children:w.length>0?s.jsx(y.Container,Object.assign({height:A(500)},{children:w.map(((e,t)=>e.displayName&&void 0!==e.variables?s.jsx("div",Object.assign({style:{borderBottom:`1px solid ${l.COLORS.stroke.primary}`}},{children:s.jsx(n.BikAccordion,Object.assign({headerPadding:"12px 16px",header:s.jsx(j.TitleSmall,Object.assign({style:{color:l.COLORS.content.secondary}},{children:e.displayName}))},{children:s.jsx(m.default,{variable:e.variables,onSelect:S})}))}),t):e.displayName?s.jsx(d.ListItem,{version:"2.0",leadingIcon:s.jsx(i.default,{width:14,height:14}),customListItemLabel:s.jsxs("div",Object.assign({style:{display:"flex",alignItems:"center",gap:4}},{children:[s.jsx(j.BodySecondary,Object.assign({style:{fontSize:"14px",color:l.COLORS.text.primary}},{children:e.displayName})),!e.isAvailable&&s.jsx(u.Tooltip,Object.assign({body:"Not Recommended"},{children:s.jsx("div",Object.assign({style:{display:"flex"}},{children:s.jsx(a.default,{width:16,height:16,color:l.COLORS.content.secondary})}))}))]})),listItem:{label:e.displayName,value:e.displayName},subText:e.description||"",onClick:()=>{S(e)}},t):s.jsx(m.default,{variable:e,onSelect:S},t)))})):s.jsx(g.default,{height:A(500),searchText:q})})]}))}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../_virtual/_tslib.js"),s=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_back.svg.js"),i=require("../../assets/icons/plus.svg.js"),a=require("../../assets/icons/triangle_error.svg.js"),r=require("react"),l=require("../../constants/Theme.js"),n=require("../accordion/Accordion.js"),o=require("../icon-button/IconButton.js"),c=require("../input/Input.js"),d=require("../list-item/ListItem.js"),h=require("../switch/Switch.js"),u=require("../tooltips/Tooltip.js"),j=require("../TypographyStyle.js"),b=require("./context.js"),g=require("./NoResult.js"),p=require("./recommendVaribles.js"),x=require("./searchVariables.js"),y=require("./styles.js"),m=require("./SubHeaderItems.js");exports.VariablePickerContent=O=>{const{data:v,onSelect:S,showHeader:f,showBackButton:C,onBackButtonClick:R}=O,[w,k]=r.useState(v),[q,B]=r.useState(""),[V,I]=r.useState([]),[L,N]=r.useState(""),[T,_]=r.useState(!1),[P,H]=r.useState([]);r.useEffect((()=>{A(!0)}),[]),r.useEffect((()=>{V.length>0?H([V[V.length-1]]):H(v)}),[V]);const A=s=>e.__awaiter(void 0,void 0,void 0,(function*(){if(_(s),s){const e=p.showOnlyRecommendedVariables(w,V);k(e)}else if(V.length>0){const e=L==V[V.length-1].displayName;if(q.length>0&&e){const e=x.searchVariables(q,P,V);k(e)}else k([V[V.length-1].variables])}else if(q.length>0){const e=x.searchVariables(q,P,V);k(e)}else k(v)})),$=e=>{let s=104;return V.length>0&&(s+=54),`calc(${e}px - ${s}px)`};return s.jsx(b.VariablePickerContext.Provider,Object.assign({value:{variables:w,searchText:q,subHeaderStack:V,showRecommended:T,setSubHeaderStack:I,setSearchText:B,setVariables:k,setShowRecommended:_}},{children:s.jsxs("div",Object.assign({tabIndex:-1,id:"variable-picker-v3",style:{backgroundColor:"white",borderRadius:4},onClick:e=>e.stopPropagation()},{children:[(f||C)&&s.jsxs(y.HeaderWrapper,{children:[C&&s.jsx(o.IconButton,{Icon:()=>s.jsx(t.default,{width:16,height:16,style:{display:"flex",color:l.COLORS.content.primary}}),onClick:R}),f&&s.jsx(j.TitleRegular,{children:"Select Variable"})]}),s.jsx("div",Object.assign({style:{padding:"0 16px",paddingTop:12,backgroundColor:l.COLORS.surface.subdued}},{children:s.jsx(c.Input,{id:"search-bar-v3-picker",onBlur:e=>{O.onSearchBlur&&O.onSearchBlur(e)},value:q,noKeyDownChange:!0,placeholder:"Search",onChangeText:e=>{e||N("");const s=x.searchVariables(e,P,V);if(T){const e=p.showOnlyRecommendedVariables(s,V);k(e)}else k(s);B(e);const t=V.length>0?V[V.length-1].displayName:"home";N(t)}})})),s.jsxs(y.RecommendWrapper,{children:[s.jsx(j.BodySecondary,Object.assign({style:{color:l.COLORS.content.secondary}},{children:"Only Recommended"})),s.jsx(h.Switch,{value:T,onValueChange:s=>e.__awaiter(void 0,void 0,void 0,(function*(){yield A(s)}))})]}),V.length>0&&s.jsxs(y.BackHeader,{children:[s.jsx("div",Object.assign({style:{position:"absolute",left:16}},{children:s.jsx(o.IconButton,{id:"back-btn-v3",style:{display:"flex"},Icon:()=>s.jsx(t.default,{width:12,height:12,style:{color:l.COLORS.content.secondary}}),onClick:e=>{e.stopPropagation();let s=q;const t=[...V],i=t.pop();if(I(t),i.displayName===L&&(B(""),s=""),s.length>0){const e=t.length>0?[t[t.length-1]]:v,i=x.searchVariables(s,e,t);if(T){const e=p.showOnlyRecommendedVariables(i,t);k(e)}else k(i)}else if(t.length>0)if(T){const e=p.showOnlyRecommendedVariables([t[t.length-1].variables],t);k(e)}else k([t[t.length-1].variables]);else if(T){const e=p.showOnlyRecommendedVariables(v,V);k(e)}else k(v)}})})),s.jsx(j.BodyCaption,Object.assign({style:{color:l.COLORS.content.secondary}},{children:V[V.length-1].displayName}))]}),s.jsx(s.Fragment,{children:w.length>0?s.jsx(y.Container,Object.assign({height:$(500)},{children:w.map(((e,t)=>e.displayName&&void 0!==e.variables?s.jsx("div",Object.assign({style:{borderBottom:`1px solid ${l.COLORS.stroke.primary}`}},{children:s.jsx(n.BikAccordion,Object.assign({headerPadding:"12px 16px",header:s.jsx(j.TitleSmall,Object.assign({style:{color:l.COLORS.content.secondary}},{children:e.displayName}))},{children:s.jsx(m.default,{variable:e.variables,onSelect:S})}))}),t):e.displayName?s.jsx(d.ListItem,{version:"2.0",leadingIcon:s.jsx(i.default,{width:14,height:14}),customListItemLabel:s.jsxs("div",Object.assign({style:{display:"flex",alignItems:"center",gap:4}},{children:[s.jsx(j.BodySecondary,Object.assign({style:{fontSize:"14px",color:l.COLORS.text.primary}},{children:e.displayName})),!e.isAvailable&&s.jsx(u.Tooltip,Object.assign({body:"Not Recommended"},{children:s.jsx("div",Object.assign({style:{display:"flex"}},{children:s.jsx(a.default,{width:16,height:16,color:l.COLORS.content.secondary})}))}))]})),listItem:{label:e.displayName,value:e.displayName},subText:e.description||"",onClick:()=>{S(e)}},t):s.jsx(m.default,{variable:e,onSelect:S},t)))})):s.jsx(g.default,{height:$(500),searchText:q})})]}))}))};
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=e=>Object.keys(e).reduce(((s,a)=>(e[a]&&e[a].isAvailable&&(s[a]=e[a]),s)),{});exports.showOnlyRecommendedVariables=(s,a)=>s.map((s=>{if(s.isAvailable&&void 0===s.variables)return s;if(void 0===s.isAvailable&&void 0!==s.variables){const a=e(s.variables);return Object.assign(Object.assign({},s),{variables:a})}if(void 0===s.variables){return e(s)}{const i=e(s.variables);return a.length?i:Object.assign(Object.assign({},s),{variables:i})}})).filter((e=>Object.keys(e).length>0));
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=e=>Object.keys(e).reduce(((s,a)=>(e[a]&&e[a].isAvailable&&(s[a]=e[a]),s)),{});exports.showOnlyRecommendedVariables=(s,a)=>s.map((s=>{if(s.isAvailable&&void 0===s.variables)return s;if(void 0===s.isAvailable&&void 0!==s.variables){const a=e(s.variables);return 0===Object.keys(a).length?{}:Object.assign(Object.assign({},s),{variables:a})}if(void 0===s.variables){return e(s)}{const i=e(s.variables);return a.length?i:Object.assign(Object.assign({},s),{variables:i})}})).filter((e=>Object.keys(e).length>0));
@@ -1,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  export declare const Menus: ({
2
3
  displayName: string;
3
4
  key: number;
@@ -1 +1 @@
1
- import{__awaiter as e}from"../../_virtual/_tslib.js";import{jsx as t,jsxs as o,Fragment as s}from"react/jsx-runtime";import i from"../../assets/icons/arrow_back.svg.js";import n from"../../assets/icons/plus.svg.js";import r from"../../assets/icons/triangle_error.svg.js";import{useState as l,useEffect as a}from"react";import{COLORS as c}from"../../constants/Theme.js";import{BikAccordion as d}from"../accordion/Accordion.js";import{IconButton as h}from"../icon-button/IconButton.js";import{Input as m}from"../input/Input.js";import{ListItem as p}from"../list-item/ListItem.js";import{Switch as g}from"../switch/Switch.js";import{Tooltip as b}from"../tooltips/Tooltip.js";import{TitleRegular as y,BodySecondary as f,BodyCaption as v,TitleSmall as u}from"../TypographyStyle.js";import{VariablePickerContext as j}from"./context.js";import x from"./NoResult.js";import{showOnlyRecommendedVariables as k}from"./recommendVaribles.js";import{searchVariables as S}from"./searchVariables.js";import{HeaderWrapper as O,RecommendWrapper as w,BackHeader as N,Container as I}from"./styles.js";import C from"./SubHeaderItems.js";const B=B=>{const{data:T,onSelect:R,showHeader:V,showBackButton:H,onBackButtonClick:P}=B,[_,L]=l(T),[$,A]=l(""),[z,D]=l([]),[K,q]=l(""),[E,F]=l(!1),[G,J]=l([]);a((()=>{z.length>0?J([z[z.length-1]]):J(T)}),[z]);const M=e=>{let t=104;return z.length>0&&(t+=54),`calc(${e}px - ${t}px)`};return t(j.Provider,Object.assign({value:{variables:_,searchText:$,subHeaderStack:z,showRecommended:E,setSubHeaderStack:D,setSearchText:A,setVariables:L,setShowRecommended:F}},{children:o("div",Object.assign({tabIndex:-1,id:"variable-picker-v3",style:{backgroundColor:"white",borderRadius:4},onClick:e=>e.stopPropagation()},{children:[(V||H)&&o(O,{children:[H&&t(h,{Icon:()=>t(i,{width:16,height:16,style:{display:"flex",color:c.content.primary}}),onClick:P}),V&&t(y,{children:"Select Variable"})]}),t("div",Object.assign({style:{padding:"0 16px",paddingTop:12,backgroundColor:c.surface.subdued}},{children:t(m,{id:"search-bar-v3-picker",onBlur:e=>{B.onSearchBlur&&B.onSearchBlur(e)},value:$,noKeyDownChange:!0,placeholder:"Search",onChangeText:e=>{e||q("");const t=S(e,G,z);if(E){const e=k(t,z);L(e)}else L(t);A(e);const o=z.length>0?z[z.length-1].displayName:"home";q(o)}})})),o(w,{children:[t(f,Object.assign({style:{color:c.content.secondary}},{children:"Only Recommended"})),t(g,{value:E,onValueChange:t=>e(void 0,void 0,void 0,(function*(){yield(t=>e(void 0,void 0,void 0,(function*(){if(F(t),t){const e=k(_,z);L(e)}else if(z.length>0){const e=K==z[z.length-1].displayName;if($.length>0&&e){const e=S($,G,z);L(e)}else L([z[z.length-1].variables])}else if($.length>0){const e=S($,G,z);L(e)}else L(T)})))(t)}))})]}),z.length>0&&o(N,{children:[t("div",Object.assign({style:{position:"absolute",left:16}},{children:t(h,{id:"back-btn-v3",style:{display:"flex"},Icon:()=>t(i,{width:12,height:12,style:{color:c.content.secondary}}),onClick:e=>{e.stopPropagation();let t=$;const o=[...z],s=o.pop();if(D(o),s.displayName===K&&(A(""),t=""),t.length>0){const e=o.length>0?[o[o.length-1]]:T,s=S(t,e,o);if(E){const e=k(s,o);L(e)}else L(s)}else if(o.length>0)if(E){const e=k([o[o.length-1].variables],o);L(e)}else L([o[o.length-1].variables]);else if(E){const e=k(T,z);L(e)}else L(T)}})})),t(v,Object.assign({style:{color:c.content.secondary}},{children:z[z.length-1].displayName}))]}),t(s,{children:_.length>0?t(I,Object.assign({height:M(500)},{children:_.map(((e,s)=>e.displayName&&void 0!==e.variables?t("div",Object.assign({style:{borderBottom:`1px solid ${c.stroke.primary}`}},{children:t(d,Object.assign({headerPadding:"12px 16px",header:t(u,Object.assign({style:{color:c.content.secondary}},{children:e.displayName}))},{children:t(C,{variable:e.variables,onSelect:R})}))}),s):e.displayName?t(p,{version:"2.0",leadingIcon:t(n,{width:14,height:14}),customListItemLabel:o("div",Object.assign({style:{display:"flex",alignItems:"center",gap:4}},{children:[t(f,Object.assign({style:{fontSize:"14px",color:c.text.primary}},{children:e.displayName})),!e.isAvailable&&t(b,Object.assign({body:"Not Recommended"},{children:t("div",Object.assign({style:{display:"flex"}},{children:t(r,{width:16,height:16,color:c.content.secondary})}))}))]})),listItem:{label:e.displayName,value:e.displayName},subText:e.description||"",onClick:()=>{R(e)}},s):t(C,{variable:e,onSelect:R},s)))})):t(x,{height:M(500),searchText:$})})]}))}))};export{B as VariablePickerContent};
1
+ import{__awaiter as e}from"../../_virtual/_tslib.js";import{jsx as t,jsxs as o,Fragment as s}from"react/jsx-runtime";import i from"../../assets/icons/arrow_back.svg.js";import n from"../../assets/icons/plus.svg.js";import r from"../../assets/icons/triangle_error.svg.js";import{useState as l,useEffect as a}from"react";import{COLORS as c}from"../../constants/Theme.js";import{BikAccordion as d}from"../accordion/Accordion.js";import{IconButton as h}from"../icon-button/IconButton.js";import{Input as m}from"../input/Input.js";import{ListItem as p}from"../list-item/ListItem.js";import{Switch as g}from"../switch/Switch.js";import{Tooltip as b}from"../tooltips/Tooltip.js";import{TitleRegular as y,BodySecondary as f,BodyCaption as v,TitleSmall as u}from"../TypographyStyle.js";import{VariablePickerContext as j}from"./context.js";import x from"./NoResult.js";import{showOnlyRecommendedVariables as k}from"./recommendVaribles.js";import{searchVariables as S}from"./searchVariables.js";import{HeaderWrapper as O,RecommendWrapper as w,BackHeader as N,Container as I}from"./styles.js";import C from"./SubHeaderItems.js";const B=B=>{const{data:T,onSelect:R,showHeader:V,showBackButton:H,onBackButtonClick:P}=B,[_,L]=l(T),[$,A]=l(""),[z,D]=l([]),[K,q]=l(""),[E,F]=l(!1),[G,J]=l([]);a((()=>{M(!0)}),[]),a((()=>{z.length>0?J([z[z.length-1]]):J(T)}),[z]);const M=t=>e(void 0,void 0,void 0,(function*(){if(F(t),t){const e=k(_,z);L(e)}else if(z.length>0){const e=K==z[z.length-1].displayName;if($.length>0&&e){const e=S($,G,z);L(e)}else L([z[z.length-1].variables])}else if($.length>0){const e=S($,G,z);L(e)}else L(T)})),Q=e=>{let t=104;return z.length>0&&(t+=54),`calc(${e}px - ${t}px)`};return t(j.Provider,Object.assign({value:{variables:_,searchText:$,subHeaderStack:z,showRecommended:E,setSubHeaderStack:D,setSearchText:A,setVariables:L,setShowRecommended:F}},{children:o("div",Object.assign({tabIndex:-1,id:"variable-picker-v3",style:{backgroundColor:"white",borderRadius:4},onClick:e=>e.stopPropagation()},{children:[(V||H)&&o(O,{children:[H&&t(h,{Icon:()=>t(i,{width:16,height:16,style:{display:"flex",color:c.content.primary}}),onClick:P}),V&&t(y,{children:"Select Variable"})]}),t("div",Object.assign({style:{padding:"0 16px",paddingTop:12,backgroundColor:c.surface.subdued}},{children:t(m,{id:"search-bar-v3-picker",onBlur:e=>{B.onSearchBlur&&B.onSearchBlur(e)},value:$,noKeyDownChange:!0,placeholder:"Search",onChangeText:e=>{e||q("");const t=S(e,G,z);if(E){const e=k(t,z);L(e)}else L(t);A(e);const o=z.length>0?z[z.length-1].displayName:"home";q(o)}})})),o(w,{children:[t(f,Object.assign({style:{color:c.content.secondary}},{children:"Only Recommended"})),t(g,{value:E,onValueChange:t=>e(void 0,void 0,void 0,(function*(){yield M(t)}))})]}),z.length>0&&o(N,{children:[t("div",Object.assign({style:{position:"absolute",left:16}},{children:t(h,{id:"back-btn-v3",style:{display:"flex"},Icon:()=>t(i,{width:12,height:12,style:{color:c.content.secondary}}),onClick:e=>{e.stopPropagation();let t=$;const o=[...z],s=o.pop();if(D(o),s.displayName===K&&(A(""),t=""),t.length>0){const e=o.length>0?[o[o.length-1]]:T,s=S(t,e,o);if(E){const e=k(s,o);L(e)}else L(s)}else if(o.length>0)if(E){const e=k([o[o.length-1].variables],o);L(e)}else L([o[o.length-1].variables]);else if(E){const e=k(T,z);L(e)}else L(T)}})})),t(v,Object.assign({style:{color:c.content.secondary}},{children:z[z.length-1].displayName}))]}),t(s,{children:_.length>0?t(I,Object.assign({height:Q(500)},{children:_.map(((e,s)=>e.displayName&&void 0!==e.variables?t("div",Object.assign({style:{borderBottom:`1px solid ${c.stroke.primary}`}},{children:t(d,Object.assign({headerPadding:"12px 16px",header:t(u,Object.assign({style:{color:c.content.secondary}},{children:e.displayName}))},{children:t(C,{variable:e.variables,onSelect:R})}))}),s):e.displayName?t(p,{version:"2.0",leadingIcon:t(n,{width:14,height:14}),customListItemLabel:o("div",Object.assign({style:{display:"flex",alignItems:"center",gap:4}},{children:[t(f,Object.assign({style:{fontSize:"14px",color:c.text.primary}},{children:e.displayName})),!e.isAvailable&&t(b,Object.assign({body:"Not Recommended"},{children:t("div",Object.assign({style:{display:"flex"}},{children:t(r,{width:16,height:16,color:c.content.secondary})}))}))]})),listItem:{label:e.displayName,value:e.displayName},subText:e.description||"",onClick:()=>{R(e)}},s):t(C,{variable:e,onSelect:R},s)))})):t(x,{height:Q(500),searchText:$})})]}))}))};export{B as VariablePickerContent};
@@ -1 +1 @@
1
- const e=(e,i)=>e.map((e=>{if(e.isAvailable&&void 0===e.variables)return e;if(void 0===e.isAvailable&&void 0!==e.variables){const i=a(e.variables);return Object.assign(Object.assign({},e),{variables:i})}if(void 0===e.variables){return a(e)}{const s=a(e.variables);return i.length?s:Object.assign(Object.assign({},e),{variables:s})}})).filter((e=>Object.keys(e).length>0)),a=e=>Object.keys(e).reduce(((a,i)=>(e[i]&&e[i].isAvailable&&(a[i]=e[i]),a)),{});export{e as showOnlyRecommendedVariables};
1
+ const e=(e,i)=>e.map((e=>{if(e.isAvailable&&void 0===e.variables)return e;if(void 0===e.isAvailable&&void 0!==e.variables){const i=a(e.variables);return 0===Object.keys(i).length?{}:Object.assign(Object.assign({},e),{variables:i})}if(void 0===e.variables){return a(e)}{const s=a(e.variables);return i.length?s:Object.assign(Object.assign({},e),{variables:s})}})).filter((e=>Object.keys(e).length>0)),a=e=>Object.keys(e).reduce(((a,i)=>(e[i]&&e[i].isAvailable&&(a[i]=e[i]),a)),{});export{e as showOnlyRecommendedVariables};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bikdotai/bik-component-library",
3
- "version": "0.0.513-beta.0",
3
+ "version": "0.0.513-beta.1",
4
4
  "description": "Bik Component Library",
5
5
  "repository": {
6
6
  "type": "git",