@bikdotai/bik-component-library 0.0.639--beta0.8 → 0.0.639--beta1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (29) hide show
  1. package/dist/cjs/assets/icons/send.svg.js +1 -0
  2. package/dist/cjs/components/analytics-chips-and-dropdowns/AnalyticsTrend.js +1 -1
  3. package/dist/cjs/components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js +1 -1
  4. package/dist/cjs/components/bik-layout/MockMenus.d.ts +0 -1
  5. package/dist/cjs/components/dropdown/MenuItem/MenuItem.js +1 -1
  6. package/dist/cjs/components/template-context-mapper/TemplateContextMapper.js +1 -1
  7. package/dist/cjs/components/template-context-mapper/modalElements/TemplateAnalyticsComponent.d.ts +5 -7
  8. package/dist/cjs/components/template-context-mapper/modalElements/TemplateAnalyticsComponent.js +1 -1
  9. package/dist/cjs/components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.d.ts +2 -3
  10. package/dist/cjs/components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.js +1 -1
  11. package/dist/cjs/components/template-context-mapper/utils/TemplateConstants.js +1 -0
  12. package/dist/cjs/index.js +1 -1
  13. package/dist/esm/assets/icons/send.svg.js +1 -0
  14. package/dist/esm/components/analytics-chips-and-dropdowns/AnalyticsTrend.js +1 -1
  15. package/dist/esm/components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js +1 -1
  16. package/dist/esm/components/bik-layout/MockMenus.d.ts +0 -1
  17. package/dist/esm/components/dropdown/MenuItem/MenuItem.js +1 -1
  18. package/dist/esm/components/template-context-mapper/TemplateContextMapper.js +1 -1
  19. package/dist/esm/components/template-context-mapper/modalElements/TemplateAnalyticsComponent.d.ts +5 -7
  20. package/dist/esm/components/template-context-mapper/modalElements/TemplateAnalyticsComponent.js +1 -1
  21. package/dist/esm/components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.d.ts +2 -3
  22. package/dist/esm/components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.js +1 -1
  23. package/dist/esm/components/template-context-mapper/utils/TemplateConstants.js +1 -0
  24. package/dist/esm/index.js +1 -1
  25. package/package.json +1 -1
  26. package/dist/cjs/components/template-context-mapper/utils/SegmentConstants.js +0 -1
  27. package/dist/esm/components/template-context-mapper/utils/SegmentConstants.js +0 -1
  28. /package/dist/cjs/components/template-context-mapper/utils/{SegmentConstants.d.ts → TemplateConstants.d.ts} +0 -0
  29. /package/dist/esm/components/template-context-mapper/utils/{SegmentConstants.d.ts → TemplateConstants.d.ts} +0 -0
@@ -0,0 +1 @@
1
+ "use strict";function e(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(r){if("default"!==r){var a=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:function(){return e[r]}})}})),t.default=e,Object.freeze(t)}Object.defineProperty(exports,"__esModule",{value:!0});var t,r,a,l=e(require("react"));function n(){return n=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e},n.apply(this,arguments)}var c=e=>l.createElement("svg",n({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 40 40"},e),t||(t=l.createElement("circle",{cx:20,cy:20,r:20,fill:"currentColor"})),r||(r=l.createElement("path",{fill:"#731DCF",d:"M11.191 11.984a.8.8 0 0 0 .566-1.358l-2.4-2.401a.8.8 0 0 0-1.132 1.131l2.4 2.401c.152.148.355.23.566.227ZM8.848 15.993h1.543a.8.8 0 1 0 0-1.6H8.848a.8.8 0 1 0 0 1.6ZM15.193 11.193a.8.8 0 0 0 .8-.8V8.848a.8.8 0 0 0-1.6 0v1.543a.8.8 0 0 0 .8.8ZM8.79 22.39a.796.796 0 0 0 .566-.228l2.401-2.401a.8.8 0 0 0-1.131-1.132l-2.401 2.4a.804.804 0 0 0 .565 1.361ZM19.194 11.987a.796.796 0 0 0 .566-.23l2.401-2.4a.8.8 0 0 0-1.132-1.132l-2.4 2.4a.804.804 0 0 0 .565 1.362Z"})),a||(a=l.createElement("path",{stroke:"#731DCF",strokeWidth:1.714,d:"m14.71 14.702-.01.009a.847.847 0 0 0-.194.912l.002.006 5.696 14.952v.002a.876.876 0 0 0 .847.56h.005a.846.846 0 0 0 .79-.611l.002-.007 1.85-6.168a.981.981 0 0 1 .661-.658l6.165-1.85a.868.868 0 0 0 .06-1.643L15.63 14.509l-.006-.002a.85.85 0 0 0-.914.195Z"})));exports.default=c;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),n=require("../shimmer/ShimmerComponent/ShimmerStyled.js"),i=require("../../utils/DateUtils.js"),r=require("../../constants/Theme.js"),s=require("../../assets/icons/arrow_down.svg.js"),a=require("../../assets/icons/arrow_up.svg.js"),l=require("../../assets/icons/info.svg.js"),o=require("../tag/Tag.js"),c=require("../tooltips/Tooltip.js"),d=require("../TypographyStyle.js"),g=require("./chart/utils/calcPercentage.js"),u=require("./CommonStyles.js");function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var y=h(t);const m=n=>{let{percent:l,direction:o,timeline:c,customRange:u,trendRaw:h,prefixSymbol:y,trendIconStyle:m,isInternationalStore:p}=n;const j="negative"===o?s.default:a.default,x="negative"===o?r.COLORS.background.negative.vibrant:"positive"===o?r.COLORS.background.positive.vibrant:r.COLORS.content.placeholder,[b,f]=t.useState("");t.useEffect((()=>{f("today"===c?"vs yesterday":"yesterday"===c?"vs 1 day before":"7 days"===c?"vs last 7 days":"30 days"===c?"vs last 30 days":"custom"===c&&u?i.default.getAnalyticsCustomDateTimelineText(u):"")}),[c,u]);const S=e=>{let t;return t=p?g.truncateValueForInternationalStore(Math.abs(e)):g.truncateValueForIndianStore(Math.abs(e)),console.log("trendRawAbs",t),console.log("trendRaw",e),e<0?"-"+t:t},O=t.useRef((()=>{const e=((null!=h?h:0)>0?"+":"")+(null!=y?y:"");return void 0===h?"--":`${null!=e?e:""}${S(h)}`})());return e.jsxs("div",Object.assign({style:{display:"flex",alignItems:"center",flexDirection:"row",flexWrap:"wrap"}},{children:["number"==typeof l&&e.jsx(j,{color:x,height:16,width:16,style:Object.assign({marginRight:2},null!=m?m:{})}),"number"==typeof l&&o&&e.jsxs(d.Caption,Object.assign({style:{color:x}},{children:["neutral"===o?0:l<1e3?l:">999","%"]})),!!h&&e.jsx(d.Caption,Object.assign({style:{marginLeft:4,color:r.COLORS.content.placeholder}},{children:`(${O.current})`})),c&&e.jsx(d.Caption,Object.assign({style:{marginLeft:4,color:r.COLORS.content.placeholder}},{children:b}))]}))};exports.AnalyticsTrend=t=>{let{title:i,value:s,trendPercent:a,type:h="horizontal",timeline:p,customRange:j,tooltip:x,card:b=!0,rightSeparator:f=!1,size:S="big",share:O=!1,formatVal:v,prefixSymbol:C,trailingIcon:T,onTrailIconClick:R,iconTooltipBody:w,funnelPercent:I,isLoading:$,trendRaw:L,suffixText:q,trendStyle:D,trendContainerStyle:F,trendIconStyle:M,containerStyle:k,prevTrendDiff:P,relativePercentageDiff:V,isInternationalStore:z}=t;const A="big"===S?d.TitleLarge:d.TitleMedium,_=void 0!==a?a<0?"negative":0===a?"neutral":"positive":void 0,N=void 0!==a?O?Math.round(a):Math.abs(Math.round(a)):void 0;return e.jsx(u.AnalyticsTrendContainer,Object.assign({card:b,style:Object.assign({},k)},{children:e.jsxs("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"row",gap:4,borderRightWidth:f?1:0,borderRightColor:r.COLORS.stroke.primary,borderRightStyle:"solid",paddingLeft:b?0:24,paddingRight:b?0:24,height:"100%",justifyContent:"space-between",alignItems:"center"},null!=F?F:{})},{children:[e.jsxs("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"column",gap:4,height:"100%"},null!=D?D:{})},{children:[e.jsxs("div",Object.assign({style:{display:"flex",flexDirection:"row",gap:4,alignItems:"center"}},{children:[e.jsx(d.BodyCaption,Object.assign({style:{color:r.COLORS.content.secondary}},{children:i})),x&&e.jsx(c.Tooltip,Object.assign({body:x,placement:"right",width:300},{children:e.jsx("div",Object.assign({style:{display:"flex",cursor:"pointer",height:"100%"}},{children:e.jsx(l.default,{color:r.COLORS.content.primary,height:16,width:16})}))}))]})),e.jsxs("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"row",gap:12,alignItems:"center"},O?{justifyContent:"space-between"}:{})},{children:[$&&e.jsx(n.ShimmerComponentStyled,{width:108,height:26}),!$&&e.jsx(A,Object.assign({style:{color:r.COLORS.content.primary}},{children:void 0===s?"--":"number"==typeof s&&v?s>999?z?`${null!=C?C:""}${g.truncateValueForInternationalStore(s)} ${null!=q?q:""}`:`${null!=C?C:""}${g.truncateValueForIndianStore(s)} ${null!=q?q:""}`:`${null!=C?C:""}${new Intl.NumberFormat("en-IN",{maximumFractionDigits:2}).format(s)} ${null!=q?q:""}`:`${null!=C?C:""}${s} ${null!=q?q:""}`})),"number"==typeof V&&e.jsx(o.Tag,{tagText:`${V}%`,theme:"light",type:"neutral"}),"horizontal"===h&&!$&&!O&&e.jsx(m,{timeline:p,customRange:j,percent:N,direction:_,trendRaw:L,prefixSymbol:C,trendIconStyle:M,isInternationalStore:z}),$&&!O&&"horizontal"===h&&e.jsx(n.ShimmerComponentStyled,{height:20,width:141,marginTop:6}),"vertical"===h&&!$&&void 0!==I&&e.jsx(o.Tag,{tagText:`${I} %`,theme:"light",type:"neutral"}),O&&!$&&void 0!==N&&e.jsx(o.Tag,{tagText:`${N} %`,theme:"light",type:"neutral"}),O||$||!P||0==P?e.jsx(e.Fragment,{}):e.jsx(o.Tag,{tagText:(e=>{const t=Math.abs(e);return t%1!=0?`${t.toFixed(1)} %`:`${t} %`})(P),theme:"light",type:"neutral"})]})),"vertical"===h&&!$&&!O&&e.jsx("div",Object.assign({style:{marginTop:10}},{children:e.jsx(m,{timeline:p,customRange:j,percent:N,direction:_,trendRaw:L,prefixSymbol:C,trendIconStyle:M,isInternationalStore:z})})),$&&"vertical"===h&&e.jsx(n.ShimmerComponentStyled,{height:20,width:141,marginTop:6})]})),w&&!$&&e.jsx(c.Tooltip,Object.assign({body:w,placement:"right"},{children:T&&e.jsx("div",Object.assign({className:"icon--holder",onClick:R},{children:y.default.createElement(T,{height:20,width:20,color:r.COLORS.content.secondary})}))}))]}))}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),n=require("../shimmer/ShimmerComponent/ShimmerStyled.js"),i=require("../../utils/DateUtils.js"),r=require("../../constants/Theme.js"),s=require("../../assets/icons/arrow_down.svg.js"),a=require("../../assets/icons/arrow_up.svg.js"),l=require("../../assets/icons/info.svg.js"),o=require("../tag/Tag.js"),c=require("../tooltips/Tooltip.js"),d=require("../TypographyStyle.js"),g=require("./chart/utils/calcPercentage.js"),u=require("./CommonStyles.js");function h(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var y=h(t);const m=n=>{let{percent:l,direction:o,timeline:c,customRange:u,trendRaw:h,prefixSymbol:y,trendIconStyle:m,isInternationalStore:p}=n;const j="negative"===o?s.default:a.default,x="negative"===o?r.COLORS.background.negative.vibrant:"positive"===o?r.COLORS.background.positive.vibrant:r.COLORS.content.placeholder,[b,f]=t.useState("");t.useEffect((()=>{f("today"===c?"vs yesterday":"yesterday"===c?"vs 1 day before":"7 days"===c?"vs last 7 days":"30 days"===c?"vs last 30 days":"custom"===c&&u?i.default.getAnalyticsCustomDateTimelineText(u):"")}),[c,u]);const S=e=>{let t;return t=p?g.truncateValueForInternationalStore(Math.abs(e)):g.truncateValueForIndianStore(Math.abs(e)),e<0?"-"+t:t},O=t.useRef((()=>{const e=((null!=h?h:0)>0?"+":"")+(null!=y?y:"");return void 0===h?"--":`${null!=e?e:""}${S(h)}`})());return e.jsxs("div",Object.assign({style:{display:"flex",alignItems:"center",flexDirection:"row",flexWrap:"wrap"}},{children:["number"==typeof l&&e.jsx(j,{color:x,height:16,width:16,style:Object.assign({marginRight:2},null!=m?m:{})}),"number"==typeof l&&o&&e.jsxs(d.Caption,Object.assign({style:{color:x}},{children:["neutral"===o?0:l<1e3?l:">999","%"]})),!!h&&e.jsx(d.Caption,Object.assign({style:{marginLeft:4,color:r.COLORS.content.placeholder}},{children:`(${O.current})`})),c&&e.jsx(d.Caption,Object.assign({style:{marginLeft:4,color:r.COLORS.content.placeholder}},{children:b}))]}))};exports.AnalyticsTrend=t=>{let{title:i,value:s,trendPercent:a,type:h="horizontal",timeline:p,customRange:j,tooltip:x,card:b=!0,rightSeparator:f=!1,size:S="big",share:O=!1,formatVal:v,prefixSymbol:C,trailingIcon:T,onTrailIconClick:R,iconTooltipBody:w,funnelPercent:I,isLoading:$,trendRaw:L,suffixText:q,trendStyle:D,trendContainerStyle:F,trendIconStyle:M,containerStyle:k,prevTrendDiff:P,relativePercentageDiff:V,isInternationalStore:z}=t;const _="big"===S?d.TitleLarge:d.TitleMedium,A=void 0!==a?a<0?"negative":0===a?"neutral":"positive":void 0,N=void 0!==a?O?Math.round(a):Math.abs(Math.round(a)):void 0;return e.jsx(u.AnalyticsTrendContainer,Object.assign({card:b,style:Object.assign({},k)},{children:e.jsxs("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"row",gap:4,borderRightWidth:f?1:0,borderRightColor:r.COLORS.stroke.primary,borderRightStyle:"solid",paddingLeft:b?0:24,paddingRight:b?0:24,height:"100%",justifyContent:"space-between",alignItems:"center"},null!=F?F:{})},{children:[e.jsxs("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"column",gap:4,height:"100%"},null!=D?D:{})},{children:[e.jsxs("div",Object.assign({style:{display:"flex",flexDirection:"row",gap:4,alignItems:"center"}},{children:[e.jsx(d.BodyCaption,Object.assign({style:{color:r.COLORS.content.secondary}},{children:i})),x&&e.jsx(c.Tooltip,Object.assign({body:x,placement:"right",width:300},{children:e.jsx("div",Object.assign({style:{display:"flex",cursor:"pointer",height:"100%"}},{children:e.jsx(l.default,{color:r.COLORS.content.primary,height:16,width:16})}))}))]})),e.jsxs("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"row",gap:12,alignItems:"center"},O?{justifyContent:"space-between"}:{})},{children:[$&&e.jsx(n.ShimmerComponentStyled,{width:108,height:26}),!$&&e.jsx(_,Object.assign({style:{color:r.COLORS.content.primary}},{children:void 0===s?"--":"number"==typeof s&&v?s>999?z?`${null!=C?C:""}${g.truncateValueForInternationalStore(s)} ${null!=q?q:""}`:`${null!=C?C:""}${g.truncateValueForIndianStore(s)} ${null!=q?q:""}`:`${null!=C?C:""}${new Intl.NumberFormat("en-IN",{maximumFractionDigits:2}).format(s)} ${null!=q?q:""}`:`${null!=C?C:""}${s} ${null!=q?q:""}`})),"number"==typeof V&&e.jsx(o.Tag,{tagText:`${V}%`,theme:"light",type:"neutral"}),"horizontal"===h&&!$&&!O&&e.jsx(m,{timeline:p,customRange:j,percent:N,direction:A,trendRaw:L,prefixSymbol:C,trendIconStyle:M,isInternationalStore:z}),$&&!O&&"horizontal"===h&&e.jsx(n.ShimmerComponentStyled,{height:20,width:141,marginTop:6}),"vertical"===h&&!$&&void 0!==I&&e.jsx(o.Tag,{tagText:`${I} %`,theme:"light",type:"neutral"}),O&&!$&&void 0!==N&&e.jsx(o.Tag,{tagText:`${N} %`,theme:"light",type:"neutral"}),O||$||!P||0==P?e.jsx(e.Fragment,{}):e.jsx(o.Tag,{tagText:(e=>{const t=Math.abs(e);return t%1!=0?`${t.toFixed(1)} %`:`${t} %`})(P),theme:"light",type:"neutral"})]})),"vertical"===h&&!$&&!O&&e.jsx("div",Object.assign({style:{marginTop:10}},{children:e.jsx(m,{timeline:p,customRange:j,percent:N,direction:A,trendRaw:L,prefixSymbol:C,trendIconStyle:M,isInternationalStore:z})})),$&&"vertical"===h&&e.jsx(n.ShimmerComponentStyled,{height:20,width:141,marginTop:6})]})),w&&!$&&e.jsx(c.Tooltip,Object.assign({body:w,placement:"right"},{children:T&&e.jsx("div",Object.assign({className:"icon--holder",onClick:R},{children:y.default.createElement(T,{height:20,width:20,color:r.COLORS.content.secondary})}))}))]}))}))};
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@emotion/styled/base"),g=require("react/jsx-runtime"),I=require("../../../../assets/icons/ChartBar.svg.js"),C=require("../../../../assets/icons/maximize.svg.js");require("@amplitude/analytics-browser"),require("../../../../amplitude/model.js");var A=require("../../../../utils/StringUtils.js"),r=require("../../../../constants/Theme.js");require("../../../../constants/zindex.js");var i=require("react");require("../../../checkBox/CheckBox.styled.js");var s=require("../../../TypographyStyle.js");require("../../../list-item/ListItem.js"),require("../../../pagination/Pagination.js"),require("../../../radioButton/RadioButton.styled.js"),require("react-dom"),require("react-toastify"),require("../../../button/Button.js"),require("../../../toaster/Toaster.styled.js"),require("../../../tooltips/Tooltip.js"),require("../../../spinner/Spinner.js"),require("../../../stepper/Stepper.styled.js"),require("../../../tag/Tag.js");var l=require("../../../icon-button/IconButton.js");require("../../../template-preview/TemplatePreview.js"),require("../../../template-preview/WhatsApp/WhatsAppLikePreview.js"),require("../../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js"),require("../../../curtain/CurtainHelper.js"),require("../../../variable-picker-v3/model.js"),require("../../../template-preview/models/TemplateMeta.js"),require("../../../template-preview/models/WhatsAppTemplate.js"),require("../../../template-preview/models/Channels.js"),require("lodash");var t=require("../../../modals/styledModal.js");require("../../../template-context-mapper/context/templateModalContext.js"),require("../../../template-context-mapper/modalElements/Footer.js"),require("../../../template-context-mapper/styles/TemplateAnalyticsStyles.js"),require("../../../template-context-mapper/utils/SegmentConstants.js"),require("../../../shimmer/ShimmerComponent/ShimmerStyled.js"),require("../../../template-context-mapper/modalElements/Body.js"),require("../../../template-context-mapper/modalElements/Header.js"),require("../../../../_virtual/_tslib.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/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("../../../progress-bar-v2/ProgressBarV2.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("../../../datePicker/DatePickerWrapper.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/ChipDropdown.js"),require("../../../dropdown/MenuItem/MenuItem.js"),require("../../../analytics-card/AnalyticsCard.styled.js"),require("../../CommonStyles.js"),require("react-calendar"),require("../../../datePicker/DatePicker.styled.js"),require("../../AnalyticsMetric.js"),require("../../../../utils/DateUtils.js"),require("../utils/calcPercentage.js"),require("../LineChart/LineChart.js"),require("../linearChipGroupedChart/LinearChipGroupedChart.styled.js");var c=require("./PieChart.js");require("../HorizontalBarGraph/HorizontalGraph.js"),require("../StackedBarChart/StackedBarChart.js"),require("../StackedBarChart/StackedBarDistributionChart.js"),require("../StackedBarChart/StackedBarDistributionChart.model.js");var a=require("../VerticalBarGraph/VerticalGraph.js");require("../VerticalBarGraph/FunnelVerticalBarGraph.js"),require("../heatmap/HeatMap.js"),require("../heatmap/HeatMapVertical.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("../../../switch/Switch.js"),require("../../../plans/SubscriptionPlanStyled.js"),require("../../../plans/SubscriptionPlanSelector.js"),require("../../../plans/SubscriptionPlansCollected.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("../../../navigation-hyperlink/NavigationHyperlink.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("../../../product-picker-v2/modal.js"),require("../../../modals/modal.styled.js"),require("../../../variable-picker-v3/NoResult.js"),require("../../../variable-picker-v3/styles.js"),require("../../../discount-modal/DiscountModal.styled.js"),require("../../../discount-modal/DynamicCoupon/DynamicCoupon.js"),require("../../../country-code-picker/CountryCodePicker.styled.js"),require("../../../carousel/carousel.js"),require("../../../carousel-secondary/CarouselSecondary.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"),require("../../../side-modal/SideModal.style.js"),require("../../../add-variableV2/AddVariableV2.styled.js"),require("../../../SearchFilter/types/SearchFilter.type.js"),require("../../../SearchFilter/components/DatePickerButton.js"),require("../../../SearchFilter/components/DateRangeOnlyButton.js"),require("../../../input-with-vars/InputWithVariables.js"),require("../../../star-rating/StarRating.js"),require("../../../dashboard-review-popup/components/FiveStar.styled.js"),require("../../../dashboard-review-popup/components/Form.styled.js"),require("../../../dashboard-review-popup/components/ZeroState.js"),require("../../../dashboard-review-popup/DashboardReviewPopUp.styled.js"),require("../../../testimonial-card/TestimonialCard.style.js"),require("../../../slider/slider.js"),require("react-slick"),require("../../../carousel-preview/CarouselPreview.style.js"),require("../../../card-selector/CardSelector.styled.js"),require("../../../action-button/ActionButton.styled.js"),require("../../../floating-input-dropdown/FloatingInputDropdown.js"),require("../../../dropdown/MultilevelDropdownPopover/index.js"),require("../../../multi-level-dropdown/MultiLevelDropdown.styled.js");var o=require("chart.js"),d=require("react-chartjs-2");function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var u=n(e);o.Chart.register(o.ArcElement,o.Legend);const p={plugins:{legend:{display:!1},tooltip:{enabled:!0,callbacks:{label:e=>{if(!e.label)return" 0%";const g=e.dataset.data.reduce(((e,g)=>e+g),0),I=parseFloat((e.raw/g*100).toFixed(1));return[` ${e.label}`,` ${e.raw} (${I}% of ${g})`]}}}}},b=["#5E07BB","#9E77ED","#D2AEFF","#CDE1FF","#92AFFA","#3935E1"],G=u.default("div","production"===process.env.NODE_ENV?{target:"elaov7f0"}:{target:"elaov7f0",label:"CartStyled"})("background:",(e=>r.COLORS.surface.standard),";border:1px solid ",(e=>r.COLORS.stroke.primary),";border-radius:4px;"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFnRThCIiwiZmlsZSI6IlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IGpzeCBhcyBfanN4LCBGcmFnbWVudCBhcyBfRnJhZ21lbnQsIGpzeHMgYXMgX2pzeHMgfSBmcm9tIFwicmVhY3QvanN4LXJ1bnRpbWVcIjtcclxuaW1wb3J0IHN0eWxlZCBmcm9tICdAZW1vdGlvbi9zdHlsZWQnO1xyXG5pbXBvcnQgQmFyQ2hhcnRJY29uIGZyb20gJ0BzcmMvYXNzZXRzL2ljb25zL0NoYXJ0QmFyLnN2Zyc7XHJcbmltcG9ydCBNYXhpbWl6ZUljb24gZnJvbSAnQHNyYy9hc3NldHMvaWNvbnMvbWF4aW1pemUuc3ZnJztcclxuaW1wb3J0IHsgU3RyaW5nVXRpbHMgfSBmcm9tIFwiLi4vLi4vLi4vLi4vaW5kZXhcIjtcclxuaW1wb3J0IHsgQXJjRWxlbWVudCwgQ2hhcnQgYXMgQ2hhcnRKUywgTGVnZW5kIH0gZnJvbSAnY2hhcnQuanMnO1xyXG5pbXBvcnQgeyB1c2VFZmZlY3QsIHVzZVN0YXRlIH0gZnJvbSAncmVhY3QnO1xyXG5pbXBvcnQgeyBEb3VnaG51dCB9IGZyb20gJ3J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xlICE9PSBudWxsICYmIHlBeGlzVGl0bGUgIT09IHZvaWQgMCA/IHlBeGlzVGl0bGUgOiAnJyxcclxuICAgIH07XHJcbiAgICBjb25zdCBiYXJDaGFydERhdGEgPSB7XHJcbiAgICAgICAgeEF4aXMsXHJcbiAgICAgICAgeUF4aXMsXHJcbiAgICAgICAgYmFyQ29sb3JSR0JBOiB7IHI6IDIxMCwgZzogMTc0LCBiOiAyNTUsIGE6IDEgfSxcclxuICAgIH07XHJcbiAgICByZXR1cm4gYmFyQ2hhcnREYXRhO1xyXG59O1xyXG5jb25zdCBvcHRpb25zID0ge1xyXG4gICAgcGx1Z2luczoge1xyXG4gICAgICAgIGxlZ2VuZDoge1xyXG4gICAgICAgICAgICBkaXNwbGF5OiBmYWxzZSxcclxuICAgICAgICB9LFxyXG4gICAgICAgIHRvb2x0aXA6IHtcclxuICAgICAgICAgICAgZW5hYmxlZDogdHJ1ZSxcclxuICAgICAgICAgICAgY2FsbGJhY2tzOiB7XHJcbiAgICAgICAgICAgICAgICBsYWJlbDogKHRvb2x0aXBJdGVtKSA9PiB7XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKCF0b29sdGlwSXRlbS5sYWJlbCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gYCAwJWA7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHRvdGFsID0gdG9vbHRpcEl0ZW0uZGF0YXNldC5kYXRhLnJlZHVjZSgoYWNjLCBjdXIpID0+IGFjYyArIGN1ciwgMCk7XHJcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgcGVyY2VudGFnZSA9IHBhcnNlRmxvYXQoKCh0b29sdGlwSXRlbS5yYXcgLyB0b3RhbCkgKiAxMDApLnRvRml4ZWQoMSkpO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBbXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGAgJHt0b29sdGlwSXRlbS5sY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2l0aENvbG9yXSk7XHJcbiAgICAgICAgaWYgKHRvdGFsU3VtID09PSAwKSB7XHJcbiAgICAgICAgICAgIGNvbnN0IGRhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBkYXRhc2V0czogW1xyXG4gICAgICAgICAgICAgICAgICAgIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgZGF0YTogWzEwMF0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogWycjRjBGMEYwJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiAwLFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZXREYXRhKGRhdGFTZXQpO1xyXG4gICAgICAgIH1cclxuICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgY29uc3QgZGF0YVNldCA9IHtcclxuICAgICAgICAgICAgICAgIGxhYmVsczogc2xpY2VzLm1hcCgoc2xpY2UpID0+IFN0cmluZ1V0aWxzLmNhcGl0YWxpemUoc2xpY2UubmFtZSkpLFxyXG4gICAgICAgICAgICAgICAgZGF0YXNldHM6IFtcclxuICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGE6IHNsaWNlcy5tYXAoKHNsaWNlKSA9PiBzbGljZS5jb3VudCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogc2xpY2VzLm1hcCgoc2xpY2UsIGluZGV4KSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHNsaWNlLmNvbG9yKSAhPT0gbnVsbCAmJiBfYSAhPT0gdm9pZCAwID8gX2EgOiBHUkFQSF9DT0xPUlNbaW5kZXggJSBHUkFQSF9DT0xPUlMubGVuZ3RoXTsgfSksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlckNvbG9yOiBbJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiA0LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJSYWRpdXM6IDgsXHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIF0sXHJcbiAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgIHNldERhdGEoZGF0YVNldCk7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGlmICh0cnVuY2F0ZVNsaWNlcyAmJiBzbGljZXMubGVuZ3RoID4gdHJ1bmNhdGVTbGljZXMpIHtcclxuICAgICAgICAgICAgY29uc3QgdHJ1bmNhdGVkU2xpY2VzID0gc2xpY2VzLnNsaWNlKDAsIHRydW5jYXRlU2xpY2VzKTtcclxuICAgICAgICAgICAgY29uc3Qgb3RoZXJTbGljZXMgPSBzbGljZXMuc2xpY2UodHJ1bmNhdGVTbGljZXMpO1xyXG4gICAgICAgICAgICBjb25zdCBvdGhlckNvdW50ID0gb3RoZXJTbGljZXMucmVkdWNlKChzdW0sIHNsaWNlKSA9PiBzdW0gKyBzbGljZS5jb3VudCwgMCk7XHJcbiAgICAgICAgICAgIHRydW5jYXRlZFNsaWNlcy5wdXNoKHsgbmFtZTogJ090aGVyJywgY291bnQ6IG90aGVyQ291bnQgfSk7XHJcbiAgICAgICAgICAgIGNvbnN0IHRydW5jYXRlZERhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBsYWJlbHM6IHRydW5jYXRlZFNsaWNlcy5tYXAoKHNsaWNlKSA9PiBTdHJpbmdVdGlscy5jYXBpdGFsaXplKHNsaWNlLm5hbWUpKSxcclxuICAgICAgICAgICAgICAgIGRhdGFzZXRzOiBbXHJcbiAgICAgICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBkYXRhOiB0cnVuY2F0ZWRTbGljZXMubWFwKChzbGljZSkgPT4gc2xpY2UuY291bnQpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBiYWNrZ3JvdW5kQ29sb3I6IHRydW5jYXRlZFNsaWNlcy5tYXAoKHNsaWNlLCBpbmRleCkgPT4geyB2YXIgX2E7IHJldHVybiAoX2EgPSBzbGljZS5jb2xvcikgIT09IG51bGwgJiYgX2EgIT09IHZvaWQgMCA/IF9hIDogR1JBUEhfQ09MT1JTW2luZGV4ICUgR1JBUEhfQ09MT1JTLmxlbmd0aF07IH0pLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJDb2xvcjogWyd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZSddLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJXaWR0aDogNCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgYm9yZGVyUmFkaXVzOiA4LFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZXRUcnVuY2F0ZWREYXRhKHRydW5jYXRlZERhdGFTZXQpO1xyXG4gICAgICAgICAgICBjb25zdCB0cnVuY2F0ZWRTbGljZXNXaXRoQ29sb3IgPSB0cnVuY2F0ZWRTbGljZXMubWFwKChzbGljZSwgaW5kZXgpID0+IChPYmplY3QuYXNzaWduKHsgY29sb3I6IEdSQVBIX0NPTE9SU1tpbmRleCAlIEdSQVBIX0NPTE9SUy5sZW5ndGhdIH0sIHNsaWNlKSkpO1xyXG4gICAgICAgICAgICBzZXRUcnVuY2F0ZWRTbGljZXNXaXRoQ29sb3IodHJ1bmNhdGVkU2xpY2VzV2l0aENvbG9yKTtcclxuICAgICAgICB9XHJcbiAgICAgICAgaWYgKHNob3dDb252ZXJ0VG9CYXJDaGFydCkge1xyXG4gICAgICAgICAgICBzZXRCYXJDaGFyd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hhcnQodHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9KSksIGFsbG93Q2hhcnRQb3B1cCAmJiAoX2pzeChJY29uQnV0dG9uLCB7IEljb246IE1heGltaXplSWNvbiwgb25DbGljazogKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXRTaG93UG9wdXAodHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9KSldIH0pXSB9KSksIF9qc3hzKFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdyb3cnIH0sIHsgY2hpbGRyZW46IFtfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdjb2wtNicgfSwgeyBjaGlsZHJlbjogX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogc2l6ZSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6IHNpemUsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IF9qc3goRG91Z2hudXQsIHsgZGF0YTogKHRydW5jYXRlU2xpY2VzID8gdHJ1bmNhdGVkRGF0YSA6IGRhdGEpLCBvcHRpb25zOiBPYmplY3QuYXNzaWduKE9iamVjdC5hc3NpZ24oe30sIG9wdGlvbnMpLCB7IG1haW50YWluQXNwZWN0UmF0aW86IHNpemUgPyBmYWxzZSA6IHRydWUgfSkgfSkgfSkpIH0pKSwgX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgY2xhc3NOYW1lOiAnY29sLTYnLCBzdHlsZToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcGFkZGluZ0xlZnQ6IDQ4LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZmxleERpcmVjdGlvbjogJ2NvbHVtbicsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBqdXN0aWZ5Q29udGVudDogJ2NlbnRlcicsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gfSwgeyBjaGlsZHJlbjogX2pzeChQaWVDaGFydCwgeyBzbGljZXM6IHRydW5jYXRlU2xpY2VzID8gdHJ1bmNhdGVkU2xpY2VzV2l0aENvbG9yIDogc2xpY2VzV2l0aENvbG9yIH0pIH0pKV0gfSkpLCBzaG93UG9wdXAgJiYgKF9qc3goU3R5bGVkTW9kYWwsIE9iamVjdC5hc3NpZ24oeyBvcGVuOiBzaG93UG9wdXAsIG9uQ2xvc2U6ICgpID0+IHNldFNob3dQb3B1cChmYWxzZSksIGNsb3NlT25PdXRzaWRlQ2xpY2s6IHRydWUsIGhlYWRpbmdUaXRsZTogdGl0bGUsIHdpZHRoOiBcIjc1JVwiIH0sIHsgY2hpbGRyZW46IF9qc3hzKFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBwYWRkaW5nOiAyNCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBqdXN0aWZ5Q29udGVudDogJ3NwYWNlLWJldHdlZW4nLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6ICc4MHZoJyxcclxuICAgICAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IFtfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZTogeyB3aWR0aDogJzU1JScsIG1hcmdpbkxlZnQ6ICc0JScgfSB9LCB7IGNoaWxkcmVuOiBfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogJzEwMCUnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6ICcxMDAlJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhbGlnbkl0ZW1zOiAnY2VudGVyJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAganVzdGlmeUNvbnRlbnQ6ICdjZW50ZXInLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gfSwgeyBjaGlsZHJlbjogX2pzeChEb3VnaG51dCwgeyBkYXRhOiBkYXRhLCBvcHRpb25zOiBPYmplY3QuYXNzaWduKE9iamVjdC5hc3NpZ24oe30sIG9wdGlvbnMpLCB7IG1haW50YWluQXNwZWN0UmF0aW86IHNpemUgPyBmYWxzZSA6IHRydWUgfSkgfSkgfSkpIH0pKSwgX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogJzMwJScsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGVpZ2h0OiAnMTAwJScsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgb3ZlcmZsb3dZOiAnYXV0bycsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IF9qc3goUGllQ2hhcnQsIHsgc2xpY2VzOiBzbGljZXNXaXRoQ29sb3IgfSkgfSkpXSB9KSkgfSkpKSwgc2hvd0JhckNoYXJ0ICYmIGJhckNoYXJ0RGF0YSAmJiAoX2pzeChTdHlsZWRNb2RhbCwgT2JqZWN0LmFzc2lnbih7IG9wZW46IHNob3dCYXJDaGFydCwgb25DbG9zZTogKCkgPT4gc2V0U2hvd0JhckNoYXJ0KGZhbHNlKSwgY2xvc2VPbk91dHNpZGVDbGljazogdHJ1ZSwgaGVhZGluZ1RpdGxlOiB0aXRsZSwgd2lkdGg6IFwiODUlXCIgfSwgeyBjaGlsZHJlbjogX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcGFkZGluZzogJzI0cHggMCcsXHJcbiAgICAgICAgICAgICAgICAgICAgfSB9LCB7IGNoaWxkcmVuOiBfanN4KFZlcnRpY2FsR3JhcGgsIHsgeEF4aXM6IGJhckNoYXJ0RGF0YS54QXhpcywgeUF4aXM6IGJhckNoYXJ0RGF0YS55QXhpcywgYmFyQ29sb3JSR0JBOiBiYXJDaGFydERhdGEgPT09IG51bGwgfHwgYmFyQ2hhcnREYXRhID09PSB2b2lkIDAgPyB2b2lkIDAgOiBiYXJDaGFydERhdGEuYmFyQ29sb3JSR0JBIH0pIH0pKSB9KSkpXSB9KSk7XHJcbn07XHJcbi8vIyBzb3VyY2VNYXBwaW5nVVJMPVBpZUNoYXJ0QW5hbHl0aWNzLmpzLm1hcCJdfQ== */"));exports.Card=e=>g.jsx(G,Object.assign({style:{padding:24}},{children:e.children})),exports.PieChartAnalytics=e=>{let{title:r,slices:o,size:n,allowChartPopup:u,showConvertToBarChart:G,truncateSlices:X,barChartXAxisTitle:y,barChartYAxisTitle:h,hideTitle:B=!1}=e;const[m,j]=i.useState(!1),[x,Z]=i.useState(!1),[R,H]=i.useState([]),[Y,J]=i.useState(),[N,S]=i.useState(),[W,F]=i.useState([]),[V,w]=i.useState(null);return i.useEffect((()=>{const e=o.reduce(((e,g)=>e+g.count),0);let g=[];if(g=Object.keys(o).map(((e,g)=>Object.assign({color:b[g%b.length]},o[e]))),H([...g]),0===e){J({datasets:[{data:[100],backgroundColor:["#F0F0F0"],borderWidth:0}]})}else{const e={labels:o.map((e=>A.default.capitalize(e.name))),datasets:[{data:o.map((e=>e.count)),backgroundColor:o.map(((e,g)=>{var I;return null!==(I=e.color)&&void 0!==I?I:b[g%b.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};J(e)}if(X&&o.length>X){const e=o.slice(0,X),g=o.slice(X).reduce(((e,g)=>e+g.count),0);e.push({name:"Other",count:g});const I={labels:e.map((e=>A.default.capitalize(e.name))),datasets:[{data:e.map((e=>e.count)),backgroundColor:e.map(((e,g)=>{var I;return null!==(I=e.color)&&void 0!==I?I:b[g%b.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};S(I);const C=e.map(((e,g)=>Object.assign({color:b[g%b.length]},e)));F(C)}G&&w(((e,g,I)=>({xAxis:{data:e.map((e=>e.name)),title:null!=g?g:""},yAxis:{data:e.map((e=>e.count)),title:null!=I?I:""},barColorRGBA:{r:210,g:174,b:255,a:1}}))(o,y,h))}),[o,X]),Y?g.jsxs(g.Fragment,{children:[g.jsxs("div",Object.assign({style:{display:"flex",justifyContent:B||0===(null==r?void 0:r.length)?"flex-end":"space-between"}},{children:[!B&&r&&g.jsx(s.TitleMedium,Object.assign({style:{marginBottom:16}},{children:r})),g.jsxs("div",{children:[G&&g.jsx(l.IconButton,{Icon:I.default,onClick:()=>{Z(!0)}}),u&&g.jsx(l.IconButton,{Icon:C.default,onClick:()=>{j(!0)}})]})]})),g.jsxs("div",Object.assign({className:"row"},{children:[g.jsx("div",Object.assign({className:"col-6"},{children:g.jsx("div",Object.assign({style:{width:n,height:n}},{children:g.jsx(d.Doughnut,{data:X?N:Y,options:Object.assign(Object.assign({},p),{maintainAspectRatio:!n})})}))})),g.jsx("div",Object.assign({className:"col-6",style:{paddingLeft:48,display:"flex",flexDirection:"column",justifyContent:"center"}},{children:g.jsx(c.PieChart,{slices:X?W:R})}))]})),m&&g.jsx(t.StyledModal,Object.assign({open:m,onClose:()=>j(!1),closeOnOutsideClick:!0,headingTitle:r,width:"75%"},{children:g.jsxs("div",Object.assign({style:{padding:24,display:"flex",justifyContent:"space-between",height:"80vh"}},{children:[g.jsx("div",Object.assign({style:{width:"55%",marginLeft:"4%"}},{children:g.jsx("div",Object.assign({style:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"}},{children:g.jsx(d.Doughnut,{data:Y,options:Object.assign(Object.assign({},p),{maintainAspectRatio:!n})})}))})),g.jsx("div",Object.assign({style:{width:"30%",height:"100%",overflowY:"auto"}},{children:g.jsx(c.PieChart,{slices:R})}))]}))})),x&&V&&g.jsx(t.StyledModal,Object.assign({open:x,onClose:()=>Z(!1),closeOnOutsideClick:!0,headingTitle:r,width:"85%"},{children:g.jsx("div",Object.assign({style:{padding:"24px 0"}},{children:g.jsx(a.VerticalGraph,{xAxis:V.xAxis,yAxis:V.yAxis,barColorRGBA:null==V?void 0:V.barColorRGBA})}))}))]}):g.jsx(g.Fragment,{})};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@emotion/styled/base"),g=require("react/jsx-runtime"),I=require("../../../../assets/icons/ChartBar.svg.js"),C=require("../../../../assets/icons/maximize.svg.js");require("@amplitude/analytics-browser"),require("../../../../amplitude/model.js");var A=require("../../../../utils/StringUtils.js"),r=require("../../../../constants/Theme.js");require("../../../../constants/zindex.js");var i=require("react");require("../../../checkBox/CheckBox.styled.js");var l=require("../../../TypographyStyle.js");require("../../../list-item/ListItem.js"),require("../../../pagination/Pagination.js"),require("../../../radioButton/RadioButton.styled.js"),require("react-dom"),require("react-toastify"),require("../../../button/Button.js"),require("../../../toaster/Toaster.styled.js"),require("../../../tooltips/Tooltip.js"),require("../../../spinner/Spinner.js"),require("../../../stepper/Stepper.styled.js"),require("../../../tag/Tag.js");var s=require("../../../icon-button/IconButton.js");require("../../../template-preview/TemplatePreview.js"),require("../../../template-preview/WhatsApp/WhatsAppLikePreview.js"),require("../../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js"),require("../../../curtain/CurtainHelper.js"),require("../../../variable-picker-v3/model.js"),require("../../../template-preview/models/TemplateMeta.js"),require("../../../template-preview/models/WhatsAppTemplate.js"),require("../../../template-preview/models/Channels.js"),require("lodash");var t=require("../../../modals/styledModal.js");require("../../../template-context-mapper/context/templateModalContext.js"),require("../../../template-context-mapper/modalElements/Footer.js"),require("../../../template-context-mapper/styles/TemplateAnalyticsStyles.js"),require("../../../template-context-mapper/utils/TemplateConstants.js"),require("../../../shimmer/ShimmerComponent/ShimmerStyled.js"),require("../../../template-context-mapper/modalElements/Body.js"),require("../../../template-context-mapper/modalElements/Header.js"),require("../../../../_virtual/_tslib.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/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("../../../progress-bar-v2/ProgressBarV2.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("../../../datePicker/DatePickerWrapper.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/ChipDropdown.js"),require("../../../dropdown/MenuItem/MenuItem.js"),require("../../../analytics-card/AnalyticsCard.styled.js"),require("../../CommonStyles.js"),require("react-calendar"),require("../../../datePicker/DatePicker.styled.js"),require("../../AnalyticsMetric.js"),require("../../../../utils/DateUtils.js"),require("../utils/calcPercentage.js"),require("../LineChart/LineChart.js"),require("../linearChipGroupedChart/LinearChipGroupedChart.styled.js");var c=require("./PieChart.js");require("../HorizontalBarGraph/HorizontalGraph.js"),require("../StackedBarChart/StackedBarChart.js"),require("../StackedBarChart/StackedBarDistributionChart.js"),require("../StackedBarChart/StackedBarDistributionChart.model.js");var a=require("../VerticalBarGraph/VerticalGraph.js");require("../VerticalBarGraph/FunnelVerticalBarGraph.js"),require("../heatmap/HeatMap.js"),require("../heatmap/HeatMapVertical.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("../../../switch/Switch.js"),require("../../../plans/SubscriptionPlanStyled.js"),require("../../../plans/SubscriptionPlanSelector.js"),require("../../../plans/SubscriptionPlansCollected.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("../../../navigation-hyperlink/NavigationHyperlink.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("../../../product-picker-v2/modal.js"),require("../../../modals/modal.styled.js"),require("../../../variable-picker-v3/NoResult.js"),require("../../../variable-picker-v3/styles.js"),require("../../../discount-modal/DiscountModal.styled.js"),require("../../../discount-modal/DynamicCoupon/DynamicCoupon.js"),require("../../../country-code-picker/CountryCodePicker.styled.js"),require("../../../carousel/carousel.js"),require("../../../carousel-secondary/CarouselSecondary.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"),require("../../../side-modal/SideModal.style.js"),require("../../../add-variableV2/AddVariableV2.styled.js"),require("../../../SearchFilter/types/SearchFilter.type.js"),require("../../../SearchFilter/components/DatePickerButton.js"),require("../../../SearchFilter/components/DateRangeOnlyButton.js"),require("../../../input-with-vars/InputWithVariables.js"),require("../../../star-rating/StarRating.js"),require("../../../dashboard-review-popup/components/FiveStar.styled.js"),require("../../../dashboard-review-popup/components/Form.styled.js"),require("../../../dashboard-review-popup/components/ZeroState.js"),require("../../../dashboard-review-popup/DashboardReviewPopUp.styled.js"),require("../../../testimonial-card/TestimonialCard.style.js"),require("../../../slider/slider.js"),require("react-slick"),require("../../../carousel-preview/CarouselPreview.style.js"),require("../../../card-selector/CardSelector.styled.js"),require("../../../action-button/ActionButton.styled.js"),require("../../../floating-input-dropdown/FloatingInputDropdown.js"),require("../../../dropdown/MultilevelDropdownPopover/index.js"),require("../../../multi-level-dropdown/MultiLevelDropdown.styled.js");var o=require("chart.js"),d=require("react-chartjs-2");function n(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var u=n(e);o.Chart.register(o.ArcElement,o.Legend);const p={plugins:{legend:{display:!1},tooltip:{enabled:!0,callbacks:{label:e=>{if(!e.label)return" 0%";const g=e.dataset.data.reduce(((e,g)=>e+g),0),I=parseFloat((e.raw/g*100).toFixed(1));return[` ${e.label}`,` ${e.raw} (${I}% of ${g})`]}}}}},b=["#5E07BB","#9E77ED","#D2AEFF","#CDE1FF","#92AFFA","#3935E1"],G=u.default("div","production"===process.env.NODE_ENV?{target:"elaov7f0"}:{target:"elaov7f0",label:"CartStyled"})("background:",(e=>r.COLORS.surface.standard),";border:1px solid ",(e=>r.COLORS.stroke.primary),";border-radius:4px;"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFnRThCIiwiZmlsZSI6IlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IGpzeCBhcyBfanN4LCBGcmFnbWVudCBhcyBfRnJhZ21lbnQsIGpzeHMgYXMgX2pzeHMgfSBmcm9tIFwicmVhY3QvanN4LXJ1bnRpbWVcIjtcclxuaW1wb3J0IHN0eWxlZCBmcm9tICdAZW1vdGlvbi9zdHlsZWQnO1xyXG5pbXBvcnQgQmFyQ2hhcnRJY29uIGZyb20gJ0BzcmMvYXNzZXRzL2ljb25zL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Swgc2xpY2UpID0+IHN1bSArIHNsaWNlLmNvdW50LCAwKTtcclxuICAgICAgICBsZXQgdXBkYXRlZFNsaWNlc1dpdGhDb2xvciA9IFtdO1xyXG4gICAgICAgIHVwZGF0ZWRTbGljZXNXaXRoQ29sb3IgPSBPYmplY3Qua2V5cyhzbGljZXMpLm1hcCgoa2V5LCBpbmRleCkgPT4gKE9iamVjdC5hc3NpZ24oeyBjb2xvcjogR1JBUEhfQ09MT1JTW2luZGV4ICUgR1JBUEhfQ09MT1JTLmxlbmd0aF0gfSwgc2xpY2VzW2tleV0pKSk7XHJcbiAgICAgICAgc2V0U2xpY2VzV2l0aENvbG9yKFsuLi51cGRhdGVkU2xpY2VzV2l0aENvbG9yXSk7XHJcbiAgICAgICAgaWYgKHRvdGFsU3VtID09PSAwKSB7XHJcbiAgICAgICAgICAgIGNvbnN0IGRhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBkYXRhc2V0czogW1xyXG4gICAgICAgICAgICAgICAgICAgIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgZGF0YTogWzEwMF0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogWycjRjBGMEYwJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiAwLFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZXREYXRhKGRhdGFTZXQpO1xyXG4gICAgICAgIH1cclxuICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgY29uc3QgZGF0YVNldCA9IHtcclxuICAgICAgICAgICAgICAgIGxhYmVsczogc2xpY2VzLm1hcCgoc2xpY2UpID0+IFN0cmluZ1V0aWxzLmNhcGl0YWxpemUoc2xpY2UubmFtZSkpLFxyXG4gICAgICAgICAgICAgICAgZGF0YXNldHM6IFtcclxuICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGE6IHNsaWNlcy5tYXAoKHNsaWNlKSA9PiBzbGljZS5jb3VudCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogc2xpY2VzLm1hcCgoc2xpY2UsIGluZGV4KSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHNsaWNlLmNvbG9yKSAhPT0gbnVsbCAmJiBfYSAhPT0gdm9pZCAwID8gX2EgOiBHUkFQSF9DT0xPUlNbaW5kZXggJSBHUkFQSF9DT0xPUlMubGVuZ3RoXTsgfSksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlckNvbG9yOiBbJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiA0LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJSYWRpdXM6IDgsXHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIF0sXHJcbiAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgIHNldERhdGEoZGF0YVNldCk7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGlmICh0cnVuY2F0ZVNsaWNlcyAmJiBzbGljZXMubGVuZ3RoID4gdHJ1bmNhdGVTbGljZXMpIHtcclxuICAgICAgICAgICAgY29uc3QgdHJ1bmNhdGVkU2xpY2VzID0gc2xpY2VzLnNsaWNlKDAsIHRydW5jYXRlU2xpY2VzKTtcclxuICAgICAgICAgICAgY29uc3Qgb3RoZXJTbGljZXMgPSBzbGljZXMuc2xpY2UodHJ1bmNhdGVTbGljZXMpO1xyXG4gICAgICAgICAgICBjb25zdCBvdGhlckNvdW50ID0gb3RoZXJTbGljZXMucmVkdWNlKChzdW0sIHNsaWNlKSA9PiBzdW0gKyBzbGljZS5jb3VudCwgMCk7XHJcbiAgICAgICAgICAgIHRydW5jYXRlZFNsaWNlcy5wdXNoKHsgbmFtZTogJ090aGVyJywgY291bnQ6IG90aGVyQ291bnQgfSk7XHJcbiAgICAgICAgICAgIGNvbnN0IHRydW5jYXRlZERhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBsYWJlbHM6IHRydW5jYXRlZFNsaWNlcy5tYXAoKHNsaWNlKSA9PiBTdHJpbmdVdGlscy5jYXBpdGFsaXplKHNsaWNlLm5hbWUpKSxcclxuICAgICAgICAgICAgICAgIGRhdGFzZXRzOiBbXHJcbiAgICAgICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBkYXRhOiB0cnVuY2F0ZWRTbGljZXMubWFwKChzbGljZSkgPT4gc2xpY2UuY291bnQpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBiYWNrZ3JvdW5kQ29sb3I6IHRydW5jYXRlZFNsaWNlcy5tYXAoKHNsaWNlLCBpbmRleCkgPT4geyB2YXIgX2E7IHJldHVybiAoX2EgPSBzbGljZS5jb2xvcikgIT09IG51bGwgJiYgX2EgIT09IHZvaWQgMCA/IF9hIDogR1JBUEhfQ09MT1JTW2luZGV4ICUgR1JBUEhfQ09MT1JTLmxlbmd0aF07IH0pLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJDb2xvcjogWyd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZSddLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJXaWR0aDogNCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgYm9yZGVyUmFkaXVzOiA4LFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZXRUcnVuY2F0ZWREYXRhKHRydW5jYXRlZERhdGFTZXQpO1xyXG4gICAgICAgICAgICBjb25zdC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4KFRpdGxlTWVkaXVtLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1hcmdpbkJvdHRvbTogMTYsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gfSwgeyBjaGlsZHJlbjogdGl0bGUgfSkpKSwgX2pzeHMoXCJkaXZcIiwgeyBjaGlsZHJlbjogW3Nob3dDb252ZXJ0VG9CYXJDaGFydCAmJiAoX2pzeChJY29uQnV0dG9uLCB7IEljb246IEJhckNoYXJ0SWNvbiwgb25DbGljazogKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXRTaG93QmFyQ2hhcnQodHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9KSksIGFsbG93Q2hhcnRQb3B1cCAmJiAoX2pzeChJY29uQnV0dG9uLCB7IEljb246IE1heGltaXplSWNvbiwgb25DbGljazogKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXRTaG93UG9wdXAodHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9KSldIH0pXSB9KSksIF9qc3hzKFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdyb3cnIH0sIHsgY2hpbGRyZW46IFtfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdjb2wtNicgfSwgeyBjaGlsZHJlbjogX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogc2l6ZSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6IHNpemUsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IF9qc3goRG91Z2hudXQsI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gICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBqdXN0aWZ5Q29udGVudDogJ3NwYWNlLWJldHdlZW4nLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6ICc4MHZoJyxcclxuICAgICAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IFtfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZTogeyB3aWR0aDogJzU1JScsIG1hcmdpbkxlZnQ6ICc0JScgfSB9LCB7IGNoaWxkcmVuOiBfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogJzEwMCUnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6ICcxMDAlJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhbGlnbkl0ZW1zOiAnY2VudGVyJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAganVzdGlmeUNvbnRlbnQ6ICdjZW50ZXInLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gfSwgeyBjaGlsZHJlbjogX2pzeChEb3VnaG51dCwgeyBkYXRhOiBkYXRhLCBvcHRpb25zOiBPYmplY3QuYXNzaWduKE9iamVjdC5hc3NpZ24oe30sIG9wdGlvbnMpLCB7IG1haW50YWluQXNwZWN0UmF0aW86IHNpemUgPyBmYWxzZSA6IHRydWUgfSkgfSkgfSkpIH0pKSwgX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogJzMwJScsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGVpZ2h0OiAnMTAwJScsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgb3ZlcmZsb3dZOiAnYXV0bycsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IF9qc3goUGllQ2hhcnQsIHsgc2xpY2VzOiBzbGljZXNXaXRoQ29sb3IgfSkgfSkpXSB9KSkgfSkpKSwgc2hvd0JhckNoYXJ0ICYmIGJhckNoYXJ0RGF0YSAmJiAoX2pzeChTdHlsZWRNb2RhbCwgT2JqZWN0LmFzc2lnbih7IG9wZW46IHNob3dCYXJDaGFydCwgb25DbG9zZTogKCkgPT4gc2V0U2hvd0JhckNoYXJ0KGZhbHNlKSwgY2xvc2VPbk91dHNpZGVDbGljazogdHJ1ZSwgaGVhZGluZ1RpdGxlOiB0aXRsZSwgd2lkdGg6IFwiODUlXCIgfSwgeyBjaGlsZHJlbjogX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcGFkZGluZzogJzI0cHggMCcsXHJcbiAgICAgICAgICAgICAgICAgICAgfSB9LCB7IGNoaWxkcmVuOiBfanN4KFZlcnRpY2FsR3JhcGgsIHsgeEF4aXM6IGJhckNoYXJ0RGF0YS54QXhpcywgeUF4aXM6IGJhckNoYXJ0RGF0YS55QXhpcywgYmFyQ29sb3JSR0JBOiBiYXJDaGFydERhdGEgPT09IG51bGwgfHwgYmFyQ2hhcnREYXRhID09PSB2b2lkIDAgPyB2b2lkIDAgOiBiYXJDaGFydERhdGEuYmFyQ29sb3JSR0JBIH0pIH0pKSB9KSkpXSB9KSk7XHJcbn07XHJcbi8vIyBzb3VyY2VNYXBwaW5nVVJMPVBpZUNoYXJ0QW5hbHl0aWNzLmpzLm1hcCJdfQ== */"));exports.Card=e=>g.jsx(G,Object.assign({style:{padding:24}},{children:e.children})),exports.PieChartAnalytics=e=>{let{title:r,slices:o,size:n,allowChartPopup:u,showConvertToBarChart:G,truncateSlices:X,barChartXAxisTitle:y,barChartYAxisTitle:h,hideTitle:B=!1}=e;const[m,j]=i.useState(!1),[x,Z]=i.useState(!1),[R,H]=i.useState([]),[Y,J]=i.useState(),[N,S]=i.useState(),[W,F]=i.useState([]),[V,w]=i.useState(null);return i.useEffect((()=>{const e=o.reduce(((e,g)=>e+g.count),0);let g=[];if(g=Object.keys(o).map(((e,g)=>Object.assign({color:b[g%b.length]},o[e]))),H([...g]),0===e){J({datasets:[{data:[100],backgroundColor:["#F0F0F0"],borderWidth:0}]})}else{const e={labels:o.map((e=>A.default.capitalize(e.name))),datasets:[{data:o.map((e=>e.count)),backgroundColor:o.map(((e,g)=>{var I;return null!==(I=e.color)&&void 0!==I?I:b[g%b.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};J(e)}if(X&&o.length>X){const e=o.slice(0,X),g=o.slice(X).reduce(((e,g)=>e+g.count),0);e.push({name:"Other",count:g});const I={labels:e.map((e=>A.default.capitalize(e.name))),datasets:[{data:e.map((e=>e.count)),backgroundColor:e.map(((e,g)=>{var I;return null!==(I=e.color)&&void 0!==I?I:b[g%b.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};S(I);const C=e.map(((e,g)=>Object.assign({color:b[g%b.length]},e)));F(C)}G&&w(((e,g,I)=>({xAxis:{data:e.map((e=>e.name)),title:null!=g?g:""},yAxis:{data:e.map((e=>e.count)),title:null!=I?I:""},barColorRGBA:{r:210,g:174,b:255,a:1}}))(o,y,h))}),[o,X]),Y?g.jsxs(g.Fragment,{children:[g.jsxs("div",Object.assign({style:{display:"flex",justifyContent:B||0===(null==r?void 0:r.length)?"flex-end":"space-between"}},{children:[!B&&r&&g.jsx(l.TitleMedium,Object.assign({style:{marginBottom:16}},{children:r})),g.jsxs("div",{children:[G&&g.jsx(s.IconButton,{Icon:I.default,onClick:()=>{Z(!0)}}),u&&g.jsx(s.IconButton,{Icon:C.default,onClick:()=>{j(!0)}})]})]})),g.jsxs("div",Object.assign({className:"row"},{children:[g.jsx("div",Object.assign({className:"col-6"},{children:g.jsx("div",Object.assign({style:{width:n,height:n}},{children:g.jsx(d.Doughnut,{data:X?N:Y,options:Object.assign(Object.assign({},p),{maintainAspectRatio:!n})})}))})),g.jsx("div",Object.assign({className:"col-6",style:{paddingLeft:48,display:"flex",flexDirection:"column",justifyContent:"center"}},{children:g.jsx(c.PieChart,{slices:X?W:R})}))]})),m&&g.jsx(t.StyledModal,Object.assign({open:m,onClose:()=>j(!1),closeOnOutsideClick:!0,headingTitle:r,width:"75%"},{children:g.jsxs("div",Object.assign({style:{padding:24,display:"flex",justifyContent:"space-between",height:"80vh"}},{children:[g.jsx("div",Object.assign({style:{width:"55%",marginLeft:"4%"}},{children:g.jsx("div",Object.assign({style:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"}},{children:g.jsx(d.Doughnut,{data:Y,options:Object.assign(Object.assign({},p),{maintainAspectRatio:!n})})}))})),g.jsx("div",Object.assign({style:{width:"30%",height:"100%",overflowY:"auto"}},{children:g.jsx(c.PieChart,{slices:R})}))]}))})),x&&V&&g.jsx(t.StyledModal,Object.assign({open:x,onClose:()=>Z(!1),closeOnOutsideClick:!0,headingTitle:r,width:"85%"},{children:g.jsx("div",Object.assign({style:{padding:"24px 0"}},{children:g.jsx(a.VerticalGraph,{xAxis:V.xAxis,yAxis:V.yAxis,barColorRGBA:null==V?void 0:V.barColorRGBA})}))}))]}):g.jsx(g.Fragment,{})};
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  export declare const Menus: ({
3
2
  displayName: string;
4
3
  key: number;
@@ -2,7 +2,7 @@
2
2
  :hover {
3
3
  background: ${s.COLORS.surface.subdued};
4
4
  }
5
- position: ${e=>e.isNewTag?"":"relative"};
5
+ position: ${e=>e.isNewTag?"relative":""};
6
6
  .new--tag {
7
7
  box-sizing: border-box;
8
8
  position: absolute;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("lodash"),l=require("react"),o=require("../../utils/StringUtils.js"),a=require("../../constants/Theme.js"),i=require("../modals/styledModal.js"),r=require("../template-preview/models/Channels.js"),s=require("../template-preview/models/WhatsAppTemplate.js"),n=require("./context/templateModalContext.js"),d=require("./modalElements/Footer.js"),u=require("./modalElements/TemplateAnalyticsComponent.js"),c=require("./modalElements/TemplateSelectModalContent.js"),p=require("./utils/convertPlaceholdersToBikDropdown.js");exports.TemplateContextMapper=v=>{var m,C,h,b,S,E,f,x,P,T;const{selectedTemplate:g,closeDialog:y,showVariableMapping:I,channel:L,htmlContent:D,templateVariables:A,onTemplateSelect:j,globalPlaceholders:w,showOnlyContent:k,whatsappSpecificPickerMeta:H,zIndex:N,showVariableModal:V,variableList:M,discountCode:O,setDiscountCode:B,onBackPress:q,enabledCustomText:F,variableListForImage:_,showSampleValues:W,disableEditVariable:Y,pod:R,extras:$,pickerConf:z,selectedCarouselProducts:U,disableEditExpiry:G,cardWidth:J,onDeleteSelectedProducts:K,fileName:Q,setFileName:X,hideDeviceContainerInPreview:Z,maxCharLimit:ee,onDefaultVariableSelect:te,skipDefaultVariableContent:le,disableDatePicker:oe,disableCopyCode:ae,initialExpiryDateTime:ie,showDiscountCodeExpiryInfo:re,footerButtonText:se,footerInfoText:ne,templateAnalytics:de}=v;l.useEffect((()=>{be(D)}),[D]);const ue=L===r.CHANNEL_TYPE.WHATSAPP&&"CAROUSEL"===(null===(C=null===(m=null==g?void 0:g.components)||void 0===m?void 0:m[1])||void 0===C?void 0:C.type),ce=null==g?void 0:g.isProductCarouselType,[pe,ve]=l.useState(L===r.CHANNEL_TYPE.EMAIL||L==r.CHANNEL_TYPE.WEBPUSH||ue?"desktop":"mobile"),[me,Ce]=l.useState(!1),[he,be]=l.useState(D),[Se,Ee]=l.useState(!1),[fe,xe]=l.useState([]),[Pe,Te]=l.useState({}),[ge,ye]=l.useState(g),[Ie,Le]=l.useState([]),[De,Ae]=l.useState(null),[je,we]=l.useState(!1),[ke,He]=l.useState(null!=A?A:[]),[Ne,Ve]=l.useState(!1),[Me,Oe]=l.useState(ue?(null===(b=null===(h=null==ge?void 0:ge.mapping)||void 0===h?void 0:h.body)||void 0===b?void 0:b.length)?-1:0:-1),[Be,qe]=l.useState([]),[Fe,_e]=l.useState(void 0),We=l.useRef(null),[Ye,Re]=l.useState(!1),[$e,ze]=l.useState(!1),[Ue,Ge]=l.useState(!1),[Je,Ke]=l.useState(!0),[Qe,Xe]=l.useState(!0),[Ze,et]=l.useState({});l.useEffect((()=>{U?qe(U):ce&&qe([])}),[U]),l.useEffect((()=>{var e;if(!je&&ce&&(!U||0===qe.length)){const t=null===(e=null==ge?void 0:ge.components)||void 0===e?void 0:e[1].cards,l=[];null==t||t.forEach((e=>{var t;null===(t=null==e?void 0:e.components)||void 0===t||t.forEach((e=>{var t,o,a;"HEADER"===e.type&&l.push(null!==(a=null===(o=null===(t=e.example)||void 0===t?void 0:t.header_handle)||void 0===o?void 0:o[0])&&void 0!==a?a:"")}))})),Le(l),we(!0)}}),[je]);const tt=l.useMemo((()=>p.convertPlaceholdersToBikDropdown(w)),[w]);return l.useEffect((()=>{_e(t.cloneDeep(M))}),[M]),(null==de?void 0:de.show)&&Je?e.jsx(u.default,{headingTitle:null==ge?void 0:ge.label,headingSubtitle:L===r.CHANNEL_TYPE.WHATSAPP?`${o.default.capitaliseFirstLetterOfString(null!==(S=null==ge?void 0:ge.category)&&void 0!==S?S:"")} • ${null!==(E=null==ge?void 0:ge.templateCategory)&&void 0!==E?E:""}`:"",templateAnalytics:de,onClose:()=>{null==y||y(),Ke(!1),Xe(!1)},onCancel:()=>{Ke(!1),Xe(!1)},onProceed:()=>{Ke(!1),Xe(!0)},templateId:(null==ge?void 0:ge.templateId)||""}):e.jsx(n.TemplateModalContext.Provider,Object.assign({value:{hideFooterButton:Ue,setHideFooterButton:Ge,hideCrossButton:$e,setHideCrossButton:ze,variableList:Fe,setVariableList:_e,variableCallback:De,setVariableCallback:Ae,showVariablePicker:me,setShowVariablePicker:Ce,template:ge,setTemplate:ye,device:pe,setDevice:ve,display_content:he,setDisplayContent:be,originalVariableList:ke,setOriginalVariableList:He,isError:Se,setIsError:Ee,channel:L,globalNormalizedPlaceholders:tt,templateSelectionTriggered:Ne,setTemplateSelectionTriggered:Ve,enabledCustomText:F,disableEditVariable:Y,pod:R,extras:$,isWhatsappCarousel:ue,selectedCarouselIndex:Me,setSelectedCarouselIndex:Oe,isProductCarouselType:ce,templateErrorIndexes:Pe,cardCount:ue?null===(x=null===(f=g.components)||void 0===f?void 0:f[1].cards)||void 0===x?void 0:x.length:void 0,errorIndexes:fe,setErrorIndexes:xe,pickerConf:z,carouselProducts:Be,setCarouselProducts:qe,disableEditExpiry:G,cardWidth:J,cardImages:Ie,onDeleteSelectedProducts:K,hideDeviceContainerInPreview:Z,sliderRef:We,isCarouselHovered:Ye,setIsCarouselHovered:Re,maxCharLimit:ee,ctaOptionsErrors:Ze,setCtaOptionsErrors:et,onDefaultVariableSelect:te,disableDatePicker:oe,disableCopyCode:ae,initialExpiryDateTime:ie,showDiscountCodeExpiryInfo:re}},{children:k?e.jsx(c.default,{variableListFromProps:M,channel:r.CHANNEL_TYPE.EMAIL,hideHeader:!0}):e.jsxs(i.StyledModal,Object.assign({hideCrossButton:$e,zIndex:N,centralContainerStyles:{width:ue?900:L===r.CHANNEL_TYPE.EMAIL&&I?1e3:800},open:Qe,onClose:()=>{Xe(!1),null==y||y()},headingTitle:null==ge?void 0:ge.label,headingSubtitle:L===r.CHANNEL_TYPE.WHATSAPP?`${o.default.capitaliseFirstLetterOfString(null!==(P=null==ge?void 0:ge.category)&&void 0!==P?P:"")} • ${null!==(T=null==ge?void 0:ge.templateCategory)&&void 0!==T?T:""}`:"",onBackPress:()=>{if(null==de?void 0:de.show)return Ke(!0),void Xe(!1);null==q||q()},modalHeaderStyles:{borderBottom:`1px solid ${a.COLORS.stroke.primary}`}},{children:[e.jsx(c.default,{variableListFromProps:M,showSampleValues:W,showVariableMapping:I,channel:L,whatsappSpecificPickerMeta:H,showVariableModal:V,discountCode:O,setDiscountCode:B,variableListForImage:_&&(null==_?void 0:_.length)>0?_:Fe,fileName:Q,setFileName:e=>{null==X||X(e)},skipDefaultVariableContent:le}),j?e.jsx(d.default,{isWhatsappCarousel:null!=ue&&ue,onSelect:function(){var e;if((null==Be?void 0:Be.length)<1&&ce)return void Ee(!0);if(Object.keys(Ze).length>0&&R!==s.POD.CHATBOT)return void Ee(!0);const t=null==j?void 0:j(ge,ke,null!=he?he:"",Be);Te(null!==(e=null==t?void 0:t.templateErrorIndexes)&&void 0!==e?e:{body:[],buttons:[]}),(null==t?void 0:t.errorIndexes)||(null==t?void 0:t.error)?((null==t?void 0:t.errorIndexes)&&xe(t.errorIndexes),(null==t?void 0:t.error)&&Ee(!!(null==t?void 0:t.error))):Ve(!0)},footerButtonText:se,footerInfoText:ne}):e.jsx(e.Fragment,{})]}))}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("lodash"),l=require("react"),o=require("../../utils/StringUtils.js"),a=require("../../constants/Theme.js"),i=require("../modals/styledModal.js"),r=require("../template-preview/models/Channels.js"),s=require("../template-preview/models/WhatsAppTemplate.js"),n=require("./context/templateModalContext.js"),d=require("./modalElements/Footer.js"),u=require("./modalElements/TemplateAnalyticsComponent.js"),c=require("./modalElements/TemplateSelectModalContent.js"),p=require("./utils/convertPlaceholdersToBikDropdown.js");exports.TemplateContextMapper=v=>{var m,C,h,b,S,E,f,x,P,T;const{selectedTemplate:g,closeDialog:y,showVariableMapping:I,channel:L,htmlContent:A,templateVariables:D,onTemplateSelect:j,globalPlaceholders:w,showOnlyContent:k,whatsappSpecificPickerMeta:H,zIndex:N,showVariableModal:V,variableList:M,discountCode:O,setDiscountCode:B,onBackPress:q,enabledCustomText:F,variableListForImage:_,showSampleValues:W,disableEditVariable:Y,pod:R,extras:$,pickerConf:z,selectedCarouselProducts:U,disableEditExpiry:G,cardWidth:J,onDeleteSelectedProducts:K,fileName:Q,setFileName:X,hideDeviceContainerInPreview:Z,maxCharLimit:ee,onDefaultVariableSelect:te,skipDefaultVariableContent:le,disableDatePicker:oe,disableCopyCode:ae,initialExpiryDateTime:ie,showDiscountCodeExpiryInfo:re,footerButtonText:se,footerInfoText:ne,templateAnalytics:de}=v;l.useEffect((()=>{be(A)}),[A]);const ue=L===r.CHANNEL_TYPE.WHATSAPP&&"CAROUSEL"===(null===(C=null===(m=null==g?void 0:g.components)||void 0===m?void 0:m[1])||void 0===C?void 0:C.type),ce=null==g?void 0:g.isProductCarouselType,[pe,ve]=l.useState(L===r.CHANNEL_TYPE.EMAIL||L==r.CHANNEL_TYPE.WEBPUSH||ue?"desktop":"mobile"),[me,Ce]=l.useState(!1),[he,be]=l.useState(A),[Se,Ee]=l.useState(!1),[fe,xe]=l.useState([]),[Pe,Te]=l.useState({}),[ge,ye]=l.useState(g),[Ie,Le]=l.useState([]),[Ae,De]=l.useState(null),[je,we]=l.useState(!1),[ke,He]=l.useState(null!=D?D:[]),[Ne,Ve]=l.useState(!1),[Me,Oe]=l.useState(ue?(null===(b=null===(h=null==ge?void 0:ge.mapping)||void 0===h?void 0:h.body)||void 0===b?void 0:b.length)?-1:0:-1),[Be,qe]=l.useState([]),[Fe,_e]=l.useState(void 0),We=l.useRef(null),[Ye,Re]=l.useState(!1),[$e,ze]=l.useState(!1),[Ue,Ge]=l.useState(!1),[Je,Ke]=l.useState(!0),[Qe,Xe]=l.useState(!0),[Ze,et]=l.useState({});l.useEffect((()=>{U?qe(U):ce&&qe([])}),[U]),l.useEffect((()=>{var e;if(!je&&ce&&(!U||0===qe.length)){const t=null===(e=null==ge?void 0:ge.components)||void 0===e?void 0:e[1].cards,l=[];null==t||t.forEach((e=>{var t;null===(t=null==e?void 0:e.components)||void 0===t||t.forEach((e=>{var t,o,a;"HEADER"===e.type&&l.push(null!==(a=null===(o=null===(t=e.example)||void 0===t?void 0:t.header_handle)||void 0===o?void 0:o[0])&&void 0!==a?a:"")}))})),Le(l),we(!0)}}),[je]);const tt=l.useMemo((()=>p.convertPlaceholdersToBikDropdown(w)),[w]);return l.useEffect((()=>{_e(t.cloneDeep(M))}),[M]),(null==de?void 0:de.show)&&Je?e.jsx(u.TemplateAnalyticsComponent,{headingTitle:null==ge?void 0:ge.label,headingSubtitle:L===r.CHANNEL_TYPE.WHATSAPP?`${o.default.capitaliseFirstLetterOfString(null!==(S=null==ge?void 0:ge.category)&&void 0!==S?S:"")} • ${null!==(E=null==ge?void 0:ge.templateCategory)&&void 0!==E?E:""}`:"",templateAnalytics:de,onClose:()=>{null==y||y(),Ke(!1),Xe(!1)},onCancel:()=>{Ke(!1),Xe(!1)},onProceed:()=>{Ke(!1),Xe(!0)},templateId:(null==ge?void 0:ge.templateId)||""}):e.jsx(n.TemplateModalContext.Provider,Object.assign({value:{hideFooterButton:Ue,setHideFooterButton:Ge,hideCrossButton:$e,setHideCrossButton:ze,variableList:Fe,setVariableList:_e,variableCallback:Ae,setVariableCallback:De,showVariablePicker:me,setShowVariablePicker:Ce,template:ge,setTemplate:ye,device:pe,setDevice:ve,display_content:he,setDisplayContent:be,originalVariableList:ke,setOriginalVariableList:He,isError:Se,setIsError:Ee,channel:L,globalNormalizedPlaceholders:tt,templateSelectionTriggered:Ne,setTemplateSelectionTriggered:Ve,enabledCustomText:F,disableEditVariable:Y,pod:R,extras:$,isWhatsappCarousel:ue,selectedCarouselIndex:Me,setSelectedCarouselIndex:Oe,isProductCarouselType:ce,templateErrorIndexes:Pe,cardCount:ue?null===(x=null===(f=g.components)||void 0===f?void 0:f[1].cards)||void 0===x?void 0:x.length:void 0,errorIndexes:fe,setErrorIndexes:xe,pickerConf:z,carouselProducts:Be,setCarouselProducts:qe,disableEditExpiry:G,cardWidth:J,cardImages:Ie,onDeleteSelectedProducts:K,hideDeviceContainerInPreview:Z,sliderRef:We,isCarouselHovered:Ye,setIsCarouselHovered:Re,maxCharLimit:ee,ctaOptionsErrors:Ze,setCtaOptionsErrors:et,onDefaultVariableSelect:te,disableDatePicker:oe,disableCopyCode:ae,initialExpiryDateTime:ie,showDiscountCodeExpiryInfo:re}},{children:k?e.jsx(c.default,{variableListFromProps:M,channel:r.CHANNEL_TYPE.EMAIL,hideHeader:!0}):e.jsxs(i.StyledModal,Object.assign({hideCrossButton:$e,zIndex:N,centralContainerStyles:{width:ue?900:L===r.CHANNEL_TYPE.EMAIL&&I?1e3:800},open:Qe,onClose:()=>{Xe(!1),null==y||y()},headingTitle:null==ge?void 0:ge.label,headingSubtitle:L===r.CHANNEL_TYPE.WHATSAPP?`${o.default.capitaliseFirstLetterOfString(null!==(P=null==ge?void 0:ge.category)&&void 0!==P?P:"")} • ${null!==(T=null==ge?void 0:ge.templateCategory)&&void 0!==T?T:""}`:"",onBackPress:()=>{if(null==de?void 0:de.show)return Ke(!0),void Xe(!1);null==q||q()},modalHeaderStyles:{borderBottom:`1px solid ${a.COLORS.stroke.primary}`}},{children:[e.jsx(c.default,{variableListFromProps:M,showSampleValues:W,showVariableMapping:I,channel:L,whatsappSpecificPickerMeta:H,showVariableModal:V,discountCode:O,setDiscountCode:B,variableListForImage:_&&(null==_?void 0:_.length)>0?_:Fe,fileName:Q,setFileName:e=>{null==X||X(e)},skipDefaultVariableContent:le}),j?e.jsx(d.default,{isWhatsappCarousel:null!=ue&&ue,onSelect:function(){var e;if((null==Be?void 0:Be.length)<1&&ce)return void Ee(!0);if(Object.keys(Ze).length>0&&R!==s.POD.CHATBOT)return void Ee(!0);const t=null==j?void 0:j(ge,ke,null!=he?he:"",Be);Te(null!==(e=null==t?void 0:t.templateErrorIndexes)&&void 0!==e?e:{body:[],buttons:[]}),(null==t?void 0:t.errorIndexes)||(null==t?void 0:t.error)?((null==t?void 0:t.errorIndexes)&&xe(t.errorIndexes),(null==t?void 0:t.error)&&Ee(!!(null==t?void 0:t.error))):Ve(!0)},footerButtonText:se,footerInfoText:ne}):e.jsx(e.Fragment,{})]}))}))};
@@ -1,14 +1,12 @@
1
- /// <reference types="react" />
2
1
  import { TemplateAnalyticsComponentI, TemplateAnalyticsDataI } from "../../template-preview/models/WhatsAppTemplate";
3
- declare const TemplateAnalyticsComponent: React.FC<TemplateAnalyticsComponentI>;
4
- export default TemplateAnalyticsComponent;
5
- export declare const RightPanelTemplateAnalytics: React.FC<{
2
+ export declare const TemplateAnalyticsComponent: (props: TemplateAnalyticsComponentI) => import("react/jsx-runtime").JSX.Element;
3
+ export declare const RightPanelTemplateAnalytics: (props: {
6
4
  analyticsData: TemplateAnalyticsDataI;
7
5
  skipTitle?: boolean;
8
- }>;
9
- export declare const AnalyticsItem: React.FC<{
6
+ }) => import("react/jsx-runtime").JSX.Element;
7
+ export declare const AnalyticsItem: (props: {
10
8
  icon: React.ElementType;
11
9
  title: string;
12
10
  value: number;
13
11
  percentValue?: number;
14
- }>;
12
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../../assets/icons/alert_triangle.svg.js"),s=require("../../../assets/icons/click.svg.js"),l=require("react"),a=require("../../modals/styledModal.js"),n=require("../../tag/Tag.js"),i=require("../../template-preview/models/WhatsAppTemplate.js"),c=require("../../TypographyStyle.js"),r=require("../../../constants/Theme.js"),o=require("../styles/TemplateAnalyticsStyles.js"),d=require("../utils/SegmentConstants.js"),u=require("./TemplateAnalyticsSkeleton.js");const j=t=>{let{analyticsData:l,skipTitle:a}=t;return e.jsxs(o.RightPanelContainer,{children:[a?e.jsx(e.Fragment,{}):e.jsx(c.TitleSmall,{children:"Here are your template's delivery & engagement stats for the last 30 days"}),e.jsx("div",Object.assign({className:"mt-3"},{children:d.ANALYTICS_ENGAGEMENT_MAP.map(((t,s)=>e.jsx(m,{icon:t.icon,title:t.title,value:l[t.valName]||0,percentValue:t.percentValName?l[t.percentValName]:null},s)))})),(null==l?void 0:l.clickAnalytics)&&e.jsxs(e.Fragment,{children:[e.jsx(c.TitleSmall,Object.assign({color:r.COLORS.content.secondary},{children:"Clicked"})),e.jsx("div",Object.assign({className:"mt-3"},{children:Object.entries(l.clickAnalytics).map(((t,l)=>{let[a,n]=t;return e.jsx(m,{icon:s.default,title:a,value:n.totalClicks||0,percentValue:n.clickPercentage},l)}))}))]})]})},m=t=>{let{icon:s,title:l,value:a,percentValue:i}=t;return e.jsxs("div",Object.assign({className:"each--analytics--container"},{children:[e.jsxs("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[e.jsx("div",Object.assign({className:"each--icon--container"},{children:e.jsx(s,{width:"16px",height:"16px",color:r.COLORS.background.brand})})),e.jsx(c.Caption,{children:l})]})),e.jsxs("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[i?e.jsx(n.Tag,{tagText:i||0,theme:"light",type:"neutral"}):e.jsx(e.Fragment,{}),e.jsx(o.CustomTitleMedium,{children:a})]}))]}))};exports.AnalyticsItem=m,exports.RightPanelTemplateAnalytics=j,exports.default=s=>{let{templateAnalytics:n,onClose:m,onProceed:g,onCancel:h,headingTitle:p,headingSubtitle:x,templateId:y}=s;const{templateQuality:T=i.TEMPLATE_QUALITY.GREEN,fetchAnalytics:b}=n||{},{icon:O,title:A,subline:C}=d.TEMPLATE_QUALITY_MAP[T||i.TEMPLATE_QUALITY.GREEN],[S,v]=l.useState({}),[N,k]=l.useState(!0);return l.useEffect((()=>{null==b||b(y||"").then((e=>{e.analytics&&v(e.analytics),k(!1)}))}),[]),e.jsx(a.StyledModal,Object.assign({open:!0,headingTitle:p,tintedHeader:!0,modalHeaderStyles:{backgroundColor:r.COLORS.surface.subdued},onBackPress:()=>{null==m||m()},headingSubtitle:x,footerShadow:!0,primaryButton:{buttonText:"Cancel",buttonType:"primary",onClick:()=>{null==m||m(),null==h||h()},disabled:N},secondaryButton:{buttonText:"Proceed with selection",buttonType:"secondary",onClick:()=>{null==g||g()},disabled:N},onClose:()=>{null==m||m()},width:"700px"},{children:e.jsxs(o.TemplateContainer,{children:[e.jsx(o.LeftPanelContainer,{children:e.jsxs("div",Object.assign({className:"inside--container"},{children:[O&&e.jsx("div",Object.assign({className:"icon--container"},{children:e.jsx(t.default,{width:40,height:40,color:r.COLORS.content.warning})})),A&&e.jsxs(c.TitleRegular,{children:[A," template"]}),e.jsx(c.Caption,Object.assign({style:{textAlign:"center"},color:r.COLORS.content.secondary},{children:C}))]}))}),N?e.jsx(u.TemplateAnalyticsSkeleton,{}):e.jsx(j,{analyticsData:S})]})}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../../assets/icons/alert_triangle.svg.js"),n=require("../../../assets/icons/click.svg.js"),s=require("react"),a=require("../../modals/styledModal.js"),l=require("../../tag/Tag.js"),i=require("../../template-preview/models/WhatsAppTemplate.js"),r=require("../../TypographyStyle.js"),c=require("../../../constants/Theme.js"),o=require("../styles/TemplateAnalyticsStyles.js"),d=require("../utils/TemplateConstants.js"),u=require("./TemplateAnalyticsSkeleton.js");const j=t=>{const{analyticsData:s,skipTitle:a}=t;return e.jsxs(o.RightPanelContainer,{children:[a?e.jsx(e.Fragment,{}):e.jsx(r.TitleSmall,{children:"Here are your template's delivery & engagement stats for the last 30 days"}),e.jsx("div",Object.assign({className:"mt-3"},{children:d.ANALYTICS_ENGAGEMENT_MAP.map(((t,n)=>e.jsx(m,{icon:t.icon,title:t.title,value:s[t.valName]||0,percentValue:t.percentValName?s[t.percentValName]:null},n)))})),(null==s?void 0:s.clickAnalytics)&&e.jsxs(e.Fragment,{children:[e.jsx(r.TitleSmall,Object.assign({color:c.COLORS.content.secondary},{children:"Clicked"})),e.jsx("div",Object.assign({className:"mt-3"},{children:Object.entries(s.clickAnalytics).map(((t,s)=>{let[a,l]=t;return e.jsx(m,{icon:n.default,title:a,value:l.totalClicks||0,percentValue:l.clickPercentage},s)}))}))]})]})},m=t=>{const{icon:n,title:s,value:a,percentValue:i}=t;return e.jsxs("div",Object.assign({className:"each--analytics--container"},{children:[e.jsxs("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[e.jsx("div",Object.assign({className:"each--icon--container"},{children:e.jsx(n,{width:"16px",height:"16px",color:c.COLORS.background.brand})})),e.jsx(r.Caption,{children:s})]})),e.jsxs("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[i?e.jsx(l.Tag,{tagText:i||0,theme:"light",type:"neutral"}):e.jsx(e.Fragment,{}),e.jsx(o.CustomTitleMedium,{children:a})]}))]}))};exports.AnalyticsItem=m,exports.RightPanelTemplateAnalytics=j,exports.TemplateAnalyticsComponent=n=>{const{templateAnalytics:l,onClose:m,onProceed:p,onCancel:y,headingTitle:h,headingSubtitle:x,templateId:g}=n,{templateQuality:T=i.TEMPLATE_QUALITY.GREEN,fetchAnalytics:b}=l||{},{icon:C,title:A,subline:O}=d.TEMPLATE_QUALITY_MAP[T||i.TEMPLATE_QUALITY.GREEN],[v,S]=s.useState({}),[E,N]=s.useState(!0);s.useEffect((()=>{null==b||b(g||"").then((e=>{e.analytics&&S(e.analytics),N(!1)}))}),[]);const k=s.useMemo((()=>T===i.TEMPLATE_QUALITY.GREEN?{primaryButton:{buttonText:"Proceed with selection",buttonType:"primary",onClick:p,disabled:E},secondaryButton:{buttonText:"Cancel",buttonType:"tertiaryGray",onClick:()=>{null==m||m(),null==y||y()},disabled:E}}:{primaryButton:{buttonText:"Cancel",buttonType:"primary",onClick:()=>{null==m||m(),null==y||y()},disabled:E},secondaryButton:{buttonText:"Proceed with selection",buttonType:"secondary",onClick:p,disabled:E}}),[T,E]);return e.jsx(a.StyledModal,Object.assign({open:!0,headingTitle:h,tintedHeader:!0,modalHeaderStyles:{backgroundColor:c.COLORS.surface.subdued},onBackPress:()=>{null==m||m()},headingSubtitle:x,footerShadow:!0,primaryButton:k.primaryButton,secondaryButton:k.secondaryButton,onClose:()=>{null==m||m()},width:"700px"},{children:e.jsxs(o.TemplateContainer,{children:[e.jsx(o.LeftPanelContainer,{children:e.jsxs("div",Object.assign({className:"inside--container"},{children:[C&&e.jsx("div",Object.assign({className:"icon--container"},{children:e.jsx(t.default,{width:40,height:40,color:c.COLORS.content.warning})})),A&&e.jsxs(r.TitleRegular,{children:[A," template"]}),e.jsx(r.Caption,Object.assign({style:{textAlign:"center"},color:c.COLORS.content.secondary},{children:O}))]}))}),E?e.jsx(u.TemplateAnalyticsSkeleton,{}):e.jsx(j,{analyticsData:v})]})}))};
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
- export declare const TemplateAnalyticsSkeleton: React.FC<{
1
+ export declare const TemplateAnalyticsSkeleton: (props: {
3
2
  skipTitleShimmer?: boolean;
4
- }>;
3
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),s=require("../../shimmer/ShimmerComponent/BikShimmer.js"),i=require("../styles/TemplateAnalyticsStyles.js");const t=()=>e.jsxs("div",Object.assign({className:"each--analytics--container"},{children:[e.jsxs("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[e.jsx(s.BikShimmer,{boxes:[{width:"24px",height:"24px"}]}),e.jsx(s.BikShimmer,{boxes:[{width:"69px",height:"11px"}]})]})),e.jsxs("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[e.jsx(s.BikShimmer,{boxes:[{width:"43px",height:"18px"}]}),e.jsx(s.BikShimmer,{boxes:[{width:"69px",height:"28px"}]})]}))]}));exports.TemplateAnalyticsSkeleton=r=>{let{skipTitleShimmer:x}=r;return e.jsxs(i.RightPanelContainer,{children:[e.jsx("div",{children:x?e.jsx(e.Fragment,{}):e.jsx(s.BikShimmer,{boxes:[{width:"76px",height:"18px"}]})}),e.jsx("div",Object.assign({className:"mt-3"},{children:[0,1,2].map((s=>e.jsx(t,{},s)))})),e.jsxs(e.Fragment,{children:[e.jsx("div",{children:e.jsx(s.BikShimmer,{boxes:[{width:"76px",height:"18px"}]})}),e.jsx("div",Object.assign({className:"mt-3"},{children:e.jsx(t,{})}))]})]})};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),s=require("../../shimmer/ShimmerComponent/BikShimmer.js"),i=require("../styles/TemplateAnalyticsStyles.js");const t=()=>e.jsxs("div",Object.assign({className:"each--analytics--container"},{children:[e.jsxs("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[e.jsx(s.BikShimmer,{boxes:[{width:"24px",height:"24px"}]}),e.jsx(s.BikShimmer,{boxes:[{width:"69px",height:"11px"}]})]})),e.jsxs("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[e.jsx(s.BikShimmer,{boxes:[{width:"43px",height:"18px"}]}),e.jsx(s.BikShimmer,{boxes:[{width:"69px",height:"28px"}]})]}))]}));exports.TemplateAnalyticsSkeleton=r=>{const{skipTitleShimmer:x}=r;return e.jsxs(i.RightPanelContainer,{children:[e.jsx("div",{children:x?e.jsx(e.Fragment,{}):e.jsx(s.BikShimmer,{boxes:[{width:"76px",height:"18px"}]})}),e.jsxs("div",Object.assign({className:"mt-3"},{children:[...Array(3).map((s=>e.jsx(t,{},s)))]})),e.jsxs(e.Fragment,{children:[e.jsx("div",{children:e.jsx(s.BikShimmer,{boxes:[{width:"76px",height:"18px"}]})}),e.jsx("div",Object.assign({className:"mt-3"},{children:e.jsx(t,{})}))]})]})};
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../assets/icons/tick.svg.js"),t=require("../../../assets/icons/send.svg.js"),a=require("../../../assets/icons/tick_double.svg.js");require("../../template-preview/TemplatePreview.js"),require("../../template-preview/WhatsApp/WhatsAppLikePreview.js"),require("../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js"),require("../../../constants/Theme.js"),require("../../curtain/CurtainHelper.js"),require("../../variable-picker-v3/model.js"),require("../../template-preview/models/TemplateMeta.js");var r=require("../../template-preview/models/WhatsAppTemplate.js");require("../../template-preview/models/Channels.js");var i=require("../../../assets/icons/alert_triangle.svg.js");const s={[r.TEMPLATE_QUALITY.YELLOW]:{icon:i.default,title:"Medium quality template",subline:"Meta has downgraded this template to a medium-quality rating due to negative feedback from multiple customers or low read rates. We recommend improving its content or choosing a different template to enhance delivery and engagement in your next campaign"},[r.TEMPLATE_QUALITY.RED]:{icon:i.default,title:"Low quality template",subline:"Meta has downgraded this template to a low-quality rating due to negative feedback from multiple customers or low read rates. We recommend improving its content or choosing a different template to enhance delivery and engagement in your next campaign"},[r.TEMPLATE_QUALITY.GREEN]:{icon:"",title:"",subline:"Here is your template's delivery and engagement stats from the last 30 days. Higher engagement today can lead to better delivery rates in the future."}},l=[{title:"Sent",icon:t.default,valName:"totalSent"},{title:"Delivered",icon:e.default,valName:"totalDelivered",percentValName:"deliveredPercentage"},{title:"Read",icon:a.default,valName:"totalReads",percentValName:"readPercentage"}];exports.ANALYTICS_ENGAGEMENT_MAP=l,exports.TEMPLATE_QUALITY_MAP=s;
package/dist/cjs/index.js CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./amplitude/index.js"),r=require("./components/template-preview/constants/regexPatterns.js"),t=require("./utils/StringUtils.js"),o=require("./constants/Theme.js"),n=require("./constants/zindex.js"),a=require("./components/checkBox/CheckBox.js"),i=require("./components/list-item/ListItem.js"),s=require("./components/pagination/Pagination.js"),p=require("./components/radioButton/RadioButton.js"),u=require("./components/toaster/Toaster.js"),c=require("./components/tooltips/Tooltip.js"),l=require("./components/spinner/Spinner.js"),d=require("./components/stepper/Stepper.js"),m=require("./components/tag/Tag.js"),T=require("./components/icon-button/IconButton.js"),x=require("./components/template-preview/TemplatePreview.js"),P=require("./components/template-preview/WhatsApp/WhatsAppLikePreview.js"),S=require("./components/template-preview/WhatsApp/WhatsAppLikePreviewV2.js"),A=require("./components/template-preview/helpers/SmsTemplateHelper.js"),C=require("./components/template-preview/helpers/WhatsAppFormatToHTML.js"),y=require("./components/template-preview/helpers/VariableEditorHelper.js"),O=require("./components/template-preview/models/TemplateMeta.js"),b=require("./components/template-preview/models/WhatsAppTemplate.js"),E=require("./components/template-preview/models/Channels.js"),j=require("./components/template-context-mapper/TemplateContextMapper.js"),h=require("./components/template-context-mapper/utils/getDataFromTemplateComponent.js"),R=require("./components/template-context-mapper/utils/validateIsUrl.js");require("./_virtual/_tslib.js");var g=require("./components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.js"),B=require("./components/template-context-mapper/modalElements/TemplateAnalyticsComponent.js"),_=require("./components/fab-menu/FABMenu.js"),I=require("./components/floating-action-button/FloatingActionButton.js"),q=require("./components/floating-action-button/FloatingActionButton.styles.js"),f=require("./components/image-compress/ImageCompress.js"),D=require("./components/TypographyStyle.js"),N=require("./components/button/Button.js"),w=require("./components/progress-bar/ProgressBarComponent.js");require("react/jsx-runtime");var k=require("./components/progress-bar-v2/ProgressBarV2.js"),L=require("./components/QueryBuilder/QueryBuilder.js"),M=require("./components/QueryBuilder/components/QueryBuilderNode/Base/BaseQueryBuilderNode.js"),V=require("./components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.js"),v=require("./components/QueryBuilder/redux/queryBuilder.reducer.js"),G=require("./components/QueryBuilder/redux/queryBuilderCache.reducer.js"),F=require("./components/QueryBuilder/types/QueryBuilderOperator.type.js"),U=require("./components/modals/styledModal.js"),H=require("./components/dropdown/DropdownPopover/index.js"),W=require("./components/dropdown/Dropdown.js"),Y=require("./components/dropdown/ChipDropdown.js"),Q=require("./components/dropdown/OpenedDropdown/components/OpennedDropdown.js"),K=require("./components/dropdown/MenuItem/MenuItem.js"),z=require("./components/analytics-card/AnalyticsCard.js"),Z=require("./components/analytics-card/AnalyticsCard.styled.js"),X=require("./components/input/Input.js"),J=require("./components/analytics-chips-and-dropdowns/AnalyticsChip.js"),$=require("./components/analytics-chips-and-dropdowns/AnalyticsDropdown.js"),ee=require("./components/analytics-chips-and-dropdowns/AnalyticsMultiChip.js"),re=require("./components/analytics-chips-and-dropdowns/AnalyticsMetric.js"),te=require("./components/analytics-chips-and-dropdowns/AnalyticsTrend.js"),oe=require("./components/analytics-chips-and-dropdowns/chart/LineChart/LineChart.js"),ne=require("./components/analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.js"),ae=require("./components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js"),ie=require("./components/analytics-chips-and-dropdowns/chart/Pie/PieChart.js"),se=require("./components/analytics-chips-and-dropdowns/chart/HorizontalBarGraph/HorizontalGraph.js"),pe=require("./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.js"),ue=require("./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.js"),ce=require("./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.model.js"),le=require("./components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/VerticalGraph.js"),de=require("./components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/FunnelVerticalBarGraph.js"),me=require("./components/analytics-chips-and-dropdowns/chart/heatmap/HeatMap.js"),Te=require("./components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.js"),xe=require("./components/analytics-chips-and-dropdowns/chart/VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js"),Pe=require("./components/analytics-chips-and-dropdowns/chart/utils/calcPercentage.js"),Se=require("./components/avatar/Avatar.js"),Ae=require("./components/avatar/AvatarHelper.js"),Ce=require("./components/alerts/Alert.js"),ye=require("./components/alerts/AlertHelper.js"),Oe=require("./components/thumbnail/Thumbnail.js"),be=require("./components/curtain/Curtain.js"),Ee=require("./components/datePicker/DatePicker.js"),je=require("./components/datePicker/DatePickerWrapper.js"),he=require("./components/switch/Switch.js"),Re=require("./components/plans/SubscriptionPlan.js"),ge=require("./components/plans/SubscriptionPlanSelector.js"),Be=require("./components/plans/NewSubscriptionPlan.js"),_e=require("./components/plans/SubscriptionPlansCollected.js"),Ie=require("./components/tabs/Tabs.js"),qe=require("./components/dynamic-tabs/DynamicTabs.js"),fe=require("./components/shimmer/ShimmerComponent/BikShimmer.js"),De=require("./components/TablePagination/TablePagination.js"),Ne=require("./components/TablePagination/TablePaginationCard.js"),we=require("./components/states-modal/StateModalComponent.js"),ke=require("./components/states-modal/DeleteConfirmationModal.js"),Le=require("./components/states/StateComponent.js"),Me=require("./components/states/ShopifyScopeWrapper.js"),Ve=require("./components/WhatsAppTextEditor/WhatsAppTextEditor.js"),ve=require("./components/WhatsAppTextEditor/WhatsAppTextEditorHeader.js"),Ge=require("./helpers/BaseWhatsappContentLang.helper.js"),Fe=require("./components/curtain/CurtainHelper.js"),Ue=require("./utils/resizeImage.js"),He=require("./components/variable-picker-v3/model.js"),We=require("./components/card-selection-modal/CardSelectionModal.js"),Ye=require("./components/image-cropper/BikImageCropper.js"),Qe=require("./components/image-cropper/BikImagePipeline/BikImagePipeline.js"),Ke=require("./components/buttonGroup/ButtonGroup.js"),ze=require("./components/accordion/Accordion.js"),Ze=require("./components/file-uploader/FileUploader.js"),Xe=require("./components/colourInput/ColourInput.js"),Je=require("./components/bik-layout/BikHeader.js"),$e=require("./components/bik-layout/BikLayout.js"),er=require("./components/bik-layout/BikProfile.js"),rr=require("./components/bik-layout/SimpleSidebar.js"),tr=require("./components/bik-layout/BikSidebar.js"),or=require("./components/bik-layout/FeatureModal.js"),nr=require("./components/bik-layout/SidebarSkeleton.js"),ar=require("./components/bik-layout/ShowShopifyRestrictedModal.js"),ir=require("./components/bik-layout/FeatureModalV2.js"),sr=require("./components/searchBar/searchBar.js"),pr=require("./components/custom-date-time/CustomDateTime.js"),ur=require("./components/product-picker/ProductPickerModal.js"),cr=require("./components/discount-modal/DiscountModal.js"),lr=require("./components/discount-modal/CouponExpiration/CouponExpiration.js"),dr=require("./components/discount-modal/type.js"),mr=require("./components/country-code-picker/CountryCodePicker.js"),Tr=require("./components/country-code-picker/CountryCodePicker.modal.js"),xr=require("./components/shimmer-image/ShimmerImage.js"),Pr=require("./components/product-picker-v2/modal.js"),Sr=require("./components/carousel/carousel.js"),Ar=require("./components/carousel-secondary/CarouselSecondary.js"),Cr=require("./components/access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.js"),yr=require("./components/radioList/RadioList.js"),Or=require("./components/checkList/CheckList.js"),br=require("./components/postPicker/postPicker.js"),Er=require("./components/dropdown-button/DropdownButton.js"),jr=require("./components/side-modal/SideModal.js"),hr=require("./components/keywords-input/KeywordsInput.js"),Rr=require("./components/add-variableV2/AddVariableV2SideModal.js"),gr=require("./components/add-variableV2/AddVariableV2.js"),Br=require("./components/navigation-hyperlink/NavigationHyperlink.js"),_r=require("./components/SearchFilter/index.js"),Ir=require("./components/input-with-vars/InputWithVariables.js"),qr=require("./components/dashboard-review-popup/DashboardReviewPopUp.js"),fr=require("./components/star-rating/StarRating.js"),Dr=require("./components/testimonial-card/TestimonialCard.js"),Nr=require("./components/slider/slider.js"),wr=require("./components/resizeImage/index.js"),kr=require("./utils/validator.js"),Lr=require("./components/carousel-preview/CarouselPreview.js"),Mr=require("./components/floater/floater.js"),Vr=require("./components/card-selector/CardSelector.js"),vr=require("./components/card-selector/CardSelectorGroup.js"),Gr=require("./components/variable-picker-v3/VariablePicker.js"),Fr=require("./components/action-button/ActionButtons.js"),Ur=require("./components/ai-modals/ActivateBikAI.js"),Hr=require("./components/ai-modals/AiSyncProgress.js"),Wr=require("./components/ai-modals/AiCreditsExhausted.js"),Yr=require("./components/ai-modals/AiCreditsLow.js"),Qr=require("./components/input-with-vars/customPortal.js"),Kr=require("./components/floating-input-dropdown/FloatingInputDropdown.js"),zr=require("./components/dropdown/MultilevelDropdownPopover/index.js"),Zr=require("./components/dropShadow/DropShadow.js"),Xr=require("./components/multi-level-dropdown/MultiLevelDropdown.js");exports.AmplitudeEvent=e.AmplitudeEvent,exports.regexPatterns=r,exports.StringUtils=t.default,exports.BASE_COLORS=o.BASE_COLORS,exports.COLORS=o.COLORS,exports.DEFAULT_THEME=o.DEFAULT_THEME,exports.FONTS=o.FONTS,exports.ComponentZindex=n.ComponentZindex,exports.CheckBox=a.CheckBox,exports.ListItem=i.ListItem,exports.Pagination=s.Pagination,exports.RadioButton=p.RadioButton,exports.Toaster=u.Toaster,exports.Tooltip=c.Tooltip,exports.PureSpinner=l.PureSpinner,exports.Spinner=l.Spinner,exports.Stepper=d.Stepper,exports.Tag=m.Tag,exports.IconButton=T.IconButton,exports.TemplatePreview=x.TemplatePreview,exports.WhatsappLikePreview=P.WhatsappLikePreview,exports.WhatsappLikePreviewV2=S.WhatsappLikePreviewV2,exports.renderVariableUIForPreview=A.renderVariableUIForPreview,exports.WhatsAppFormatToHTML=C.WhatsAppFormatToHTML,exports.VariableEditorHelper=y.VariableEditorHelper,Object.defineProperty(exports,"ACTIONS_TYPES",{enumerable:!0,get:function(){return O.ACTIONS_TYPES}}),exports.CUSTOM_URL_NAME=O.CUSTOM_URL_NAME,Object.defineProperty(exports,"HEADER_TYPES",{enumerable:!0,get:function(){return O.HEADER_TYPES}}),exports.STATIC_URL_CTA_OPTION=O.STATIC_URL_CTA_OPTION,Object.defineProperty(exports,"TEMPLATE_EDITOR",{enumerable:!0,get:function(){return O.TEMPLATE_EDITOR}}),Object.defineProperty(exports,"TEMPLATE_STATUS",{enumerable:!0,get:function(){return O.TEMPLATE_STATUS}}),Object.defineProperty(exports,"BUTTON_TYPE",{enumerable:!0,get:function(){return b.BUTTON_TYPE}}),Object.defineProperty(exports,"POD",{enumerable:!0,get:function(){return b.POD}}),Object.defineProperty(exports,"TEMPLATE_QUALITY",{enumerable:!0,get:function(){return b.TEMPLATE_QUALITY}}),Object.defineProperty(exports,"CHANNEL_TYPE",{enumerable:!0,get:function(){return E.CHANNEL_TYPE}}),exports.TemplateContextMapper=j.TemplateContextMapper,exports.getAllDataFromTemplateComponent=h.getAllDataFromTemplateComponent,exports.getAllDataFromWebpushTemplateComponent=h.getAllDataFromWebpushTemplateComponent,exports.isVariable=R.isVariable,exports.validateIsUrl=R.validateIsUrl,exports.TemplateAnalyticsSkeleton=g.TemplateAnalyticsSkeleton,exports.AnalyticsItem=B.AnalyticsItem,exports.RightPanelTemplateAnalytics=B.RightPanelTemplateAnalytics,exports.FABMenu=_.FABMenu,exports.FloatingActionButton=I.FloatingActionButton,Object.defineProperty(exports,"DROP_POSITION",{enumerable:!0,get:function(){return q.DROP_POSITION}}),exports.DropdownToggleContainer=q.DropdownToggleContainer,Object.defineProperty(exports,"FAB_POSITION",{enumerable:!0,get:function(){return q.FAB_POSITION}}),exports.FloatingActionButtonContainer=q.FloatingActionButtonContainer,exports.FloatingActionButtonOuterContainer=q.FloatingActionButtonOuterContainer,Object.defineProperty(exports,"MENU_ALIGNMENT",{enumerable:!0,get:function(){return q.MENU_ALIGNMENT}}),exports.StyledDropdown=q.StyledDropdown,exports.TooltipStyled=q.TooltipStyled,exports.ImageService=f.ImageService,exports.AiBodyCaption=D.AiBodyCaption,exports.AiBodyTiny=D.AiBodyTiny,exports.BodyCaption=D.BodyCaption,exports.BodyLarge=D.BodyLarge,exports.BodyPrimary=D.BodyPrimary,exports.BodyPrimaryLink=D.BodyPrimaryLink,exports.BodyRegular=D.BodyRegular,exports.BodySecondary=D.BodySecondary,exports.BodySecondaryLink=D.BodySecondaryLink,exports.BodySmall=D.BodySmall,exports.BodyTiny=D.BodyTiny,exports.ButtonLarge=D.ButtonLarge,exports.ButtonLargeAI=D.ButtonLargeAI,exports.ButtonRegular=D.ButtonRegular,exports.ButtonRegularAI=D.ButtonRegularAI,exports.Caption=D.Caption,exports.CaptionBold=D.CaptionBold,exports.Display=D.Display,exports.SmallRegular=D.SmallRegular,exports.SubHeading=D.SubHeading,exports.TextPlaceholder=D.TextPlaceholder,exports.Tiny=D.Tiny,exports.TitleFour=D.TitleFour,exports.TitleLarge=D.TitleLarge,exports.TitleMedium=D.TitleMedium,exports.TitleRegular=D.TitleRegular,exports.TitleSmall=D.TitleSmall,exports.TitleXlarge=D.TitleXlarge,exports.Button=N.Button,exports.ProgressBarComponent=w.ProgressBarComponent,exports.ProgressCompletedBar=w.ProgressCompletedBar,Object.defineProperty(exports,"ProgressBarType",{enumerable:!0,get:function(){return k.ProgressBarType}}),exports.ProgressBarV2=k.ProgressBarV2,Object.defineProperty(exports,"TextAlignment",{enumerable:!0,get:function(){return k.TextAlignment}}),exports.QueryBuilder=L.QueryBuilder,exports.BaseQueryBuilderNode=M.BaseQueryBuilderNode,exports.PropertyNode=V.PropertyNode,exports.PropertyNodeHeadless=V.PropertyNodeHeadless,exports.queryBuilderSlice=v.queryBuilderSlice,exports.queryBuilderCacheSlice=G.queryBuilderCacheSlice,Object.defineProperty(exports,"AD_STRING_OPERATORS",{enumerable:!0,get:function(){return F.AD_STRING_OPERATORS}}),Object.defineProperty(exports,"ANY_AD_OPERATORS",{enumerable:!0,get:function(){return F.ANY_AD_OPERATORS}}),Object.defineProperty(exports,"ANY_IG_OPERATORS",{enumerable:!0,get:function(){return F.ANY_IG_OPERATORS}}),Object.defineProperty(exports,"BOOLEAN_OPERATORS",{enumerable:!0,get:function(){return F.BOOLEAN_OPERATORS}}),Object.defineProperty(exports,"DATE_OPERATORS",{enumerable:!0,get:function(){return F.DATE_OPERATORS}}),Object.defineProperty(exports,"EVENT_VALUES",{enumerable:!0,get:function(){return F.EVENT_VALUES}}),Object.defineProperty(exports,"EXACTLY_OPERATORS",{enumerable:!0,get:function(){return F.EXACTLY_OPERATORS}}),Object.defineProperty(exports,"FREQUENCY_OPERATORS",{enumerable:!0,get:function(){return F.FREQUENCY_OPERATORS}}),Object.defineProperty(exports,"ICE_BREAKER_OPERATORS",{enumerable:!0,get:function(){return F.ICE_BREAKER_OPERATORS}}),Object.defineProperty(exports,"IG_STRING_OPERATORS",{enumerable:!0,get:function(){return F.IG_STRING_OPERATORS}}),Object.defineProperty(exports,"INTEGER_OPERATORS",{enumerable:!0,get:function(){return F.INTEGER_OPERATORS}}),Object.defineProperty(exports,"MAIL_SUBJECT_OPERATORS",{enumerable:!0,get:function(){return F.MAIL_SUBJECT_OPERATORS}}),Object.defineProperty(exports,"REACTION_OPERATORS",{enumerable:!0,get:function(){return F.REACTION_OPERATORS}}),Object.defineProperty(exports,"SPECIFIC_IG_OPERATORS",{enumerable:!0,get:function(){return F.SPECIFIC_IG_OPERATORS}}),Object.defineProperty(exports,"STRING_OPERATORS",{enumerable:!0,get:function(){return F.STRING_OPERATORS}}),Object.defineProperty(exports,"STRING_RESTRICTED_OPERATORS",{enumerable:!0,get:function(){return F.STRING_RESTRICTED_OPERATORS}}),Object.defineProperty(exports,"STRING_RESTRICTED_OPERATORS_2",{enumerable:!0,get:function(){return F.STRING_RESTRICTED_OPERATORS_2}}),Object.defineProperty(exports,"STRING_RESTRICTED_OPERATORS_3",{enumerable:!0,get:function(){return F.STRING_RESTRICTED_OPERATORS_3}}),exports.StyledModal=U.StyledModal,exports.DropdownPopover=H.DropdownPopover,exports.Dropdown=W.Dropdown,exports.ChipDropdown=Y.ChipDropdown,exports.ChipDropdownContainer=Y.ChipDropdownContainer,exports.OpenedDropdown=Q.OpenedDropdown,exports.MenuItemDropdown=K.MenuItemDropdown,exports.AnalyticsCard=z.AnalyticsCard,exports.AnalyticsContainer=Z.AnalyticsContainer,exports.CardDataContainer=Z.CardDataContainer,exports.Input=X.Input,exports.AnalyticsChip=J.AnalyticsChip,exports.AnalyticsDropdown=$.AnalyticsDropdown,exports.EachItem=$.EachItem,exports.formatDate=$.formatDate,exports.AnalyticsMultiChip=ee.AnalyticsMultiChip,exports.AnalyticsMetric=re.AnalyticsMetric,exports.AnalyticsTrend=te.AnalyticsTrend,exports.LineChart=oe.LineChart,exports.LinearChipGroupedChart=ne.LinearChipGroupedChart,exports.Card=ae.Card,exports.PieChartAnalytics=ae.PieChartAnalytics,exports.PieChart=ie.PieChart,exports.HorizontalGraph=se.HorizontalGraph,exports.StackedBarChart=pe.StackedBarChart,exports.StackedBarDistributionChart=ue.StackedBarDistributionChart,Object.defineProperty(exports,"GRAPH_ORIENTATION",{enumerable:!0,get:function(){return ce.GRAPH_ORIENTATION}}),exports.VerticalGraph=le.VerticalGraph,exports.FunnelVerticalBarGraph=de.FunnelVerticalBarGraph,Object.defineProperty(exports,"HEAT",{enumerable:!0,get:function(){return me.HEAT}}),exports.HEAT_COLORS=me.HEAT_COLORS,Object.defineProperty(exports,"HEAT_GRADING_TYPE",{enumerable:!0,get:function(){return me.HEAT_GRADING_TYPE}}),exports.HeatMap=me.HeatMap,exports.HeatBoxStyled=Te.HeatBoxStyled,exports.HeatMapVertical=Te.HeatMapVertical,exports.VerticalBarAndLinearGraph=xe.VerticalBarAndLinearGraph,Object.defineProperty(exports,"TruncateValue",{enumerable:!0,get:function(){return Pe.TruncateValue}}),exports.calculatePercentage=Pe.calculatePercentage,exports.roundNumber=Pe.roundNumber,exports.truncateValueForIndianStore=Pe.truncateValueForIndianStore,exports.truncateValueForInternationalStore=Pe.truncateValueForInternationalStore,exports.truncateValueTo10K=Pe.truncateValueTo10K,exports.truncateValueToA=Pe.truncateValueToA,exports.truncateValueToB=Pe.truncateValueToB,exports.truncateValueToC=Pe.truncateValueToC,exports.truncateValueToK=Pe.truncateValueToK,exports.truncateValueToL=Pe.truncateValueToL,exports.truncateValueToM=Pe.truncateValueToM,exports.truncateValueToT=Pe.truncateValueToT,exports.AVATAR_SIZE_VS_ICON_SIZE_MAP=Se.AVATAR_SIZE_VS_ICON_SIZE_MAP,exports.Avatar=Se.Avatar,exports.BACKGROUND_VS_TEXT_COLOR_MAP=Se.BACKGROUND_VS_TEXT_COLOR_MAP,Object.defineProperty(exports,"MESSAGE_CHANNELS",{enumerable:!0,get:function(){return Se.MESSAGE_CHANNELS}}),Object.defineProperty(exports,"AVATAR_BACKGROUND",{enumerable:!0,get:function(){return Ae.AVATAR_BACKGROUND}}),exports.AVATAR_SIZE_MAP=Ae.AVATAR_SIZE_MAP,Object.defineProperty(exports,"AVATAR_TYPES",{enumerable:!0,get:function(){return Ae.AVATAR_TYPES}}),Object.defineProperty(exports,"SIZE",{enumerable:!0,get:function(){return Ae.SIZE}}),exports.Alert=Ce.Alert,Object.defineProperty(exports,"ALERT_TYPES",{enumerable:!0,get:function(){return ye.ALERT_TYPES}}),exports.COLOR_CONFIG_MAP=ye.COLOR_CONFIG_MAP,Object.defineProperty(exports,"CONTENT_POSITION",{enumerable:!0,get:function(){return ye.CONTENT_POSITION}}),Object.defineProperty(exports,"RATIO",{enumerable:!0,get:function(){return Oe.RATIO}}),exports.Thumbnail=Oe.Thumbnail,exports.Curtain=be.Curtain,exports.DatePicker=Ee.DatePicker,Object.defineProperty(exports,"DateButtonType",{enumerable:!0,get:function(){return je.DateButtonType}}),exports.DatePickerWrapper=je.DatePickerWrapper,exports.Loader=he.Loader,exports.Switch=he.Switch,exports.SwitchContainer=he.SwitchContainer,exports.Thumb=he.Thumb,exports.SubscriptionPlan=Re.SubscriptionPlan,exports.BottomWrapper=ge.BottomWrapper,exports.HeaderWrapper=ge.HeaderWrapper,exports.SubscriptionPlanSelector=ge.SubscriptionPlanSelector,exports.defaultTabs=ge.defaultTabs,exports.NewSubscriptionPlan=Be.NewSubscriptionPlan,exports.SubscriptionPlansCollected=_e.SubscriptionPlansCollected,exports.TabItemComponent=Ie.TabItemComponent,exports.Tabs=Ie.Tabs,exports.DynamicTabs=qe.DynamicTabs,exports.BikShimmer=fe.BikShimmer,exports.TablePagination=De.TablePagination,exports.TablePaginationCard=Ne.TablePaginationCard,exports.TablePaginationCardStyled=Ne.TablePaginationCardStyled,exports.StateModalComponent=we.StateModalComponent,exports.DeleteConfirmationModal=ke.DeleteConfirmationModal,Object.defineProperty(exports,"ButtonActions",{enumerable:!0,get:function(){return Le.ButtonActions}}),Object.defineProperty(exports,"ButtonTypes",{enumerable:!0,get:function(){return Le.ButtonTypes}}),exports.StateComponent=Le.StateComponent,Object.defineProperty(exports,"StateInterface",{enumerable:!0,get:function(){return Le.StateInterface}}),exports.ShopifyScopeWrapper=Me.ShopifyScopeWrapper,exports.WhatsAppTextEditor=Ve.WhatsAppTextEditor,exports.CustomRightBorder=ve.CustomRightBorder,Object.defineProperty(exports,"EditorActionTypes",{enumerable:!0,get:function(){return ve.EditorActionTypes}}),exports.WhatsAppTextEditorHeader=ve.WhatsAppTextEditorHeader,exports.BaseWhatsappContentLangHelper=Ge.BaseWhatsappContentLangHelper,exports.CURTAIN_COLOR_CONFIG_MAP=Fe.CURTAIN_COLOR_CONFIG_MAP,Object.defineProperty(exports,"CURTAIN_MODE",{enumerable:!0,get:function(){return Fe.CURTAIN_MODE}}),Object.defineProperty(exports,"CURTAIN_TYPES",{enumerable:!0,get:function(){return Fe.CURTAIN_TYPES}}),exports.resizeImage=Ue.resizeImage,Object.defineProperty(exports,"PickerType",{enumerable:!0,get:function(){return He.PickerType}}),exports.CardSelectionModal=We.CardSelectionModal,exports.BikImageCropper=Ye.BikImageCropper,exports.BikImagePipeline=Qe.BikImagePipeline,exports.ButtonGroup=Ke.ButtonGroup,exports.BikAccordion=ze.BikAccordion,exports.FileUploader=Ze.FileUploader,exports.ColourInput=Xe.ColourInput,exports.BikHeader=Je.BikHeader,exports.BikLayout=$e.BikLayout,exports.BikProfile=er.BikProfile,exports.SimpleSidebar=rr.SimpleSidebar,exports.BikSidebar=tr.BikSidebar,exports.FeatureModal=or.FeatureModal,exports.SidebarSkeleton=nr.SidebarSkeleton,exports.ShowShopifyRestrictedModal=ar.ShowShopifyRestrictedModal,exports.FeatureModalV2=ir.FeatureModalV2,exports.SearchBar=sr.SearchBar,exports.CustomDateTime=pr.CustomDateTime,exports.PricePleaseProductPicker=ur.PricePleaseProductPicker,exports.ProductPickerContent=ur.ProductPickerContent,exports.DiscountModal=cr.DiscountModal,exports.CouponExpiration=lr.CouponExpiration,Object.defineProperty(exports,"COUPON_EXPIRATION",{enumerable:!0,get:function(){return dr.COUPON_EXPIRATION}}),Object.defineProperty(exports,"DISCOUNT_APPLIES_TO",{enumerable:!0,get:function(){return dr.DISCOUNT_APPLIES_TO}}),Object.defineProperty(exports,"DISCOUNT_TARGET_SELECTION",{enumerable:!0,get:function(){return dr.DISCOUNT_TARGET_SELECTION}}),Object.defineProperty(exports,"DISCOUNT_TARGET_TYPES",{enumerable:!0,get:function(){return dr.DISCOUNT_TARGET_TYPES}}),Object.defineProperty(exports,"DISCOUNT_TYPES",{enumerable:!0,get:function(){return dr.DISCOUNT_TYPES}}),Object.defineProperty(exports,"DISCOUNT_VALUE_TYPES",{enumerable:!0,get:function(){return dr.DISCOUNT_VALUE_TYPES}}),Object.defineProperty(exports,"MIN_PURCHASE_REQUIREMENT",{enumerable:!0,get:function(){return dr.MIN_PURCHASE_REQUIREMENT}}),Object.defineProperty(exports,"OFFER_APPLIES_TO",{enumerable:!0,get:function(){return dr.OFFER_APPLIES_TO}}),exports.initialDynamicCouponErrorState=dr.initialDynamicCouponErrorState,exports.initialStaticCouponErrorState=dr.initialStaticCouponErrorState,exports.CountryCodePicker=mr.CountryCodePicker,exports.CountriesData=Tr.CountriesData,exports.DEFAULT_IMAGE=xr.DEFAULT_IMAGE,exports.ShimmerImage=xr.ShimmerImage,exports.ProductPickerModal=Pr.ProductPickerModal,Object.defineProperty(exports,"ScreenName",{enumerable:!0,get:function(){return Pr.ScreenName}}),exports.Carousel=Sr.Carousel,exports.CarouselSecondary=Ar.CarouselSecondary,Object.defineProperty(exports,"CarouselVersion",{enumerable:!0,get:function(){return Ar.CarouselVersion}}),exports.AccessTokenTroubleshootDialog=Cr.AccessTokenTroubleshootDialog,exports.RadioList=yr.RadioList,exports.CheckList=Or.CheckList,Object.defineProperty(exports,"DateKeys",{enumerable:!0,get:function(){return br.DateKeys}}),Object.defineProperty(exports,"MEDIA_TYPES",{enumerable:!0,get:function(){return br.MEDIA_TYPES}}),exports.PostPicker=br.PostPicker,exports.dateOptions=br.dateOptions,exports.DropdownButton=Er.DropdownButton,exports.SideModal=jr.SideModal,exports.KeywordsInput=hr.KeywordsInput,exports.AddVariableV2SideModal=Rr.AddVariableV2SideModal,exports.AddVariableV2=gr.AddVariableV2,exports.NaLinkWrapper=Br.NaLinkWrapper,exports.NavigationHyperlink=Br.NavigationHyperlink,exports.SearchFilter=_r.SearchFilter,exports.InputWithVariables=Ir.InputWithVariables,exports.DashboardReviewPopUp=qr.DashboardReviewPopUp,exports.StarRating=fr.StarRating,exports.TestimonialCard=Dr.TestimonialCard,exports.BikSlider=Nr.BikSlider,exports.ResizableImage=wr.ResizableImage,exports.validateURL=kr.validateURL,exports.CarouselPreview=Lr.CarouselPreview,exports.Floater=Mr.Floater,exports.CardSelector=Vr.CardSelector,exports.CardSelectorGroup=vr.CardSelectorGroup,exports.VariablePicker=Gr.VariablePicker,exports.ActionButtons=Fr.ActionButtons,exports.ActivateBikAi=Ur.ActivateBikAi,exports.AiSyncProgress=Hr.AiSyncProgress,exports.AiCreditsExhausted=Wr.AiCreditsExhausted,exports.AiCreditsLow=Yr.AiCreditsLow,exports.CustomPortal=Qr.CustomPortal,exports.FloatingInputDropdown=Kr.FloatingInputDropdown,exports.MultilevelDropdownPopover=zr.MultilevelDropdownPopover,exports.DropShadow=Zr.DropShadow,exports.MultiLevelDropdown=Xr.MultiLevelDropdown;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./amplitude/index.js"),r=require("./components/template-preview/constants/regexPatterns.js"),t=require("./utils/StringUtils.js"),o=require("./constants/Theme.js"),n=require("./constants/zindex.js"),a=require("./components/checkBox/CheckBox.js"),i=require("./components/list-item/ListItem.js"),p=require("./components/pagination/Pagination.js"),s=require("./components/radioButton/RadioButton.js"),u=require("./components/toaster/Toaster.js"),c=require("./components/tooltips/Tooltip.js"),l=require("./components/spinner/Spinner.js"),d=require("./components/stepper/Stepper.js"),m=require("./components/tag/Tag.js"),T=require("./components/icon-button/IconButton.js"),x=require("./components/template-preview/TemplatePreview.js"),P=require("./components/template-preview/WhatsApp/WhatsAppLikePreview.js"),S=require("./components/template-preview/WhatsApp/WhatsAppLikePreviewV2.js"),A=require("./components/template-preview/helpers/SmsTemplateHelper.js"),C=require("./components/template-preview/helpers/WhatsAppFormatToHTML.js"),y=require("./components/template-preview/helpers/VariableEditorHelper.js"),O=require("./components/template-preview/models/TemplateMeta.js"),b=require("./components/template-preview/models/WhatsAppTemplate.js"),E=require("./components/template-preview/models/Channels.js"),j=require("./components/template-context-mapper/TemplateContextMapper.js"),h=require("./components/template-context-mapper/utils/getDataFromTemplateComponent.js"),R=require("./components/template-context-mapper/utils/validateIsUrl.js");require("./_virtual/_tslib.js");var g=require("./components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.js"),B=require("./components/template-context-mapper/modalElements/TemplateAnalyticsComponent.js"),_=require("./components/fab-menu/FABMenu.js"),I=require("./components/floating-action-button/FloatingActionButton.js"),q=require("./components/floating-action-button/FloatingActionButton.styles.js"),f=require("./components/image-compress/ImageCompress.js"),D=require("./components/TypographyStyle.js"),N=require("./components/button/Button.js"),w=require("./components/progress-bar/ProgressBarComponent.js");require("react/jsx-runtime");var k=require("./components/progress-bar-v2/ProgressBarV2.js"),L=require("./components/QueryBuilder/QueryBuilder.js"),M=require("./components/QueryBuilder/components/QueryBuilderNode/Base/BaseQueryBuilderNode.js"),V=require("./components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.js"),v=require("./components/QueryBuilder/redux/queryBuilder.reducer.js"),G=require("./components/QueryBuilder/redux/queryBuilderCache.reducer.js"),F=require("./components/QueryBuilder/types/QueryBuilderOperator.type.js"),U=require("./components/modals/styledModal.js"),H=require("./components/dropdown/DropdownPopover/index.js"),W=require("./components/dropdown/Dropdown.js"),Y=require("./components/dropdown/ChipDropdown.js"),Q=require("./components/dropdown/OpenedDropdown/components/OpennedDropdown.js"),K=require("./components/dropdown/MenuItem/MenuItem.js"),z=require("./components/analytics-card/AnalyticsCard.js"),Z=require("./components/analytics-card/AnalyticsCard.styled.js"),X=require("./components/input/Input.js"),J=require("./components/analytics-chips-and-dropdowns/AnalyticsChip.js"),$=require("./components/analytics-chips-and-dropdowns/AnalyticsDropdown.js"),ee=require("./components/analytics-chips-and-dropdowns/AnalyticsMultiChip.js"),re=require("./components/analytics-chips-and-dropdowns/AnalyticsMetric.js"),te=require("./components/analytics-chips-and-dropdowns/AnalyticsTrend.js"),oe=require("./components/analytics-chips-and-dropdowns/chart/LineChart/LineChart.js"),ne=require("./components/analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.js"),ae=require("./components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js"),ie=require("./components/analytics-chips-and-dropdowns/chart/Pie/PieChart.js"),pe=require("./components/analytics-chips-and-dropdowns/chart/HorizontalBarGraph/HorizontalGraph.js"),se=require("./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.js"),ue=require("./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.js"),ce=require("./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.model.js"),le=require("./components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/VerticalGraph.js"),de=require("./components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/FunnelVerticalBarGraph.js"),me=require("./components/analytics-chips-and-dropdowns/chart/heatmap/HeatMap.js"),Te=require("./components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.js"),xe=require("./components/analytics-chips-and-dropdowns/chart/VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js"),Pe=require("./components/analytics-chips-and-dropdowns/chart/utils/calcPercentage.js"),Se=require("./components/avatar/Avatar.js"),Ae=require("./components/avatar/AvatarHelper.js"),Ce=require("./components/alerts/Alert.js"),ye=require("./components/alerts/AlertHelper.js"),Oe=require("./components/thumbnail/Thumbnail.js"),be=require("./components/curtain/Curtain.js"),Ee=require("./components/datePicker/DatePicker.js"),je=require("./components/datePicker/DatePickerWrapper.js"),he=require("./components/switch/Switch.js"),Re=require("./components/plans/SubscriptionPlan.js"),ge=require("./components/plans/SubscriptionPlanSelector.js"),Be=require("./components/plans/NewSubscriptionPlan.js"),_e=require("./components/plans/SubscriptionPlansCollected.js"),Ie=require("./components/tabs/Tabs.js"),qe=require("./components/dynamic-tabs/DynamicTabs.js"),fe=require("./components/shimmer/ShimmerComponent/BikShimmer.js"),De=require("./components/TablePagination/TablePagination.js"),Ne=require("./components/TablePagination/TablePaginationCard.js"),we=require("./components/states-modal/StateModalComponent.js"),ke=require("./components/states-modal/DeleteConfirmationModal.js"),Le=require("./components/states/StateComponent.js"),Me=require("./components/states/ShopifyScopeWrapper.js"),Ve=require("./components/WhatsAppTextEditor/WhatsAppTextEditor.js"),ve=require("./components/WhatsAppTextEditor/WhatsAppTextEditorHeader.js"),Ge=require("./helpers/BaseWhatsappContentLang.helper.js"),Fe=require("./components/curtain/CurtainHelper.js"),Ue=require("./utils/resizeImage.js"),He=require("./components/variable-picker-v3/model.js"),We=require("./components/card-selection-modal/CardSelectionModal.js"),Ye=require("./components/image-cropper/BikImageCropper.js"),Qe=require("./components/image-cropper/BikImagePipeline/BikImagePipeline.js"),Ke=require("./components/buttonGroup/ButtonGroup.js"),ze=require("./components/accordion/Accordion.js"),Ze=require("./components/file-uploader/FileUploader.js"),Xe=require("./components/colourInput/ColourInput.js"),Je=require("./components/bik-layout/BikHeader.js"),$e=require("./components/bik-layout/BikLayout.js"),er=require("./components/bik-layout/BikProfile.js"),rr=require("./components/bik-layout/SimpleSidebar.js"),tr=require("./components/bik-layout/BikSidebar.js"),or=require("./components/bik-layout/FeatureModal.js"),nr=require("./components/bik-layout/SidebarSkeleton.js"),ar=require("./components/bik-layout/ShowShopifyRestrictedModal.js"),ir=require("./components/bik-layout/FeatureModalV2.js"),pr=require("./components/searchBar/searchBar.js"),sr=require("./components/custom-date-time/CustomDateTime.js"),ur=require("./components/product-picker/ProductPickerModal.js"),cr=require("./components/discount-modal/DiscountModal.js"),lr=require("./components/discount-modal/CouponExpiration/CouponExpiration.js"),dr=require("./components/discount-modal/type.js"),mr=require("./components/country-code-picker/CountryCodePicker.js"),Tr=require("./components/country-code-picker/CountryCodePicker.modal.js"),xr=require("./components/shimmer-image/ShimmerImage.js"),Pr=require("./components/product-picker-v2/modal.js"),Sr=require("./components/carousel/carousel.js"),Ar=require("./components/carousel-secondary/CarouselSecondary.js"),Cr=require("./components/access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.js"),yr=require("./components/radioList/RadioList.js"),Or=require("./components/checkList/CheckList.js"),br=require("./components/postPicker/postPicker.js"),Er=require("./components/dropdown-button/DropdownButton.js"),jr=require("./components/side-modal/SideModal.js"),hr=require("./components/keywords-input/KeywordsInput.js"),Rr=require("./components/add-variableV2/AddVariableV2SideModal.js"),gr=require("./components/add-variableV2/AddVariableV2.js"),Br=require("./components/navigation-hyperlink/NavigationHyperlink.js"),_r=require("./components/SearchFilter/index.js"),Ir=require("./components/input-with-vars/InputWithVariables.js"),qr=require("./components/dashboard-review-popup/DashboardReviewPopUp.js"),fr=require("./components/star-rating/StarRating.js"),Dr=require("./components/testimonial-card/TestimonialCard.js"),Nr=require("./components/slider/slider.js"),wr=require("./components/resizeImage/index.js"),kr=require("./utils/validator.js"),Lr=require("./components/carousel-preview/CarouselPreview.js"),Mr=require("./components/floater/floater.js"),Vr=require("./components/card-selector/CardSelector.js"),vr=require("./components/card-selector/CardSelectorGroup.js"),Gr=require("./components/variable-picker-v3/VariablePicker.js"),Fr=require("./components/action-button/ActionButtons.js"),Ur=require("./components/ai-modals/ActivateBikAI.js"),Hr=require("./components/ai-modals/AiSyncProgress.js"),Wr=require("./components/ai-modals/AiCreditsExhausted.js"),Yr=require("./components/ai-modals/AiCreditsLow.js"),Qr=require("./components/input-with-vars/customPortal.js"),Kr=require("./components/floating-input-dropdown/FloatingInputDropdown.js"),zr=require("./components/dropdown/MultilevelDropdownPopover/index.js"),Zr=require("./components/dropShadow/DropShadow.js"),Xr=require("./components/multi-level-dropdown/MultiLevelDropdown.js");exports.AmplitudeEvent=e.AmplitudeEvent,exports.regexPatterns=r,exports.StringUtils=t.default,exports.BASE_COLORS=o.BASE_COLORS,exports.COLORS=o.COLORS,exports.DEFAULT_THEME=o.DEFAULT_THEME,exports.FONTS=o.FONTS,exports.ComponentZindex=n.ComponentZindex,exports.CheckBox=a.CheckBox,exports.ListItem=i.ListItem,exports.Pagination=p.Pagination,exports.RadioButton=s.RadioButton,exports.Toaster=u.Toaster,exports.Tooltip=c.Tooltip,exports.PureSpinner=l.PureSpinner,exports.Spinner=l.Spinner,exports.Stepper=d.Stepper,exports.Tag=m.Tag,exports.IconButton=T.IconButton,exports.TemplatePreview=x.TemplatePreview,exports.WhatsappLikePreview=P.WhatsappLikePreview,exports.WhatsappLikePreviewV2=S.WhatsappLikePreviewV2,exports.renderVariableUIForPreview=A.renderVariableUIForPreview,exports.WhatsAppFormatToHTML=C.WhatsAppFormatToHTML,exports.VariableEditorHelper=y.VariableEditorHelper,Object.defineProperty(exports,"ACTIONS_TYPES",{enumerable:!0,get:function(){return O.ACTIONS_TYPES}}),exports.CUSTOM_URL_NAME=O.CUSTOM_URL_NAME,Object.defineProperty(exports,"HEADER_TYPES",{enumerable:!0,get:function(){return O.HEADER_TYPES}}),exports.STATIC_URL_CTA_OPTION=O.STATIC_URL_CTA_OPTION,Object.defineProperty(exports,"TEMPLATE_EDITOR",{enumerable:!0,get:function(){return O.TEMPLATE_EDITOR}}),Object.defineProperty(exports,"TEMPLATE_STATUS",{enumerable:!0,get:function(){return O.TEMPLATE_STATUS}}),Object.defineProperty(exports,"BUTTON_TYPE",{enumerable:!0,get:function(){return b.BUTTON_TYPE}}),Object.defineProperty(exports,"POD",{enumerable:!0,get:function(){return b.POD}}),Object.defineProperty(exports,"TEMPLATE_QUALITY",{enumerable:!0,get:function(){return b.TEMPLATE_QUALITY}}),Object.defineProperty(exports,"CHANNEL_TYPE",{enumerable:!0,get:function(){return E.CHANNEL_TYPE}}),exports.TemplateContextMapper=j.TemplateContextMapper,exports.getAllDataFromTemplateComponent=h.getAllDataFromTemplateComponent,exports.getAllDataFromWebpushTemplateComponent=h.getAllDataFromWebpushTemplateComponent,exports.isVariable=R.isVariable,exports.validateIsUrl=R.validateIsUrl,exports.TemplateAnalyticsSkeleton=g.TemplateAnalyticsSkeleton,exports.AnalyticsItem=B.AnalyticsItem,exports.RightPanelTemplateAnalytics=B.RightPanelTemplateAnalytics,exports.TemplateAnalyticsComponent=B.TemplateAnalyticsComponent,exports.FABMenu=_.FABMenu,exports.FloatingActionButton=I.FloatingActionButton,Object.defineProperty(exports,"DROP_POSITION",{enumerable:!0,get:function(){return q.DROP_POSITION}}),exports.DropdownToggleContainer=q.DropdownToggleContainer,Object.defineProperty(exports,"FAB_POSITION",{enumerable:!0,get:function(){return q.FAB_POSITION}}),exports.FloatingActionButtonContainer=q.FloatingActionButtonContainer,exports.FloatingActionButtonOuterContainer=q.FloatingActionButtonOuterContainer,Object.defineProperty(exports,"MENU_ALIGNMENT",{enumerable:!0,get:function(){return q.MENU_ALIGNMENT}}),exports.StyledDropdown=q.StyledDropdown,exports.TooltipStyled=q.TooltipStyled,exports.ImageService=f.ImageService,exports.AiBodyCaption=D.AiBodyCaption,exports.AiBodyTiny=D.AiBodyTiny,exports.BodyCaption=D.BodyCaption,exports.BodyLarge=D.BodyLarge,exports.BodyPrimary=D.BodyPrimary,exports.BodyPrimaryLink=D.BodyPrimaryLink,exports.BodyRegular=D.BodyRegular,exports.BodySecondary=D.BodySecondary,exports.BodySecondaryLink=D.BodySecondaryLink,exports.BodySmall=D.BodySmall,exports.BodyTiny=D.BodyTiny,exports.ButtonLarge=D.ButtonLarge,exports.ButtonLargeAI=D.ButtonLargeAI,exports.ButtonRegular=D.ButtonRegular,exports.ButtonRegularAI=D.ButtonRegularAI,exports.Caption=D.Caption,exports.CaptionBold=D.CaptionBold,exports.Display=D.Display,exports.SmallRegular=D.SmallRegular,exports.SubHeading=D.SubHeading,exports.TextPlaceholder=D.TextPlaceholder,exports.Tiny=D.Tiny,exports.TitleFour=D.TitleFour,exports.TitleLarge=D.TitleLarge,exports.TitleMedium=D.TitleMedium,exports.TitleRegular=D.TitleRegular,exports.TitleSmall=D.TitleSmall,exports.TitleXlarge=D.TitleXlarge,exports.Button=N.Button,exports.ProgressBarComponent=w.ProgressBarComponent,exports.ProgressCompletedBar=w.ProgressCompletedBar,Object.defineProperty(exports,"ProgressBarType",{enumerable:!0,get:function(){return k.ProgressBarType}}),exports.ProgressBarV2=k.ProgressBarV2,Object.defineProperty(exports,"TextAlignment",{enumerable:!0,get:function(){return k.TextAlignment}}),exports.QueryBuilder=L.QueryBuilder,exports.BaseQueryBuilderNode=M.BaseQueryBuilderNode,exports.PropertyNode=V.PropertyNode,exports.PropertyNodeHeadless=V.PropertyNodeHeadless,exports.queryBuilderSlice=v.queryBuilderSlice,exports.queryBuilderCacheSlice=G.queryBuilderCacheSlice,Object.defineProperty(exports,"AD_STRING_OPERATORS",{enumerable:!0,get:function(){return F.AD_STRING_OPERATORS}}),Object.defineProperty(exports,"ANY_AD_OPERATORS",{enumerable:!0,get:function(){return F.ANY_AD_OPERATORS}}),Object.defineProperty(exports,"ANY_IG_OPERATORS",{enumerable:!0,get:function(){return F.ANY_IG_OPERATORS}}),Object.defineProperty(exports,"BOOLEAN_OPERATORS",{enumerable:!0,get:function(){return F.BOOLEAN_OPERATORS}}),Object.defineProperty(exports,"DATE_OPERATORS",{enumerable:!0,get:function(){return F.DATE_OPERATORS}}),Object.defineProperty(exports,"EVENT_VALUES",{enumerable:!0,get:function(){return F.EVENT_VALUES}}),Object.defineProperty(exports,"EXACTLY_OPERATORS",{enumerable:!0,get:function(){return F.EXACTLY_OPERATORS}}),Object.defineProperty(exports,"FREQUENCY_OPERATORS",{enumerable:!0,get:function(){return F.FREQUENCY_OPERATORS}}),Object.defineProperty(exports,"ICE_BREAKER_OPERATORS",{enumerable:!0,get:function(){return F.ICE_BREAKER_OPERATORS}}),Object.defineProperty(exports,"IG_STRING_OPERATORS",{enumerable:!0,get:function(){return F.IG_STRING_OPERATORS}}),Object.defineProperty(exports,"INTEGER_OPERATORS",{enumerable:!0,get:function(){return F.INTEGER_OPERATORS}}),Object.defineProperty(exports,"MAIL_SUBJECT_OPERATORS",{enumerable:!0,get:function(){return F.MAIL_SUBJECT_OPERATORS}}),Object.defineProperty(exports,"REACTION_OPERATORS",{enumerable:!0,get:function(){return F.REACTION_OPERATORS}}),Object.defineProperty(exports,"SPECIFIC_IG_OPERATORS",{enumerable:!0,get:function(){return F.SPECIFIC_IG_OPERATORS}}),Object.defineProperty(exports,"STRING_OPERATORS",{enumerable:!0,get:function(){return F.STRING_OPERATORS}}),Object.defineProperty(exports,"STRING_RESTRICTED_OPERATORS",{enumerable:!0,get:function(){return F.STRING_RESTRICTED_OPERATORS}}),Object.defineProperty(exports,"STRING_RESTRICTED_OPERATORS_2",{enumerable:!0,get:function(){return F.STRING_RESTRICTED_OPERATORS_2}}),Object.defineProperty(exports,"STRING_RESTRICTED_OPERATORS_3",{enumerable:!0,get:function(){return F.STRING_RESTRICTED_OPERATORS_3}}),exports.StyledModal=U.StyledModal,exports.DropdownPopover=H.DropdownPopover,exports.Dropdown=W.Dropdown,exports.ChipDropdown=Y.ChipDropdown,exports.ChipDropdownContainer=Y.ChipDropdownContainer,exports.OpenedDropdown=Q.OpenedDropdown,exports.MenuItemDropdown=K.MenuItemDropdown,exports.AnalyticsCard=z.AnalyticsCard,exports.AnalyticsContainer=Z.AnalyticsContainer,exports.CardDataContainer=Z.CardDataContainer,exports.Input=X.Input,exports.AnalyticsChip=J.AnalyticsChip,exports.AnalyticsDropdown=$.AnalyticsDropdown,exports.EachItem=$.EachItem,exports.formatDate=$.formatDate,exports.AnalyticsMultiChip=ee.AnalyticsMultiChip,exports.AnalyticsMetric=re.AnalyticsMetric,exports.AnalyticsTrend=te.AnalyticsTrend,exports.LineChart=oe.LineChart,exports.LinearChipGroupedChart=ne.LinearChipGroupedChart,exports.Card=ae.Card,exports.PieChartAnalytics=ae.PieChartAnalytics,exports.PieChart=ie.PieChart,exports.HorizontalGraph=pe.HorizontalGraph,exports.StackedBarChart=se.StackedBarChart,exports.StackedBarDistributionChart=ue.StackedBarDistributionChart,Object.defineProperty(exports,"GRAPH_ORIENTATION",{enumerable:!0,get:function(){return ce.GRAPH_ORIENTATION}}),exports.VerticalGraph=le.VerticalGraph,exports.FunnelVerticalBarGraph=de.FunnelVerticalBarGraph,Object.defineProperty(exports,"HEAT",{enumerable:!0,get:function(){return me.HEAT}}),exports.HEAT_COLORS=me.HEAT_COLORS,Object.defineProperty(exports,"HEAT_GRADING_TYPE",{enumerable:!0,get:function(){return me.HEAT_GRADING_TYPE}}),exports.HeatMap=me.HeatMap,exports.HeatBoxStyled=Te.HeatBoxStyled,exports.HeatMapVertical=Te.HeatMapVertical,exports.VerticalBarAndLinearGraph=xe.VerticalBarAndLinearGraph,Object.defineProperty(exports,"TruncateValue",{enumerable:!0,get:function(){return Pe.TruncateValue}}),exports.calculatePercentage=Pe.calculatePercentage,exports.roundNumber=Pe.roundNumber,exports.truncateValueForIndianStore=Pe.truncateValueForIndianStore,exports.truncateValueForInternationalStore=Pe.truncateValueForInternationalStore,exports.truncateValueTo10K=Pe.truncateValueTo10K,exports.truncateValueToA=Pe.truncateValueToA,exports.truncateValueToB=Pe.truncateValueToB,exports.truncateValueToC=Pe.truncateValueToC,exports.truncateValueToK=Pe.truncateValueToK,exports.truncateValueToL=Pe.truncateValueToL,exports.truncateValueToM=Pe.truncateValueToM,exports.truncateValueToT=Pe.truncateValueToT,exports.AVATAR_SIZE_VS_ICON_SIZE_MAP=Se.AVATAR_SIZE_VS_ICON_SIZE_MAP,exports.Avatar=Se.Avatar,exports.BACKGROUND_VS_TEXT_COLOR_MAP=Se.BACKGROUND_VS_TEXT_COLOR_MAP,Object.defineProperty(exports,"MESSAGE_CHANNELS",{enumerable:!0,get:function(){return Se.MESSAGE_CHANNELS}}),Object.defineProperty(exports,"AVATAR_BACKGROUND",{enumerable:!0,get:function(){return Ae.AVATAR_BACKGROUND}}),exports.AVATAR_SIZE_MAP=Ae.AVATAR_SIZE_MAP,Object.defineProperty(exports,"AVATAR_TYPES",{enumerable:!0,get:function(){return Ae.AVATAR_TYPES}}),Object.defineProperty(exports,"SIZE",{enumerable:!0,get:function(){return Ae.SIZE}}),exports.Alert=Ce.Alert,Object.defineProperty(exports,"ALERT_TYPES",{enumerable:!0,get:function(){return ye.ALERT_TYPES}}),exports.COLOR_CONFIG_MAP=ye.COLOR_CONFIG_MAP,Object.defineProperty(exports,"CONTENT_POSITION",{enumerable:!0,get:function(){return ye.CONTENT_POSITION}}),Object.defineProperty(exports,"RATIO",{enumerable:!0,get:function(){return Oe.RATIO}}),exports.Thumbnail=Oe.Thumbnail,exports.Curtain=be.Curtain,exports.DatePicker=Ee.DatePicker,Object.defineProperty(exports,"DateButtonType",{enumerable:!0,get:function(){return je.DateButtonType}}),exports.DatePickerWrapper=je.DatePickerWrapper,exports.Loader=he.Loader,exports.Switch=he.Switch,exports.SwitchContainer=he.SwitchContainer,exports.Thumb=he.Thumb,exports.SubscriptionPlan=Re.SubscriptionPlan,exports.BottomWrapper=ge.BottomWrapper,exports.HeaderWrapper=ge.HeaderWrapper,exports.SubscriptionPlanSelector=ge.SubscriptionPlanSelector,exports.defaultTabs=ge.defaultTabs,exports.NewSubscriptionPlan=Be.NewSubscriptionPlan,exports.SubscriptionPlansCollected=_e.SubscriptionPlansCollected,exports.TabItemComponent=Ie.TabItemComponent,exports.Tabs=Ie.Tabs,exports.DynamicTabs=qe.DynamicTabs,exports.BikShimmer=fe.BikShimmer,exports.TablePagination=De.TablePagination,exports.TablePaginationCard=Ne.TablePaginationCard,exports.TablePaginationCardStyled=Ne.TablePaginationCardStyled,exports.StateModalComponent=we.StateModalComponent,exports.DeleteConfirmationModal=ke.DeleteConfirmationModal,Object.defineProperty(exports,"ButtonActions",{enumerable:!0,get:function(){return Le.ButtonActions}}),Object.defineProperty(exports,"ButtonTypes",{enumerable:!0,get:function(){return Le.ButtonTypes}}),exports.StateComponent=Le.StateComponent,Object.defineProperty(exports,"StateInterface",{enumerable:!0,get:function(){return Le.StateInterface}}),exports.ShopifyScopeWrapper=Me.ShopifyScopeWrapper,exports.WhatsAppTextEditor=Ve.WhatsAppTextEditor,exports.CustomRightBorder=ve.CustomRightBorder,Object.defineProperty(exports,"EditorActionTypes",{enumerable:!0,get:function(){return ve.EditorActionTypes}}),exports.WhatsAppTextEditorHeader=ve.WhatsAppTextEditorHeader,exports.BaseWhatsappContentLangHelper=Ge.BaseWhatsappContentLangHelper,exports.CURTAIN_COLOR_CONFIG_MAP=Fe.CURTAIN_COLOR_CONFIG_MAP,Object.defineProperty(exports,"CURTAIN_MODE",{enumerable:!0,get:function(){return Fe.CURTAIN_MODE}}),Object.defineProperty(exports,"CURTAIN_TYPES",{enumerable:!0,get:function(){return Fe.CURTAIN_TYPES}}),exports.resizeImage=Ue.resizeImage,Object.defineProperty(exports,"PickerType",{enumerable:!0,get:function(){return He.PickerType}}),exports.CardSelectionModal=We.CardSelectionModal,exports.BikImageCropper=Ye.BikImageCropper,exports.BikImagePipeline=Qe.BikImagePipeline,exports.ButtonGroup=Ke.ButtonGroup,exports.BikAccordion=ze.BikAccordion,exports.FileUploader=Ze.FileUploader,exports.ColourInput=Xe.ColourInput,exports.BikHeader=Je.BikHeader,exports.BikLayout=$e.BikLayout,exports.BikProfile=er.BikProfile,exports.SimpleSidebar=rr.SimpleSidebar,exports.BikSidebar=tr.BikSidebar,exports.FeatureModal=or.FeatureModal,exports.SidebarSkeleton=nr.SidebarSkeleton,exports.ShowShopifyRestrictedModal=ar.ShowShopifyRestrictedModal,exports.FeatureModalV2=ir.FeatureModalV2,exports.SearchBar=pr.SearchBar,exports.CustomDateTime=sr.CustomDateTime,exports.PricePleaseProductPicker=ur.PricePleaseProductPicker,exports.ProductPickerContent=ur.ProductPickerContent,exports.DiscountModal=cr.DiscountModal,exports.CouponExpiration=lr.CouponExpiration,Object.defineProperty(exports,"COUPON_EXPIRATION",{enumerable:!0,get:function(){return dr.COUPON_EXPIRATION}}),Object.defineProperty(exports,"DISCOUNT_APPLIES_TO",{enumerable:!0,get:function(){return dr.DISCOUNT_APPLIES_TO}}),Object.defineProperty(exports,"DISCOUNT_TARGET_SELECTION",{enumerable:!0,get:function(){return dr.DISCOUNT_TARGET_SELECTION}}),Object.defineProperty(exports,"DISCOUNT_TARGET_TYPES",{enumerable:!0,get:function(){return dr.DISCOUNT_TARGET_TYPES}}),Object.defineProperty(exports,"DISCOUNT_TYPES",{enumerable:!0,get:function(){return dr.DISCOUNT_TYPES}}),Object.defineProperty(exports,"DISCOUNT_VALUE_TYPES",{enumerable:!0,get:function(){return dr.DISCOUNT_VALUE_TYPES}}),Object.defineProperty(exports,"MIN_PURCHASE_REQUIREMENT",{enumerable:!0,get:function(){return dr.MIN_PURCHASE_REQUIREMENT}}),Object.defineProperty(exports,"OFFER_APPLIES_TO",{enumerable:!0,get:function(){return dr.OFFER_APPLIES_TO}}),exports.initialDynamicCouponErrorState=dr.initialDynamicCouponErrorState,exports.initialStaticCouponErrorState=dr.initialStaticCouponErrorState,exports.CountryCodePicker=mr.CountryCodePicker,exports.CountriesData=Tr.CountriesData,exports.DEFAULT_IMAGE=xr.DEFAULT_IMAGE,exports.ShimmerImage=xr.ShimmerImage,exports.ProductPickerModal=Pr.ProductPickerModal,Object.defineProperty(exports,"ScreenName",{enumerable:!0,get:function(){return Pr.ScreenName}}),exports.Carousel=Sr.Carousel,exports.CarouselSecondary=Ar.CarouselSecondary,Object.defineProperty(exports,"CarouselVersion",{enumerable:!0,get:function(){return Ar.CarouselVersion}}),exports.AccessTokenTroubleshootDialog=Cr.AccessTokenTroubleshootDialog,exports.RadioList=yr.RadioList,exports.CheckList=Or.CheckList,Object.defineProperty(exports,"DateKeys",{enumerable:!0,get:function(){return br.DateKeys}}),Object.defineProperty(exports,"MEDIA_TYPES",{enumerable:!0,get:function(){return br.MEDIA_TYPES}}),exports.PostPicker=br.PostPicker,exports.dateOptions=br.dateOptions,exports.DropdownButton=Er.DropdownButton,exports.SideModal=jr.SideModal,exports.KeywordsInput=hr.KeywordsInput,exports.AddVariableV2SideModal=Rr.AddVariableV2SideModal,exports.AddVariableV2=gr.AddVariableV2,exports.NaLinkWrapper=Br.NaLinkWrapper,exports.NavigationHyperlink=Br.NavigationHyperlink,exports.SearchFilter=_r.SearchFilter,exports.InputWithVariables=Ir.InputWithVariables,exports.DashboardReviewPopUp=qr.DashboardReviewPopUp,exports.StarRating=fr.StarRating,exports.TestimonialCard=Dr.TestimonialCard,exports.BikSlider=Nr.BikSlider,exports.ResizableImage=wr.ResizableImage,exports.validateURL=kr.validateURL,exports.CarouselPreview=Lr.CarouselPreview,exports.Floater=Mr.Floater,exports.CardSelector=Vr.CardSelector,exports.CardSelectorGroup=vr.CardSelectorGroup,exports.VariablePicker=Gr.VariablePicker,exports.ActionButtons=Fr.ActionButtons,exports.ActivateBikAi=Ur.ActivateBikAi,exports.AiSyncProgress=Hr.AiSyncProgress,exports.AiCreditsExhausted=Wr.AiCreditsExhausted,exports.AiCreditsLow=Yr.AiCreditsLow,exports.CustomPortal=Qr.CustomPortal,exports.FloatingInputDropdown=Kr.FloatingInputDropdown,exports.MultilevelDropdownPopover=zr.MultilevelDropdownPopover,exports.DropShadow=Zr.DropShadow,exports.MultiLevelDropdown=Xr.MultiLevelDropdown;
@@ -0,0 +1 @@
1
+ import*as a from"react";var e,t,r;function l(){return l=Object.assign?Object.assign.bind():function(a){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(a[r]=t[r])}return a},l.apply(this,arguments)}var n=n=>a.createElement("svg",l({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 40 40"},n),e||(e=a.createElement("circle",{cx:20,cy:20,r:20,fill:"currentColor"})),t||(t=a.createElement("path",{fill:"#731DCF",d:"M11.191 11.984a.8.8 0 0 0 .566-1.358l-2.4-2.401a.8.8 0 0 0-1.132 1.131l2.4 2.401c.152.148.355.23.566.227ZM8.848 15.993h1.543a.8.8 0 1 0 0-1.6H8.848a.8.8 0 1 0 0 1.6ZM15.193 11.193a.8.8 0 0 0 .8-.8V8.848a.8.8 0 0 0-1.6 0v1.543a.8.8 0 0 0 .8.8ZM8.79 22.39a.796.796 0 0 0 .566-.228l2.401-2.401a.8.8 0 0 0-1.131-1.132l-2.401 2.4a.804.804 0 0 0 .565 1.361ZM19.194 11.987a.796.796 0 0 0 .566-.23l2.401-2.4a.8.8 0 0 0-1.132-1.132l-2.4 2.4a.804.804 0 0 0 .565 1.362Z"})),r||(r=a.createElement("path",{stroke:"#731DCF",strokeWidth:1.714,d:"m14.71 14.702-.01.009a.847.847 0 0 0-.194.912l.002.006 5.696 14.952v.002a.876.876 0 0 0 .847.56h.005a.846.846 0 0 0 .79-.611l.002-.007 1.85-6.168a.981.981 0 0 1 .661-.658l6.165-1.85a.868.868 0 0 0 .06-1.643L15.63 14.509l-.006-.002a.85.85 0 0 0-.914.195Z"})));export{n as default};
@@ -1 +1 @@
1
- import{jsx as e,jsxs as t,Fragment as i}from"react/jsx-runtime";import n,{useState as r,useEffect as o,useRef as l}from"react";import{ShimmerComponentStyled as a}from"../shimmer/ShimmerComponent/ShimmerStyled.js";import s from"../../utils/DateUtils.js";import{COLORS as c}from"../../constants/Theme.js";import d from"../../assets/icons/arrow_down.svg.js";import g from"../../assets/icons/arrow_up.svg.js";import m from"../../assets/icons/info.svg.js";import{Tag as h}from"../tag/Tag.js";import{Tooltip as p}from"../tooltips/Tooltip.js";import{BodyCaption as y,Caption as u,TitleLarge as b,TitleMedium as f}from"../TypographyStyle.js";import{truncateValueForInternationalStore as v,truncateValueForIndianStore as j}from"./chart/utils/calcPercentage.js";import{AnalyticsTrendContainer as x}from"./CommonStyles.js";const w=r=>{let{title:o,value:l,trendPercent:s,type:d="horizontal",timeline:g,customRange:u,tooltip:w,card:O=!0,rightSeparator:$=!1,size:T="big",share:I=!1,formatVal:R,prefixSymbol:D,trailingIcon:C,onTrailIconClick:M,iconTooltipBody:k,funnelPercent:z,isLoading:L,trendRaw:P,suffixText:F,trendStyle:N,trendContainerStyle:A,trendIconStyle:W,containerStyle:_,prevTrendDiff:B,relativePercentageDiff:E,isInternationalStore:U}=r;const V="big"===T?b:f,q=void 0!==s?s<0?"negative":0===s?"neutral":"positive":void 0,G=void 0!==s?I?Math.round(s):Math.abs(Math.round(s)):void 0;return e(x,Object.assign({card:O,style:Object.assign({},_)},{children:t("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"row",gap:4,borderRightWidth:$?1:0,borderRightColor:c.stroke.primary,borderRightStyle:"solid",paddingLeft:O?0:24,paddingRight:O?0:24,height:"100%",justifyContent:"space-between",alignItems:"center"},null!=A?A:{})},{children:[t("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"column",gap:4,height:"100%"},null!=N?N:{})},{children:[t("div",Object.assign({style:{display:"flex",flexDirection:"row",gap:4,alignItems:"center"}},{children:[e(y,Object.assign({style:{color:c.content.secondary}},{children:o})),w&&e(p,Object.assign({body:w,placement:"right",width:300},{children:e("div",Object.assign({style:{display:"flex",cursor:"pointer",height:"100%"}},{children:e(m,{color:c.content.primary,height:16,width:16})}))}))]})),t("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"row",gap:12,alignItems:"center"},I?{justifyContent:"space-between"}:{})},{children:[L&&e(a,{width:108,height:26}),!L&&e(V,Object.assign({style:{color:c.content.primary}},{children:void 0===l?"--":"number"==typeof l&&R?l>999?U?`${null!=D?D:""}${v(l)} ${null!=F?F:""}`:`${null!=D?D:""}${j(l)} ${null!=F?F:""}`:`${null!=D?D:""}${new Intl.NumberFormat("en-IN",{maximumFractionDigits:2}).format(l)} ${null!=F?F:""}`:`${null!=D?D:""}${l} ${null!=F?F:""}`})),"number"==typeof E&&e(h,{tagText:`${E}%`,theme:"light",type:"neutral"}),"horizontal"===d&&!L&&!I&&e(S,{timeline:g,customRange:u,percent:G,direction:q,trendRaw:P,prefixSymbol:D,trendIconStyle:W,isInternationalStore:U}),L&&!I&&"horizontal"===d&&e(a,{height:20,width:141,marginTop:6}),"vertical"===d&&!L&&void 0!==z&&e(h,{tagText:`${z} %`,theme:"light",type:"neutral"}),I&&!L&&void 0!==G&&e(h,{tagText:`${G} %`,theme:"light",type:"neutral"}),I||L||!B||0==B?e(i,{}):e(h,{tagText:(e=>{const t=Math.abs(e);return t%1!=0?`${t.toFixed(1)} %`:`${t} %`})(B),theme:"light",type:"neutral"})]})),"vertical"===d&&!L&&!I&&e("div",Object.assign({style:{marginTop:10}},{children:e(S,{timeline:g,customRange:u,percent:G,direction:q,trendRaw:P,prefixSymbol:D,trendIconStyle:W,isInternationalStore:U})})),L&&"vertical"===d&&e(a,{height:20,width:141,marginTop:6})]})),k&&!L&&e(p,Object.assign({body:k,placement:"right"},{children:C&&e("div",Object.assign({className:"icon--holder",onClick:M},{children:n.createElement(C,{height:20,width:20,color:c.content.secondary})}))}))]}))}))},S=i=>{let{percent:n,direction:a,timeline:m,customRange:h,trendRaw:p,prefixSymbol:y,trendIconStyle:b,isInternationalStore:f}=i;const x="negative"===a?d:g,w="negative"===a?c.background.negative.vibrant:"positive"===a?c.background.positive.vibrant:c.content.placeholder,[S,O]=r("");o((()=>{O("today"===m?"vs yesterday":"yesterday"===m?"vs 1 day before":"7 days"===m?"vs last 7 days":"30 days"===m?"vs last 30 days":"custom"===m&&h?s.getAnalyticsCustomDateTimelineText(h):"")}),[m,h]);const $=e=>{let t;return t=f?v(Math.abs(e)):j(Math.abs(e)),console.log("trendRawAbs",t),console.log("trendRaw",e),e<0?"-"+t:t},T=l((()=>{const e=((null!=p?p:0)>0?"+":"")+(null!=y?y:"");return void 0===p?"--":`${null!=e?e:""}${$(p)}`})());return t("div",Object.assign({style:{display:"flex",alignItems:"center",flexDirection:"row",flexWrap:"wrap"}},{children:["number"==typeof n&&e(x,{color:w,height:16,width:16,style:Object.assign({marginRight:2},null!=b?b:{})}),"number"==typeof n&&a&&t(u,Object.assign({style:{color:w}},{children:["neutral"===a?0:n<1e3?n:">999","%"]})),!!p&&e(u,Object.assign({style:{marginLeft:4,color:c.content.placeholder}},{children:`(${T.current})`})),m&&e(u,Object.assign({style:{marginLeft:4,color:c.content.placeholder}},{children:S}))]}))};export{w as AnalyticsTrend};
1
+ import{jsx as e,jsxs as t,Fragment as i}from"react/jsx-runtime";import n,{useState as r,useEffect as o,useRef as l}from"react";import{ShimmerComponentStyled as a}from"../shimmer/ShimmerComponent/ShimmerStyled.js";import s from"../../utils/DateUtils.js";import{COLORS as c}from"../../constants/Theme.js";import d from"../../assets/icons/arrow_down.svg.js";import g from"../../assets/icons/arrow_up.svg.js";import m from"../../assets/icons/info.svg.js";import{Tag as h}from"../tag/Tag.js";import{Tooltip as p}from"../tooltips/Tooltip.js";import{BodyCaption as y,Caption as u,TitleLarge as f,TitleMedium as b}from"../TypographyStyle.js";import{truncateValueForInternationalStore as v,truncateValueForIndianStore as j}from"./chart/utils/calcPercentage.js";import{AnalyticsTrendContainer as x}from"./CommonStyles.js";const w=r=>{let{title:o,value:l,trendPercent:s,type:d="horizontal",timeline:g,customRange:u,tooltip:w,card:O=!0,rightSeparator:$=!1,size:T="big",share:I=!1,formatVal:R,prefixSymbol:D,trailingIcon:C,onTrailIconClick:M,iconTooltipBody:k,funnelPercent:z,isLoading:L,trendRaw:P,suffixText:F,trendStyle:N,trendContainerStyle:W,trendIconStyle:_,containerStyle:A,prevTrendDiff:B,relativePercentageDiff:E,isInternationalStore:U}=r;const V="big"===T?f:b,q=void 0!==s?s<0?"negative":0===s?"neutral":"positive":void 0,G=void 0!==s?I?Math.round(s):Math.abs(Math.round(s)):void 0;return e(x,Object.assign({card:O,style:Object.assign({},A)},{children:t("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"row",gap:4,borderRightWidth:$?1:0,borderRightColor:c.stroke.primary,borderRightStyle:"solid",paddingLeft:O?0:24,paddingRight:O?0:24,height:"100%",justifyContent:"space-between",alignItems:"center"},null!=W?W:{})},{children:[t("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"column",gap:4,height:"100%"},null!=N?N:{})},{children:[t("div",Object.assign({style:{display:"flex",flexDirection:"row",gap:4,alignItems:"center"}},{children:[e(y,Object.assign({style:{color:c.content.secondary}},{children:o})),w&&e(p,Object.assign({body:w,placement:"right",width:300},{children:e("div",Object.assign({style:{display:"flex",cursor:"pointer",height:"100%"}},{children:e(m,{color:c.content.primary,height:16,width:16})}))}))]})),t("div",Object.assign({style:Object.assign({display:"flex",flexDirection:"row",gap:12,alignItems:"center"},I?{justifyContent:"space-between"}:{})},{children:[L&&e(a,{width:108,height:26}),!L&&e(V,Object.assign({style:{color:c.content.primary}},{children:void 0===l?"--":"number"==typeof l&&R?l>999?U?`${null!=D?D:""}${v(l)} ${null!=F?F:""}`:`${null!=D?D:""}${j(l)} ${null!=F?F:""}`:`${null!=D?D:""}${new Intl.NumberFormat("en-IN",{maximumFractionDigits:2}).format(l)} ${null!=F?F:""}`:`${null!=D?D:""}${l} ${null!=F?F:""}`})),"number"==typeof E&&e(h,{tagText:`${E}%`,theme:"light",type:"neutral"}),"horizontal"===d&&!L&&!I&&e(S,{timeline:g,customRange:u,percent:G,direction:q,trendRaw:P,prefixSymbol:D,trendIconStyle:_,isInternationalStore:U}),L&&!I&&"horizontal"===d&&e(a,{height:20,width:141,marginTop:6}),"vertical"===d&&!L&&void 0!==z&&e(h,{tagText:`${z} %`,theme:"light",type:"neutral"}),I&&!L&&void 0!==G&&e(h,{tagText:`${G} %`,theme:"light",type:"neutral"}),I||L||!B||0==B?e(i,{}):e(h,{tagText:(e=>{const t=Math.abs(e);return t%1!=0?`${t.toFixed(1)} %`:`${t} %`})(B),theme:"light",type:"neutral"})]})),"vertical"===d&&!L&&!I&&e("div",Object.assign({style:{marginTop:10}},{children:e(S,{timeline:g,customRange:u,percent:G,direction:q,trendRaw:P,prefixSymbol:D,trendIconStyle:_,isInternationalStore:U})})),L&&"vertical"===d&&e(a,{height:20,width:141,marginTop:6})]})),k&&!L&&e(p,Object.assign({body:k,placement:"right"},{children:C&&e("div",Object.assign({className:"icon--holder",onClick:M},{children:n.createElement(C,{height:20,width:20,color:c.content.secondary})}))}))]}))}))},S=i=>{let{percent:n,direction:a,timeline:m,customRange:h,trendRaw:p,prefixSymbol:y,trendIconStyle:f,isInternationalStore:b}=i;const x="negative"===a?d:g,w="negative"===a?c.background.negative.vibrant:"positive"===a?c.background.positive.vibrant:c.content.placeholder,[S,O]=r("");o((()=>{O("today"===m?"vs yesterday":"yesterday"===m?"vs 1 day before":"7 days"===m?"vs last 7 days":"30 days"===m?"vs last 30 days":"custom"===m&&h?s.getAnalyticsCustomDateTimelineText(h):"")}),[m,h]);const $=e=>{let t;return t=b?v(Math.abs(e)):j(Math.abs(e)),e<0?"-"+t:t},T=l((()=>{const e=((null!=p?p:0)>0?"+":"")+(null!=y?y:"");return void 0===p?"--":`${null!=e?e:""}${$(p)}`})());return t("div",Object.assign({style:{display:"flex",alignItems:"center",flexDirection:"row",flexWrap:"wrap"}},{children:["number"==typeof n&&e(x,{color:w,height:16,width:16,style:Object.assign({marginRight:2},null!=f?f:{})}),"number"==typeof n&&a&&t(u,Object.assign({style:{color:w}},{children:["neutral"===a?0:n<1e3?n:">999","%"]})),!!p&&e(u,Object.assign({style:{marginLeft:4,color:c.content.placeholder}},{children:`(${T.current})`})),m&&e(u,Object.assign({style:{marginLeft:4,color:c.content.placeholder}},{children:S}))]}))};export{w as AnalyticsTrend};
@@ -1 +1 @@
1
- import g from"@emotion/styled/base";import{jsx as I,Fragment as C,jsxs as t}from"react/jsx-runtime";import A from"../../../../assets/icons/ChartBar.svg.js";import e from"../../../../assets/icons/maximize.svg.js";import"@amplitude/analytics-browser";import"../../../../amplitude/model.js";import o from"../../../../utils/StringUtils.js";import{COLORS as i}from"../../../../constants/Theme.js";import"../../../../constants/zindex.js";import{useState as l,useEffect as c}from"react";import"../../../checkBox/CheckBox.styled.js";import{TitleMedium as s}from"../../../TypographyStyle.js";import"../../../list-item/ListItem.js";import"../../../pagination/Pagination.js";import"../../../radioButton/RadioButton.styled.js";import"react-dom";import"react-toastify";import"../../../button/Button.js";import"../../../toaster/Toaster.styled.js";import"../../../tooltips/Tooltip.js";import"../../../spinner/Spinner.js";import"../../../stepper/Stepper.styled.js";import"../../../tag/Tag.js";import{IconButton as r}from"../../../icon-button/IconButton.js";import"../../../template-preview/TemplatePreview.js";import"../../../template-preview/WhatsApp/WhatsAppLikePreview.js";import"../../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js";import"../../../curtain/CurtainHelper.js";import"../../../variable-picker-v3/model.js";import"../../../template-preview/models/TemplateMeta.js";import"../../../template-preview/models/WhatsAppTemplate.js";import"../../../template-preview/models/Channels.js";import"lodash";import{StyledModal as a}from"../../../modals/styledModal.js";import"../../../template-context-mapper/context/templateModalContext.js";import"../../../template-context-mapper/modalElements/Footer.js";import"../../../template-context-mapper/styles/TemplateAnalyticsStyles.js";import"../../../template-context-mapper/utils/SegmentConstants.js";import"../../../shimmer/ShimmerComponent/ShimmerStyled.js";import"../../../template-context-mapper/modalElements/Body.js";import"../../../template-context-mapper/modalElements/Header.js";import"../../../../_virtual/_tslib.js";import"../../../zeroState/ZeroState.js";import"../../../dropdown/OpenedDropdown/components/description/Description.styled.js";import"../../../dropdown/OpenedDropdown/components/menu/FreeFormMenu.styled.js";import"../../../dropdown/OpenedDropdown/components/menu/MenuItem.js";import"../../../dropdown/OpenedDropdown/components/menu/MenuList.styled.js";import"../../../dropdown/OpenedDropdown/components/multiSelect/MultiSelectDropdownBottomBar.styled.js";import"../../../dropdown/OpenedDropdown/components/OpennedDropdown.styled.js";import"../../../input/Input.js";import"react-bootstrap";import"../../../floating-action-button/FloatingActionButton.styles.js";import"../../../image-compress/ImageCompress.js";import"../../../progress-bar/ProgressBarComponent.js";import"../../../progress-bar-v2/ProgressBarV2.js";import"../../../QueryBuilder/QueryBuilder.js";import"../../../QueryBuilder/components/QueryBuilderNode/Base/BaseQueryBuilderNode.js";import"../../../QueryBuilder/constants/connectorPosition.js";import"../../../QueryBuilder/constants/connector.js";import"../../../QueryBuilder/types/QueryBuilder.type.js";import"../../../dropdown/Dropdown.js";import"../../../QueryBuilder/components/InputLoader.js";import"../../../QueryBuilder/components/Connectors/Components/EmojiPicker.js";import"react-chips";import"../../../input/ChipInput.styled.js";import"../../../QueryBuilder/components/Connectors/Components/FrequencyIntegerPositiveSingle.js";import"../../../QueryBuilder/components/Connectors/Components/IgPicker.js";import"../../../QueryBuilder/components/Connectors/Components/InTheLast.js";import"../../../QueryBuilder/components/Connectors/Components/InTwoLast.js";import"../../../datePicker/DatePickerWrapper.js";import"../../../QueryBuilder/components/Connectors/Connector.styled.js";import"../../../QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.styled.js";import"../../../QueryBuilder/components/QueryBuilderNode/Property/PropertyNodeUIWrapper.styled.js";import"../../../QueryBuilder/redux/queryBuilder.reducer.js";import"../../../QueryBuilder/redux/queryBuilderCache.reducer.js";import"../../../QueryBuilder/types/QueryBuilderOperator.type.js";import"../../../dropdown/DropdownPopover/index.js";import"../../../dropdown/ChipDropdown.js";import"../../../dropdown/MenuItem/MenuItem.js";import"../../../analytics-card/AnalyticsCard.styled.js";import"../../CommonStyles.js";import"react-calendar";import"../../../datePicker/DatePicker.styled.js";import"../../AnalyticsMetric.js";import"../../../../utils/DateUtils.js";import"../utils/calcPercentage.js";import"../LineChart/LineChart.js";import"../linearChipGroupedChart/LinearChipGroupedChart.styled.js";import{PieChart as p}from"./PieChart.js";import"../HorizontalBarGraph/HorizontalGraph.js";import"../StackedBarChart/StackedBarChart.js";import"../StackedBarChart/StackedBarDistributionChart.js";import"../StackedBarChart/StackedBarDistributionChart.model.js";import{VerticalGraph as d}from"../VerticalBarGraph/VerticalGraph.js";import"../VerticalBarGraph/FunnelVerticalBarGraph.js";import"../heatmap/HeatMap.js";import"../heatmap/HeatMapVertical.js";import"../VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js";import"../../../avatar/Avatar.js";import"../../../avatar/AvatarHelper.js";import"../../../alerts/Alert.styled.js";import"../../../alerts/AlertHelper.js";import"../../../thumbnail/Thumbnail.js";import"../../../curtain/Curtain.styled.js";import"../../../switch/Switch.js";import"../../../plans/SubscriptionPlanStyled.js";import"../../../plans/SubscriptionPlanSelector.js";import"../../../plans/SubscriptionPlansCollected.js";import"../../../tabs/Tabs.js";import"../../../TablePagination/TablePagination.styled.js";import"../../../TablePagination/TablePaginationCard.js";import"../../../states/StateComponent.js";import"../../../WhatsAppTextEditor/WhatsAppTextEditor.js";import"../../../WhatsAppTextEditor/WhatsAppTextEditorHeader.js";import"../../../card-selection-modal/CardSelectionModal.styled.js";import"react-image-crop";import"../../../buttonGroup/ButtonGroupStyle.js";import"../../../accordion/Accordion.style.js";import"../../../accordion/AccordionArrow.js";import"../../../file-uploader/FileUploaderStyle.js";import"../../../colourInput/ColourInput.styled.js";import"../../../bik-layout/CommonStyles.js";import"../../../navigation-hyperlink/NavigationHyperlink.js";import"../../../bik-layout/SidebarStyles.js";import"date-fns";import"react-popper";import"../../../dropdown/Common.styled.js";import"../../../custom-date-time/CustomDateTime.styled.js";import"../../../../node_modules/lodash.debounce/index.js";import"../../../product-picker/ProductPicker.styled.js";import"../../../discount-modal/type.js";import"../../../product-picker-v2/modal.js";import"../../../modals/modal.styled.js";import"../../../variable-picker-v3/NoResult.js";import"../../../variable-picker-v3/styles.js";import"../../../discount-modal/DiscountModal.styled.js";import"../../../discount-modal/DynamicCoupon/DynamicCoupon.js";import"../../../country-code-picker/CountryCodePicker.styled.js";import"../../../carousel/carousel.js";import"../../../carousel-secondary/CarouselSecondary.js";import"../../../access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.styles.js";import"../../../radioList/RadioList.styled.js";import"../../../checkList/CheckList.styled.js";import"../../../postPicker/postPicker.js";import"../../../dropdown-button/DropdownButton.style.js";import"../../../side-modal/SideModal.style.js";import"../../../add-variableV2/AddVariableV2.styled.js";import"../../../SearchFilter/types/SearchFilter.type.js";import"../../../SearchFilter/components/DatePickerButton.js";import"../../../SearchFilter/components/DateRangeOnlyButton.js";import"../../../input-with-vars/InputWithVariables.js";import"../../../star-rating/StarRating.js";import"../../../dashboard-review-popup/components/FiveStar.styled.js";import"../../../dashboard-review-popup/components/Form.styled.js";import"../../../dashboard-review-popup/components/ZeroState.js";import"../../../dashboard-review-popup/DashboardReviewPopUp.styled.js";import"../../../testimonial-card/TestimonialCard.style.js";import"../../../slider/slider.js";import"react-slick";import"../../../carousel-preview/CarouselPreview.style.js";import"../../../card-selector/CardSelector.styled.js";import"../../../action-button/ActionButton.styled.js";import"../../../floating-input-dropdown/FloatingInputDropdown.js";import"../../../dropdown/MultilevelDropdownPopover/index.js";import"../../../multi-level-dropdown/MultiLevelDropdown.styled.js";import{Chart as n,ArcElement as m,Legend as b}from"chart.js";import{Doughnut as G}from"react-chartjs-2";n.register(m,b);const X={plugins:{legend:{display:!1},tooltip:{enabled:!0,callbacks:{label:g=>{if(!g.label)return" 0%";const I=g.dataset.data.reduce(((g,I)=>g+I),0),C=parseFloat((g.raw/I*100).toFixed(1));return[` ${g.label}`,` ${g.raw} (${C}% of ${I})`]}}}}},y=["#5E07BB","#9E77ED","#D2AEFF","#CDE1FF","#92AFFA","#3935E1"],h=g("div","production"===process.env.NODE_ENV?{target:"elaov7f0"}:{target:"elaov7f0",label:"CartStyled"})("background:",(g=>i.surface.standard),";border:1px solid ",(g=>i.stroke.primary),";border-radius:4px;"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFnRThCIiwiZmlsZSI6IlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IGpzeCBhcyBfanN4LCBGcmFnbWVudCBhcyBfRnJhZ21lbnQsIGpzeHMgYXMgX2pzeHMgfSBmcm9tIFwicmVhY3QvanN4LXJ1bnRpbWVcIjtcclxuaW1wb3J0IHN0eWxlZCBmcm9tICdAZW1vdGlvbi9zdHlsZW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b29sdGlwSXRlbS5sYWJlbCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gYCAwJWA7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHRvdGFsID0gdG9vbHRpcEl0ZW0uZGF0YXNldC5kYXRhLnJlZHVjZSgoYWNjLCBjdXIpID0+IGFjYyArIGN1ciwgMCk7XHJcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgcGVyY2VudGFnZSA9IHBhcnNlRmxvYXQoKCh0b29sdGlwSXRlbS5yYXcgLyB0b3RhbCkgKiAxMDApLnRvRml4ZWQoMSkpO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBbXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGAgJHt0b29sdGlwSXRlbS5sYWJlbH1gLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBgICR7dG9vbHRpcEl0ZW0ucmF3fSAoJHtwZXJjZW50YWdlfSUgb2YgJHt0b3RhbH0pYCxcclxuICAgICAgICAgICAgICAgICAgICBdO1xyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICB9LFxyXG4gICAgfSxcclxufTtcclxuY29uc3QgR1JBUEhfQ09MT1JTID0gW1xyXG4gICAgJyM1RTA3QkInLFxyXG4gICAgJyM5RTc3RUQnLFxyXG4gICAgJyNEMkFFRkYnLFxyXG4gICAgJyNDREUxRkYnLFxyXG4gICAgJyM5MkFGRkEnLFxyXG4gICAgJyMzOTM1RTEnLFxyXG5dO1xyXG5jb25zdCBDYXJ0U3R5bGVkID0gc3R5bGVkLmRpdiBgXG5cdGJhY2tncm91bmQ6ICR7KHByb3BzKSA9PiBDT0xPUlMuc3VyZmFjZS5zdGFuZGFyZH07XG5cdGJvcmRlcjogMXB4IHNvbGlkICR7KHByb3BzKSA9PiBDT0xPUlMuc3Ryb2tlLnByaW1hcnl9O1xuXHRib3JkZXItcmFkaXVzOi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gpID0+IHtcclxuICAgICAgICBjb25zdCB0b3RhbFN1bSA9IHNsaWNlcy5yZWR1Y2UoKHN1bSwgc2xpY2UpID0+IHN1bSArIHNsaWNlLmNvdW50LCAwKTtcclxuICAgICAgICBsZXQgdXBkYXRlZFNsaWNlc1dpdGhDb2xvciA9IFtdO1xyXG4gICAgICAgIHVwZGF0ZWRTbGljZXNXaXRoQ29sb3IgPSBPYmplY3Qua2V5cyhzbGljZXMpLm1hcCgoa2V5LCBpbmRleCkgPT4gKE9iamVjdC5hc3NpZ24oeyBjb2xvcjogR1JBUEhfQ09MT1JTW2luZGV4ICUgR1JBUEhfQ09MT1JTLmxlbmd0aF0gfSwgc2xpY2VzW2tleV0pKSk7XHJcbiAgICAgICAgc2V0U2xpY2VzV2l0aENvbG9yKFsuLi51cGRhdGVkU2xpY2VzV2l0aENvbG9yXSk7XHJcbiAgICAgICAgaWYgKHRvdGFsU3VtID09PSAwKSB7XHJcbiAgICAgICAgICAgIGNvbnN0IGRhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBkYXRhc2V0czogW1xyXG4gICAgICAgICAgICAgICAgICAgIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgZGF0YTogWzEwMF0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogWycjRjBGMEYwJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiAwLFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZXREYXRhKGRhdGFTZXQpO1xyXG4gICAgICAgIH1cclxuICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgY29uc3QgZGF0YVNldCA9IHtcclxuICAgICAgICAgICAgICAgIGxhYmVsczogc2xpY2VzLm1hcCgoc2xpY2UpID0+IFN0cmluZ1V0aWxzLmNhcGl0YWxpemUoc2xpY2UubmFtZSkpLFxyXG4gICAgICAgICAgICAgICAgZGF0YXNldHM6IFtcclxuICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGE6IHNsaWNlcy5tYXAoKHNsaWNlKSA9PiBzbGljZS5jb3VudCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogc2xpY2VzLm1hcCgoc2xpY2UsIGluZGV4KSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHNsaWNlLmNvbG9yKSAhPT0gbnVsbCAmJiBfYSAhPT0gdm9pZCAwID8gX2EgOiBHUkFQSF9DT0xPUlNbaW5kZXggJSBHUkFQSF9DT0xPUlMubGVuZ3RoXTsgfSksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlckNvbG9yOiBbJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiA0LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJSYWRpdXM6IDgsXHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIF0sXHJcbiAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgIHNldERhdGEoZGF0YVNldCk7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGlmICh0cnVuY2F0ZVNsaWNlcyAmJiBzbGljZXMubGVuZ3RoID4gdHJ1bmNhdGVTbGljZXMpIHtcclxuICAgICAgICAgICAgY29uc3QgdHJ1bmNhdGVkU2xpY2VzID0gc2xpY2VzLnNsaWNlKDAsIHRydW5jYXRlU2xpY2VzKTtcclxuICAgICAgICAgICAgY29uc3Qgb3RoZXJTbGljZXMgPSBzbGljZXMuc2xpY2UodHJ1bmNhdGVTbGljZXMpO1xyXG4gICAgICAgICAgICBjb25zdCBvdGhlckNvdW50ID0gb3RoZXJTbGljZXMucmVkdWNlKChzdW0sIHNsaWNlKSA9PiBzdW0gKyBzbGljZS5jb3VudCwgMCk7XHJcbiAgICAgICAgICAgIHRydW5jYXRlZFNsaWNlcy5wdXNoKHsgbmFtZTogJ090aGVyJywgY291bnQ6IG90aGVyQ291bnQgfSk7XHJcbiAgICAgICAgICAgIGNvbnN0IHRydW5jYXRlZERhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBsYWJlbHM6IHRydW5jYXRlZFNsaWNlcy5tYXAoKHNsaWNlKSA9PiBTdHJpbmdVdGlscy5jYXBpdGFsaXplKHNsaWNlLm5hbWUpKSxcclxuICAgICAgICAgICAgICAgIGRhdGFzZXRzOiBbXHJcbiAgICAgICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBkYXRhOiB0cnVuY2F0ZWRTbGljZXMubWFwKChzbGljZSkgPT4gc2xpY2UuY291bnQpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBiYWNrZ3JvdW5kQ29sb3I6IHRydW5jYXRlZFNsaWNlcy5tYXAoKHNsaWNlLCBpbmRleCkgPT4geyB2YXIgX2E7IHJldHVybiAoX2EgPSBzbGljZS5jb2xvcikgIT09IG51bGwgJiYgX2EgIT09IHZvaWQgMCA/IF9hIDogR1JBUEhfQ09MT1JTW2luZGV4ICUgR1JBUEhfQ09MT1JTLmxlbmd0aF07IH0pLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJDb2xvcjogWyd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZSddLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJXaWR0aDogNCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgYm9yZGVyUmFkaXVzOiA4LFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZ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gICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IFshaGlkZVRpdGxlICYmIHRpdGxlICYmIChfanN4KFRpdGxlTWVkaXVtLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1hcmdpbkJvdHRvbTogMTYsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gfSwgeyBjaGlsZHJlbjogdGl0bGUgfSkpKSwgX2pzeHMoXCJkaXZcIiwgeyBjaGlsZHJlbjogW3Nob3dDb252ZXJ0VG9CYXJDaGFydCAmJiAoX2pzeChJY29uQnV0dG9uLCB7IEljb246IEJhckNoYXJ0SWNvbiwgb25DbGljazogKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXRTaG93QmFyQ2hhcnQodHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9KSksIGFsbG93Q2hhcnRQb3B1cCAmJiAoX2pzeChJY29uQnV0dG9uLCB7IEljb246IE1heGltaXplSWNvbiwgb25DbGljazogKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXRTaG93UG9wdXAodHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9KSldIH0pXSB9KSksIF9qc3hzKFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdyb3cnIH0sIHsgY2hpbGRyZW46IFtfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdjb2wtNicgfSwgeyBjaGlsZHJlbjogX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogc2l6ZSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6IHNpemUsXHJcbiA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Toge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBwYWRkaW5nOiAyNCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBqdXN0aWZ5Q29udGVudDogJ3NwYWNlLWJldHdlZW4nLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6ICc4MHZoJyxcclxuICAgICAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IFtfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZTogeyB3aWR0aDogJzU1JScsIG1hcmdpbkxlZnQ6ICc0JScgfSB9LCB7IGNoaWxkcmVuOiBfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogJzEwMCUnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6ICcxMDAlJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhbGlnbkl0ZW1zOiAnY2VudGVyJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAganVzdGlmeUNvbnRlbnQ6ICdjZW50ZXInLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gfSwgeyBjaGlsZHJlbjogX2pzeChEb3VnaG51dCwgeyBkYXRhOiBkYXRhLCBvcHRpb25zOiBPYmplY3QuYXNzaWduKE9iamVjdC5hc3NpZ24oe30sIG9wdGlvbnMpLCB7IG1haW50YWluQXNwZWN0UmF0aW86IHNpemUgPyBmYWxzZSA6IHRydWUgfSkgfSkgfSkpIH0pKSwgX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHt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hcCJdfQ== */")),u=g=>I(h,Object.assign({style:{padding:24}},{children:g.children})),B=g=>{let{title:i,slices:n,size:m,allowChartPopup:b,showConvertToBarChart:h,truncateSlices:u,barChartXAxisTitle:B,barChartYAxisTitle:j,hideTitle:Z=!1}=g;const[R,H]=l(!1),[x,Y]=l(!1),[J,N]=l([]),[W,F]=l(),[S,V]=l(),[w,k]=l([]),[v,z]=l(null);return c((()=>{const g=n.reduce(((g,I)=>g+I.count),0);let I=[];if(I=Object.keys(n).map(((g,I)=>Object.assign({color:y[I%y.length]},n[g]))),N([...I]),0===g){F({datasets:[{data:[100],backgroundColor:["#F0F0F0"],borderWidth:0}]})}else{const g={labels:n.map((g=>o.capitalize(g.name))),datasets:[{data:n.map((g=>g.count)),backgroundColor:n.map(((g,I)=>{var C;return null!==(C=g.color)&&void 0!==C?C:y[I%y.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};F(g)}if(u&&n.length>u){const g=n.slice(0,u),I=n.slice(u).reduce(((g,I)=>g+I.count),0);g.push({name:"Other",count:I});const C={labels:g.map((g=>o.capitalize(g.name))),datasets:[{data:g.map((g=>g.count)),backgroundColor:g.map(((g,I)=>{var C;return null!==(C=g.color)&&void 0!==C?C:y[I%y.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};V(C);const t=g.map(((g,I)=>Object.assign({color:y[I%y.length]},g)));k(t)}h&&z(((g,I,C)=>({xAxis:{data:g.map((g=>g.name)),title:null!=I?I:""},yAxis:{data:g.map((g=>g.count)),title:null!=C?C:""},barColorRGBA:{r:210,g:174,b:255,a:1}}))(n,B,j))}),[n,u]),W?t(C,{children:[t("div",Object.assign({style:{display:"flex",justifyContent:Z||0===(null==i?void 0:i.length)?"flex-end":"space-between"}},{children:[!Z&&i&&I(s,Object.assign({style:{marginBottom:16}},{children:i})),t("div",{children:[h&&I(r,{Icon:A,onClick:()=>{Y(!0)}}),b&&I(r,{Icon:e,onClick:()=>{H(!0)}})]})]})),t("div",Object.assign({className:"row"},{children:[I("div",Object.assign({className:"col-6"},{children:I("div",Object.assign({style:{width:m,height:m}},{children:I(G,{data:u?S:W,options:Object.assign(Object.assign({},X),{maintainAspectRatio:!m})})}))})),I("div",Object.assign({className:"col-6",style:{paddingLeft:48,display:"flex",flexDirection:"column",justifyContent:"center"}},{children:I(p,{slices:u?w:J})}))]})),R&&I(a,Object.assign({open:R,onClose:()=>H(!1),closeOnOutsideClick:!0,headingTitle:i,width:"75%"},{children:t("div",Object.assign({style:{padding:24,display:"flex",justifyContent:"space-between",height:"80vh"}},{children:[I("div",Object.assign({style:{width:"55%",marginLeft:"4%"}},{children:I("div",Object.assign({style:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"}},{children:I(G,{data:W,options:Object.assign(Object.assign({},X),{maintainAspectRatio:!m})})}))})),I("div",Object.assign({style:{width:"30%",height:"100%",overflowY:"auto"}},{children:I(p,{slices:J})}))]}))})),x&&v&&I(a,Object.assign({open:x,onClose:()=>Y(!1),closeOnOutsideClick:!0,headingTitle:i,width:"85%"},{children:I("div",Object.assign({style:{padding:"24px 0"}},{children:I(d,{xAxis:v.xAxis,yAxis:v.yAxis,barColorRGBA:null==v?void 0:v.barColorRGBA})}))}))]}):I(C,{})};export{u as Card,B as PieChartAnalytics};
1
+ import g from"@emotion/styled/base";import{jsx as I,Fragment as C,jsxs as t}from"react/jsx-runtime";import A from"../../../../assets/icons/ChartBar.svg.js";import e from"../../../../assets/icons/maximize.svg.js";import"@amplitude/analytics-browser";import"../../../../amplitude/model.js";import o from"../../../../utils/StringUtils.js";import{COLORS as i}from"../../../../constants/Theme.js";import"../../../../constants/zindex.js";import{useState as l,useEffect as c}from"react";import"../../../checkBox/CheckBox.styled.js";import{TitleMedium as s}from"../../../TypographyStyle.js";import"../../../list-item/ListItem.js";import"../../../pagination/Pagination.js";import"../../../radioButton/RadioButton.styled.js";import"react-dom";import"react-toastify";import"../../../button/Button.js";import"../../../toaster/Toaster.styled.js";import"../../../tooltips/Tooltip.js";import"../../../spinner/Spinner.js";import"../../../stepper/Stepper.styled.js";import"../../../tag/Tag.js";import{IconButton as r}from"../../../icon-button/IconButton.js";import"../../../template-preview/TemplatePreview.js";import"../../../template-preview/WhatsApp/WhatsAppLikePreview.js";import"../../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js";import"../../../curtain/CurtainHelper.js";import"../../../variable-picker-v3/model.js";import"../../../template-preview/models/TemplateMeta.js";import"../../../template-preview/models/WhatsAppTemplate.js";import"../../../template-preview/models/Channels.js";import"lodash";import{StyledModal as a}from"../../../modals/styledModal.js";import"../../../template-context-mapper/context/templateModalContext.js";import"../../../template-context-mapper/modalElements/Footer.js";import"../../../template-context-mapper/styles/TemplateAnalyticsStyles.js";import"../../../template-context-mapper/utils/TemplateConstants.js";import"../../../shimmer/ShimmerComponent/ShimmerStyled.js";import"../../../template-context-mapper/modalElements/Body.js";import"../../../template-context-mapper/modalElements/Header.js";import"../../../../_virtual/_tslib.js";import"../../../zeroState/ZeroState.js";import"../../../dropdown/OpenedDropdown/components/description/Description.styled.js";import"../../../dropdown/OpenedDropdown/components/menu/FreeFormMenu.styled.js";import"../../../dropdown/OpenedDropdown/components/menu/MenuItem.js";import"../../../dropdown/OpenedDropdown/components/menu/MenuList.styled.js";import"../../../dropdown/OpenedDropdown/components/multiSelect/MultiSelectDropdownBottomBar.styled.js";import"../../../dropdown/OpenedDropdown/components/OpennedDropdown.styled.js";import"../../../input/Input.js";import"react-bootstrap";import"../../../floating-action-button/FloatingActionButton.styles.js";import"../../../image-compress/ImageCompress.js";import"../../../progress-bar/ProgressBarComponent.js";import"../../../progress-bar-v2/ProgressBarV2.js";import"../../../QueryBuilder/QueryBuilder.js";import"../../../QueryBuilder/components/QueryBuilderNode/Base/BaseQueryBuilderNode.js";import"../../../QueryBuilder/constants/connectorPosition.js";import"../../../QueryBuilder/constants/connector.js";import"../../../QueryBuilder/types/QueryBuilder.type.js";import"../../../dropdown/Dropdown.js";import"../../../QueryBuilder/components/InputLoader.js";import"../../../QueryBuilder/components/Connectors/Components/EmojiPicker.js";import"react-chips";import"../../../input/ChipInput.styled.js";import"../../../QueryBuilder/components/Connectors/Components/FrequencyIntegerPositiveSingle.js";import"../../../QueryBuilder/components/Connectors/Components/IgPicker.js";import"../../../QueryBuilder/components/Connectors/Components/InTheLast.js";import"../../../QueryBuilder/components/Connectors/Components/InTwoLast.js";import"../../../datePicker/DatePickerWrapper.js";import"../../../QueryBuilder/components/Connectors/Connector.styled.js";import"../../../QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.styled.js";import"../../../QueryBuilder/components/QueryBuilderNode/Property/PropertyNodeUIWrapper.styled.js";import"../../../QueryBuilder/redux/queryBuilder.reducer.js";import"../../../QueryBuilder/redux/queryBuilderCache.reducer.js";import"../../../QueryBuilder/types/QueryBuilderOperator.type.js";import"../../../dropdown/DropdownPopover/index.js";import"../../../dropdown/ChipDropdown.js";import"../../../dropdown/MenuItem/MenuItem.js";import"../../../analytics-card/AnalyticsCard.styled.js";import"../../CommonStyles.js";import"react-calendar";import"../../../datePicker/DatePicker.styled.js";import"../../AnalyticsMetric.js";import"../../../../utils/DateUtils.js";import"../utils/calcPercentage.js";import"../LineChart/LineChart.js";import"../linearChipGroupedChart/LinearChipGroupedChart.styled.js";import{PieChart as p}from"./PieChart.js";import"../HorizontalBarGraph/HorizontalGraph.js";import"../StackedBarChart/StackedBarChart.js";import"../StackedBarChart/StackedBarDistributionChart.js";import"../StackedBarChart/StackedBarDistributionChart.model.js";import{VerticalGraph as d}from"../VerticalBarGraph/VerticalGraph.js";import"../VerticalBarGraph/FunnelVerticalBarGraph.js";import"../heatmap/HeatMap.js";import"../heatmap/HeatMapVertical.js";import"../VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js";import"../../../avatar/Avatar.js";import"../../../avatar/AvatarHelper.js";import"../../../alerts/Alert.styled.js";import"../../../alerts/AlertHelper.js";import"../../../thumbnail/Thumbnail.js";import"../../../curtain/Curtain.styled.js";import"../../../switch/Switch.js";import"../../../plans/SubscriptionPlanStyled.js";import"../../../plans/SubscriptionPlanSelector.js";import"../../../plans/SubscriptionPlansCollected.js";import"../../../tabs/Tabs.js";import"../../../TablePagination/TablePagination.styled.js";import"../../../TablePagination/TablePaginationCard.js";import"../../../states/StateComponent.js";import"../../../WhatsAppTextEditor/WhatsAppTextEditor.js";import"../../../WhatsAppTextEditor/WhatsAppTextEditorHeader.js";import"../../../card-selection-modal/CardSelectionModal.styled.js";import"react-image-crop";import"../../../buttonGroup/ButtonGroupStyle.js";import"../../../accordion/Accordion.style.js";import"../../../accordion/AccordionArrow.js";import"../../../file-uploader/FileUploaderStyle.js";import"../../../colourInput/ColourInput.styled.js";import"../../../bik-layout/CommonStyles.js";import"../../../navigation-hyperlink/NavigationHyperlink.js";import"../../../bik-layout/SidebarStyles.js";import"date-fns";import"react-popper";import"../../../dropdown/Common.styled.js";import"../../../custom-date-time/CustomDateTime.styled.js";import"../../../../node_modules/lodash.debounce/index.js";import"../../../product-picker/ProductPicker.styled.js";import"../../../discount-modal/type.js";import"../../../product-picker-v2/modal.js";import"../../../modals/modal.styled.js";import"../../../variable-picker-v3/NoResult.js";import"../../../variable-picker-v3/styles.js";import"../../../discount-modal/DiscountModal.styled.js";import"../../../discount-modal/DynamicCoupon/DynamicCoupon.js";import"../../../country-code-picker/CountryCodePicker.styled.js";import"../../../carousel/carousel.js";import"../../../carousel-secondary/CarouselSecondary.js";import"../../../access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.styles.js";import"../../../radioList/RadioList.styled.js";import"../../../checkList/CheckList.styled.js";import"../../../postPicker/postPicker.js";import"../../../dropdown-button/DropdownButton.style.js";import"../../../side-modal/SideModal.style.js";import"../../../add-variableV2/AddVariableV2.styled.js";import"../../../SearchFilter/types/SearchFilter.type.js";import"../../../SearchFilter/components/DatePickerButton.js";import"../../../SearchFilter/components/DateRangeOnlyButton.js";import"../../../input-with-vars/InputWithVariables.js";import"../../../star-rating/StarRating.js";import"../../../dashboard-review-popup/components/FiveStar.styled.js";import"../../../dashboard-review-popup/components/Form.styled.js";import"../../../dashboard-review-popup/components/ZeroState.js";import"../../../dashboard-review-popup/DashboardReviewPopUp.styled.js";import"../../../testimonial-card/TestimonialCard.style.js";import"../../../slider/slider.js";import"react-slick";import"../../../carousel-preview/CarouselPreview.style.js";import"../../../card-selector/CardSelector.styled.js";import"../../../action-button/ActionButton.styled.js";import"../../../floating-input-dropdown/FloatingInputDropdown.js";import"../../../dropdown/MultilevelDropdownPopover/index.js";import"../../../multi-level-dropdown/MultiLevelDropdown.styled.js";import{Chart as n,ArcElement as m,Legend as b}from"chart.js";import{Doughnut as G}from"react-chartjs-2";n.register(m,b);const X={plugins:{legend:{display:!1},tooltip:{enabled:!0,callbacks:{label:g=>{if(!g.label)return" 0%";const I=g.dataset.data.reduce(((g,I)=>g+I),0),C=parseFloat((g.raw/I*100).toFixed(1));return[` ${g.label}`,` ${g.raw} (${C}% of ${I})`]}}}}},y=["#5E07BB","#9E77ED","#D2AEFF","#CDE1FF","#92AFFA","#3935E1"],h=g("div","production"===process.env.NODE_ENV?{target:"elaov7f0"}:{target:"elaov7f0",label:"CartStyled"})("background:",(g=>i.surface.standard),";border:1px solid ",(g=>i.stroke.primary),";border-radius:4px;"+("production"===process.env.NODE_ENV?"":"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFnRThCIiwiZmlsZSI6IlBpZUNoYXJ0QW5hbHl0aWNzLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7IGpzeCBhcyBfanN4LCBGcmFnbWVudCBhcyBfRnJhZ21lbnQsIGpzeHMgYXMgX2pzeHMgfSBmcm9tIFwicmVhY3QvanN4LXJ1bnRpbWVcIjtcclxuaW1wb3J0IHN0eWxlZCBmcm9tICdAZW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AgICAgICAgaWYgKCF0b29sdGlwSXRlbS5sYWJlbCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gYCAwJWA7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHRvdGFsID0gdG9vbHRpcEl0ZW0uZGF0YXNldC5kYXRhLnJlZHVjZSgoYWNjLCBjdXIpID0+IGFjYyArIGN1ciwgMCk7XHJcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgcGVyY2VudGFnZSA9IHBhcnNlRmxvYXQoKCh0b29sdGlwSXRlbS5yYXcgLyB0b3RhbCkgKiAxMDApLnRvRml4ZWQoMSkpO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBbXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGAgJHt0b29sdGlwSXRlbS5sYWJlbH1gLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBgICR7dG9vbHRpcEl0ZW0ucmF3fSAoJHtwZXJjZW50YWdlfSUgb2YgJHt0b3RhbH0pYCxcclxuICAgICAgICAgICAgICAgICAgICBdO1xyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgfSxcclxuICAgICAgICB9LFxyXG4gICAgfSxcclxufTtcclxuY29uc3QgR1JBUEhfQ09MT1JTID0gW1xyXG4gICAgJyM1RTA3QkInLFxyXG4gICAgJyM5RTc3RUQnLFxyXG4gICAgJyNEMkFFRkYnLFxyXG4gICAgJyNDREUxRkYnLFxyXG4gICAgJyM5MkFGRkEnLFxyXG4gICAgJyMzOTM1RTEnLFxyXG5dO1xyXG5jb25zdCBDYXJ0U3R5bGVkID0gc3R5bGVkLmRpdiBgXG5cdGJhY2tncm91bmQ6ICR7KHByb3BzKSA9PiBDT0xPUlMuc3VyZmFjZS5zdGFuZGFyZH07XG5cdGJvcmRlcjogMXB4IHNvbGlkICR7KHByb3BzKSA9PiBDT0xPUlMuc3Ryb2tlLnByaW1hcnl9O1xuXHRib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AgdXNlRWZmZWN0KCgpID0+IHtcclxuICAgICAgICBjb25zdCB0b3RhbFN1bSA9IHNsaWNlcy5yZWR1Y2UoKHN1bSwgc2xpY2UpID0+IHN1bSArIHNsaWNlLmNvdW50LCAwKTtcclxuICAgICAgICBsZXQgdXBkYXRlZFNsaWNlc1dpdGhDb2xvciA9IFtdO1xyXG4gICAgICAgIHVwZGF0ZWRTbGljZXNXaXRoQ29sb3IgPSBPYmplY3Qua2V5cyhzbGljZXMpLm1hcCgoa2V5LCBpbmRleCkgPT4gKE9iamVjdC5hc3NpZ24oeyBjb2xvcjogR1JBUEhfQ09MT1JTW2luZGV4ICUgR1JBUEhfQ09MT1JTLmxlbmd0aF0gfSwgc2xpY2VzW2tleV0pKSk7XHJcbiAgICAgICAgc2V0U2xpY2VzV2l0aENvbG9yKFsuLi51cGRhdGVkU2xpY2VzV2l0aENvbG9yXSk7XHJcbiAgICAgICAgaWYgKHRvdGFsU3VtID09PSAwKSB7XHJcbiAgICAgICAgICAgIGNvbnN0IGRhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBkYXRhc2V0czogW1xyXG4gICAgICAgICAgICAgICAgICAgIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgZGF0YTogWzEwMF0sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogWycjRjBGMEYwJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiAwLFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyXG4gICAgICAgICAgICBzZXREYXRhKGRhdGFTZXQpO1xyXG4gICAgICAgIH1cclxuICAgICAgICBlbHNlIHtcclxuICAgICAgICAgICAgY29uc3QgZGF0YVNldCA9IHtcclxuICAgICAgICAgICAgICAgIGxhYmVsczogc2xpY2VzLm1hcCgoc2xpY2UpID0+IFN0cmluZ1V0aWxzLmNhcGl0YWxpemUoc2xpY2UubmFtZSkpLFxyXG4gICAgICAgICAgICAgICAgZGF0YXNldHM6IFtcclxuICAgICAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGRhdGE6IHNsaWNlcy5tYXAoKHNsaWNlKSA9PiBzbGljZS5jb3VudCksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJhY2tncm91bmRDb2xvcjogc2xpY2VzLm1hcCgoc2xpY2UsIGluZGV4KSA9PiB7IHZhciBfYTsgcmV0dXJuIChfYSA9IHNsaWNlLmNvbG9yKSAhPT0gbnVsbCAmJiBfYSAhPT0gdm9pZCAwID8gX2EgOiBHUkFQSF9DT0xPUlNbaW5kZXggJSBHUkFQSF9DT0xPUlMubGVuZ3RoXTsgfSksXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlckNvbG9yOiBbJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJywgJ3doaXRlJ10sXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGJvcmRlcldpZHRoOiA0LFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJSYWRpdXM6IDgsXHJcbiAgICAgICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIF0sXHJcbiAgICAgICAgICAgIH07XHJcbiAgICAgICAgICAgIHNldERhdGEoZGF0YVNldCk7XHJcbiAgICAgICAgfVxyXG4gICAgICAgIGlmICh0cnVuY2F0ZVNsaWNlcyAmJiBzbGljZXMubGVuZ3RoID4gdHJ1bmNhdGVTbGljZXMpIHtcclxuICAgICAgICAgICAgY29uc3QgdHJ1bmNhdGVkU2xpY2VzID0gc2xpY2VzLnNsaWNlKDAsIHRydW5jYXRlU2xpY2VzKTtcclxuICAgICAgICAgICAgY29uc3Qgb3RoZXJTbGljZXMgPSBzbGljZXMuc2xpY2UodHJ1bmNhdGVTbGljZXMpO1xyXG4gICAgICAgICAgICBjb25zdCBvdGhlckNvdW50ID0gb3RoZXJTbGljZXMucmVkdWNlKChzdW0sIHNsaWNlKSA9PiBzdW0gKyBzbGljZS5jb3VudCwgMCk7XHJcbiAgICAgICAgICAgIHRydW5jYXRlZFNsaWNlcy5wdXNoKHsgbmFtZTogJ090aGVyJywgY291bnQ6IG90aGVyQ291bnQgfSk7XHJcbiAgICAgICAgICAgIGNvbnN0IHRydW5jYXRlZERhdGFTZXQgPSB7XHJcbiAgICAgICAgICAgICAgICBsYWJlbHM6IHRydW5jYXRlZFNsaWNlcy5tYXAoKHNsaWNlKSA9PiBTdHJpbmdVdGlscy5jYXBpdGFsaXplKHNsaWNlLm5hbWUpKSxcclxuICAgICAgICAgICAgICAgIGRhdGFzZXRzOiBbXHJcbiAgICAgICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBkYXRhOiB0cnVuY2F0ZWRTbGljZXMubWFwKChzbGljZSkgPT4gc2xpY2UuY291bnQpLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBiYWNrZ3JvdW5kQ29sb3I6IHRydW5jYXRlZFNsaWNlcy5tYXAoKHNsaWNlLCBpbmRleCkgPT4geyB2YXIgX2E7IHJldHVybiAoX2EgPSBzbGljZS5jb2xvcikgIT09IG51bGwgJiYgX2EgIT09IHZvaWQgMCA/IF9hIDogR1JBUEhfQ09MT1JTW2luZGV4ICUgR1JBUEhfQ09MT1JTLmxlbmd0aF07IH0pLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJDb2xvcjogWyd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZScsICd3aGl0ZSddLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBib3JkZXJXaWR0aDogNCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgYm9yZGVyUmFkaXVzOiA4LFxyXG4gICAgICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICBdLFxyXG4gICAgICAgICAgICB9O1xyX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2VlbicsXHJcbiAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IFshaGlkZVRpdGxlICYmIHRpdGxlICYmIChfanN4KFRpdGxlTWVkaXVtLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1hcmdpbkJvdHRvbTogMTYsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gfSwgeyBjaGlsZHJlbjogdGl0bGUgfSkpKSwgX2pzeHMoXCJkaXZcIiwgeyBjaGlsZHJlbjogW3Nob3dDb252ZXJ0VG9CYXJDaGFydCAmJiAoX2pzeChJY29uQnV0dG9uLCB7IEljb246IEJhckNoYXJ0SWNvbiwgb25DbGljazogKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXRTaG93QmFyQ2hhcnQodHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9KSksIGFsbG93Q2hhcnRQb3B1cCAmJiAoX2pzeChJY29uQnV0dG9uLCB7IEljb246IE1heGltaXplSWNvbiwgb25DbGljazogKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzZXRTaG93UG9wdXAodHJ1ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfSB9KSldIH0pXSB9KSksIF9qc3hzKFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdyb3cnIH0sIHsgY2hpbGRyZW46IFtfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBjbGFzc05hbWU6ICdjb2wtNicgfSwgeyBjaGlsZHJlbjogX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaWduKHsgc3R5bGU6IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogc2l6ZSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ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3NpZ24oeyBzdHlsZToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBwYWRkaW5nOiAyNCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBqdXN0aWZ5Q29udGVudDogJ3NwYWNlLWJldHdlZW4nLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6ICc4MHZoJyxcclxuICAgICAgICAgICAgICAgICAgICB9IH0sIHsgY2hpbGRyZW46IFtfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZTogeyB3aWR0aDogJzU1JScsIG1hcmdpbkxlZnQ6ICc0JScgfSB9LCB7IGNoaWxkcmVuOiBfanN4KFwiZGl2XCIsIE9iamVjdC5hc3NpZ24oeyBzdHlsZToge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB3aWR0aDogJzEwMCUnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBoZWlnaHQ6ICcxMDAlJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGlzcGxheTogJ2ZsZXgnLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhbGlnbkl0ZW1zOiAnY2VudGVyJyxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAganVzdGlmeUNvbnRlbnQ6ICdjZW50ZXInLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gfSwgeyBjaGlsZHJlbjogX2pzeChEb3VnaG51dCwgeyBkYXRhOiBkYXRhLCBvcHRpb25zOiBPYmplY3QuYXNzaWduKE9iamVjdC5hc3NpZ24oe30sIG9wdGlvbnMpLCB7IG1haW50YWluQXNwZWN0UmF0aW86IHNpemUgPyBmYWxzZSA6IHRydWUgfSkgfSkgfSkpIH0pKSwgX2pzeChcImRpdlwiLCBPYmplY3QuYXNzaW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hbHl0aWNzLmpzLm1hcCJdfQ== */")),u=g=>I(h,Object.assign({style:{padding:24}},{children:g.children})),B=g=>{let{title:i,slices:n,size:m,allowChartPopup:b,showConvertToBarChart:h,truncateSlices:u,barChartXAxisTitle:B,barChartYAxisTitle:j,hideTitle:Z=!1}=g;const[R,H]=l(!1),[x,Y]=l(!1),[J,N]=l([]),[W,F]=l(),[S,V]=l(),[w,k]=l([]),[v,z]=l(null);return c((()=>{const g=n.reduce(((g,I)=>g+I.count),0);let I=[];if(I=Object.keys(n).map(((g,I)=>Object.assign({color:y[I%y.length]},n[g]))),N([...I]),0===g){F({datasets:[{data:[100],backgroundColor:["#F0F0F0"],borderWidth:0}]})}else{const g={labels:n.map((g=>o.capitalize(g.name))),datasets:[{data:n.map((g=>g.count)),backgroundColor:n.map(((g,I)=>{var C;return null!==(C=g.color)&&void 0!==C?C:y[I%y.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};F(g)}if(u&&n.length>u){const g=n.slice(0,u),I=n.slice(u).reduce(((g,I)=>g+I.count),0);g.push({name:"Other",count:I});const C={labels:g.map((g=>o.capitalize(g.name))),datasets:[{data:g.map((g=>g.count)),backgroundColor:g.map(((g,I)=>{var C;return null!==(C=g.color)&&void 0!==C?C:y[I%y.length]})),borderColor:["white","white","white","white","white","white"],borderWidth:4,borderRadius:8}]};V(C);const t=g.map(((g,I)=>Object.assign({color:y[I%y.length]},g)));k(t)}h&&z(((g,I,C)=>({xAxis:{data:g.map((g=>g.name)),title:null!=I?I:""},yAxis:{data:g.map((g=>g.count)),title:null!=C?C:""},barColorRGBA:{r:210,g:174,b:255,a:1}}))(n,B,j))}),[n,u]),W?t(C,{children:[t("div",Object.assign({style:{display:"flex",justifyContent:Z||0===(null==i?void 0:i.length)?"flex-end":"space-between"}},{children:[!Z&&i&&I(s,Object.assign({style:{marginBottom:16}},{children:i})),t("div",{children:[h&&I(r,{Icon:A,onClick:()=>{Y(!0)}}),b&&I(r,{Icon:e,onClick:()=>{H(!0)}})]})]})),t("div",Object.assign({className:"row"},{children:[I("div",Object.assign({className:"col-6"},{children:I("div",Object.assign({style:{width:m,height:m}},{children:I(G,{data:u?S:W,options:Object.assign(Object.assign({},X),{maintainAspectRatio:!m})})}))})),I("div",Object.assign({className:"col-6",style:{paddingLeft:48,display:"flex",flexDirection:"column",justifyContent:"center"}},{children:I(p,{slices:u?w:J})}))]})),R&&I(a,Object.assign({open:R,onClose:()=>H(!1),closeOnOutsideClick:!0,headingTitle:i,width:"75%"},{children:t("div",Object.assign({style:{padding:24,display:"flex",justifyContent:"space-between",height:"80vh"}},{children:[I("div",Object.assign({style:{width:"55%",marginLeft:"4%"}},{children:I("div",Object.assign({style:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"}},{children:I(G,{data:W,options:Object.assign(Object.assign({},X),{maintainAspectRatio:!m})})}))})),I("div",Object.assign({style:{width:"30%",height:"100%",overflowY:"auto"}},{children:I(p,{slices:J})}))]}))})),x&&v&&I(a,Object.assign({open:x,onClose:()=>Y(!1),closeOnOutsideClick:!0,headingTitle:i,width:"85%"},{children:I("div",Object.assign({style:{padding:"24px 0"}},{children:I(d,{xAxis:v.xAxis,yAxis:v.yAxis,barColorRGBA:null==v?void 0:v.barColorRGBA})}))}))]}):I(C,{})};export{u as Card,B as PieChartAnalytics};
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  export declare const Menus: ({
3
2
  displayName: string;
4
3
  key: number;
@@ -2,7 +2,7 @@ import{jsx as o,jsxs as e}from"react/jsx-runtime";import t from"../../../assets/
2
2
  :hover {
3
3
  background: ${i.surface.subdued};
4
4
  }
5
- position: ${o=>o.isNewTag?"":"relative"};
5
+ position: ${o=>o.isNewTag?"relative":""};
6
6
  .new--tag {
7
7
  box-sizing: border-box;
8
8
  position: absolute;
@@ -1 +1 @@
1
- import{jsx as e,jsxs as o,Fragment as l}from"react/jsx-runtime";import{cloneDeep as t}from"lodash";import{useEffect as i,useState as r,useRef as a,useMemo as n}from"react";import s from"../../utils/StringUtils.js";import{COLORS as d}from"../../constants/Theme.js";import{StyledModal as u}from"../modals/styledModal.js";import{CHANNEL_TYPE as c}from"../template-preview/models/Channels.js";import{POD as p}from"../template-preview/models/WhatsAppTemplate.js";import{TemplateModalContext as m}from"./context/templateModalContext.js";import v from"./modalElements/Footer.js";import h from"./modalElements/TemplateAnalyticsComponent.js";import C from"./modalElements/TemplateSelectModalContent.js";import{convertPlaceholdersToBikDropdown as b}from"./utils/convertPlaceholdersToBikDropdown.js";const f=f=>{var g,x,P,y,E,T,I,S,w,D;const{selectedTemplate:V,closeDialog:k,showVariableMapping:L,channel:A,htmlContent:j,templateVariables:B,onTemplateSelect:H,globalPlaceholders:M,showOnlyContent:F,whatsappSpecificPickerMeta:O,zIndex:W,showVariableModal:N,variableList:$,discountCode:z,setDiscountCode:R,onBackPress:U,enabledCustomText:_,variableListForImage:q,showSampleValues:G,disableEditVariable:J,pod:K,extras:Q,pickerConf:X,selectedCarouselProducts:Y,disableEditExpiry:Z,cardWidth:ee,onDeleteSelectedProducts:oe,fileName:le,setFileName:te,hideDeviceContainerInPreview:ie,maxCharLimit:re,onDefaultVariableSelect:ae,skipDefaultVariableContent:ne,disableDatePicker:se,disableCopyCode:de,initialExpiryDateTime:ue,showDiscountCodeExpiryInfo:ce,footerButtonText:pe,footerInfoText:me,templateAnalytics:ve}=f;i((()=>{ye(j)}),[j]);const he=A===c.WHATSAPP&&"CAROUSEL"===(null===(x=null===(g=null==V?void 0:V.components)||void 0===g?void 0:g[1])||void 0===x?void 0:x.type),Ce=null==V?void 0:V.isProductCarouselType,[be,fe]=r(A===c.EMAIL||A==c.WEBPUSH||he?"desktop":"mobile"),[ge,xe]=r(!1),[Pe,ye]=r(j),[Ee,Te]=r(!1),[Ie,Se]=r([]),[we,De]=r({}),[Ve,ke]=r(V),[Le,Ae]=r([]),[je,Be]=r(null),[He,Me]=r(!1),[Fe,Oe]=r(null!=B?B:[]),[We,Ne]=r(!1),[$e,ze]=r(he?(null===(y=null===(P=null==Ve?void 0:Ve.mapping)||void 0===P?void 0:P.body)||void 0===y?void 0:y.length)?-1:0:-1),[Re,Ue]=r([]),[_e,qe]=r(void 0),Ge=a(null),[Je,Ke]=r(!1),[Qe,Xe]=r(!1),[Ye,Ze]=r(!1),[eo,oo]=r(!0),[lo,to]=r(!0),[io,ro]=r({});i((()=>{Y?Ue(Y):Ce&&Ue([])}),[Y]),i((()=>{var e;if(!He&&Ce&&(!Y||0===Ue.length)){const o=null===(e=null==Ve?void 0:Ve.components)||void 0===e?void 0:e[1].cards,l=[];null==o||o.forEach((e=>{var o;null===(o=null==e?void 0:e.components)||void 0===o||o.forEach((e=>{var o,t,i;"HEADER"===e.type&&l.push(null!==(i=null===(t=null===(o=e.example)||void 0===o?void 0:o.header_handle)||void 0===t?void 0:t[0])&&void 0!==i?i:"")}))})),Ae(l),Me(!0)}}),[He]);const ao=n((()=>b(M)),[M]);return i((()=>{qe(t($))}),[$]),(null==ve?void 0:ve.show)&&eo?e(h,{headingTitle:null==Ve?void 0:Ve.label,headingSubtitle:A===c.WHATSAPP?`${s.capitaliseFirstLetterOfString(null!==(E=null==Ve?void 0:Ve.category)&&void 0!==E?E:"")} • ${null!==(T=null==Ve?void 0:Ve.templateCategory)&&void 0!==T?T:""}`:"",templateAnalytics:ve,onClose:()=>{null==k||k(),oo(!1),to(!1)},onCancel:()=>{oo(!1),to(!1)},onProceed:()=>{oo(!1),to(!0)},templateId:(null==Ve?void 0:Ve.templateId)||""}):e(m.Provider,Object.assign({value:{hideFooterButton:Ye,setHideFooterButton:Ze,hideCrossButton:Qe,setHideCrossButton:Xe,variableList:_e,setVariableList:qe,variableCallback:je,setVariableCallback:Be,showVariablePicker:ge,setShowVariablePicker:xe,template:Ve,setTemplate:ke,device:be,setDevice:fe,display_content:Pe,setDisplayContent:ye,originalVariableList:Fe,setOriginalVariableList:Oe,isError:Ee,setIsError:Te,channel:A,globalNormalizedPlaceholders:ao,templateSelectionTriggered:We,setTemplateSelectionTriggered:Ne,enabledCustomText:_,disableEditVariable:J,pod:K,extras:Q,isWhatsappCarousel:he,selectedCarouselIndex:$e,setSelectedCarouselIndex:ze,isProductCarouselType:Ce,templateErrorIndexes:we,cardCount:he?null===(S=null===(I=V.components)||void 0===I?void 0:I[1].cards)||void 0===S?void 0:S.length:void 0,errorIndexes:Ie,setErrorIndexes:Se,pickerConf:X,carouselProducts:Re,setCarouselProducts:Ue,disableEditExpiry:Z,cardWidth:ee,cardImages:Le,onDeleteSelectedProducts:oe,hideDeviceContainerInPreview:ie,sliderRef:Ge,isCarouselHovered:Je,setIsCarouselHovered:Ke,maxCharLimit:re,ctaOptionsErrors:io,setCtaOptionsErrors:ro,onDefaultVariableSelect:ae,disableDatePicker:se,disableCopyCode:de,initialExpiryDateTime:ue,showDiscountCodeExpiryInfo:ce}},{children:F?e(C,{variableListFromProps:$,channel:c.EMAIL,hideHeader:!0}):o(u,Object.assign({hideCrossButton:Qe,zIndex:W,centralContainerStyles:{width:he?900:A===c.EMAIL&&L?1e3:800},open:lo,onClose:()=>{to(!1),null==k||k()},headingTitle:null==Ve?void 0:Ve.label,headingSubtitle:A===c.WHATSAPP?`${s.capitaliseFirstLetterOfString(null!==(w=null==Ve?void 0:Ve.category)&&void 0!==w?w:"")} • ${null!==(D=null==Ve?void 0:Ve.templateCategory)&&void 0!==D?D:""}`:"",onBackPress:()=>{if(null==ve?void 0:ve.show)return oo(!0),void to(!1);null==U||U()},modalHeaderStyles:{borderBottom:`1px solid ${d.stroke.primary}`}},{children:[e(C,{variableListFromProps:$,showSampleValues:G,showVariableMapping:L,channel:A,whatsappSpecificPickerMeta:O,showVariableModal:N,discountCode:z,setDiscountCode:R,variableListForImage:q&&(null==q?void 0:q.length)>0?q:_e,fileName:le,setFileName:e=>{null==te||te(e)},skipDefaultVariableContent:ne}),H?e(v,{isWhatsappCarousel:null!=he&&he,onSelect:function(){var e;if((null==Re?void 0:Re.length)<1&&Ce)return void Te(!0);if(Object.keys(io).length>0&&K!==p.CHATBOT)return void Te(!0);const o=null==H?void 0:H(Ve,Fe,null!=Pe?Pe:"",Re);De(null!==(e=null==o?void 0:o.templateErrorIndexes)&&void 0!==e?e:{body:[],buttons:[]}),(null==o?void 0:o.errorIndexes)||(null==o?void 0:o.error)?((null==o?void 0:o.errorIndexes)&&Se(o.errorIndexes),(null==o?void 0:o.error)&&Te(!!(null==o?void 0:o.error))):Ne(!0)},footerButtonText:pe,footerInfoText:me}):e(l,{})]}))}))};export{f as TemplateContextMapper};
1
+ import{jsx as e,jsxs as o,Fragment as l}from"react/jsx-runtime";import{cloneDeep as t}from"lodash";import{useEffect as i,useState as r,useRef as a,useMemo as n}from"react";import s from"../../utils/StringUtils.js";import{COLORS as d}from"../../constants/Theme.js";import{StyledModal as u}from"../modals/styledModal.js";import{CHANNEL_TYPE as c}from"../template-preview/models/Channels.js";import{POD as p}from"../template-preview/models/WhatsAppTemplate.js";import{TemplateModalContext as m}from"./context/templateModalContext.js";import v from"./modalElements/Footer.js";import{TemplateAnalyticsComponent as h}from"./modalElements/TemplateAnalyticsComponent.js";import C from"./modalElements/TemplateSelectModalContent.js";import{convertPlaceholdersToBikDropdown as b}from"./utils/convertPlaceholdersToBikDropdown.js";const f=f=>{var g,x,P,y,E,T,I,S,w,D;const{selectedTemplate:V,closeDialog:k,showVariableMapping:L,channel:A,htmlContent:j,templateVariables:B,onTemplateSelect:H,globalPlaceholders:M,showOnlyContent:F,whatsappSpecificPickerMeta:O,zIndex:W,showVariableModal:N,variableList:$,discountCode:z,setDiscountCode:R,onBackPress:U,enabledCustomText:_,variableListForImage:q,showSampleValues:G,disableEditVariable:J,pod:K,extras:Q,pickerConf:X,selectedCarouselProducts:Y,disableEditExpiry:Z,cardWidth:ee,onDeleteSelectedProducts:oe,fileName:le,setFileName:te,hideDeviceContainerInPreview:ie,maxCharLimit:re,onDefaultVariableSelect:ae,skipDefaultVariableContent:ne,disableDatePicker:se,disableCopyCode:de,initialExpiryDateTime:ue,showDiscountCodeExpiryInfo:ce,footerButtonText:pe,footerInfoText:me,templateAnalytics:ve}=f;i((()=>{ye(j)}),[j]);const he=A===c.WHATSAPP&&"CAROUSEL"===(null===(x=null===(g=null==V?void 0:V.components)||void 0===g?void 0:g[1])||void 0===x?void 0:x.type),Ce=null==V?void 0:V.isProductCarouselType,[be,fe]=r(A===c.EMAIL||A==c.WEBPUSH||he?"desktop":"mobile"),[ge,xe]=r(!1),[Pe,ye]=r(j),[Ee,Te]=r(!1),[Ie,Se]=r([]),[we,De]=r({}),[Ve,ke]=r(V),[Le,Ae]=r([]),[je,Be]=r(null),[He,Me]=r(!1),[Fe,Oe]=r(null!=B?B:[]),[We,Ne]=r(!1),[$e,ze]=r(he?(null===(y=null===(P=null==Ve?void 0:Ve.mapping)||void 0===P?void 0:P.body)||void 0===y?void 0:y.length)?-1:0:-1),[Re,Ue]=r([]),[_e,qe]=r(void 0),Ge=a(null),[Je,Ke]=r(!1),[Qe,Xe]=r(!1),[Ye,Ze]=r(!1),[eo,oo]=r(!0),[lo,to]=r(!0),[io,ro]=r({});i((()=>{Y?Ue(Y):Ce&&Ue([])}),[Y]),i((()=>{var e;if(!He&&Ce&&(!Y||0===Ue.length)){const o=null===(e=null==Ve?void 0:Ve.components)||void 0===e?void 0:e[1].cards,l=[];null==o||o.forEach((e=>{var o;null===(o=null==e?void 0:e.components)||void 0===o||o.forEach((e=>{var o,t,i;"HEADER"===e.type&&l.push(null!==(i=null===(t=null===(o=e.example)||void 0===o?void 0:o.header_handle)||void 0===t?void 0:t[0])&&void 0!==i?i:"")}))})),Ae(l),Me(!0)}}),[He]);const ao=n((()=>b(M)),[M]);return i((()=>{qe(t($))}),[$]),(null==ve?void 0:ve.show)&&eo?e(h,{headingTitle:null==Ve?void 0:Ve.label,headingSubtitle:A===c.WHATSAPP?`${s.capitaliseFirstLetterOfString(null!==(E=null==Ve?void 0:Ve.category)&&void 0!==E?E:"")} • ${null!==(T=null==Ve?void 0:Ve.templateCategory)&&void 0!==T?T:""}`:"",templateAnalytics:ve,onClose:()=>{null==k||k(),oo(!1),to(!1)},onCancel:()=>{oo(!1),to(!1)},onProceed:()=>{oo(!1),to(!0)},templateId:(null==Ve?void 0:Ve.templateId)||""}):e(m.Provider,Object.assign({value:{hideFooterButton:Ye,setHideFooterButton:Ze,hideCrossButton:Qe,setHideCrossButton:Xe,variableList:_e,setVariableList:qe,variableCallback:je,setVariableCallback:Be,showVariablePicker:ge,setShowVariablePicker:xe,template:Ve,setTemplate:ke,device:be,setDevice:fe,display_content:Pe,setDisplayContent:ye,originalVariableList:Fe,setOriginalVariableList:Oe,isError:Ee,setIsError:Te,channel:A,globalNormalizedPlaceholders:ao,templateSelectionTriggered:We,setTemplateSelectionTriggered:Ne,enabledCustomText:_,disableEditVariable:J,pod:K,extras:Q,isWhatsappCarousel:he,selectedCarouselIndex:$e,setSelectedCarouselIndex:ze,isProductCarouselType:Ce,templateErrorIndexes:we,cardCount:he?null===(S=null===(I=V.components)||void 0===I?void 0:I[1].cards)||void 0===S?void 0:S.length:void 0,errorIndexes:Ie,setErrorIndexes:Se,pickerConf:X,carouselProducts:Re,setCarouselProducts:Ue,disableEditExpiry:Z,cardWidth:ee,cardImages:Le,onDeleteSelectedProducts:oe,hideDeviceContainerInPreview:ie,sliderRef:Ge,isCarouselHovered:Je,setIsCarouselHovered:Ke,maxCharLimit:re,ctaOptionsErrors:io,setCtaOptionsErrors:ro,onDefaultVariableSelect:ae,disableDatePicker:se,disableCopyCode:de,initialExpiryDateTime:ue,showDiscountCodeExpiryInfo:ce}},{children:F?e(C,{variableListFromProps:$,channel:c.EMAIL,hideHeader:!0}):o(u,Object.assign({hideCrossButton:Qe,zIndex:W,centralContainerStyles:{width:he?900:A===c.EMAIL&&L?1e3:800},open:lo,onClose:()=>{to(!1),null==k||k()},headingTitle:null==Ve?void 0:Ve.label,headingSubtitle:A===c.WHATSAPP?`${s.capitaliseFirstLetterOfString(null!==(w=null==Ve?void 0:Ve.category)&&void 0!==w?w:"")} • ${null!==(D=null==Ve?void 0:Ve.templateCategory)&&void 0!==D?D:""}`:"",onBackPress:()=>{if(null==ve?void 0:ve.show)return oo(!0),void to(!1);null==U||U()},modalHeaderStyles:{borderBottom:`1px solid ${d.stroke.primary}`}},{children:[e(C,{variableListFromProps:$,showSampleValues:G,showVariableMapping:L,channel:A,whatsappSpecificPickerMeta:O,showVariableModal:N,discountCode:z,setDiscountCode:R,variableListForImage:q&&(null==q?void 0:q.length)>0?q:_e,fileName:le,setFileName:e=>{null==te||te(e)},skipDefaultVariableContent:ne}),H?e(v,{isWhatsappCarousel:null!=he&&he,onSelect:function(){var e;if((null==Re?void 0:Re.length)<1&&Ce)return void Te(!0);if(Object.keys(io).length>0&&K!==p.CHATBOT)return void Te(!0);const o=null==H?void 0:H(Ve,Fe,null!=Pe?Pe:"",Re);De(null!==(e=null==o?void 0:o.templateErrorIndexes)&&void 0!==e?e:{body:[],buttons:[]}),(null==o?void 0:o.errorIndexes)||(null==o?void 0:o.error)?((null==o?void 0:o.errorIndexes)&&Se(o.errorIndexes),(null==o?void 0:o.error)&&Te(!!(null==o?void 0:o.error))):Ne(!0)},footerButtonText:pe,footerInfoText:me}):e(l,{})]}))}))};export{f as TemplateContextMapper};
@@ -1,14 +1,12 @@
1
- /// <reference types="react" />
2
1
  import { TemplateAnalyticsComponentI, TemplateAnalyticsDataI } from "../../template-preview/models/WhatsAppTemplate";
3
- declare const TemplateAnalyticsComponent: React.FC<TemplateAnalyticsComponentI>;
4
- export default TemplateAnalyticsComponent;
5
- export declare const RightPanelTemplateAnalytics: React.FC<{
2
+ export declare const TemplateAnalyticsComponent: (props: TemplateAnalyticsComponentI) => import("react/jsx-runtime").JSX.Element;
3
+ export declare const RightPanelTemplateAnalytics: (props: {
6
4
  analyticsData: TemplateAnalyticsDataI;
7
5
  skipTitle?: boolean;
8
- }>;
9
- export declare const AnalyticsItem: React.FC<{
6
+ }) => import("react/jsx-runtime").JSX.Element;
7
+ export declare const AnalyticsItem: (props: {
10
8
  icon: React.ElementType;
11
9
  title: string;
12
10
  value: number;
13
11
  percentValue?: number;
14
- }>;
12
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- import{jsxs as e,jsx as t,Fragment as n}from"react/jsx-runtime";import l from"../../../assets/icons/alert_triangle.svg.js";import a from"../../../assets/icons/click.svg.js";import{useState as i,useEffect as c}from"react";import{StyledModal as s}from"../../modals/styledModal.js";import{Tag as r}from"../../tag/Tag.js";import{TEMPLATE_QUALITY as o}from"../../template-preview/models/WhatsAppTemplate.js";import{TitleSmall as d,Caption as m,TitleRegular as p}from"../../TypographyStyle.js";import{COLORS as h}from"../../../constants/Theme.js";import{RightPanelContainer as u,CustomTitleMedium as g,TemplateContainer as y,LeftPanelContainer as b}from"../styles/TemplateAnalyticsStyles.js";import{ANALYTICS_ENGAGEMENT_MAP as j,TEMPLATE_QUALITY_MAP as f}from"../utils/SegmentConstants.js";import{TemplateAnalyticsSkeleton as v}from"./TemplateAnalyticsSkeleton.js";const T=n=>{let{templateAnalytics:a,onClose:r,onProceed:d,onCancel:u,headingTitle:g,headingSubtitle:j,templateId:T}=n;const{templateQuality:N=o.GREEN,fetchAnalytics:O}=a||{},{icon:x,title:C,subline:A}=f[N||o.GREEN],[S,w]=i({}),[V,E]=i(!0);return c((()=>{null==O||O(T||"").then((e=>{e.analytics&&w(e.analytics),E(!1)}))}),[]),t(s,Object.assign({open:!0,headingTitle:g,tintedHeader:!0,modalHeaderStyles:{backgroundColor:h.surface.subdued},onBackPress:()=>{null==r||r()},headingSubtitle:j,footerShadow:!0,primaryButton:{buttonText:"Cancel",buttonType:"primary",onClick:()=>{null==r||r(),null==u||u()},disabled:V},secondaryButton:{buttonText:"Proceed with selection",buttonType:"secondary",onClick:()=>{null==d||d()},disabled:V},onClose:()=>{null==r||r()},width:"700px"},{children:e(y,{children:[t(b,{children:e("div",Object.assign({className:"inside--container"},{children:[x&&t("div",Object.assign({className:"icon--container"},{children:t(l,{width:40,height:40,color:h.content.warning})})),C&&e(p,{children:[C," template"]}),t(m,Object.assign({style:{textAlign:"center"},color:h.content.secondary},{children:A}))]}))}),V?t(v,{}):t(k,{analyticsData:S})]})}))},k=l=>{let{analyticsData:i,skipTitle:c}=l;return e(u,{children:[c?t(n,{}):t(d,{children:"Here are your template's delivery & engagement stats for the last 30 days"}),t("div",Object.assign({className:"mt-3"},{children:j.map(((e,n)=>t(N,{icon:e.icon,title:e.title,value:i[e.valName]||0,percentValue:e.percentValName?i[e.percentValName]:null},n)))})),(null==i?void 0:i.clickAnalytics)&&e(n,{children:[t(d,Object.assign({color:h.content.secondary},{children:"Clicked"})),t("div",Object.assign({className:"mt-3"},{children:Object.entries(i.clickAnalytics).map(((e,n)=>{let[l,i]=e;return t(N,{icon:a,title:l,value:i.totalClicks||0,percentValue:i.clickPercentage},n)}))}))]})]})},N=l=>{let{icon:a,title:i,value:c,percentValue:s}=l;return e("div",Object.assign({className:"each--analytics--container"},{children:[e("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[t("div",Object.assign({className:"each--icon--container"},{children:t(a,{width:"16px",height:"16px",color:h.background.brand})})),t(m,{children:i})]})),e("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[s?t(r,{tagText:s||0,theme:"light",type:"neutral"}):t(n,{}),t(g,{children:c})]}))]}))};export{N as AnalyticsItem,k as RightPanelTemplateAnalytics,T as default};
1
+ import{jsx as e,jsxs as t,Fragment as n}from"react/jsx-runtime";import a from"../../../assets/icons/alert_triangle.svg.js";import l from"../../../assets/icons/click.svg.js";import{useState as i,useEffect as c,useMemo as s}from"react";import{StyledModal as r}from"../../modals/styledModal.js";import{Tag as o}from"../../tag/Tag.js";import{TEMPLATE_QUALITY as d}from"../../template-preview/models/WhatsAppTemplate.js";import{TitleRegular as m,Caption as p,TitleSmall as u}from"../../TypographyStyle.js";import{COLORS as y}from"../../../constants/Theme.js";import{TemplateContainer as h,LeftPanelContainer as g,RightPanelContainer as b,CustomTitleMedium as j}from"../styles/TemplateAnalyticsStyles.js";import{TEMPLATE_QUALITY_MAP as T,ANALYTICS_ENGAGEMENT_MAP as f}from"../utils/TemplateConstants.js";import{TemplateAnalyticsSkeleton as v}from"./TemplateAnalyticsSkeleton.js";const k=n=>{const{templateAnalytics:l,onClose:o,onProceed:u,onCancel:b,headingTitle:j,headingSubtitle:f,templateId:k}=n,{templateQuality:x=d.GREEN,fetchAnalytics:C}=l||{},{icon:O,title:B,subline:w}=T[x||d.GREEN],[A,S]=i({}),[E,P]=i(!0);c((()=>{null==C||C(k||"").then((e=>{e.analytics&&S(e.analytics),P(!1)}))}),[]);const V=s((()=>x===d.GREEN?{primaryButton:{buttonText:"Proceed with selection",buttonType:"primary",onClick:u,disabled:E},secondaryButton:{buttonText:"Cancel",buttonType:"tertiaryGray",onClick:()=>{null==o||o(),null==b||b()},disabled:E}}:{primaryButton:{buttonText:"Cancel",buttonType:"primary",onClick:()=>{null==o||o(),null==b||b()},disabled:E},secondaryButton:{buttonText:"Proceed with selection",buttonType:"secondary",onClick:u,disabled:E}}),[x,E]);return e(r,Object.assign({open:!0,headingTitle:j,tintedHeader:!0,modalHeaderStyles:{backgroundColor:y.surface.subdued},onBackPress:()=>{null==o||o()},headingSubtitle:f,footerShadow:!0,primaryButton:V.primaryButton,secondaryButton:V.secondaryButton,onClose:()=>{null==o||o()},width:"700px"},{children:t(h,{children:[e(g,{children:t("div",Object.assign({className:"inside--container"},{children:[O&&e("div",Object.assign({className:"icon--container"},{children:e(a,{width:40,height:40,color:y.content.warning})})),B&&t(m,{children:[B," template"]}),e(p,Object.assign({style:{textAlign:"center"},color:y.content.secondary},{children:w}))]}))}),E?e(v,{}):e(N,{analyticsData:A})]})}))},N=a=>{const{analyticsData:i,skipTitle:c}=a;return t(b,{children:[c?e(n,{}):e(u,{children:"Here are your template's delivery & engagement stats for the last 30 days"}),e("div",Object.assign({className:"mt-3"},{children:f.map(((t,n)=>e(x,{icon:t.icon,title:t.title,value:i[t.valName]||0,percentValue:t.percentValName?i[t.percentValName]:null},n)))})),(null==i?void 0:i.clickAnalytics)&&t(n,{children:[e(u,Object.assign({color:y.content.secondary},{children:"Clicked"})),e("div",Object.assign({className:"mt-3"},{children:Object.entries(i.clickAnalytics).map(((t,n)=>{let[a,i]=t;return e(x,{icon:l,title:a,value:i.totalClicks||0,percentValue:i.clickPercentage},n)}))}))]})]})},x=a=>{const{icon:l,title:i,value:c,percentValue:s}=a;return t("div",Object.assign({className:"each--analytics--container"},{children:[t("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[e("div",Object.assign({className:"each--icon--container"},{children:e(l,{width:"16px",height:"16px",color:y.background.brand})})),e(p,{children:i})]})),t("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[s?e(o,{tagText:s||0,theme:"light",type:"neutral"}):e(n,{}),e(j,{children:c})]}))]}))};export{x as AnalyticsItem,N as RightPanelTemplateAnalytics,k as TemplateAnalyticsComponent};
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
- export declare const TemplateAnalyticsSkeleton: React.FC<{
1
+ export declare const TemplateAnalyticsSkeleton: (props: {
3
2
  skipTitleShimmer?: boolean;
4
- }>;
3
+ }) => import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- import{jsxs as e,jsx as i,Fragment as t}from"react/jsx-runtime";import{BikShimmer as s}from"../../shimmer/ShimmerComponent/BikShimmer.js";import{RightPanelContainer as h}from"../styles/TemplateAnalyticsStyles.js";const a=a=>{let{skipTitleShimmer:l}=a;return e(h,{children:[i("div",{children:l?i(t,{}):i(s,{boxes:[{width:"76px",height:"18px"}]})}),i("div",Object.assign({className:"mt-3"},{children:[0,1,2].map((e=>i(c,{},e)))})),e(t,{children:[i("div",{children:i(s,{boxes:[{width:"76px",height:"18px"}]})}),i("div",Object.assign({className:"mt-3"},{children:i(c,{})}))]})]})},c=()=>e("div",Object.assign({className:"each--analytics--container"},{children:[e("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[i(s,{boxes:[{width:"24px",height:"24px"}]}),i(s,{boxes:[{width:"69px",height:"11px"}]})]})),e("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[i(s,{boxes:[{width:"43px",height:"18px"}]}),i(s,{boxes:[{width:"69px",height:"28px"}]})]}))]}));export{a as TemplateAnalyticsSkeleton};
1
+ import{jsxs as e,jsx as i,Fragment as s}from"react/jsx-runtime";import{BikShimmer as t}from"../../shimmer/ShimmerComponent/BikShimmer.js";import{RightPanelContainer as h}from"../styles/TemplateAnalyticsStyles.js";const r=r=>{const{skipTitleShimmer:c}=r;return e(h,{children:[i("div",{children:c?i(s,{}):i(t,{boxes:[{width:"76px",height:"18px"}]})}),e("div",Object.assign({className:"mt-3"},{children:[...Array(3).map((e=>i(a,{},e)))]})),e(s,{children:[i("div",{children:i(t,{boxes:[{width:"76px",height:"18px"}]})}),i("div",Object.assign({className:"mt-3"},{children:i(a,{})}))]})]})},a=()=>e("div",Object.assign({className:"each--analytics--container"},{children:[e("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[i(t,{boxes:[{width:"24px",height:"24px"}]}),i(t,{boxes:[{width:"69px",height:"11px"}]})]})),e("div",Object.assign({className:"d-flex align--center",style:{gap:8}},{children:[i(t,{boxes:[{width:"43px",height:"18px"}]}),i(t,{boxes:[{width:"69px",height:"28px"}]})]}))]}));export{r as TemplateAnalyticsSkeleton};
@@ -0,0 +1 @@
1
+ import e from"../../../assets/icons/tick.svg.js";import t from"../../../assets/icons/send.svg.js";import a from"../../../assets/icons/tick_double.svg.js";import"../../template-preview/TemplatePreview.js";import"../../template-preview/WhatsApp/WhatsAppLikePreview.js";import"../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js";import"../../../constants/Theme.js";import"../../curtain/CurtainHelper.js";import"../../variable-picker-v3/model.js";import"../../template-preview/models/TemplateMeta.js";import{TEMPLATE_QUALITY as i}from"../../template-preview/models/WhatsAppTemplate.js";import"../../template-preview/models/Channels.js";import r from"../../../assets/icons/alert_triangle.svg.js";const o={[i.YELLOW]:{icon:r,title:"Medium quality template",subline:"Meta has downgraded this template to a medium-quality rating due to negative feedback from multiple customers or low read rates. We recommend improving its content or choosing a different template to enhance delivery and engagement in your next campaign"},[i.RED]:{icon:r,title:"Low quality template",subline:"Meta has downgraded this template to a low-quality rating due to negative feedback from multiple customers or low read rates. We recommend improving its content or choosing a different template to enhance delivery and engagement in your next campaign"},[i.GREEN]:{icon:"",title:"",subline:"Here is your template's delivery and engagement stats from the last 30 days. Higher engagement today can lead to better delivery rates in the future."}},s=[{title:"Sent",icon:t,valName:"totalSent"},{title:"Delivered",icon:e,valName:"totalDelivered",percentValName:"deliveredPercentage"},{title:"Read",icon:a,valName:"totalReads",percentValName:"readPercentage"}];export{s as ANALYTICS_ENGAGEMENT_MAP,o as TEMPLATE_QUALITY_MAP};
package/dist/esm/index.js CHANGED
@@ -1 +1 @@
1
- export{AmplitudeEvent}from"./amplitude/index.js";import*as o from"./components/template-preview/constants/regexPatterns.js";export{o as regexPatterns};export{default as StringUtils}from"./utils/StringUtils.js";export{BASE_COLORS,COLORS,DEFAULT_THEME,FONTS}from"./constants/Theme.js";export{ComponentZindex}from"./constants/zindex.js";export{CheckBox}from"./components/checkBox/CheckBox.js";export{ListItem}from"./components/list-item/ListItem.js";export{Pagination}from"./components/pagination/Pagination.js";export{RadioButton}from"./components/radioButton/RadioButton.js";export{Toaster}from"./components/toaster/Toaster.js";export{Tooltip}from"./components/tooltips/Tooltip.js";export{PureSpinner,Spinner}from"./components/spinner/Spinner.js";export{Stepper}from"./components/stepper/Stepper.js";export{Tag}from"./components/tag/Tag.js";export{IconButton}from"./components/icon-button/IconButton.js";export{TemplatePreview}from"./components/template-preview/TemplatePreview.js";export{WhatsappLikePreview}from"./components/template-preview/WhatsApp/WhatsAppLikePreview.js";export{WhatsappLikePreviewV2}from"./components/template-preview/WhatsApp/WhatsAppLikePreviewV2.js";export{renderVariableUIForPreview}from"./components/template-preview/helpers/SmsTemplateHelper.js";export{WhatsAppFormatToHTML}from"./components/template-preview/helpers/WhatsAppFormatToHTML.js";export{VariableEditorHelper}from"./components/template-preview/helpers/VariableEditorHelper.js";export{ACTIONS_TYPES,CUSTOM_URL_NAME,HEADER_TYPES,STATIC_URL_CTA_OPTION,TEMPLATE_EDITOR,TEMPLATE_STATUS}from"./components/template-preview/models/TemplateMeta.js";export{BUTTON_TYPE,POD,TEMPLATE_QUALITY}from"./components/template-preview/models/WhatsAppTemplate.js";export{CHANNEL_TYPE}from"./components/template-preview/models/Channels.js";export{TemplateContextMapper}from"./components/template-context-mapper/TemplateContextMapper.js";export{getAllDataFromTemplateComponent,getAllDataFromWebpushTemplateComponent}from"./components/template-context-mapper/utils/getDataFromTemplateComponent.js";export{isVariable,validateIsUrl}from"./components/template-context-mapper/utils/validateIsUrl.js";import"./_virtual/_tslib.js";export{TemplateAnalyticsSkeleton}from"./components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.js";export{AnalyticsItem,RightPanelTemplateAnalytics}from"./components/template-context-mapper/modalElements/TemplateAnalyticsComponent.js";export{FABMenu}from"./components/fab-menu/FABMenu.js";export{FloatingActionButton}from"./components/floating-action-button/FloatingActionButton.js";export{DROP_POSITION,DropdownToggleContainer,FAB_POSITION,FloatingActionButtonContainer,FloatingActionButtonOuterContainer,MENU_ALIGNMENT,StyledDropdown,TooltipStyled}from"./components/floating-action-button/FloatingActionButton.styles.js";export{ImageService}from"./components/image-compress/ImageCompress.js";export{AiBodyCaption,AiBodyTiny,BodyCaption,BodyLarge,BodyPrimary,BodyPrimaryLink,BodyRegular,BodySecondary,BodySecondaryLink,BodySmall,BodyTiny,ButtonLarge,ButtonLargeAI,ButtonRegular,ButtonRegularAI,Caption,CaptionBold,Display,SmallRegular,SubHeading,TextPlaceholder,Tiny,TitleFour,TitleLarge,TitleMedium,TitleRegular,TitleSmall,TitleXlarge}from"./components/TypographyStyle.js";export{Button}from"./components/button/Button.js";export{ProgressBarComponent,ProgressCompletedBar}from"./components/progress-bar/ProgressBarComponent.js";import"react/jsx-runtime";export{ProgressBarType,ProgressBarV2,TextAlignment}from"./components/progress-bar-v2/ProgressBarV2.js";export{QueryBuilder}from"./components/QueryBuilder/QueryBuilder.js";export{BaseQueryBuilderNode}from"./components/QueryBuilder/components/QueryBuilderNode/Base/BaseQueryBuilderNode.js";export{PropertyNode,PropertyNodeHeadless}from"./components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.js";export{queryBuilderSlice}from"./components/QueryBuilder/redux/queryBuilder.reducer.js";export{queryBuilderCacheSlice}from"./components/QueryBuilder/redux/queryBuilderCache.reducer.js";export{AD_STRING_OPERATORS,ANY_AD_OPERATORS,ANY_IG_OPERATORS,BOOLEAN_OPERATORS,DATE_OPERATORS,EVENT_VALUES,EXACTLY_OPERATORS,FREQUENCY_OPERATORS,ICE_BREAKER_OPERATORS,IG_STRING_OPERATORS,INTEGER_OPERATORS,MAIL_SUBJECT_OPERATORS,REACTION_OPERATORS,SPECIFIC_IG_OPERATORS,STRING_OPERATORS,STRING_RESTRICTED_OPERATORS,STRING_RESTRICTED_OPERATORS_2,STRING_RESTRICTED_OPERATORS_3}from"./components/QueryBuilder/types/QueryBuilderOperator.type.js";export{StyledModal}from"./components/modals/styledModal.js";export{DropdownPopover}from"./components/dropdown/DropdownPopover/index.js";export{Dropdown}from"./components/dropdown/Dropdown.js";export{ChipDropdown,ChipDropdownContainer}from"./components/dropdown/ChipDropdown.js";export{OpenedDropdown}from"./components/dropdown/OpenedDropdown/components/OpennedDropdown.js";export{MenuItemDropdown}from"./components/dropdown/MenuItem/MenuItem.js";export{AnalyticsCard}from"./components/analytics-card/AnalyticsCard.js";export{AnalyticsContainer,CardDataContainer}from"./components/analytics-card/AnalyticsCard.styled.js";export{Input}from"./components/input/Input.js";export{AnalyticsChip}from"./components/analytics-chips-and-dropdowns/AnalyticsChip.js";export{AnalyticsDropdown,EachItem,formatDate}from"./components/analytics-chips-and-dropdowns/AnalyticsDropdown.js";export{AnalyticsMultiChip}from"./components/analytics-chips-and-dropdowns/AnalyticsMultiChip.js";export{AnalyticsMetric}from"./components/analytics-chips-and-dropdowns/AnalyticsMetric.js";export{AnalyticsTrend}from"./components/analytics-chips-and-dropdowns/AnalyticsTrend.js";export{LineChart}from"./components/analytics-chips-and-dropdowns/chart/LineChart/LineChart.js";export{LinearChipGroupedChart}from"./components/analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.js";export{Card,PieChartAnalytics}from"./components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js";export{PieChart}from"./components/analytics-chips-and-dropdowns/chart/Pie/PieChart.js";export{HorizontalGraph}from"./components/analytics-chips-and-dropdowns/chart/HorizontalBarGraph/HorizontalGraph.js";export{StackedBarChart}from"./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.js";export{StackedBarDistributionChart}from"./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.js";export{GRAPH_ORIENTATION}from"./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.model.js";export{VerticalGraph}from"./components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/VerticalGraph.js";export{FunnelVerticalBarGraph}from"./components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/FunnelVerticalBarGraph.js";export{HEAT,HEAT_COLORS,HEAT_GRADING_TYPE,HeatMap}from"./components/analytics-chips-and-dropdowns/chart/heatmap/HeatMap.js";export{HeatBoxStyled,HeatMapVertical}from"./components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.js";export{VerticalBarAndLinearGraph}from"./components/analytics-chips-and-dropdowns/chart/VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js";export{TruncateValue,calculatePercentage,roundNumber,truncateValueForIndianStore,truncateValueForInternationalStore,truncateValueTo10K,truncateValueToA,truncateValueToB,truncateValueToC,truncateValueToK,truncateValueToL,truncateValueToM,truncateValueToT}from"./components/analytics-chips-and-dropdowns/chart/utils/calcPercentage.js";export{AVATAR_SIZE_VS_ICON_SIZE_MAP,Avatar,BACKGROUND_VS_TEXT_COLOR_MAP,MESSAGE_CHANNELS}from"./components/avatar/Avatar.js";export{AVATAR_BACKGROUND,AVATAR_SIZE_MAP,AVATAR_TYPES,SIZE}from"./components/avatar/AvatarHelper.js";export{Alert}from"./components/alerts/Alert.js";export{ALERT_TYPES,COLOR_CONFIG_MAP,CONTENT_POSITION}from"./components/alerts/AlertHelper.js";export{RATIO,Thumbnail}from"./components/thumbnail/Thumbnail.js";export{Curtain}from"./components/curtain/Curtain.js";export{DatePicker}from"./components/datePicker/DatePicker.js";export{DateButtonType,DatePickerWrapper}from"./components/datePicker/DatePickerWrapper.js";export{Loader,Switch,SwitchContainer,Thumb}from"./components/switch/Switch.js";export{SubscriptionPlan}from"./components/plans/SubscriptionPlan.js";export{BottomWrapper,HeaderWrapper,SubscriptionPlanSelector,defaultTabs}from"./components/plans/SubscriptionPlanSelector.js";export{NewSubscriptionPlan}from"./components/plans/NewSubscriptionPlan.js";export{SubscriptionPlansCollected}from"./components/plans/SubscriptionPlansCollected.js";export{TabItemComponent,Tabs}from"./components/tabs/Tabs.js";export{DynamicTabs}from"./components/dynamic-tabs/DynamicTabs.js";export{BikShimmer}from"./components/shimmer/ShimmerComponent/BikShimmer.js";export{TablePagination}from"./components/TablePagination/TablePagination.js";export{TablePaginationCard,TablePaginationCardStyled}from"./components/TablePagination/TablePaginationCard.js";export{StateModalComponent}from"./components/states-modal/StateModalComponent.js";export{DeleteConfirmationModal}from"./components/states-modal/DeleteConfirmationModal.js";export{ButtonActions,ButtonTypes,StateComponent,StateInterface}from"./components/states/StateComponent.js";export{ShopifyScopeWrapper}from"./components/states/ShopifyScopeWrapper.js";export{WhatsAppTextEditor}from"./components/WhatsAppTextEditor/WhatsAppTextEditor.js";export{CustomRightBorder,EditorActionTypes,WhatsAppTextEditorHeader}from"./components/WhatsAppTextEditor/WhatsAppTextEditorHeader.js";export{BaseWhatsappContentLangHelper}from"./helpers/BaseWhatsappContentLang.helper.js";export{CURTAIN_COLOR_CONFIG_MAP,CURTAIN_MODE,CURTAIN_TYPES}from"./components/curtain/CurtainHelper.js";export{resizeImage}from"./utils/resizeImage.js";export{PickerType}from"./components/variable-picker-v3/model.js";export{CardSelectionModal}from"./components/card-selection-modal/CardSelectionModal.js";export{BikImageCropper}from"./components/image-cropper/BikImageCropper.js";export{BikImagePipeline}from"./components/image-cropper/BikImagePipeline/BikImagePipeline.js";export{ButtonGroup}from"./components/buttonGroup/ButtonGroup.js";export{BikAccordion}from"./components/accordion/Accordion.js";export{FileUploader}from"./components/file-uploader/FileUploader.js";export{ColourInput}from"./components/colourInput/ColourInput.js";export{BikHeader}from"./components/bik-layout/BikHeader.js";export{BikLayout}from"./components/bik-layout/BikLayout.js";export{BikProfile}from"./components/bik-layout/BikProfile.js";export{SimpleSidebar}from"./components/bik-layout/SimpleSidebar.js";export{BikSidebar}from"./components/bik-layout/BikSidebar.js";export{FeatureModal}from"./components/bik-layout/FeatureModal.js";export{SidebarSkeleton}from"./components/bik-layout/SidebarSkeleton.js";export{ShowShopifyRestrictedModal}from"./components/bik-layout/ShowShopifyRestrictedModal.js";export{FeatureModalV2}from"./components/bik-layout/FeatureModalV2.js";export{SearchBar}from"./components/searchBar/searchBar.js";export{CustomDateTime}from"./components/custom-date-time/CustomDateTime.js";export{PricePleaseProductPicker,ProductPickerContent}from"./components/product-picker/ProductPickerModal.js";export{DiscountModal}from"./components/discount-modal/DiscountModal.js";export{CouponExpiration}from"./components/discount-modal/CouponExpiration/CouponExpiration.js";export{COUPON_EXPIRATION,DISCOUNT_APPLIES_TO,DISCOUNT_TARGET_SELECTION,DISCOUNT_TARGET_TYPES,DISCOUNT_TYPES,DISCOUNT_VALUE_TYPES,MIN_PURCHASE_REQUIREMENT,OFFER_APPLIES_TO,initialDynamicCouponErrorState,initialStaticCouponErrorState}from"./components/discount-modal/type.js";export{CountryCodePicker}from"./components/country-code-picker/CountryCodePicker.js";export{CountriesData}from"./components/country-code-picker/CountryCodePicker.modal.js";export{DEFAULT_IMAGE,ShimmerImage}from"./components/shimmer-image/ShimmerImage.js";export{ProductPickerModal,ScreenName}from"./components/product-picker-v2/modal.js";export{Carousel}from"./components/carousel/carousel.js";export{CarouselSecondary,CarouselVersion}from"./components/carousel-secondary/CarouselSecondary.js";export{AccessTokenTroubleshootDialog}from"./components/access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.js";export{RadioList}from"./components/radioList/RadioList.js";export{CheckList}from"./components/checkList/CheckList.js";export{DateKeys,MEDIA_TYPES,PostPicker,dateOptions}from"./components/postPicker/postPicker.js";export{DropdownButton}from"./components/dropdown-button/DropdownButton.js";export{SideModal}from"./components/side-modal/SideModal.js";export{KeywordsInput}from"./components/keywords-input/KeywordsInput.js";export{AddVariableV2SideModal}from"./components/add-variableV2/AddVariableV2SideModal.js";export{AddVariableV2}from"./components/add-variableV2/AddVariableV2.js";export{NaLinkWrapper,NavigationHyperlink}from"./components/navigation-hyperlink/NavigationHyperlink.js";export{SearchFilter}from"./components/SearchFilter/index.js";export{InputWithVariables}from"./components/input-with-vars/InputWithVariables.js";export{DashboardReviewPopUp}from"./components/dashboard-review-popup/DashboardReviewPopUp.js";export{StarRating}from"./components/star-rating/StarRating.js";export{TestimonialCard}from"./components/testimonial-card/TestimonialCard.js";export{BikSlider}from"./components/slider/slider.js";export{ResizableImage}from"./components/resizeImage/index.js";export{validateURL}from"./utils/validator.js";export{CarouselPreview}from"./components/carousel-preview/CarouselPreview.js";export{Floater}from"./components/floater/floater.js";export{CardSelector}from"./components/card-selector/CardSelector.js";export{CardSelectorGroup}from"./components/card-selector/CardSelectorGroup.js";export{VariablePicker}from"./components/variable-picker-v3/VariablePicker.js";export{ActionButtons}from"./components/action-button/ActionButtons.js";export{ActivateBikAi}from"./components/ai-modals/ActivateBikAI.js";export{AiSyncProgress}from"./components/ai-modals/AiSyncProgress.js";export{AiCreditsExhausted}from"./components/ai-modals/AiCreditsExhausted.js";export{AiCreditsLow}from"./components/ai-modals/AiCreditsLow.js";export{CustomPortal}from"./components/input-with-vars/customPortal.js";export{FloatingInputDropdown}from"./components/floating-input-dropdown/FloatingInputDropdown.js";export{MultilevelDropdownPopover}from"./components/dropdown/MultilevelDropdownPopover/index.js";export{DropShadow}from"./components/dropShadow/DropShadow.js";export{MultiLevelDropdown}from"./components/multi-level-dropdown/MultiLevelDropdown.js";
1
+ export{AmplitudeEvent}from"./amplitude/index.js";import*as o from"./components/template-preview/constants/regexPatterns.js";export{o as regexPatterns};export{default as StringUtils}from"./utils/StringUtils.js";export{BASE_COLORS,COLORS,DEFAULT_THEME,FONTS}from"./constants/Theme.js";export{ComponentZindex}from"./constants/zindex.js";export{CheckBox}from"./components/checkBox/CheckBox.js";export{ListItem}from"./components/list-item/ListItem.js";export{Pagination}from"./components/pagination/Pagination.js";export{RadioButton}from"./components/radioButton/RadioButton.js";export{Toaster}from"./components/toaster/Toaster.js";export{Tooltip}from"./components/tooltips/Tooltip.js";export{PureSpinner,Spinner}from"./components/spinner/Spinner.js";export{Stepper}from"./components/stepper/Stepper.js";export{Tag}from"./components/tag/Tag.js";export{IconButton}from"./components/icon-button/IconButton.js";export{TemplatePreview}from"./components/template-preview/TemplatePreview.js";export{WhatsappLikePreview}from"./components/template-preview/WhatsApp/WhatsAppLikePreview.js";export{WhatsappLikePreviewV2}from"./components/template-preview/WhatsApp/WhatsAppLikePreviewV2.js";export{renderVariableUIForPreview}from"./components/template-preview/helpers/SmsTemplateHelper.js";export{WhatsAppFormatToHTML}from"./components/template-preview/helpers/WhatsAppFormatToHTML.js";export{VariableEditorHelper}from"./components/template-preview/helpers/VariableEditorHelper.js";export{ACTIONS_TYPES,CUSTOM_URL_NAME,HEADER_TYPES,STATIC_URL_CTA_OPTION,TEMPLATE_EDITOR,TEMPLATE_STATUS}from"./components/template-preview/models/TemplateMeta.js";export{BUTTON_TYPE,POD,TEMPLATE_QUALITY}from"./components/template-preview/models/WhatsAppTemplate.js";export{CHANNEL_TYPE}from"./components/template-preview/models/Channels.js";export{TemplateContextMapper}from"./components/template-context-mapper/TemplateContextMapper.js";export{getAllDataFromTemplateComponent,getAllDataFromWebpushTemplateComponent}from"./components/template-context-mapper/utils/getDataFromTemplateComponent.js";export{isVariable,validateIsUrl}from"./components/template-context-mapper/utils/validateIsUrl.js";import"./_virtual/_tslib.js";export{TemplateAnalyticsSkeleton}from"./components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.js";export{AnalyticsItem,RightPanelTemplateAnalytics,TemplateAnalyticsComponent}from"./components/template-context-mapper/modalElements/TemplateAnalyticsComponent.js";export{FABMenu}from"./components/fab-menu/FABMenu.js";export{FloatingActionButton}from"./components/floating-action-button/FloatingActionButton.js";export{DROP_POSITION,DropdownToggleContainer,FAB_POSITION,FloatingActionButtonContainer,FloatingActionButtonOuterContainer,MENU_ALIGNMENT,StyledDropdown,TooltipStyled}from"./components/floating-action-button/FloatingActionButton.styles.js";export{ImageService}from"./components/image-compress/ImageCompress.js";export{AiBodyCaption,AiBodyTiny,BodyCaption,BodyLarge,BodyPrimary,BodyPrimaryLink,BodyRegular,BodySecondary,BodySecondaryLink,BodySmall,BodyTiny,ButtonLarge,ButtonLargeAI,ButtonRegular,ButtonRegularAI,Caption,CaptionBold,Display,SmallRegular,SubHeading,TextPlaceholder,Tiny,TitleFour,TitleLarge,TitleMedium,TitleRegular,TitleSmall,TitleXlarge}from"./components/TypographyStyle.js";export{Button}from"./components/button/Button.js";export{ProgressBarComponent,ProgressCompletedBar}from"./components/progress-bar/ProgressBarComponent.js";import"react/jsx-runtime";export{ProgressBarType,ProgressBarV2,TextAlignment}from"./components/progress-bar-v2/ProgressBarV2.js";export{QueryBuilder}from"./components/QueryBuilder/QueryBuilder.js";export{BaseQueryBuilderNode}from"./components/QueryBuilder/components/QueryBuilderNode/Base/BaseQueryBuilderNode.js";export{PropertyNode,PropertyNodeHeadless}from"./components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.js";export{queryBuilderSlice}from"./components/QueryBuilder/redux/queryBuilder.reducer.js";export{queryBuilderCacheSlice}from"./components/QueryBuilder/redux/queryBuilderCache.reducer.js";export{AD_STRING_OPERATORS,ANY_AD_OPERATORS,ANY_IG_OPERATORS,BOOLEAN_OPERATORS,DATE_OPERATORS,EVENT_VALUES,EXACTLY_OPERATORS,FREQUENCY_OPERATORS,ICE_BREAKER_OPERATORS,IG_STRING_OPERATORS,INTEGER_OPERATORS,MAIL_SUBJECT_OPERATORS,REACTION_OPERATORS,SPECIFIC_IG_OPERATORS,STRING_OPERATORS,STRING_RESTRICTED_OPERATORS,STRING_RESTRICTED_OPERATORS_2,STRING_RESTRICTED_OPERATORS_3}from"./components/QueryBuilder/types/QueryBuilderOperator.type.js";export{StyledModal}from"./components/modals/styledModal.js";export{DropdownPopover}from"./components/dropdown/DropdownPopover/index.js";export{Dropdown}from"./components/dropdown/Dropdown.js";export{ChipDropdown,ChipDropdownContainer}from"./components/dropdown/ChipDropdown.js";export{OpenedDropdown}from"./components/dropdown/OpenedDropdown/components/OpennedDropdown.js";export{MenuItemDropdown}from"./components/dropdown/MenuItem/MenuItem.js";export{AnalyticsCard}from"./components/analytics-card/AnalyticsCard.js";export{AnalyticsContainer,CardDataContainer}from"./components/analytics-card/AnalyticsCard.styled.js";export{Input}from"./components/input/Input.js";export{AnalyticsChip}from"./components/analytics-chips-and-dropdowns/AnalyticsChip.js";export{AnalyticsDropdown,EachItem,formatDate}from"./components/analytics-chips-and-dropdowns/AnalyticsDropdown.js";export{AnalyticsMultiChip}from"./components/analytics-chips-and-dropdowns/AnalyticsMultiChip.js";export{AnalyticsMetric}from"./components/analytics-chips-and-dropdowns/AnalyticsMetric.js";export{AnalyticsTrend}from"./components/analytics-chips-and-dropdowns/AnalyticsTrend.js";export{LineChart}from"./components/analytics-chips-and-dropdowns/chart/LineChart/LineChart.js";export{LinearChipGroupedChart}from"./components/analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.js";export{Card,PieChartAnalytics}from"./components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js";export{PieChart}from"./components/analytics-chips-and-dropdowns/chart/Pie/PieChart.js";export{HorizontalGraph}from"./components/analytics-chips-and-dropdowns/chart/HorizontalBarGraph/HorizontalGraph.js";export{StackedBarChart}from"./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.js";export{StackedBarDistributionChart}from"./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.js";export{GRAPH_ORIENTATION}from"./components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.model.js";export{VerticalGraph}from"./components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/VerticalGraph.js";export{FunnelVerticalBarGraph}from"./components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/FunnelVerticalBarGraph.js";export{HEAT,HEAT_COLORS,HEAT_GRADING_TYPE,HeatMap}from"./components/analytics-chips-and-dropdowns/chart/heatmap/HeatMap.js";export{HeatBoxStyled,HeatMapVertical}from"./components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.js";export{VerticalBarAndLinearGraph}from"./components/analytics-chips-and-dropdowns/chart/VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js";export{TruncateValue,calculatePercentage,roundNumber,truncateValueForIndianStore,truncateValueForInternationalStore,truncateValueTo10K,truncateValueToA,truncateValueToB,truncateValueToC,truncateValueToK,truncateValueToL,truncateValueToM,truncateValueToT}from"./components/analytics-chips-and-dropdowns/chart/utils/calcPercentage.js";export{AVATAR_SIZE_VS_ICON_SIZE_MAP,Avatar,BACKGROUND_VS_TEXT_COLOR_MAP,MESSAGE_CHANNELS}from"./components/avatar/Avatar.js";export{AVATAR_BACKGROUND,AVATAR_SIZE_MAP,AVATAR_TYPES,SIZE}from"./components/avatar/AvatarHelper.js";export{Alert}from"./components/alerts/Alert.js";export{ALERT_TYPES,COLOR_CONFIG_MAP,CONTENT_POSITION}from"./components/alerts/AlertHelper.js";export{RATIO,Thumbnail}from"./components/thumbnail/Thumbnail.js";export{Curtain}from"./components/curtain/Curtain.js";export{DatePicker}from"./components/datePicker/DatePicker.js";export{DateButtonType,DatePickerWrapper}from"./components/datePicker/DatePickerWrapper.js";export{Loader,Switch,SwitchContainer,Thumb}from"./components/switch/Switch.js";export{SubscriptionPlan}from"./components/plans/SubscriptionPlan.js";export{BottomWrapper,HeaderWrapper,SubscriptionPlanSelector,defaultTabs}from"./components/plans/SubscriptionPlanSelector.js";export{NewSubscriptionPlan}from"./components/plans/NewSubscriptionPlan.js";export{SubscriptionPlansCollected}from"./components/plans/SubscriptionPlansCollected.js";export{TabItemComponent,Tabs}from"./components/tabs/Tabs.js";export{DynamicTabs}from"./components/dynamic-tabs/DynamicTabs.js";export{BikShimmer}from"./components/shimmer/ShimmerComponent/BikShimmer.js";export{TablePagination}from"./components/TablePagination/TablePagination.js";export{TablePaginationCard,TablePaginationCardStyled}from"./components/TablePagination/TablePaginationCard.js";export{StateModalComponent}from"./components/states-modal/StateModalComponent.js";export{DeleteConfirmationModal}from"./components/states-modal/DeleteConfirmationModal.js";export{ButtonActions,ButtonTypes,StateComponent,StateInterface}from"./components/states/StateComponent.js";export{ShopifyScopeWrapper}from"./components/states/ShopifyScopeWrapper.js";export{WhatsAppTextEditor}from"./components/WhatsAppTextEditor/WhatsAppTextEditor.js";export{CustomRightBorder,EditorActionTypes,WhatsAppTextEditorHeader}from"./components/WhatsAppTextEditor/WhatsAppTextEditorHeader.js";export{BaseWhatsappContentLangHelper}from"./helpers/BaseWhatsappContentLang.helper.js";export{CURTAIN_COLOR_CONFIG_MAP,CURTAIN_MODE,CURTAIN_TYPES}from"./components/curtain/CurtainHelper.js";export{resizeImage}from"./utils/resizeImage.js";export{PickerType}from"./components/variable-picker-v3/model.js";export{CardSelectionModal}from"./components/card-selection-modal/CardSelectionModal.js";export{BikImageCropper}from"./components/image-cropper/BikImageCropper.js";export{BikImagePipeline}from"./components/image-cropper/BikImagePipeline/BikImagePipeline.js";export{ButtonGroup}from"./components/buttonGroup/ButtonGroup.js";export{BikAccordion}from"./components/accordion/Accordion.js";export{FileUploader}from"./components/file-uploader/FileUploader.js";export{ColourInput}from"./components/colourInput/ColourInput.js";export{BikHeader}from"./components/bik-layout/BikHeader.js";export{BikLayout}from"./components/bik-layout/BikLayout.js";export{BikProfile}from"./components/bik-layout/BikProfile.js";export{SimpleSidebar}from"./components/bik-layout/SimpleSidebar.js";export{BikSidebar}from"./components/bik-layout/BikSidebar.js";export{FeatureModal}from"./components/bik-layout/FeatureModal.js";export{SidebarSkeleton}from"./components/bik-layout/SidebarSkeleton.js";export{ShowShopifyRestrictedModal}from"./components/bik-layout/ShowShopifyRestrictedModal.js";export{FeatureModalV2}from"./components/bik-layout/FeatureModalV2.js";export{SearchBar}from"./components/searchBar/searchBar.js";export{CustomDateTime}from"./components/custom-date-time/CustomDateTime.js";export{PricePleaseProductPicker,ProductPickerContent}from"./components/product-picker/ProductPickerModal.js";export{DiscountModal}from"./components/discount-modal/DiscountModal.js";export{CouponExpiration}from"./components/discount-modal/CouponExpiration/CouponExpiration.js";export{COUPON_EXPIRATION,DISCOUNT_APPLIES_TO,DISCOUNT_TARGET_SELECTION,DISCOUNT_TARGET_TYPES,DISCOUNT_TYPES,DISCOUNT_VALUE_TYPES,MIN_PURCHASE_REQUIREMENT,OFFER_APPLIES_TO,initialDynamicCouponErrorState,initialStaticCouponErrorState}from"./components/discount-modal/type.js";export{CountryCodePicker}from"./components/country-code-picker/CountryCodePicker.js";export{CountriesData}from"./components/country-code-picker/CountryCodePicker.modal.js";export{DEFAULT_IMAGE,ShimmerImage}from"./components/shimmer-image/ShimmerImage.js";export{ProductPickerModal,ScreenName}from"./components/product-picker-v2/modal.js";export{Carousel}from"./components/carousel/carousel.js";export{CarouselSecondary,CarouselVersion}from"./components/carousel-secondary/CarouselSecondary.js";export{AccessTokenTroubleshootDialog}from"./components/access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.js";export{RadioList}from"./components/radioList/RadioList.js";export{CheckList}from"./components/checkList/CheckList.js";export{DateKeys,MEDIA_TYPES,PostPicker,dateOptions}from"./components/postPicker/postPicker.js";export{DropdownButton}from"./components/dropdown-button/DropdownButton.js";export{SideModal}from"./components/side-modal/SideModal.js";export{KeywordsInput}from"./components/keywords-input/KeywordsInput.js";export{AddVariableV2SideModal}from"./components/add-variableV2/AddVariableV2SideModal.js";export{AddVariableV2}from"./components/add-variableV2/AddVariableV2.js";export{NaLinkWrapper,NavigationHyperlink}from"./components/navigation-hyperlink/NavigationHyperlink.js";export{SearchFilter}from"./components/SearchFilter/index.js";export{InputWithVariables}from"./components/input-with-vars/InputWithVariables.js";export{DashboardReviewPopUp}from"./components/dashboard-review-popup/DashboardReviewPopUp.js";export{StarRating}from"./components/star-rating/StarRating.js";export{TestimonialCard}from"./components/testimonial-card/TestimonialCard.js";export{BikSlider}from"./components/slider/slider.js";export{ResizableImage}from"./components/resizeImage/index.js";export{validateURL}from"./utils/validator.js";export{CarouselPreview}from"./components/carousel-preview/CarouselPreview.js";export{Floater}from"./components/floater/floater.js";export{CardSelector}from"./components/card-selector/CardSelector.js";export{CardSelectorGroup}from"./components/card-selector/CardSelectorGroup.js";export{VariablePicker}from"./components/variable-picker-v3/VariablePicker.js";export{ActionButtons}from"./components/action-button/ActionButtons.js";export{ActivateBikAi}from"./components/ai-modals/ActivateBikAI.js";export{AiSyncProgress}from"./components/ai-modals/AiSyncProgress.js";export{AiCreditsExhausted}from"./components/ai-modals/AiCreditsExhausted.js";export{AiCreditsLow}from"./components/ai-modals/AiCreditsLow.js";export{CustomPortal}from"./components/input-with-vars/customPortal.js";export{FloatingInputDropdown}from"./components/floating-input-dropdown/FloatingInputDropdown.js";export{MultilevelDropdownPopover}from"./components/dropdown/MultilevelDropdownPopover/index.js";export{DropShadow}from"./components/dropShadow/DropShadow.js";export{MultiLevelDropdown}from"./components/multi-level-dropdown/MultiLevelDropdown.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bikdotai/bik-component-library",
3
- "version": "0.0.639--beta0.8",
3
+ "version": "0.0.639--beta1.0",
4
4
  "description": "Bik Component Library",
5
5
  "repository": {
6
6
  "type": "git",
@@ -1 +0,0 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../assets/icons/tick.svg.js"),t=require("../../../assets/icons/tick_double.svg.js");require("../../template-preview/TemplatePreview.js"),require("../../template-preview/WhatsApp/WhatsAppLikePreview.js"),require("../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js"),require("../../../constants/Theme.js"),require("../../curtain/CurtainHelper.js"),require("../../variable-picker-v3/model.js"),require("../../template-preview/models/TemplateMeta.js");var a=require("../../template-preview/models/WhatsAppTemplate.js");require("../../template-preview/models/Channels.js");var r=require("../../../assets/icons/alert_triangle.svg.js");const i={[a.TEMPLATE_QUALITY.YELLOW]:{icon:r.default,title:"Medium quality template",subline:"Meta has downgraded this template to a medium-quality rating due to negative feedback from multiple customers or low read rates. We recommend improving its content or choosing a different template to enhance delivery and engagement in your next campaign"},[a.TEMPLATE_QUALITY.RED]:{icon:r.default,title:"Low quality template",subline:"Meta has downgraded this template to a low-quality rating due to negative feedback from multiple customers or low read rates. We recommend improving its content or choosing a different template to enhance delivery and engagement in your next campaign"},[a.TEMPLATE_QUALITY.GREEN]:{icon:"",title:"",subline:"Here is your template's delivery and engagement stats from the last 30 days. Higher engagement today can lead to better delivery rates in the future."}},l=[{title:"Sent",icon:e.default,valName:"totalSent"},{title:"Delivered",icon:e.default,valName:"totalDelivered",percentValName:"deliveredPercentage"},{title:"Read",icon:t.default,valName:"totalReads",percentValName:"readPercentage"}];exports.ANALYTICS_ENGAGEMENT_MAP=l,exports.TEMPLATE_QUALITY_MAP=i;
@@ -1 +0,0 @@
1
- import e from"../../../assets/icons/tick.svg.js";import t from"../../../assets/icons/tick_double.svg.js";import"../../template-preview/TemplatePreview.js";import"../../template-preview/WhatsApp/WhatsAppLikePreview.js";import"../../template-preview/WhatsApp/WhatsAppLikePreviewV2.js";import"../../../constants/Theme.js";import"../../curtain/CurtainHelper.js";import"../../variable-picker-v3/model.js";import"../../template-preview/models/TemplateMeta.js";import{TEMPLATE_QUALITY as a}from"../../template-preview/models/WhatsAppTemplate.js";import"../../template-preview/models/Channels.js";import i from"../../../assets/icons/alert_triangle.svg.js";const r={[a.YELLOW]:{icon:i,title:"Medium quality template",subline:"Meta has downgraded this template to a medium-quality rating due to negative feedback from multiple customers or low read rates. We recommend improving its content or choosing a different template to enhance delivery and engagement in your next campaign"},[a.RED]:{icon:i,title:"Low quality template",subline:"Meta has downgraded this template to a low-quality rating due to negative feedback from multiple customers or low read rates. We recommend improving its content or choosing a different template to enhance delivery and engagement in your next campaign"},[a.GREEN]:{icon:"",title:"",subline:"Here is your template's delivery and engagement stats from the last 30 days. Higher engagement today can lead to better delivery rates in the future."}},o=[{title:"Sent",icon:e,valName:"totalSent"},{title:"Delivered",icon:e,valName:"totalDelivered",percentValName:"deliveredPercentage"},{title:"Read",icon:t,valName:"totalReads",percentValName:"readPercentage"}];export{o as ANALYTICS_ENGAGEMENT_MAP,r as TEMPLATE_QUALITY_MAP};