π Open source, privacy-first web analytics β a cookie-less Google Analytics alternative with built-in error tracking and performance monitoring. Self-host it or use our cloud. Get started for free!
TypeScript chartsclickhousedockergdprgoogle-analyticsmetricsmonitoringmysqlnestjsprivacyredisself-hostedselfhostedstatisticstailwindcssweb-analyticswebanalyticswebsite
Merge branch 'main' into comments
Maksim Mrug7147d4d2e604
diff --cc src/pages/Project/View/ViewProject.tsxindex 4a9320fdc,980fae956..1295aab5e--- a/src/pages/Project/View/ViewProject.tsx+++ b/src/pages/Project/View/ViewProject.tsx@@@ -368,16 -294,14 +369,18 @@@ const ViewProject = (tnMapping.userFlow, // when fragment 1 is selected]+ // activeTabLabel is a label for active tab. Using for title in dropdownconst activeTabLabel = useMemo(() => _find(tabs, tab => tab.id === activeTab)?.label, [tabs, activeTab])+ // { name } is a project name from projectconst { name } = project- // sharedRoles is a role for shared project+ const pageTitle = user?.showLiveVisitorsInTitle ? `π ${liveStats[id]} - ${name}` : name-++const sharedRoles = useMemo(() => _find(user.sharedProjects, p => p.project.id === id)?.role || {}, [user, id])++ // sharedRoles is a role for shared project+ // chartMetrics is a list of metrics for dropdownconst chartMetrics = useMemo(() => {return [{@@@ -674,9 -578,8 +677,10 @@@} else {key = getProjectCacheKey(period, timeBucket)}--+++ // check if we need to load new date or we have data in redux/localstorage- if (!forced && !_isEmpty(cache[id]) && !_isEmpty(cache[id][key])) {+ if (!forced && !_isEmpty(cache[id]) && !_isEmpty(cache[id][key]) && !_isEmpty(newFilters || filters)) {++data = cache[id][key]} else {if (period === 'custom' && dateRange) {@@@ -1181,11 -1072,14 +1185,14 @@@}}, [isLoading, activeChartMetrics, chartData, chartDataPerf, activeChartMetricsPerf, dataChartCompare]) // eslint-disable-line- // Initialising Swetrix SDK instance+ // Initialising Swetrix SDK instance. Using for marketplace and extensionsuseEffect(() => {let sdk: any | null = null- if (!_isEmpty(extensions)) {- const processedExtensions = _map(extensions, (ext) => {++ const filteredExtensions = _filter(extensions, (ext) => _isString(ext.fileURL))++ if (!_isEmpty(filteredExtensions)) {+ const processedExtensions = _map(filteredExtensions, (ext) => {const { id: extId, fileURL } = extreturn {id: extId,@@@ -1419,9 -1308,8 +1426,9 @@@loadAnalyticsPerf()}}- }, [project, period, timeBucket, periodPairs, areFiltersParsed, areTimeBucketParsed, arePeriodParsed, t, activeTab, areFiltersPerfParsed]) // eslint-disable-line+ }, [project, period, chartType, filters, forecasedChartData, timeBucket, periodPairs, areFiltersParsed, areTimeBucketParsed, arePeriodParsed, t, activeTab, areFiltersPerfParsed]) // eslint-disable-line+ // using this for fix some bugs with update custom events data for chartuseEffect(() => {if (!_isEmpty(activeChartMetricsCustomEvents)) {setActiveChartMetricsCustomEvents([])