@stokr/components-library 2.3.58-beta.6 → 2.3.58-beta.8
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/api/StokrWeb3.js +3 -3
- package/dist/api/auth.js +16 -53
- package/dist/api/fetchData.js +26 -66
- package/dist/api/fetchDataPublic.js +20 -57
- package/dist/components/2FA/Connect2FA.js +10 -11
- package/dist/components/2FA/EnterCode.js +32 -30
- package/dist/components/2FA/EnterCode.stories.js +4 -8
- package/dist/components/2FA/InstallAuthApp.js +8 -9
- package/dist/components/2FA/ResetCode.js +11 -12
- package/dist/components/2FA/Sucess2FA.js +12 -16
- package/dist/components/2FA/disable-2fa-flow.js +53 -104
- package/dist/components/2FA/disable-2fa-flow.stories.js +4 -8
- package/dist/components/2FA/enable-2fa-flow.js +73 -144
- package/dist/components/2FA/enable-2fa-flow.stories.js +4 -8
- package/dist/components/2FA/index.js +9 -9
- package/dist/components/2FA/login-with-otp-flow.js +126 -206
- package/dist/components/2FA/login-with-otp-flow.stories.js +4 -8
- package/dist/components/2FA/main-flow.js +70 -144
- package/dist/components/2FA/main-flow.stories.js +4 -8
- package/dist/components/AccountBalance/AccountBalance.js +14 -13
- package/dist/components/AccountBalance/AccountBalance.stories.js +6 -12
- package/dist/components/AccountBalance/AccountBalance.styles.js +9 -17
- package/dist/components/AdminDashboard/Table/ReactTable.js +77 -84
- package/dist/components/AdminDashboard/Table/ReactTable.stories.js +87 -63
- package/dist/components/AdminDashboard/Table/ReactTableWrapper.js +24 -30
- package/dist/components/AdminDashboard/Table/Table.js +88 -123
- package/dist/components/AdminDashboard/Table/Table.styles.js +28 -90
- package/dist/components/AgreementItem/AgreementItem.js +10 -11
- package/dist/components/AgreementItem/AgreementItem.stories.js +5 -10
- package/dist/components/AgreementItem/AgreementItem.styles.js +8 -12
- package/dist/components/AnalyticGraphs/Analytic.js +504 -743
- package/dist/components/AnalyticGraphs/Analytic.styles.js +14 -26
- package/dist/components/BackButton/BackButton.js +9 -10
- package/dist/components/BackButton/BackButton.stories.js +4 -8
- package/dist/components/BackButton/BackButton.styles.js +13 -51
- package/dist/components/Background/Background.js +12 -11
- package/dist/components/Background/Background.stories.js +8 -14
- package/dist/components/Background/Background.styles.js +17 -33
- package/dist/components/BarChart/BarChart.js +138 -181
- package/dist/components/BarChart/BarChart.stories.js +5 -10
- package/dist/components/BarChart/BarChart.styles.js +8 -15
- package/dist/components/BarChartLegend/BarChartLegend.js +40 -67
- package/dist/components/BarChartLegend/BarChartLegend.styles.js +5 -10
- package/dist/components/BasicTable/BasicTable.js +12 -13
- package/dist/components/BasicTable/BasicTable.stories.js +5 -10
- package/dist/components/BasicTable/BasicTable.styles.js +11 -27
- package/dist/components/BlogPost/BlogPost.js +34 -53
- package/dist/components/BlogPost/BlogPost.stories.js +33 -46
- package/dist/components/BlogPost/BlogPost.styles.js +67 -59
- package/dist/components/Button/Button-stoDetails.js +150 -129
- package/dist/components/Button/Button.stories.js +27 -44
- package/dist/components/Button/Button.styles.js +24 -62
- package/dist/components/Button/GlareButton.js +61 -89
- package/dist/components/Button/GlareButton.stories.js +19 -29
- package/dist/components/ButtonContainer/ButtonContainer.styles.js +5 -10
- package/dist/components/CapitalRaisedSummary/CapitalRaisedSummery.stories.js +4 -8
- package/dist/components/CapitalRaisedSummary/CaptialRaisedSummary.js +9 -10
- package/dist/components/CapitalRaisedSummary/CaptialRaisedSummary.styles.js +8 -17
- package/dist/components/Card/Card.styles.js +14 -41
- package/dist/components/ChartBox/ChartBox.js +5 -8
- package/dist/components/ChartBox/ChartBox.stories.js +3 -6
- package/dist/components/ChartBox/ChartBox.styles.js +8 -14
- package/dist/components/ChartBox/ChartBoxDistribution.js +5 -8
- package/dist/components/ChartBox/ChartBoxDistribution.stories.js +3 -6
- package/dist/components/ChartLegend/ChartLegend.js +30 -46
- package/dist/components/ChartLegend/ChartLegend.stories.js +22 -28
- package/dist/components/ChartLegend/ChartLegend.styles.js +16 -41
- package/dist/components/Checkbox/Checkbox.js +32 -32
- package/dist/components/Checkbox/Checkbox.stories.js +5 -10
- package/dist/components/Checkbox/Checkbox.styles.js +10 -23
- package/dist/components/Checklist/ChecklistCard.js +33 -35
- package/dist/components/Checklist/ChecklistCard.stories.js +77 -100
- package/dist/components/Checklist/ChecklistCard.styles.js +12 -15
- package/dist/components/Chips/Chip.js +14 -13
- package/dist/components/Chips/Chip.stories.js +10 -19
- package/dist/components/Chips/Chip.styles.js +14 -14
- package/dist/components/Chips/ChipWrapper.js +23 -41
- package/dist/components/Chips/ChipsWrapper.stories.js +9 -17
- package/dist/components/ComponentScroll/ComponentScroll.js +25 -34
- package/dist/components/ComponentScroll/ComponentScroll.stories.js +16 -23
- package/dist/components/ComponentScroll/ComponentScroll.styles.js +22 -47
- package/dist/components/ComponentWrapper/ComponentWrapper.styles.js +7 -61
- package/dist/components/CryptoAddress/ComponentWrap.js +10 -11
- package/dist/components/CryptoAddress/CryptoAddress.js +51 -68
- package/dist/components/CryptoAddress/CryptoAddress.stories.js +7 -13
- package/dist/components/CryptoAddress/CryptoAddress.styles.js +55 -124
- package/dist/components/CryptoAddress/RadioWrap.js +9 -10
- package/dist/components/CryptoAddressDetails/CryptoAddressDetails.js +24 -25
- package/dist/components/CryptoAddressDetails/CryptoAddressDetails.stories.js +5 -10
- package/dist/components/CryptoAddressDetails/CryptoAddressDetails.styles.js +12 -42
- package/dist/components/CryptoAddressWrapper/CryptoAddressWrapper.js +10 -9
- package/dist/components/CryptoAddressWrapper/CryptoAddressWrapper.styles.js +16 -27
- package/dist/components/DonutChart/DonutChart.js +101 -130
- package/dist/components/DonutChart/DonutChart.stories.js +4 -8
- package/dist/components/DonutChart/DonutChart.styles.js +15 -27
- package/dist/components/DoubleButton/DoubleButton.styles.js +8 -8
- package/dist/components/ErrorMessage/ErrorMessage.styles.js +3 -5
- package/dist/components/FAQ/FAQ.js +29 -45
- package/dist/components/FAQ/FAQ.stories.js +4 -9
- package/dist/components/FAQ/FAQ.styles.js +23 -39
- package/dist/components/Footer/Footer.js +9 -10
- package/dist/components/Footer/Footer.stories.js +6 -12
- package/dist/components/Footer/Footer.styles.js +22 -46
- package/dist/components/Footer/FooterLayout.js +16 -20
- package/dist/components/Footer/FooterLayout.stories.js +4 -8
- package/dist/components/Footer/FooterMenu.js +61 -83
- package/dist/components/Footer/FooterMenu.stories.js +4 -8
- package/dist/components/Footer/FooterMenu.styles.js +16 -39
- package/dist/components/Footer/index.js +4 -4
- package/dist/components/ForgotPasswordModal/ForgotPasswordModal.js +92 -114
- package/dist/components/ForgotPasswordModal/ForgotPasswordModal.stories.js +4 -8
- package/dist/components/Form/Form.js +15 -14
- package/dist/components/Form/Form.stories.js +4 -8
- package/dist/components/Form/Form.styles.js +16 -36
- package/dist/components/FullscreenCard/FullscreenCard.styles.js +7 -12
- package/dist/components/Grid/Grid.styles.js +17 -68
- package/dist/components/Header/Header.js +98 -163
- package/dist/components/Header/Header.stories.js +17 -28
- package/dist/components/Header/Header.styles.js +61 -124
- package/dist/components/HeroBlock/HeroVideoBlock.js +20 -25
- package/dist/components/Icon/Icon.style.js +10 -22
- package/dist/components/Icon/Icon2.js +11 -13
- package/dist/components/InfoIcon/InfoIcon.js +18 -17
- package/dist/components/InfoIcon/InfoIcon.stories.js +5 -10
- package/dist/components/InfoIcon/InfoIcon.styles.js +5 -21
- package/dist/components/InfoPanel/InfoPanel.js +26 -48
- package/dist/components/Input/DatePickerInput.js +21 -33
- package/dist/components/Input/DatePickerInput.stories.js +5 -10
- package/dist/components/Input/DatePickerInput.styles.js +5 -19
- package/dist/components/Input/Input.js +43 -51
- package/dist/components/Input/Input.stories.js +9 -16
- package/dist/components/Input/Input.styles.js +8 -43
- package/dist/components/Input/InputPassword.js +30 -50
- package/dist/components/Input/InputPassword.stories.js +6 -12
- package/dist/components/Input/InputPassword.styles.js +30 -57
- package/dist/components/Input/InputUsername.js +83 -102
- package/dist/components/Input/InputWithButton.js +20 -19
- package/dist/components/Input/InputWithButton.stories.js +5 -9
- package/dist/components/Input/InputWithButton.styles.js +7 -19
- package/dist/components/Input/OtpInput.js +27 -42
- package/dist/components/Input/OtpInput.stories.js +5 -11
- package/dist/components/Input/RangeInput.js +29 -25
- package/dist/components/Input/RangeInput.stories.js +4 -8
- package/dist/components/Input/RangeInput.styles.js +15 -42
- package/dist/components/Input/Select.js +68 -89
- package/dist/components/Input/Select.stories.js +6 -12
- package/dist/components/Input/Select.styles.js +12 -32
- package/dist/components/InvestCalculator/InvestCalculator.js +245 -243
- package/dist/components/InvestCalculator/InvestCalculator.stories.js +18 -21
- package/dist/components/InvestCalculator/InvestCalculator.styles.js +14 -33
- package/dist/components/InvestmentStat/InvestmentStat.js +11 -10
- package/dist/components/InvestmentStat/InvestmentStat.stories.js +5 -10
- package/dist/components/InvestmentStat/InvestmentStat.styles.js +12 -24
- package/dist/components/KYCFlow/BasicInfo.js +419 -460
- package/dist/components/KYCFlow/Confirmation.js +12 -17
- package/dist/components/KYCFlow/DocumentFileUpload.js +214 -227
- package/dist/components/KYCFlow/DocumentScan.js +16 -15
- package/dist/components/KYCFlow/DocumentScanUpload.js +203 -210
- package/dist/components/KYCFlow/DocumentSelect.js +87 -117
- package/dist/components/KYCFlow/DocumentSuccess.js +14 -15
- package/dist/components/KYCFlow/DocumentUpload.js +10 -11
- package/dist/components/KYCFlow/DocumentVerificationType.js +98 -128
- package/dist/components/KYCFlow/FaceScan.js +10 -11
- package/dist/components/KYCFlow/FaceScanRecognition.js +14 -13
- package/dist/components/KYCFlow/FaceScanSuccess.js +10 -13
- package/dist/components/KYCFlow/Terms.js +90 -113
- package/dist/components/KYCFlow/_styles.js +37 -86
- package/dist/components/KYCFlow/index.js +14 -14
- package/dist/components/KYCSelectBox/KYCSelectBox.styles.js +7 -19
- package/dist/components/LatestUpdate/LatestUpdate.js +12 -11
- package/dist/components/LatestUpdate/LatestUpdate.stories.js +5 -10
- package/dist/components/LatestUpdate/LatestUpdate.styles.js +15 -28
- package/dist/components/Layout/Layout-func-no-work.js +24 -24
- package/dist/components/Layout/Layout.js +47 -68
- package/dist/components/Layout/Layout.stories.js +5 -12
- package/dist/components/LearnMoreCarousel/LearnMoreCarousel.js +13 -12
- package/dist/components/LearnMoreCarousel/LearnMoreCarousel.stories.js +5 -10
- package/dist/components/LearnMoreCarousel/LearnMoreCarousel.styles.js +10 -22
- package/dist/components/LearnMorePage/LearnMore.js +134 -174
- package/dist/components/LearnMorePage/LearnMore.shared.styles.js +7 -22
- package/dist/components/LearnMorePage/LearnMore.stories.js +4 -8
- package/dist/components/LearnMorePage/LearnMore.styles.js +24 -74
- package/dist/components/LearnMorePage/LearnMoreExampleObject.js +3 -5
- package/dist/components/LearnMorePage/LearnMoreItem.js +11 -16
- package/dist/components/LearnMorePage/LearnMoreItem.stories.js +4 -8
- package/dist/components/LearnMorePage/LearnMoreItem.styles.js +18 -54
- package/dist/components/LearnMoreSection/LearnMore.js +119 -158
- package/dist/components/LearnMoreSection/LearnMore.stories.js +4 -8
- package/dist/components/LearnMoreSection/LearnMore.styles.js +15 -41
- package/dist/components/LearnMoreSection/LearnMoreItem.js +14 -15
- package/dist/components/LearnMoreSection/LearnMoreItem.stories.js +4 -8
- package/dist/components/LearnMoreSection/LearnMoreItem.styles.js +9 -23
- package/dist/components/LoginModal/LoginModal.js +35 -41
- package/dist/components/LoginModal/LoginModal.stories.js +8 -12
- package/dist/components/MainMenu/DynamicMainMenu.js +11 -14
- package/dist/components/MainMenu/MainMenu.js +157 -190
- package/dist/components/MainMenu/MainMenu.styles.js +48 -89
- package/dist/components/MatomoConnect/Matomo.js +201 -463
- package/dist/components/MenuNav/MenuNav.styles.js +5 -9
- package/dist/components/Modal/Modal.js +46 -48
- package/dist/components/Modal/Modal.stories.js +8 -16
- package/dist/components/Modal/Modal.styles.js +34 -96
- package/dist/components/Modal/NewVentureModal/NewVentureModal.js +69 -95
- package/dist/components/Modal/NewVentureModal/NewVentureModal.stories.js +22 -43
- package/dist/components/Modal/PaymentModal.js +43 -54
- package/dist/components/Modal/PaymentModal.stories.js +4 -8
- package/dist/components/MultiProgressBar/MultiProgressBar.js +19 -23
- package/dist/components/MultiProgressBar/MultiProgressBar.stories.js +6 -12
- package/dist/components/MultiProgressBar/MultiProgressBar.styles.js +9 -22
- package/dist/components/Newsletter/Newsletter.js +65 -100
- package/dist/components/Newsletter/Newsletter.stories.js +4 -8
- package/dist/components/Newsletter/Newsletter.styles.js +47 -44
- package/dist/components/NotificationContext/NotificationContext.js +93 -125
- package/dist/components/NotificationCounter/NotificationCounter.styles.js +4 -16
- package/dist/components/Number/Number.js +13 -10
- package/dist/components/Number/Number.stories.js +23 -41
- package/dist/components/Number/Number.styles.js +4 -10
- package/dist/components/PageTransition/PageTransition.js +16 -19
- package/dist/components/Pagination/Pagination.js +22 -25
- package/dist/components/Pagination/Pagination.stories.js +29 -36
- package/dist/components/Pagination/Pagination.styles.js +8 -15
- package/dist/components/Pagination/PaginationControls.js +32 -36
- package/dist/components/Pagination/PaginationControls.stories.js +33 -62
- package/dist/components/Pagination/usePagination.js +29 -37
- package/dist/components/Process/Process.stories.js +6 -12
- package/dist/components/Process/Process.styles.js +6 -16
- package/dist/components/ProfileBadge/ProfileBadge.js +12 -11
- package/dist/components/ProfileBadge/ProfileBadge.stories.js +5 -9
- package/dist/components/ProfileBadge/ProfileBadge.styles.js +13 -19
- package/dist/components/ProfileBox/ProfileBox.js +15 -17
- package/dist/components/ProfileBox/ProfileBox.stories.js +5 -9
- package/dist/components/ProfileBox/ProfileBox.styles.js +9 -21
- package/dist/components/ProfileHeader/ProfileHeader.js +163 -199
- package/dist/components/ProfileHeader/ProfileHeader.styles.js +24 -46
- package/dist/components/ProfileStat/ProfileStat.js +12 -11
- package/dist/components/ProfileStat/ProfileStat.stories.js +6 -12
- package/dist/components/ProfileStat/ProfileStat.styles.js +9 -23
- package/dist/components/ProofOfAddress/ProofOfAddress.styles.js +20 -36
- package/dist/components/QRCode/QRCode.js +30 -30
- package/dist/components/QRCode/QRCode.stories.js +14 -26
- package/dist/components/ROI/ROI.js +225 -261
- package/dist/components/ROI/ROI.styles.js +13 -25
- package/dist/components/ROI/ROIChart.js +196 -303
- package/dist/components/ROI/ROIChart.styles.js +7 -11
- package/dist/components/ROI/ROIModal.js +13 -20
- package/dist/components/ROI/ROIParkingo.js +208 -244
- package/dist/components/ROI/ROIPixelmatic.js +209 -245
- package/dist/components/ROI/ROIScenarioBox.js +9 -8
- package/dist/components/ROI/ROIScenarioBox.styles.js +10 -33
- package/dist/components/Radio/Radio.js +19 -18
- package/dist/components/Radio/Radio.stories.js +4 -8
- package/dist/components/Radio/Radio.styles.js +5 -14
- package/dist/components/RefreshButton/RefreshButton.js +6 -5
- package/dist/components/RefreshButton/RefreshButton.stories.js +5 -10
- package/dist/components/RefreshButton/RefreshButton.styles.js +9 -24
- package/dist/components/RegisterConfirmModal/RegisterConfirmModal.js +17 -18
- package/dist/components/RegisterConfirmModal/RegisterConfirmModal.stories.js +5 -9
- package/dist/components/RegisterConfirmModal/RegisterConfirmModal.styles.js +3 -4
- package/dist/components/RegisterLiquidSteps/RegisterLiquidSteps.js +46 -70
- package/dist/components/RegisterLiquidSteps/RegisterLiquidSteps.styles.js +10 -22
- package/dist/components/RegisterLiquidSteps/complete.js +4 -5
- package/dist/components/RegisterLiquidSteps/flow.js +53 -99
- package/dist/components/RegisterLiquidSteps/index.js +7 -22
- package/dist/components/RegisterLiquidSteps/register-liquid.js +62 -102
- package/dist/components/RegisterModal/RegisterModal.js +82 -118
- package/dist/components/RegisterModal/RegisterModal.stories.js +5 -9
- package/dist/components/RequestDataBox/RequestDataBox.js +9 -8
- package/dist/components/RequestDataBox/RequestDataBox.stories.js +4 -8
- package/dist/components/RequestDataBox/RequestDataBox.styles.js +7 -12
- package/dist/components/ResetConfirmModal/ResetConfirmModal.js +10 -11
- package/dist/components/ResetConfirmModal/ResetConfirmModal.styles.js +3 -4
- package/dist/components/ResetPasswordModal/ResetPasswordModal.js +29 -28
- package/dist/components/SEO/SEO.js +11 -10
- package/dist/components/SEO/SEO.stories.js +4 -8
- package/dist/components/SectionTitle/SectionTitle.styles.js +3 -5
- package/dist/components/ShareButton/ShareButton.js +132 -145
- package/dist/components/SideLine/SideLine.js +3 -6
- package/dist/components/SideLine/SideLine.stories.js +3 -6
- package/dist/components/SideLine/SideLine.styles.js +6 -12
- package/dist/components/SigningSubflow/SignSubIntro.js +9 -8
- package/dist/components/SigningSubflow/_styles.js +9 -20
- package/dist/components/SigningSubflow/index.js +5 -5
- package/dist/components/Slider/Slider.js +16 -16
- package/dist/components/Slider/Slider.stories.js +5 -10
- package/dist/components/Slider/Slider.styles.js +5 -8
- package/dist/components/SpanButton/SpanButton.styles.js +3 -6
- package/dist/components/StatusBadge/StatusBadge.styles.js +4 -10
- package/dist/components/StepController/StepController.js +49 -74
- package/dist/components/StepController/StepController.stories.js +4 -8
- package/dist/components/StepController/StepController.styles.js +6 -12
- package/dist/components/StepController/StepControllerContext.js +46 -68
- package/dist/components/StepController/StepControllerProgress.js +16 -19
- package/dist/components/StepController/StepControllerProgress.stories.js +4 -8
- package/dist/components/StepsProgress/StepsProgress.js +44 -58
- package/dist/components/StepsProgress/StepsProgress.stories.js +33 -35
- package/dist/components/StepsProgress/StepsProgress.styles.js +7 -15
- package/dist/components/StokrLoader/StokrLoader.js +20 -23
- package/dist/components/StokrLoader/media.js +5 -7
- package/dist/components/SvgIcons/AdminBadgeSvg.js +16 -19
- package/dist/components/SvgIcons/CameraSvg.js +26 -29
- package/dist/components/SvgIcons/CapsLockSvg.js +21 -24
- package/dist/components/SvgIcons/DocumentBackSvg.js +25 -28
- package/dist/components/SvgIcons/DocumentSmallSvg.js +51 -54
- package/dist/components/SvgIcons/DocumentSvg.js +28 -31
- package/dist/components/SvgIcons/Early.js +14 -17
- package/dist/components/SvgIcons/EthSvg.js +30 -33
- package/dist/components/SvgIcons/EurSvg.js +16 -19
- package/dist/components/SvgIcons/FaceScanIconSvg.js +21 -24
- package/dist/components/SvgIcons/FourSvg.js +11 -14
- package/dist/components/SvgIcons/Glassess.js +19 -22
- package/dist/components/SvgIcons/LogoSvg.js +14 -17
- package/dist/components/SvgIcons/OneSvg.js +13 -16
- package/dist/components/SvgIcons/PassportSvg.js +46 -49
- package/dist/components/SvgIcons/RefreshSvg.js +17 -20
- package/dist/components/SvgIcons/SocialFacebook.js +20 -23
- package/dist/components/SvgIcons/SocialInstagram.js +11 -14
- package/dist/components/SvgIcons/SocialLinkedIn.js +25 -28
- package/dist/components/SvgIcons/SocialMedium.js +15 -18
- package/dist/components/SvgIcons/SocialReddit.js +15 -18
- package/dist/components/SvgIcons/SocialTelegram.js +49 -52
- package/dist/components/SvgIcons/SocialTwitter.js +44 -47
- package/dist/components/SvgIcons/SocialYoutube.js +15 -18
- package/dist/components/SvgIcons/ThreeSvg.js +10 -13
- package/dist/components/SvgIcons/TwoSidedDocumentSvg.js +72 -75
- package/dist/components/SvgIcons/TwoSvg.js +13 -16
- package/dist/components/SvgIcons/UpdateDefaultSvg.js +19 -22
- package/dist/components/SvgIcons/UpdateHardSvg.js +15 -18
- package/dist/components/SvgIcons/UpdateSoftSvg.js +17 -20
- package/dist/components/SvgIcons/UploadSvg.js +24 -27
- package/dist/components/SvgIcons/VerifiedBadge.js +13 -16
- package/dist/components/SvgIcons/index.js +32 -32
- package/dist/components/Switch/Switch.js +23 -37
- package/dist/components/Switch/Switch.stories.js +8 -14
- package/dist/components/Switch/Switch.styles.js +8 -33
- package/dist/components/Tabs/Tabs.js +19 -21
- package/dist/components/Tabs/Tabs.stories.js +4 -8
- package/dist/components/Tabs/Tabs.styles.js +4 -6
- package/dist/components/TabsNav/TabNav.js +14 -13
- package/dist/components/TabsNav/TabNav.stories.js +5 -10
- package/dist/components/TabsNav/TabsNav.js +14 -14
- package/dist/components/TabsNav/TabsNav.stories.js +4 -8
- package/dist/components/TabsNav/TabsNav.styles.js +10 -25
- package/dist/components/TeamOverview/TeamOverview.js +38 -84
- package/dist/components/TeamOverview/TeamOverview.stories.js +5 -10
- package/dist/components/TeamOverview/TeamOverview.styles.js +18 -35
- package/dist/components/TermsModal/TermsModal.js +49 -79
- package/dist/components/TermsModal/TermsModal.stories.js +4 -8
- package/dist/components/TermsModal/_styles.js +35 -100
- package/dist/components/Text/Headline.js +15 -14
- package/dist/components/Text/Headline.stories.js +4 -8
- package/dist/components/Text/StyledText.js +5 -8
- package/dist/components/Text/Text.stories.js +5 -10
- package/dist/components/Text/Text.styles.js +15 -37
- package/dist/components/TextLink/TextLink.styles.js +6 -17
- package/dist/components/ToDoList/ToDoList.js +76 -85
- package/dist/components/ToDoList/ToDoList.stories.js +7 -14
- package/dist/components/ToDoList/ToDoList.styles.js +34 -43
- package/dist/components/ToDoList/ToDoListTask.js +22 -35
- package/dist/components/ToDoList/ToDoListTask.stories.js +5 -10
- package/dist/components/ToDoList/ToDoListTask.styles.js +13 -40
- package/dist/components/TransactionDetails/TransactionDetails.js +9 -19
- package/dist/components/TransactionDetails/TransactionDetails.stories.js +5 -10
- package/dist/components/TransactionDetails/TransactionDetails.styles.js +6 -15
- package/dist/components/TransactionInfo/TransactionInfo.js +18 -17
- package/dist/components/TransactionInfo/TransactionInfo.stories.js +4 -8
- package/dist/components/TransactionInfo/TransactionInfo.styles.js +10 -31
- package/dist/components/TwoFactorModal/TwoFactorModal.js +72 -94
- package/dist/components/VerifyEmailModal/VerifyEmailModal.js +49 -48
- package/dist/components/VerifyEmailModal/VerifyEmailModal.stories.js +6 -11
- package/dist/components/breakdown/Breakdown.js +38 -36
- package/dist/components/breakdown/index.js +3 -5
- package/dist/components/headerHo/HeaderHo.js +585 -769
- package/dist/components/headerHo/HeaderHo.stories.js +9 -13
- package/dist/components/headerHo/index.js +3 -5
- package/dist/components/icons/Arrow.js +43 -46
- package/dist/components/icons/Arrow.stories.js +7 -14
- package/dist/components/icons/ArrowSimple.js +32 -35
- package/dist/components/icons/ArrowSimple.stories.js +7 -14
- package/dist/components/icons/Check.js +28 -31
- package/dist/components/icons/Check.stories.js +3 -6
- package/dist/components/icons/Facebook.js +11 -14
- package/dist/components/icons/Facebook.stories.js +3 -6
- package/dist/components/icons/Info.js +40 -43
- package/dist/components/icons/Info.stories.js +3 -6
- package/dist/components/icons/Instagram.js +11 -14
- package/dist/components/icons/Instagram.stories.js +3 -6
- package/dist/components/icons/LinkIcon.js +19 -22
- package/dist/components/icons/LinkIcon.stories.js +3 -6
- package/dist/components/icons/LinkedIn.js +28 -31
- package/dist/components/icons/LinkedIn.stories.js +3 -6
- package/dist/components/icons/Medium.js +27 -30
- package/dist/components/icons/Medium.stories.js +3 -6
- package/dist/components/icons/Reddit.js +17 -20
- package/dist/components/icons/Reddit.stories.js +3 -6
- package/dist/components/icons/Share.js +47 -50
- package/dist/components/icons/Share.stories.js +3 -6
- package/dist/components/icons/Telegram.js +27 -30
- package/dist/components/icons/Telegram.stories.js +3 -6
- package/dist/components/icons/Twitter.js +11 -14
- package/dist/components/icons/Twitter.stories.js +3 -6
- package/dist/components/icons/X.js +11 -14
- package/dist/components/icons/X.stories.js +3 -6
- package/dist/components/icons/Youtube.js +11 -14
- package/dist/components/icons/Youtube.stories.js +3 -6
- package/dist/components/icons/index.js +15 -15
- package/dist/components/landing-page/List.js +3 -5
- package/dist/components/landing-page/PageContent.js +5 -7
- package/dist/components/landing-page/PageText.js +12 -16
- package/dist/components/landing-page/PageTitle.js +16 -47
- package/dist/components/logo/Logo.js +49 -71
- package/dist/components/logo/index.js +3 -5
- package/dist/components/renderToBody/index.js +3 -5
- package/dist/components/renderToBody/renderToBody.js +39 -60
- package/dist/components/taxId/TaxId.stories.js +11 -16
- package/dist/components/taxId/complete.js +9 -11
- package/dist/components/taxId/flow.js +22 -34
- package/dist/components/taxId/index.js +4 -4
- package/dist/components/taxId/register-taxid.js +54 -92
- package/dist/components/video/Video.js +69 -84
- package/dist/components/video/Video.stories.js +5 -9
- package/dist/components/video/index.js +3 -5
- package/dist/constants/globalVariables.js +10 -20
- package/dist/constants/style.js +23 -46
- package/dist/context/Auth.js +247 -340
- package/dist/context/AuthContext.js +545 -1023
- package/dist/context/Checkbox/CheckboxContext.js +65 -117
- package/dist/firebase-config.js +4 -6
- package/dist/hooks/useNewVentureForm.js +128 -193
- package/dist/hooks/useTimer.js +29 -51
- package/dist/index.js +134 -134
- package/dist/model/axios.js +4 -6
- package/dist/model/axiosPublic.js +4 -6
- package/dist/services/TimerService.js +70 -89
- package/dist/static/images/copy_icon.svg +4 -0
- package/dist/styles/colors.js +2 -4
- package/dist/styles/fonts.js +3 -4
- package/dist/styles/global.js +3 -4
- package/dist/styles/grid.js +4 -5
- package/dist/styles/reactTippy.js +3 -4
- package/dist/styles/rwd.js +12 -26
- package/dist/styles/semanticUi.js +3 -4
- package/dist/styles/spacing.js +2 -3
- package/dist/styles/theme.js +6 -9
- package/dist/utils/allowed-countries-list.js +2 -3
- package/dist/utils/analytics.js +32 -48
- package/dist/utils/check-sale-time-left.js +37 -39
- package/dist/utils/check-todo-status.js +3 -4
- package/dist/utils/checklistGenerator.js +46 -46
- package/dist/utils/copyToClipboard.js +65 -131
- package/dist/utils/countries-list.js +2 -3
- package/dist/utils/customHooks.js +40 -67
- package/dist/utils/delete-redirect-cookie-and-navigate.js +3 -3
- package/dist/utils/fix-decimals.js +4 -5
- package/dist/utils/formatCurrencyValue.js +41 -52
- package/dist/utils/get-cookie-domain.js +3 -4
- package/dist/utils/get-short-address.js +1 -3
- package/dist/utils/isUSInvestor.js +2 -4
- package/dist/utils/km_ify.js +3 -3
- package/dist/utils/lock-body.js +3 -5
- package/dist/utils/moment.js +10 -12
- package/dist/utils/redirect-url.js +2 -3
- package/dist/utils/saveAs.js +5 -5
- package/dist/utils/scrollUtils.js +33 -36
- package/dist/utils/set-redirect-cookie.js +6 -7
- package/dist/utils/withRouter.js +6 -6
- package/package.json +134 -141
|
@@ -6,25 +6,16 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
exports.default = exports.Analytic = void 0;
|
|
7
7
|
var _Matomo = _interopRequireDefault(require("../MatomoConnect/Matomo"));
|
|
8
8
|
var Moment = _interopRequireWildcard(require("moment"));
|
|
9
|
-
function
|
|
10
|
-
function
|
|
11
|
-
function
|
|
12
|
-
function
|
|
13
|
-
function
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
20
|
-
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
21
|
-
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
22
|
-
var matomoConnect = new _Matomo.default();
|
|
23
|
-
var months = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'];
|
|
24
|
-
var monthsShort = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
|
|
25
|
-
var Analytic = /*#__PURE__*/function () {
|
|
26
|
-
function Analytic() {
|
|
27
|
-
_classCallCheck(this, Analytic);
|
|
9
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
12
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
13
|
+
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
14
|
+
const matomoConnect = new _Matomo.default();
|
|
15
|
+
const months = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'];
|
|
16
|
+
const monthsShort = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
|
|
17
|
+
class Analytic {
|
|
18
|
+
constructor() {
|
|
28
19
|
_defineProperty(this, "CURRENT_DATE", void 0);
|
|
29
20
|
_defineProperty(this, "START_DATE", void 0);
|
|
30
21
|
_defineProperty(this, "VISITS_SUMMARY", {});
|
|
@@ -33,748 +24,518 @@ var Analytic = /*#__PURE__*/function () {
|
|
|
33
24
|
this.START_DATE = this.CURRENT_DATE.clone().subtract(2, 'months');
|
|
34
25
|
this.getSummary();
|
|
35
26
|
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
27
|
+
async getSummary() {
|
|
28
|
+
this.TOTAL_SUMMARY = {
|
|
29
|
+
visits: 0,
|
|
30
|
+
bounce_count: 0,
|
|
31
|
+
visit_length: 0,
|
|
32
|
+
unique_visitors: 0,
|
|
33
|
+
avg_time_on_site: 0
|
|
34
|
+
};
|
|
35
|
+
this.VISITS_SUMMARY = await matomoConnect.init(matomoConnect.GetVisitsSummary, 'month', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
36
|
+
Object.keys(this.VISITS_SUMMARY).forEach(key => {
|
|
37
|
+
this.TOTAL_SUMMARY.visits += this.VISITS_SUMMARY[key].nb_visits || 0;
|
|
38
|
+
this.TOTAL_SUMMARY.bounce_count += this.VISITS_SUMMARY[key].bounce_count || 0;
|
|
39
|
+
this.TOTAL_SUMMARY.visit_length += this.VISITS_SUMMARY[key].sum_visit_length || 0;
|
|
40
|
+
this.TOTAL_SUMMARY.unique_visitors += this.VISITS_SUMMARY[key].nb_uniq_visitors || 0;
|
|
41
|
+
this.TOTAL_SUMMARY.avg_time_on_site += this.VISITS_SUMMARY[key].avg_time_on_site || 0;
|
|
42
|
+
});
|
|
43
|
+
}
|
|
44
|
+
static async getRealTimeUsersBasicGraph() {
|
|
45
|
+
const lastMinute = await matomoConnect.init(matomoConnect.LiveGetCounters, 10, 'visitors');
|
|
46
|
+
const lastHour = await matomoConnect.init(matomoConnect.LiveGetCounters, 60, 'visitors');
|
|
47
|
+
const last2Hours = await matomoConnect.init(matomoConnect.LiveGetCounters, 120, 'visitors');
|
|
48
|
+
const increase = Analytic.getIncrease(last2Hours, lastMinute);
|
|
49
|
+
const object = {
|
|
50
|
+
id: 'realTimeUsersStat',
|
|
51
|
+
title: 'realtime users',
|
|
52
|
+
value: lastMinute.toString(),
|
|
53
|
+
percent: isNaN(increase) ? 0 : parseFloat(parseFloat(increase).toFixed(1)),
|
|
54
|
+
chart: {
|
|
55
|
+
id: 'realTimeUsersChart',
|
|
56
|
+
fill: '#e4ecf9',
|
|
57
|
+
stroke: '#0050ca',
|
|
58
|
+
data: [{
|
|
59
|
+
date: 1,
|
|
60
|
+
value: last2Hours
|
|
61
|
+
}, {
|
|
62
|
+
date: 2,
|
|
63
|
+
value: lastHour
|
|
64
|
+
}, {
|
|
65
|
+
date: 3,
|
|
66
|
+
value: lastMinute
|
|
67
|
+
}]
|
|
70
68
|
}
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
69
|
+
};
|
|
70
|
+
return object;
|
|
71
|
+
}
|
|
72
|
+
async getBasicGraphs() {
|
|
73
|
+
return [this.getTotalVisitsBasicGraph(), this.getBounceRateBasicGraph(), this.getVisitDurationBasicGraph()];
|
|
74
|
+
}
|
|
75
|
+
getTotalVisitsBasicGraph() {
|
|
76
|
+
const totalVisitsChartData = [];
|
|
77
|
+
Object.keys(this.VISITS_SUMMARY).forEach(key => {
|
|
78
|
+
totalVisitsChartData.push({
|
|
79
|
+
date: totalVisitsChartData.length + 1,
|
|
80
|
+
value: this.VISITS_SUMMARY[key].nb_visits ? this.VISITS_SUMMARY[key].nb_visits : 0
|
|
81
|
+
});
|
|
82
|
+
});
|
|
83
|
+
const visitsSummaryKeys = Object.keys(this.VISITS_SUMMARY);
|
|
84
|
+
const previousMonth = this.VISITS_SUMMARY[visitsSummaryKeys[visitsSummaryKeys.length - 2]];
|
|
85
|
+
const lastMonth = this.VISITS_SUMMARY[visitsSummaryKeys[visitsSummaryKeys.length - 1]];
|
|
86
|
+
const totalVisitsIncrease = Analytic.getIncrease(previousMonth && previousMonth.nb_visits ? previousMonth.nb_visits : 0, lastMonth && lastMonth.nb_visits ? lastMonth.nb_visits : 0);
|
|
87
|
+
return {
|
|
88
|
+
id: 'totalVisitsStat',
|
|
89
|
+
title: 'total visits',
|
|
90
|
+
value: this.TOTAL_SUMMARY.visits.toString(),
|
|
91
|
+
percent: isNaN(totalVisitsIncrease) ? 0 : parseFloat(parseFloat(totalVisitsIncrease).toFixed(1)),
|
|
92
|
+
chart: {
|
|
93
|
+
id: 'totalVisitsGraph',
|
|
94
|
+
fill: '#fee8e8',
|
|
95
|
+
stroke: '#ee220d',
|
|
96
|
+
data: totalVisitsChartData
|
|
89
97
|
}
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
totalVisitsChartData.push({
|
|
99
|
-
date: totalVisitsChartData.length + 1,
|
|
100
|
-
value: _this2.VISITS_SUMMARY[key].nb_visits ? _this2.VISITS_SUMMARY[key].nb_visits : 0
|
|
101
|
-
});
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
getBounceRateBasicGraph() {
|
|
101
|
+
const bounceRateData = [];
|
|
102
|
+
Object.keys(this.VISITS_SUMMARY).forEach(key => {
|
|
103
|
+
bounceRateData.push({
|
|
104
|
+
date: bounceRateData.length + 1,
|
|
105
|
+
value: this.VISITS_SUMMARY[key].bounce_count ? this.VISITS_SUMMARY[key].bounce_count : 0
|
|
102
106
|
});
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
107
|
+
});
|
|
108
|
+
const visitsSummaryKeys = Object.keys(this.VISITS_SUMMARY);
|
|
109
|
+
const firstMonth = this.VISITS_SUMMARY[visitsSummaryKeys.shift()];
|
|
110
|
+
const lastMonth = this.VISITS_SUMMARY[visitsSummaryKeys[visitsSummaryKeys.length - 1]];
|
|
111
|
+
const bounceRateIncrease = Analytic.getIncrease(firstMonth && firstMonth.bounce_count ? firstMonth.bounce_count : 0, lastMonth && lastMonth.bounce_count ? lastMonth.bounce_count : 0);
|
|
112
|
+
const bounceRate = Analytic.getPercent(this.TOTAL_SUMMARY.bounce_count, this.TOTAL_SUMMARY.visits);
|
|
113
|
+
return {
|
|
114
|
+
id: 'bounceRateStat',
|
|
115
|
+
title: 'bounce rate',
|
|
116
|
+
value: "".concat(bounceRate, "%"),
|
|
117
|
+
percent: isNaN(bounceRateIncrease) ? 0 : parseFloat(parseFloat(bounceRateIncrease).toFixed(1)),
|
|
118
|
+
chart: {
|
|
119
|
+
id: 'bounceRateGraph',
|
|
120
|
+
fill: '#eff8ec',
|
|
121
|
+
stroke: '#69bd53',
|
|
122
|
+
data: bounceRateData
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
getVisitDurationBasicGraph() {
|
|
127
|
+
const visitDurationData = [];
|
|
128
|
+
Object.keys(this.VISITS_SUMMARY).forEach(key => {
|
|
129
|
+
visitDurationData.push({
|
|
130
|
+
date: visitDurationData.length + 1,
|
|
131
|
+
value: this.VISITS_SUMMARY[key].avg_time_on_site ? this.VISITS_SUMMARY[key].avg_time_on_site : 0
|
|
132
|
+
});
|
|
133
|
+
});
|
|
134
|
+
const visitsSummaryKeys = Object.keys(this.VISITS_SUMMARY);
|
|
135
|
+
const firstMonth = this.VISITS_SUMMARY[visitsSummaryKeys.shift()];
|
|
136
|
+
const lastMonth = this.VISITS_SUMMARY[visitsSummaryKeys[visitsSummaryKeys.length - 1]];
|
|
137
|
+
const visitDurationIncrease = Analytic.getIncrease(firstMonth && firstMonth.avg_time_on_site ? firstMonth.avg_time_on_site : 0, lastMonth && lastMonth.avg_time_on_site ? lastMonth.avg_time_on_site : 0);
|
|
138
|
+
const value = new Moment().startOf('day').seconds(this.TOTAL_SUMMARY.avg_time_on_site);
|
|
139
|
+
return {
|
|
140
|
+
id: 'visitDurationStat',
|
|
141
|
+
title: 'avg. visit duration',
|
|
142
|
+
value: Analytic.getTimeSpent(value),
|
|
143
|
+
percent: isNaN(visitDurationIncrease) ? 0 : parseFloat(parseFloat(visitDurationIncrease).toFixed(1)),
|
|
144
|
+
chart: {
|
|
145
|
+
id: 'visitDurationGraph',
|
|
146
|
+
fill: '#f0f0f0',
|
|
147
|
+
stroke: '#2f2f2f',
|
|
148
|
+
data: visitDurationData
|
|
149
|
+
}
|
|
150
|
+
};
|
|
151
|
+
}
|
|
152
|
+
async getCountryGraph() {
|
|
153
|
+
const graphData = [];
|
|
154
|
+
const countries = await matomoConnect.init(matomoConnect.GetCountrySummary, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
155
|
+
const countriesByMonth = await matomoConnect.init(matomoConnect.GetCountrySummary, 'month', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
156
|
+
countries.forEach((value, key) => {
|
|
157
|
+
const bounceRateData = [];
|
|
158
|
+
let bounceRate = value.bounce_count * 100 / value.nb_visits;
|
|
159
|
+
bounceRate = parseFloat(bounceRate).toFixed(2);
|
|
160
|
+
Object.keys(countriesByMonth).forEach(byMonthKey => {
|
|
161
|
+
const object = {
|
|
162
|
+
date: bounceRateData.length + 1
|
|
163
|
+
};
|
|
164
|
+
countriesByMonth[byMonthKey].forEach(cv => {
|
|
165
|
+
if (cv.code === value.code) {
|
|
166
|
+
object.value = cv && cv.bounce_count ? cv.bounce_count : 0;
|
|
167
|
+
}
|
|
129
168
|
});
|
|
169
|
+
if (!object.value) {
|
|
170
|
+
object.value = 0;
|
|
171
|
+
}
|
|
172
|
+
bounceRateData.push(object);
|
|
130
173
|
});
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
value: "".concat(bounceRate, "%"),
|
|
140
|
-
percent: isNaN(bounceRateIncrease) ? 0 : parseFloat(parseFloat(bounceRateIncrease).toFixed(1)),
|
|
174
|
+
graphData.push({
|
|
175
|
+
id: key,
|
|
176
|
+
country: value.code,
|
|
177
|
+
country_name: value.label,
|
|
178
|
+
visits: value.nb_visits,
|
|
179
|
+
unique_visitors: value.sum_daily_nb_uniq_visitors,
|
|
180
|
+
flag_url: "".concat(matomoConnect.MATOMO_API_URL, "/").concat(value.logo),
|
|
181
|
+
bounce_rate: "".concat(bounceRate, "%"),
|
|
141
182
|
chart: {
|
|
142
|
-
id:
|
|
143
|
-
fill: '#
|
|
144
|
-
stroke: '#
|
|
183
|
+
id: "countryChart".concat(key),
|
|
184
|
+
fill: '#E4ECF9',
|
|
185
|
+
stroke: '#0050CA',
|
|
145
186
|
data: bounceRateData
|
|
146
187
|
}
|
|
147
|
-
};
|
|
148
|
-
}
|
|
149
|
-
}, {
|
|
150
|
-
key: "getVisitDurationBasicGraph",
|
|
151
|
-
value: function getVisitDurationBasicGraph() {
|
|
152
|
-
var _this4 = this;
|
|
153
|
-
var visitDurationData = [];
|
|
154
|
-
Object.keys(this.VISITS_SUMMARY).forEach(function (key) {
|
|
155
|
-
visitDurationData.push({
|
|
156
|
-
date: visitDurationData.length + 1,
|
|
157
|
-
value: _this4.VISITS_SUMMARY[key].avg_time_on_site ? _this4.VISITS_SUMMARY[key].avg_time_on_site : 0
|
|
158
|
-
});
|
|
159
188
|
});
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
countries = _context3.sent;
|
|
191
|
-
_context3.next = 6;
|
|
192
|
-
return matomoConnect.init(matomoConnect.GetCountrySummary, 'month', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
193
|
-
case 6:
|
|
194
|
-
countriesByMonth = _context3.sent;
|
|
195
|
-
countries.forEach(function (value, key) {
|
|
196
|
-
var bounceRateData = [];
|
|
197
|
-
var bounceRate = value.bounce_count * 100 / value.nb_visits;
|
|
198
|
-
bounceRate = parseFloat(bounceRate).toFixed(2);
|
|
199
|
-
Object.keys(countriesByMonth).forEach(function (byMonthKey) {
|
|
200
|
-
var object = {
|
|
201
|
-
date: bounceRateData.length + 1
|
|
202
|
-
};
|
|
203
|
-
countriesByMonth[byMonthKey].forEach(function (cv) {
|
|
204
|
-
if (cv.code === value.code) {
|
|
205
|
-
object.value = cv && cv.bounce_count ? cv.bounce_count : 0;
|
|
206
|
-
}
|
|
207
|
-
});
|
|
208
|
-
if (!object.value) {
|
|
209
|
-
object.value = 0;
|
|
210
|
-
}
|
|
211
|
-
bounceRateData.push(object);
|
|
212
|
-
});
|
|
213
|
-
graphData.push({
|
|
214
|
-
id: key,
|
|
215
|
-
country: value.code,
|
|
216
|
-
country_name: value.label,
|
|
217
|
-
visits: value.nb_visits,
|
|
218
|
-
unique_visitors: value.sum_daily_nb_uniq_visitors,
|
|
219
|
-
flag_url: "".concat(matomoConnect.MATOMO_API_URL, "/").concat(value.logo),
|
|
220
|
-
bounce_rate: "".concat(bounceRate, "%"),
|
|
221
|
-
chart: {
|
|
222
|
-
id: "countryChart".concat(key),
|
|
223
|
-
fill: '#E4ECF9',
|
|
224
|
-
stroke: '#0050CA',
|
|
225
|
-
data: bounceRateData
|
|
226
|
-
}
|
|
227
|
-
});
|
|
228
|
-
});
|
|
229
|
-
return _context3.abrupt("return", graphData);
|
|
230
|
-
case 9:
|
|
231
|
-
case "end":
|
|
232
|
-
return _context3.stop();
|
|
233
|
-
}
|
|
234
|
-
}, _callee3, this);
|
|
235
|
-
}));
|
|
236
|
-
function getCountryGraph() {
|
|
237
|
-
return _getCountryGraph.apply(this, arguments);
|
|
189
|
+
});
|
|
190
|
+
return graphData;
|
|
191
|
+
}
|
|
192
|
+
async getSocialGraph() {
|
|
193
|
+
const graphData = [];
|
|
194
|
+
const socials = await matomoConnect.init(matomoConnect.GetSocialSummary, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
195
|
+
socials.forEach((value, key) => {
|
|
196
|
+
let progress = value.sum_daily_nb_uniq_visitors * 100 / this.TOTAL_SUMMARY.unique_visitors;
|
|
197
|
+
progress = parseFloat(progress).toFixed(2);
|
|
198
|
+
graphData.push({
|
|
199
|
+
id: key,
|
|
200
|
+
network: "".concat(value.label.charAt(0).toUpperCase()).concat(value.label.slice(1)),
|
|
201
|
+
visitors: value.sum_daily_nb_uniq_visitors,
|
|
202
|
+
progress: parseFloat(progress)
|
|
203
|
+
});
|
|
204
|
+
});
|
|
205
|
+
return graphData;
|
|
206
|
+
}
|
|
207
|
+
async getDeviceGraph() {
|
|
208
|
+
const devices = await matomoConnect.init(matomoConnect.GetDeviceOsFamilies, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
209
|
+
const browsers = await matomoConnect.init(matomoConnect.GetDeviceBrowsers, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
210
|
+
const models = await matomoConnect.init(matomoConnect.GetDeviceModels, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
211
|
+
let desktop = 0;
|
|
212
|
+
let android = 0;
|
|
213
|
+
let ios = 0;
|
|
214
|
+
let other = 0;
|
|
215
|
+
let total = 0;
|
|
216
|
+
devices.forEach((value, key) => {
|
|
217
|
+
if (value.label === 'Android') {
|
|
218
|
+
android += value.nb_visits;
|
|
238
219
|
}
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
}, {
|
|
242
|
-
key: "getSocialGraph",
|
|
243
|
-
value: function () {
|
|
244
|
-
var _getSocialGraph = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4() {
|
|
245
|
-
var _this5 = this;
|
|
246
|
-
var graphData, socials;
|
|
247
|
-
return _regeneratorRuntime().wrap(function _callee4$(_context4) {
|
|
248
|
-
while (1) switch (_context4.prev = _context4.next) {
|
|
249
|
-
case 0:
|
|
250
|
-
graphData = [];
|
|
251
|
-
_context4.next = 3;
|
|
252
|
-
return matomoConnect.init(matomoConnect.GetSocialSummary, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
253
|
-
case 3:
|
|
254
|
-
socials = _context4.sent;
|
|
255
|
-
socials.forEach(function (value, key) {
|
|
256
|
-
var progress = value.sum_daily_nb_uniq_visitors * 100 / _this5.TOTAL_SUMMARY.unique_visitors;
|
|
257
|
-
progress = parseFloat(progress).toFixed(2);
|
|
258
|
-
graphData.push({
|
|
259
|
-
id: key,
|
|
260
|
-
network: "".concat(value.label.charAt(0).toUpperCase()).concat(value.label.slice(1)),
|
|
261
|
-
visitors: value.sum_daily_nb_uniq_visitors,
|
|
262
|
-
progress: parseFloat(progress)
|
|
263
|
-
});
|
|
264
|
-
});
|
|
265
|
-
return _context4.abrupt("return", graphData);
|
|
266
|
-
case 6:
|
|
267
|
-
case "end":
|
|
268
|
-
return _context4.stop();
|
|
269
|
-
}
|
|
270
|
-
}, _callee4, this);
|
|
271
|
-
}));
|
|
272
|
-
function getSocialGraph() {
|
|
273
|
-
return _getSocialGraph.apply(this, arguments);
|
|
220
|
+
if (value.label === 'iOS') {
|
|
221
|
+
ios += value.nb_visits;
|
|
274
222
|
}
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
}, {
|
|
278
|
-
key: "getDeviceGraph",
|
|
279
|
-
value: function () {
|
|
280
|
-
var _getDeviceGraph = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee5() {
|
|
281
|
-
var devices, browsers, models, desktop, android, ios, other, total, donutChart, deviceData, desktopBrowsers, desktopBrowsersTotal, iosModels, iosTotal, androidModels, androidTotal;
|
|
282
|
-
return _regeneratorRuntime().wrap(function _callee5$(_context5) {
|
|
283
|
-
while (1) switch (_context5.prev = _context5.next) {
|
|
284
|
-
case 0:
|
|
285
|
-
_context5.next = 2;
|
|
286
|
-
return matomoConnect.init(matomoConnect.GetDeviceOsFamilies, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
287
|
-
case 2:
|
|
288
|
-
devices = _context5.sent;
|
|
289
|
-
_context5.next = 5;
|
|
290
|
-
return matomoConnect.init(matomoConnect.GetDeviceBrowsers, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
291
|
-
case 5:
|
|
292
|
-
browsers = _context5.sent;
|
|
293
|
-
_context5.next = 8;
|
|
294
|
-
return matomoConnect.init(matomoConnect.GetDeviceModels, 'range', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
295
|
-
case 8:
|
|
296
|
-
models = _context5.sent;
|
|
297
|
-
desktop = 0;
|
|
298
|
-
android = 0;
|
|
299
|
-
ios = 0;
|
|
300
|
-
other = 0;
|
|
301
|
-
total = 0;
|
|
302
|
-
devices.forEach(function (value, key) {
|
|
303
|
-
if (value.label === 'Android') {
|
|
304
|
-
android += value.nb_visits;
|
|
305
|
-
}
|
|
306
|
-
if (value.label === 'iOS') {
|
|
307
|
-
ios += value.nb_visits;
|
|
308
|
-
}
|
|
309
|
-
if (value.label === 'Windows' || value.label === 'Mac' || value.label === 'GNU/Linux') {
|
|
310
|
-
desktop += value.nb_visits;
|
|
311
|
-
}
|
|
312
|
-
if (!['Windows', 'Mac', 'GNU/Linux', 'Android', 'iOS'].includes(value.label)) {
|
|
313
|
-
other += value.nb_visits;
|
|
314
|
-
}
|
|
315
|
-
});
|
|
316
|
-
total = android + ios + desktop + other;
|
|
317
|
-
donutChart = [{
|
|
318
|
-
name: 'Android',
|
|
319
|
-
value: android,
|
|
320
|
-
color: '#0050CA'
|
|
321
|
-
}, {
|
|
322
|
-
name: 'Other',
|
|
323
|
-
value: other,
|
|
324
|
-
color: '#69BD53'
|
|
325
|
-
}, {
|
|
326
|
-
name: 'IOS',
|
|
327
|
-
value: ios,
|
|
328
|
-
color: '#CEDDF5'
|
|
329
|
-
}, {
|
|
330
|
-
name: 'Desktop',
|
|
331
|
-
value: desktop,
|
|
332
|
-
color: '#EE220D'
|
|
333
|
-
}];
|
|
334
|
-
deviceData = {
|
|
335
|
-
Android: {
|
|
336
|
-
percent: Analytic.getPercent(android, total),
|
|
337
|
-
value: android
|
|
338
|
-
},
|
|
339
|
-
iOS: {
|
|
340
|
-
percent: Analytic.getPercent(ios, total),
|
|
341
|
-
value: ios
|
|
342
|
-
},
|
|
343
|
-
Desktop: {
|
|
344
|
-
percent: Analytic.getPercent(desktop, total),
|
|
345
|
-
value: desktop
|
|
346
|
-
},
|
|
347
|
-
Other: {
|
|
348
|
-
percent: Analytic.getPercent(other, total),
|
|
349
|
-
value: other
|
|
350
|
-
}
|
|
351
|
-
};
|
|
352
|
-
desktopBrowsers = [];
|
|
353
|
-
desktopBrowsersTotal = 0;
|
|
354
|
-
browsers.forEach(function (value, key) {
|
|
355
|
-
if (['Chrome', 'Firefox', 'Safari', 'Opera', 'Internet Explorer', 'Microsoft Edge', 'Vivaldi'].includes(value.label)) {
|
|
356
|
-
desktopBrowsersTotal += value.nb_visits;
|
|
357
|
-
}
|
|
358
|
-
});
|
|
359
|
-
browsers.forEach(function (value, key) {
|
|
360
|
-
if (['Chrome', 'Firefox', 'Safari', 'Opera', 'Internet Explorer', 'Microsoft Edge', 'Vivaldi'].includes(value.label)) {
|
|
361
|
-
desktopBrowsers.push({
|
|
362
|
-
label: value.label,
|
|
363
|
-
value: "".concat(value.nb_visits, " (").concat(Analytic.getPercent(value.nb_visits, desktopBrowsersTotal), "%)")
|
|
364
|
-
});
|
|
365
|
-
}
|
|
366
|
-
});
|
|
367
|
-
iosModels = [];
|
|
368
|
-
iosTotal = 0;
|
|
369
|
-
androidModels = [];
|
|
370
|
-
androidTotal = 0;
|
|
371
|
-
models.forEach(function (value, key) {
|
|
372
|
-
if (!value.label.includes('Generic') && value.label.includes('Apple')) {
|
|
373
|
-
iosTotal += value.nb_visits;
|
|
374
|
-
}
|
|
375
|
-
if (!value.label.includes('Generic') && !value.label.includes('Apple')) {
|
|
376
|
-
androidTotal += value.nb_visits;
|
|
377
|
-
}
|
|
378
|
-
});
|
|
379
|
-
models.forEach(function (value, key) {
|
|
380
|
-
if (!value.label.includes('Generic') && value.label.includes('Apple')) {
|
|
381
|
-
iosModels.push({
|
|
382
|
-
label: value.label,
|
|
383
|
-
value: "".concat(value.nb_visits, " (").concat(Analytic.getPercent(value.nb_visits, iosTotal), "%)")
|
|
384
|
-
});
|
|
385
|
-
}
|
|
386
|
-
if (!value.label.includes('Generic') && !value.label.includes('Apple')) {
|
|
387
|
-
androidModels.push({
|
|
388
|
-
label: value.label,
|
|
389
|
-
value: "".concat(value.nb_visits, " (").concat(Analytic.getPercent(value.nb_visits, androidTotal), "%)")
|
|
390
|
-
});
|
|
391
|
-
}
|
|
392
|
-
});
|
|
393
|
-
return _context5.abrupt("return", {
|
|
394
|
-
donutChart: donutChart,
|
|
395
|
-
deviceData: deviceData,
|
|
396
|
-
desktopBrowsers: desktopBrowsers,
|
|
397
|
-
iosModels: iosModels,
|
|
398
|
-
androidModels: androidModels
|
|
399
|
-
});
|
|
400
|
-
case 29:
|
|
401
|
-
case "end":
|
|
402
|
-
return _context5.stop();
|
|
403
|
-
}
|
|
404
|
-
}, _callee5, this);
|
|
405
|
-
}));
|
|
406
|
-
function getDeviceGraph() {
|
|
407
|
-
return _getDeviceGraph.apply(this, arguments);
|
|
223
|
+
if (value.label === 'Windows' || value.label === 'Mac' || value.label === 'GNU/Linux') {
|
|
224
|
+
desktop += value.nb_visits;
|
|
408
225
|
}
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
}, {
|
|
412
|
-
key: "getMonthSlider",
|
|
413
|
-
value: function () {
|
|
414
|
-
var _getMonthSlider = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee6() {
|
|
415
|
-
var response, data;
|
|
416
|
-
return _regeneratorRuntime().wrap(function _callee6$(_context6) {
|
|
417
|
-
while (1) switch (_context6.prev = _context6.next) {
|
|
418
|
-
case 0:
|
|
419
|
-
_context6.next = 2;
|
|
420
|
-
return matomoConnect.init(matomoConnect.GetVisitsSummary, 'day', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
421
|
-
case 2:
|
|
422
|
-
response = _context6.sent;
|
|
423
|
-
data = [];
|
|
424
|
-
Object.keys(response).forEach(function (key) {
|
|
425
|
-
var month = key.split('-');
|
|
426
|
-
var check = false;
|
|
427
|
-
data.forEach(function (value, k) {
|
|
428
|
-
if (value.title === "".concat(months[parseInt(month[1], 10) - 1], " ").concat(month[0])) {
|
|
429
|
-
check = true;
|
|
430
|
-
}
|
|
431
|
-
});
|
|
432
|
-
if (!check) {
|
|
433
|
-
data.push({
|
|
434
|
-
title: "".concat(months[parseInt(month[1], 10) - 1], " ").concat(month[0]),
|
|
435
|
-
values: [],
|
|
436
|
-
total: 0
|
|
437
|
-
});
|
|
438
|
-
}
|
|
439
|
-
data.forEach(function (value, k) {
|
|
440
|
-
if (value.title === "".concat(months[parseInt(month[1], 10) - 1], " ").concat(month[0])) {
|
|
441
|
-
value.values.push({
|
|
442
|
-
name: key.split('-')[2],
|
|
443
|
-
value: response[key].nb_uniq_visitors ? response[key].nb_uniq_visitors : 0
|
|
444
|
-
});
|
|
445
|
-
value.total += response[key].nb_uniq_visitors ? response[key].nb_uniq_visitors : 0;
|
|
446
|
-
}
|
|
447
|
-
});
|
|
448
|
-
});
|
|
449
|
-
return _context6.abrupt("return", data.reverse());
|
|
450
|
-
case 6:
|
|
451
|
-
case "end":
|
|
452
|
-
return _context6.stop();
|
|
453
|
-
}
|
|
454
|
-
}, _callee6, this);
|
|
455
|
-
}));
|
|
456
|
-
function getMonthSlider() {
|
|
457
|
-
return _getMonthSlider.apply(this, arguments);
|
|
226
|
+
if (!['Windows', 'Mac', 'GNU/Linux', 'Android', 'iOS'].includes(value.label)) {
|
|
227
|
+
other += value.nb_visits;
|
|
458
228
|
}
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
}
|
|
495
|
-
});
|
|
496
|
-
});
|
|
497
|
-
return _context7.abrupt("return", data.reverse());
|
|
498
|
-
case 6:
|
|
499
|
-
case "end":
|
|
500
|
-
return _context7.stop();
|
|
501
|
-
}
|
|
502
|
-
}, _callee7, this);
|
|
503
|
-
}));
|
|
504
|
-
function getYearSlider() {
|
|
505
|
-
return _getYearSlider.apply(this, arguments);
|
|
229
|
+
});
|
|
230
|
+
total = android + ios + desktop + other;
|
|
231
|
+
const donutChart = [{
|
|
232
|
+
name: 'Android',
|
|
233
|
+
value: android,
|
|
234
|
+
color: '#0050CA'
|
|
235
|
+
}, {
|
|
236
|
+
name: 'Other',
|
|
237
|
+
value: other,
|
|
238
|
+
color: '#69BD53'
|
|
239
|
+
}, {
|
|
240
|
+
name: 'IOS',
|
|
241
|
+
value: ios,
|
|
242
|
+
color: '#CEDDF5'
|
|
243
|
+
}, {
|
|
244
|
+
name: 'Desktop',
|
|
245
|
+
value: desktop,
|
|
246
|
+
color: '#EE220D'
|
|
247
|
+
}];
|
|
248
|
+
const deviceData = {
|
|
249
|
+
Android: {
|
|
250
|
+
percent: Analytic.getPercent(android, total),
|
|
251
|
+
value: android
|
|
252
|
+
},
|
|
253
|
+
iOS: {
|
|
254
|
+
percent: Analytic.getPercent(ios, total),
|
|
255
|
+
value: ios
|
|
256
|
+
},
|
|
257
|
+
Desktop: {
|
|
258
|
+
percent: Analytic.getPercent(desktop, total),
|
|
259
|
+
value: desktop
|
|
260
|
+
},
|
|
261
|
+
Other: {
|
|
262
|
+
percent: Analytic.getPercent(other, total),
|
|
263
|
+
value: other
|
|
506
264
|
}
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
key
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
var response, data;
|
|
514
|
-
return _regeneratorRuntime().wrap(function _callee8$(_context8) {
|
|
515
|
-
while (1) switch (_context8.prev = _context8.next) {
|
|
516
|
-
case 0:
|
|
517
|
-
_context8.next = 2;
|
|
518
|
-
return matomoConnect.init(matomoConnect.GetVisitsSummary, 'day', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
519
|
-
case 2:
|
|
520
|
-
response = _context8.sent;
|
|
521
|
-
data = [];
|
|
522
|
-
Object.keys(response).forEach(function (key) {
|
|
523
|
-
var startOfWeek = Moment(key).startOf('isoWeek');
|
|
524
|
-
var endOfWeek = Moment(key).endOf('isoWeek');
|
|
525
|
-
var slicedStartOfWeek = startOfWeek.toString().slice(4, 10); //15)
|
|
526
|
-
var slicedEndOfWeek = endOfWeek.toString().slice(4, 10); //15)
|
|
527
|
-
|
|
528
|
-
var day = Moment(key).format('ddd');
|
|
529
|
-
var check = false;
|
|
530
|
-
data.forEach(function (value, k) {
|
|
531
|
-
if (value.title === "".concat(slicedStartOfWeek, " - ").concat(slicedEndOfWeek)) {
|
|
532
|
-
check = true;
|
|
533
|
-
}
|
|
534
|
-
});
|
|
535
|
-
if (!check) {
|
|
536
|
-
data.push({
|
|
537
|
-
title: "".concat(slicedStartOfWeek, " - ").concat(slicedEndOfWeek),
|
|
538
|
-
values: []
|
|
539
|
-
});
|
|
540
|
-
}
|
|
541
|
-
data.forEach(function (value, k) {
|
|
542
|
-
if (value.title === "".concat(slicedStartOfWeek, " - ").concat(slicedEndOfWeek)) {
|
|
543
|
-
value.values.push({
|
|
544
|
-
name: day,
|
|
545
|
-
value: response[key].nb_uniq_visitors ? response[key].nb_uniq_visitors : 0
|
|
546
|
-
});
|
|
547
|
-
}
|
|
548
|
-
});
|
|
549
|
-
});
|
|
550
|
-
return _context8.abrupt("return", data.reverse());
|
|
551
|
-
case 6:
|
|
552
|
-
case "end":
|
|
553
|
-
return _context8.stop();
|
|
554
|
-
}
|
|
555
|
-
}, _callee8, this);
|
|
556
|
-
}));
|
|
557
|
-
function getWeekSlider() {
|
|
558
|
-
return _getWeekSlider.apply(this, arguments);
|
|
265
|
+
};
|
|
266
|
+
const desktopBrowsers = [];
|
|
267
|
+
let desktopBrowsersTotal = 0;
|
|
268
|
+
browsers.forEach((value, key) => {
|
|
269
|
+
if (['Chrome', 'Firefox', 'Safari', 'Opera', 'Internet Explorer', 'Microsoft Edge', 'Vivaldi'].includes(value.label)) {
|
|
270
|
+
desktopBrowsersTotal += value.nb_visits;
|
|
559
271
|
}
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
return _regeneratorRuntime().wrap(function _callee9$(_context9) {
|
|
568
|
-
while (1) switch (_context9.prev = _context9.next) {
|
|
569
|
-
case 0:
|
|
570
|
-
periods = {
|
|
571
|
-
'00': {
|
|
572
|
-
value: '12AM'
|
|
573
|
-
},
|
|
574
|
-
'01': {
|
|
575
|
-
value: '1AM'
|
|
576
|
-
},
|
|
577
|
-
'02': {
|
|
578
|
-
value: '2AM'
|
|
579
|
-
},
|
|
580
|
-
'03': {
|
|
581
|
-
value: '3AM'
|
|
582
|
-
},
|
|
583
|
-
'04': {
|
|
584
|
-
value: '4AM'
|
|
585
|
-
},
|
|
586
|
-
'05': {
|
|
587
|
-
value: '5AM'
|
|
588
|
-
},
|
|
589
|
-
'06': {
|
|
590
|
-
value: '6AM'
|
|
591
|
-
},
|
|
592
|
-
'07': {
|
|
593
|
-
value: '7AM'
|
|
594
|
-
},
|
|
595
|
-
'08': {
|
|
596
|
-
value: '8AM'
|
|
597
|
-
},
|
|
598
|
-
'09': {
|
|
599
|
-
value: '9AM'
|
|
600
|
-
},
|
|
601
|
-
10: {
|
|
602
|
-
value: '10AM'
|
|
603
|
-
},
|
|
604
|
-
11: {
|
|
605
|
-
value: '11AM'
|
|
606
|
-
},
|
|
607
|
-
12: {
|
|
608
|
-
value: '12PM'
|
|
609
|
-
},
|
|
610
|
-
13: {
|
|
611
|
-
value: '1PM'
|
|
612
|
-
},
|
|
613
|
-
14: {
|
|
614
|
-
value: '2PM'
|
|
615
|
-
},
|
|
616
|
-
15: {
|
|
617
|
-
value: '3PM'
|
|
618
|
-
},
|
|
619
|
-
16: {
|
|
620
|
-
value: '4PM'
|
|
621
|
-
},
|
|
622
|
-
17: {
|
|
623
|
-
value: '5PM'
|
|
624
|
-
},
|
|
625
|
-
18: {
|
|
626
|
-
value: '6PM'
|
|
627
|
-
},
|
|
628
|
-
19: {
|
|
629
|
-
value: '7PM'
|
|
630
|
-
},
|
|
631
|
-
20: {
|
|
632
|
-
value: '8PM'
|
|
633
|
-
},
|
|
634
|
-
21: {
|
|
635
|
-
value: '9PM'
|
|
636
|
-
},
|
|
637
|
-
22: {
|
|
638
|
-
value: '10PM'
|
|
639
|
-
},
|
|
640
|
-
23: {
|
|
641
|
-
value: '11PM'
|
|
642
|
-
},
|
|
643
|
-
24: {
|
|
644
|
-
value: '12PM'
|
|
645
|
-
}
|
|
646
|
-
};
|
|
647
|
-
uniqueData = {};
|
|
648
|
-
_context9.next = 4;
|
|
649
|
-
return matomoConnect.init(matomoConnect.GetVisitTimePerLocalTime, 'day', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
650
|
-
case 4:
|
|
651
|
-
response = _context9.sent;
|
|
652
|
-
Object.keys(response).forEach(function (key) {
|
|
653
|
-
var time = new Moment(key);
|
|
654
|
-
response[key].forEach(function (hour, k) {
|
|
655
|
-
var day = time.format('ddd').toUpperCase();
|
|
656
|
-
var uniqueId = "".concat(day, "-").concat(hour.label);
|
|
657
|
-
if (uniqueData[uniqueId] !== undefined) {
|
|
658
|
-
var datum = uniqueData[uniqueId];
|
|
659
|
-
// calculate an average value for all redundant data
|
|
660
|
-
datum.value = (datum.dataCount * datum.value + hour.nb_uniq_visitors) / (datum.dataCount + 1);
|
|
661
|
-
datum.dataCount += 1;
|
|
662
|
-
} else {
|
|
663
|
-
uniqueData[uniqueId] = {
|
|
664
|
-
group: day,
|
|
665
|
-
variable: periods[hour.label].value,
|
|
666
|
-
value: hour.nb_uniq_visitors,
|
|
667
|
-
dataCount: 1
|
|
668
|
-
};
|
|
669
|
-
}
|
|
670
|
-
});
|
|
671
|
-
});
|
|
672
|
-
data = Object.keys(uniqueData).map(function (uniqueId) {
|
|
673
|
-
var datum = uniqueData[uniqueId];
|
|
674
|
-
return {
|
|
675
|
-
group: datum.group,
|
|
676
|
-
variable: datum.variable,
|
|
677
|
-
value: datum.value
|
|
678
|
-
};
|
|
679
|
-
});
|
|
680
|
-
return _context9.abrupt("return", data);
|
|
681
|
-
case 8:
|
|
682
|
-
case "end":
|
|
683
|
-
return _context9.stop();
|
|
684
|
-
}
|
|
685
|
-
}, _callee9, this);
|
|
686
|
-
}));
|
|
687
|
-
function getHeatmap() {
|
|
688
|
-
return _getHeatmap.apply(this, arguments);
|
|
272
|
+
});
|
|
273
|
+
browsers.forEach((value, key) => {
|
|
274
|
+
if (['Chrome', 'Firefox', 'Safari', 'Opera', 'Internet Explorer', 'Microsoft Edge', 'Vivaldi'].includes(value.label)) {
|
|
275
|
+
desktopBrowsers.push({
|
|
276
|
+
label: value.label,
|
|
277
|
+
value: "".concat(value.nb_visits, " (").concat(Analytic.getPercent(value.nb_visits, desktopBrowsersTotal), "%)")
|
|
278
|
+
});
|
|
689
279
|
}
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
while (1) switch (_context10.prev = _context10.next) {
|
|
699
|
-
case 0:
|
|
700
|
-
_context10.next = 2;
|
|
701
|
-
return matomoConnect.init(matomoConnect.LiveGetCounters, 10, 'visitors');
|
|
702
|
-
case 2:
|
|
703
|
-
lastMinute = _context10.sent;
|
|
704
|
-
_context10.next = 5;
|
|
705
|
-
return matomoConnect.init(matomoConnect.LiveGetCounters, 60, 'visitors');
|
|
706
|
-
case 5:
|
|
707
|
-
lastHour = _context10.sent;
|
|
708
|
-
_context10.next = 8;
|
|
709
|
-
return matomoConnect.init(matomoConnect.LiveGetCounters, 120, 'visitors');
|
|
710
|
-
case 8:
|
|
711
|
-
last2Hours = _context10.sent;
|
|
712
|
-
increase = Analytic.getIncrease(last2Hours, lastMinute);
|
|
713
|
-
object = {
|
|
714
|
-
id: 'realTimeUsersStat',
|
|
715
|
-
title: 'realtime users',
|
|
716
|
-
value: lastMinute.toString(),
|
|
717
|
-
percent: isNaN(increase) ? 0 : parseFloat(parseFloat(increase).toFixed(1)),
|
|
718
|
-
chart: {
|
|
719
|
-
id: 'realTimeUsersChart',
|
|
720
|
-
fill: '#e4ecf9',
|
|
721
|
-
stroke: '#0050ca',
|
|
722
|
-
data: [{
|
|
723
|
-
date: 1,
|
|
724
|
-
value: last2Hours
|
|
725
|
-
}, {
|
|
726
|
-
date: 2,
|
|
727
|
-
value: lastHour
|
|
728
|
-
}, {
|
|
729
|
-
date: 3,
|
|
730
|
-
value: lastMinute
|
|
731
|
-
}]
|
|
732
|
-
}
|
|
733
|
-
};
|
|
734
|
-
return _context10.abrupt("return", object);
|
|
735
|
-
case 12:
|
|
736
|
-
case "end":
|
|
737
|
-
return _context10.stop();
|
|
738
|
-
}
|
|
739
|
-
}, _callee10);
|
|
740
|
-
}));
|
|
741
|
-
function getRealTimeUsersBasicGraph() {
|
|
742
|
-
return _getRealTimeUsersBasicGraph.apply(this, arguments);
|
|
280
|
+
});
|
|
281
|
+
const iosModels = [];
|
|
282
|
+
let iosTotal = 0;
|
|
283
|
+
const androidModels = [];
|
|
284
|
+
let androidTotal = 0;
|
|
285
|
+
models.forEach((value, key) => {
|
|
286
|
+
if (!value.label.includes('Generic') && value.label.includes('Apple')) {
|
|
287
|
+
iosTotal += value.nb_visits;
|
|
743
288
|
}
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
value
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
}
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
289
|
+
if (!value.label.includes('Generic') && !value.label.includes('Apple')) {
|
|
290
|
+
androidTotal += value.nb_visits;
|
|
291
|
+
}
|
|
292
|
+
});
|
|
293
|
+
models.forEach((value, key) => {
|
|
294
|
+
if (!value.label.includes('Generic') && value.label.includes('Apple')) {
|
|
295
|
+
iosModels.push({
|
|
296
|
+
label: value.label,
|
|
297
|
+
value: "".concat(value.nb_visits, " (").concat(Analytic.getPercent(value.nb_visits, iosTotal), "%)")
|
|
298
|
+
});
|
|
299
|
+
}
|
|
300
|
+
if (!value.label.includes('Generic') && !value.label.includes('Apple')) {
|
|
301
|
+
androidModels.push({
|
|
302
|
+
label: value.label,
|
|
303
|
+
value: "".concat(value.nb_visits, " (").concat(Analytic.getPercent(value.nb_visits, androidTotal), "%)")
|
|
304
|
+
});
|
|
305
|
+
}
|
|
306
|
+
});
|
|
307
|
+
return {
|
|
308
|
+
donutChart,
|
|
309
|
+
deviceData,
|
|
310
|
+
desktopBrowsers,
|
|
311
|
+
iosModels,
|
|
312
|
+
androidModels
|
|
313
|
+
};
|
|
314
|
+
}
|
|
315
|
+
async getMonthSlider() {
|
|
316
|
+
const response = await matomoConnect.init(matomoConnect.GetVisitsSummary, 'day', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
317
|
+
const data = [];
|
|
318
|
+
Object.keys(response).forEach(key => {
|
|
319
|
+
const month = key.split('-');
|
|
320
|
+
let check = false;
|
|
321
|
+
data.forEach((value, k) => {
|
|
322
|
+
if (value.title === "".concat(months[parseInt(month[1], 10) - 1], " ").concat(month[0])) {
|
|
323
|
+
check = true;
|
|
324
|
+
}
|
|
325
|
+
});
|
|
326
|
+
if (!check) {
|
|
327
|
+
data.push({
|
|
328
|
+
title: "".concat(months[parseInt(month[1], 10) - 1], " ").concat(month[0]),
|
|
329
|
+
values: [],
|
|
330
|
+
total: 0
|
|
331
|
+
});
|
|
332
|
+
}
|
|
333
|
+
data.forEach((value, k) => {
|
|
334
|
+
if (value.title === "".concat(months[parseInt(month[1], 10) - 1], " ").concat(month[0])) {
|
|
335
|
+
value.values.push({
|
|
336
|
+
name: key.split('-')[2],
|
|
337
|
+
value: response[key].nb_uniq_visitors ? response[key].nb_uniq_visitors : 0
|
|
338
|
+
});
|
|
339
|
+
value.total += response[key].nb_uniq_visitors ? response[key].nb_uniq_visitors : 0;
|
|
340
|
+
}
|
|
341
|
+
});
|
|
342
|
+
});
|
|
343
|
+
return data.reverse();
|
|
344
|
+
}
|
|
345
|
+
async getYearSlider() {
|
|
346
|
+
const data = [];
|
|
347
|
+
const response = await this.getMonthSlider();
|
|
348
|
+
response && response.reverse().forEach(month => {
|
|
349
|
+
const year = month.title.split(' ');
|
|
350
|
+
let check = false;
|
|
351
|
+
data.forEach((value, k) => {
|
|
352
|
+
if (value.title === "".concat(year[1])) {
|
|
353
|
+
check = true;
|
|
354
|
+
}
|
|
355
|
+
});
|
|
356
|
+
if (!check) {
|
|
357
|
+
data.push({
|
|
358
|
+
title: "".concat(year[1]),
|
|
359
|
+
values: []
|
|
360
|
+
});
|
|
769
361
|
}
|
|
770
|
-
|
|
771
|
-
|
|
362
|
+
data.forEach((value, k) => {
|
|
363
|
+
if (value.title === "".concat(year[1])) {
|
|
364
|
+
value.values.push({
|
|
365
|
+
name: "".concat(year[0]),
|
|
366
|
+
value: month.total || 0
|
|
367
|
+
});
|
|
368
|
+
}
|
|
369
|
+
});
|
|
370
|
+
});
|
|
371
|
+
return data.reverse();
|
|
372
|
+
}
|
|
373
|
+
async getWeekSlider() {
|
|
374
|
+
const response = await matomoConnect.init(matomoConnect.GetVisitsSummary, 'day', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
375
|
+
const data = [];
|
|
376
|
+
Object.keys(response).forEach(key => {
|
|
377
|
+
const startOfWeek = Moment(key).startOf('isoWeek');
|
|
378
|
+
const endOfWeek = Moment(key).endOf('isoWeek');
|
|
379
|
+
const slicedStartOfWeek = startOfWeek.toString().slice(4, 10); //15)
|
|
380
|
+
const slicedEndOfWeek = endOfWeek.toString().slice(4, 10); //15)
|
|
381
|
+
|
|
382
|
+
const day = Moment(key).format('ddd');
|
|
383
|
+
let check = false;
|
|
384
|
+
data.forEach((value, k) => {
|
|
385
|
+
if (value.title === "".concat(slicedStartOfWeek, " - ").concat(slicedEndOfWeek)) {
|
|
386
|
+
check = true;
|
|
387
|
+
}
|
|
388
|
+
});
|
|
389
|
+
if (!check) {
|
|
390
|
+
data.push({
|
|
391
|
+
title: "".concat(slicedStartOfWeek, " - ").concat(slicedEndOfWeek),
|
|
392
|
+
values: []
|
|
393
|
+
});
|
|
394
|
+
}
|
|
395
|
+
data.forEach((value, k) => {
|
|
396
|
+
if (value.title === "".concat(slicedStartOfWeek, " - ").concat(slicedEndOfWeek)) {
|
|
397
|
+
value.values.push({
|
|
398
|
+
name: day,
|
|
399
|
+
value: response[key].nb_uniq_visitors ? response[key].nb_uniq_visitors : 0
|
|
400
|
+
});
|
|
401
|
+
}
|
|
402
|
+
});
|
|
403
|
+
});
|
|
404
|
+
return data.reverse();
|
|
405
|
+
}
|
|
406
|
+
async getHeatmap() {
|
|
407
|
+
const periods = {
|
|
408
|
+
'00': {
|
|
409
|
+
value: '12AM'
|
|
410
|
+
},
|
|
411
|
+
'01': {
|
|
412
|
+
value: '1AM'
|
|
413
|
+
},
|
|
414
|
+
'02': {
|
|
415
|
+
value: '2AM'
|
|
416
|
+
},
|
|
417
|
+
'03': {
|
|
418
|
+
value: '3AM'
|
|
419
|
+
},
|
|
420
|
+
'04': {
|
|
421
|
+
value: '4AM'
|
|
422
|
+
},
|
|
423
|
+
'05': {
|
|
424
|
+
value: '5AM'
|
|
425
|
+
},
|
|
426
|
+
'06': {
|
|
427
|
+
value: '6AM'
|
|
428
|
+
},
|
|
429
|
+
'07': {
|
|
430
|
+
value: '7AM'
|
|
431
|
+
},
|
|
432
|
+
'08': {
|
|
433
|
+
value: '8AM'
|
|
434
|
+
},
|
|
435
|
+
'09': {
|
|
436
|
+
value: '9AM'
|
|
437
|
+
},
|
|
438
|
+
10: {
|
|
439
|
+
value: '10AM'
|
|
440
|
+
},
|
|
441
|
+
11: {
|
|
442
|
+
value: '11AM'
|
|
443
|
+
},
|
|
444
|
+
12: {
|
|
445
|
+
value: '12PM'
|
|
446
|
+
},
|
|
447
|
+
13: {
|
|
448
|
+
value: '1PM'
|
|
449
|
+
},
|
|
450
|
+
14: {
|
|
451
|
+
value: '2PM'
|
|
452
|
+
},
|
|
453
|
+
15: {
|
|
454
|
+
value: '3PM'
|
|
455
|
+
},
|
|
456
|
+
16: {
|
|
457
|
+
value: '4PM'
|
|
458
|
+
},
|
|
459
|
+
17: {
|
|
460
|
+
value: '5PM'
|
|
461
|
+
},
|
|
462
|
+
18: {
|
|
463
|
+
value: '6PM'
|
|
464
|
+
},
|
|
465
|
+
19: {
|
|
466
|
+
value: '7PM'
|
|
467
|
+
},
|
|
468
|
+
20: {
|
|
469
|
+
value: '8PM'
|
|
470
|
+
},
|
|
471
|
+
21: {
|
|
472
|
+
value: '9PM'
|
|
473
|
+
},
|
|
474
|
+
22: {
|
|
475
|
+
value: '10PM'
|
|
476
|
+
},
|
|
477
|
+
23: {
|
|
478
|
+
value: '11PM'
|
|
479
|
+
},
|
|
480
|
+
24: {
|
|
481
|
+
value: '12PM'
|
|
772
482
|
}
|
|
773
|
-
|
|
483
|
+
};
|
|
484
|
+
const uniqueData = {};
|
|
485
|
+
const response = await matomoConnect.init(matomoConnect.GetVisitTimePerLocalTime, 'day', "".concat(this.START_DATE.format('YYYY-MM-DD'), ",").concat(this.CURRENT_DATE.format('YYYY-MM-DD')));
|
|
486
|
+
Object.keys(response).forEach(key => {
|
|
487
|
+
const time = new Moment(key);
|
|
488
|
+
response[key].forEach((hour, k) => {
|
|
489
|
+
const day = time.format('ddd').toUpperCase();
|
|
490
|
+
const uniqueId = "".concat(day, "-").concat(hour.label);
|
|
491
|
+
if (uniqueData[uniqueId] !== undefined) {
|
|
492
|
+
const datum = uniqueData[uniqueId];
|
|
493
|
+
// calculate an average value for all redundant data
|
|
494
|
+
datum.value = (datum.dataCount * datum.value + hour.nb_uniq_visitors) / (datum.dataCount + 1);
|
|
495
|
+
datum.dataCount += 1;
|
|
496
|
+
} else {
|
|
497
|
+
uniqueData[uniqueId] = {
|
|
498
|
+
group: day,
|
|
499
|
+
variable: periods[hour.label].value,
|
|
500
|
+
value: hour.nb_uniq_visitors,
|
|
501
|
+
dataCount: 1
|
|
502
|
+
};
|
|
503
|
+
}
|
|
504
|
+
});
|
|
505
|
+
});
|
|
506
|
+
const data = Object.keys(uniqueData).map(uniqueId => {
|
|
507
|
+
const datum = uniqueData[uniqueId];
|
|
508
|
+
return {
|
|
509
|
+
group: datum.group,
|
|
510
|
+
variable: datum.variable,
|
|
511
|
+
value: datum.value
|
|
512
|
+
};
|
|
513
|
+
});
|
|
514
|
+
return data;
|
|
515
|
+
}
|
|
516
|
+
static getPercent(number, total) {
|
|
517
|
+
let percent = number * 100 / total;
|
|
518
|
+
percent = parseFloat(percent).toFixed(2);
|
|
519
|
+
return isNaN(parseFloat(percent)) ? 0 : parseFloat(percent);
|
|
520
|
+
}
|
|
521
|
+
static getIncrease() {
|
|
522
|
+
let min = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
|
|
523
|
+
let max = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
|
|
524
|
+
let increase = max - min;
|
|
525
|
+
increase = increase / min * 100;
|
|
526
|
+
return increase === Infinity && increase > 100 ? 100 : increase;
|
|
527
|
+
}
|
|
528
|
+
static getTimeSpent(value) {
|
|
529
|
+
let hours = '';
|
|
530
|
+
let minutes = '';
|
|
531
|
+
if (value.format('H') !== 0) {
|
|
532
|
+
hours = "".concat(value.format('H'), "h ");
|
|
774
533
|
}
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
}
|
|
534
|
+
if (value.format('m') !== 0) {
|
|
535
|
+
minutes = "".concat(value.format('m'), "m ");
|
|
536
|
+
}
|
|
537
|
+
return "".concat(hours).concat(minutes).concat(value.format('s'), "s");
|
|
538
|
+
}
|
|
539
|
+
}
|
|
778
540
|
exports.Analytic = Analytic;
|
|
779
|
-
var _default = Analytic;
|
|
780
|
-
exports.default = _default;
|
|
541
|
+
var _default = exports.default = Analytic;
|