@bikdotai/bik-component-library 0.0.627-containerStyle-2 → 0.0.627

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,4 +1,4 @@
1
1
  import React from 'react';
2
- import { QueryBuilderNodeProps } from "../../../Types/QueryBuilderNodeProps.type";
2
+ import { QueryBuilderNodeProps } from "../../../types/QueryBuilderNodeProps.type";
3
3
  declare const EventsTrigger: React.FC<QueryBuilderNodeProps>;
4
4
  export default EventsTrigger;
@@ -1,2 +1,2 @@
1
- import { QueryBuilderAPIData } from "../../../Types/QueryBuilderAPI.type";
1
+ import { QueryBuilderAPIData } from "../../../types/QueryBuilderAPI.type";
2
2
  export declare const useIGTriggerNameCacheSelector: () => QueryBuilderAPIData[];
@@ -1,4 +1,4 @@
1
1
  import React from 'react';
2
- import { QueryBuilderNodeProps } from "../../../Types/QueryBuilderNodeProps.type";
2
+ import { QueryBuilderNodeProps } from "../../../types/QueryBuilderNodeProps.type";
3
3
  declare const IGTrigger: React.FC<QueryBuilderNodeProps>;
4
4
  export default IGTrigger;
@@ -1,2 +1,2 @@
1
- import { QueryBuilderAPIData } from "../../../Types/QueryBuilderAPI.type";
1
+ import { QueryBuilderAPIData } from "../../../types/QueryBuilderAPI.type";
2
2
  export declare const useIGTriggerNameCacheSelector: () => QueryBuilderAPIData[];
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import { DropdownOption } from "../../../dropdown/type";
3
- import { QueryBuilderProperty } from "../../Types/QueryBuilder.type";
4
- import { QueryBuilderNodeProps } from "../../Types/QueryBuilderNodeProps.type";
3
+ import { QueryBuilderProperty } from "../../types/QueryBuilder.type";
4
+ import { QueryBuilderNodeProps } from "../../types/QueryBuilderNodeProps.type";
5
5
  declare const BaseTriggerQueryBuilderNode: React.FC<QueryBuilderNodeProps & {
6
6
  cacheKey: string;
7
7
  propertyAddBtnText: string;
@@ -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:w,height:v,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:Z,containerStyle:T={}}=f;const{dropdownOptions:E,search:P,searchedString:_,searchedOptions:z,onApplyHandler:K,selectAllHandler:N,onMultiSelectClear:W,onFreeFormSelect:G,onMultiSelectApply:J,latestDropdownOptionsRef:Q,getSelectedOptions:U}=s.useDropdown(C,j,m,D,g,y,H,R),[V,X]=t.useState(null!=b?b:S),[Y,$]=t.useState(null),ee=t.useRef(null),te=t.useRef([]);r.useOutside(ee,(()=>{if($(null),g&&"2.0"===C){const e=U(Q.current);null==O||O(e)}else null==O||O(E)}),[M,te]);const ne=null!=v?v:h,re="number"==typeof ne?x&&g?ne-96:x&&!g||!x&&g?ne-48:ne:ne;t.useEffect((()=>{const e=null!=b?b:S;if(null===Y)X(e);else if("number"==typeof e)X(2*e);else if("string"==typeof e&&e.endsWith("px")){const t=2*parseInt(e.replace("px",""));X(t)}}),[Y]);const se=[],oe=(_&&y?z: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()))&&(se.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()))?(se.push(!_||e.label===_),e):null}return e})).filter((e=>null!==e)),ie=!!x&&_&&0===oe.length;return e.jsxs(c.OpennedDropdownContainer,Object.assign({version:C,ref:ee,style:Object.assign({width:V},T)},{children:[e.jsxs("div",Object.assign({style:{width:Y?"50%":"100%",display:"flex",flexDirection:"column",background:"white"}},{children:[!!x&&e.jsx(d.SearchBox,{onSearch:P,version:C}),oe.length||_?e.jsxs(c.MenuListContainer,Object.assign({minHeight:ne,maxHeight:re},{children:[!!g&&!ie&&!q&&e.jsx(u.SelectAllMenu,{version:C,options:_&&y?z:E,onSelect:N}),!w&&ie&&e.jsx(p.SearchZeroState,{isLoading:I,height:re,searchedString:_}),w&&(ie||!!se.length&&se.every((e=>!1===e)))&&e.jsx(i.FreeFormMenu,{version:C,isMultiSelect:g,onSelect:G,searchedString:_}),e.jsx(l.MenuList,{onInfiniteScroll:F,onDropdownItemClick:A,version:C,onSelect:K,showDescription:function(e,t){$(e&&t?{title:e,description:t}:null)},isMultiSelect:g,options:oe,useDefaultCursor:Z,ref:te})]})):e.jsx("div",Object.assign({style:{height:ne,display:"flex"}},{children:e.jsx(n.ZeroState,{title:"No results found",subTitle:"Please try again later or contact us at support@bik.ai if you require further assistance."})})),!!g&&!(!oe.length&&!_)&&"2.0"!==C&&e.jsx(a.default,{onClear:()=>{W(),null==k||k()},onApply:J,list:_&&y?z:E,buttonText:L,buttonOptions:B})]})),!!Y&&e.jsx(o.Description,{title:Y.title,description:Y.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:w,height:v,onClose:m,onSelect:O,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:Z}=f;const{dropdownOptions:T,search:E,searchedString:P,searchedOptions:_,onApplyHandler:z,selectAllHandler:K,onMultiSelectClear:N,onFreeFormSelect:W,onMultiSelectApply:G,latestDropdownOptionsRef:J,getSelectedOptions:Q}=o.useDropdown(C,j,O,D,g,y,H,R),[U,V]=t.useState(null!=b?b:S),[X,Y]=t.useState(null),$=t.useRef(null),ee=t.useRef([]);r.useOutside($,(()=>{if(Y(null),g&&"2.0"===C){const e=Q(J.current);null==m||m(e)}else null==m||m(T)}),[M,ee]);const te=null!=v?v:h,ne="number"==typeof te?x&&g?te-96:x&&!g||!x&&g?te-48:te:te;t.useEffect((()=>{const e=null!=b?b:S;if(null===X)V(e);else if("number"==typeof e)V(2*e);else if("string"==typeof e&&e.endsWith("px")){const t=2*parseInt(e.replace("px",""));V(t)}}),[X]);const re=[],oe=(P&&y?_:T).map((e=>{var t,n;if(P&&!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(P.toLowerCase()))&&(re.push(!P||e.label===P),!0)})),t.options.length>0?t:null}return(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(P.toLowerCase()))||(null===(n=e.searchKey)||void 0===n?void 0:n.toLowerCase().includes(P.toLowerCase()))?(re.push(!P||e.label===P),e):null}return e})).filter((e=>null!==e)),se=!!x&&P&&0===oe.length;return e.jsxs(c.OpennedDropdownContainer,Object.assign({version:C,ref:$,style:{width:U}},{children:[e.jsxs("div",Object.assign({style:{width:X?"50%":"100%",display:"flex",flexDirection:"column",background:"white"}},{children:[!!x&&e.jsx(d.SearchBox,{onSearch:E,version:C}),oe.length||P?e.jsxs(c.MenuListContainer,Object.assign({minHeight:te,maxHeight:ne},{children:[!!g&&!se&&!q&&e.jsx(u.SelectAllMenu,{version:C,options:P&&y?_:T,onSelect:K}),!w&&se&&e.jsx(p.SearchZeroState,{isLoading:I,height:ne,searchedString:P}),w&&(se||!!re.length&&re.every((e=>!1===e)))&&e.jsx(i.FreeFormMenu,{version:C,isMultiSelect:g,onSelect:W,searchedString:P}),e.jsx(l.MenuList,{onInfiniteScroll:F,onDropdownItemClick:A,version:C,onSelect:z,showDescription:function(e,t){Y(e&&t?{title:e,description:t}:null)},isMultiSelect:g,options:oe,useDefaultCursor:Z,ref:ee})]})):e.jsx("div",Object.assign({style:{height:te,display:"flex"}},{children:e.jsx(n.ZeroState,{title:"No results found",subTitle:"Please try again later or contact us at support@bik.ai if you require further assistance."})})),!!g&&!(!oe.length&&!P)&&"2.0"!==C&&e.jsx(a.default,{onClear:()=>{N(),null==k||k()},onApply:G,list:P&&y?_:T,buttonText:L,buttonOptions:B})]})),!!X&&e.jsx(s.Description,{title:X.title,description:X.description,version:C})]}))};
@@ -29,7 +29,6 @@ export interface OpenDropdownProps {
29
29
  disableSearchedOptionExcept?: string[];
30
30
  useDefaultCursor?: boolean;
31
31
  'data-test'?: string;
32
- containerStyle?: React.CSSProperties;
33
32
  }
34
33
  export type GroupedOption = {
35
34
  label?: string;
@@ -1,4 +1,4 @@
1
1
  import React from 'react';
2
- import { QueryBuilderNodeProps } from "../../../Types/QueryBuilderNodeProps.type";
2
+ import { QueryBuilderNodeProps } from "../../../types/QueryBuilderNodeProps.type";
3
3
  declare const EventsTrigger: React.FC<QueryBuilderNodeProps>;
4
4
  export default EventsTrigger;
@@ -1,2 +1,2 @@
1
- import { QueryBuilderAPIData } from "../../../Types/QueryBuilderAPI.type";
1
+ import { QueryBuilderAPIData } from "../../../types/QueryBuilderAPI.type";
2
2
  export declare const useIGTriggerNameCacheSelector: () => QueryBuilderAPIData[];
@@ -1,4 +1,4 @@
1
1
  import React from 'react';
2
- import { QueryBuilderNodeProps } from "../../../Types/QueryBuilderNodeProps.type";
2
+ import { QueryBuilderNodeProps } from "../../../types/QueryBuilderNodeProps.type";
3
3
  declare const IGTrigger: React.FC<QueryBuilderNodeProps>;
4
4
  export default IGTrigger;
@@ -1,2 +1,2 @@
1
- import { QueryBuilderAPIData } from "../../../Types/QueryBuilderAPI.type";
1
+ import { QueryBuilderAPIData } from "../../../types/QueryBuilderAPI.type";
2
2
  export declare const useIGTriggerNameCacheSelector: () => QueryBuilderAPIData[];
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import { DropdownOption } from "../../../dropdown/type";
3
- import { QueryBuilderProperty } from "../../Types/QueryBuilder.type";
4
- import { QueryBuilderNodeProps } from "../../Types/QueryBuilderNodeProps.type";
3
+ import { QueryBuilderProperty } from "../../types/QueryBuilder.type";
4
+ import { QueryBuilderNodeProps } from "../../types/QueryBuilderNodeProps.type";
5
5
  declare const BaseTriggerQueryBuilderNode: React.FC<QueryBuilderNodeProps & {
6
6
  cacheKey: string;
7
7
  propertyAddBtnText: string;
@@ -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 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,w=w=>{let{options:j,isSearchable:v,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:R,buttonOptions:Z,isSearchLoading:q,disableSearchOptions:z,disableSearchedOptionExcept:E,useDefaultCursor:K,containerStyle:N={}}=w;const{dropdownOptions:P,search:W,searchedString:G,searchedOptions:J,onApplyHandler:Q,selectAllHandler:U,onMultiSelectClear:V,onFreeFormSelect:X,onMultiSelectApply:Y,latestDropdownOptionsRef:$,getSelectedOptions:_}=s(k,j,M,A,y,L,z,E),[ee,te]=o(null!=O?O:b),[oe,ne]=o(null),ie=n(null),re=n([]);l(ie,(()=>{if(ne(null),y&&"2.0"===k){const e=_($.current);null==D||D(e)}else null==D||D(P)}),[F,re]);const le=null!=C?C:g,se="number"==typeof le?v&&y?le-96:v&&!y||!v&&y?le-48:le:le;i((()=>{const e=null!=O?O:b;if(null===oe)te(e);else if("number"==typeof e)te(2*e);else if("string"==typeof e&&e.endsWith("px")){const t=2*parseInt(e.replace("px",""));te(t)}}),[oe]);const ce=[],ae=(G&&L?J:P).map((e=>{var t,o;if(G&&!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(G.toLowerCase()))&&(ce.push(!G||e.label===G),!0)})),t.options.length>0?t:null}return(null===(t=e.label)||void 0===t?void 0:t.toLowerCase().includes(G.toLowerCase()))||(null===(o=e.searchKey)||void 0===o?void 0:o.toLowerCase().includes(G.toLowerCase()))?(ce.push(!G||e.label===G),e):null}return e})).filter((e=>null!==e)),ue=!!v&&G&&0===ae.length;return e(h,Object.assign({version:k,ref:ie,style:Object.assign({width:ee},N)},{children:[e("div",Object.assign({style:{width:oe?"50%":"100%",display:"flex",flexDirection:"column",background:"white"}},{children:[!!v&&t(f,{onSearch:W,version:k}),ae.length||G?e(m,Object.assign({minHeight:le,maxHeight:se},{children:[!!y&&!ue&&!I&&t(p,{version:k,options:G&&L?J:P,onSelect:U}),!x&&ue&&t(S,{isLoading:q,height:se,searchedString:G}),x&&(ue||!!ce.length&&ce.every((e=>!1===e)))&&t(a,{version:k,isMultiSelect:y,onSelect:X,searchedString:G}),t(u,{onInfiniteScroll:H,onDropdownItemClick:R,version:k,onSelect:Q,showDescription:function(e,t){ne(e&&t?{title:e,description:t}:null)},isMultiSelect:y,options:ae,useDefaultCursor:K,ref:re})]})):t("div",Object.assign({style:{height:le,display:"flex"}},{children:t(r,{title:"No results found",subTitle:"Please try again later or contact us at support@bik.ai if you require further assistance."})})),!!y&&!(!ae.length&&!G)&&"2.0"!==k&&t(d,{onClear:()=>{V(),null==T||T()},onApply:Y,list:G&&L?J:P,buttonText:B,buttonOptions:Z})]})),!!oe&&t(c,{title:oe.title,description:oe.description,version:k})]}))};export{w as OpenedDropdown};
1
+ import{jsxs as e,jsx as t}from"react/jsx-runtime";import{useState as o,useRef as n,useEffect as r}from"react";import{ZeroState as i}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,w=w=>{let{options:v,isSearchable:j,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:R,buttonOptions:Z,isSearchLoading:q,disableSearchOptions:z,disableSearchedOptionExcept:E,useDefaultCursor:K}=w;const{dropdownOptions:N,search:P,searchedString:W,searchedOptions:G,onApplyHandler:J,selectAllHandler:Q,onMultiSelectClear:U,onFreeFormSelect:V,onMultiSelectApply:X,latestDropdownOptionsRef:Y,getSelectedOptions:$}=s(k,v,M,A,y,L,z,E),[_,ee]=o(null!=O?O:b),[te,oe]=o(null),ne=n(null),re=n([]);l(ne,(()=>{if(oe(null),y&&"2.0"===k){const e=$(Y.current);null==D||D(e)}else null==D||D(N)}),[F,re]);const ie=null!=C?C:g,le="number"==typeof ie?j&&y?ie-96:j&&!y||!j&&y?ie-48:ie:ie;r((()=>{const e=null!=O?O:b;if(null===te)ee(e);else if("number"==typeof e)ee(2*e);else if("string"==typeof e&&e.endsWith("px")){const t=2*parseInt(e.replace("px",""));ee(t)}}),[te]);const se=[],ce=(W&&L?G:N).map((e=>{var t,o;if(W&&!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(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===(o=e.searchKey)||void 0===o?void 0:o.toLowerCase().includes(W.toLowerCase()))?(se.push(!W||e.label===W),e):null}return e})).filter((e=>null!==e)),ae=!!j&&W&&0===ce.length;return e(h,Object.assign({version:k,ref:ne,style:{width:_}},{children:[e("div",Object.assign({style:{width:te?"50%":"100%",display:"flex",flexDirection:"column",background:"white"}},{children:[!!j&&t(f,{onSearch:P,version:k}),ce.length||W?e(m,Object.assign({minHeight:ie,maxHeight:le},{children:[!!y&&!ae&&!I&&t(p,{version:k,options:W&&L?G:N,onSelect:Q}),!x&&ae&&t(S,{isLoading:q,height:le,searchedString:W}),x&&(ae||!!se.length&&se.every((e=>!1===e)))&&t(a,{version:k,isMultiSelect:y,onSelect:V,searchedString:W}),t(u,{onInfiniteScroll:H,onDropdownItemClick:R,version:k,onSelect:J,showDescription:function(e,t){oe(e&&t?{title:e,description:t}:null)},isMultiSelect:y,options:ce,useDefaultCursor:K,ref:re})]})):t("div",Object.assign({style:{height:ie,display:"flex"}},{children:t(i,{title:"No results found",subTitle:"Please try again later or contact us at support@bik.ai if you require further assistance."})})),!!y&&!(!ce.length&&!W)&&"2.0"!==k&&t(d,{onClear:()=>{U(),null==T||T()},onApply:X,list:W&&L?G:N,buttonText:B,buttonOptions:Z})]})),!!te&&t(c,{title:te.title,description:te.description,version:k})]}))};export{w as OpenedDropdown};
@@ -29,7 +29,6 @@ export interface OpenDropdownProps {
29
29
  disableSearchedOptionExcept?: string[];
30
30
  useDefaultCursor?: boolean;
31
31
  'data-test'?: string;
32
- containerStyle?: React.CSSProperties;
33
32
  }
34
33
  export type GroupedOption = {
35
34
  label?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bikdotai/bik-component-library",
3
- "version": "0.0.627-containerStyle-2",
3
+ "version": "0.0.627",
4
4
  "description": "Bik Component Library",
5
5
  "repository": {
6
6
  "type": "git",