Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(web-analytics): Add overview stats #17722

Merged
merged 7 commits into from
Oct 3, 2023

Conversation

robbie-c
Copy link
Member

@robbie-c robbie-c commented Oct 2, 2023

Problem

Continuing web analytics

Changes

Add a new query for some overview stats
Move shared parts of some queries into a common file
Fix an issue with the pathname cte when there weren't any pageview events
Add an extremely basic grid layout, which is still very much WIP
Screenshot 2023-10-02 at 21 14 31
(the next step will be improving the UI)

How did you test this code?

(Behind FF) ran it

@robbie-c robbie-c marked this pull request as ready for review October 2, 2023 20:16
@robbie-c robbie-c requested review from mariusandra and Twixes October 2, 2023 20:17
@robbie-c robbie-c force-pushed the add-more-web-analytics-queries branch from 5f9c5c0 to e3f3470 Compare October 3, 2023 08:22
@robbie-c robbie-c changed the title feat(web-analytics): Add more web analytics queries feat(web-analytics): Add overview stats Oct 3, 2023
Copy link
Collaborator

@mariusandra mariusandra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good, just some suggestions to get this in line with out frontend guidelines.

frontend/src/scenes/web-analytics/WebDashboard.scss Outdated Show resolved Hide resolved
frontend/src/scenes/web-analytics/WebDashboard.tsx Outdated Show resolved Hide resolved
posthog/hogql_queries/web_analytics/top_sources.py Outdated Show resolved Hide resolved
@robbie-c robbie-c requested a review from mariusandra October 3, 2023 14:18
Copy link
Collaborator

@mariusandra mariusandra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I still believe you're over-engineering it with the CSS grid (e.g. did you think of mobile? we have had many problems with the grid on dashboards, etc...), and it would be better for everyone to just do:

<div className='space-y-2'>
  <div className='flex flex-col gap-2'>
    <div className='w-50 sm:w-full md:w-full'>{first_one}</div>
    <div className='w-50 sm:w-full md:w-full'>{second_one}</div>
  </div>
  <div>{third one}</div>
</div>

or something like that and call it a day.

Since this is feature flagged, I'll 🤷 now, but this will come back.

@robbie-c robbie-c force-pushed the add-more-web-analytics-queries branch from 4098219 to 080c450 Compare October 3, 2023 15:54
@robbie-c robbie-c force-pushed the add-more-web-analytics-queries branch from 080c450 to 7a092bd Compare October 3, 2023 16:03
@robbie-c robbie-c merged commit 3b4aaf0 into master Oct 3, 2023
@robbie-c robbie-c deleted the add-more-web-analytics-queries branch October 3, 2023 17:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants