@bikdotai/bik-component-library 0.0.736-beta.10 → 0.0.736-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/_virtual/_tslib.js +1 -1
- package/dist/cjs/amplitude/Track.stories.d.ts +4 -0
- package/dist/cjs/amplitude/index.js +1 -1
- package/dist/cjs/assets/icons/AiEdit.svg.js +1 -1
- package/dist/cjs/assets/icons/Ai_event_generating.svg.js +1 -1
- package/dist/cjs/assets/icons/Bik_logo.svg.js +1 -1
- package/dist/cjs/assets/icons/ChartBar.svg.js +1 -1
- package/dist/cjs/assets/icons/ChartPie.svg.js +1 -1
- package/dist/cjs/assets/icons/HelpIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/Idea.svg.js +1 -1
- package/dist/cjs/assets/icons/RCS_PDF.svg.js +1 -1
- package/dist/cjs/assets/icons/RedirectToNew.svg.js +1 -1
- package/dist/cjs/assets/icons/WhiteStarFilled.svg.js +1 -1
- package/dist/cjs/assets/icons/aiContentIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/alert.svg.js +1 -1
- package/dist/cjs/assets/icons/alert_triangle.svg.js +1 -1
- package/dist/cjs/assets/icons/arrow_back.svg.js +1 -1
- package/dist/cjs/assets/icons/arrow_down.svg.js +1 -1
- package/dist/cjs/assets/icons/arrow_left.svg.js +1 -1
- package/dist/cjs/assets/icons/arrow_up.svg.js +1 -1
- package/dist/cjs/assets/icons/back_icon.svg.js +1 -1
- package/dist/cjs/assets/icons/bik_livechat.svg.js +1 -1
- package/dist/cjs/assets/icons/bold.svg.js +1 -1
- package/dist/cjs/assets/icons/box.svg.js +1 -1
- package/dist/cjs/assets/icons/boxV2.svg.js +1 -1
- package/dist/cjs/assets/icons/box_round.svg.js +1 -1
- package/dist/cjs/assets/icons/box_search.svg.js +1 -1
- package/dist/cjs/assets/icons/broken_media_image.svg.js +1 -1
- package/dist/cjs/assets/icons/calendar.svg.js +1 -1
- package/dist/cjs/assets/icons/card_footer_arraw.svg.js +1 -1
- package/dist/cjs/assets/icons/chat-channel.svg.js +1 -1
- package/dist/cjs/assets/icons/check.svg.js +1 -1
- package/dist/cjs/assets/icons/checkCircle.svg.js +1 -1
- package/dist/cjs/assets/icons/checklistIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/chevronDown.svg.js +1 -1
- package/dist/cjs/assets/icons/chevronDownOutline.svg.js +1 -1
- package/dist/cjs/assets/icons/chevronLeft.svg.js +1 -1
- package/dist/cjs/assets/icons/chevronLeft2.svg.js +1 -1
- package/dist/cjs/assets/icons/chevronRight.svg.js +1 -1
- package/dist/cjs/assets/icons/chevronRight2.svg.js +1 -1
- package/dist/cjs/assets/icons/chevronRightAlt.svg.js +1 -1
- package/dist/cjs/assets/icons/chevronUpOutline.svg.js +1 -1
- package/dist/cjs/assets/icons/click.svg.js +1 -1
- package/dist/cjs/assets/icons/clock.svg.js +1 -1
- package/dist/cjs/assets/icons/copy-code-icon.svg.js +1 -1
- package/dist/cjs/assets/icons/cross.svg.js +1 -1
- package/dist/cjs/assets/icons/cubeIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/cursor.svg.js +1 -1
- package/dist/cjs/assets/icons/delete.svg.js +1 -1
- package/dist/cjs/assets/icons/desktop_custom.svg.js +1 -1
- package/dist/cjs/assets/icons/document_pdf.svg.js +1 -1
- package/dist/cjs/assets/icons/drag_handle.svg.js +1 -1
- package/dist/cjs/assets/icons/edit.svg.js +1 -1
- package/dist/cjs/assets/icons/email-channel.svg.js +1 -1
- package/dist/cjs/assets/icons/emoji.svg.js +1 -1
- package/dist/cjs/assets/icons/errorIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/errorInfo.svg.js +1 -1
- package/dist/cjs/assets/icons/expressionless_emoji.svg.js +1 -1
- package/dist/cjs/assets/icons/facebook_channel.svg.js +1 -1
- package/dist/cjs/assets/icons/file.svg.js +1 -1
- package/dist/cjs/assets/icons/filePdf.svg.js +1 -1
- package/dist/cjs/assets/icons/gift_icon.svg.js +1 -1
- package/dist/cjs/assets/icons/gmail.svg.js +1 -1
- package/dist/cjs/assets/icons/graph.svg.js +1 -1
- package/dist/cjs/assets/icons/halfRectangle.svg.js +1 -1
- package/dist/cjs/assets/icons/help.svg.js +1 -1
- package/dist/cjs/assets/icons/horizontal_dots.svg.js +1 -1
- package/dist/cjs/assets/icons/image.svg.js +1 -1
- package/dist/cjs/assets/icons/info.svg.js +1 -1
- package/dist/cjs/assets/icons/instagram-channel.svg.js +1 -1
- package/dist/cjs/assets/icons/instagram.svg.js +1 -1
- package/dist/cjs/assets/icons/italic.svg.js +1 -1
- package/dist/cjs/assets/icons/locked.svg.js +1 -1
- package/dist/cjs/assets/icons/log_out.svg.js +1 -1
- package/dist/cjs/assets/icons/lto_icon.svg.js +1 -1
- package/dist/cjs/assets/icons/maximize.svg.js +1 -1
- package/dist/cjs/assets/icons/mobile_custom.svg.js +1 -1
- package/dist/cjs/assets/icons/more_vertical.svg.js +1 -1
- package/dist/cjs/assets/icons/openai.svg.js +1 -1
- package/dist/cjs/assets/icons/percentage_icon.svg.js +1 -1
- package/dist/cjs/assets/icons/phone.svg.js +1 -1
- package/dist/cjs/assets/icons/phone_round.svg.js +1 -1
- package/dist/cjs/assets/icons/plus.svg.js +1 -1
- package/dist/cjs/assets/icons/qrb.svg.js +1 -1
- package/dist/cjs/assets/icons/question-mark.svg.js +1 -1
- package/dist/cjs/assets/icons/quotes.svg.js +1 -1
- package/dist/cjs/assets/icons/redirect.svg.js +1 -1
- package/dist/cjs/assets/icons/refresh.svg.js +1 -1
- package/dist/cjs/assets/icons/retryIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/sad_emoji.svg.js +1 -1
- package/dist/cjs/assets/icons/search.svg.js +1 -1
- package/dist/cjs/assets/icons/searchIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/send_template.svg.js +1 -1
- package/dist/cjs/assets/icons/shipping_icon.svg.js +1 -1
- package/dist/cjs/assets/icons/similar.svg.js +1 -1
- package/dist/cjs/assets/icons/smiley_emoji.svg.js +1 -1
- package/dist/cjs/assets/icons/sparkle.svg.js +1 -1
- package/dist/cjs/assets/icons/speedometer.svg.js +1 -1
- package/dist/cjs/assets/icons/starEmpty.svg.js +1 -1
- package/dist/cjs/assets/icons/starFilled.svg.js +1 -1
- package/dist/cjs/assets/icons/starFilledV2.svg.js +1 -1
- package/dist/cjs/assets/icons/state_icon.svg.js +1 -1
- package/dist/cjs/assets/icons/strikeThrough.svg.js +1 -1
- package/dist/cjs/assets/icons/sub_category.svg.js +1 -1
- package/dist/cjs/assets/icons/successIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/sync.svg.js +1 -1
- package/dist/cjs/assets/icons/task.svg.js +1 -1
- package/dist/cjs/assets/icons/text_t9.svg.js +1 -1
- package/dist/cjs/assets/icons/tick.svg.js +1 -1
- package/dist/cjs/assets/icons/tick_double.svg.js +1 -1
- package/dist/cjs/assets/icons/triangle_error.svg.js +1 -1
- package/dist/cjs/assets/icons/undo.svg.js +1 -1
- package/dist/cjs/assets/icons/union.svg.js +1 -1
- package/dist/cjs/assets/icons/upload.svg.js +1 -1
- package/dist/cjs/assets/icons/user_icon.svg.js +1 -1
- package/dist/cjs/assets/icons/vertical_dots.svg.js +1 -1
- package/dist/cjs/assets/icons/videoRecorder.svg.js +1 -1
- package/dist/cjs/assets/icons/warning.svg.js +1 -1
- package/dist/cjs/assets/icons/warningIcon.svg.js +1 -1
- package/dist/cjs/assets/icons/website.svg.js +1 -1
- package/dist/cjs/assets/icons/whatsNew.svg.js +1 -1
- package/dist/cjs/assets/icons/whatsapp-channel.svg.js +1 -1
- package/dist/cjs/assets/icons/whatsapp_color.svg.js +1 -1
- package/dist/cjs/components/InfiniteScroll/InfiniteScroll.js +1 -1
- package/dist/cjs/components/QueryBuilder/Filters/CustomField/components/CustomField.js +1 -1
- package/dist/cjs/components/QueryBuilder/Filters/Event/components/EventFilter.js +1 -1
- package/dist/cjs/components/QueryBuilder/Filters/Segment/components/SegmentFilter.js +1 -1
- package/dist/cjs/components/QueryBuilder/Filters/UserProperty/components/UserPropertyFilter.js +1 -1
- package/dist/cjs/components/QueryBuilder/QueryBuilder.js +1 -1
- package/dist/cjs/components/QueryBuilder/Triggers/EVENTS/components/EventsTrigger.js +1 -1
- package/dist/cjs/components/QueryBuilder/Triggers/components/BaseTriggerQueryBuilderNode.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/AddNodeButton.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/AllowedListDropdown.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/EmojiPicker.js +3 -6
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/FreeText.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/FrequencyIntegerPositiveSingle.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/IgPicker.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/InTheLast.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/InTwoLast.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/IntegerPositiveSingle.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/IntegerSingleValue.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/MultiselectDropdownFreeText.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/NumberTime.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/SingleDate.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/SingleselectDropdownFreeText.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/StringSingleValue.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/TwoDate.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Components/TwoNumberInputsSeperatedByAnd.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/Connectors/Connector.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/DeleteButton.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/DropdownWrapper.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/InputLoader.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/QueryBuilderNode/Property/AddPropertyButton.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNodeUIWrapper.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNodes.js +1 -1
- package/dist/cjs/components/QueryBuilder/components/QueryBuilderNodes.js +1 -1
- package/dist/cjs/components/QueryBuilder/helpers/ApiResponse.helper.js +1 -1
- package/dist/cjs/components/QueryBuilder/helpers/Connector.helper.js +1 -1
- package/dist/cjs/components/QueryBuilder/hooks/useQueryBuilderCache.js +1 -1
- package/dist/cjs/components/QueryBuilder/redux/queryBuilder.reducer.js +1 -1
- package/dist/cjs/components/QueryBuilder/redux/selectors/useQueryBuilderCacheSelector.js +1 -1
- package/dist/cjs/components/SearchFilter/components/DatePickerButton.js +1 -1
- package/dist/cjs/components/SearchFilter/components/DateRangeOnlyButton.js +1 -1
- package/dist/cjs/components/SearchFilter/components/FilterChipListRenderer.js +1 -1
- package/dist/cjs/components/SearchFilter/index.js +1 -1
- package/dist/cjs/components/TablePagination/TablePagination.js +1 -1
- package/dist/cjs/components/WhatsAppTextEditor/WhatsAppTextEditor.js +1 -1
- package/dist/cjs/components/WhatsAppTextEditor/WhatsAppTextEditorHeader.js +2 -2
- package/dist/cjs/components/access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.js +1 -1
- package/dist/cjs/components/accordion/Accordion.js +1 -1
- package/dist/cjs/components/accordion/Accordion.style.js +1 -1
- package/dist/cjs/components/accordion/AccordionArrow.js +1 -1
- package/dist/cjs/components/action-button/ActionButton.styled.js +1 -1
- package/dist/cjs/components/action-button/ActionButtons.js +1 -1
- package/dist/cjs/components/add-variableV2/AddVariableV2.js +1 -1
- package/dist/cjs/components/ai-modals/ActivateBikAI.js +1 -1
- package/dist/cjs/components/ai-modals/AiCreditsExhausted.js +1 -1
- package/dist/cjs/components/ai-modals/AiCreditsLow.js +1 -1
- package/dist/cjs/components/ai-modals/AiSyncProgress.js +1 -1
- package/dist/cjs/components/analytics-card/AnalyticsCard.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/AnalyticsDropdown.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/AnalyticsMetric.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/AnalyticsMultiChip.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/AnalyticsTrend.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/HorizontalBarGraph/HorizontalGraph.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/Legend/Legend.js +2 -2
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/LineChart/LineChart.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/Pie/PieChart.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js +2 -2
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.styles.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/FunnelVerticalBarGraph.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/VerticalGraph.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/heatmap/HeatMap.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/scoreBlock/Chip.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/scoreBlock/HorizontalBar.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/scoreBlock/ScoreBlock.js +1 -1
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/scoreBlock/ScoreBlock.styled.js +8 -8
- package/dist/cjs/components/analytics-chips-and-dropdowns/chart/utils/calcPercentage.js +1 -1
- package/dist/cjs/components/avatar/Avatar.js +1 -1
- package/dist/cjs/components/banner/BannerInline.js +1 -1
- package/dist/cjs/components/banner/CardBanner.js +1 -1
- package/dist/cjs/components/bik-chatbot/components/AIChat.js +1 -1
- package/dist/cjs/components/bik-chatbot/components/BIKChatbot.js +1 -1
- package/dist/cjs/components/bik-chatbot/components/ChatLoadingState.js +1 -1
- package/dist/cjs/components/bik-chatbot/components/ChatWindow.js +1 -1
- package/dist/cjs/components/bik-chatbot/components/ThinkingIndicator.js +1 -1
- package/dist/cjs/components/bik-chatbot/contexts/AIContext.js +1 -1
- package/dist/cjs/components/bik-chatbot/services/aiService.js +1 -1
- package/dist/cjs/components/bik-chatbot/services/callToChatbot.js +1 -1
- package/dist/cjs/components/bik-chatbot/services/db.js +1 -1
- package/dist/cjs/components/bik-chatbot/services/useAIChat.js +1 -1
- package/dist/cjs/components/bik-chatbot/utils/markdown.js +1 -1
- package/dist/cjs/components/bik-layout/BikProfile.js +1 -1
- package/dist/cjs/components/bik-layout/BikSidebar.js +1 -1
- package/dist/cjs/components/bik-layout/SidebarPopup.js +1 -1
- package/dist/cjs/components/bik-layout/SidebarSkeleton.js +1 -1
- package/dist/cjs/components/bik-layout/SimpleSidebar.js +1 -1
- package/dist/cjs/components/button/Button.js +1 -1
- package/dist/cjs/components/button/Button.styled.js +1 -1
- package/dist/cjs/components/button/themes.js +1 -1
- package/dist/cjs/components/buttonGroup/ButtonGroup.js +1 -1
- package/dist/cjs/components/card-selection-modal/CardSelectionModal.js +1 -1
- package/dist/cjs/components/card-selector/CardSelectorGroup.js +1 -1
- package/dist/cjs/components/carousel-preview/CarouselPreview.js +1 -1
- package/dist/cjs/components/carousel-preview/CarouselPreviewCard.js +1 -1
- package/dist/cjs/components/carousel-secondary/CarouselSecondary.js +1 -1
- package/dist/cjs/components/checkBox/CheckBox.js +1 -1
- package/dist/cjs/components/checkList/CheckList.js +1 -1
- package/dist/cjs/components/code-block/CodeBlock.js +1 -1
- package/dist/cjs/components/code-block/CodeBlock.styled.js +33 -33
- package/dist/cjs/components/code-block/CodeBlockHelper.js +1 -1
- package/dist/cjs/components/country-code-picker/CountryCodePicker.js +1 -1
- package/dist/cjs/components/custom-date-time/CustomDateTime.js +1 -1
- package/dist/cjs/components/custom-date-time/CustomDateTime.styled.js +1 -0
- package/dist/cjs/components/custom-date-time/DateSelector/DateSelector.js +1 -1
- package/dist/cjs/components/dashboard-review-popup/DashboardReviewPopUp.js +1 -1
- package/dist/cjs/components/dashboard-review-popup/components/FiveStar.js +1 -1
- package/dist/cjs/components/dashboard-review-popup/components/Form.js +1 -1
- package/dist/cjs/components/dashboard-review-popup/components/ZeroState.js +1 -1
- package/dist/cjs/components/data-source-panel/DataSourceInfoFooter.js +1 -1
- package/dist/cjs/components/data-source-panel/DataSourcePanel.js +1 -1
- package/dist/cjs/components/data-source-panel/Modals/DescriptionModal.js +1 -1
- package/dist/cjs/components/datePicker/DatePicker.js +1 -1
- package/dist/cjs/components/datePicker/DatePickerWrapper.js +1 -1
- package/dist/cjs/components/datePicker/TimePicker.js +1 -1
- package/dist/cjs/components/discount-modal/CouponExpiration/CouponExpiration.js +1 -1
- package/dist/cjs/components/discount-modal/DiscountModal.js +1 -1
- package/dist/cjs/components/discount-modal/DiscountUtils.js +1 -1
- package/dist/cjs/components/discount-modal/DynamicCoupon/DynamicCoupon.js +1 -1
- package/dist/cjs/components/discount-modal/DynamicCoupon/DynamicCoupon.styled.js +6 -6
- package/dist/cjs/components/dot-pulse/DotPulse.js +2 -2
- package/dist/cjs/components/dropShadow/DropShadow.js +1 -1
- package/dist/cjs/components/dropdown/ChipInput.js +1 -1
- package/dist/cjs/components/dropdown/Dropdown.js +1 -1
- package/dist/cjs/components/dropdown/DropdownPopover/index.js +1 -1
- package/dist/cjs/components/dropdown/MenuItem/MenuItem.js +1 -1
- package/dist/cjs/components/dropdown/MultilevelDropdownPopover/index.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/OpennedDropdown.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/description/Description.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/FreeFormMenu.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/MenuItem.js +5 -5
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/MenuList.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/menu/SelectAllMenu.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/multiSelect/MultiSelectDropdownBottomBar.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/searchbox/SearchBox.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/components/searchbox/SearchZeroState.js +1 -1
- package/dist/cjs/components/dropdown/OpenedDropdown/utils/iterationOnOptions.js +1 -1
- package/dist/cjs/components/dropdown/hooks/useDropdown.js +1 -1
- package/dist/cjs/components/dynamic-tabs/DynamicTabs.js +1 -1
- package/dist/cjs/components/feature-announcements/FeatureAnnouncementProvider.js +1 -1
- package/dist/cjs/components/feature-announcements/MajorUpdatePopup.js +1 -1
- package/dist/cjs/components/feature-announcements/MinorUpdatePopup.js +1 -1
- package/dist/cjs/components/feature-announcements/VideoModal.js +1 -1
- package/dist/cjs/components/feature-announcements/hooks/useFeatureAnnouncements.js +1 -1
- package/dist/cjs/components/feature-announcements/utils/animationHelpers.js +1 -1
- package/dist/cjs/components/feature-announcements/utils/elementHelpers.js +1 -1
- package/dist/cjs/components/file-uploader/FileUploader.js +1 -1
- package/dist/cjs/components/floater/floater.js +1 -1
- package/dist/cjs/components/floating-input-dropdown/FloatingInputDropdown.js +4 -4
- package/dist/cjs/components/icon-button/IconButton.js +1 -1
- package/dist/cjs/components/icon-button/IconButton.styled.js +1 -1
- package/dist/cjs/components/image-compress/ImageCompress.js +1 -1
- package/dist/cjs/components/image-cropper/BikImageCropper.js +1 -1
- package/dist/cjs/components/image-cropper/BikImagePipeline/BikImagePipeline.js +1 -1
- package/dist/cjs/components/input/ChipInput.js +1 -1
- package/dist/cjs/components/input/ChipInput.styled.js +1 -146
- package/dist/cjs/components/input/Input-helper.js +1 -1
- package/dist/cjs/components/input/Input.js +1 -1
- package/dist/cjs/components/input/Input.styled.js +1 -1
- package/dist/cjs/components/input-with-vars/InputWithVariables.js +1 -1
- package/dist/cjs/components/keywords-input/KeywordsInput.js +1 -1
- package/dist/cjs/components/list-item/ListItem.js +1 -1
- package/dist/cjs/components/markdown/index.js +1 -1
- package/dist/cjs/components/modals/Modal.js +1 -1
- package/dist/cjs/components/multi-level-dropdown/GroupedMenuList.js +1 -1
- package/dist/cjs/components/multi-level-dropdown/MenuItem.js +1 -1
- package/dist/cjs/components/multi-level-dropdown/MenuList.js +1 -1
- package/dist/cjs/components/multi-level-dropdown/MultiLevelDropdown.js +1 -1
- package/dist/cjs/components/multi-level-dropdown/MultiLevelDropdown.styled.js +20 -20
- package/dist/cjs/components/pagination/Pagination.js +1 -1
- package/dist/cjs/components/plans/NewSubscriptionPlan.js +1 -1
- package/dist/cjs/components/plans/SubscriptionPlan.js +1 -1
- package/dist/cjs/components/plans/SubscriptionPlanSelector.js +1 -1
- package/dist/cjs/components/plans/SubscriptionPlansCollected.js +1 -1
- package/dist/cjs/components/postPicker/postPicker.js +1 -1
- package/dist/cjs/components/product-picker/ProductPickerModal.js +1 -1
- package/dist/cjs/components/product-picker-v2/ProductPickerShimmer.js +1 -1
- package/dist/cjs/components/product-picker-v2/collectionScreen.js +1 -1
- package/dist/cjs/components/product-picker-v2/emptyState.js +1 -1
- package/dist/cjs/components/product-picker-v2/helpers/ProductHelper.js +1 -1
- package/dist/cjs/components/product-picker-v2/modal.js +1 -1
- package/dist/cjs/components/product-picker-v2/product.js +1 -1
- package/dist/cjs/components/product-picker-v2/productScreen.js +1 -1
- package/dist/cjs/components/product-picker-v2/rearrangeScreen.js +1 -1
- package/dist/cjs/components/product-picker-v2/searchScreen.js +1 -1
- package/dist/cjs/components/product-picker-v2/selectedScreen.js +1 -1
- package/dist/cjs/components/product-picker-v2/utility.js +1 -1
- package/dist/cjs/components/product-picker-v2/variantComponents.js +1 -1
- package/dist/cjs/components/progress-bar/CircularProgressBar.js +1 -1
- package/dist/cjs/components/progress-bar/ProgressBarComponent.js +1 -1
- package/dist/cjs/components/radioButton/RadioButton.js +1 -1
- package/dist/cjs/components/radioList/RadioList.js +1 -1
- package/dist/cjs/components/resizeImage/index.js +1 -1
- package/dist/cjs/components/searchBar/searchBar.js +1 -1
- package/dist/cjs/components/shimmer/ShimmerComponent/BikShimmer.js +1 -1
- package/dist/cjs/components/shimmer-image/ShimmerImage.js +1 -1
- package/dist/cjs/components/side-modal/SideModal.style.js +16 -16
- package/dist/cjs/components/slider/slider.js +1 -1
- package/dist/cjs/components/spinner/Spinner.js +1 -1
- package/dist/cjs/components/star-rating/Star.js +1 -1
- package/dist/cjs/components/star-rating/StarRating.js +1 -1
- package/dist/cjs/components/states/ShopifyScopeWrapper.js +1 -1
- package/dist/cjs/components/stepper/Stepper.js +1 -1
- package/dist/cjs/components/switch/Switch.js +1 -1
- package/dist/cjs/components/tabs/Tabs.js +1 -1
- package/dist/cjs/components/tag/Tag.js +1 -1
- package/dist/cjs/components/template-context-mapper/TemplateContextMapper.js +1 -1
- package/dist/cjs/components/template-context-mapper/custom-hooks/useAdditionalVariables.js +1 -1
- package/dist/cjs/components/template-context-mapper/helpers/WebpushTemplateHelper.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/DesktopPreview.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/DiscountCodeComponent.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/EditMediaModal.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/EditWebpushTemplate.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/EditWhatsAppCarouselTemplateV2.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/EditWhatsAppTemplateV2.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/Footer.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/Header.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/MobilePreview.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/QueryParamsComponent.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/TemplateAnalyticsComponent.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/TemplateSelectModalContent.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/VariableConnector.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/VariableConnectorWhatsApp.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/VariableConnectorsPanel.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/VariableEditorHeader.js +2 -2
- package/dist/cjs/components/template-context-mapper/modalElements/WhatsAppTemplateCardButtonV2.js +1 -1
- package/dist/cjs/components/template-context-mapper/modalElements/useEditWhtasappTemplateMedia.js +1 -1
- package/dist/cjs/components/template-context-mapper/utils/convertPlaceholdersToBikDropdown.js +1 -1
- package/dist/cjs/components/template-context-mapper/utils/getDataFromTemplateComponent.js +1 -1
- package/dist/cjs/components/template-context-mapper/utils/highlightFor.js +1 -1
- package/dist/cjs/components/template-context-mapper/utils/validateName.js +1 -1
- package/dist/cjs/components/template-preview/EmailTemplateThumbnailPreview.js +1 -1
- package/dist/cjs/components/template-preview/RCS/RCSButtons.js +1 -1
- package/dist/cjs/components/template-preview/RCS/RCSChatPreview.js +1 -1
- package/dist/cjs/components/template-preview/RCS/RCSMediaCard.js +1 -1
- package/dist/cjs/components/template-preview/SmsTemplatePreview.js +1 -1
- package/dist/cjs/components/template-preview/TemplatePreview.js +1 -1
- package/dist/cjs/components/template-preview/WhatsApp/ChatBtn.js +1 -1
- package/dist/cjs/components/template-preview/WhatsApp/ChatUI.js +1 -1
- package/dist/cjs/components/template-preview/WhatsApp/ChatUiV2.js +1 -1
- package/dist/cjs/components/template-preview/WhatsApp/MediaCard.js +1 -1
- package/dist/cjs/components/template-preview/WhatsApp/RenderTemplateWithVariable.js +1 -1
- package/dist/cjs/components/template-preview/WhatsAppTemplatePreview.js +1 -1
- package/dist/cjs/components/template-preview/helpers/SmsTemplateHelper.js +1 -1
- package/dist/cjs/components/template-preview/helpers/TemplateCreatorHelper.js +1 -1
- package/dist/cjs/components/template-preview/helpers/VariableEditorHelper.js +1 -1
- package/dist/cjs/components/template-preview/utils/TemplateHelperUtils.js +1 -1
- package/dist/cjs/components/template-preview/utils/getPreviewPropLen.js +1 -1
- package/dist/cjs/components/template-preview/webpush/WebpushPreview.js +1 -1
- package/dist/cjs/components/text-picker/TextPickerCategoryCard.js +5 -5
- package/dist/cjs/components/text-picker/TextPickerFooter.js +3 -3
- package/dist/cjs/components/text-picker/TextPickerItemRow.js +4 -4
- package/dist/cjs/components/text-picker/TextPickerModal.js +1 -1
- package/dist/cjs/components/text-picker/TextPickerSelectAllRow.js +5 -5
- package/dist/cjs/components/toaster/Toaster.js +1 -1
- package/dist/cjs/components/unsatisfactory-response-list/UnsatisfactoryCountIntentWiseModal.js +1 -1
- package/dist/cjs/components/unsatisfactory-response-list/UnsatisfactoryResponseList.js +1 -1
- package/dist/cjs/components/variable-picker-v3/Content.js +1 -1
- package/dist/cjs/components/variable-picker-v3/SubHeaderItems.js +1 -1
- package/dist/cjs/components/variable-picker-v3/recommendVaribles.js +1 -1
- package/dist/cjs/components/variable-picker-v3/searchVariables.js +1 -1
- package/dist/cjs/components/whats-new/WhatsNew.js +1 -1
- package/dist/cjs/components/whats-new/WhatsNewButton.js +1 -1
- package/dist/cjs/components/whats-new/WhatsNewPanel.js +1 -1
- package/dist/cjs/components/whats-new/WhatsNewProvider.js +1 -1
- package/dist/cjs/components/whats-new/useWhatsNew.js +1 -1
- package/dist/cjs/helpers/BaseWhatsappContentLang.helper.js +1 -1
- package/dist/cjs/hooks/useCurreny.js +1 -1
- package/dist/cjs/hooks/useOutside.js +1 -1
- package/dist/cjs/node_modules/@reduxjs/toolkit/dist/redux-toolkit.modern.mjs.js +1 -1
- package/dist/cjs/node_modules/immer/dist/immer.mjs.js +1 -1
- package/dist/cjs/node_modules/lodash.debounce/index.js +1 -1
- package/dist/cjs/src/components/banner/Banner.stories.d.ts +6 -9
- package/dist/cjs/src/components/bik-layout/CommonStyles.d.ts +2 -2
- package/dist/cjs/src/components/floating-action-button/FloatingActionButton.styles.d.ts +8 -8
- package/dist/cjs/src/components/input/ChipInput.d.ts +0 -1
- package/dist/cjs/src/components/input/ChipInput.styled.d.ts +14 -871
- package/dist/cjs/src/components/progress-bar/ProgressBarComponent.d.ts +0 -1
- package/dist/cjs/src/components/shimmer-image/ShimmerImage.stories.d.ts +5 -6
- package/dist/cjs/src/components/tag/Tag.stories.d.ts +19 -34
- package/dist/cjs/utils/DateUtils.js +1 -1
- package/dist/cjs/utils/StringUtils.js +1 -1
- package/dist/cjs/utils/resizeImage.js +1 -1
- package/dist/cjs/utils/unCamelCase.js +1 -1
- package/dist/esm/_virtual/_tslib.js +1 -1
- package/dist/esm/amplitude/Track.stories.d.ts +4 -0
- package/dist/esm/amplitude/index.js +1 -1
- package/dist/esm/assets/icons/AiEdit.svg.js +1 -1
- package/dist/esm/assets/icons/Ai_event_generating.svg.js +1 -1
- package/dist/esm/assets/icons/Bik_logo.svg.js +1 -1
- package/dist/esm/assets/icons/ChartBar.svg.js +1 -1
- package/dist/esm/assets/icons/ChartPie.svg.js +1 -1
- package/dist/esm/assets/icons/HelpIcon.svg.js +1 -1
- package/dist/esm/assets/icons/Idea.svg.js +1 -1
- package/dist/esm/assets/icons/RCS_PDF.svg.js +1 -1
- package/dist/esm/assets/icons/RedirectToNew.svg.js +1 -1
- package/dist/esm/assets/icons/WhiteStarFilled.svg.js +1 -1
- package/dist/esm/assets/icons/aiContentIcon.svg.js +1 -1
- package/dist/esm/assets/icons/alert.svg.js +1 -1
- package/dist/esm/assets/icons/alert_triangle.svg.js +1 -1
- package/dist/esm/assets/icons/arrow_back.svg.js +1 -1
- package/dist/esm/assets/icons/arrow_down.svg.js +1 -1
- package/dist/esm/assets/icons/arrow_left.svg.js +1 -1
- package/dist/esm/assets/icons/arrow_up.svg.js +1 -1
- package/dist/esm/assets/icons/back_icon.svg.js +1 -1
- package/dist/esm/assets/icons/bik_livechat.svg.js +1 -1
- package/dist/esm/assets/icons/bold.svg.js +1 -1
- package/dist/esm/assets/icons/box.svg.js +1 -1
- package/dist/esm/assets/icons/boxV2.svg.js +1 -1
- package/dist/esm/assets/icons/box_round.svg.js +1 -1
- package/dist/esm/assets/icons/box_search.svg.js +1 -1
- package/dist/esm/assets/icons/broken_media_image.svg.js +1 -1
- package/dist/esm/assets/icons/calendar.svg.js +1 -1
- package/dist/esm/assets/icons/card_footer_arraw.svg.js +1 -1
- package/dist/esm/assets/icons/chat-channel.svg.js +1 -1
- package/dist/esm/assets/icons/check.svg.js +1 -1
- package/dist/esm/assets/icons/checkCircle.svg.js +1 -1
- package/dist/esm/assets/icons/checklistIcon.svg.js +1 -1
- package/dist/esm/assets/icons/chevronDown.svg.js +1 -1
- package/dist/esm/assets/icons/chevronDownOutline.svg.js +1 -1
- package/dist/esm/assets/icons/chevronLeft.svg.js +1 -1
- package/dist/esm/assets/icons/chevronLeft2.svg.js +1 -1
- package/dist/esm/assets/icons/chevronRight.svg.js +1 -1
- package/dist/esm/assets/icons/chevronRight2.svg.js +1 -1
- package/dist/esm/assets/icons/chevronRightAlt.svg.js +1 -1
- package/dist/esm/assets/icons/chevronUpOutline.svg.js +1 -1
- package/dist/esm/assets/icons/click.svg.js +1 -1
- package/dist/esm/assets/icons/clock.svg.js +1 -1
- package/dist/esm/assets/icons/copy-code-icon.svg.js +1 -1
- package/dist/esm/assets/icons/cross.svg.js +1 -1
- package/dist/esm/assets/icons/cubeIcon.svg.js +1 -1
- package/dist/esm/assets/icons/cursor.svg.js +1 -1
- package/dist/esm/assets/icons/delete.svg.js +1 -1
- package/dist/esm/assets/icons/desktop_custom.svg.js +1 -1
- package/dist/esm/assets/icons/document_pdf.svg.js +1 -1
- package/dist/esm/assets/icons/drag_handle.svg.js +1 -1
- package/dist/esm/assets/icons/edit.svg.js +1 -1
- package/dist/esm/assets/icons/email-channel.svg.js +1 -1
- package/dist/esm/assets/icons/emoji.svg.js +1 -1
- package/dist/esm/assets/icons/errorIcon.svg.js +1 -1
- package/dist/esm/assets/icons/errorInfo.svg.js +1 -1
- package/dist/esm/assets/icons/expressionless_emoji.svg.js +1 -1
- package/dist/esm/assets/icons/facebook_channel.svg.js +1 -1
- package/dist/esm/assets/icons/file.svg.js +1 -1
- package/dist/esm/assets/icons/filePdf.svg.js +1 -1
- package/dist/esm/assets/icons/gift_icon.svg.js +1 -1
- package/dist/esm/assets/icons/gmail.svg.js +1 -1
- package/dist/esm/assets/icons/graph.svg.js +1 -1
- package/dist/esm/assets/icons/halfRectangle.svg.js +1 -1
- package/dist/esm/assets/icons/help.svg.js +1 -1
- package/dist/esm/assets/icons/horizontal_dots.svg.js +1 -1
- package/dist/esm/assets/icons/image.svg.js +1 -1
- package/dist/esm/assets/icons/info.svg.js +1 -1
- package/dist/esm/assets/icons/instagram-channel.svg.js +1 -1
- package/dist/esm/assets/icons/instagram.svg.js +1 -1
- package/dist/esm/assets/icons/italic.svg.js +1 -1
- package/dist/esm/assets/icons/locked.svg.js +1 -1
- package/dist/esm/assets/icons/log_out.svg.js +1 -1
- package/dist/esm/assets/icons/lto_icon.svg.js +1 -1
- package/dist/esm/assets/icons/maximize.svg.js +1 -1
- package/dist/esm/assets/icons/mobile_custom.svg.js +1 -1
- package/dist/esm/assets/icons/more_vertical.svg.js +1 -1
- package/dist/esm/assets/icons/openai.svg.js +1 -1
- package/dist/esm/assets/icons/percentage_icon.svg.js +1 -1
- package/dist/esm/assets/icons/phone.svg.js +1 -1
- package/dist/esm/assets/icons/phone_round.svg.js +1 -1
- package/dist/esm/assets/icons/plus.svg.js +1 -1
- package/dist/esm/assets/icons/qrb.svg.js +1 -1
- package/dist/esm/assets/icons/question-mark.svg.js +1 -1
- package/dist/esm/assets/icons/quotes.svg.js +1 -1
- package/dist/esm/assets/icons/redirect.svg.js +1 -1
- package/dist/esm/assets/icons/refresh.svg.js +1 -1
- package/dist/esm/assets/icons/retryIcon.svg.js +1 -1
- package/dist/esm/assets/icons/sad_emoji.svg.js +1 -1
- package/dist/esm/assets/icons/search.svg.js +1 -1
- package/dist/esm/assets/icons/searchIcon.svg.js +1 -1
- package/dist/esm/assets/icons/send_template.svg.js +1 -1
- package/dist/esm/assets/icons/shipping_icon.svg.js +1 -1
- package/dist/esm/assets/icons/similar.svg.js +1 -1
- package/dist/esm/assets/icons/smiley_emoji.svg.js +1 -1
- package/dist/esm/assets/icons/sparkle.svg.js +1 -1
- package/dist/esm/assets/icons/speedometer.svg.js +1 -1
- package/dist/esm/assets/icons/starEmpty.svg.js +1 -1
- package/dist/esm/assets/icons/starFilled.svg.js +1 -1
- package/dist/esm/assets/icons/starFilledV2.svg.js +1 -1
- package/dist/esm/assets/icons/state_icon.svg.js +1 -1
- package/dist/esm/assets/icons/strikeThrough.svg.js +1 -1
- package/dist/esm/assets/icons/sub_category.svg.js +1 -1
- package/dist/esm/assets/icons/successIcon.svg.js +1 -1
- package/dist/esm/assets/icons/sync.svg.js +1 -1
- package/dist/esm/assets/icons/task.svg.js +1 -1
- package/dist/esm/assets/icons/text_t9.svg.js +1 -1
- package/dist/esm/assets/icons/tick.svg.js +1 -1
- package/dist/esm/assets/icons/tick_double.svg.js +1 -1
- package/dist/esm/assets/icons/triangle_error.svg.js +1 -1
- package/dist/esm/assets/icons/undo.svg.js +1 -1
- package/dist/esm/assets/icons/union.svg.js +1 -1
- package/dist/esm/assets/icons/upload.svg.js +1 -1
- package/dist/esm/assets/icons/user_icon.svg.js +1 -1
- package/dist/esm/assets/icons/vertical_dots.svg.js +1 -1
- package/dist/esm/assets/icons/videoRecorder.svg.js +1 -1
- package/dist/esm/assets/icons/warning.svg.js +1 -1
- package/dist/esm/assets/icons/warningIcon.svg.js +1 -1
- package/dist/esm/assets/icons/website.svg.js +1 -1
- package/dist/esm/assets/icons/whatsNew.svg.js +1 -1
- package/dist/esm/assets/icons/whatsapp-channel.svg.js +1 -1
- package/dist/esm/assets/icons/whatsapp_color.svg.js +1 -1
- package/dist/esm/components/InfiniteScroll/InfiniteScroll.js +1 -1
- package/dist/esm/components/QueryBuilder/Filters/CustomField/components/CustomField.js +1 -1
- package/dist/esm/components/QueryBuilder/Filters/Event/components/EventFilter.js +1 -1
- package/dist/esm/components/QueryBuilder/Filters/Segment/components/SegmentFilter.js +1 -1
- package/dist/esm/components/QueryBuilder/Filters/UserProperty/components/UserPropertyFilter.js +1 -1
- package/dist/esm/components/QueryBuilder/QueryBuilder.js +1 -1
- package/dist/esm/components/QueryBuilder/Triggers/EVENTS/components/EventsTrigger.js +1 -1
- package/dist/esm/components/QueryBuilder/Triggers/components/BaseTriggerQueryBuilderNode.js +1 -1
- package/dist/esm/components/QueryBuilder/components/AddNodeButton.js +1 -1
- package/dist/esm/components/QueryBuilder/components/AllowedListDropdown.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/EmojiPicker.js +4 -7
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/FreeText.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/FrequencyIntegerPositiveSingle.js +2 -2
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/IgPicker.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/InTheLast.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/InTwoLast.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/IntegerPositiveSingle.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/IntegerSingleValue.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/MultiselectDropdownFreeText.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/NumberTime.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/SingleDate.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/SingleselectDropdownFreeText.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/StringSingleValue.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/TwoDate.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Components/TwoNumberInputsSeperatedByAnd.js +1 -1
- package/dist/esm/components/QueryBuilder/components/Connectors/Connector.js +1 -1
- package/dist/esm/components/QueryBuilder/components/DeleteButton.js +1 -1
- package/dist/esm/components/QueryBuilder/components/DropdownWrapper.js +1 -1
- package/dist/esm/components/QueryBuilder/components/InputLoader.js +4 -4
- package/dist/esm/components/QueryBuilder/components/QueryBuilderNode/Property/AddPropertyButton.js +1 -1
- package/dist/esm/components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNode.js +1 -1
- package/dist/esm/components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNodeUIWrapper.js +1 -1
- package/dist/esm/components/QueryBuilder/components/QueryBuilderNode/Property/PropertyNodes.js +1 -1
- package/dist/esm/components/QueryBuilder/components/QueryBuilderNodes.js +1 -1
- package/dist/esm/components/QueryBuilder/helpers/ApiResponse.helper.js +1 -1
- package/dist/esm/components/QueryBuilder/helpers/Connector.helper.js +1 -1
- package/dist/esm/components/QueryBuilder/hooks/useQueryBuilderCache.js +1 -1
- package/dist/esm/components/QueryBuilder/redux/queryBuilder.reducer.js +1 -1
- package/dist/esm/components/QueryBuilder/redux/selectors/useQueryBuilderCacheSelector.js +1 -1
- package/dist/esm/components/SearchFilter/components/DatePickerButton.js +1 -1
- package/dist/esm/components/SearchFilter/components/DateRangeOnlyButton.js +1 -1
- package/dist/esm/components/SearchFilter/components/FilterChipListRenderer.js +1 -1
- package/dist/esm/components/SearchFilter/index.js +1 -1
- package/dist/esm/components/TablePagination/TablePagination.js +1 -1
- package/dist/esm/components/WhatsAppTextEditor/WhatsAppTextEditor.js +1 -1
- package/dist/esm/components/WhatsAppTextEditor/WhatsAppTextEditorHeader.js +2 -2
- package/dist/esm/components/access-token-troubleshoot-dialog/AccessTokenTroubleshootDialog.js +1 -1
- package/dist/esm/components/accordion/Accordion.js +1 -1
- package/dist/esm/components/accordion/Accordion.style.js +1 -1
- package/dist/esm/components/accordion/AccordionArrow.js +1 -1
- package/dist/esm/components/action-button/ActionButton.styled.js +1 -1
- package/dist/esm/components/action-button/ActionButtons.js +1 -1
- package/dist/esm/components/add-variableV2/AddVariableV2.js +1 -1
- package/dist/esm/components/ai-modals/ActivateBikAI.js +1 -1
- package/dist/esm/components/ai-modals/AiCreditsExhausted.js +1 -1
- package/dist/esm/components/ai-modals/AiCreditsLow.js +1 -1
- package/dist/esm/components/ai-modals/AiSyncProgress.js +1 -1
- package/dist/esm/components/analytics-card/AnalyticsCard.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/AnalyticsDropdown.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/AnalyticsMetric.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/AnalyticsMultiChip.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/AnalyticsTrend.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/HorizontalBarGraph/HorizontalGraph.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/Legend/Legend.js +2 -2
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/LineChart/LineChart.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/Pie/PieChart.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js +2 -2
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.styles.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/FunnelVerticalBarGraph.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/VerticalBarGraph/VerticalGraph.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/heatmap/HeatMap.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/scoreBlock/Chip.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/scoreBlock/HorizontalBar.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/scoreBlock/ScoreBlock.js +1 -1
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/scoreBlock/ScoreBlock.styled.js +5 -5
- package/dist/esm/components/analytics-chips-and-dropdowns/chart/utils/calcPercentage.js +1 -1
- package/dist/esm/components/avatar/Avatar.js +1 -1
- package/dist/esm/components/banner/BannerInline.js +1 -1
- package/dist/esm/components/banner/CardBanner.js +1 -1
- package/dist/esm/components/bik-chatbot/components/AIChat.js +1 -1
- package/dist/esm/components/bik-chatbot/components/BIKChatbot.js +1 -1
- package/dist/esm/components/bik-chatbot/components/ChatLoadingState.js +1 -1
- package/dist/esm/components/bik-chatbot/components/ChatWindow.js +1 -1
- package/dist/esm/components/bik-chatbot/components/ThinkingIndicator.js +1 -1
- package/dist/esm/components/bik-chatbot/contexts/AIContext.js +1 -1
- package/dist/esm/components/bik-chatbot/services/aiService.js +1 -1
- package/dist/esm/components/bik-chatbot/services/callToChatbot.js +1 -1
- package/dist/esm/components/bik-chatbot/services/db.js +1 -1
- package/dist/esm/components/bik-chatbot/services/useAIChat.js +1 -1
- package/dist/esm/components/bik-chatbot/utils/markdown.js +1 -1
- package/dist/esm/components/bik-layout/BikProfile.js +1 -1
- package/dist/esm/components/bik-layout/BikSidebar.js +1 -1
- package/dist/esm/components/bik-layout/SidebarPopup.js +1 -1
- package/dist/esm/components/bik-layout/SidebarSkeleton.js +1 -1
- package/dist/esm/components/bik-layout/SimpleSidebar.js +1 -1
- package/dist/esm/components/button/Button.js +1 -1
- package/dist/esm/components/button/Button.styled.js +1 -1
- package/dist/esm/components/button/themes.js +1 -1
- package/dist/esm/components/buttonGroup/ButtonGroup.js +1 -1
- package/dist/esm/components/card-selection-modal/CardSelectionModal.js +1 -1
- package/dist/esm/components/card-selector/CardSelectorGroup.js +1 -1
- package/dist/esm/components/carousel-preview/CarouselPreview.js +1 -1
- package/dist/esm/components/carousel-preview/CarouselPreviewCard.js +1 -1
- package/dist/esm/components/carousel-secondary/CarouselSecondary.js +1 -1
- package/dist/esm/components/checkBox/CheckBox.js +1 -1
- package/dist/esm/components/checkList/CheckList.js +1 -1
- package/dist/esm/components/code-block/CodeBlock.js +1 -1
- package/dist/esm/components/code-block/CodeBlock.styled.js +31 -31
- package/dist/esm/components/code-block/CodeBlockHelper.js +1 -1
- package/dist/esm/components/country-code-picker/CountryCodePicker.js +1 -1
- package/dist/esm/components/custom-date-time/CustomDateTime.js +1 -1
- package/dist/esm/components/custom-date-time/CustomDateTime.styled.js +1 -0
- package/dist/esm/components/custom-date-time/DateSelector/DateSelector.js +1 -1
- package/dist/esm/components/dashboard-review-popup/DashboardReviewPopUp.js +1 -1
- package/dist/esm/components/dashboard-review-popup/components/FiveStar.js +1 -1
- package/dist/esm/components/dashboard-review-popup/components/Form.js +1 -1
- package/dist/esm/components/dashboard-review-popup/components/ZeroState.js +2 -2
- package/dist/esm/components/data-source-panel/DataSourceInfoFooter.js +1 -1
- package/dist/esm/components/data-source-panel/DataSourcePanel.js +1 -1
- package/dist/esm/components/data-source-panel/Modals/DescriptionModal.js +1 -1
- package/dist/esm/components/datePicker/DatePicker.js +1 -1
- package/dist/esm/components/datePicker/DatePickerWrapper.js +1 -1
- package/dist/esm/components/datePicker/TimePicker.js +1 -1
- package/dist/esm/components/discount-modal/CouponExpiration/CouponExpiration.js +1 -1
- package/dist/esm/components/discount-modal/DiscountModal.js +1 -1
- package/dist/esm/components/discount-modal/DiscountUtils.js +1 -1
- package/dist/esm/components/discount-modal/DynamicCoupon/DynamicCoupon.js +1 -1
- package/dist/esm/components/discount-modal/DynamicCoupon/DynamicCoupon.styled.js +8 -8
- package/dist/esm/components/dot-pulse/DotPulse.js +2 -2
- package/dist/esm/components/dropShadow/DropShadow.js +1 -1
- package/dist/esm/components/dropdown/ChipInput.js +1 -1
- package/dist/esm/components/dropdown/Dropdown.js +1 -1
- package/dist/esm/components/dropdown/DropdownPopover/index.js +1 -1
- package/dist/esm/components/dropdown/MenuItem/MenuItem.js +1 -1
- package/dist/esm/components/dropdown/MultilevelDropdownPopover/index.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/OpennedDropdown.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/description/Description.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/FreeFormMenu.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/MenuItem.js +5 -5
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/MenuList.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/menu/SelectAllMenu.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/multiSelect/MultiSelectDropdownBottomBar.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/searchbox/SearchBox.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/components/searchbox/SearchZeroState.js +1 -1
- package/dist/esm/components/dropdown/OpenedDropdown/utils/iterationOnOptions.js +1 -1
- package/dist/esm/components/dropdown/hooks/useDropdown.js +1 -1
- package/dist/esm/components/dynamic-tabs/DynamicTabs.js +1 -1
- package/dist/esm/components/feature-announcements/FeatureAnnouncementProvider.js +1 -1
- package/dist/esm/components/feature-announcements/MajorUpdatePopup.js +1 -1
- package/dist/esm/components/feature-announcements/MinorUpdatePopup.js +1 -1
- package/dist/esm/components/feature-announcements/VideoModal.js +1 -1
- package/dist/esm/components/feature-announcements/hooks/useFeatureAnnouncements.js +1 -1
- package/dist/esm/components/feature-announcements/utils/animationHelpers.js +1 -1
- package/dist/esm/components/feature-announcements/utils/elementHelpers.js +1 -1
- package/dist/esm/components/file-uploader/FileUploader.js +1 -1
- package/dist/esm/components/floater/floater.js +1 -1
- package/dist/esm/components/floating-input-dropdown/FloatingInputDropdown.js +3 -3
- package/dist/esm/components/icon-button/IconButton.js +1 -1
- package/dist/esm/components/icon-button/IconButton.styled.js +1 -1
- package/dist/esm/components/image-compress/ImageCompress.js +1 -1
- package/dist/esm/components/image-cropper/BikImageCropper.js +1 -1
- package/dist/esm/components/image-cropper/BikImagePipeline/BikImagePipeline.js +1 -1
- package/dist/esm/components/input/ChipInput.js +1 -1
- package/dist/esm/components/input/ChipInput.styled.js +1 -146
- package/dist/esm/components/input/Input-helper.js +1 -1
- package/dist/esm/components/input/Input.js +1 -1
- package/dist/esm/components/input/Input.styled.js +1 -1
- package/dist/esm/components/input-with-vars/InputWithVariables.js +1 -1
- package/dist/esm/components/keywords-input/KeywordsInput.js +1 -1
- package/dist/esm/components/list-item/ListItem.js +1 -1
- package/dist/esm/components/markdown/index.js +1 -1
- package/dist/esm/components/modals/Modal.js +1 -1
- package/dist/esm/components/multi-level-dropdown/GroupedMenuList.js +1 -1
- package/dist/esm/components/multi-level-dropdown/MenuItem.js +1 -1
- package/dist/esm/components/multi-level-dropdown/MenuList.js +1 -1
- package/dist/esm/components/multi-level-dropdown/MultiLevelDropdown.js +1 -1
- package/dist/esm/components/multi-level-dropdown/MultiLevelDropdown.styled.js +25 -25
- package/dist/esm/components/pagination/Pagination.js +1 -1
- package/dist/esm/components/plans/NewSubscriptionPlan.js +1 -1
- package/dist/esm/components/plans/SubscriptionPlan.js +1 -1
- package/dist/esm/components/plans/SubscriptionPlanSelector.js +1 -1
- package/dist/esm/components/plans/SubscriptionPlansCollected.js +1 -1
- package/dist/esm/components/postPicker/postPicker.js +1 -1
- package/dist/esm/components/product-picker/ProductPickerModal.js +1 -1
- package/dist/esm/components/product-picker-v2/ProductPickerShimmer.js +1 -1
- package/dist/esm/components/product-picker-v2/collectionScreen.js +1 -1
- package/dist/esm/components/product-picker-v2/emptyState.js +1 -1
- package/dist/esm/components/product-picker-v2/helpers/ProductHelper.js +1 -1
- package/dist/esm/components/product-picker-v2/modal.js +1 -1
- package/dist/esm/components/product-picker-v2/product.js +1 -1
- package/dist/esm/components/product-picker-v2/productScreen.js +1 -1
- package/dist/esm/components/product-picker-v2/rearrangeScreen.js +1 -1
- package/dist/esm/components/product-picker-v2/searchScreen.js +1 -1
- package/dist/esm/components/product-picker-v2/selectedScreen.js +1 -1
- package/dist/esm/components/product-picker-v2/utility.js +1 -1
- package/dist/esm/components/product-picker-v2/variantComponents.js +1 -1
- package/dist/esm/components/progress-bar/CircularProgressBar.js +1 -1
- package/dist/esm/components/progress-bar/ProgressBarComponent.js +3 -3
- package/dist/esm/components/radioButton/RadioButton.js +1 -1
- package/dist/esm/components/radioList/RadioList.js +1 -1
- package/dist/esm/components/resizeImage/index.js +1 -1
- package/dist/esm/components/searchBar/searchBar.js +1 -1
- package/dist/esm/components/shimmer/ShimmerComponent/BikShimmer.js +1 -1
- package/dist/esm/components/shimmer-image/ShimmerImage.js +1 -1
- package/dist/esm/components/side-modal/SideModal.style.js +9 -9
- package/dist/esm/components/slider/slider.js +1 -1
- package/dist/esm/components/spinner/Spinner.js +1 -1
- package/dist/esm/components/star-rating/Star.js +1 -1
- package/dist/esm/components/star-rating/StarRating.js +2 -2
- package/dist/esm/components/states/ShopifyScopeWrapper.js +1 -1
- package/dist/esm/components/stepper/Stepper.js +1 -1
- package/dist/esm/components/switch/Switch.js +1 -1
- package/dist/esm/components/tabs/Tabs.js +1 -1
- package/dist/esm/components/tag/Tag.js +1 -1
- package/dist/esm/components/template-context-mapper/TemplateContextMapper.js +1 -1
- package/dist/esm/components/template-context-mapper/custom-hooks/useAdditionalVariables.js +1 -1
- package/dist/esm/components/template-context-mapper/helpers/WebpushTemplateHelper.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/DesktopPreview.js +3 -3
- package/dist/esm/components/template-context-mapper/modalElements/DiscountCodeComponent.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/EditMediaModal.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/EditWebpushTemplate.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/EditWhatsAppCarouselTemplateV2.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/EditWhatsAppTemplateV2.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/Footer.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/Header.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/MobilePreview.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/QueryParamsComponent.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/TemplateAnalyticsComponent.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/TemplateAnalyticsSkeleton.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/TemplateSelectModalContent.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/VariableConnector.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/VariableConnectorWhatsApp.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/VariableConnectorsPanel.js +2 -2
- package/dist/esm/components/template-context-mapper/modalElements/VariableEditorHeader.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/WhatsAppTemplateCardButtonV2.js +1 -1
- package/dist/esm/components/template-context-mapper/modalElements/useEditWhtasappTemplateMedia.js +1 -1
- package/dist/esm/components/template-context-mapper/utils/convertPlaceholdersToBikDropdown.js +1 -1
- package/dist/esm/components/template-context-mapper/utils/getDataFromTemplateComponent.js +1 -1
- package/dist/esm/components/template-context-mapper/utils/highlightFor.js +1 -1
- package/dist/esm/components/template-context-mapper/utils/validateName.js +1 -1
- package/dist/esm/components/template-preview/EmailTemplateThumbnailPreview.js +1 -1
- package/dist/esm/components/template-preview/RCS/RCSButtons.js +1 -1
- package/dist/esm/components/template-preview/RCS/RCSChatPreview.js +1 -1
- package/dist/esm/components/template-preview/RCS/RCSMediaCard.js +1 -1
- package/dist/esm/components/template-preview/SmsTemplatePreview.js +1 -1
- package/dist/esm/components/template-preview/TemplatePreview.js +1 -1
- package/dist/esm/components/template-preview/WhatsApp/ChatBtn.js +1 -1
- package/dist/esm/components/template-preview/WhatsApp/ChatUI.js +1 -1
- package/dist/esm/components/template-preview/WhatsApp/ChatUiV2.js +1 -1
- package/dist/esm/components/template-preview/WhatsApp/MediaCard.js +1 -1
- package/dist/esm/components/template-preview/WhatsApp/RenderTemplateWithVariable.js +1 -1
- package/dist/esm/components/template-preview/WhatsAppTemplatePreview.js +1 -1
- package/dist/esm/components/template-preview/helpers/SmsTemplateHelper.js +1 -1
- package/dist/esm/components/template-preview/helpers/TemplateCreatorHelper.js +1 -1
- package/dist/esm/components/template-preview/helpers/VariableEditorHelper.js +1 -1
- package/dist/esm/components/template-preview/utils/TemplateHelperUtils.js +1 -1
- package/dist/esm/components/template-preview/utils/getPreviewPropLen.js +1 -1
- package/dist/esm/components/template-preview/webpush/WebpushPreview.js +1 -1
- package/dist/esm/components/text-picker/TextPickerCategoryCard.js +4 -4
- package/dist/esm/components/text-picker/TextPickerFooter.js +4 -4
- package/dist/esm/components/text-picker/TextPickerItemRow.js +6 -6
- package/dist/esm/components/text-picker/TextPickerModal.js +1 -1
- package/dist/esm/components/text-picker/TextPickerSelectAllRow.js +5 -5
- package/dist/esm/components/toaster/Toaster.js +1 -1
- package/dist/esm/components/unsatisfactory-response-list/UnsatisfactoryCountIntentWiseModal.js +1 -1
- package/dist/esm/components/unsatisfactory-response-list/UnsatisfactoryResponseList.js +1 -1
- package/dist/esm/components/variable-picker-v3/Content.js +1 -1
- package/dist/esm/components/variable-picker-v3/SubHeaderItems.js +1 -1
- package/dist/esm/components/variable-picker-v3/recommendVaribles.js +1 -1
- package/dist/esm/components/variable-picker-v3/searchVariables.js +1 -1
- package/dist/esm/components/whats-new/WhatsNew.js +1 -1
- package/dist/esm/components/whats-new/WhatsNewButton.js +1 -1
- package/dist/esm/components/whats-new/WhatsNewPanel.js +1 -1
- package/dist/esm/components/whats-new/WhatsNewProvider.js +1 -1
- package/dist/esm/components/whats-new/useWhatsNew.js +1 -1
- package/dist/esm/helpers/BaseWhatsappContentLang.helper.js +1 -1
- package/dist/esm/hooks/useCurreny.js +1 -1
- package/dist/esm/hooks/useOutside.js +1 -1
- package/dist/esm/node_modules/@reduxjs/toolkit/dist/redux-toolkit.modern.mjs.js +1 -1
- package/dist/esm/node_modules/immer/dist/immer.mjs.js +1 -1
- package/dist/esm/node_modules/lodash.debounce/index.js +1 -1
- package/dist/esm/src/components/banner/Banner.stories.d.ts +6 -9
- package/dist/esm/src/components/bik-layout/CommonStyles.d.ts +2 -2
- package/dist/esm/src/components/floating-action-button/FloatingActionButton.styles.d.ts +8 -8
- package/dist/esm/src/components/input/ChipInput.d.ts +0 -1
- package/dist/esm/src/components/input/ChipInput.styled.d.ts +14 -871
- package/dist/esm/src/components/progress-bar/ProgressBarComponent.d.ts +0 -1
- package/dist/esm/src/components/shimmer-image/ShimmerImage.stories.d.ts +5 -6
- package/dist/esm/src/components/tag/Tag.stories.d.ts +19 -34
- package/dist/esm/utils/DateUtils.js +1 -1
- package/dist/esm/utils/StringUtils.js +1 -1
- package/dist/esm/utils/resizeImage.js +1 -1
- package/dist/esm/utils/unCamelCase.js +1 -1
- package/package.json +24 -40
- package/dist/cjs/src/amplitude/Track.stories.d.ts +0 -6
- package/dist/esm/src/amplitude/Track.stories.d.ts +0 -6
- /package/dist/cjs/{src/amplitude → amplitude}/index.d.ts +0 -0
- /package/dist/esm/{src/amplitude → amplitude}/index.d.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),n=require("../zeroState/ZeroState.js"),r=require("../../constants/Theme.js"),o=require("../dropdown/OpenedDropdown/components/searchbox/SearchBox.js"),s=require("../floater/floater.js"),i=require("./MenuList.js"),l=require("./MultiLevelDropdown.styled.js");function u(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var d=u(t);exports.MultiLevelDropdown=
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("react"),n=require("../zeroState/ZeroState.js"),r=require("../../constants/Theme.js"),o=require("../dropdown/OpenedDropdown/components/searchbox/SearchBox.js"),s=require("../floater/floater.js"),i=require("./MenuList.js"),l=require("./MultiLevelDropdown.styled.js");function u(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var d=u(t);exports.MultiLevelDropdown=u=>{let{options:c,width:a,isSearchable:f,onDropdownItemClick:p,refElement:h,topOffset:j,leftOffset:w,isDropdownOpen:x,onDropdownOutsideClick:O}=u;const m=d.default.useRef(null),[b,g]=t.useState(c),v=e=>{const t=Array.isArray(c)?[...c]:[],n=[];for(;t.length>0;){const r=t.shift();r&&r.label.toLowerCase().includes(e.toLowerCase())&&n.push(r),r&&"children"in r&&r.children?t.push(...r.children):r&&"options"in r&&r.options&&t.push(...r.options)}const r=e=>e.map((e=>{if(n.includes(e))return e;if("children"in e&&e.children){const t=r(e.children);if(t.length>0)return Object.assign(Object.assign({},e),{children:t})}if("options"in e&&e.options){const t=r(e.options);if(t.length>0)return Object.assign(Object.assign({},e),{options:t})}return null})).filter((e=>null!==e));g(r(c))},y=e=>{m.current&&!m.current.contains(e.target)?O&&O(!0):O&&O(!1)};return t.useEffect((()=>{x&&v("")}),[x]),t.useEffect((()=>(document.addEventListener("mousedown",y),()=>{document.removeEventListener("mousedown",y)})),[]),t.useEffect((()=>{g(c)}),[c]),e.jsx(s.Floater,{refElement:h,topOffset:j,leftOffset:w,children:x&&e.jsx("div",{ref:m,style:{backgroundColor:r.COLORS.surface.standard,zIndex:99999,borderRadius:"8px",whiteSpace:"normal"},children:e.jsxs(l.DropdownContainer,{width:a,children:[f&&e.jsx("div",{style:{padding:"4px",width:null!=a?a:"200px"},children:e.jsx(o.SearchBox,{onSearch:v,version:"2.0"})}),e.jsx(l.OptionsContainer,{width:a,children:(null!=b?b:[]).length>0&&e.jsx(i.MenuList,{width:null!=a?a:"200px",onDropdownItemClick:p,options:b,parents:[]})}),0===(null!=b?b:[]).length&&e.jsx(l.NoResultsContainer,{style:{width:null!=a?a:"200px"},children:e.jsx(n.ZeroState,{title:"No results found!",subTitle:"Sorry, we are unable to find any results for your search."})})]})})})};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("styled-components"),t=require("../../constants/Theme.js");function i(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("styled-components"),t=require("../../constants/Theme.js");function i(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var r=i(e);const n=r.default.div`
|
|
2
2
|
position: relative;
|
|
3
3
|
border-radius: 8px;
|
|
4
4
|
box-shadow: 0px 2px 8px 0px rgba(0, 0, 0, 0.12);
|
|
5
5
|
padding-bottom: 4px;
|
|
6
|
-
`,o=
|
|
7
|
-
width: ${
|
|
6
|
+
`,o=r.default.div`
|
|
7
|
+
width: ${e=>{let{width:t}=e;return t||"200px"}};
|
|
8
8
|
max-width: 300px;
|
|
9
9
|
max-height: 280px;
|
|
10
10
|
overflow-y: scroll;
|
|
@@ -12,24 +12,24 @@
|
|
|
12
12
|
&::-webkit-scrollbar {
|
|
13
13
|
width: 0px;
|
|
14
14
|
}
|
|
15
|
-
`,d=
|
|
15
|
+
`,d=r.default.div`
|
|
16
16
|
margin-top: 64px;
|
|
17
17
|
height: 200px;
|
|
18
|
-
width: ${
|
|
19
|
-
`,a=
|
|
18
|
+
width: ${e=>{let{width:t}=e;return t||"200px"}};
|
|
19
|
+
`,a=r.default.div`
|
|
20
20
|
width: 100%;
|
|
21
21
|
justify-content: center;
|
|
22
22
|
cursor: pointer;
|
|
23
23
|
align-items: center;
|
|
24
24
|
justify-content: space-between;
|
|
25
25
|
margin: 4px 0;
|
|
26
|
-
`,p=
|
|
26
|
+
`,p=r.default.div`
|
|
27
27
|
z-index: 1000;
|
|
28
28
|
position: relative;
|
|
29
29
|
margin: 0px;
|
|
30
30
|
padding: 0px;
|
|
31
31
|
width: 100%;
|
|
32
|
-
`,s=
|
|
32
|
+
`,s=r.default.div`
|
|
33
33
|
position: relative;
|
|
34
34
|
padding: 1px 4px;
|
|
35
35
|
cursor: pointer;
|
|
@@ -38,31 +38,31 @@
|
|
|
38
38
|
&:focus-within > .submenu {
|
|
39
39
|
display: block;
|
|
40
40
|
}
|
|
41
|
-
`,l=
|
|
41
|
+
`,l=r.default.div`
|
|
42
42
|
position: relative;
|
|
43
43
|
padding: 4px 8px 4px 8px;
|
|
44
44
|
transition: background-color 0.2s;
|
|
45
45
|
width: 100%;
|
|
46
46
|
border-radius: 8px;
|
|
47
47
|
justify-content: center;
|
|
48
|
-
background-color: ${
|
|
49
|
-
color: ${
|
|
48
|
+
background-color: ${e=>{let{isSelected:i,isHovered:r,isSubMenuOpen:n,isDisabled:o}=e;return o?t.COLORS.surface.standard:i||n?t.COLORS.background.positive.light:r?t.COLORS.surface.hovered:t.COLORS.surface.standard}};
|
|
49
|
+
color: ${e=>{let{isSelected:i,isSubMenuOpen:r}=e;return i||r?t.COLORS.content.positive:t.COLORS.content.primary}};
|
|
50
50
|
display: flex;
|
|
51
51
|
align-items: center;
|
|
52
52
|
justify-content: space-between;
|
|
53
53
|
|
|
54
54
|
&:hover {
|
|
55
|
-
background-color: ${
|
|
55
|
+
background-color: ${e=>{let{isSelected:i,isDisabled:r}=e;return r?t.COLORS.surface.standard:i?t.COLORS.background.positive.light:t.COLORS.surface.hovered}};
|
|
56
56
|
}
|
|
57
|
-
`,
|
|
57
|
+
`,u=r.default.div`
|
|
58
58
|
display: flex;
|
|
59
59
|
align-items: center;
|
|
60
60
|
gap: 8px;
|
|
61
|
-
`,
|
|
61
|
+
`,x=r.default.div`
|
|
62
62
|
z-index: 1001;
|
|
63
63
|
position: fixed;
|
|
64
64
|
border-left: 4px solid transparent;
|
|
65
|
-
`,c=
|
|
65
|
+
`,c=r.default.div`
|
|
66
66
|
margin: 4px;
|
|
67
67
|
background-color: ${t.COLORS.surface.standard};
|
|
68
68
|
box-shadow: 0px 2px 8px 0px rgba(0, 0, 0, 0.12);
|
|
@@ -75,24 +75,24 @@
|
|
|
75
75
|
&::-webkit-scrollbar {
|
|
76
76
|
display: none;
|
|
77
77
|
}
|
|
78
|
-
`,f=
|
|
78
|
+
`,f=r.default.div`
|
|
79
79
|
width: 16px;
|
|
80
80
|
height: 16px;
|
|
81
81
|
display: flex;
|
|
82
82
|
align-items: center;
|
|
83
83
|
justify-content: center;
|
|
84
84
|
margin-right: 4px;
|
|
85
|
-
`,g=
|
|
85
|
+
`,g=r.default.div`
|
|
86
86
|
width: 16px;
|
|
87
87
|
height: 16px;
|
|
88
88
|
display: flex;
|
|
89
89
|
align-items: center;
|
|
90
90
|
justify-content: center;
|
|
91
91
|
margin-left: 4px;
|
|
92
|
-
`,h=
|
|
92
|
+
`,h=r.default.div`
|
|
93
93
|
width: ${e=>e.width};
|
|
94
|
-
`,b=
|
|
94
|
+
`,b=r.default(x)`
|
|
95
95
|
width: ${e=>e.width};
|
|
96
96
|
top: ${e=>e.top}px;
|
|
97
97
|
left: ${e=>e.left}px;
|
|
98
|
-
`;exports.ContentContainer=
|
|
98
|
+
`;exports.ContentContainer=u,exports.DropdownContainer=n,exports.GroupedMenuListContainer=a,exports.LeadingIconContainer=f,exports.MenuItemContainer=l,exports.MenuItemWrapper=s,exports.NoResultsContainer=d,exports.OptionsContainer=o,exports.StyledMenuList=p,exports.StyledSubMenuWrapper=b,exports.SubMenuContainer=h,exports.SubMenuListContainer=c,exports.SubMenuWrapper=x,exports.TrailingIconContainer=g;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../_virtual/_tslib.js"),r=require("react/jsx-runtime"),o=require("react"),n=require("../TypographyStyle.js"),t=require("../../constants/Theme.js"),i=require("./Pagination.styled.js");const s=o.forwardRef(o=>{var{id:s,onShowMore:a,isLoading:d,numberOfItemsLoaded:l,totalNumberOfItems:c}=o,u=e.__rest(o,["id","onShowMore","isLoading","numberOfItemsLoaded","totalNumberOfItems"]);return r.jsx(i.Pagination,Object.assign({id:s},u,{children:d?r.jsx(r.Fragment,{children:"loading..."}):r.jsx("div",{children:l<c?r.jsxs(i.Pagination,{children:[r.jsxs(n.BodySecondary,{style:{color:t.COLORS.content.secondary},children:["Showing ",l," out of ",c," ","results"]}),r.jsx(n.ButtonRegular,{style:{color:t.COLORS.content.brand,cursor:"pointer"},onClick:()=>a&&a(),children:"Show more"})]}):r.jsx(i.Pagination,{children:r.jsxs(n.BodySecondary,{style:{color:t.COLORS.content.secondary},children:["Showing all ",c," results"]})})})}))});s.displayName="Pagination",exports.Pagination=s;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../_virtual/_tslib.js"),r=require("react/jsx-runtime"),o=require("react"),n=require("../TypographyStyle.js"),t=require("../../constants/Theme.js"),i=require("./Pagination.styled.js");const s=o.forwardRef((o=>{var{id:s,onShowMore:a,isLoading:d,numberOfItemsLoaded:l,totalNumberOfItems:c}=o,u=e.__rest(o,["id","onShowMore","isLoading","numberOfItemsLoaded","totalNumberOfItems"]);return r.jsx(i.Pagination,Object.assign({id:s},u,{children:d?r.jsx(r.Fragment,{children:"loading..."}):r.jsx("div",{children:l<c?r.jsxs(i.Pagination,{children:[r.jsxs(n.BodySecondary,{style:{color:t.COLORS.content.secondary},children:["Showing ",l," out of ",c," ","results"]}),r.jsx(n.ButtonRegular,{style:{color:t.COLORS.content.brand,cursor:"pointer"},onClick:()=>a&&a(),children:"Show more"})]}):r.jsx(i.Pagination,{children:r.jsxs(n.BodySecondary,{style:{color:t.COLORS.content.secondary},children:["Showing all ",c," results"]})})})}))}));s.displayName="Pagination",exports.Pagination=s;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/check.svg.js"),s=require("../../assets/icons/checkCircle.svg.js"),i=require("../../assets/icons/quotes.svg.js"),a=require("../../assets/icons/WhiteStarFilled.svg.js"),n=require("../button/Button.js"),o=require("./SubscriptionPlanStyled.js"),r=require("../TypographyStyle.js"),l=require("../../hooks/useCurreny.js"),c=require("../../constants/Theme.js"),d=require("../tag/Tag.js"),h=require("../tooltips/Tooltip.js");exports.NewSubscriptionPlan=u=>{var p;const{formatCurrency:m}=l.useCurrency(),x=u.showMonthlyOptions?u.features:u.annualFeatures||[],y=u.showMonthlyOptions?u.monthlyPlan:u.yearlyPlan,j=!u.isDisabled&&u.isMostPopular,g=u.showMonthlyOptions?u.code:null!==(p=u.yearlyCode)&&void 0!==p?p:u.code,{planName:b,isSelected:C=!1,isDisabled:v=!1,onPlanSelect:T,oldPrice:S,hideMonthYearTag:O,planDescription:N,planDescriptionDiscount:f,showTrialOptions:L,freeTrialMessages:P,extraBlockMessage:k,isLoading:w,buttonText:M,bottomDescription:B,showMonthlyOptions:q,popularTestimony:R,skipRadioSelection:D=!1,includeText:F,height:$,showFeaturesButton:_,businessDescription:z,isPlanSelected:H=!1,onClickShowAllFeatures:W,showSelectedPlanChip:I=!1,perMonthForYearly:U=!1,minHeightOfFeatures:Y,hoverTooltip:A,hidePriceBlock:E=!1}=u,G=e=>U&&!q?0==e?"$0":m(Math.round(e/12),"USD"):0==e?"$0":m(e,"USD");return e.jsx(h.Tooltip,{body:A,children:e.jsxs(o.NewSubscriptionStyled,{height:$,showMostPopularChip:j||!1,onClick:()=>T(g),children:[j&&e.jsxs("div",{className:"most-popular-chip",children:[e.jsx(r.Caption,{className:"popular-text",children:"Most popular "}),e.jsx(a.default,{height:12,width:12})]}),e.jsxs("div",{className:`box ${v?"disabled":""} \n\t\t\t\t`,children:[e.jsxs("div",{className:"radio-flex",children:[!D&&e.jsx("input",{type:"radio",id:"html",name:"fav_language",value:"HTML",disabled:null!=v&&v,onChange:()=>T(g),className:"radio-button",checked:H}),e.jsx(r.TitleRegular,{style:{color:c.COLORS.content.secondary,marginBottom:4},children:b}),I&&e.jsx("div",{style:{marginLeft:"auto"},children:e.jsx(d.Tag,{tagText:"Current plan",type:"positive",theme:"dark"})})]}),E?e.jsx(e.Fragment,{}):e.jsxs("div",{className:"price-block",children:[S?e.jsx(r.BodyCaption,{className:"old--price",children:G(y.price)}):e.jsx(e.Fragment,{}),e.jsx(r.TitleLarge,{style:{color:c.COLORS.content.primary},children:G(S||y.price)}),e.jsx(r.Caption,{style:{color:c.COLORS.content.secondary,marginLeft:4},children:O?"":"/ "+(q?"month":U?"month billed annually":"year")})]}),N&&e.jsxs("div",{className:"per-message-price",children:[e.jsx(r.BodyCaption,{style:{color:c.COLORS.content.secondary},children:N}),f&&e.jsx(r.BodyCaption,{style:{color:c.COLORS.background.positive.vibrant,marginLeft:4},children:f})]}),z&&z.length&&e.jsx("div",{style:{marginTop:4},children:z.map((t,s)=>e.jsx(r.BodyCaption,{style:{color:c.COLORS.content.secondary},dangerouslySetInnerHTML:{__html:t}},s))}),L&&e.jsxs(r.Caption,{className:"trial "+(C?"selected":""),children:["7 day free trial with ",P," messages"]}),k&&e.jsx(r.Caption,{className:"trial "+(C?"selected":""),children:k}),e.jsx(r.TitleSmall,{className:"extra-include-margin",style:{height:F?"":"20px"},children:F||""}),e.jsx("div",{className:"features",style:{minHeight:Y},children:x.map((t,i)=>e.jsxs("div",{className:"feature",children:[e.jsx("div",{children:e.jsx(s.default,{height:20,width:20,color:c.COLORS.content.primary})}),e.jsx(r.BodyCaption,{className:"feature-text",children:t.detail},i)]},t.detail))}),_&&e.jsx(n.Button,{isLoading:!1,buttonType:"tertiary",buttonText:"See all features",size:"small",onClick:e=>{e.stopPropagation(),W&&W()}}),D&&e.jsx("div",{className:"button-box",children:w?e.jsx(n.Button,{isLoading:!0,buttonType:"primary",buttonText:"Choose plan",size:"medium",matchParentWidth:!0}):e.jsxs(e.Fragment,{children:[C&&e.jsx(n.Button,{disabled:v,LeadingIcon:t.default,buttonType:"tertiary",size:"medium",matchParentWidth:!0,buttonText:M||"Selected Plan"}),!C&&!v&&e.jsx(n.Button,{buttonType:"primary",size:"medium",onClick:e=>{e.stopPropagation(),T(g)},matchParentWidth:!0,buttonText:M||"Choose plan"})]})}),R&&e.jsxs("div",{className:"popular-testimony",children:[e.jsx(i.default,{height:26,width:70}),e.jsx("div",{className:"testimony-text",children:e.jsx("i",{children:R})})]})]}),B&&e.jsx("div",{className:`plan-bottom-information\n\t\t\t\t\t${v?"disabled":""}\n\t\t\t\t\t${C?"selected":""}\n\t\t\t\t`,children:e.jsx(r.Caption,{className:"text",style:{color:c.COLORS.background.inverse},children:B})})]})})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/check.svg.js"),s=require("../../assets/icons/checkCircle.svg.js"),i=require("../../assets/icons/quotes.svg.js"),a=require("../../assets/icons/WhiteStarFilled.svg.js"),n=require("../button/Button.js"),o=require("./SubscriptionPlanStyled.js"),r=require("../TypographyStyle.js"),l=require("../../hooks/useCurreny.js"),c=require("../../constants/Theme.js"),d=require("../tag/Tag.js"),h=require("../tooltips/Tooltip.js");exports.NewSubscriptionPlan=u=>{var p;const{formatCurrency:m}=l.useCurrency(),x=u.showMonthlyOptions?u.features:u.annualFeatures||[],y=u.showMonthlyOptions?u.monthlyPlan:u.yearlyPlan,j=!u.isDisabled&&u.isMostPopular,g=u.showMonthlyOptions?u.code:null!==(p=u.yearlyCode)&&void 0!==p?p:u.code,{planName:b,isSelected:C=!1,isDisabled:v=!1,onPlanSelect:T,oldPrice:S,hideMonthYearTag:O,planDescription:N,planDescriptionDiscount:f,showTrialOptions:L,freeTrialMessages:P,extraBlockMessage:k,isLoading:w,buttonText:M,bottomDescription:B,showMonthlyOptions:q,popularTestimony:R,skipRadioSelection:D=!1,includeText:F,height:$,showFeaturesButton:_,businessDescription:z,isPlanSelected:H=!1,onClickShowAllFeatures:W,showSelectedPlanChip:I=!1,perMonthForYearly:U=!1,minHeightOfFeatures:Y,hoverTooltip:A,hidePriceBlock:E=!1}=u,G=e=>U&&!q?0==e?"$0":m(Math.round(e/12),"USD"):0==e?"$0":m(e,"USD");return e.jsx(h.Tooltip,{body:A,children:e.jsxs(o.NewSubscriptionStyled,{height:$,showMostPopularChip:j||!1,onClick:()=>T(g),children:[j&&e.jsxs("div",{className:"most-popular-chip",children:[e.jsx(r.Caption,{className:"popular-text",children:"Most popular "}),e.jsx(a.default,{height:12,width:12})]}),e.jsxs("div",{className:`box ${v?"disabled":""} \n\t\t\t\t`,children:[e.jsxs("div",{className:"radio-flex",children:[!D&&e.jsx("input",{type:"radio",id:"html",name:"fav_language",value:"HTML",disabled:null!=v&&v,onChange:()=>T(g),className:"radio-button",checked:H}),e.jsx(r.TitleRegular,{style:{color:c.COLORS.content.secondary,marginBottom:4},children:b}),I&&e.jsx("div",{style:{marginLeft:"auto"},children:e.jsx(d.Tag,{tagText:"Current plan",type:"positive",theme:"dark"})})]}),E?e.jsx(e.Fragment,{}):e.jsxs("div",{className:"price-block",children:[S?e.jsx(r.BodyCaption,{className:"old--price",children:G(y.price)}):e.jsx(e.Fragment,{}),e.jsx(r.TitleLarge,{style:{color:c.COLORS.content.primary},children:G(S||y.price)}),e.jsx(r.Caption,{style:{color:c.COLORS.content.secondary,marginLeft:4},children:O?"":"/ "+(q?"month":U?"month billed annually":"year")})]}),N&&e.jsxs("div",{className:"per-message-price",children:[e.jsx(r.BodyCaption,{style:{color:c.COLORS.content.secondary},children:N}),f&&e.jsx(r.BodyCaption,{style:{color:c.COLORS.background.positive.vibrant,marginLeft:4},children:f})]}),z&&z.length&&e.jsx("div",{style:{marginTop:4},children:z.map(((t,s)=>e.jsx(r.BodyCaption,{style:{color:c.COLORS.content.secondary},dangerouslySetInnerHTML:{__html:t}},s)))}),L&&e.jsxs(r.Caption,{className:"trial "+(C?"selected":""),children:["7 day free trial with ",P," messages"]}),k&&e.jsx(r.Caption,{className:"trial "+(C?"selected":""),children:k}),e.jsx(r.TitleSmall,{className:"extra-include-margin",style:{height:F?"":"20px"},children:F||""}),e.jsx("div",{className:"features",style:{minHeight:Y},children:x.map(((t,i)=>e.jsxs("div",{className:"feature",children:[e.jsx("div",{children:e.jsx(s.default,{height:20,width:20,color:c.COLORS.content.primary})}),e.jsx(r.BodyCaption,{className:"feature-text",children:t.detail},i)]},t.detail)))}),_&&e.jsx(n.Button,{isLoading:!1,buttonType:"tertiary",buttonText:"See all features",size:"small",onClick:e=>{e.stopPropagation(),W&&W()}}),D&&e.jsx("div",{className:"button-box",children:w?e.jsx(n.Button,{isLoading:!0,buttonType:"primary",buttonText:"Choose plan",size:"medium",matchParentWidth:!0}):e.jsxs(e.Fragment,{children:[C&&e.jsx(n.Button,{disabled:v,LeadingIcon:t.default,buttonType:"tertiary",size:"medium",matchParentWidth:!0,buttonText:M||"Selected Plan"}),!C&&!v&&e.jsx(n.Button,{buttonType:"primary",size:"medium",onClick:e=>{e.stopPropagation(),T(g)},matchParentWidth:!0,buttonText:M||"Choose plan"})]})}),R&&e.jsxs("div",{className:"popular-testimony",children:[e.jsx(i.default,{height:26,width:70}),e.jsx("div",{className:"testimony-text",children:e.jsx("i",{children:R})})]})]}),B&&e.jsx("div",{className:`plan-bottom-information\n\t\t\t\t\t${v?"disabled":""}\n\t\t\t\t\t${C?"selected":""}\n\t\t\t\t`,children:e.jsx(r.Caption,{className:"text",style:{color:c.COLORS.background.inverse},children:B})})]})})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/check.svg.js"),s=require("../button/Button.js"),i=require("./SubscriptionPlanStyled.js"),n=require("../TypographyStyle.js"),r=require("../../hooks/useCurreny.js"),a=require("../../constants/Theme.js");exports.SubscriptionPlan=o=>{const{formatCurrency:l}=r.useCurrency(),c=o.showMonthlyOptions?o.features:o.annualFeatures||[],d=o.showMonthlyOptions?o.monthlyPlan:o.yearlyPlan,u=!o.isDisabled&&o.isMostPopular,p=e=>0==e?"$0":l(e,"USD");return e.jsxs(i.SubscriptionPlanStyled,{isManifestPlan:!0,isSelected:o.isSelected||!1,style:{marginTop:u?0:24},children:[u&&e.jsx("div",{className:"most-popular",children:e.jsx(n.Caption,{className:"text",children:"Most popular ⭐️"})}),e.jsxs("div",{className:`box ${o.isSelected?"selected":""} ${o.isDisabled?"disabled":""} ${u?"":"rounded-corners"}\n\t\t\t\t`,children:[e.jsxs("div",{children:[e.jsx(n.TitleRegular,{style:{color:a.COLORS.content.secondary,marginBottom:4},children:o.planName}),(null==o?void 0:o.hidePriceBlock)?e.jsx(e.Fragment,{}):e.jsxs("div",{className:"price-block",children:[o.oldPrice?e.jsx(n.BodyCaption,{className:"old--price",children:p(d.price)}):e.jsx(e.Fragment,{}),e.jsx(n.TitleMedium,{style:{color:a.COLORS.content.primary},children:o.oldPrice?p(o.oldPrice):p(d.price)}),e.jsx(n.BodyPrimary,{style:{color:a.COLORS.content.secondary,marginLeft:4},children:o.hideMonthYearTag?"":"/ "+(o.showMonthlyOptions?"month":"year")})]}),e.jsxs("div",{className:"per-message-price",children:[o.planDescription&&e.jsx(n.BodyCaption,{style:{color:a.COLORS.content.secondary},children:o.planDescription}),o.planDescriptionDiscount&&e.jsx(n.BodyCaption,{style:{color:a.COLORS.background.positive.vibrant,marginLeft:4},children:o.planDescriptionDiscount})]}),o.showTrialOptions&&e.jsxs(n.Caption,{className:"trial "+(o.isSelected?"selected":""),children:["7 day free trial with ",o.freeTrialMessages," messages"]}),o.extraBlockMessage&&e.jsx(n.Caption,{className:"trial "+(o.isSelected?"selected":""),children:o.extraBlockMessage}),e.jsx("div",{className:"features",children:c.map((s,i)=>e.jsxs("div",{className:"feature",children:[e.jsx("div",{children:e.jsx(t.default,{height:12,width:12,color:a.COLORS.content.primary})}),e.jsx(n.BodyCaption,{className:"feature-text",children:s.detail},i)]},s.detail))})]}),e.jsx("div",{className:"button-box",children:o.isLoading?e.jsx(s.Button,{isLoading:!0,buttonType:"primary",buttonText:"Choose plan",size:"medium",matchParentWidth:!0}):e.jsxs(e.Fragment,{children:[o.isSelected&&e.jsx(s.Button,{disabled:o.isDisabled,LeadingIcon:t.default,buttonType:"tertiary",size:"medium",matchParentWidth:!0,buttonText:o.buttonText||"Selected Plan"}),!o.isSelected&&!o.isDisabled&&e.jsx(s.Button,{buttonType:"primary",size:"medium",onClick:()=>o.onPlanSelect(o.code),matchParentWidth:!0,buttonText:o.buttonText||"Choose plan"})]})})]}),o.bottomDescription&&e.jsx("div",{className:`plan-bottom-information\n\t\t\t\t\t${o.isDisabled?"disabled":""}\n\t\t\t\t\t${o.isSelected?"selected":""}\n\t\t\t\t`,children:e.jsx(n.Caption,{className:"text",style:{color:a.COLORS.background.inverse},children:o.bottomDescription})})]})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/check.svg.js"),s=require("../button/Button.js"),i=require("./SubscriptionPlanStyled.js"),n=require("../TypographyStyle.js"),r=require("../../hooks/useCurreny.js"),a=require("../../constants/Theme.js");exports.SubscriptionPlan=o=>{const{formatCurrency:l}=r.useCurrency(),c=o.showMonthlyOptions?o.features:o.annualFeatures||[],d=o.showMonthlyOptions?o.monthlyPlan:o.yearlyPlan,u=!o.isDisabled&&o.isMostPopular,p=e=>0==e?"$0":l(e,"USD");return e.jsxs(i.SubscriptionPlanStyled,{isManifestPlan:!0,isSelected:o.isSelected||!1,style:{marginTop:u?0:24},children:[u&&e.jsx("div",{className:"most-popular",children:e.jsx(n.Caption,{className:"text",children:"Most popular ⭐️"})}),e.jsxs("div",{className:`box ${o.isSelected?"selected":""} ${o.isDisabled?"disabled":""} ${u?"":"rounded-corners"}\n\t\t\t\t`,children:[e.jsxs("div",{children:[e.jsx(n.TitleRegular,{style:{color:a.COLORS.content.secondary,marginBottom:4},children:o.planName}),(null==o?void 0:o.hidePriceBlock)?e.jsx(e.Fragment,{}):e.jsxs("div",{className:"price-block",children:[o.oldPrice?e.jsx(n.BodyCaption,{className:"old--price",children:p(d.price)}):e.jsx(e.Fragment,{}),e.jsx(n.TitleMedium,{style:{color:a.COLORS.content.primary},children:o.oldPrice?p(o.oldPrice):p(d.price)}),e.jsx(n.BodyPrimary,{style:{color:a.COLORS.content.secondary,marginLeft:4},children:o.hideMonthYearTag?"":"/ "+(o.showMonthlyOptions?"month":"year")})]}),e.jsxs("div",{className:"per-message-price",children:[o.planDescription&&e.jsx(n.BodyCaption,{style:{color:a.COLORS.content.secondary},children:o.planDescription}),o.planDescriptionDiscount&&e.jsx(n.BodyCaption,{style:{color:a.COLORS.background.positive.vibrant,marginLeft:4},children:o.planDescriptionDiscount})]}),o.showTrialOptions&&e.jsxs(n.Caption,{className:"trial "+(o.isSelected?"selected":""),children:["7 day free trial with ",o.freeTrialMessages," messages"]}),o.extraBlockMessage&&e.jsx(n.Caption,{className:"trial "+(o.isSelected?"selected":""),children:o.extraBlockMessage}),e.jsx("div",{className:"features",children:c.map(((s,i)=>e.jsxs("div",{className:"feature",children:[e.jsx("div",{children:e.jsx(t.default,{height:12,width:12,color:a.COLORS.content.primary})}),e.jsx(n.BodyCaption,{className:"feature-text",children:s.detail},i)]},s.detail)))})]}),e.jsx("div",{className:"button-box",children:o.isLoading?e.jsx(s.Button,{isLoading:!0,buttonType:"primary",buttonText:"Choose plan",size:"medium",matchParentWidth:!0}):e.jsxs(e.Fragment,{children:[o.isSelected&&e.jsx(s.Button,{disabled:o.isDisabled,LeadingIcon:t.default,buttonType:"tertiary",size:"medium",matchParentWidth:!0,buttonText:o.buttonText||"Selected Plan"}),!o.isSelected&&!o.isDisabled&&e.jsx(s.Button,{buttonType:"primary",size:"medium",onClick:()=>o.onPlanSelect(o.code),matchParentWidth:!0,buttonText:o.buttonText||"Choose plan"})]})})]}),o.bottomDescription&&e.jsx("div",{className:`plan-bottom-information\n\t\t\t\t\t${o.isDisabled?"disabled":""}\n\t\t\t\t\t${o.isSelected?"selected":""}\n\t\t\t\t`,children:e.jsx(n.Caption,{className:"text",style:{color:a.COLORS.background.inverse},children:o.bottomDescription})})]})};
|
|
@@ -98,4 +98,4 @@
|
|
|
98
98
|
justify-content: flex-start;
|
|
99
99
|
gap: 8px;
|
|
100
100
|
}
|
|
101
|
-
`,b=[{key:"Monthly",title:"Monthly"},{key:"yearly",title:"Yearly"}];exports.BottomWrapper=m,exports.HeaderWrapper=g,exports.SubscriptionPlanSelector=s=>{var u,x,y,j,f,C,O,w,P,S,k,L,T,I;const[M,N]=e.useState(null===(u=s.discountInputProperties)||void 0===u?void 0:u.defaultValue),R=s.staticWidthMultiplier?s.staticWidthMultiplier:275;return o.jsxs(r.StyledModal,{centralContainerStyles:{width:s.plans.length*R},open:!0,closeOnOutsideClick:!0,onClose:s.onClose,children:[o.jsxs(g,{children:[o.jsxs("div",{children:[o.jsx(c.TitleMedium,{children:s.header||"Select a plan to proceed"}),o.jsx(c.BodyPrimary,{className:"sub--header",children:s.subHeader||""})]}),s.showMonthlyTabs?o.jsx(p.Tabs,{tabs:s.tabProperties&&s.tabProperties.tabs?s.tabProperties.tabs:b,onTabSelected:e=>{var o,t;return(null===(o=s.tabProperties)||void 0===o?void 0:o.onTabSelected)?null===(t=s.tabProperties)||void 0===t?void 0:t.onTabSelected(e):""},isSquared:!0}):o.jsx(o.Fragment,{})]}),s.warningDescription&&o.jsx(h,{children:s.warningDescription}),o.jsx(v,{children:s.plans.map(o=>e.createElement(d.SubscriptionPlan,Object.assign({},o,{showMonthly:!0,showMonthlyOptions:s.showMonthlyOptions||!1,showTrialOptions:s.showTrialOptions||!1,onPlanSelect:s.onPlanSelect,key:o.planName})))}),(s.showCouponApplicationCode||s.showBookAdemo)&&o.jsxs(m,{children:[o.jsx("div",{children:s.showCouponApplicationCode&&o.jsxs("div",{className:"coupon-code",children:[o.jsxs("div",{className:"coupon-input",children:[o.jsx(c.BodyPrimary,{style:{color:(null===(x=s.discountInputProperties)||void 0===x?void 0:x.errorMessage)?a.COLORS.content.negative:""},children:"Apply coupon code"}),o.jsxs("div",{className:"button--wrapper",children:[o.jsxs("div",{className:(null===(y=s.discountInputProperties)||void 0===y?void 0:y.errorMessage)?"error--border dotted--border":"dotted--border",children:[o.jsx("input",{className:"input--class",onChange:e=>{var o;N(e.target.value),null===(o=s.discountInputProperties)||void 0===o||o.onChangeText(e.target.value)},value:M,placeholder:"eg:PLAN20",disabled:null===(j=s.discountInputProperties)||void 0===j?void 0:j.isLoading}),(null===(f=s.discountInputProperties)||void 0===f?void 0:f.successText)&&o.jsxs("div",{className:"success--inside--chip",children:[o.jsx(t.default,{height:16,width:16,color:a.COLORS.content.primaryInverse}),o.jsx(c.BodyCaption,{style:{color:a.COLORS.content.primaryInverse},children:"Coupon applied"})]})]}),!(null===(C=s.discountInputProperties)||void 0===C?void 0:C.successText)&&o.jsx(l.Button,{buttonText:"Apply",buttonType:"primary",onClick:null===(O=null==s?void 0:s.discountInputProperties)||void 0===O?void 0:O.onCouponApply,isLoading:null===(w=s.discountInputProperties)||void 0===w?void 0:w.isLoading})]}),(null===(P=s.discountInputProperties)||void 0===P?void 0:P.errorMessage)&&o.jsxs("div",{className:"d-flex",style:{gap:8},children:[o.jsx(n.default,{height:16,width:16,color:a.COLORS.content.negative}),o.jsx(c.BodyCaption,{style:{color:a.COLORS.content.negative},children:null!==(k=null===(S=s.discountInputProperties)||void 0===S?void 0:S.errorMessage)&&void 0!==k?k:"Enter a valid code"})]}),(null===(L=s.discountInputProperties)||void 0===L?void 0:L.showRemoveCoupon)&&o.jsx("div",{className:"demo--input",onClick:()=>{var e,o;N(""),(null===(e=s.discountInputProperties)||void 0===e?void 0:e.removeCoupon)&&(null===(o=s.discountInputProperties)||void 0===o||o.removeCoupon())},children:"Remove coupon"})]}),(null===(T=s.discountInputProperties)||void 0===T?void 0:T.successText)&&o.jsx("div",{className:"coupon--success--chip",children:o.jsx(c.BodyCaption,{style:{color:"#00580E",maxWidth:180},children:null===(I=s.discountInputProperties)||void 0===I?void 0:I.successText})})]})}),s.showBookAdemo&&o.jsxs("div",{className:"demo--wrapper",children:[o.jsx("div",{className:"demo--phone",children:o.jsx(i.default,{height:16,width:16,color:a.COLORS.background.brand})}),o.jsx(c.BodyPrimary,{className:"demo--input",onClick:()=>s.demoLink?window.open(s.demoLink,"_blank"):s.onClickingBookADemo?s.onClickingBookADemo():"",children:"Book a demo with the team"})]})]})]})},exports.defaultTabs=b;
|
|
101
|
+
`,b=[{key:"Monthly",title:"Monthly"},{key:"yearly",title:"Yearly"}];exports.BottomWrapper=m,exports.HeaderWrapper=g,exports.SubscriptionPlanSelector=s=>{var u,x,y,j,f,C,O,w,P,S,k,L,T,I;const[M,N]=e.useState(null===(u=s.discountInputProperties)||void 0===u?void 0:u.defaultValue),R=s.staticWidthMultiplier?s.staticWidthMultiplier:275;return o.jsxs(r.StyledModal,{centralContainerStyles:{width:s.plans.length*R},open:!0,closeOnOutsideClick:!0,onClose:s.onClose,children:[o.jsxs(g,{children:[o.jsxs("div",{children:[o.jsx(c.TitleMedium,{children:s.header||"Select a plan to proceed"}),o.jsx(c.BodyPrimary,{className:"sub--header",children:s.subHeader||""})]}),s.showMonthlyTabs?o.jsx(p.Tabs,{tabs:s.tabProperties&&s.tabProperties.tabs?s.tabProperties.tabs:b,onTabSelected:e=>{var o,t;return(null===(o=s.tabProperties)||void 0===o?void 0:o.onTabSelected)?null===(t=s.tabProperties)||void 0===t?void 0:t.onTabSelected(e):""},isSquared:!0}):o.jsx(o.Fragment,{})]}),s.warningDescription&&o.jsx(h,{children:s.warningDescription}),o.jsx(v,{children:s.plans.map((o=>e.createElement(d.SubscriptionPlan,Object.assign({},o,{showMonthly:!0,showMonthlyOptions:s.showMonthlyOptions||!1,showTrialOptions:s.showTrialOptions||!1,onPlanSelect:s.onPlanSelect,key:o.planName}))))}),(s.showCouponApplicationCode||s.showBookAdemo)&&o.jsxs(m,{children:[o.jsx("div",{children:s.showCouponApplicationCode&&o.jsxs("div",{className:"coupon-code",children:[o.jsxs("div",{className:"coupon-input",children:[o.jsx(c.BodyPrimary,{style:{color:(null===(x=s.discountInputProperties)||void 0===x?void 0:x.errorMessage)?a.COLORS.content.negative:""},children:"Apply coupon code"}),o.jsxs("div",{className:"button--wrapper",children:[o.jsxs("div",{className:(null===(y=s.discountInputProperties)||void 0===y?void 0:y.errorMessage)?"error--border dotted--border":"dotted--border",children:[o.jsx("input",{className:"input--class",onChange:e=>{var o;N(e.target.value),null===(o=s.discountInputProperties)||void 0===o||o.onChangeText(e.target.value)},value:M,placeholder:"eg:PLAN20",disabled:null===(j=s.discountInputProperties)||void 0===j?void 0:j.isLoading}),(null===(f=s.discountInputProperties)||void 0===f?void 0:f.successText)&&o.jsxs("div",{className:"success--inside--chip",children:[o.jsx(t.default,{height:16,width:16,color:a.COLORS.content.primaryInverse}),o.jsx(c.BodyCaption,{style:{color:a.COLORS.content.primaryInverse},children:"Coupon applied"})]})]}),!(null===(C=s.discountInputProperties)||void 0===C?void 0:C.successText)&&o.jsx(l.Button,{buttonText:"Apply",buttonType:"primary",onClick:null===(O=null==s?void 0:s.discountInputProperties)||void 0===O?void 0:O.onCouponApply,isLoading:null===(w=s.discountInputProperties)||void 0===w?void 0:w.isLoading})]}),(null===(P=s.discountInputProperties)||void 0===P?void 0:P.errorMessage)&&o.jsxs("div",{className:"d-flex",style:{gap:8},children:[o.jsx(n.default,{height:16,width:16,color:a.COLORS.content.negative}),o.jsx(c.BodyCaption,{style:{color:a.COLORS.content.negative},children:null!==(k=null===(S=s.discountInputProperties)||void 0===S?void 0:S.errorMessage)&&void 0!==k?k:"Enter a valid code"})]}),(null===(L=s.discountInputProperties)||void 0===L?void 0:L.showRemoveCoupon)&&o.jsx("div",{className:"demo--input",onClick:()=>{var e,o;N(""),(null===(e=s.discountInputProperties)||void 0===e?void 0:e.removeCoupon)&&(null===(o=s.discountInputProperties)||void 0===o||o.removeCoupon())},children:"Remove coupon"})]}),(null===(T=s.discountInputProperties)||void 0===T?void 0:T.successText)&&o.jsx("div",{className:"coupon--success--chip",children:o.jsx(c.BodyCaption,{style:{color:"#00580E",maxWidth:180},children:null===(I=s.discountInputProperties)||void 0===I?void 0:I.successText})})]})}),s.showBookAdemo&&o.jsxs("div",{className:"demo--wrapper",children:[o.jsx("div",{className:"demo--phone",children:o.jsx(i.default,{height:16,width:16,color:a.COLORS.background.brand})}),o.jsx(c.BodyPrimary,{className:"demo--input",onClick:()=>s.demoLink?window.open(s.demoLink,"_blank"):s.onClickingBookADemo?s.onClickingBookADemo():"",children:"Book a demo with the team"})]})]})]})},exports.defaultTabs=b;
|
|
@@ -16,4 +16,4 @@
|
|
|
16
16
|
&::-webkit-scrollbar-thumb:horizontal {
|
|
17
17
|
width: 8px;
|
|
18
18
|
}
|
|
19
|
-
`;exports.SubscriptionPlansCollected=l=>{var r;const[a,o]=t.useState(null!==(r=l.selectedPlan)&&void 0!==r?r:"");return e.jsx(n,{style:{padding:"28px 0px 5px 0px"},maxWidth:l.maxWidth,children:l.plans.map((r,n)=>{var s,d,c;return e.jsx("div",{style:{minWidth:null!==(s=l.staticWidth)&&void 0!==s?s:280,maxWidth:null!==(d=l.staticWidth)&&void 0!==d?d:280},children:t.createElement(i.NewSubscriptionPlan,Object.assign({},r,{showMonthly:!0,showMonthlyOptions:null!==(c="monthly"==l.selectedTab)&&void 0!==c&&c,showTrialOptions:l.showTrialOptions||!1,onPlanSelect:e=>{l.onPlanSelect(e),o(e)},key:r.planName,isPlanSelected:a==("monthly"==l.selectedTab?r.code:r.yearlyCode),onClickShowAllFeatures:l.onClickShowAllFeatures,showSelectedPlanChip:l.currentPlan==("monthly"==l.selectedTab?r.code:r.yearlyCode),minHeightOfFeatures:l.minHeightOfFeatures}))},n)})})};
|
|
19
|
+
`;exports.SubscriptionPlansCollected=l=>{var r;const[a,o]=t.useState(null!==(r=l.selectedPlan)&&void 0!==r?r:"");return e.jsx(n,{style:{padding:"28px 0px 5px 0px"},maxWidth:l.maxWidth,children:l.plans.map(((r,n)=>{var s,d,c;return e.jsx("div",{style:{minWidth:null!==(s=l.staticWidth)&&void 0!==s?s:280,maxWidth:null!==(d=l.staticWidth)&&void 0!==d?d:280},children:t.createElement(i.NewSubscriptionPlan,Object.assign({},r,{showMonthly:!0,showMonthlyOptions:null!==(c="monthly"==l.selectedTab)&&void 0!==c&&c,showTrialOptions:l.showTrialOptions||!1,onPlanSelect:e=>{l.onPlanSelect(e),o(e)},key:r.planName,isPlanSelected:a==("monthly"==l.selectedTab?r.code:r.yearlyCode),onClickShowAllFeatures:l.onClickShowAllFeatures,showSelectedPlanChip:l.currentPlan==("monthly"==l.selectedTab?r.code:r.yearlyCode),minHeightOfFeatures:l.minHeightOfFeatures}))},n)}))})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/searchIcon.js"),a=require("react"),r=require("./PostPicker.styled.js"),s=require("../tag/Tag.js"),i=require("../TypographyStyle.js"),n=require("../../utils/unCamelCase.js"),o=require("../../constants/colors.js"),l=require("../../constants/Theme.js"),d=require("../../assets/icons/instagram.svg.js"),c=require("../../assets/icons/warning.svg.js");require("../tooltips/Tooltip.js"),require("../analytics-chips-and-dropdowns/CommonStyles.js");var p=require("../analytics-chips-and-dropdowns/AnalyticsDropdown.js");require("../analytics-chips-and-dropdowns/AnalyticsMetric.js"),require("../shimmer/ShimmerComponent/ShimmerStyled.js"),require("../../utils/DateUtils.js"),require("../analytics-chips-and-dropdowns/chart/utils/calcPercentage.js"),require("../analytics-chips-and-dropdowns/chart/LineChart/LineChart.js"),require("react-bootstrap"),require("../analytics-chips-and-dropdowns/chart/scoreBlock/ScoreBlock.styled.js"),require("../analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.styled.js"),require("../analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js"),require("../analytics-chips-and-dropdowns/chart/Pie/PieChart.js"),require("../analytics-chips-and-dropdowns/chart/HorizontalBarGraph/HorizontalGraph.js"),require("../analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.js"),require("../analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.js"),require("../analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.model.js"),require("../analytics-chips-and-dropdowns/chart/VerticalBarGraph/VerticalGraph.js"),require("../analytics-chips-and-dropdowns/chart/VerticalBarGraph/FunnelVerticalBarGraph.js"),require("../analytics-chips-and-dropdowns/chart/heatmap/HeatMap.js"),require("../analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.js"),require("../analytics-chips-and-dropdowns/chart/VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js");var h,u,y=require("../modals/styledModal.js"),m=require("../shimmer/ShimmerComponent/BikShimmer.js"),x=require("../shimmer-image/ShimmerImage.js"),j=require("../states/StateComponent.js");require("../../_virtual/_tslib.js"),exports.MEDIA_TYPES=void 0,(h=exports.MEDIA_TYPES||(exports.MEDIA_TYPES={})).STORY="story",h.POST="post",h.REEL="reel",exports.DateKeys=void 0,(u=exports.DateKeys||(exports.DateKeys={})).Today="Today",u["7_Days"]="7",u["30_Days"]="30",u.custom="custom",u.Yesterday="Yesterday";const g=[{label:"Today",value:"today",key:exports.DateKeys.Today,typeValue:[new Date,new Date]},{label:"Last 7 days",value:"7 days",key:exports.DateKeys["7_Days"],typeValue:[new Date((new Date).setDate((new Date).getDate()-6)),new Date]},{label:"Last 30 days",value:"30 days",key:exports.DateKeys["30_Days"],typeValue:[new Date((new Date).setDate((new Date).getDate()-29)),new Date]},{label:"Custom range",value:"calender",key:exports.DateKeys.custom,isCustom:!0,dateRangeSelectionOptions:{selectRange:!0,maxDate:new Date((new Date).setMonth((new Date).getMonth()+3))}}];exports.PostPicker=h=>{var u,S;const[w,D]=a.useState(null!==(u=h.previouslySelected)&&void 0!==u?u:[]),[v,C]=a.useState(""),[T,f]=a.useState(!1),[q,k]=a.useState(h.media),[B,P]=a.useState(!1),[E,b]=a.useState(!1),[I,O]=a.useState(!1),_=a.useRef(null);a.useEffect(()=>{h.media.length||(f(!0),setTimeout(()=>{f(!1)},2e3)),D(h.selected||[])},[]),a.useEffect(()=>{h.media.length>0&&(k(h.media),f(!1))},[null===(S=null==h?void 0:h.media)||void 0===S?void 0:S.length]),a.useEffect(()=>{w.length>0&&C("")},[w.length]),a.useEffect(()=>{B&&(k(h.media),b(!1))},[B]),a.useEffect(()=>{const e=e=>{document.getElementById("analytic-dropdown").contains(e.target)||O(!I)},t=document.getElementById("post-picker");return t&&t.addEventListener("click",e),()=>{t&&t.removeEventListener("click",e)}});return e.jsx("div",{ref:_,children:e.jsxs(y.StyledModal,{zIndex:201,open:h.showModal,headingTitle:h.title,onClose:h.onClose,centralContainerStyles:{width:1071,height:h.showFilter?650:564},primaryButton:{disabled:!q.length,buttonType:"primary",buttonText:`Select ${n.unCamelCase(h.mediaType)}`,onClick:()=>{w.length?h.onSelect(w):C(`Please select a ${h.mediaType} to proceed`)}},secondaryButton:{buttonType:"secondary",buttonText:"Back",onClick:()=>h.onClose()},footerLeftCustomElement:v?e.jsx(s.Tag,{tagText:v,type:"negative",LeadingIcon:c.default}):w.length?e.jsxs(i.BodySecondary,{children:[w.length," selected"]}):null,id:"post-picker",children:[h.showFilter&&e.jsxs("div",{style:{marginTop:24,marginBottom:24,padding:"0 24px",display:"flex",flexDirection:"row",gap:8,alignItems:"center"},children:[e.jsx(p.AnalyticsDropdown,{options:g,placeholder:"posted on",resetDropdown:B,onOptionSelected:e=>{var t,a;let r=null,s=null;"Custom range"===e.label?(r=(null===(t=null==e?void 0:e.selectedRange)||void 0===t?void 0:t[0])||new Date,s=(null===(a=null==e?void 0:e.selectedRange)||void 0===a?void 0:a[1])||new Date):(r=e.typeValue[0],s=e.typeValue[1]);const i=h.media.filter(e=>function(e,t,a){const r=new Date(e),s=new Date(t),i=new Date(a);return r>=s&&r<=i}(e.timestamp,r,s));k(i),b(!0),P(!1)},closeDropdown:I}),E&&e.jsx(i.ButtonRegular,{color:l.COLORS.content.secondary,onClick:()=>P(!0),style:{cursor:"pointer"},children:"Clear"})]}),T?e.jsx("div",{style:{padding:"0 24px"},children:e.jsx(m.BikShimmer,{boxes:[{width:(h.mediaType==exports.MEDIA_TYPES.POST?148:104)+"px",height:(h.mediaType==exports.MEDIA_TYPES.POST?148:172)+"px"}]})}):e.jsx(e.Fragment,{children:q&&q.length?e.jsx(r.StyledProductGrid,{mediaType:h.mediaType,children:q.map(t=>{return e.jsxs(r.StyledProduct,{mediaType:h.mediaType,className:""+(a=t,s=w,s.some(e=>e.id===a.id)?"selected":""),onClick:()=>{return e=t,void D(()=>w.find(t=>t.id===e.id)?w.filter(t=>t.id!==e.id):!h.limit||w.length<h.limit?[...w,e]:(C(`Only ${h.limit} ${h.mediaType}s can be selected`),w));var e},children:[e.jsx(x.ShimmerImage,{imageUrl:t.imageUrl,width:h.mediaType==exports.MEDIA_TYPES.POST?148:104,height:h.mediaType==exports.MEDIA_TYPES.POST?148:172,alt:t.overlayCaption}),e.jsxs("div",{className:"overlay",children:[e.jsx("a",{target:"_blank",rel:"noreferrer",href:t.redirectionUrl,children:e.jsxs("div",{className:"overlay__redirection",children:[e.jsx(d.default,{height:22,width:22}),e.jsx(i.BodyPrimary,{color:o.PRIMARY,style:{fontWeight:500},children:"View"})]})}),e.jsx("div",{className:"overlay__caption",children:e.jsx(i.BodyCaption,{color:l.COLORS.content.placeholder,children:t.overlayCaption})})]})]},t.id);var a,s})}):e.jsx("div",{style:{justifyContent:"center",alignItems:"center",display:"flex",height:422},children:h.media.length?q.length?e.jsx(e.Fragment,{}):e.jsxs("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:"16px"},children:[e.jsx("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",width:"48px",height:"48px",backgroundColor:`${l.COLORS.background.inverse}`,borderRadius:"50%"},children:e.jsx(t.SearchIcon,{color:l.COLORS.content.primaryInverse})}),e.jsxs("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:"8px"},children:[e.jsx(i.TitleMedium,{children:"No results found"}),e.jsx(i.BodyPrimary,{children:"Sorry we could not find any results for the selected filter"})]}),e.jsx("div",{onClick:()=>{P(!0)},style:{cursor:"pointer"},children:e.jsx(i.ButtonLarge,{color:`${l.COLORS.content.brand}`,children:"Clear Filter"})})]}):e.jsx(j.StateComponent,{states:j.StateInterface.WARNING,heading:`No ${h.mediaType}s on your account`,subline:`There seems to be no ${h.mediaType}s on your account`,isButtonEnabled:!1,width:400})})})]})})},exports.dateOptions=g;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/searchIcon.js"),a=require("react"),r=require("./PostPicker.styled.js"),s=require("../tag/Tag.js"),i=require("../TypographyStyle.js"),n=require("../../utils/unCamelCase.js"),o=require("../../constants/colors.js"),l=require("../../constants/Theme.js"),d=require("../../assets/icons/instagram.svg.js"),c=require("../../assets/icons/warning.svg.js");require("../tooltips/Tooltip.js"),require("../analytics-chips-and-dropdowns/CommonStyles.js");var p=require("../analytics-chips-and-dropdowns/AnalyticsDropdown.js");require("../analytics-chips-and-dropdowns/AnalyticsMetric.js"),require("../shimmer/ShimmerComponent/ShimmerStyled.js"),require("../../utils/DateUtils.js"),require("../analytics-chips-and-dropdowns/chart/utils/calcPercentage.js"),require("../analytics-chips-and-dropdowns/chart/LineChart/LineChart.js"),require("react-bootstrap"),require("../analytics-chips-and-dropdowns/chart/scoreBlock/ScoreBlock.styled.js"),require("../analytics-chips-and-dropdowns/chart/linearChipGroupedChart/LinearChipGroupedChart.styled.js"),require("../analytics-chips-and-dropdowns/chart/Pie/PieChartAnalytics.js"),require("../analytics-chips-and-dropdowns/chart/Pie/PieChart.js"),require("../analytics-chips-and-dropdowns/chart/HorizontalBarGraph/HorizontalGraph.js"),require("../analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarChart.js"),require("../analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.js"),require("../analytics-chips-and-dropdowns/chart/StackedBarChart/StackedBarDistributionChart.model.js"),require("../analytics-chips-and-dropdowns/chart/VerticalBarGraph/VerticalGraph.js"),require("../analytics-chips-and-dropdowns/chart/VerticalBarGraph/FunnelVerticalBarGraph.js"),require("../analytics-chips-and-dropdowns/chart/heatmap/HeatMap.js"),require("../analytics-chips-and-dropdowns/chart/heatmap/HeatMapVertical.js"),require("../analytics-chips-and-dropdowns/chart/VerticalBarAndLinearGraph/VerticalBarAndLinearGraph.js");var h,u,y=require("../modals/styledModal.js"),m=require("../shimmer/ShimmerComponent/BikShimmer.js"),x=require("../shimmer-image/ShimmerImage.js"),j=require("../states/StateComponent.js");require("../../_virtual/_tslib.js"),exports.MEDIA_TYPES=void 0,(h=exports.MEDIA_TYPES||(exports.MEDIA_TYPES={})).STORY="story",h.POST="post",h.REEL="reel",exports.DateKeys=void 0,(u=exports.DateKeys||(exports.DateKeys={})).Today="Today",u["7_Days"]="7",u["30_Days"]="30",u.custom="custom",u.Yesterday="Yesterday";const g=[{label:"Today",value:"today",key:exports.DateKeys.Today,typeValue:[new Date,new Date]},{label:"Last 7 days",value:"7 days",key:exports.DateKeys["7_Days"],typeValue:[new Date((new Date).setDate((new Date).getDate()-6)),new Date]},{label:"Last 30 days",value:"30 days",key:exports.DateKeys["30_Days"],typeValue:[new Date((new Date).setDate((new Date).getDate()-29)),new Date]},{label:"Custom range",value:"calender",key:exports.DateKeys.custom,isCustom:!0,dateRangeSelectionOptions:{selectRange:!0,maxDate:new Date((new Date).setMonth((new Date).getMonth()+3))}}];exports.PostPicker=h=>{var u,S;const[w,D]=a.useState(null!==(u=h.previouslySelected)&&void 0!==u?u:[]),[v,C]=a.useState(""),[T,f]=a.useState(!1),[q,k]=a.useState(h.media),[B,P]=a.useState(!1),[E,b]=a.useState(!1),[I,O]=a.useState(!1),_=a.useRef(null);a.useEffect((()=>{h.media.length||(f(!0),setTimeout((()=>{f(!1)}),2e3)),D(h.selected||[])}),[]),a.useEffect((()=>{h.media.length>0&&(k(h.media),f(!1))}),[null===(S=null==h?void 0:h.media)||void 0===S?void 0:S.length]),a.useEffect((()=>{w.length>0&&C("")}),[w.length]),a.useEffect((()=>{B&&(k(h.media),b(!1))}),[B]),a.useEffect((()=>{const e=e=>{document.getElementById("analytic-dropdown").contains(e.target)||O(!I)},t=document.getElementById("post-picker");return t&&t.addEventListener("click",e),()=>{t&&t.removeEventListener("click",e)}}));return e.jsx("div",{ref:_,children:e.jsxs(y.StyledModal,{zIndex:201,open:h.showModal,headingTitle:h.title,onClose:h.onClose,centralContainerStyles:{width:1071,height:h.showFilter?650:564},primaryButton:{disabled:!q.length,buttonType:"primary",buttonText:`Select ${n.unCamelCase(h.mediaType)}`,onClick:()=>{w.length?h.onSelect(w):C(`Please select a ${h.mediaType} to proceed`)}},secondaryButton:{buttonType:"secondary",buttonText:"Back",onClick:()=>h.onClose()},footerLeftCustomElement:v?e.jsx(s.Tag,{tagText:v,type:"negative",LeadingIcon:c.default}):w.length?e.jsxs(i.BodySecondary,{children:[w.length," selected"]}):null,id:"post-picker",children:[h.showFilter&&e.jsxs("div",{style:{marginTop:24,marginBottom:24,padding:"0 24px",display:"flex",flexDirection:"row",gap:8,alignItems:"center"},children:[e.jsx(p.AnalyticsDropdown,{options:g,placeholder:"posted on",resetDropdown:B,onOptionSelected:e=>{var t,a;let r=null,s=null;"Custom range"===e.label?(r=(null===(t=null==e?void 0:e.selectedRange)||void 0===t?void 0:t[0])||new Date,s=(null===(a=null==e?void 0:e.selectedRange)||void 0===a?void 0:a[1])||new Date):(r=e.typeValue[0],s=e.typeValue[1]);const i=h.media.filter((e=>function(e,t,a){const r=new Date(e),s=new Date(t),i=new Date(a);return r>=s&&r<=i}(e.timestamp,r,s)));k(i),b(!0),P(!1)},closeDropdown:I}),E&&e.jsx(i.ButtonRegular,{color:l.COLORS.content.secondary,onClick:()=>P(!0),style:{cursor:"pointer"},children:"Clear"})]}),T?e.jsx("div",{style:{padding:"0 24px"},children:e.jsx(m.BikShimmer,{boxes:[{width:(h.mediaType==exports.MEDIA_TYPES.POST?148:104)+"px",height:(h.mediaType==exports.MEDIA_TYPES.POST?148:172)+"px"}]})}):e.jsx(e.Fragment,{children:q&&q.length?e.jsx(r.StyledProductGrid,{mediaType:h.mediaType,children:q.map((t=>{return e.jsxs(r.StyledProduct,{mediaType:h.mediaType,className:""+(a=t,s=w,s.some((e=>e.id===a.id))?"selected":""),onClick:()=>{return e=t,void D((()=>w.find((t=>t.id===e.id))?w.filter((t=>t.id!==e.id)):!h.limit||w.length<h.limit?[...w,e]:(C(`Only ${h.limit} ${h.mediaType}s can be selected`),w)));var e},children:[e.jsx(x.ShimmerImage,{imageUrl:t.imageUrl,width:h.mediaType==exports.MEDIA_TYPES.POST?148:104,height:h.mediaType==exports.MEDIA_TYPES.POST?148:172,alt:t.overlayCaption}),e.jsxs("div",{className:"overlay",children:[e.jsx("a",{target:"_blank",rel:"noreferrer",href:t.redirectionUrl,children:e.jsxs("div",{className:"overlay__redirection",children:[e.jsx(d.default,{height:22,width:22}),e.jsx(i.BodyPrimary,{color:o.PRIMARY,style:{fontWeight:500},children:"View"})]})}),e.jsx("div",{className:"overlay__caption",children:e.jsx(i.BodyCaption,{color:l.COLORS.content.placeholder,children:t.overlayCaption})})]})]},t.id);var a,s}))}):e.jsx("div",{style:{justifyContent:"center",alignItems:"center",display:"flex",height:422},children:h.media.length?q.length?e.jsx(e.Fragment,{}):e.jsxs("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",gap:"16px"},children:[e.jsx("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",width:"48px",height:"48px",backgroundColor:`${l.COLORS.background.inverse}`,borderRadius:"50%"},children:e.jsx(t.SearchIcon,{color:l.COLORS.content.primaryInverse})}),e.jsxs("div",{style:{display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:"8px"},children:[e.jsx(i.TitleMedium,{children:"No results found"}),e.jsx(i.BodyPrimary,{children:"Sorry we could not find any results for the selected filter"})]}),e.jsx("div",{onClick:()=>{P(!0)},style:{cursor:"pointer"},children:e.jsx(i.ButtonLarge,{color:`${l.COLORS.content.brand}`,children:"Clear Filter"})})]}):e.jsx(j.StateComponent,{states:j.StateInterface.WARNING,heading:`No ${h.mediaType}s on your account`,subline:`There seems to be no ${h.mediaType}s on your account`,isButtonEnabled:!1,width:400})})})]})})},exports.dateOptions=g;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../node_modules/lodash.debounce/index.js"),s=require("react"),o=require("../bik-layout/PageLoader.js"),r=require("../checkBox/CheckBox.js"),l=require("../input/Input.js"),n=require("../modals/styledModal.js"),c=require("./ProductPicker.styled.js"),d=require("../TypographyStyle.js"),i=require("../../utils/DateUtils.js"),a=require("../../constants/Theme.js"),u=require("../../assets/icons/alert_triangle.svg.js"),p=require("../../assets/icons/search.svg.js");const h="https://jkfenner.com/wp-content/uploads/2019/11/default.jpg",x=
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../node_modules/lodash.debounce/index.js"),s=require("react"),o=require("../bik-layout/PageLoader.js"),r=require("../checkBox/CheckBox.js"),l=require("../input/Input.js"),n=require("../modals/styledModal.js"),c=require("./ProductPicker.styled.js"),d=require("../TypographyStyle.js"),i=require("../../utils/DateUtils.js"),a=require("../../constants/Theme.js"),u=require("../../assets/icons/alert_triangle.svg.js"),p=require("../../assets/icons/search.svg.js");const h="https://jkfenner.com/wp-content/uploads/2019/11/default.jpg",x=t=>{let{text:s,styleProps:o}=t;return e.jsxs(c.StyledZeroState,{children:[e.jsx("div",{className:"icon__container",style:Object.assign({},o),children:e.jsx(u.default,{width:24,height:24,color:a.DEFAULT_THEME.colorsV2.content.secondary})}),e.jsx(d.TitleSmall,{children:"No results found"}),e.jsx(d.BodySecondary,{style:{color:a.DEFAULT_THEME.colorsV2.content.secondary,textAlign:"center"},children:`Sorry we could not find any results for "${s}"`})]})},j=n=>{var u,j,m,P;const y=n.instaPost?i.default.dateFormat(new Date(n.instaPost.timestamp),"•",!0):"",[v,g]=s.useState(n.products),[E,_]=s.useState(!1),[T,f]=s.useState(""),S=s.useCallback(t.default((e=>{e?(g([]),n.onSearchKeyChange(e).then((e=>{g(e),_(!1)}))):(g(n.products),_(!1))}),700),[]);return e.jsxs(c.StyledProductPickerContainer,{children:[n.instaPost&&e.jsxs("div",{className:"post__wrapper",children:[e.jsx("img",{alt:"Ig Media",onError:e=>{e.target.onerror=null,e.target.src=h},src:null===(u=n.instaPost)||void 0===u?void 0:u.media_url,className:"post__thumbnail"}),e.jsxs("div",{className:"post__info-wrapper",children:[e.jsx(d.BodyPrimary,{style:{textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap",color:n.instaPost.caption?a.DEFAULT_THEME.colorsV2.content.primary:a.DEFAULT_THEME.colorsV2.content.secondary},children:(null===(j=n.instaPost)||void 0===j?void 0:j.caption)?null===(m=n.instaPost)||void 0===m?void 0:m.caption:"No caption"}),e.jsx(d.Caption,{style:{color:a.DEFAULT_THEME.colorsV2.content.placeholder},children:y})]})]}),e.jsx("div",{style:{borderTop:n.instaPost?`1px solid ${a.DEFAULT_THEME.colorsV2.stroke.primary}`:"none",borderBottom:`1px solid ${a.DEFAULT_THEME.colorsV2.stroke.primary}`,padding:n.instaPost?"16px 24px":"0px 24px 16px 24px"},children:e.jsx(l.Input,{placeholder:null!==(P=n.searchPlaceholder)&&void 0!==P?P:"Search products..",onChangeText:e=>{var t;f(e),(null===(t=e.trim())||void 0===t?void 0:t.length)>0?(_(!0),S(e)):(_(!1),g(n.products))},rightIcon:{icon:p.default}})}),e.jsxs("div",{style:{maxHeight:350,overflowY:"scroll"},children:[E&&e.jsx("div",{className:"loader__wrapper",children:e.jsx(o.PageLoader,{})}),0!==v.length||E?v.map((t=>{var s;const o=n.selectedProducts.find((e=>e.id===t.id));return e.jsxs("div",{className:"product__wrapper",children:[e.jsxs("div",{className:"product__info-wrapper",children:[e.jsx("img",{alt:"Product",onError:e=>{e.target.onerror=null,e.target.src=h},src:null!==(s=t.image)&&void 0!==s?s:h,className:"product__image"}),e.jsx(d.TitleSmall,{children:t.name})]}),e.jsx("div",{style:{order:1},children:e.jsx(r.CheckBox,{isChecked:void 0!==o,onValueChange:e=>{((e,t)=>{const s=n.selectedProducts.find((e=>e.id===t.id));if(e&&!s){const e=[...n.selectedProducts,t];n.setSelectedProducts(e)}else if(s){const e=[...n.selectedProducts];let s=-1;n.selectedProducts.forEach(((e,o)=>{e.id===t.id&&(s=o)})),e.splice(s,1),n.setSelectedProducts(e)}})(e,t)}})})]},t.id)})):e.jsx(x,{text:T})]})]})};exports.PricePleaseProductPicker=t=>{var o;const[r,l]=s.useState([]);return s.useEffect((()=>{var e;l(null!==(e=t.selectedProducts)&&void 0!==e?e:[])}),[null===(o=t.selectedProducts)||void 0===o?void 0:o.length]),e.jsx(n.StyledModal,{open:t.show,onClose:()=>{t.onClose()},footerLeftCustomElement:r.length>10?e.jsx(d.Caption,{style:{color:a.DEFAULT_THEME.colorsV2.content.negative},children:"Can't add more than 10 products"}):e.jsx(d.Caption,{style:{color:a.DEFAULT_THEME.colorsV2.content.placeholder},children:r?`${r.length} selected`:""}),headingTitle:t.title,primaryButton:{disabled:r.length>10||0===r.length,buttonType:"primary",buttonText:"Select",size:"small",onClick:()=>{t.setSelectedProducts(r),t.onClose()}},secondaryButton:t.secondaryButtonProps,footerShadow:!0,children:e.jsx(j,Object.assign({},t,{selectedProducts:r,setSelectedProducts:l}))})},exports.ProductPickerContent=j;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("../shimmer/ShimmerComponent/BikShimmer.js");exports.ProductPickerShimmer=i=>{const{limit:t}=i;return e.jsx(e.Fragment,{children:Array.from({length:null!=t?t:5}).map((i,t)=>e.jsx("div",{style:{borderBottom:"1px solid #E0E0E0"},children:e.jsx(r.BikShimmer,{boxes:[{height:"64px",width:"100%",marginTop:"0px"}]})},t))})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),r=require("../shimmer/ShimmerComponent/BikShimmer.js");exports.ProductPickerShimmer=i=>{const{limit:t}=i;return e.jsx(e.Fragment,{children:Array.from({length:null!=t?t:5}).map(((i,t)=>e.jsx("div",{style:{borderBottom:"1px solid #E0E0E0"},children:e.jsx(r.BikShimmer,{boxes:[{height:"64px",width:"100%",marginTop:"0px"}]})},t)))})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/chevronRight.svg.js"),l=require("react"),i=require("../checkBox/CheckBox.js"),o=require("../icon-button/IconButton.js"),r=require("../tag/Tag.js"),c=require("../tooltips/Tooltip.js"),s=require("../TypographyStyle.js"),n=require("./emptyState.js"),d=require("./ProductPickerShimmer.js"),a=require("./style.js"),u=require("./utility.js");const C=l=>{const{customCollectionRestriction:n,data:d,selectedCollectionsDispatch:u,setCollectionId:C,setSelectedCollectionId:h,isPartiallyChecked:p,setScreen:y,id:v,isChecked:j,isDisabled:x,hideCollectionCheckbox:g,pickerType:m,usedInSearch:k}=l;return d?e.jsxs(a.CollectionCardStyle,{isDisabled:x,onClick:e=>{if(!x){if("COLLECTION"===m)return e.stopPropagation(),u({type:"reset",data:{}}),u({type:"selected",data:{id:v,val:d,isRestricted:n}}),C(v),void h(v);C(v),h(v),y("products")}},isActive:j,usedInSearch:null!=k&&k,children:[e.jsxs(a.CollectionCardInfoStyle,{children:[!g&&e.jsx(i.CheckBox,{isDisabled:x,isChecked:j,isPartiallyChecked:p,onValueChange:function(e,t,l){null==l||l.stopPropagation(),u(e?{type:"selected",data:{id:v,val:d,isRestricted:n}}:{type:"unselected",data:{id:v}}),h(e?v:"")}}),e.jsx(a.CollectionCardDetailStyle,{children:e.jsx(c.Tooltip,{body:d.name,placement:"bottom",delay:400,variant:"light",children:e.jsxs(a.CollectionNameHolder,{children:[k?e.jsx(s.BodyPrimary,{numberOfLines:1,children:d.name}):e.jsx(s.TitleRegular,{numberOfLines:1,children:d.name}),d.isSmartCollection?e.jsx("div",{style:{display:"flex"},children:e.jsx(r.Tag,{tagText:"Smart Collection",type:"warning"})}):e.jsx(e.Fragment,{})]})})})]}),"COLLECTION"!==m&&e.jsx(o.IconButton,{height:12,width:12,disabled:x,Icon:t.default})]}):e.jsx(e.Fragment,{})};exports.CollectionCard=C,exports.CollectionsScreen=t=>{var i;const{customCollectionRestriction:o,dataLoading:r,collections:c,selectedCollectionsDispatch:s,setCollectionId:a,setSelectedCollectionId:h,selectedCollections:p,setScreen:y,collectionFetcher:v,collectionsDispatch:j,pagingControls:x,storeId:g,setSaveDisabled:m,hideCollectionCheckbox:k,renderWithoutModal:f,pickerType:S,scrollContainerRef:b,appType:P,limit:I,exactLimit:O}=t,T=l.useRef(x.curPage),q=!!o&&(null==p?void 0:p.isCustom),[L,R]=l.useState(!1),D=l.useRef(!1),E=l.useRef(!1),B=()=>{if(!b||!(null==b?void 0:b.current))return;const{scrollTop:e,clientHeight:t,scrollHeight:l}=b.current;e+t>=l-20&&!D.current&&!E.current&&(m(!0),R(!0),E.current=!0,m(!0),R(!0),v(T.current,g,P).then(e=>{j({type:"paged",data:(null==e?void 0:e.collections)||{}}),x.setCurPage(T.current+1),R(!1),m(!1),E.current=!1,Object.keys(null==e?void 0:e.collections).length||(D.current=!0)}).catch())};l.useEffect(()=>{var e;return null===(e=null==b?void 0:b.current)||void 0===e||e.addEventListener("scroll",B),()=>{var e;null===(e=null==b?void 0:b.current)||void 0===e||e.removeEventListener("scroll",B)}},[]),l.useEffect(()=>{T.current=x.curPage},[x.curPage]);const N=Object.keys(p||{}).filter(e=>"isCustom"!==e).length;return e.jsxs("div",{children:[(null===(i=Object.keys(null!=c?c:{}))||void 0===i?void 0:i.length)?Object.keys(c).map(t=>{var l,i;const r=!!(null==p?void 0:p[t])&&("PRODUCT"!==S||!!Object.keys(null!==(i=null===(l=null==p?void 0:p[t])||void 0===l?void 0:l.products)&&void 0!==i?i:{}).length),n="COLLECTION"===S&&!r&&(!!O&&N>=O||!!I&&N>=I);return e.jsx(C,{customCollectionRestriction:o,data:c[t],isDisabled:q&&!(null==p?void 0:p[t])||n,isChecked:r,isPartiallyChecked:u.isCollectionPartiallyChecked(t,null==c?void 0:c[t],p),selectedCollectionsDispatch:s,setCollectionId:a,setSelectedCollectionId:h,setScreen:y,id:t,hideCollectionCheckbox:k||"-1"===t,selectedCollections:p,renderWithoutModal:f,pickerType:S},t)}):r?e.jsx(d.ProductPickerShimmer,{}):e.jsx(n.EmptyState,{title:"No collections to show",subtitle:"We couldn’t find any collection."}),L&&e.jsx(d.ProductPickerShimmer,{})]})},exports.truncate=(e,t,l)=>{if(!e)return"";if(e.length<=t)return e;const i=e.slice(0,t-1);return(l?i.slice(0,i.lastIndexOf(" ")):i)+"..."};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/chevronRight.svg.js"),l=require("react"),i=require("../checkBox/CheckBox.js"),o=require("../icon-button/IconButton.js"),r=require("../tag/Tag.js"),c=require("../tooltips/Tooltip.js"),s=require("../TypographyStyle.js"),n=require("./emptyState.js"),d=require("./ProductPickerShimmer.js"),a=require("./style.js"),u=require("./utility.js");const C=l=>{const{customCollectionRestriction:n,data:d,selectedCollectionsDispatch:u,setCollectionId:C,setSelectedCollectionId:h,isPartiallyChecked:p,setScreen:y,id:v,isChecked:j,isDisabled:x,hideCollectionCheckbox:g,pickerType:m,usedInSearch:k}=l;return d?e.jsxs(a.CollectionCardStyle,{isDisabled:x,onClick:e=>{if(!x){if("COLLECTION"===m)return e.stopPropagation(),u({type:"reset",data:{}}),u({type:"selected",data:{id:v,val:d,isRestricted:n}}),C(v),void h(v);C(v),h(v),y("products")}},isActive:j,usedInSearch:null!=k&&k,children:[e.jsxs(a.CollectionCardInfoStyle,{children:[!g&&e.jsx(i.CheckBox,{isDisabled:x,isChecked:j,isPartiallyChecked:p,onValueChange:function(e,t,l){null==l||l.stopPropagation(),u(e?{type:"selected",data:{id:v,val:d,isRestricted:n}}:{type:"unselected",data:{id:v}}),h(e?v:"")}}),e.jsx(a.CollectionCardDetailStyle,{children:e.jsx(c.Tooltip,{body:d.name,placement:"bottom",delay:400,variant:"light",children:e.jsxs(a.CollectionNameHolder,{children:[k?e.jsx(s.BodyPrimary,{numberOfLines:1,children:d.name}):e.jsx(s.TitleRegular,{numberOfLines:1,children:d.name}),d.isSmartCollection?e.jsx("div",{style:{display:"flex"},children:e.jsx(r.Tag,{tagText:"Smart Collection",type:"warning"})}):e.jsx(e.Fragment,{})]})})})]}),"COLLECTION"!==m&&e.jsx(o.IconButton,{height:12,width:12,disabled:x,Icon:t.default})]}):e.jsx(e.Fragment,{})};exports.CollectionCard=C,exports.CollectionsScreen=t=>{var i;const{customCollectionRestriction:o,dataLoading:r,collections:c,selectedCollectionsDispatch:s,setCollectionId:a,setSelectedCollectionId:h,selectedCollections:p,setScreen:y,collectionFetcher:v,collectionsDispatch:j,pagingControls:x,storeId:g,setSaveDisabled:m,hideCollectionCheckbox:k,renderWithoutModal:f,pickerType:S,scrollContainerRef:b,appType:P,limit:I,exactLimit:O}=t,T=l.useRef(x.curPage),q=!!o&&(null==p?void 0:p.isCustom),[L,R]=l.useState(!1),D=l.useRef(!1),E=l.useRef(!1),B=()=>{if(!b||!(null==b?void 0:b.current))return;const{scrollTop:e,clientHeight:t,scrollHeight:l}=b.current;e+t>=l-20&&!D.current&&!E.current&&(m(!0),R(!0),E.current=!0,m(!0),R(!0),v(T.current,g,P).then((e=>{j({type:"paged",data:(null==e?void 0:e.collections)||{}}),x.setCurPage(T.current+1),R(!1),m(!1),E.current=!1,Object.keys(null==e?void 0:e.collections).length||(D.current=!0)})).catch())};l.useEffect((()=>{var e;return null===(e=null==b?void 0:b.current)||void 0===e||e.addEventListener("scroll",B),()=>{var e;null===(e=null==b?void 0:b.current)||void 0===e||e.removeEventListener("scroll",B)}}),[]),l.useEffect((()=>{T.current=x.curPage}),[x.curPage]);const N=Object.keys(p||{}).filter((e=>"isCustom"!==e)).length;return e.jsxs("div",{children:[(null===(i=Object.keys(null!=c?c:{}))||void 0===i?void 0:i.length)?Object.keys(c).map((t=>{var l,i;const r=!!(null==p?void 0:p[t])&&("PRODUCT"!==S||!!Object.keys(null!==(i=null===(l=null==p?void 0:p[t])||void 0===l?void 0:l.products)&&void 0!==i?i:{}).length),n="COLLECTION"===S&&!r&&(!!O&&N>=O||!!I&&N>=I);return e.jsx(C,{customCollectionRestriction:o,data:c[t],isDisabled:q&&!(null==p?void 0:p[t])||n,isChecked:r,isPartiallyChecked:u.isCollectionPartiallyChecked(t,null==c?void 0:c[t],p),selectedCollectionsDispatch:s,setCollectionId:a,setSelectedCollectionId:h,setScreen:y,id:t,hideCollectionCheckbox:k||"-1"===t,selectedCollections:p,renderWithoutModal:f,pickerType:S},t)})):r?e.jsx(d.ProductPickerShimmer,{}):e.jsx(n.EmptyState,{title:"No collections to show",subtitle:"We couldn’t find any collection."}),L&&e.jsx(d.ProductPickerShimmer,{})]})},exports.truncate=(e,t,l)=>{if(!e)return"";if(e.length<=t)return e;const i=e.slice(0,t-1);return(l?i.slice(0,i.lastIndexOf(" ")):i)+"..."};
|
|
@@ -5,4 +5,4 @@
|
|
|
5
5
|
align-items: center;
|
|
6
6
|
justify-content: center;
|
|
7
7
|
text-align: center;
|
|
8
|
-
`;exports.EmptyState=
|
|
8
|
+
`;exports.EmptyState=r=>{let{title:i,subtitle:l}=r;return e.jsxs(o,{children:[e.jsx(t.default,{width:48,height:48}),e.jsx(s.TitleRegular,{style:{marginTop:8},children:i}),e.jsx(s.BodySecondary,{style:{color:n.COLORS.content.secondary,marginTop:4},children:l})]})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t=require("../type.js");const n={NORMAL:null,NOT_SYNCED:"Hidden",OUT_OF_STOCK:"Out of Stock",FB_REJECTED:"Rejected on FB catalog"};class l{static getProductLabels(l
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var t=require("../type.js");const n={NORMAL:null,NOT_SYNCED:"Hidden",OUT_OF_STOCK:"Out of Stock",FB_REJECTED:"Rejected on FB catalog"};class l{static getProductLabels(l){let i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.OUT_OF_STOCK_ACTION.NORMAL,u="NORMAL";if(l.variants)return n[u];const e=l;return"REJECTED"===(null==e?void 0:e.fbStatus)?n.FB_REJECTED:(i===t.OUT_OF_STOCK_ACTION.HIDE&&(!e.skipSync||0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)||(u="NOT_SYNCED"),e.skipSync&&0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)&&(u="NOT_SYNCED"),e.skipSync||0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)||(u="NOT_SYNCED"),e.skipSync||0===(null==e?void 0:e.quantity)||-2===(null==e?void 0:e.quantity)||(u="NORMAL")),i===t.OUT_OF_STOCK_ACTION.BLUR&&(!e.skipSync||0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)||(u="NOT_SYNCED"),e.skipSync&&0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)&&(u="NOT_SYNCED"),e.skipSync||0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)||(u="OUT_OF_STOCK"),e.skipSync||0===(null==e?void 0:e.quantity)||-2===(null==e?void 0:e.quantity)||(u="NORMAL")),i===t.OUT_OF_STOCK_ACTION.NORMAL&&(!e.skipSync||0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)||(u="NOT_SYNCED"),e.skipSync&&0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)&&(u="NOT_SYNCED"),e.skipSync||0!==(null==e?void 0:e.quantity)&&-2!==(null==e?void 0:e.quantity)||(u="NORMAL"),e.skipSync||0===(null==e?void 0:e.quantity)||-2===(null==e?void 0:e.quantity)||(u="NORMAL")),n[u])}}Object.defineProperty(l,"getTagType",{enumerable:!0,configurable:!0,writable:!0,value:t=>n.FB_REJECTED===t?"negative":"warning"}),Object.defineProperty(l,"getDataForProductPickerTag",{enumerable:!0,configurable:!0,writable:!0,value:(t,n,i)=>{var u,e;let a=t,r=n;1===Object.keys(null!==(u=null==t?void 0:t.variants)&&void 0!==u?u:{}).length&&(a=Object.values(null!==(e=null==t?void 0:t.variants)&&void 0!==e?e:{})[0],r=!0);const o=l.getProductLabels(a,i);return{isVariantForProductPickerTag:r,dataForProductPickerTag:a,tagText:null!=o?o:void 0,tagType:l.getTagType(null!=o?o:"")}}});exports.ProductHelper=l,exports.parseSelectedVariantsToArray=t=>{let n=[];Object.keys(t).forEach((l=>{var i;return Object.keys((null===(i=null==t?void 0:t[l])||void 0===i?void 0:i.products)||[]).forEach((i=>{var u,e;const a=null!==(u=t[l].products)&&void 0!==u?u:[],r=null!==(e=a[i].variants)&&void 0!==e?e:[];return Object.keys(r).map((t=>{const n=r[t];n.currency=a[i].currency,n.variantId=t,n.productId=i,n.collectionId=l,n.productName=a[i].name})),n=[...n,...Object.values(r)],n}))}));const l=n.sort(((t,n)=>null==t.displayOrder&&null==n.displayOrder?0:null==t.displayOrder?1:null==n.displayOrder?-1:t.displayOrder-n.displayOrder));return l.forEach(((t,n)=>{t.displayOrder=n})),l};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("@bikdotai/bik-models/growth/models/bik-store"),o=require("../../assets/icons/search.svg.js"),c=require("react"),r=require("../../constants/Theme.js"),s=require("../../assets/icons/cross.svg.js"),n=require("../button/Button.js"),i=require("../input/Input.js"),l=require("../modals/styledModal.js"),a=require("../spinner/Spinner.js"),d=require("../tag/Tag.js"),u=require("./collectionScreen.js"),h=require("./productInfoOverlay.js"),p=require("./productScreen.js"),S=require("./rearrangeScreen.js"),C=require("./reducers.js"),y=require("./searchScreen.js"),g=require("./selectedScreen.js"),m=require("./style.js"),x=require("./type.js"),j=require("./utility.js");exports.ProductPickerModal=b=>{const{storeId:f,selectedItems:v,onClose:k,visible:I,zIndex:O,exactLimit:F,limit:P,hideCollectionCheckbox:T,hideProductCheckbox:R,outOfStockAction:D=x.OUT_OF_STOCK_ACTION.BLUR,hideVariantCheckbox:q,selectProductsFromCustomCollection:E,hideSelectionCount:N,title:L,width:A,left:B,renderWithoutModal:w,onClickSave:$,pickerType:M,hideProductVariants:V=!1,startupScreen:z=x.ScreenName.Collections,rearrangeEnabled:_,selectSingleItem:H=!1,showProductDetails:K,containerStyle:W,crossButtonInsideHeader:G=!1,footerForNonModal:U={},primaryButton:Y,secondaryButton:J,subtitle:Q}=b,X=b.appType||t.ApplicationType.BIK,[Z,ee]=c.useReducer(C.collectionsReducer,{}),[te,oe]=c.useState([x.ScreenName.Collections,x.ScreenName.RearrangeProducts].includes(z)?z:x.ScreenName.Collections),[ce,re]=c.useState("grid"),[se,ne]=c.useState(""),[ie,le]=c.useState(""),[ae,de]=c.useState(0),[ue,he]=c.useState(!1),[pe,Se]=c.useState(0),[Ce,ye]=c.useState(""),[ge,me]=c.useState(!1),[xe,je]=c.useState(!1),[be,fe]=c.useReducer(C.searchReducer,{collections:{},products:{}}),[ve,ke]=c.useReducer(C.selectedColectionsReducer,Object.keys(v).length>0?v:{}),Ie=c.useRef(null),[Oe,Fe]=c.useState(!1),[Pe,Te]=c.useState();c.useEffect(()=>{he(!0),je(!0),b.collectionFetcher(ae,f,X).then(e=>{ee({type:"fetched",data:(null==e?void 0:e.collections)||{}}),he(!1),de(e=>e+1),je(!1)}).catch()},[]),c.useEffect(()=>{let e=0;"COLLECTION"===M?e=Object.keys(ve||{}).filter(e=>"isCustom"!==e).length:V?Object.keys(ve||[]).forEach(t=>{var o;Object.keys((null===(o=ve[t])||void 0===o?void 0:o.products)||[]).forEach(o=>{var c;"-1"!==t&&ve[-1]&&(null===(c=ve[-1].products)||void 0===c?void 0:c[o])||(e+=1)})}):Object.keys(ve||[]).forEach(t=>{var o;Object.keys((null===(o=ve[t])||void 0===o?void 0:o.products)||[]).forEach(o=>{var c,r;Object.keys((null===(r=null===(c=ve[t].products)||void 0===c?void 0:c[o])||void 0===r?void 0:r.variants)||[]).forEach(()=>{e+=1})})}),Se(e)},[Z,ve,V,M]),c.useEffect(()=>{ie&&(he(!0),b.productFetcher(ie,f,X).then(e=>{Object.keys(e).length&&ee({type:"productsFetched",data:{collectionId:ie,products:e}}),he(!1)}).catch())},[ie]),c.useEffect(()=>{const e=setTimeout(()=>{"rearrange"!==te&&(Ce.length||"collections"!==te)&&(Ce.length?(me(!0),b.searchFetcher(f,Ce,X).then(e=>{"collections"in e&&"products"in e?(fe({type:"set",data:e}),ee({type:"searched",data:e.collections}),ee({type:"searched",data:e.products})):(fe({type:"set",data:{collections:{},products:e}}),ee({type:"searched",data:e})),oe("searchProducts"),he(!1),me(!1)})):oe("collections"))},800);return()=>clearTimeout(e)},[Ce]),c.useEffect(()=>{$&&(b.onAdd(ve,pe),Re())},[$]),c.useEffect(()=>{H&&Object.keys(ve||{}).length&&pe&&(b.onAdd(ve,pe),Re())},[H,ve,pe]);const Re=()=>{ke({type:"reset",data:{}})},De=()=>{let t,o;return"COLLECTION"===M?(t="collection",o="collections"):V?(t="product",o="products"):(t="variant",o="variants"),F&&pe>F?e.jsx(d.Tag,{tagText:`You can only select ${F} ${1===F?t:o}`,type:"negative"}):P&&pe>P?e.jsx(d.Tag,{tagText:`You can only select ${P} ${1===P?t:o}`,type:"negative"}):pe>0?e.jsx(n.Button,{onClick:()=>{oe(_?x.ScreenName.RearrangeProducts:x.ScreenName.SelectedProducts)},buttonText:F?`${pe}/${F} ${1===pe?t:o} selected`:`${pe} ${1===pe?t:o} selected`,buttonType:["rearrange","view"].includes(te)?"tertiaryGray":"tertiary",disabled:["rearrange","view"].includes(te)}):e.jsx(n.Button,{disabled:!0,buttonText:F?`${pe}/${F} ${1===F?t:o} selected`:`${pe} ${1===pe?t:o} selected`,buttonType:"tertiaryGray"})},qe=e=>ue?"Loading...":te===x.ScreenName.RearrangeProducts?null!=e?e:"Done":null!=e?e:"Add",Ee=e.jsxs(m.ContainerStyle,{style:null!=W?W:{},children:[b.postHeader&&e.jsx("div",{style:{padding:"0 24px"},children:b.postHeader}),!b.hideGlobalSearch&&e.jsx(e.Fragment,{children:("collections"===te||"searchProducts"===te)&&e.jsx("div",{style:{padding:w?"8px 16px":"12px 24px",borderBottom:"1px solid #E0E0E0"},children:e.jsx(i.Input,{placeholder:"Search using ID, Name or SKU ID",noKeyDownChange:!0,noErrorHint:!0,rightIcon:{icon:()=>ge?e.jsx(a.Spinner,{size:"small",color:r.COLORS.content.primary}):e.jsx(o.default,{})},id:"listInput",height:"24px",type:"text",value:Ce,onChangeText:e=>{e.length&&e.trim().length?ye(e):ye("")}})})}),e.jsxs(m.ScrollContainerStyle,{ref:Ie,screenName:te,children:["collections"===te&&e.jsx(u.CollectionsScreen,{customCollectionRestriction:b.customCollectionRestriction,dataLoading:xe,collections:Z,selectedCollectionsDispatch:ke,setCollectionId:ne,setSelectedCollectionId:le,setScreen:oe,selectedCollections:ve,collectionFetcher:b.collectionFetcher,storeId:f,appType:X,collectionsDispatch:ee,setSaveDisabled:he,pagingControls:{curPage:ae,setCurPage:de},hideCollectionCheckbox:T,renderWithoutModal:w,pickerType:M,scrollContainerRef:Ie,limit:P,exactLimit:F}),"products"===te&&se&&e.jsx(C.CollectionIdContext.Provider,{value:se,children:e.jsx(p.ProductsScreen,{hideInCollectionSearch:b.hideInCollectionSearch,customCollectionRestriction:b.customCollectionRestriction,productFetcher:b.productFetcher,setScreen:oe,storeId:f,appType:X,data:Z[se],collectionsDispatch:ee,selectedCollectionsDispatch:ke,selectedData:ve,setSaveDisabled:he,searchInCollectionFetcher:b.searchInCollectionFetcher,hideProductCheckbox:R,outOfStockAction:D,hideVariantCheckbox:q,selectProductsFromCustomCollection:E,renderWithoutModal:w,pickerType:M,hideProductVariants:V,fbStatusFetcher:b.fbStatusFetcher,onProductDetailClick:e=>{Fe(!0),Te(e)},showProductDetailInfoIcon:K,scrollContainerRef:Ie})}),"view"===te&&e.jsx(g.SelectedScreen,{selectedCollections:ve||{},selectedCollectionsDispatch:ke,setScreen:oe,collections:Z,hideProductVariants:V,outOfStockAction:D,storeId:f,appType:X,fbStatusFetcher:b.fbStatusFetcher}),"rearrange"===te&&e.jsx(S.RearrangeScreen,{selectedCollections:ve||{},selectedCollectionsDispatch:ke,setScreen:oe,outOfStockAction:D,rearrangeViewType:"grid"===ce?"list":"grid",scrollContainerRef:Ie,storeId:f,appType:X,fbStatusFetcher:b.fbStatusFetcher}),"searchProducts"===te&&e.jsx(y.SearchScreen,{customCollectionRestriction:b.customCollectionRestriction,selectedCollections:ve||{},searchedCollections:be||{},searchedCollectionsDispatch:fe,selectedCollectionsDispatch:ke,setScreen:oe,collections:Z,onBackPress:()=>{ye(""),fe({type:"set",data:{collections:{},products:{}}})},pickerType:M,hideProductCheckbox:R,hideProductVariants:V,hideVariantCheckbox:q,storeId:f,appType:X,fbStatusFetcher:b.fbStatusFetcher,setCollectionId:ne,setSelectedCollectionId:le,renderWithoutModal:w,hideCollectionCheckbox:T,outOfStockAction:D,limit:P,exactLimit:F})]})]});return e.jsx(e.Fragment,{children:w?e.jsxs(e.Fragment,{children:[Ee,U.renderFooter?e.jsxs(m.StyledFooterForNonModal,{children:[De(),e.jsx(n.Button,{buttonText:qe(U.primaryButtonText),disabled:!U.isLoading&&(ue||pe<1||F&&pe<F||!F&&P&&pe>P)||U.primaryButtonDisabled,isLoading:U.isLoading,onClick:()=>{b.onAdd(ve,pe),Re(),oe([x.ScreenName.Collections,x.ScreenName.RearrangeProducts].includes(z)?z:x.ScreenName.Collections)}})]}):e.jsx(e.Fragment,{}),Oe&&Pe?e.jsx(h.ProductInfoOverlay,{productData:Pe,outOfStockAction:D,useDynamicInfoImageSize:b.useDynamicInfoImageSize,onClose:()=>{Fe(!1)}}):e.jsx(e.Fragment,{})]}):e.jsxs(l.StyledModal,{zIndex:O,open:I,onClose:()=>{null==k||k(),Re()},headingTitle:L||("collections"===te||"products"===te?"Select Products":"view"===te?"Selected Products":"searchProducts"===te?"Searched Results":"rearrange"===te?"Rearrange Products":void 0),headingSubtitle:Q,footerShadow:!0,centralContainerStyles:{width:A||"600px",left:B||"auto"},headerRightCustomElement:G?e.jsx("div",{style:{cursor:"pointer",display:"flex"},onClick:k,children:e.jsx(s.default,{width:20,height:20,color:r.COLORS.content.secondary})}):e.jsx(e.Fragment,{}),footerContainerStyle:b.stickyFooter?{position:"absolute",bottom:0,left:0,width:"100%",zIndex:9,background:r.COLORS.surface.standard}:void 0,primaryButton:Y?(e=>Object.assign(Object.assign({},e),{disabled:!e.isLoading&&(ue||pe<1||F&&pe<F||!F&&P&&pe>P)||e.disabled,onClick:()=>{b.onAdd(ve,pe),Re(),oe([x.ScreenName.Collections,x.ScreenName.RearrangeProducts].includes(z)?z:x.ScreenName.Collections)}}))(Y):{buttonText:qe(),disabled:ue||pe<1||F&&pe<F||!F&&P&&pe>P||!1,onClick:()=>{b.onAdd(ve,pe),Re()}},secondaryButton:J?(e=>Object.assign(Object.assign({},e),{disabled:ue||pe<1||F&&pe<F||!F&&P&&pe>P||!1,onClick:()=>{const e=j.updateAllVariantsForSelectedProducts(ve,Z,be);b.onAdd(e,pe,!0)}}))(J):void 0,wrapperStyle:b.stickyFooter?{height:"calc(100vh - 168px)"}:void 0,footerLeftCustomElement:N?e.jsx(e.Fragment,{}):De(),hideCrossButton:Oe||G,children:[Ee,Oe&&Pe?e.jsx(h.ProductInfoOverlay,{productData:Pe,useDynamicInfoImageSize:b.useDynamicInfoImageSize,outOfStockAction:D,onClose:()=>{Fe(!1)}}):e.jsx(e.Fragment,{})]})})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("@bikdotai/bik-models/growth/models/bik-store"),o=require("../../assets/icons/search.svg.js"),c=require("react"),r=require("../../constants/Theme.js"),s=require("../../assets/icons/cross.svg.js"),n=require("../button/Button.js"),i=require("../input/Input.js"),l=require("../modals/styledModal.js"),a=require("../spinner/Spinner.js"),d=require("../tag/Tag.js"),u=require("./collectionScreen.js"),h=require("./productInfoOverlay.js"),p=require("./productScreen.js"),S=require("./rearrangeScreen.js"),C=require("./reducers.js"),y=require("./searchScreen.js"),g=require("./selectedScreen.js"),m=require("./style.js"),x=require("./type.js"),j=require("./utility.js");exports.ProductPickerModal=b=>{const{storeId:f,selectedItems:v,onClose:k,visible:I,zIndex:O,exactLimit:F,limit:P,hideCollectionCheckbox:T,hideProductCheckbox:R,outOfStockAction:D=x.OUT_OF_STOCK_ACTION.BLUR,hideVariantCheckbox:q,selectProductsFromCustomCollection:E,hideSelectionCount:N,title:L,width:A,left:B,renderWithoutModal:w,onClickSave:$,pickerType:M,hideProductVariants:V=!1,startupScreen:z=x.ScreenName.Collections,rearrangeEnabled:_,selectSingleItem:H=!1,showProductDetails:K,containerStyle:W,crossButtonInsideHeader:G=!1,footerForNonModal:U={},primaryButton:Y,secondaryButton:J,subtitle:Q}=b,X=b.appType||t.ApplicationType.BIK,[Z,ee]=c.useReducer(C.collectionsReducer,{}),[te,oe]=c.useState([x.ScreenName.Collections,x.ScreenName.RearrangeProducts].includes(z)?z:x.ScreenName.Collections),[ce,re]=c.useState("grid"),[se,ne]=c.useState(""),[ie,le]=c.useState(""),[ae,de]=c.useState(0),[ue,he]=c.useState(!1),[pe,Se]=c.useState(0),[Ce,ye]=c.useState(""),[ge,me]=c.useState(!1),[xe,je]=c.useState(!1),[be,fe]=c.useReducer(C.searchReducer,{collections:{},products:{}}),[ve,ke]=c.useReducer(C.selectedColectionsReducer,Object.keys(v).length>0?v:{}),Ie=c.useRef(null),[Oe,Fe]=c.useState(!1),[Pe,Te]=c.useState();c.useEffect((()=>{he(!0),je(!0),b.collectionFetcher(ae,f,X).then((e=>{ee({type:"fetched",data:(null==e?void 0:e.collections)||{}}),he(!1),de((e=>e+1)),je(!1)})).catch()}),[]),c.useEffect((()=>{let e=0;"COLLECTION"===M?e=Object.keys(ve||{}).filter((e=>"isCustom"!==e)).length:V?Object.keys(ve||[]).forEach((t=>{var o;Object.keys((null===(o=ve[t])||void 0===o?void 0:o.products)||[]).forEach((o=>{var c;"-1"!==t&&ve[-1]&&(null===(c=ve[-1].products)||void 0===c?void 0:c[o])||(e+=1)}))})):Object.keys(ve||[]).forEach((t=>{var o;Object.keys((null===(o=ve[t])||void 0===o?void 0:o.products)||[]).forEach((o=>{var c,r;Object.keys((null===(r=null===(c=ve[t].products)||void 0===c?void 0:c[o])||void 0===r?void 0:r.variants)||[]).forEach((()=>{e+=1}))}))})),Se(e)}),[Z,ve,V,M]),c.useEffect((()=>{ie&&(he(!0),b.productFetcher(ie,f,X).then((e=>{Object.keys(e).length&&ee({type:"productsFetched",data:{collectionId:ie,products:e}}),he(!1)})).catch())}),[ie]),c.useEffect((()=>{const e=setTimeout((()=>{"rearrange"!==te&&(Ce.length||"collections"!==te)&&(Ce.length?(me(!0),b.searchFetcher(f,Ce,X).then((e=>{"collections"in e&&"products"in e?(fe({type:"set",data:e}),ee({type:"searched",data:e.collections}),ee({type:"searched",data:e.products})):(fe({type:"set",data:{collections:{},products:e}}),ee({type:"searched",data:e})),oe("searchProducts"),he(!1),me(!1)}))):oe("collections"))}),800);return()=>clearTimeout(e)}),[Ce]),c.useEffect((()=>{$&&(b.onAdd(ve,pe),Re())}),[$]),c.useEffect((()=>{H&&Object.keys(ve||{}).length&&pe&&(b.onAdd(ve,pe),Re())}),[H,ve,pe]);const Re=()=>{ke({type:"reset",data:{}})},De=()=>{let t,o;return"COLLECTION"===M?(t="collection",o="collections"):V?(t="product",o="products"):(t="variant",o="variants"),F&&pe>F?e.jsx(d.Tag,{tagText:`You can only select ${F} ${1===F?t:o}`,type:"negative"}):P&&pe>P?e.jsx(d.Tag,{tagText:`You can only select ${P} ${1===P?t:o}`,type:"negative"}):pe>0?e.jsx(n.Button,{onClick:()=>{oe(_?x.ScreenName.RearrangeProducts:x.ScreenName.SelectedProducts)},buttonText:F?`${pe}/${F} ${1===pe?t:o} selected`:`${pe} ${1===pe?t:o} selected`,buttonType:["rearrange","view"].includes(te)?"tertiaryGray":"tertiary",disabled:["rearrange","view"].includes(te)}):e.jsx(n.Button,{disabled:!0,buttonText:F?`${pe}/${F} ${1===F?t:o} selected`:`${pe} ${1===pe?t:o} selected`,buttonType:"tertiaryGray"})},qe=e=>ue?"Loading...":te===x.ScreenName.RearrangeProducts?null!=e?e:"Done":null!=e?e:"Add",Ee=e.jsxs(m.ContainerStyle,{style:null!=W?W:{},children:[b.postHeader&&e.jsx("div",{style:{padding:"0 24px"},children:b.postHeader}),!b.hideGlobalSearch&&e.jsx(e.Fragment,{children:("collections"===te||"searchProducts"===te)&&e.jsx("div",{style:{padding:w?"8px 16px":"12px 24px",borderBottom:"1px solid #E0E0E0"},children:e.jsx(i.Input,{placeholder:"Search using ID, Name or SKU ID",noKeyDownChange:!0,noErrorHint:!0,rightIcon:{icon:()=>ge?e.jsx(a.Spinner,{size:"small",color:r.COLORS.content.primary}):e.jsx(o.default,{})},id:"listInput",height:"24px",type:"text",value:Ce,onChangeText:e=>{e.length&&e.trim().length?ye(e):ye("")}})})}),e.jsxs(m.ScrollContainerStyle,{ref:Ie,screenName:te,children:["collections"===te&&e.jsx(u.CollectionsScreen,{customCollectionRestriction:b.customCollectionRestriction,dataLoading:xe,collections:Z,selectedCollectionsDispatch:ke,setCollectionId:ne,setSelectedCollectionId:le,setScreen:oe,selectedCollections:ve,collectionFetcher:b.collectionFetcher,storeId:f,appType:X,collectionsDispatch:ee,setSaveDisabled:he,pagingControls:{curPage:ae,setCurPage:de},hideCollectionCheckbox:T,renderWithoutModal:w,pickerType:M,scrollContainerRef:Ie,limit:P,exactLimit:F}),"products"===te&&se&&e.jsx(C.CollectionIdContext.Provider,{value:se,children:e.jsx(p.ProductsScreen,{hideInCollectionSearch:b.hideInCollectionSearch,customCollectionRestriction:b.customCollectionRestriction,productFetcher:b.productFetcher,setScreen:oe,storeId:f,appType:X,data:Z[se],collectionsDispatch:ee,selectedCollectionsDispatch:ke,selectedData:ve,setSaveDisabled:he,searchInCollectionFetcher:b.searchInCollectionFetcher,hideProductCheckbox:R,outOfStockAction:D,hideVariantCheckbox:q,selectProductsFromCustomCollection:E,renderWithoutModal:w,pickerType:M,hideProductVariants:V,fbStatusFetcher:b.fbStatusFetcher,onProductDetailClick:e=>{Fe(!0),Te(e)},showProductDetailInfoIcon:K,scrollContainerRef:Ie})}),"view"===te&&e.jsx(g.SelectedScreen,{selectedCollections:ve||{},selectedCollectionsDispatch:ke,setScreen:oe,collections:Z,hideProductVariants:V,outOfStockAction:D,storeId:f,appType:X,fbStatusFetcher:b.fbStatusFetcher}),"rearrange"===te&&e.jsx(S.RearrangeScreen,{selectedCollections:ve||{},selectedCollectionsDispatch:ke,setScreen:oe,outOfStockAction:D,rearrangeViewType:"grid"===ce?"list":"grid",scrollContainerRef:Ie,storeId:f,appType:X,fbStatusFetcher:b.fbStatusFetcher}),"searchProducts"===te&&e.jsx(y.SearchScreen,{customCollectionRestriction:b.customCollectionRestriction,selectedCollections:ve||{},searchedCollections:be||{},searchedCollectionsDispatch:fe,selectedCollectionsDispatch:ke,setScreen:oe,collections:Z,onBackPress:()=>{ye(""),fe({type:"set",data:{collections:{},products:{}}})},pickerType:M,hideProductCheckbox:R,hideProductVariants:V,hideVariantCheckbox:q,storeId:f,appType:X,fbStatusFetcher:b.fbStatusFetcher,setCollectionId:ne,setSelectedCollectionId:le,renderWithoutModal:w,hideCollectionCheckbox:T,outOfStockAction:D,limit:P,exactLimit:F})]})]});return e.jsx(e.Fragment,{children:w?e.jsxs(e.Fragment,{children:[Ee,U.renderFooter?e.jsxs(m.StyledFooterForNonModal,{children:[De(),e.jsx(n.Button,{buttonText:qe(U.primaryButtonText),disabled:!U.isLoading&&(ue||pe<1||F&&pe<F||!F&&P&&pe>P)||U.primaryButtonDisabled,isLoading:U.isLoading,onClick:()=>{b.onAdd(ve,pe),Re(),oe([x.ScreenName.Collections,x.ScreenName.RearrangeProducts].includes(z)?z:x.ScreenName.Collections)}})]}):e.jsx(e.Fragment,{}),Oe&&Pe?e.jsx(h.ProductInfoOverlay,{productData:Pe,outOfStockAction:D,useDynamicInfoImageSize:b.useDynamicInfoImageSize,onClose:()=>{Fe(!1)}}):e.jsx(e.Fragment,{})]}):e.jsxs(l.StyledModal,{zIndex:O,open:I,onClose:()=>{null==k||k(),Re()},headingTitle:L||("collections"===te||"products"===te?"Select Products":"view"===te?"Selected Products":"searchProducts"===te?"Searched Results":"rearrange"===te?"Rearrange Products":void 0),headingSubtitle:Q,footerShadow:!0,centralContainerStyles:{width:A||"600px",left:B||"auto"},headerRightCustomElement:G?e.jsx("div",{style:{cursor:"pointer",display:"flex"},onClick:k,children:e.jsx(s.default,{width:20,height:20,color:r.COLORS.content.secondary})}):e.jsx(e.Fragment,{}),footerContainerStyle:b.stickyFooter?{position:"absolute",bottom:0,left:0,width:"100%",zIndex:9,background:r.COLORS.surface.standard}:void 0,primaryButton:Y?(e=>Object.assign(Object.assign({},e),{disabled:!e.isLoading&&(ue||pe<1||F&&pe<F||!F&&P&&pe>P)||e.disabled,onClick:()=>{b.onAdd(ve,pe),Re(),oe([x.ScreenName.Collections,x.ScreenName.RearrangeProducts].includes(z)?z:x.ScreenName.Collections)}}))(Y):{buttonText:qe(),disabled:ue||pe<1||F&&pe<F||!F&&P&&pe>P||!1,onClick:()=>{b.onAdd(ve,pe),Re()}},secondaryButton:J?(e=>Object.assign(Object.assign({},e),{disabled:ue||pe<1||F&&pe<F||!F&&P&&pe>P||!1,onClick:()=>{const e=j.updateAllVariantsForSelectedProducts(ve,Z,be);b.onAdd(e,pe,!0)}}))(J):void 0,wrapperStyle:b.stickyFooter?{height:"calc(100vh - 168px)"}:void 0,footerLeftCustomElement:N?e.jsx(e.Fragment,{}):De(),hideCrossButton:Oe||G,children:[Ee,Oe&&Pe?e.jsx(h.ProductInfoOverlay,{productData:Pe,useDynamicInfoImageSize:b.useDynamicInfoImageSize,outOfStockAction:D,onClose:()=>{Fe(!1)}}):e.jsx(e.Fragment,{})]})})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../constants/Theme.js"),i=require("../../assets/icons/info.svg.js"),o=require("../checkBox/CheckBox.js"),c=require("../icon-button/IconButton.js"),d=require("../shimmer-image/ShimmerImage.js"),r=require("../tooltips/Tooltip.js"),l=require("../TypographyStyle.js"),n=require("./constants.js"),a=require("./helpers/ProductHelper.js"),s=require("./ProductPickerTag.js"),u=require("./style.js"),v=require("./utility.js");const p=n=>{const{isVariant:p,data:h,productId:y,collectionId:I,variantId:P,isSelected:j,selectedCollectionsDispatch:x,viewOnly:k,upliftAdditions:C,isPartiallyChecked:g,hideProductCheckbox:S,outOfStockAction:f,hideVariantCheckbox:m,hideProductVariants:b,pickerType:O="PRODUCT",onProductDetailClick:T,showProductDetailInfoIcon:D,currencyAndPrice:V}=n,{isVariantForProductPickerTag:q,dataForProductPickerTag:w,tagText:A,tagType:U}=a.ProductHelper.getDataForProductPickerTag(h,p,f),B=v.getSkuId(h,p);return e.jsxs(u.ProductCardStyle,{isVariant:p,onClick:e=>{if(e.stopPropagation(),"PRODUCT"===O&&(S||m)){const e=Object.keys(h.variants);b?j?x({type:"productUnselected",data:{productId:y,collectionId:I}}):C("productSelected",{productId:y,variantId:P,collectionId:I,product:h}):j?x({type:"variantUnselected",data:{productId:y,variantId:P,collectionId:I}}):C("variantSelected",{productId:y,variantId:P||e[0],collectionId:I,variant:h})}},isActive:j,children:[p&&!k&&!m||!p&&!k&&!S?e.jsx(o.CheckBox,{isChecked:j,isPartiallyChecked:g||!1,onValueChange:function(e,t,i){null==i||i.stopPropagation(),p?e?C(b?"productSelected":"variantSelected",{productId:y,variantId:P,collectionId:I,variant:h}):x({type:b?"productUnselected":"variantUnselected",data:{productId:y,variantId:P,collectionId:I}}):e?C("productSelected",{productId:y,collectionId:I,product:h}):x({type:"productUnselected",data:{productId:y,collectionId:I}})}}):e.jsx(e.Fragment,{}),e.jsx("div",{children:e.jsx(d.ShimmerImage,{width:40,height:40,imageUrl:h.image,alt:"Item",borderRadius:4})}),e.jsxs("div",{style:{display:"flex",flexDirection:"column",flex:1},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:16},children:[e.jsx(r.Tooltip,{variant:"light",body:h.name,placement:"bottom",delay:400,children:e.jsx(l.TitleSmall,{style:{flex:1},numberOfLines:1,children:h.name})}),e.jsxs(u.ProductInfo,{children:[e.jsx(s.ProductPickerTag,{isVariant:q,data:w,tagText:A,tagType:U}),D&&e.jsx(c.IconButton,{onClick:()=>{null==T||T(h)},Icon:()=>e.jsx(i.default,{width:20,height:20,color:t.COLORS.content.placeholder})})]})]}),e.jsxs(u.ProductSubTitle,{children:[!(null==w?void 0:w.fbStatus)&&q||A?null:e.jsx(l.BodyCaption,{color:t.COLORS.content.secondary,children:V}),B&&e.jsx(r.Tooltip,{body:B,placement:"top",children:e.jsx(u.SKUIDBadge,{children:e.jsx(u.EllipsedBodyTiny,{children:`SKU ID: ${B}`})})})]})]})]})};exports.ProductCard=p,exports.ProductGroup=t=>{var i,o,c,d,r,l,a,s,u;const{collectionId:h,productId:y,data:I,selectedData:P,selectedCollectionsDispatch:j,viewOnly:x,upliftAdditions:k,isProductPartiallyChecked:C,hideProductCheckbox:g,outOfStockAction:S,hideVariantCheckbox:f,hideProductVariants:m,pickerType:b,onProductDetailClick:O,showProductDetailInfoIcon:T}=t,D=e=>{var t,i,o,c,d,r;if(!(null===(i=null===(t=null==P?void 0:P[h])||void 0===t?void 0:t.products)||void 0===i?void 0:i[y]))return!1;return!!(null===(r=null===(d=null===(c=null===(o=null==P?void 0:P[h])||void 0===o?void 0:o.products)||void 0===c?void 0:c[y])||void 0===d?void 0:d.variants)||void 0===r?void 0:r[e])},V=m||!v.shouldShowVariant(I)?`${I.currency&&null!==(i=n.CurrencySymbols[I.currency])&&void 0!==i?i:""}${null!==(u=null!==(r=null===(d=null===(c=Object.values(null!==(o=I.variants)&&void 0!==o?o:{}))||void 0===c?void 0:c[0])||void 0===d?void 0:d.price)&&void 0!==r?r:null===(s=null===(a=Object.values(null!==(l=I.variants)&&void 0!==l?l:{}))||void 0===a?void 0:a[0])||void 0===s?void 0:s.actualPrice)&&void 0!==u?u:""}`:"";return e.jsxs("div",{children:[e.jsx(p,{isVariant:!1,data:I,productId:y,collectionId:h,isSelected:(()=>{var e,t;return!!(null===(t=null===(e=null==P?void 0:P[h])||void 0===e?void 0:e.products)||void 0===t?void 0:t[y])})(),isPartiallyChecked:C,selectedCollectionsDispatch:j,upliftAdditions:k,viewOnly:x,hideProductCheckbox:g,hideVariantCheckbox:f,hideProductVariants:m,pickerType:b,outOfStockAction:S,onProductDetailClick:O,showProductDetailInfoIcon:T,currencyAndPrice:V},y),m?null:v.shouldShowVariant(I)&&Object.keys(I.variants||[]).map(t=>{var i,o,c,d,r,l,a;const s=`${I.currency&&null!==(i=n.CurrencySymbols[I.currency])&&void 0!==i?i:""}${null!==(a=null!==(d=null===(c=null===(o=I.variants)||void 0===o?void 0:o[t])||void 0===c?void 0:c.price)&&void 0!==d?d:null===(l=null===(r=I.variants)||void 0===r?void 0:r[t])||void 0===l?void 0:l.actualPrice)&&void 0!==a?a:""}`;return e.jsx(p,{isVariant:!0,hideVariantCheckbox:f,data:Object.assign(Object.assign({},I.variants[t]),{currency:I.currency}),variantId:t,productId:y,viewOnly:x,upliftAdditions:k,collectionId:h,isSelected:D(t),selectedCollectionsDispatch:j,outOfStockAction:S,onProductDetailClick:O,showProductDetailInfoIcon:T,currencyAndPrice:s},t)})]})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../constants/Theme.js"),i=require("../../assets/icons/info.svg.js"),o=require("../checkBox/CheckBox.js"),c=require("../icon-button/IconButton.js"),d=require("../shimmer-image/ShimmerImage.js"),r=require("../tooltips/Tooltip.js"),l=require("../TypographyStyle.js"),n=require("./constants.js"),a=require("./helpers/ProductHelper.js"),s=require("./ProductPickerTag.js"),u=require("./style.js"),v=require("./utility.js");const p=n=>{const{isVariant:p,data:h,productId:y,collectionId:I,variantId:P,isSelected:j,selectedCollectionsDispatch:x,viewOnly:k,upliftAdditions:C,isPartiallyChecked:g,hideProductCheckbox:S,outOfStockAction:f,hideVariantCheckbox:m,hideProductVariants:b,pickerType:O="PRODUCT",onProductDetailClick:T,showProductDetailInfoIcon:D,currencyAndPrice:V}=n,{isVariantForProductPickerTag:q,dataForProductPickerTag:w,tagText:A,tagType:U}=a.ProductHelper.getDataForProductPickerTag(h,p,f),B=v.getSkuId(h,p);return e.jsxs(u.ProductCardStyle,{isVariant:p,onClick:e=>{if(e.stopPropagation(),"PRODUCT"===O&&(S||m)){const e=Object.keys(h.variants);b?j?x({type:"productUnselected",data:{productId:y,collectionId:I}}):C("productSelected",{productId:y,variantId:P,collectionId:I,product:h}):j?x({type:"variantUnselected",data:{productId:y,variantId:P,collectionId:I}}):C("variantSelected",{productId:y,variantId:P||e[0],collectionId:I,variant:h})}},isActive:j,children:[p&&!k&&!m||!p&&!k&&!S?e.jsx(o.CheckBox,{isChecked:j,isPartiallyChecked:g||!1,onValueChange:function(e,t,i){null==i||i.stopPropagation(),p?e?C(b?"productSelected":"variantSelected",{productId:y,variantId:P,collectionId:I,variant:h}):x({type:b?"productUnselected":"variantUnselected",data:{productId:y,variantId:P,collectionId:I}}):e?C("productSelected",{productId:y,collectionId:I,product:h}):x({type:"productUnselected",data:{productId:y,collectionId:I}})}}):e.jsx(e.Fragment,{}),e.jsx("div",{children:e.jsx(d.ShimmerImage,{width:40,height:40,imageUrl:h.image,alt:"Item",borderRadius:4})}),e.jsxs("div",{style:{display:"flex",flexDirection:"column",flex:1},children:[e.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:16},children:[e.jsx(r.Tooltip,{variant:"light",body:h.name,placement:"bottom",delay:400,children:e.jsx(l.TitleSmall,{style:{flex:1},numberOfLines:1,children:h.name})}),e.jsxs(u.ProductInfo,{children:[e.jsx(s.ProductPickerTag,{isVariant:q,data:w,tagText:A,tagType:U}),D&&e.jsx(c.IconButton,{onClick:()=>{null==T||T(h)},Icon:()=>e.jsx(i.default,{width:20,height:20,color:t.COLORS.content.placeholder})})]})]}),e.jsxs(u.ProductSubTitle,{children:[!(null==w?void 0:w.fbStatus)&&q||A?null:e.jsx(l.BodyCaption,{color:t.COLORS.content.secondary,children:V}),B&&e.jsx(r.Tooltip,{body:B,placement:"top",children:e.jsx(u.SKUIDBadge,{children:e.jsx(u.EllipsedBodyTiny,{children:`SKU ID: ${B}`})})})]})]})]})};exports.ProductCard=p,exports.ProductGroup=t=>{var i,o,c,d,r,l,a,s,u;const{collectionId:h,productId:y,data:I,selectedData:P,selectedCollectionsDispatch:j,viewOnly:x,upliftAdditions:k,isProductPartiallyChecked:C,hideProductCheckbox:g,outOfStockAction:S,hideVariantCheckbox:f,hideProductVariants:m,pickerType:b,onProductDetailClick:O,showProductDetailInfoIcon:T}=t,D=e=>{var t,i,o,c,d,r;if(!(null===(i=null===(t=null==P?void 0:P[h])||void 0===t?void 0:t.products)||void 0===i?void 0:i[y]))return!1;return!!(null===(r=null===(d=null===(c=null===(o=null==P?void 0:P[h])||void 0===o?void 0:o.products)||void 0===c?void 0:c[y])||void 0===d?void 0:d.variants)||void 0===r?void 0:r[e])},V=m||!v.shouldShowVariant(I)?`${I.currency&&null!==(i=n.CurrencySymbols[I.currency])&&void 0!==i?i:""}${null!==(u=null!==(r=null===(d=null===(c=Object.values(null!==(o=I.variants)&&void 0!==o?o:{}))||void 0===c?void 0:c[0])||void 0===d?void 0:d.price)&&void 0!==r?r:null===(s=null===(a=Object.values(null!==(l=I.variants)&&void 0!==l?l:{}))||void 0===a?void 0:a[0])||void 0===s?void 0:s.actualPrice)&&void 0!==u?u:""}`:"";return e.jsxs("div",{children:[e.jsx(p,{isVariant:!1,data:I,productId:y,collectionId:h,isSelected:(()=>{var e,t;return!!(null===(t=null===(e=null==P?void 0:P[h])||void 0===e?void 0:e.products)||void 0===t?void 0:t[y])})(),isPartiallyChecked:C,selectedCollectionsDispatch:j,upliftAdditions:k,viewOnly:x,hideProductCheckbox:g,hideVariantCheckbox:f,hideProductVariants:m,pickerType:b,outOfStockAction:S,onProductDetailClick:O,showProductDetailInfoIcon:T,currencyAndPrice:V},y),m?null:v.shouldShowVariant(I)&&Object.keys(I.variants||[]).map((t=>{var i,o,c,d,r,l,a;const s=`${I.currency&&null!==(i=n.CurrencySymbols[I.currency])&&void 0!==i?i:""}${null!==(a=null!==(d=null===(c=null===(o=I.variants)||void 0===o?void 0:o[t])||void 0===c?void 0:c.price)&&void 0!==d?d:null===(l=null===(r=I.variants)||void 0===r?void 0:r[t])||void 0===l?void 0:l.actualPrice)&&void 0!==a?a:""}`;return e.jsx(p,{isVariant:!0,hideVariantCheckbox:f,data:Object.assign(Object.assign({},I.variants[t]),{currency:I.currency}),variantId:t,productId:y,viewOnly:x,upliftAdditions:k,collectionId:h,isSelected:D(t),selectedCollectionsDispatch:j,outOfStockAction:S,onProductDetailClick:O,showProductDetailInfoIcon:T,currencyAndPrice:s},t)}))]})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_left.svg.js"),r=require("../../assets/icons/box.svg.js"),o=require("../../assets/icons/search.svg.js"),c=require("lodash"),s=require("react"),n=require("../../constants/Theme.js"),i=require("../checkBox/CheckBox.js"),l=require("../icon-button/IconButton.js"),d=require("../InfiniteScroll/InfiniteScroll.js"),u=require("../input/Input.js"),a=require("../spinner/Spinner.js"),h=require("../TypographyStyle.js"),p=require("./emptyState.js"),j=require("./product.js"),v=require("./ProductPickerShimmer.js"),g=require("./reducers.js"),y=require("./style.js"),f=require("./type.js"),k=require("./utility.js");exports.ProductsScreen=C=>{var P,O;const{data:b,collectionsDispatch:x,selectedData:S,selectedCollectionsDispatch:I,productFetcher:m,storeId:q,setScreen:A,setSaveDisabled:D,hideInCollectionSearch:T,customCollectionRestriction:E,hideProductCheckbox:R,outOfStockAction:V=f.OUT_OF_STOCK_ACTION.BLUR,hideVariantCheckbox:L=!1,selectProductsFromCustomCollection:F=!1,pickerType:w,hideProductVariants:B,fbStatusFetcher:_,onProductDetailClick:U,showProductDetailInfoIcon:K,scrollContainerRef:M,appType:N}=C,H=s.useContext(g.CollectionIdContext),J=s.useRef(0),W=s.useRef(!1),[z,G]=s.useState(""),[Q,X]=s.useState(!1),[Y,Z]=s.useState(b),$=s.useRef(!0),ee=s.useRef(!1);s.useEffect(()=>{if($.current)return void($.current=!1);const e=setTimeout(()=>{z.length?(X(!0),C.searchInCollectionFetcher(q,H,z,N).then(e=>{const t=c.cloneDeep(b);t.products=e,Z(t);const r=k.getVariantIdsToFetchAtProductLevel(null!=e?e:{});re(r,null!=e?e:{},!0),D(!1),X(!1)})):Z(b)},800);return()=>clearTimeout(e)},[z]);s.useEffect(()=>{var e,t,r,o;ee.current=!1,J.current=Math.floor((null===(t=Object.keys(null!==(e=b.products)&&void 0!==e?e:{}))||void 0===t?void 0:t.length)/10);const c=k.getVariantIdsToFetchAtProductLevel(null!==(r=b.products)&&void 0!==r?r:{});re(c,null!==(o=b.products)&&void 0!==o?o:{})},[H]);const te=!!E&&b.isSmartCollection;s.useEffect(()=>{(null==b?void 0:b.products)||oe(10)},[]);const re=(e,t,r)=>{_||(r?k.markVariantsAsApprovedProductsLevel(t,x,H,Y,Z):k.markVariantsAsApprovedProductsLevel(t,x,H)),e.length>0&&_&&_(q,e,N).then(e=>{const o=Object.assign({},t);Object.keys(t).forEach(r=>{var c,s;Object.keys(null!==(s=null===(c=null==t?void 0:t[r])||void 0===c?void 0:c.variants)&&void 0!==s?s:{}).forEach(c=>{var s,n;const i=null===(s=null==t?void 0:t[r].variants)||void 0===s?void 0:s[c];i&&"REJECTED"===e[c]?i.fbStatus="REJECTED":i&&"APPROVED"===e[c]&&(i.fbStatus="APPROVED");const l=null===(n=null==o?void 0:o[r])||void 0===n?void 0:n.variants;l&&l[c]&&(l[c]=i)})}),r?(Z(e=>{const t=Object.assign({},e);return t.products=o,t}),x({type:"productsPaged",data:{collectionId:H,products:o}})):x({type:"productsPaged",data:{collectionId:H,products:o}})}).catch(e=>{r?k.markVariantsAsApprovedProductsLevel(t,x,H,Y,Z):k.markVariantsAsApprovedProductsLevel(t,x,H)})},oe=e=>{D(!0),X(!0),m(H,q,N,e,0).then(t=>{if(Object.keys(t).length||(ee.current=!0),Object.keys(t).length){Z(Object.assign(Object.assign({},Y),{products:t}));const e=k.getVariantIdsToFetchAtProductLevel(t);re(e,t),J.current=1}e||I({type:"selected",data:{id:H,val:Object.assign(Object.assign({},b),{products:t})}}),D(!1),X(!1)}).catch()},ce=(e,t)=>{const r=k.liftTheStateUp(t,b);I({type:e,data:Object.assign(Object.assign({},r),{isRestricted:E})})},se=!!(null==S?void 0:S[H])&&!!Object.keys(null!==(O=null===(P=null==S?void 0:S[H])||void 0===P?void 0:P.products)&&void 0!==O?O:{}).length;return e.jsxs("div",{children:[e.jsxs(y.ProductScreenHeader,{children:[e.jsx(l.IconButton,{Icon:t.default,height:16,onClick:()=>{A("collections")}}),e.jsx(h.BodyCaption,{style:{color:n.COLORS.content.secondary},children:b.name})]}),!T&&e.jsx("div",{style:{padding:16,height:"76px",borderBottom:"1px solid #E0E0E0"},children:e.jsx(u.Input,{noKeyDownChange:!0,noErrorHint:!0,rightIcon:{icon:()=>Q&&z.length?e.jsx(a.Spinner,{size:"small",color:n.COLORS.content.primary}):e.jsx(o.default,{})},id:"listInput",height:"24px",type:"text",value:z,onChangeText:e=>{e.length&&e.trim().length?G(e):G("")},placeholder:"Search using ID, Name or SKU ID"})}),Object.keys((null==Y?void 0:Y.products)||[]).length>0&&!te&&!z.length&&!R&&"-1"!==H&&e.jsxs(y.ProductScreenCollectionCardStyle,{children:[e.jsx(i.CheckBox,{isChecked:se,isPartiallyChecked:k.isCollectionPartiallyChecked(H,Y,S,B),onValueChange:function(e){e?oe():I({type:"unselected",data:{id:H}})}}),e.jsx("div",{style:{width:40,height:40},children:e.jsx(r.default,{})}),e.jsx(h.TitleRegular,{children:"All Products"})]}),e.jsx(d.InfiniteScroll,{hasData:!(Object.keys((null==Y?void 0:Y.products)||[]).length<10)&&!!Object.keys((null==Y?void 0:Y.products)||[]).length,fetchMore:()=>(W.current=!0,m(H,q,N,10,J.current).then(e=>{let t=!1;if(Object.keys(e).length||(t=!0),Object.keys(e).length){const t=Y;t.products=Object.assign(Object.assign({},Y.products),e),Z(Object.assign({},t));const r=k.getVariantIdsToFetchAtProductLevel(e);re(r,e)}return D(!1),W.current=!1,J.current+=1,t})),containerRef:M,children:Object.keys((null==Y?void 0:Y.products)||[]).length?Object.keys(Y.products||[]).map(t=>e.jsx(j.ProductGroup,{outOfStockAction:V,collectionId:H,isProductPartiallyChecked:k.isProductPartiallyChecked(H,t,S,Y,B),productId:t,data:Y.products[t],selectedData:S,selectedCollectionsDispatch:I,viewOnly:!F&&!!te,upliftAdditions:ce,hideProductCheckbox:R,hideVariantCheckbox:L,hideProductVariants:B,pickerType:w,onProductDetailClick:U,showProductDetailInfoIcon:K},t)):Q?e.jsx(v.ProductPickerShimmer,{limit:10}):e.jsx(p.EmptyState,{title:"No products to show",subtitle:z.length?"We couldn't find the product you were looking for":"We couldn’t find any product in this collection."})})]})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_left.svg.js"),r=require("../../assets/icons/box.svg.js"),o=require("../../assets/icons/search.svg.js"),c=require("lodash"),s=require("react"),n=require("../../constants/Theme.js"),i=require("../checkBox/CheckBox.js"),l=require("../icon-button/IconButton.js"),d=require("../InfiniteScroll/InfiniteScroll.js"),u=require("../input/Input.js"),a=require("../spinner/Spinner.js"),h=require("../TypographyStyle.js"),p=require("./emptyState.js"),j=require("./product.js"),v=require("./ProductPickerShimmer.js"),g=require("./reducers.js"),y=require("./style.js"),f=require("./type.js"),k=require("./utility.js");exports.ProductsScreen=C=>{var P,O;const{data:b,collectionsDispatch:x,selectedData:S,selectedCollectionsDispatch:I,productFetcher:m,storeId:q,setScreen:A,setSaveDisabled:D,hideInCollectionSearch:T,customCollectionRestriction:E,hideProductCheckbox:R,outOfStockAction:V=f.OUT_OF_STOCK_ACTION.BLUR,hideVariantCheckbox:L=!1,selectProductsFromCustomCollection:F=!1,pickerType:w,hideProductVariants:B,fbStatusFetcher:_,onProductDetailClick:U,showProductDetailInfoIcon:K,scrollContainerRef:M,appType:N}=C,H=s.useContext(g.CollectionIdContext),J=s.useRef(0),W=s.useRef(!1),[z,G]=s.useState(""),[Q,X]=s.useState(!1),[Y,Z]=s.useState(b),$=s.useRef(!0),ee=s.useRef(!1);s.useEffect((()=>{if($.current)return void($.current=!1);const e=setTimeout((()=>{z.length?(X(!0),C.searchInCollectionFetcher(q,H,z,N).then((e=>{const t=c.cloneDeep(b);t.products=e,Z(t);const r=k.getVariantIdsToFetchAtProductLevel(null!=e?e:{});re(r,null!=e?e:{},!0),D(!1),X(!1)}))):Z(b)}),800);return()=>clearTimeout(e)}),[z]);s.useEffect((()=>{var e,t,r,o;ee.current=!1,J.current=Math.floor((null===(t=Object.keys(null!==(e=b.products)&&void 0!==e?e:{}))||void 0===t?void 0:t.length)/10);const c=k.getVariantIdsToFetchAtProductLevel(null!==(r=b.products)&&void 0!==r?r:{});re(c,null!==(o=b.products)&&void 0!==o?o:{})}),[H]);const te=!!E&&b.isSmartCollection;s.useEffect((()=>{(null==b?void 0:b.products)||oe(10)}),[]);const re=(e,t,r)=>{_||(r?k.markVariantsAsApprovedProductsLevel(t,x,H,Y,Z):k.markVariantsAsApprovedProductsLevel(t,x,H)),e.length>0&&_&&_(q,e,N).then((e=>{const o=Object.assign({},t);Object.keys(t).forEach((r=>{var c,s;Object.keys(null!==(s=null===(c=null==t?void 0:t[r])||void 0===c?void 0:c.variants)&&void 0!==s?s:{}).forEach((c=>{var s,n;const i=null===(s=null==t?void 0:t[r].variants)||void 0===s?void 0:s[c];i&&"REJECTED"===e[c]?i.fbStatus="REJECTED":i&&"APPROVED"===e[c]&&(i.fbStatus="APPROVED");const l=null===(n=null==o?void 0:o[r])||void 0===n?void 0:n.variants;l&&l[c]&&(l[c]=i)}))})),r?(Z((e=>{const t=Object.assign({},e);return t.products=o,t})),x({type:"productsPaged",data:{collectionId:H,products:o}})):x({type:"productsPaged",data:{collectionId:H,products:o}})})).catch((e=>{r?k.markVariantsAsApprovedProductsLevel(t,x,H,Y,Z):k.markVariantsAsApprovedProductsLevel(t,x,H)}))},oe=e=>{D(!0),X(!0),m(H,q,N,e,0).then((t=>{if(Object.keys(t).length||(ee.current=!0),Object.keys(t).length){Z(Object.assign(Object.assign({},Y),{products:t}));const e=k.getVariantIdsToFetchAtProductLevel(t);re(e,t),J.current=1}e||I({type:"selected",data:{id:H,val:Object.assign(Object.assign({},b),{products:t})}}),D(!1),X(!1)})).catch()},ce=(e,t)=>{const r=k.liftTheStateUp(t,b);I({type:e,data:Object.assign(Object.assign({},r),{isRestricted:E})})},se=!!(null==S?void 0:S[H])&&!!Object.keys(null!==(O=null===(P=null==S?void 0:S[H])||void 0===P?void 0:P.products)&&void 0!==O?O:{}).length;return e.jsxs("div",{children:[e.jsxs(y.ProductScreenHeader,{children:[e.jsx(l.IconButton,{Icon:t.default,height:16,onClick:()=>{A("collections")}}),e.jsx(h.BodyCaption,{style:{color:n.COLORS.content.secondary},children:b.name})]}),!T&&e.jsx("div",{style:{padding:16,height:"76px",borderBottom:"1px solid #E0E0E0"},children:e.jsx(u.Input,{noKeyDownChange:!0,noErrorHint:!0,rightIcon:{icon:()=>Q&&z.length?e.jsx(a.Spinner,{size:"small",color:n.COLORS.content.primary}):e.jsx(o.default,{})},id:"listInput",height:"24px",type:"text",value:z,onChangeText:e=>{e.length&&e.trim().length?G(e):G("")},placeholder:"Search using ID, Name or SKU ID"})}),Object.keys((null==Y?void 0:Y.products)||[]).length>0&&!te&&!z.length&&!R&&"-1"!==H&&e.jsxs(y.ProductScreenCollectionCardStyle,{children:[e.jsx(i.CheckBox,{isChecked:se,isPartiallyChecked:k.isCollectionPartiallyChecked(H,Y,S,B),onValueChange:function(e){e?oe():I({type:"unselected",data:{id:H}})}}),e.jsx("div",{style:{width:40,height:40},children:e.jsx(r.default,{})}),e.jsx(h.TitleRegular,{children:"All Products"})]}),e.jsx(d.InfiniteScroll,{hasData:!(Object.keys((null==Y?void 0:Y.products)||[]).length<10)&&!!Object.keys((null==Y?void 0:Y.products)||[]).length,fetchMore:()=>(W.current=!0,m(H,q,N,10,J.current).then((e=>{let t=!1;if(Object.keys(e).length||(t=!0),Object.keys(e).length){const t=Y;t.products=Object.assign(Object.assign({},Y.products),e),Z(Object.assign({},t));const r=k.getVariantIdsToFetchAtProductLevel(e);re(r,e)}return D(!1),W.current=!1,J.current+=1,t}))),containerRef:M,children:Object.keys((null==Y?void 0:Y.products)||[]).length?Object.keys(Y.products||[]).map((t=>e.jsx(j.ProductGroup,{outOfStockAction:V,collectionId:H,isProductPartiallyChecked:k.isProductPartiallyChecked(H,t,S,Y,B),productId:t,data:Y.products[t],selectedData:S,selectedCollectionsDispatch:I,viewOnly:!F&&!!te,upliftAdditions:ce,hideProductCheckbox:R,hideVariantCheckbox:L,hideProductVariants:B,pickerType:w,onProductDetailClick:U,showProductDetailInfoIcon:K},t))):Q?e.jsx(v.ProductPickerShimmer,{limit:10}):e.jsx(p.EmptyState,{title:"No products to show",subtitle:z.length?"We couldn't find the product you were looking for":"We couldn’t find any product in this collection."})})]})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_left.svg.js"),r=require("react"),s=require("react-beautiful-dnd"),o=require("../../constants/Theme.js"),c=require("../icon-button/IconButton.js"),i=require("../TypographyStyle.js"),n=require("./emptyState.js"),a=require("./helpers/ProductHelper.js"),l=require("./style.js"),d=require("./utility.js"),u=require("./variantComponents.js");exports.RearrangeScreen=p=>{const{selectedCollections:S,selectedCollectionsDispatch:j,setScreen:h,rearrangeViewType:y,outOfStockAction:f,scrollContainerRef:x,storeId:q,fbStatusFetcher:C,appType:O}=p,[V,g]=r.useState(a.parseSelectedVariantsToArray(S));r.useEffect(()=>{g(a.parseSelectedVariantsToArray(S))},[S]),r.useEffect(()=>{var e;null===(e=null==x?void 0:x.current)||void 0===e||e.scrollTo({top:0}),d.fetchFbStatusCollection(S,q,O,j,C,"update")},[]);return e.jsxs(s.DragDropContext,{onDragEnd:e=>{if(!e.destination)return;const t=V,[r]=t.splice(e.source.index,1);t.splice(e.destination.index,0,r),t.forEach((e,t)=>{e.displayOrder=t}),g(t)},children:[e.jsxs(l.SelectedScreenHeader,{children:[e.jsx(c.IconButton,{Icon:t.default,width:16,height:16,color:o.COLORS.content.secondary,onClick:()=>{h("collections")}}),e.jsx(i.BodyCaption,{color:o.COLORS.content.secondary,children:"All Products"})]}),Object.keys(S).length>0?"list"===y?e.jsx(u.VariantsList,{selectedVariants:V,setSelectedVariants:g,selectedCollectionsDispatch:j,outOfStockAction:f}):e.jsx(u.VariantsGrid,{selectedVariants:V,setSelectedVariants:g,selectedCollectionsDispatch:j}):e.jsx(n.EmptyState,{title:"No Products Selected",subtitle:"Selected products will appear here"})]})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_left.svg.js"),r=require("react"),s=require("react-beautiful-dnd"),o=require("../../constants/Theme.js"),c=require("../icon-button/IconButton.js"),i=require("../TypographyStyle.js"),n=require("./emptyState.js"),a=require("./helpers/ProductHelper.js"),l=require("./style.js"),d=require("./utility.js"),u=require("./variantComponents.js");exports.RearrangeScreen=p=>{const{selectedCollections:S,selectedCollectionsDispatch:j,setScreen:h,rearrangeViewType:y,outOfStockAction:f,scrollContainerRef:x,storeId:q,fbStatusFetcher:C,appType:O}=p,[V,g]=r.useState(a.parseSelectedVariantsToArray(S));r.useEffect((()=>{g(a.parseSelectedVariantsToArray(S))}),[S]),r.useEffect((()=>{var e;null===(e=null==x?void 0:x.current)||void 0===e||e.scrollTo({top:0}),d.fetchFbStatusCollection(S,q,O,j,C,"update")}),[]);return e.jsxs(s.DragDropContext,{onDragEnd:e=>{if(!e.destination)return;const t=V,[r]=t.splice(e.source.index,1);t.splice(e.destination.index,0,r),t.forEach(((e,t)=>{e.displayOrder=t})),g(t)},children:[e.jsxs(l.SelectedScreenHeader,{children:[e.jsx(c.IconButton,{Icon:t.default,width:16,height:16,color:o.COLORS.content.secondary,onClick:()=>{h("collections")}}),e.jsx(i.BodyCaption,{color:o.COLORS.content.secondary,children:"All Products"})]}),Object.keys(S).length>0?"list"===y?e.jsx(u.VariantsList,{selectedVariants:V,setSelectedVariants:g,selectedCollectionsDispatch:j,outOfStockAction:f}):e.jsx(u.VariantsGrid,{selectedVariants:V,setSelectedVariants:g,selectedCollectionsDispatch:j}):e.jsx(n.EmptyState,{title:"No Products Selected",subtitle:"Selected products will appear here"})]})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_left.svg.js"),o=require("react"),l=require("../icon-button/IconButton.js"),i=require("../TypographyStyle.js"),c=require("./collectionScreen.js"),s=require("./emptyState.js"),r=require("./product.js"),d=require("./style.js"),n=require("./utility.js");exports.SearchScreen=u=>{var a;const{customCollectionRestriction:h,selectedCollections:p,searchedCollections:v,searchedCollectionsDispatch:C,selectedCollectionsDispatch:j,setScreen:y,collections:k,onBackPress:b,hideVariantCheckbox:x,pickerType:S,hideProductVariants:m,hideProductCheckbox:P,storeId:f,fbStatusFetcher:O,setCollectionId:g,setSelectedCollectionId:I,hideCollectionCheckbox:q,renderWithoutModal:T,outOfStockAction:D,appType:F,limit:B,exactLimit:V}=u;o.useEffect(()=>{var e;n.fetchFbStatusCollection(null!==(e=v.products)&&void 0!==e?e:{},f,F,C,O,"setProducts")},[null==v?void 0:v.products]);const w=!!h&&(null==p?void 0:p.isCustom),A=Object.keys(p||{}).filter(e=>"isCustom"!==e).length;return e.jsxs("div",{children:[e.jsxs(d.SelectedScreenHeader,{children:[e.jsx(l.IconButton,{Icon:t.default,onClick:()=>{y("collections"),b()}}),e.jsx(i.BodyCaption,{children:(null===(a=Object.keys(null==v?void 0:v.collections))||void 0===a?void 0:a.length)?"Searched Collections & Products":"Searched Products"})]}),e.jsx("div",{children:Object.keys(null==v?void 0:v.products).length||Object.keys(null==v?void 0:v.collections).length?e.jsxs(e.Fragment,{children:[e.jsx(e.Fragment,{children:Object.keys(null==v?void 0:v.collections).map(t=>{const o=!!(null==p?void 0:p[t]),l="COLLECTION"===S&&!o&&(!!V&&A>=V||!!B&&A>=B);return e.jsx(c.CollectionCard,{customCollectionRestriction:h,data:null==k?void 0:k[t],isDisabled:w&&!(null==p?void 0:p[t])||l,isChecked:o,isPartiallyChecked:n.isCollectionPartiallyChecked(t,null==k?void 0:k[t],p,m),selectedCollectionsDispatch:j,setCollectionId:g,setSelectedCollectionId:I,setScreen:y,id:t,hideCollectionCheckbox:q||"-1"===t,selectedCollections:p,renderWithoutModal:T,pickerType:S,usedInSearch:!0},t)})}),e.jsx(e.Fragment,{children:Object.keys(null==v?void 0:v.products).map(t=>{var o,l;return Object.keys((null===(l=null===(o=null==v?void 0:v.products)||void 0===o?void 0:o[t])||void 0===l?void 0:l.products)||[]).map(o=>{var l,i,c;let s=!1;return(null===(l=null==v?void 0:v.products)||void 0===l?void 0:l.isCustom)&&(s=!0),e.jsx(r.ProductGroup,{collectionId:t,upliftAdditions:(e,o)=>((e,t,o)=>{var l;const i=n.liftTheStateUp(o,null===(l=null==v?void 0:v.products)||void 0===l?void 0:l[e]);j({type:t,data:Object.assign(Object.assign({},i),{isRestricted:h})})})(t,e,o),productId:o,data:(null===(i=null==v?void 0:v.products)||void 0===i?void 0:i[t].products)[o],isProductPartiallyChecked:n.isProductPartiallyChecked(t,o,p,null===(c=v.products)||void 0===c?void 0:c[t],m),selectedData:p,selectedCollectionsDispatch:j,viewOnly:s,hideProductCheckbox:P,hideVariantCheckbox:x,hideProductVariants:m,pickerType:S,outOfStockAction:D},o)})})})]}):e.jsx(s.EmptyState,{title:"No search results found",subtitle:"We couldn’t find the product you were looking for."})})]})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_left.svg.js"),o=require("react"),l=require("../icon-button/IconButton.js"),i=require("../TypographyStyle.js"),c=require("./collectionScreen.js"),s=require("./emptyState.js"),r=require("./product.js"),d=require("./style.js"),n=require("./utility.js");exports.SearchScreen=u=>{var a;const{customCollectionRestriction:h,selectedCollections:p,searchedCollections:v,searchedCollectionsDispatch:C,selectedCollectionsDispatch:j,setScreen:y,collections:k,onBackPress:b,hideVariantCheckbox:x,pickerType:S,hideProductVariants:m,hideProductCheckbox:P,storeId:f,fbStatusFetcher:O,setCollectionId:g,setSelectedCollectionId:I,hideCollectionCheckbox:q,renderWithoutModal:T,outOfStockAction:D,appType:F,limit:B,exactLimit:V}=u;o.useEffect((()=>{var e;n.fetchFbStatusCollection(null!==(e=v.products)&&void 0!==e?e:{},f,F,C,O,"setProducts")}),[null==v?void 0:v.products]);const w=!!h&&(null==p?void 0:p.isCustom),A=Object.keys(p||{}).filter((e=>"isCustom"!==e)).length;return e.jsxs("div",{children:[e.jsxs(d.SelectedScreenHeader,{children:[e.jsx(l.IconButton,{Icon:t.default,onClick:()=>{y("collections"),b()}}),e.jsx(i.BodyCaption,{children:(null===(a=Object.keys(null==v?void 0:v.collections))||void 0===a?void 0:a.length)?"Searched Collections & Products":"Searched Products"})]}),e.jsx("div",{children:Object.keys(null==v?void 0:v.products).length||Object.keys(null==v?void 0:v.collections).length?e.jsxs(e.Fragment,{children:[e.jsx(e.Fragment,{children:Object.keys(null==v?void 0:v.collections).map((t=>{const o=!!(null==p?void 0:p[t]),l="COLLECTION"===S&&!o&&(!!V&&A>=V||!!B&&A>=B);return e.jsx(c.CollectionCard,{customCollectionRestriction:h,data:null==k?void 0:k[t],isDisabled:w&&!(null==p?void 0:p[t])||l,isChecked:o,isPartiallyChecked:n.isCollectionPartiallyChecked(t,null==k?void 0:k[t],p,m),selectedCollectionsDispatch:j,setCollectionId:g,setSelectedCollectionId:I,setScreen:y,id:t,hideCollectionCheckbox:q||"-1"===t,selectedCollections:p,renderWithoutModal:T,pickerType:S,usedInSearch:!0},t)}))}),e.jsx(e.Fragment,{children:Object.keys(null==v?void 0:v.products).map((t=>{var o,l;return Object.keys((null===(l=null===(o=null==v?void 0:v.products)||void 0===o?void 0:o[t])||void 0===l?void 0:l.products)||[]).map((o=>{var l,i,c;let s=!1;return(null===(l=null==v?void 0:v.products)||void 0===l?void 0:l.isCustom)&&(s=!0),e.jsx(r.ProductGroup,{collectionId:t,upliftAdditions:(e,o)=>((e,t,o)=>{var l;const i=n.liftTheStateUp(o,null===(l=null==v?void 0:v.products)||void 0===l?void 0:l[e]);j({type:t,data:Object.assign(Object.assign({},i),{isRestricted:h})})})(t,e,o),productId:o,data:(null===(i=null==v?void 0:v.products)||void 0===i?void 0:i[t].products)[o],isProductPartiallyChecked:n.isProductPartiallyChecked(t,o,p,null===(c=v.products)||void 0===c?void 0:c[t],m),selectedData:p,selectedCollectionsDispatch:j,viewOnly:s,hideProductCheckbox:P,hideVariantCheckbox:x,hideProductVariants:m,pickerType:S,outOfStockAction:D},o)}))}))})]}):e.jsx(s.EmptyState,{title:"No search results found",subtitle:"We couldn’t find the product you were looking for."})})]})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_left.svg.js"),r=require("react"),c=require("../icon-button/IconButton.js"),s=require("../TypographyStyle.js"),n=require("./emptyState.js"),i=require("./product.js"),o=require("./reducers.js"),u=require("./style.js"),l=require("./utility.js");exports.SelectedScreen=d=>{const{selectedCollections:a,selectedCollectionsDispatch:p,setScreen:j,collections:f,hideProductVariants:h=!1,outOfStockAction:y,storeId:S,fbStatusFetcher:v,appType:b}=d,x=r.useRef(0),g=r.useRef(null),[q,C]=r.useReducer(o.paginationReducer,{});r.useEffect(()=>{x.current=0;const e=l.paginateSelectedItems(a,10,0);C({type:"paginate",data:e}),l.fetchFbStatusCollection(e,S,b,C,v,"set"),x.current+=1},[]),r.useEffect(()=>{C({type:"filter",data:a})},[a]),r.useEffect(()=>{const e=new IntersectionObserver(e=>{if(e[0].isIntersecting&&x.current>0){const e=l.paginateSelectedItems(a,10,x.current);C({type:"paginate",data:e}),l.fetchFbStatusCollection(e,S,b,C,v,"update"),x.current+=1}},{threshold:1});return g.current&&e.observe(g.current),()=>{g.current&&e.unobserve(g.current)}},[g,a]);const I=a;return e.jsxs("div",{children:[e.jsxs(u.SelectedScreenHeader,{children:[e.jsx(c.IconButton,{Icon:t.default,onClick:()=>{j("collections")}}),e.jsx(s.BodyCaption,{children:"Selected Products"})]}),e.jsxs("div",{children:[Object.keys(q).length>0?e.jsx(e.Fragment,{children:Object.keys(q).map(t=>{var r;return Object.keys((null===(r=null==q?void 0:q[t])||void 0===r?void 0:r.products)||[]).map(r=>{let c=!1;return(null==I?void 0:I.isCustom)&&(c=!0),e.jsx(i.ProductGroup,{upliftAdditions:null,collectionId:t,productId:r,data:q[t].products[r],isProductPartiallyChecked:l.isProductPartiallyChecked(t,r,I,null==f?void 0:f[t],h),selectedData:I,selectedCollectionsDispatch:p,viewOnly:c,hideProductVariants:h,outOfStockAction:y},r)})})}):e.jsx(n.EmptyState,{title:"No Products Selected",subtitle:"Select products will appear here"}),e.jsx("div",{ref:g})]})]})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),t=require("../../assets/icons/arrow_left.svg.js"),r=require("react"),c=require("../icon-button/IconButton.js"),s=require("../TypographyStyle.js"),n=require("./emptyState.js"),i=require("./product.js"),o=require("./reducers.js"),u=require("./style.js"),l=require("./utility.js");exports.SelectedScreen=d=>{const{selectedCollections:a,selectedCollectionsDispatch:p,setScreen:j,collections:f,hideProductVariants:h=!1,outOfStockAction:y,storeId:S,fbStatusFetcher:v,appType:b}=d,x=r.useRef(0),g=r.useRef(null),[q,C]=r.useReducer(o.paginationReducer,{});r.useEffect((()=>{x.current=0;const e=l.paginateSelectedItems(a,10,0);C({type:"paginate",data:e}),l.fetchFbStatusCollection(e,S,b,C,v,"set"),x.current+=1}),[]),r.useEffect((()=>{C({type:"filter",data:a})}),[a]),r.useEffect((()=>{const e=new IntersectionObserver((e=>{if(e[0].isIntersecting&&x.current>0){const e=l.paginateSelectedItems(a,10,x.current);C({type:"paginate",data:e}),l.fetchFbStatusCollection(e,S,b,C,v,"update"),x.current+=1}}),{threshold:1});return g.current&&e.observe(g.current),()=>{g.current&&e.unobserve(g.current)}}),[g,a]);const I=a;return e.jsxs("div",{children:[e.jsxs(u.SelectedScreenHeader,{children:[e.jsx(c.IconButton,{Icon:t.default,onClick:()=>{j("collections")}}),e.jsx(s.BodyCaption,{children:"Selected Products"})]}),e.jsxs("div",{children:[Object.keys(q).length>0?e.jsx(e.Fragment,{children:Object.keys(q).map((t=>{var r;return Object.keys((null===(r=null==q?void 0:q[t])||void 0===r?void 0:r.products)||[]).map((r=>{let c=!1;return(null==I?void 0:I.isCustom)&&(c=!0),e.jsx(i.ProductGroup,{upliftAdditions:null,collectionId:t,productId:r,data:q[t].products[r],isProductPartiallyChecked:l.isProductPartiallyChecked(t,r,I,null==f?void 0:f[t],h),selectedData:I,selectedCollectionsDispatch:p,viewOnly:c,hideProductVariants:h,outOfStockAction:y},r)}))}))}):e.jsx(n.EmptyState,{title:"No Products Selected",subtitle:"Select products will appear here"}),e.jsx("div",{ref:g})]})]})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var o=require("lodash");function l(o,l,t){if(!o)return{};const i=Object.keys(o).slice(t,t+l),n={};return i.forEach(l=>{n[l]=o[l]}),n}const t=(o,l,t)=>{Object.keys(o).forEach(l=>{var t,i;const n=null!==(i=null===(t=o[l])||void 0===t?void 0:t.products)&&void 0!==i?i:{};Object.keys(n).forEach(t=>{var i,n,d,v;const s=null!==(v=null===(d=null===(n=null===(i=o[l])||void 0===i?void 0:i.products)||void 0===n?void 0:n[t])||void 0===d?void 0:d.variants)&&void 0!==v?v:{};Object.keys(s).forEach(i=>{var n,d,v,s;const e=null===(s=null===(v=null===(d=null===(n=o[l])||void 0===n?void 0:n.products)||void 0===d?void 0:d[t])||void 0===v?void 0:v.variants)||void 0===s?void 0:s[i];e&&!e.fbStatus&&(e.fbStatus="APPROVED")})})}),l({type:t,data:o})};exports.fetchFbStatusCollection=(o,l,i,n,d
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var o=require("lodash");function l(o,l,t){if(!o)return{};const i=Object.keys(o).slice(t,t+l),n={};return i.forEach((l=>{n[l]=o[l]})),n}const t=(o,l,t)=>{Object.keys(o).forEach((l=>{var t,i;const n=null!==(i=null===(t=o[l])||void 0===t?void 0:t.products)&&void 0!==i?i:{};Object.keys(n).forEach((t=>{var i,n,d,v;const s=null!==(v=null===(d=null===(n=null===(i=o[l])||void 0===i?void 0:i.products)||void 0===n?void 0:n[t])||void 0===d?void 0:d.variants)&&void 0!==v?v:{};Object.keys(s).forEach((i=>{var n,d,v,s;const e=null===(s=null===(v=null===(d=null===(n=o[l])||void 0===n?void 0:n.products)||void 0===d?void 0:d[t])||void 0===v?void 0:v.variants)||void 0===s?void 0:s[i];e&&!e.fbStatus&&(e.fbStatus="APPROVED")}))}))})),l({type:t,data:o})};exports.fetchFbStatusCollection=function(o,l,i,n,d){let v=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"paged";d||t(o,n,v);const s=(o=>{const l=[];return Object.keys(o).forEach((t=>{var i,n;const d=null!==(n=null===(i=o[t])||void 0===i?void 0:i.products)&&void 0!==n?n:{};Object.keys(d).forEach((i=>{var n,d,v,s;const e=null!==(s=null===(v=null===(d=null===(n=o[t])||void 0===n?void 0:n.products)||void 0===d?void 0:d[i])||void 0===v?void 0:v.variants)&&void 0!==s?s:{};Object.keys(e).forEach((n=>{var d,v,s,e;const u=null===(e=null===(s=null===(v=null===(d=o[t])||void 0===d?void 0:d.products)||void 0===v?void 0:v[i])||void 0===s?void 0:s.variants)||void 0===e?void 0:e[n];(null==u?void 0:u.fbStatus)||l.push(n)}))}))})),l})(o);s.length>0&&d&&d(l,s,i).then((l=>{const t=Object.assign({},o);Object.keys(t).forEach((o=>{var i,n;const d=null!==(n=null===(i=t[o])||void 0===i?void 0:i.products)&&void 0!==n?n:{};Object.keys(d).forEach((i=>{var n,d,v,s;const e=null!==(s=null===(v=null===(d=null===(n=t[o])||void 0===n?void 0:n.products)||void 0===d?void 0:d[i])||void 0===v?void 0:v.variants)&&void 0!==s?s:{};Object.keys(e).forEach((n=>{var d,v,s,e;const u=null===(e=null===(s=null===(v=null===(d=t[o])||void 0===d?void 0:d.products)||void 0===v?void 0:v[i])||void 0===s?void 0:s.variants)||void 0===e?void 0:e[n];u&&"REJECTED"===l[n]?u.fbStatus="REJECTED":u&&"APPROVED"===l[n]&&(u.fbStatus="APPROVED")}))}))})),n({type:v,data:t})})).catch((l=>{console.error("Error in fbStatusFetcher",l),t(o,n,v)}))},exports.getSkuId=(o,l)=>{var t;if(l)return o.skuId;const i=Object.values(null!==(t=null==o?void 0:o.variants)&&void 0!==t?t:{});return 1===i.length&&i[0].name.includes(o.name)?i[0].skuId:""},exports.getVariantIdsToFetchAtProductLevel=(o,l)=>{const t=[];return Object.keys(null!=o?o:{}).forEach((i=>{var n,d;const v=null!==(d=null===(n=null==o?void 0:o[i])||void 0===n?void 0:n.variants)&&void 0!==d?d:{};Object.keys(v).forEach((n=>{var d,v,s,e,u;let r;r=l?null===(s=null===(v=null===(d=null==l?void 0:l.products)||void 0===d?void 0:d[i])||void 0===v?void 0:v.variants)||void 0===s?void 0:s[n]:null===(u=null===(e=null==o?void 0:o[i])||void 0===e?void 0:e.variants)||void 0===u?void 0:u[n],(null==r?void 0:r.fbStatus)||t.push(n)}))})),t},exports.isCollectionPartiallyChecked=function(o,l,t){var i,n,d,v;let s=0,e=0;if(arguments.length>3&&void 0!==arguments[3]&&arguments[3]){const v=null!==(i=null==l?void 0:l.products)&&void 0!==i?i:{};s=Object.keys(v).length;const u=null!==(d=null===(n=t[o])||void 0===n?void 0:n.products)&&void 0!==d?d:{};e=Object.keys(u).length}else if(t[o]){const i=null==l?void 0:l.products;i&&Object.keys(i).forEach((o=>{var l;const t=null===(l=i[o])||void 0===l?void 0:l.variants;t&&Object.keys(t).forEach((o=>s+=1))}));const n=null===(v=t[o])||void 0===v?void 0:v.products;if(n&&Object.keys(n).forEach((o=>{var l;const t=null===(l=n[o])||void 0===l?void 0:l.variants;t&&Object.keys(t).forEach((o=>e+=1))})),s<=0&&e>0)return!1}return e>0&&s!==e},exports.isProductPartiallyChecked=(o,l,t,i,n)=>{var d,v,s,e,u,r,c,a,p,b,O,f,j,h,y,g,k,E,P;let D=0,S=0;if(null===(v=null===(d=null==t?void 0:t[o])||void 0===d?void 0:d.products)||void 0===v?void 0:v[l]){if(n)return!1;const d=(null===(u=null===(e=null===(s=null==t?void 0:t[o])||void 0===s?void 0:s.products)||void 0===e?void 0:e[l])||void 0===u?void 0:u.variants)||[];if(1===Object.keys(d).length)for(const i in d){const n=null===(c=null===(r=null==t?void 0:t[o])||void 0===r?void 0:r.products)||void 0===c?void 0:c[l],d=null===(O=null===(b=null===(p=null===(a=null==t?void 0:t[o])||void 0===a?void 0:a.products)||void 0===p?void 0:p[l])||void 0===b?void 0:b.variants)||void 0===O?void 0:O[i];if(null===(f=null==d?void 0:d.name)||void 0===f?void 0:f.includes(null!==(j=null==n?void 0:n.name)&&void 0!==j?j:""))return!1}if(null===(g=Object.keys((null===(y=null===(h=null==i?void 0:i.products)||void 0===h?void 0:h[l])||void 0===y?void 0:y.variants)||[]))||void 0===g||g.forEach((()=>S++)),Object.keys((null===(P=null===(E=null===(k=null==t?void 0:t[o])||void 0===k?void 0:k.products)||void 0===E?void 0:E[l])||void 0===P?void 0:P.variants)||[]).forEach((()=>D++)),D>0&&S!==D)return!0}return!1},exports.liftTheStateUp=(l,t)=>{const i=o.cloneDeep(t);if(delete i.products,(l=Object.assign(Object.assign({},l),{catalogOnlyData:i})).productId&&t.products){const n=o.cloneDeep(t.products[l.productId]);(null==n?void 0:n.variants)&&delete n.variants,l=Object.assign(Object.assign({},l),{catalogOnlyData:i,productOnlyData:n})}return l},exports.markVariantsAsApprovedProductsLevel=(o,l,t,i,n)=>{const d=Object.assign({},o);if(Object.keys(o).forEach((l=>{var t,i;Object.keys(null!==(i=null===(t=null==o?void 0:o[l])||void 0===t?void 0:t.variants)&&void 0!==i?i:{}).forEach((t=>{var i,n;const v=null===(i=null==o?void 0:o[l].variants)||void 0===i?void 0:i[t];v&&(v.fbStatus="APPROVED");const s=null===(n=null==d?void 0:d[l])||void 0===n?void 0:n.variants;s&&s[t]&&(s[t]=v)}))})),i&&n){const o=Object.assign({},i);o.products=d,n(o),l({type:"productsPaged",data:{collectionId:t,products:d}})}else l({type:"productsPaged",data:{collectionId:t,products:d}})},exports.paginateSelectedItems=function(o,t,i){var n;const d={};let v=0;for(const s in o)if(Object.prototype.hasOwnProperty.call(o,s)){const e=o[s],u=l(e.products,t,i-v);u&&Object.keys(u).length>0&&(d[s]=Object.assign(Object.assign({},e),{products:u})),v+=Object.keys(null!==(n=e.products)&&void 0!==n?n:{}).length}return d},exports.shouldShowVariant=o=>{const l=Object.keys(o.variants||[]);let t=!1;return!(l.length<=1)||(l.forEach((l=>{var i,n;t=null!==(n=null===(i=o.variants)||void 0===i?void 0:i[l].name.includes(o.name))&&void 0!==n&&n})),!t)},exports.updateAllVariantsForSelectedProducts=(l,t,i)=>Object.keys(l).reduce(((n,d)=>{var v;return d in t?(n[d]=Object.assign(Object.assign({},l[d]),{products:Object.keys(null!==(v=l[d].products)&&void 0!==v?v:{}).reduce(((n,v)=>{var s,e,u,r,c,a,p,b,O,f;const j=null===(s=t[d].products)||void 0===s?void 0:s[v],h=null===(r=null===(u=null===(e=null==i?void 0:i.products)||void 0===e?void 0:e[d])||void 0===u?void 0:u.products)||void 0===r?void 0:r[v];return j?n[v]=Object.assign(Object.assign({},(null===(c=l[d].products)||void 0===c?void 0:c[v])||{}),{allVariants:o.cloneDeep(j.variants)}):h?n[v]=Object.assign(Object.assign({},(null===(a=l[d].products)||void 0===a?void 0:a[v])||{}),{allVariants:o.cloneDeep(h.variants)}):(null===(b=null===(p=l[d].products)||void 0===p?void 0:p[v])||void 0===b?void 0:b.allVariants)&&(n[v]=Object.assign(Object.assign({},(null===(O=l[d].products)||void 0===O?void 0:O[v])||{}),{allVariants:o.cloneDeep(null===(f=l[d].products)||void 0===f?void 0:f[v].allVariants)})),n}),{})}),n):n}),{});
|