@bikdotai/bik-component-library 0.0.210-beta.1 → 0.0.210
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.
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/InTheLast.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Connector.js +1 -1
- package/dist/cjs/components/QueryBuilder/constants/connector.d.ts +7 -16
- package/dist/cjs/components/QueryBuilder/constants/connector.js +1 -1
- package/dist/cjs/components/QueryBuilder/helpers/Connector.helper.d.ts +0 -2
- package/dist/cjs/components/QueryBuilder/helpers/Connector.helper.js +1 -1
- package/dist/cjs/components/QueryBuilder/types/QueryBuilderConnector.type.d.ts +1 -1
- package/dist/cjs/components/QueryBuilder/types/QueryBuilderOperator.type.d.ts +7 -15
- package/dist/cjs/components/QueryBuilder/types/QueryBuilderOperator.type.js +1 -1
- package/dist/cjs/components/accordion/Accordion.d.ts +6 -2
- package/dist/cjs/components/accordion/Accordion.js +1 -1
- package/dist/cjs/components/accordion/Accordion.style.d.ts +2 -0
- package/dist/cjs/components/accordion/Accordion.style.js +8 -4
- package/dist/cjs/components/accordion/AccordionArrow.d.ts +5 -2
- package/dist/cjs/components/accordion/AccordionArrow.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js +1 -1
- package/dist/cjs/components/avatar/Avatar.js +1 -1
- package/dist/cjs/components/avatar/Avatar.styled.d.ts +2 -1
- package/dist/cjs/components/avatar/Avatar.styled.js +3 -3
- package/dist/cjs/components/avatar/index.d.ts +1 -0
- package/dist/cjs/components/bik-layout/CommonStyles.js +1 -1
- package/dist/cjs/components/checkBox/CheckBox.d.ts +2 -0
- package/dist/cjs/components/checkBox/CheckBox.js +1 -1
- package/dist/cjs/components/checkBox/CheckBox.styled.d.ts +1 -0
- package/dist/cjs/components/checkBox/CheckBox.styled.js +13 -12
- package/dist/cjs/components/country-code-picker/CountryCodePicker.d.ts +1 -0
- package/dist/cjs/components/country-code-picker/CountryCodePicker.js +1 -1
- package/dist/cjs/components/custom-date-time/CustomDateTime.js +1 -1
- package/dist/cjs/components/discount-modal/DiscountModal.js +1 -1
- package/dist/cjs/components/discount-modal/DynamicCoupon/DynamicCoupon.js +1 -1
- package/dist/cjs/components/dropdown/DropdownPopover/index.d.ts +0 -6
- package/dist/cjs/components/dropdown/DropdownPopover/index.js +1 -1
- package/dist/cjs/components/dropdown/MenuItem/MenuItem.js +2 -2
- package/dist/cjs/components/dropdown/OpenedDropdown/components/OpennedDropdown.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/OpennedDropdown.styled.d.ts +3 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/OpennedDropdown.styled.js +10 -24
- package/dist/cjs/components/dropdown/OpenedDropdown/components/description/Description.d.ts +1 -0
- package/dist/cjs/components/dropdown/OpenedDropdown/components/description/Description.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/description/Description.styled.d.ts +3 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/description/Description.styled.js +2 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/FreeFormMenu.d.ts +1 -0
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/FreeFormMenu.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/MenuItem.d.ts +1 -0
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/MenuItem.js +4 -3
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/MenuList.d.ts +1 -0
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/MenuList.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/MenuList.styled.d.ts +2 -0
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/MenuList.styled.js +5 -4
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/SelectAllMenu.d.ts +1 -0
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/SelectAllMenu.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/searchbox/SearchBox.d.ts +1 -0
- package/dist/cjs/components/dropdown/OpenedDropdown/components/searchbox/SearchBox.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/searchbox/SearchZeroState.d.ts +1 -0
- package/dist/cjs/components/dropdown/OpenedDropdown/components/searchbox/SearchZeroState.js +1 -1
- package/dist/cjs/components/dropdown/index.d.ts +1 -2
- package/dist/cjs/components/dropdown/type.d.ts +3 -1
- package/dist/cjs/components/dropdown-button/DropdownButton.js +1 -1
- package/dist/cjs/components/fab-menu/FABMenu.d.ts +1 -0
- package/dist/cjs/components/fab-menu/FABMenu.js +1 -1
- package/dist/cjs/components/input/Input.d.ts +1 -0
- package/dist/cjs/components/input/Input.js +1 -1
- package/dist/cjs/components/list-item/ListItem.d.ts +1 -0
- package/dist/cjs/components/list-item/ListItem.js +1 -1
- package/dist/cjs/components/list-item/ListItem.styled.d.ts +1 -0
- package/dist/cjs/components/list-item/ListItem.styled.js +1 -1
- package/dist/cjs/components/list-item/themes.d.ts +1 -1
- package/dist/cjs/components/list-item/themes.js +1 -1
- package/dist/cjs/components/radioButton/RadioButton.d.ts +2 -0
- package/dist/cjs/components/radioButton/RadioButton.js +1 -1
- package/dist/cjs/components/radioButton/RadioButton.styled.d.ts +1 -0
- package/dist/cjs/components/radioButton/RadioButton.styled.js +8 -7
- package/dist/cjs/components/states/StateComponent.d.ts +1 -0
- package/dist/cjs/components/states/StateComponent.js +1 -1
- package/dist/cjs/components/states/StateComponent.styled.d.ts +6 -2
- package/dist/cjs/components/states/StateComponent.styled.js +9 -6
- package/dist/cjs/components/tag/Tag.d.ts +1 -1
- package/dist/cjs/components/tag/Tag.js +1 -1
- package/dist/cjs/components/tag/Tag.styled.d.ts +2 -0
- package/dist/cjs/components/tag/Tag.styled.js +1 -1
- package/dist/cjs/components/tag/model.d.ts +2 -0
- package/dist/cjs/index.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/InTheLast.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Connector.js +1 -1
- package/dist/esm/components/QueryBuilder/constants/connector.d.ts +7 -16
- package/dist/esm/components/QueryBuilder/constants/connector.js +1 -1
- package/dist/esm/components/QueryBuilder/helpers/Connector.helper.d.ts +0 -2
- package/dist/esm/components/QueryBuilder/helpers/Connector.helper.js +1 -1
- package/dist/esm/components/QueryBuilder/types/QueryBuilderConnector.type.d.ts +1 -1
- package/dist/esm/components/QueryBuilder/types/QueryBuilderOperator.type.d.ts +7 -15
- package/dist/esm/components/QueryBuilder/types/QueryBuilderOperator.type.js +1 -1
- package/dist/esm/components/accordion/Accordion.d.ts +6 -2
- package/dist/esm/components/accordion/Accordion.js +1 -1
- package/dist/esm/components/accordion/Accordion.style.d.ts +2 -0
- package/dist/esm/components/accordion/Accordion.style.js +8 -4
- package/dist/esm/components/accordion/AccordionArrow.d.ts +5 -2
- package/dist/esm/components/accordion/AccordionArrow.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js +1 -1
- package/dist/esm/components/avatar/Avatar.js +1 -1
- package/dist/esm/components/avatar/Avatar.styled.d.ts +2 -1
- package/dist/esm/components/avatar/Avatar.styled.js +3 -3
- package/dist/esm/components/avatar/index.d.ts +1 -0
- package/dist/esm/components/bik-layout/CommonStyles.js +1 -1
- package/dist/esm/components/checkBox/CheckBox.d.ts +2 -0
- package/dist/esm/components/checkBox/CheckBox.js +1 -1
- package/dist/esm/components/checkBox/CheckBox.styled.d.ts +1 -0
- package/dist/esm/components/checkBox/CheckBox.styled.js +7 -6
- package/dist/esm/components/country-code-picker/CountryCodePicker.d.ts +1 -0
- package/dist/esm/components/country-code-picker/CountryCodePicker.js +1 -1
- package/dist/esm/components/custom-date-time/CustomDateTime.js +1 -1
- package/dist/esm/components/discount-modal/DiscountModal.js +1 -1
- package/dist/esm/components/discount-modal/DynamicCoupon/DynamicCoupon.js +1 -1
- package/dist/esm/components/dropdown/DropdownPopover/index.d.ts +0 -6
- package/dist/esm/components/dropdown/DropdownPopover/index.js +1 -1
- package/dist/esm/components/dropdown/MenuItem/MenuItem.js +2 -2
- package/dist/esm/components/dropdown/OpenedDropdown/components/OpennedDropdown.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/OpennedDropdown.styled.d.ts +3 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/OpennedDropdown.styled.js +10 -24
- package/dist/esm/components/dropdown/OpenedDropdown/components/description/Description.d.ts +1 -0
- package/dist/esm/components/dropdown/OpenedDropdown/components/description/Description.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/description/Description.styled.d.ts +3 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/description/Description.styled.js +2 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/FreeFormMenu.d.ts +1 -0
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/FreeFormMenu.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/MenuItem.d.ts +1 -0
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/MenuItem.js +4 -3
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/MenuList.d.ts +1 -0
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/MenuList.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/MenuList.styled.d.ts +2 -0
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/MenuList.styled.js +6 -5
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/SelectAllMenu.d.ts +1 -0
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/SelectAllMenu.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/searchbox/SearchBox.d.ts +1 -0
- package/dist/esm/components/dropdown/OpenedDropdown/components/searchbox/SearchBox.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/searchbox/SearchZeroState.d.ts +1 -0
- package/dist/esm/components/dropdown/OpenedDropdown/components/searchbox/SearchZeroState.js +1 -1
- package/dist/esm/components/dropdown/index.d.ts +1 -2
- package/dist/esm/components/dropdown/type.d.ts +3 -1
- package/dist/esm/components/dropdown-button/DropdownButton.js +1 -1
- package/dist/esm/components/fab-menu/FABMenu.d.ts +1 -0
- package/dist/esm/components/fab-menu/FABMenu.js +1 -1
- package/dist/esm/components/input/Input.d.ts +1 -0
- package/dist/esm/components/input/Input.js +1 -1
- package/dist/esm/components/list-item/ListItem.d.ts +1 -0
- package/dist/esm/components/list-item/ListItem.js +1 -1
- package/dist/esm/components/list-item/ListItem.styled.d.ts +1 -0
- package/dist/esm/components/list-item/ListItem.styled.js +1 -1
- package/dist/esm/components/list-item/themes.d.ts +1 -1
- package/dist/esm/components/list-item/themes.js +1 -1
- package/dist/esm/components/radioButton/RadioButton.d.ts +2 -0
- package/dist/esm/components/radioButton/RadioButton.js +1 -1
- package/dist/esm/components/radioButton/RadioButton.styled.d.ts +1 -0
- package/dist/esm/components/radioButton/RadioButton.styled.js +8 -7
- package/dist/esm/components/states/StateComponent.d.ts +1 -0
- package/dist/esm/components/states/StateComponent.js +1 -1
- package/dist/esm/components/states/StateComponent.styled.d.ts +6 -2
- package/dist/esm/components/states/StateComponent.styled.js +9 -6
- package/dist/esm/components/tag/Tag.d.ts +1 -1
- package/dist/esm/components/tag/Tag.js +1 -1
- package/dist/esm/components/tag/Tag.styled.d.ts +2 -0
- package/dist/esm/components/tag/Tag.styled.js +1 -1
- package/dist/esm/components/tag/model.d.ts +2 -0
- package/dist/esm/index.js +1 -1
- package/package.json +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/InTwoLast.d.ts +0 -4
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/InTwoLast.js +0 -1
- package/dist/cjs/components/QueryBuilder/constants/DATE_OPERATORS_OPTIONS.d.ts +0 -2
- package/dist/cjs/components/QueryBuilder/constants/DATE_OPERATORS_OPTIONS.js +0 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/InTwoLast.d.ts +0 -4
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/InTwoLast.js +0 -1
- package/dist/esm/components/QueryBuilder/constants/DATE_OPERATORS_OPTIONS.d.ts +0 -2
- package/dist/esm/components/QueryBuilder/constants/DATE_OPERATORS_OPTIONS.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@emotion/styled/base"),I=require("react/jsx-runtime"),d=require("react")
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@emotion/styled/base"),I=require("react/jsx-runtime"),d=require("react"),g=require("../../../../dropdown/Dropdown.js");require("../../../../dropdown/DropdownPopover/index.js"),require("../../../../zeroState/ZeroState.js"),require("../../../../TypographyStyle.js"),require("../../../../../constants/Theme.js"),require("../../../../dropdown/OpenedDropdown/components/description/Description.styled.js"),require("../../../../checkBox/CheckBox.styled.js"),require("../../../../list-item/ListItem.js"),require("../../../../dropdown/OpenedDropdown/components/menu/FreeFormMenu.styled.js"),require("../../../../dropdown/OpenedDropdown/components/menu/MenuItem.js"),require("../../../../dropdown/OpenedDropdown/components/menu/MenuList.styled.js"),require("../../../../button/Button.js"),require("../../../../dropdown/OpenedDropdown/components/multiSelect/MultiSelectDropdownBottomBar.styled.js"),require("../../../../dropdown/OpenedDropdown/components/OpennedDropdown.styled.js");var l=require("../../../../input/Input.js"),c=require("../../../../input/context/InputStyleProvider.js");require("../../../../dropdown/MenuItem/MenuItem.js");var n=require("../../InputLoader.js");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const s=o(e).default("div","production"===process.env.NODE_ENV?{target:"e18hgh550"}:{target:"e18hgh550",label:"Container"})("production"===process.env.NODE_ENV?{name:"180p6fo",styles:"display:flex;flex-direction:row;gap:12px"}:{name:"180p6fo",styles:"display:flex;flex-direction:row;gap:12px",map:"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb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09PSB2b2lkIDAgPyB2b2lkIDAgOiBvbkNoYW5nZShbdGV4dCwgdGltZV0pIH0pLCBfanN4KERyb3Bkb3duLCB7IGRpc2FibGVkOiBkaXNhYmxlZCwgcGxhY2VIb2xkZXI6IFwiVGltZVwiLCB3aWR0aDogXCIxMDhweFwiLCBzaXplOiBcInNtYWxsXCIsIG9wdGlvbnM6IG9wdGlvbnMsIG9uU2VsZWN0OiAob3B0aW9uKSA9PiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIG9uQ2hhbmdlID09PSBudWxsIHx8IG9uQ2hhbmdlID09PSB2b2lkIDAgPyB2b2lkIDAgOiBvbkNoYW5nZShbbnVtLCBvcHRpb24udmFsdWVdKTtcclxuICAgICAgICAgICAgICAgICAgICB9IH0pXSB9KSB9KSkpO1xyXG59O1xyXG4vLyBlc2xpbnQtZGlzYWJsZS1uZXh0LWxpbmUgcmVhY3QvZGlzcGxheS1uYW1lXHJcbmV4cG9ydCBkZWZhdWx0IChwcm9wcykgPT4gX2pzeChJblRoZUxhc3QsIE9iamVjdC5hc3NpZ24oe30sIHByb3BzKSk7XHJcbi8vIyBzb3VyY2VNYXBwaW5nVVJMPUluVGhlTGFzdC5qcy5tYXAiXX0= */",toString:function(){return"You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."}}),u=[{label:"day(s)",value:"days"},{label:"minute(s)",value:"minutes"},{label:"hour(s)",value:"hours"}],i=e=>{let{val:o,onChange:i,errors:t,isLoading:C,disabled:b}=e;var r,p;const[A,B]=d.useState(u),a=null!==(r=null==o?void 0:o[1])&&void 0!==r?r:"days",y=null!==(p=null==o?void 0:o[0])&&void 0!==p?p:"1";return d.useEffect((()=>{var e;const I=null!==(e=null==o?void 0:o[1])&&void 0!==e?e:"days";B((e=>e.map((e=>Object.assign(Object.assign({},e),{selected:I===e.value})))))}),[o]),d.useEffect((()=>{var e;if(void 0===(null==o?void 0:o[0])){const I=null!==(e=null==o?void 0:o[1])&&void 0!==e?e:"days";null==i||i(["1",I])}}),[]),C?I.jsx("div",Object.assign({style:{width:200}},{children:I.jsx(n.default,{containerStyle:{padding:"5px 8px"}})})):I.jsx(c.InputStyleContext.Provider,Object.assign({value:{InputWrapper:{width:104}}},{children:I.jsxs(s,{children:[I.jsx(l.Input,{type:"number",variant:"small",state:b?"disabled":"none",errorMessage:null==t?void 0:t.val,value:y,onChangeText:e=>null==i?void 0:i([e,a])}),I.jsx(g.Dropdown,{disabled:b,placeHolder:"Time",width:"108px",size:"small",options:A,onSelect:e=>{null==i||i([y,e.value])}})]})}))};exports.default=e=>I.jsx(i,Object.assign({},e));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("react"),n=require("../../constants/connectorPosition.js"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("react"),t=require("../../../../utils/unCamelCase.js"),n=require("../../constants/connectorPosition.js"),o=require("../../helpers/Connector.helper.js"),i=require("../../types/QueryBuilder.type.js"),l=require("../DropdownWrapper.js"),s=require("./Components/EmojiPicker.js"),u=require("./Components/FreeText.js"),a=require("./Components/FrequencyIntegerPositiveSingle.js"),d=require("./Components/IgPicker.js"),p=require("./Components/IntegerPositiveSingle.js"),c=require("./Components/IntegerSingleValue.js"),g=require("./Components/InTheLast.js"),C=require("./Components/MultiselectDropdownFreeText.js"),m=require("./Components/NoInput.js"),j=require("./Components/NumberTime.js"),q=require("./Components/SingleDate.js"),v=require("./Components/SingleselectDropdownFreeText.js"),f=require("./Components/StringSingleValue.js"),S=require("./Components/TwoDate.js"),I=require("./Components/TwoNumberInputsSeperatedByAnd.js"),P=require("./Connector.styled.js");const T={FreeText:u.default,IntegerPositiveSingle:p.default,IntegerSingleValue:c.default,StringSingleValue:f.default,MultiselectDropdownFreeText:C.default,SingleselectDropdownFreeText:v.default,NoInput:m.default,SingleDate:q.default,TwoNumberInputsSeperatedByAnd:I.default,FrequencyIntegerPositiveSingle:a.default,TwoDate:S.default,NumberTime:j.default,PostIgPicker:d.PostIgPicker,ReelIgPicker:d.ReelIgPicker,StoryIgPicker:d.StoryIgPicker,EmojiPicker:s.default,InTheLast:g.default};exports.default=s=>{let{isLoading:u,noDefault:a,connectorType:d,defaultConnector:p,onOperatorChange:c,onValueChange:g,connectorVal:C,extra:m,errors:j,disabled:q}=s;var v,f,S;const[I,y]=r.useState(null),[x,b]=r.useState(!1),h=o.ConnectorHelper.getConnectorType(d).map((e=>({selected:e===p,value:e,label:t.unCamelCaseWithFirstUppercase(e)})));function w(e){let r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];b(!0);const t=o.ConnectorHelper.getConnectorComponent(d,e.value);void 0!==t?d===i.QueryBuilderConnectorType.frequency&&"IntegerPositiveSingle"===t?y("FrequencyIntegerPositiveSingle"):y(t):y(null),r||c(e.value),setTimeout((()=>{b(!1)}),5)}return r.useEffect((()=>{a||(p?w({value:p,label:p},!0):(null==h?void 0:h[0])&&w(h[0]))}),[p]),e.jsxs(P.Container,{children:[e.jsx("div",{children:!(null===(v=null===n.disableOperatorDropdown||void 0===n.disableOperatorDropdown?void 0:n.disableOperatorDropdown[d])||void 0===v?void 0:v[p])&&e.jsx(l.default,{isSearchable:!0,disabled:q,width:"200px",isLoading:x,options:h,defaultOption:null===(f=h.filter((e=>e.selected)))||void 0===f?void 0:f[0],onSelect:w})}),null!==I&&!x&&(null===(S=T[I])||void 0===S?void 0:S.call(T,{disabled:q,val:C,onChange:g,extra:m,errors:j,isLoading:u}))]})};
|
|
@@ -20,8 +20,7 @@ export declare enum CONNECTOR_VALUE_COMPONENT_TYPES {
|
|
|
20
20
|
ReelIgPicker = "ReelIgPicker",
|
|
21
21
|
StoryIgPicker = "StoryIgPicker",
|
|
22
22
|
EmojiPicker = "EmojiPicker",
|
|
23
|
-
InTheLast = "InTheLast"
|
|
24
|
-
InTwoLast = "InTwoLast"
|
|
23
|
+
InTheLast = "InTheLast"
|
|
25
24
|
}
|
|
26
25
|
export declare const INTEGER_OPERATORS_COMPONENT: {
|
|
27
26
|
is: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
@@ -60,26 +59,18 @@ export declare const REACTION_OPERATORS_COMPONENT: {
|
|
|
60
59
|
contains: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
61
60
|
};
|
|
62
61
|
export declare const DATE_OPERATORS_COMPONENT: {
|
|
63
|
-
today: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
64
|
-
yesterday: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
65
|
-
"last 30 days": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
66
|
-
"last 7 days": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
67
|
-
"this month": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
68
|
-
"this week": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
69
|
-
"last month": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
70
|
-
"last week": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
71
|
-
exactly: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
72
|
-
"not exactly": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
73
|
-
"in the last": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
74
|
-
"not in the last": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
75
|
-
"in between last": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
76
|
-
"not in between last": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
77
62
|
on: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
78
63
|
notOn: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
79
64
|
inBetween: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
80
65
|
notInBetween: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
81
66
|
before: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
82
67
|
after: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
68
|
+
today: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
69
|
+
yesterday: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
70
|
+
"last week": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
71
|
+
"last month": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
72
|
+
"last quarter": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
73
|
+
"in the last": CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
83
74
|
};
|
|
84
75
|
export declare const SPECIFIC_IG_POST_OPERATORS_COMPONENT: {
|
|
85
76
|
in: CONNECTOR_VALUE_COMPONENT_TYPES;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../types/QueryBuilder.type.js"),O=require("../types/QueryBuilderOperator.type.js");const E={[e.QueryBuilderConnectorType.boolean]:O.BOOLEAN_OPERATORS,[e.QueryBuilderConnectorType.string]:O.STRING_OPERATORS,[e.QueryBuilderConnectorType.integer]:O.INTEGER_OPERATORS,[e.QueryBuilderConnectorType.frequency]:O.FREQUENCY_OPERATORS,[e.QueryBuilderConnectorType.date]:O.DATE_OPERATORS,[e.QueryBuilderConnectorType.specificPost]:O.SPECIFIC_IG_OPERATORS,[e.QueryBuilderConnectorType.specificReel]:O.SPECIFIC_IG_OPERATORS,[e.QueryBuilderConnectorType.specificStory]:O.SPECIFIC_IG_OPERATORS,[e.QueryBuilderConnectorType.anyIg]:O.ANY_IG_OPERATORS,[e.QueryBuilderConnectorType.reaction]:O.REACTION_OPERATORS,[e.QueryBuilderConnectorType.activityString]:O.IG_STRING_OPERATORS,[e.QueryBuilderConnectorType.anyAd]:O.ANY_AD_OPERATORS,[e.QueryBuilderConnectorType.specificAd]:O.AD_STRING_OPERATORS,[e.QueryBuilderConnectorType.iceBreaker]:O.ICE_BREAKER_OPERATORS};var T;exports.CONNECTOR_VALUE_COMPONENT_TYPES=void 0,(T=exports.CONNECTOR_VALUE_COMPONENT_TYPES||(exports.CONNECTOR_VALUE_COMPONENT_TYPES={})).FreeText="FreeText",T.NoInput="NoInput",T.IntegerSingleValue="IntegerSingleValue",T.StringSingleValue="StringSingleValue",T.TwoNumberInputsSeperatedByAnd="TwoNumberInputsSeperatedByAnd",T.MultiselectDropdownFreeText="MultiselectDropdownFreeText",T.SingleselectDropdownFreeText="SingleselectDropdownFreeText",T.SingleDate="SingleDate",T.TwoDate="TwoDate",T.IntegerPositiveSingle="IntegerPositiveSingle",T.NumberTime="NumberTime",T.PostIgPicker="PostIgPicker",T.ReelIgPicker="ReelIgPicker",T.StoryIgPicker="StoryIgPicker",T.EmojiPicker="EmojiPicker",T.InTheLast="InTheLast"
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../types/QueryBuilder.type.js"),O=require("../types/QueryBuilderOperator.type.js");const E={[e.QueryBuilderConnectorType.boolean]:O.BOOLEAN_OPERATORS,[e.QueryBuilderConnectorType.string]:O.STRING_OPERATORS,[e.QueryBuilderConnectorType.integer]:O.INTEGER_OPERATORS,[e.QueryBuilderConnectorType.frequency]:O.FREQUENCY_OPERATORS,[e.QueryBuilderConnectorType.date]:O.DATE_OPERATORS,[e.QueryBuilderConnectorType.specificPost]:O.SPECIFIC_IG_OPERATORS,[e.QueryBuilderConnectorType.specificReel]:O.SPECIFIC_IG_OPERATORS,[e.QueryBuilderConnectorType.specificStory]:O.SPECIFIC_IG_OPERATORS,[e.QueryBuilderConnectorType.anyIg]:O.ANY_IG_OPERATORS,[e.QueryBuilderConnectorType.reaction]:O.REACTION_OPERATORS,[e.QueryBuilderConnectorType.activityString]:O.IG_STRING_OPERATORS,[e.QueryBuilderConnectorType.anyAd]:O.ANY_AD_OPERATORS,[e.QueryBuilderConnectorType.specificAd]:O.AD_STRING_OPERATORS,[e.QueryBuilderConnectorType.iceBreaker]:O.ICE_BREAKER_OPERATORS};var T;exports.CONNECTOR_VALUE_COMPONENT_TYPES=void 0,(T=exports.CONNECTOR_VALUE_COMPONENT_TYPES||(exports.CONNECTOR_VALUE_COMPONENT_TYPES={})).FreeText="FreeText",T.NoInput="NoInput",T.IntegerSingleValue="IntegerSingleValue",T.StringSingleValue="StringSingleValue",T.TwoNumberInputsSeperatedByAnd="TwoNumberInputsSeperatedByAnd",T.MultiselectDropdownFreeText="MultiselectDropdownFreeText",T.SingleselectDropdownFreeText="SingleselectDropdownFreeText",T.SingleDate="SingleDate",T.TwoDate="TwoDate",T.IntegerPositiveSingle="IntegerPositiveSingle",T.NumberTime="NumberTime",T.PostIgPicker="PostIgPicker",T.ReelIgPicker="ReelIgPicker",T.StoryIgPicker="StoryIgPicker",T.EmojiPicker="EmojiPicker",T.InTheLast="InTheLast";const N={[O.INTEGER_OPERATORS.is]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText,[O.INTEGER_OPERATORS.isNot]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText,[O.INTEGER_OPERATORS.exists]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.INTEGER_OPERATORS.doesntExist]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.INTEGER_OPERATORS.lessThan]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.IntegerSingleValue,[O.INTEGER_OPERATORS.lessThanOrEqualTo]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.IntegerSingleValue,[O.INTEGER_OPERATORS.greaterThan]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.IntegerSingleValue,[O.INTEGER_OPERATORS.greaterThanOrEqualTo]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.IntegerSingleValue},_={[O.STRING_OPERATORS.is]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.MultiselectDropdownFreeText,[O.STRING_OPERATORS.isNot]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.MultiselectDropdownFreeText,[O.STRING_OPERATORS.contains]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText,[O.STRING_OPERATORS.doesntContain]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText,[O.STRING_OPERATORS.startsWith]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText,[O.STRING_OPERATORS.endsWith]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText,[O.STRING_OPERATORS.exists]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.STRING_OPERATORS.doesntExist]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput},t={[O.IG_STRING_OPERATORS.any]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.IG_STRING_OPERATORS.is]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.MultiselectDropdownFreeText,[O.IG_STRING_OPERATORS.contains]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText,[O.IG_STRING_OPERATORS.startsWith]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText,[O.IG_STRING_OPERATORS.endsWith]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.FreeText},r={[O.AD_STRING_OPERATORS.is]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.SingleselectDropdownFreeText},R={[O.ICE_BREAKER_OPERATORS.is]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.MultiselectDropdownFreeText},C={[O.REACTION_OPERATORS.contains]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.EmojiPicker},P={[O.DATE_OPERATORS.on]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.SingleDate,[O.DATE_OPERATORS.notOn]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.SingleDate,[O.DATE_OPERATORS.inBetween]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.TwoDate,[O.DATE_OPERATORS.notInBetween]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.TwoDate,[O.DATE_OPERATORS.before]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.SingleDate,[O.DATE_OPERATORS.after]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.SingleDate,[O.DATE_OPERATORS.today]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.DATE_OPERATORS.yesterday]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.DATE_OPERATORS["last week"]]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.DATE_OPERATORS["last month"]]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.DATE_OPERATORS["last quarter"]]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.DATE_OPERATORS["in the last"]]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.InTheLast},o={[O.SPECIFIC_IG_OPERATORS.in]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.PostIgPicker},S={[O.SPECIFIC_IG_OPERATORS.in]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.ReelIgPicker},n={[O.SPECIFIC_IG_OPERATORS.in]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.StoryIgPicker},A={[O.ANY_IG_OPERATORS.in]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput},s={[O.ANY_AD_OPERATORS.in]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput},i={[O.BOOLEAN_OPERATORS.isTrue]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.BOOLEAN_OPERATORS.isFalse]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.BOOLEAN_OPERATORS.exists]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput,[O.BOOLEAN_OPERATORS.doesntExist]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.NoInput},p={[O.FREQUENCY_OPERATORS.exactly]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.IntegerPositiveSingle,[O.FREQUENCY_OPERATORS.atleast]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.IntegerPositiveSingle,[O.FREQUENCY_OPERATORS.atMost]:exports.CONNECTOR_VALUE_COMPONENT_TYPES.IntegerPositiveSingle},I={[e.QueryBuilderConnectorType.boolean]:i,[e.QueryBuilderConnectorType.string]:_,[e.QueryBuilderConnectorType.integer]:N,[e.QueryBuilderConnectorType.frequency]:p,[e.QueryBuilderConnectorType.date]:P,[e.QueryBuilderConnectorType.specificPost]:o,[e.QueryBuilderConnectorType.specificReel]:S,[e.QueryBuilderConnectorType.specificStory]:n,[e.QueryBuilderConnectorType.anyIg]:A,[e.QueryBuilderConnectorType.reaction]:C,[e.QueryBuilderConnectorType.activityString]:t,[e.QueryBuilderConnectorType.anyAd]:s,[e.QueryBuilderConnectorType.specificAd]:r,[e.QueryBuilderConnectorType.iceBreaker]:R};exports.AD_STRING_OPERATORS_COMPONENT=r,exports.ANY_AD_OPERATORS_COMPONENT=s,exports.ANY_IG_OPERATORS_COMPONENT=A,exports.BOOLEAN_OPERATORS_COMPONENT=i,exports.CONNECTOR_TYPE_TO_COMPONENT_MAP=I,exports.CONNECTOR_TYPE_TO_OPERATORS=E,exports.DATE_OPERATORS_COMPONENT=P,exports.FREQUENCY_OPERATORS_COMPONENT=p,exports.ICE_BREAKER_OPERATORS_COMPONENT=R,exports.IG_STRING_OPERATORS_COMPONENT=t,exports.INTEGER_OPERATORS_COMPONENT=N,exports.REACTION_OPERATORS_COMPONENT=C,exports.SPECIFIC_IG_POST_OPERATORS_COMPONENT=o,exports.SPECIFIC_IG_REEL_OPERATORS_COMPONENT=S,exports.SPECIFIC_IG_STORY_OPERATORS_COMPONENT=n,exports.STRING_OPERATORS_COMPONENT=_;
|
|
@@ -1,8 +1,6 @@
|
|
|
1
|
-
import { DropdownOption } from "../../dropdown/type";
|
|
2
1
|
import { QueryBuilderConnectorType } from '../types/QueryBuilder.type';
|
|
3
2
|
import { CONNECTOR_OPERATORS } from '../types/QueryBuilderOperator.type';
|
|
4
3
|
export declare class ConnectorHelper {
|
|
5
4
|
static getConnectorType(datatype: QueryBuilderConnectorType): string[];
|
|
6
|
-
static getDropdownOptionFromDataType(datatype: QueryBuilderConnectorType, defaultConnector: CONNECTOR_OPERATORS | undefined): DropdownOption[];
|
|
7
5
|
static getConnectorComponent(dataType: QueryBuilderConnectorType, connectorType: CONNECTOR_OPERATORS): "FreeText" | "NoInput" | "IntegerSingleValue" | "StringSingleValue" | "TwoNumberInputsSeperatedByAnd" | "MultiselectDropdownFreeText" | "SingleselectDropdownFreeText" | "SingleDate" | "TwoDate" | "IntegerPositiveSingle" | "NumberTime" | null;
|
|
8
6
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../constants/connector.js");exports.ConnectorHelper=class{static getConnectorType(t){const r=e.CONNECTOR_TYPE_TO_OPERATORS[t];return r?Object.keys(r):[]}static getConnectorComponent(t,r){if(e.CONNECTOR_TYPE_TO_OPERATORS[t]){return e.CONNECTOR_TYPE_TO_COMPONENT_MAP[t][r]}return null}};
|
|
@@ -39,7 +39,7 @@ export type ConnectorProps = {
|
|
|
39
39
|
testID?: string;
|
|
40
40
|
disabled?: boolean;
|
|
41
41
|
};
|
|
42
|
-
export type CONNECTOR_VALUE_TYPE =
|
|
42
|
+
export type CONNECTOR_VALUE_TYPE = string[] | number | Date[] | Date | number[] | number | undefined | /** for multiselect */ QueryBuilderAPIData[] | IG_VALUE[];
|
|
43
43
|
type IG_VALUE = {
|
|
44
44
|
imageUrl: string;
|
|
45
45
|
redirectionUrl: string;
|
|
@@ -48,26 +48,18 @@ export declare enum REACTION_OPERATORS {
|
|
|
48
48
|
contains = "contains"
|
|
49
49
|
}
|
|
50
50
|
export declare enum DATE_OPERATORS {
|
|
51
|
-
today = "today",
|
|
52
|
-
yesterday = "yesterday",
|
|
53
|
-
'last 7 days' = "last 7 days",
|
|
54
|
-
'last 30 days' = "last 30 days",
|
|
55
|
-
'this week' = "this week",
|
|
56
|
-
'last week' = "last week",
|
|
57
|
-
'this month' = "this month",
|
|
58
|
-
'last month' = "last month",
|
|
59
|
-
'exactly' = "exactly",
|
|
60
|
-
'not exactly' = "not exactly",
|
|
61
|
-
'in the last' = "in the last",
|
|
62
|
-
'not in the last' = "not in the last",
|
|
63
|
-
'in between last' = "in between last",
|
|
64
|
-
'not in between last' = "not in between last",
|
|
65
51
|
on = "on",
|
|
66
52
|
notOn = "notOn",
|
|
67
53
|
inBetween = "inBetween",
|
|
68
54
|
notInBetween = "notInBetween",
|
|
69
55
|
before = "before",
|
|
70
|
-
after = "after"
|
|
56
|
+
after = "after",
|
|
57
|
+
today = "today",
|
|
58
|
+
yesterday = "yesterday",
|
|
59
|
+
'last week' = "last week",
|
|
60
|
+
'last month' = "last month",
|
|
61
|
+
'last quarter' = "last quarter",
|
|
62
|
+
'in the last' = "in the last"
|
|
71
63
|
}
|
|
72
64
|
export declare enum BOOLEAN_OPERATORS {
|
|
73
65
|
isTrue = "isTrue",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var e,t,s,o,
|
|
1
|
+
"use strict";var e,t,s,o,R,r,i;Object.defineProperty(exports,"__esModule",{value:!0}),exports.INTEGER_OPERATORS=void 0,(e=exports.INTEGER_OPERATORS||(exports.INTEGER_OPERATORS={})).is="is",e.isNot="isNot",e.exists="exists",e.doesntExist="doesntExist",e.lessThan="lessThan",e.lessThanOrEqualTo="lessThanOrEqualTo",e.greaterThan="greaterThan",e.greaterThanOrEqualTo="greaterThanOrEqualTo",exports.STRING_OPERATORS=void 0,(t=exports.STRING_OPERATORS||(exports.STRING_OPERATORS={})).is="is",t.isNot="isNot",t.contains="contains",t.doesntContain="doesntContain",t.startsWith="startsWith",t.endsWith="endsWith",t.exists="exists",t.doesntExist="doesntExist",exports.IG_STRING_OPERATORS=void 0,(s=exports.IG_STRING_OPERATORS||(exports.IG_STRING_OPERATORS={})).any="any",s.is="is",s.contains="contains",s.startsWith="startsWith",s.endsWith="endsWith",exports.AD_STRING_OPERATORS=void 0,(exports.AD_STRING_OPERATORS||(exports.AD_STRING_OPERATORS={})).is="is",exports.SPECIFIC_IG_OPERATORS=void 0,(exports.SPECIFIC_IG_OPERATORS||(exports.SPECIFIC_IG_OPERATORS={})).in="in",exports.ICE_BREAKER_OPERATORS=void 0,(exports.ICE_BREAKER_OPERATORS||(exports.ICE_BREAKER_OPERATORS={})).is="is",exports.ANY_IG_OPERATORS=void 0,(exports.ANY_IG_OPERATORS||(exports.ANY_IG_OPERATORS={})).in="in",exports.ANY_AD_OPERATORS=void 0,(exports.ANY_AD_OPERATORS||(exports.ANY_AD_OPERATORS={})).in="in",exports.REACTION_OPERATORS=void 0,(exports.REACTION_OPERATORS||(exports.REACTION_OPERATORS={})).contains="contains",exports.DATE_OPERATORS=void 0,(o=exports.DATE_OPERATORS||(exports.DATE_OPERATORS={})).on="on",o.notOn="notOn",o.inBetween="inBetween",o.notInBetween="notInBetween",o.before="before",o.after="after",o.today="today",o.yesterday="yesterday",o["last week"]="last week",o["last month"]="last month",o["last quarter"]="last quarter",o["in the last"]="in the last",exports.BOOLEAN_OPERATORS=void 0,(R=exports.BOOLEAN_OPERATORS||(exports.BOOLEAN_OPERATORS={})).isTrue="isTrue",R.isFalse="isFalse",R.exists="exists",R.doesntExist="doesntExist",exports.FREQUENCY_OPERATORS=void 0,(r=exports.FREQUENCY_OPERATORS||(exports.FREQUENCY_OPERATORS={})).exactly="exactly",r.atleast="atleast",r.atMost="atMost",exports.EVENT_VALUES=void 0,(i=exports.EVENT_VALUES||(exports.EVENT_VALUES={})).FreeText="FreeText",i.NoInput="NoInput",i.IntegerSingleValue="IntegerSingleValue",i.StringSingleValue="StringSingleValue",i.TwoNumberInputsSeperatedByAnd="TwoNumberInputsSeperatedByAnd",i.MultiselectDropdownFreeText="MultiselectDropdownFreeText",i.SingleselectDropdownFreeText="SingleselectDropdownFreeText",i.SingleDate="SingleDate",i.TwoDate="TwoDate",i.IntegerPositiveSingle="IntegerPositiveSingle",i.NumberTime="NumberTime";
|
|
@@ -1,9 +1,13 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
export interface AccordionProps {
|
|
3
|
-
header: string;
|
|
4
|
-
caption
|
|
3
|
+
header: JSX.Element | string;
|
|
4
|
+
caption?: string;
|
|
5
5
|
children: ReactNode;
|
|
6
6
|
width?: string;
|
|
7
|
+
rightActionComponent?: JSX.Element;
|
|
7
8
|
contentMargin?: string;
|
|
9
|
+
skipHoverHeader?: boolean;
|
|
10
|
+
headerPadding?: string;
|
|
11
|
+
childrenPadding?: string;
|
|
8
12
|
}
|
|
9
13
|
export declare const BikAccordion: React.FC<AccordionProps>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("react"),t=require("../TypographyStyle.js"),n=require("./Accordion.style.js"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("react"),t=require("../TypographyStyle.js"),n=require("./Accordion.style.js"),i=require("./AccordionArrow.js");exports.BikAccordion=s=>{const[a,c]=r.useState(!1),o=r.useRef(null),d=r.useRef(null),l=(e,r)=>{var t;d.current&&o.current&&("keydown"===r.type&&"Enter"!==r.key||(c(e),d.current.style.maxHeight?(d.current.style.maxHeight="",o.current.style.transform="rotate(0deg)",o.current.style.transition="transform 0.25s ease-in-out",d.current.style.padding="0",d.current.style.transition=" padding 0s"):(d.current.style.maxHeight=d.current.scrollHeight+"px",o.current.style.transform="rotate(180deg)",d.current.style.padding=null!==(t=s.childrenPadding)&&void 0!==t?t:"0px 24px 24px 24px",o.current.style.transition="transform 0.25s ease-in-out",d.current.style.transition="max-height 0.25s ease-in-out")))};return e.jsxs(n.default,Object.assign({className:"accordion",isActive:a,width:null==s?void 0:s.width,contentMargin:null==s?void 0:s.contentMargin,headerPadding:s.headerPadding,skipHoverState:s.skipHoverHeader},{children:[e.jsxs("div",Object.assign({className:"accordion__overview "+(a?"active":""),onClick:e=>l(!a,e),onKeyDown:e=>l(!a,e),role:"button",tabIndex:0},{children:[!s.rightActionComponent&&e.jsxs("div",Object.assign({className:"accordion__overview__header"},{children:["string"==typeof s.header?e.jsx(t.TitleRegular,{children:null==s?void 0:s.header}):s.header,e.jsx(i.default,{isNewIcon:!1,ref:o})]})),s.rightActionComponent&&e.jsxs("div",Object.assign({className:"accordion__overview__header"},{children:[e.jsxs("div",Object.assign({className:"accordion__overview__title-wrapper"},{children:[e.jsx(i.default,{isNewIcon:!0,ref:o}),"string"==typeof s.header?e.jsx(t.TitleRegular,{children:null==s?void 0:s.header}):s.header]})),s.rightActionComponent]})),(null==s?void 0:s.caption)&&e.jsx("div",Object.assign({className:"accordion__overview__caption"},{children:e.jsx(t.BodySecondary,{children:s.caption})}))]})),e.jsx("div",Object.assign({ref:d,className:"accordion__content"},{children:s.children}))]}))};
|
|
@@ -2,5 +2,7 @@ declare const AccordionStyle: import("styled-components").StyledComponent<"div",
|
|
|
2
2
|
isActive: boolean;
|
|
3
3
|
width?: string | undefined;
|
|
4
4
|
contentMargin?: string | undefined;
|
|
5
|
+
skipHoverState?: boolean | undefined;
|
|
6
|
+
headerPadding?: string | undefined;
|
|
5
7
|
}, never>;
|
|
6
8
|
export default AccordionStyle;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("styled-components"),t=require("../../constants/Theme.js");function i(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("styled-components"),t=require("../../constants/Theme.js");function i(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const d=i(e).default.div`
|
|
2
2
|
width: ${e=>(null==e?void 0:e.width)||"100%"};
|
|
3
3
|
display: flex;
|
|
4
4
|
flex-direction: column;
|
|
@@ -7,15 +7,19 @@
|
|
|
7
7
|
display: flex;
|
|
8
8
|
flex-direction: column;
|
|
9
9
|
gap: 4px;
|
|
10
|
-
padding: 24px;
|
|
10
|
+
padding: ${e=>e.headerPadding?e.headerPadding:"24px"};
|
|
11
11
|
&__header {
|
|
12
12
|
display: flex;
|
|
13
13
|
flex-direction: row;
|
|
14
14
|
align-items: center;
|
|
15
15
|
justify-content: space-between;
|
|
16
16
|
}
|
|
17
|
+
&__title-wrapper {
|
|
18
|
+
display: flex;
|
|
19
|
+
gap: 8px;
|
|
20
|
+
}
|
|
17
21
|
:hover {
|
|
18
|
-
background: ${t.COLORS.surface.subdued};
|
|
22
|
+
background: ${e=>e.skipHoverState?null:t.COLORS.surface.subdued};
|
|
19
23
|
border-radius: 4px;
|
|
20
24
|
}
|
|
21
25
|
}
|
|
@@ -25,4 +29,4 @@
|
|
|
25
29
|
max-height: 0;
|
|
26
30
|
}
|
|
27
31
|
}
|
|
28
|
-
`;exports.default=
|
|
32
|
+
`;exports.default=d;
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
|
|
1
|
+
import React, { HTMLAttributes } from 'react';
|
|
2
|
+
interface BikAccordionArrowProps extends HTMLAttributes<HTMLDivElement> {
|
|
3
|
+
isNewIcon: boolean;
|
|
4
|
+
}
|
|
5
|
+
declare const BikAccordionArrow: React.ForwardRefExoticComponent<BikAccordionArrowProps & React.RefAttributes<HTMLDivElement>>;
|
|
3
6
|
export default BikAccordionArrow;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime");function
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime");function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const i=t(require("react")).default.forwardRef(((t,i)=>e.jsxs("div",Object.assign({ref:i,className:"d-flex align-items-center"},{children:[!t.isNewIcon&&e.jsx("svg",Object.assign({width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:e.jsx("path",{d:"M7.7071 10.7071C7.07713 10.0771 7.5233 9 8.41421 9H15.5858C16.4767 9 16.9228 10.0771 16.2929 10.7071L12.7071 14.2929C12.3166 14.6834 11.6834 14.6834 11.2929 14.2929L7.7071 10.7071Z",fill:"currentColor"})})),t.isNewIcon&&e.jsx("svg",Object.assign({width:"10",height:"6",viewBox:"0 0 10 6",fill:"none",xmlns:"http://www.w3.org/2000/svg"},{children:e.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M0.528758 0.52827C0.789108 0.26792 1.21122 0.26792 1.47157 0.52827L5.00016 4.05687L8.52876 0.52827C8.78911 0.26792 9.21122 0.26792 9.47157 0.52827C9.73192 0.788619 9.73192 1.21073 9.47157 1.47108L5.47157 5.47108C5.21122 5.73143 4.78911 5.73143 4.52876 5.47108L0.528758 1.47108C0.268409 1.21073 0.268409 0.788619 0.528758 0.52827Z",fill:"currentColor"})}))]}))));i.displayName="BikAccordionArrow",exports.default=i;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@emotion/styled/base"),r=require("react/jsx-runtime"),g=require("../../../../utils/StringUtils.js"),t=require("../../../../constants/Theme.js"),I=require("react");require("../../../checkBox/CheckBox.styled.js");var i=require("../../../TypographyStyle.js");require("../../../list-item/ListItem.js"),require("../../../pagination/Pagination.js"),require("../../../radioButton/RadioButton.styled.js"),require("react-toastify"),require("../../../toaster/Toaster.styled.js"),require("@tippyjs/react"),require("../../../tooltips/TooltipInternal.js"),require("../../../spinner/Spinner.js"),require("../../../stepper/Stepper.styled.js"),require("../../../tag/Tag.js"),require("../../../icon-button/IconButton.js"),require("../../../template-preview/TemplatePreview.js"),require("../../../template-preview/WhatsApp/WhatsAppLikePreview.js"),require("../../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js"),require("../../../template-preview/models/TemplateMeta.js"),require("../../../modals/styledModal.js"),require("../../../template-preview/models/Channels.js"),require("../../../template-context-mapper/context/templateModalContext.js"),require("../../../template-context-mapper/modalElements/Footer.js"),require("../../../template-context-mapper/modalElements/Body.js"),require("../../../template-context-mapper/modalElements/Header.js"),require("../../../zeroState/ZeroState.js"),require("../../../dropdown/OpenedDropdown/components/description/Description.styled.js"),require("../../../dropdown/OpenedDropdown/components/menu/FreeFormMenu.styled.js"),require("../../../dropdown/OpenedDropdown/components/menu/MenuItem.js"),require("../../../dropdown/OpenedDropdown/components/menu/MenuList.styled.js"),require("../../../dropdown/OpenedDropdown/components/menu/SelectAllMenu.js"),require("../../../button/Button.js"),require("../../../dropdown/OpenedDropdown/components/multiSelect/MultiSelectDropdownBottomBar.styled.js"),require("../../../dropdown/OpenedDropdown/components/OpennedDropdown.styled.js"),require("../../../input/Input.js"),require("react-bootstrap"),require("../../../floating-action-button/FloatingActionButton.styles.js"),require("../../../image-compress/ImageCompress.js"),require("../../../progress-bar/ProgressBarComponent.js"),require("../../../QueryBuilder/QueryBuilder.js"),require("../../../QueryBuilder/components/QueryBuilderNode/Base/BaseQueryBuilderNode.js"),require("../../../QueryBuilder/constants/connectorPosition.js"),require("../../../QueryBuilder/constants/connector.js"),require("../../../QueryBuilder/types/QueryBuilder.type.js"),require("../../../dropdown/Dropdown.js"),require("../../../QueryBuilder/components/InputLoader.js"),require("../../../QueryBuilder/components/Connectors/Components/EmojiPicker.js"),require("react-chips"),require("../../../input/ChipInput.styled.js"),require("../../../QueryBuilder/components/Connectors/Components/FrequencyIntegerPositiveSingle.js"),require("../../../QueryBuilder/components/Connectors/Components/IgPicker.js"),require("../../../QueryBuilder/components/Connectors/Components/InTheLast.js"),require("../../../QueryBuilder/components/Connectors/Components/InTwoLast.js"),require("react-calendar"),require("../../../../utils/DateUtils.js"),require("../../../datePicker/DatePickerWrapper.styled.js"),require("../../../QueryBuilder/components/Connectors/Connector.styled.js"),require("../../../QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.styled.js"),require("../../../QueryBuilder/components/QueryBuilderNode/Property/PropertyNodeUIWrapper.styled.js"),require("../../../QueryBuilder/redux/queryBuilder.reducer.js"),require("../../../QueryBuilder/redux/queryBuilderCache.reducer.js"),require("../../../QueryBuilder/types/QueryBuilderOperator.type.js"),require("../../../dropdown/DropdownPopover/index.js"),require("../../../dropdown/MenuItem/MenuItem.js"),require("../../../shimmer/ShimmerComponent/ShimmerStyled.js"),require("../../../analytics-card/AnalyticsCard.styled.js"),require("../../CommonStyles.js"),require("../../../datePicker/DatePicker.styled.js"),require("../../AnalyticsMetric.js"),require("../LineChart/LineChart.js"),require("../linearChipGroupedChart/LinearChipGroupedChart.styled.js");var C=require("./PieChart.js");require("../HorizontalBarGraph/HorizontalGraph.js"),require("../StackedBarChart/StackedBarChart.js"),require("../VerticalBarGraph/VerticalGraph.js"),require("../heatmap/HeatMap.js"),require("../VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js"),require("../../../avatar/Avatar.js"),require("../../../alerts/Alert.styled.js"),require("../../../alerts/AlertHelper.js"),require("../../../thumbnail/Thumbnail.js"),require("../../../curtain/Curtain.styled.js"),require("../../../curtain/CurtainHelper.js"),require("../../../switch/Switch.js"),require("../../../plans/SubscriptionPlanStyled.js"),require("../../../plans/SubscriptionPlanSelector.js"),require("../../../tabs/Tabs.js"),require("../../../TablePagination/TablePagination.styled.js"),require("../../../TablePagination/TablePaginationCard.js"),require("../../../states/StateComponent.js"),require("../../../WhatsAppTextEditor/WhatsAppTextEditor.js"),require("../../../WhatsAppTextEditor/WhatsAppTextEditorHeader.js"),require("../../../card-selection-modal/CardSelectionModal.styled.js"),require("react-image-crop"),require("../../../buttonGroup/ButtonGroupStyle.js"),require("../../../accordion/Accordion.style.js"),require("../../../accordion/AccordionArrow.js"),require("../../../file-uploader/FileUploaderStyle.js"),require("../../../colourInput/ColourInput.styled.js"),require("../../../bik-layout/CommonStyles.js"),require("../../../bik-layout/SidebarStyles.js"),require("date-fns"),require("react-popper"),require("../../../dropdown/Common.styled.js"),require("../../../custom-date-time/CustomDateTime.styled.js"),require("../../../../node_modules/lodash.debounce/index.js"),require("../../../product-picker/ProductPicker.styled.js"),require("../../../discount-modal/type.js"),require("../../../discount-modal/DiscountModal.styled.js"),require("../../../discount-modal/DynamicCoupon/DynamicCoupon.js"),require("../../../discount-modal/CouponExpiration/CouponExpiration.js"),require("../../../country-code-picker/CountryCodePicker.styled.js"),require("../../../product-picker-v2/emptyState.js"),require("../../../product-picker-v2/style.js"),require("lodash"),require("../../../carousel/carousel.js"),require("../../../carousel-secondary/CarouselSecondary.style.js"),require("../../../access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.styles.js"),require("../../../radioList/RadioList.styled.js"),require("../../../checkList/CheckList.styled.js"),require("../../../postPicker/postPicker.js"),require("../../../dropdown-button/DropdownButton.style.js");var s=require("chart.js"),c=require("react-chartjs-2");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var A=o(e);s.Chart.register(s.ArcElement,s.Legend);const l={plugins:{legend:{display:!1},tooltip:{enabled:!0,callbacks:{label:e=>{if(!e.label)return" 0%";const r=e.dataset.data.reduce(((e,r)=>e+r),0),g=parseFloat((e.raw/r*100).toFixed(1));return` ${e.label}: ${g}%`}}}}},a=["#5E07BB","#9E77ED","#D2AEFF","#CDE1FF","#92AFFA","#3935E1"],d=A.default("div","production"===process.env.NODE_ENV?{target:"elaov7f0"}:{target:"elaov7f0",label:"CartStyled"})("background:",(e=>t.COLORS.surface.standard),";border:1px solid ",(e=>t.COLORS.stroke.primary),";border-radius:4px;"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFzQzhCIiwiZmlsZSI6IlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IG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xyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZXREYXRhKGRhdGFTZXQpO1xyXG4gICAgICAgIH1cclxuICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgY29uc3QgZGF0YVNldCA9IHtcclxuICAgICAgICAgICAgICAgIGxhYmVsczogc2xpY2VzLm1hcCgoc2xpY2UpID0+IFN0cmluZ1V0aWxzLmNhcGl0YWxpemUoc2xpY2UubmFtZSkpLFxyXG4gICAgICAgICAgICAgICAgZGF0YXNldHM6IFtcclxuICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGE6IHNsaWNlcy5tYXAoKHNsaWNlKSA9PiBzbGljZS5jb3VudCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogc2xpY2VzLm1hcCgoc2xpY2UsIGluZGV4KSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHNsaWNlLmNvbG9yKSAhPT0gbnVsbCAmJiBfYSAhPT0gdm9pZCAwID8gX2EgOiBHUkFQSF9DT0xPUlNbaW5kZXggJSBHUkFQSF9DT0xPUlMubGVuZ3RoXTsgfSksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlckNvbG9yOiBbJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiA0LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJSYWRpdXM6IDgsXHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIF0sXHJcbiAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgIHNldERhdGEoZGF0YVNldCk7XHJcbiAgICAgICAgfVxyXG4gICAgfSwgW3Nsa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AgICAgICAgICBkaXNwbGF5OiAnZmxleCcsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBmbGV4RGlyZWN0aW9uOiAnY29sdW1uJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGp1c3RpZnlDb250ZW50OiAnY2VudGVyJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSB9LCB7IGNoaWxkcmVuOiBfanN4KFBpZUNoYXJ0LCB7IHNsaWNlczogc2xpY2VzV2l0aENvbG9yIH0pIH0pKV0gfSkpXSB9KSk7XHJcbn07XHJcbi8vIyBzb3VyY2VNYXBwaW5nVVJMPVBpZUNoYXJ0QW5hbHl0aWNzLmpzLm1hcCJdfQ== */"));exports.Card=e=>r.jsx(d,Object.assign({style:{padding:24}},{children:e.children})),exports.PieChartAnalytics=e=>{let{title:t,slices:s,size:o}=e;const[A,d]=I.useState([]),[n,u]=I.useState();return I.useEffect((()=>{const e=s.reduce(((e,r)=>e+r.count),0);let r=[];if(r=Object.keys(s).map(((e,r)=>Object.assign({color:a[r%a.length]},s[e]))),d([...r]),0===e){u({datasets:[{data:[100],backgroundColor:["#F0F0F0"],borderWidth:0}]})}else{const e={labels:s.map((e=>g.default.capitalize(e.name))),datasets:[{data:s.map((e=>e.count)),backgroundColor:s.map(((e,r)=>{var g;return null!==(g=e.color)&&void 0!==g?g:a[r%a.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};u(e)}}),[s]),n?r.jsxs(r.Fragment,{children:[t&&r.jsx(i.TitleMedium,Object.assign({style:{marginBottom:16}},{children:t})),r.jsxs("div",Object.assign({className:"row"},{children:[r.jsx("div",Object.assign({className:"col-6"},{children:r.jsx("div",Object.assign({style:{width:o,height:o}},{children:r.jsx(c.Doughnut,{data:n,options:Object.assign(Object.assign({},l),{maintainAspectRatio:!o})})}))})),r.jsx("div",Object.assign({className:"col-6",style:{paddingLeft:48,display:"flex",flexDirection:"column",justifyContent:"center"}},{children:r.jsx(C.PieChart,{slices:A})}))]}))]}):r.jsx(r.Fragment,{})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@emotion/styled/base"),r=require("react/jsx-runtime"),g=require("../../../../utils/StringUtils.js"),I=require("../../../../constants/Theme.js"),t=require("react");require("../../../checkBox/CheckBox.styled.js");var i=require("../../../TypographyStyle.js");require("../../../list-item/ListItem.js"),require("../../../pagination/Pagination.js"),require("../../../radioButton/RadioButton.styled.js"),require("react-toastify"),require("../../../toaster/Toaster.styled.js"),require("@tippyjs/react"),require("../../../tooltips/TooltipInternal.js"),require("../../../spinner/Spinner.js"),require("../../../stepper/Stepper.styled.js"),require("../../../tag/Tag.js"),require("../../../icon-button/IconButton.js"),require("../../../template-preview/TemplatePreview.js"),require("../../../template-preview/WhatsApp/WhatsAppLikePreview.js"),require("../../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js"),require("../../../template-preview/models/TemplateMeta.js"),require("../../../modals/styledModal.js"),require("../../../template-preview/models/Channels.js"),require("../../../template-context-mapper/context/templateModalContext.js"),require("../../../template-context-mapper/modalElements/Footer.js"),require("../../../template-context-mapper/modalElements/Body.js"),require("../../../template-context-mapper/modalElements/Header.js"),require("../../../zeroState/ZeroState.js"),require("../../../dropdown/OpenedDropdown/components/description/Description.styled.js"),require("../../../dropdown/OpenedDropdown/components/menu/FreeFormMenu.styled.js"),require("../../../dropdown/OpenedDropdown/components/menu/MenuItem.js"),require("../../../dropdown/OpenedDropdown/components/menu/MenuList.styled.js"),require("../../../button/Button.js"),require("../../../dropdown/OpenedDropdown/components/multiSelect/MultiSelectDropdownBottomBar.styled.js"),require("../../../dropdown/OpenedDropdown/components/OpennedDropdown.styled.js"),require("../../../input/Input.js"),require("react-bootstrap"),require("../../../floating-action-button/FloatingActionButton.styles.js"),require("../../../image-compress/ImageCompress.js"),require("../../../progress-bar/ProgressBarComponent.js"),require("../../../QueryBuilder/QueryBuilder.js"),require("../../../QueryBuilder/components/QueryBuilderNode/Base/BaseQueryBuilderNode.js"),require("../../../QueryBuilder/constants/connectorPosition.js"),require("../../../QueryBuilder/constants/connector.js"),require("../../../QueryBuilder/types/QueryBuilder.type.js"),require("../../../dropdown/Dropdown.js"),require("../../../QueryBuilder/components/InputLoader.js"),require("../../../QueryBuilder/components/Connectors/Components/EmojiPicker.js"),require("react-chips"),require("../../../input/ChipInput.styled.js"),require("../../../QueryBuilder/components/Connectors/Components/FrequencyIntegerPositiveSingle.js"),require("../../../QueryBuilder/components/Connectors/Components/IgPicker.js"),require("../../../QueryBuilder/components/Connectors/Components/InTheLast.js"),require("react-calendar"),require("../../../../utils/DateUtils.js"),require("../../../datePicker/DatePickerWrapper.styled.js"),require("../../../QueryBuilder/components/Connectors/Connector.styled.js"),require("../../../QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.styled.js"),require("../../../QueryBuilder/components/QueryBuilderNode/Property/PropertyNodeUIWrapper.styled.js"),require("../../../QueryBuilder/redux/queryBuilder.reducer.js"),require("../../../QueryBuilder/redux/queryBuilderCache.reducer.js"),require("../../../QueryBuilder/types/QueryBuilderOperator.type.js"),require("../../../dropdown/DropdownPopover/index.js"),require("../../../dropdown/MenuItem/MenuItem.js"),require("../../../shimmer/ShimmerComponent/ShimmerStyled.js"),require("../../../analytics-card/AnalyticsCard.styled.js"),require("../../CommonStyles.js"),require("../../../datePicker/DatePicker.styled.js"),require("../../AnalyticsMetric.js"),require("../LineChart/LineChart.js"),require("../linearChipGroupedChart/LinearChipGroupedChart.styled.js");var C=require("./PieChart.js");require("../HorizontalBarGraph/HorizontalGraph.js"),require("../StackedBarChart/StackedBarChart.js"),require("../VerticalBarGraph/VerticalGraph.js"),require("../heatmap/HeatMap.js"),require("../VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js"),require("../../../avatar/Avatar.js"),require("../../../avatar/AvatarHelper.js"),require("../../../alerts/Alert.styled.js"),require("../../../alerts/AlertHelper.js"),require("../../../thumbnail/Thumbnail.js"),require("../../../curtain/Curtain.styled.js"),require("../../../curtain/CurtainHelper.js"),require("../../../switch/Switch.js"),require("../../../plans/SubscriptionPlanStyled.js"),require("../../../plans/SubscriptionPlanSelector.js"),require("../../../tabs/Tabs.js"),require("../../../TablePagination/TablePagination.styled.js"),require("../../../TablePagination/TablePaginationCard.js"),require("../../../states/StateComponent.js"),require("../../../WhatsAppTextEditor/WhatsAppTextEditor.js"),require("../../../WhatsAppTextEditor/WhatsAppTextEditorHeader.js"),require("../../../card-selection-modal/CardSelectionModal.styled.js"),require("react-image-crop"),require("../../../buttonGroup/ButtonGroupStyle.js"),require("../../../accordion/Accordion.style.js"),require("../../../accordion/AccordionArrow.js"),require("../../../file-uploader/FileUploaderStyle.js"),require("../../../colourInput/ColourInput.styled.js"),require("../../../bik-layout/CommonStyles.js"),require("../../../bik-layout/SidebarStyles.js"),require("date-fns"),require("react-popper"),require("../../../dropdown/Common.styled.js"),require("../../../custom-date-time/CustomDateTime.styled.js"),require("../../../../node_modules/lodash.debounce/index.js"),require("../../../product-picker/ProductPicker.styled.js"),require("../../../discount-modal/type.js"),require("../../../discount-modal/DiscountModal.styled.js"),require("../../../discount-modal/DynamicCoupon/DynamicCoupon.js"),require("../../../discount-modal/CouponExpiration/CouponExpiration.js"),require("../../../country-code-picker/CountryCodePicker.styled.js"),require("../../../product-picker-v2/emptyState.js"),require("../../../product-picker-v2/style.js"),require("lodash"),require("../../../carousel/carousel.js"),require("../../../carousel-secondary/CarouselSecondary.style.js"),require("../../../access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.styles.js"),require("../../../radioList/RadioList.styled.js"),require("../../../checkList/CheckList.styled.js"),require("../../../postPicker/postPicker.js"),require("../../../dropdown-button/DropdownButton.style.js");var s=require("chart.js"),c=require("react-chartjs-2");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var A=o(e);s.Chart.register(s.ArcElement,s.Legend);const l={plugins:{legend:{display:!1},tooltip:{enabled:!0,callbacks:{label:e=>{if(!e.label)return" 0%";const r=e.dataset.data.reduce(((e,r)=>e+r),0),g=parseFloat((e.raw/r*100).toFixed(1));return` ${e.label}: ${g}%`}}}}},a=["#5E07BB","#9E77ED","#D2AEFF","#CDE1FF","#92AFFA","#3935E1"],d=A.default("div","production"===process.env.NODE_ENV?{target:"elaov7f0"}:{target:"elaov7f0",label:"CartStyled"})("background:",(e=>I.COLORS.surface.standard),";border:1px solid ",(e=>I.COLORS.stroke.primary),";border-radius:4px;"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFzQzhCIiwiZmlsZSI6IlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IGpzeCBhcyBfanN4LCBGcmFnbWVudCBhcyBfRnJhZ21lbnQsIGpzeHMgYXMgX2pzeHMgfSBmcm9tIFwicmVhY3QvanN4LXJ1bnRpbWVcIjtcclxuaW1wb3J0IHN0eWxlZCBmcm9tICdAZW1vdGlvbi9zdHlsZWQnO1xyXG5pbXBvcnQgeyBTdHJpbmdVdGlscyB9IGZyb20gXCIuLi8uLi8uLi8uLi9pbmRleFwiO1xyXG5pbXBvcnQgeyBBcmNFbGVtZW50LCBDaGFydCBhcyBDaGFydEpTLCBMZWdlbmQgfSBmcm9tICdjaGFydC5qcyc7XHJcbmltcG9ydCB7IHVzZUVmZmVjdCwgdXNlU3RhdGUgfSBmcm9tICdyZWFjdCc7XHJcbmltcG9ydCB7IERvdWdobnV0IH0gZnJvbSAncmVhY3QtY2hhcnRqcy0yJztcclxuaW1wb3J0IHsgVGl0bGVNZWRpdW0gfSBmcm9tIFwiLi4vLi4vLi4vVHlwb2dyYXBoeVN0eWxlXCI7XHJcbmltcG9ydCB7IENPTE9SUyB9IGZyb20gXCIuLi8uLi8uLi8uLi9jb25zdGFudHMvVGhlbWVcIjtcclxuaW1wb3J0IHsgUGllQ2hhcnQgfSBmcm9tICcuL1BpZUNoYXJ0JztcclxuQ2hhcnRKUy5yZWdpc3RlcihBcmNFbGVtZW50LCBMZWdlbmQpO1xyXG5jb25zdCBvcHRpb25zID0ge1xyXG4gICAgcGx1Z2luczoge1xyXG4gICAgICAgIGxlZ2VuZDoge1xyXG4gICAgICAgICAgICBkaXNwbGF5OiBmYWxzZSxcclxuICAgICAgICB9LFxyXG4gICAgICAgIHRvb2x0aXA6IHtcclxuICAgICAgICAgICAgZW5hYmxlZDogdHJ1ZSxcclxuICAgICAgICAgICAgY2FsbGJhY2tzOiB7XHJcbiAgICAgICAgICAgICAgICBsYWJlbDogKHRvb2x0aXBJdGVtKSA9PiB7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKCF0b29sdGlwSXRlbS5sYWJlbCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gYCAwJWA7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHRvdGFsID0gdG9vbHRpcEl0ZW0uZGF0YXNldC5kYXRhLnJlZHVjZSgoYWNjLCBjdXIpID0+IGFjYyArIGN1ciwgMCk7XHJcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgcGVyY2VudGFnZSA9IHBhcnNlRmxvYXQoKCh0b29sdGlwSXRlbS5yYXcgLyB0b3RhbCkgKiAxMDApLnRvRml4ZWQoMSkpO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBgICR7dG9vbHRpcEl0ZW0ubGFiZWx9OiAke3BlcmNlbnRhZ2V9JWA7XHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICB9LFxyXG4gICAgICAgIH0sXHJcbiAgICB9LFxyXG59O1xyXG5jb25zdCBHUkFQSF9DT0xPUlMgPSBbXHJcbiAgICAnIzVFMDdCQicsXHJcbiAgICAnIzlFNzdFRCcsXHJcbiAgICAnI0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BUEhfQ09MT1JTW2luZGV4ICUgR1JBUEhfQ09MT1JTLmxlbmd0aF0gfSwgc2xpY2VzW2tleV0pKSk7XHJcbiAgICAgICAgc2V0U2xpY2VzV2l0aENvbG9yKFsuLi51cGRhdGVkU2xpY2VzV2l0aENvbG9yXSk7XHJcbiAgICAgICAgaWYgKHRvdGFsU3VtID09PSAwKSB7XHJcbiAgICAgICAgICAgIGNvbnN0IGRhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBkYXRhc2V0czogW1xyXG4gICAgICAgICAgICAgICAgICAgIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgZGF0YTogWzEwMF0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogWycjRjBGMEYwJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiAwLFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZXREYXRhKGRhdGFTZXQpO1xyXG4gICAgICAgIH1cclxuICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgY29uc3QgZGF0YVNldCA9IHtcclxuICAgICAgICAgICAgICAgIGxhYmVsczogc2xpY2VzLm1hcCgoc2xpY2UpID0+IFN0cmluZ1V0aWxzLmNhcGl0YWxpemUoc2xpY2UubmFtZSkpLFxyXG4gICAgICAgICAgICAgICAgZGF0YXNldHM6IFtcclxuICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGE6IHNsaWNlcy5tYXAoKHNsaWNlKSA9PiBzbGljZS5jb3VudCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogc2xpY2VzLm1hcCgoc2xpY2UsIGluZGV4KSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHNsaWNlLmNvbG9yKSAhPT0gbnVsbCAmJiBfYSAhPT0gdm9pZCAwID8gX2EgOiBHUkFQSF9DT0xPUlNbaW5kZXggJSBHUkFQSF9DT0xPUlMubGVuZ3RoXTsgfSksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlckNvbG9yOiBbJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiA0LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJSYWRpdXM6IDgsXHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIF0sXHJcbiAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgIHNldERhdGEoZGF0YVNldCk7XHJcbiAgICAgICAgfVxyXG4gICAgfSwgW3NsaWNlc10pO1xyXG4gICAgaWYgKCFkYXRhKSB7XHJcbiAgICAgICAgcmV0dXJuIF9qc3goX0ZyYWdtZW50LCB7fSk7XHJcbiAgICB9XHJcbiAgICByZXR1cm4gKF9qc3hzKF9GcmFnbWVudCwgeyBjaGlsZHJlbjogW3RpdGxlICYmIChfanN4KFRpdGxlTWVkaXVtLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICBtYXJnaW5Cb3R0b206IDE2LFxyXG4gICAgICAgICAgICAgICAgfSB9LCB7IGNoaWxkcmVuOiB0aXRsZSB9KSkpLCBfanN4cyhcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgY2xhc3NOYW1lOiAncm93JyB9LCB7IGNoaWxkcmVuOiBbX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgY2xhc3NOYW1lOiAnY29sLTYnIH0sIHsgY2hpbGRyZW46IF9qc3goXCJkaXZcIiwgT2JqZWN0LmFzc2lnbih7IHN0eWxlOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgd2lkdGg6IHNpemUsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGVpZ2h0OiBzaXplLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9LCB7IGNoaWxkcmVuOiBfanN4KERvdWdobnV0LCB7IGRhdGE6IGRhdGEsIG9wdGlvbnM6IE9iamVjdC5hc3NpZ24oT2JqZWN0LmFzc2lnbih7fSwgb3B0aW9ucyksIHsgbWFpbnRhaW5Bc3BlY3RSYXRpbzogc2l6ZSA/IGZhbHNlIDogdHJ1ZSB9KSB9KSB9KSkgfSkpLCBfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdjb2wtNicsIHN0eWxlOiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBwYWRkaW5nTGVmdDogNDgsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBkaXNwbGF5OiAnZmxleCcsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBmbGV4RGlyZWN0aW9uOiAnY29sdW1uJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGp1c3RpZnlDb250ZW50OiAnY2VudGVyJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSB9LCB7IGNoaWxkcmVuOiBfanN4KFBpZUNoYXJ0LCB7IHNsaWNlczogc2xpY2VzV2l0aENvbG9yIH0pIH0pKV0gfSkpXSB9KSk7XHJcbn07XHJcbi8vIyBzb3VyY2VNYXBwaW5nVVJMPVBpZUNoYXJ0QW5hbHl0aWNzLmpzLm1hcCJdfQ== */"));exports.Card=e=>r.jsx(d,Object.assign({style:{padding:24}},{children:e.children})),exports.PieChartAnalytics=e=>{let{title:I,slices:s,size:o}=e;const[A,d]=t.useState([]),[u,n]=t.useState();return t.useEffect((()=>{const e=s.reduce(((e,r)=>e+r.count),0);let r=[];if(r=Object.keys(s).map(((e,r)=>Object.assign({color:a[r%a.length]},s[e]))),d([...r]),0===e){n({datasets:[{data:[100],backgroundColor:["#F0F0F0"],borderWidth:0}]})}else{const e={labels:s.map((e=>g.default.capitalize(e.name))),datasets:[{data:s.map((e=>e.count)),backgroundColor:s.map(((e,r)=>{var g;return null!==(g=e.color)&&void 0!==g?g:a[r%a.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};n(e)}}),[s]),u?r.jsxs(r.Fragment,{children:[I&&r.jsx(i.TitleMedium,Object.assign({style:{marginBottom:16}},{children:I})),r.jsxs("div",Object.assign({className:"row"},{children:[r.jsx("div",Object.assign({className:"col-6"},{children:r.jsx("div",Object.assign({style:{width:o,height:o}},{children:r.jsx(c.Doughnut,{data:u,options:Object.assign(Object.assign({},l),{maintainAspectRatio:!o})})}))})),r.jsx("div",Object.assign({className:"col-6",style:{paddingLeft:48,display:"flex",flexDirection:"column",justifyContent:"center"}},{children:r.jsx(C.PieChart,{slices:A})}))]}))]}):r.jsx(r.Fragment,{})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),s=require("./Avatar.styled.js"),r=require("./AvatarHelper.js"),t=require("../TypographyStyle.js"),i=require("../../constants/Theme.js");const A={[r.SIZE.SMALL]:16,[r.SIZE.MEDIUM]:20,[r.SIZE.LARGE]:32},o={[r.AVATAR_BACKGROUND.LIGHT]:i.COLORS.content.secondary,[r.AVATAR_BACKGROUND.DARK]:i.COLORS.surface.standard};exports.AVATAR_SIZE_VS_ICON_SIZE_MAP=A,exports.Avatar=i=>e.jsxs(s.AvatarStyle,Object.assign({size:i.size,background:i.background},{children:[i.type===r.AVATAR_TYPES.IMAGE&&e.jsx("img",{alt:"",width:r.AVATAR_SIZE_MAP[i.size],height:r.AVATAR_SIZE_MAP[i.size],style:{borderRadius:"50%"},src:i.photoUrl}),i.type===r.AVATAR_TYPES.INITIALS&&e.jsx("div",{children:(()=>{const s=(i.name||"").split(".").join(" ").split(" ").map((e=>e.charAt(0).toUpperCase())).slice(0,2).join("");return i.size===r.SIZE.SMALL?e.jsx(t.BodyTiny,Object.assign({style:{color:o[i.background]}},{children:s})):i.size===r.SIZE.MEDIUM?e.jsx(t.TitleSmall,Object.assign({style:{color:o[i.background]}},{children:s})):i.size===r.SIZE.LARGE?e.jsx(t.TitleMedium,Object.assign({style:{color:o[i.background]}},{children:s})):void 0})()}),i.type===r.AVATAR_TYPES.ICON&&i.icon&&e.jsx(i.icon,{width:A[i.size],height:A[i.size],color:o[i.background]})]})),exports.BACKGROUND_VS_TEXT_COLOR_MAP=o;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),s=require("./Avatar.styled.js"),r=require("./AvatarHelper.js"),t=require("../TypographyStyle.js"),i=require("../../constants/Theme.js");const A={[r.SIZE.SMALL]:16,[r.SIZE.MEDIUM]:20,[r.SIZE.LARGE]:32},o={[r.AVATAR_BACKGROUND.LIGHT]:i.COLORS.content.secondary,[r.AVATAR_BACKGROUND.DARK]:i.COLORS.surface.standard};exports.AVATAR_SIZE_VS_ICON_SIZE_MAP=A,exports.Avatar=i=>e.jsxs(s.AvatarStyle,Object.assign({type:i.type,size:i.size,background:i.background},{children:[i.type===r.AVATAR_TYPES.IMAGE&&e.jsx("img",{alt:"",width:r.AVATAR_SIZE_MAP[i.size],height:r.AVATAR_SIZE_MAP[i.size],style:{borderRadius:"50%"},src:i.photoUrl}),i.type===r.AVATAR_TYPES.INITIALS&&e.jsx("div",{children:(()=>{const s=(i.name||"").split(".").join(" ").split(" ").map((e=>e.charAt(0).toUpperCase())).slice(0,2).join("");return i.size===r.SIZE.SMALL?e.jsx(t.BodyTiny,Object.assign({style:{color:o[i.background]}},{children:s})):i.size===r.SIZE.MEDIUM?e.jsx(t.TitleSmall,Object.assign({style:{color:o[i.background]}},{children:s})):i.size===r.SIZE.LARGE?e.jsx(t.TitleMedium,Object.assign({style:{color:o[i.background]}},{children:s})):void 0})()}),i.type===r.AVATAR_TYPES.ICON&&i.icon&&e.jsx(i.icon,{width:A[i.size],height:A[i.size],color:o[i.background]})]})),exports.BACKGROUND_VS_TEXT_COLOR_MAP=o;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { AVATAR_BACKGROUND, SIZE } from "./AvatarHelper";
|
|
1
|
+
import { AVATAR_BACKGROUND, AVATAR_TYPES, SIZE } from "./AvatarHelper";
|
|
2
2
|
export declare const AvatarStyle: import("styled-components").StyledComponent<"div", any, {
|
|
3
3
|
size: SIZE;
|
|
4
4
|
background: AVATAR_BACKGROUND;
|
|
5
|
+
type: AVATAR_TYPES;
|
|
5
6
|
}, never>;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("styled-components"),r=require("./AvatarHelper.js"),t=require("../../constants/Theme.js");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("styled-components"),r=require("./AvatarHelper.js"),t=require("../../constants/Theme.js");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}const n=o(e).default.div`
|
|
2
2
|
width: ${e=>r.AVATAR_SIZE_MAP[e.size]+"px"};
|
|
3
3
|
height: ${e=>r.AVATAR_SIZE_MAP[e.size]+"px"};
|
|
4
4
|
display: flex;
|
|
5
5
|
justify-content: center;
|
|
6
6
|
align-items: center;
|
|
7
|
-
background-color: ${e=>e.background===r.AVATAR_BACKGROUND.LIGHT?t.COLORS.background.base:t.COLORS.background.inverse};
|
|
7
|
+
background-color: ${e=>e.type===r.AVATAR_TYPES.IMAGE?"null":e.background===r.AVATAR_BACKGROUND.LIGHT?t.COLORS.background.base:t.COLORS.background.inverse};
|
|
8
8
|
border: ${e=>e.background===r.AVATAR_BACKGROUND.LIGHT?"1px solid "+t.COLORS.stroke.primary:0};
|
|
9
9
|
border-radius: 50%;
|
|
10
|
-
`;exports.AvatarStyle=
|
|
10
|
+
`;exports.AvatarStyle=n;
|