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: filter trains #279

Merged
merged 27 commits into from
Nov 8, 2023
Merged

feat: filter trains #279

merged 27 commits into from
Nov 8, 2023

Conversation

jqpe
Copy link
Owner

@jqpe jqpe commented Nov 5, 2023

Screencast.from.05.11.2023.15.30.25.webm

Allows user to filter trains by destination station

@jqpe jqpe added the feature New feature or request label Nov 5, 2023
Copy link

vercel bot commented Nov 5, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
junat-live ✅ Ready (Inspect) Visit Preview Nov 8, 2023 1:50pm
storybook ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 8, 2023 1:50pm

Copy link

github-actions bot commented Nov 5, 2023

📦 Next.js Bundle Analysis for junat.live

This analysis was generated by the Next.js Bundle Analysis action. 🤖

⚠️ Global Bundle Size Increased

Page Size (compressed)
global 183.33 KB (🟡 +218 B)
Details

The global bundle is the javascript bundle that loads alongside every page. It is in its own category because its impact is much higher - an increase to its size means that every page on your website loads slower, and a decrease means every page loads faster.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

If you want further insight into what is behind the changes, give @next/bundle-analyzer a try!

Three Pages Changed Size

The following pages changed size from the code in this PR compared to its base branch:

Page Size (compressed) First Load
/ 87.73 KB (🟡 +149 B) 271.06 KB
/[stationName] 103.03 KB (🔴 +36.64 KB) 286.36 KB
/train/[date]/[trainNumber] 37.09 KB (🟡 +153 B) 220.41 KB
Details

Only the gzipped size is provided here based on an expert tip.

First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If next/link is used, subsequent page loads would only need to download that page's bundle (the number in the "Size" column), since the global bundle has already been downloaded.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

Next to the size is how much the size has increased or decreased compared with the base branch of this PR. If this percentage has increased by 10% or more, there will be a red status indicator applied, indicating that special attention should be given to this.

Copy link

codecov bot commented Nov 5, 2023

Codecov Report

Merging #279 (cbba275) into main (0263392) will decrease coverage by 1.07%.
The diff coverage is 40.67%.

❗ Current head cbba275 differs from pull request most recent head 75748c7. Consider uploading reports for the commit 75748c7 to get more accurate results

@@            Coverage Diff             @@
##             main     #279      +/-   ##
==========================================
- Coverage   78.42%   77.35%   -1.07%     
==========================================
  Files         104      106       +2     
  Lines        1761     1815      +54     
  Branches      250      263      +13     
==========================================
+ Hits         1381     1404      +23     
- Misses        298      326      +28     
- Partials       82       85       +3     
Files Coverage Δ
site/src/components/dialog/index.tsx 90.00% <85.71%> (-10.00%) ⬇️
site/src/hooks/use_filters.ts 66.66% <66.66%> (ø)
...ite/src/components/station_dropdown_menu/index.tsx 77.77% <55.55%> (-7.94%) ⬇️
site/src/lib/digitraffic/hooks/use_live_trains.ts 4.16% <0.00%> (-4.93%) ⬇️
.../components/station_dropdown_menu/filter_train.tsx 40.74% <40.74%> (ø)

... and 2 files with indirect coverage changes

📣 Codecov offers a browser extension for seamless coverage viewing on GitHub. Try it in Chrome or Firefox today!

@vercel vercel bot temporarily deployed to Preview – storybook November 5, 2023 16:57 Inactive
Copy link

github-actions bot commented Nov 5, 2023

📦 Next.js Bundle Analysis for junat.live

This analysis was generated by the Next.js Bundle Analysis action. 🤖

⚠️ Global Bundle Size Increased

Page Size (compressed)
global 183.43 KB (🟡 +323 B)
Details

The global bundle is the javascript bundle that loads alongside every page. It is in its own category because its impact is much higher - an increase to its size means that every page on your website loads slower, and a decrease means every page loads faster.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

If you want further insight into what is behind the changes, give @next/bundle-analyzer a try!

Three Pages Changed Size

The following pages changed size from the code in this PR compared to its base branch:

Page Size (compressed) First Load
/ 87.73 KB (🟡 +149 B) 271.16 KB
/[stationName] 103.08 KB (🔴 +36.69 KB) 286.51 KB
/train/[date]/[trainNumber] 37.09 KB (🟡 +153 B) 220.52 KB
Details

Only the gzipped size is provided here based on an expert tip.

First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If next/link is used, subsequent page loads would only need to download that page's bundle (the number in the "Size" column), since the global bundle has already been downloaded.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

Next to the size is how much the size has increased or decreased compared with the base branch of this PR. If this percentage has increased by 10% or more, there will be a red status indicator applied, indicating that special attention should be given to this.

@vercel vercel bot temporarily deployed to Preview – junat-live November 5, 2023 16:59 Inactive
This reverts commit aaa6420.

Lets pretend we care about the quality and try to make this into 'stable' and then scream in agony as it breaks. Acceptance testing would be too easy.
const { data: stations = [] } = useStations()
const [selectedStation, setSelectedStation] =
React.useState<LocalizedStation | null>(null)
Copy link
Owner Author

Choose a reason for hiding this comment

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

Simplifying this to undefined instead of null so we can treat as an indicator that the form was reset. tailwindlabs/headlessui#2660

@vercel vercel bot temporarily deployed to Preview – junat-live November 8, 2023 13:34 Inactive
Copy link

github-actions bot commented Nov 8, 2023

📦 Next.js Bundle Analysis for junat.live

This analysis was generated by the Next.js Bundle Analysis action. 🤖

⚠️ Global Bundle Size Increased

Page Size (compressed)
global 183.33 KB (🟡 +223 B)
Details

The global bundle is the javascript bundle that loads alongside every page. It is in its own category because its impact is much higher - an increase to its size means that every page on your website loads slower, and a decrease means every page loads faster.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

If you want further insight into what is behind the changes, give @next/bundle-analyzer a try!

Three Pages Changed Size

The following pages changed size from the code in this PR compared to its base branch:

Page Size (compressed) First Load
/ 87.73 KB (🟡 +149 B) 271.07 KB
/[stationName] 103.06 KB (🔴 +36.68 KB) 286.39 KB
/train/[date]/[trainNumber] 37.09 KB (🟡 +153 B) 220.42 KB
Details

Only the gzipped size is provided here based on an expert tip.

First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If next/link is used, subsequent page loads would only need to download that page's bundle (the number in the "Size" column), since the global bundle has already been downloaded.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

Next to the size is how much the size has increased or decreased compared with the base branch of this PR. If this percentage has increased by 10% or more, there will be a red status indicator applied, indicating that special attention should be given to this.

@vercel vercel bot temporarily deployed to Preview – storybook November 8, 2023 13:36 Inactive
@vercel vercel bot temporarily deployed to Preview – storybook November 8, 2023 13:48 Inactive
Copy link

github-actions bot commented Nov 8, 2023

📦 Next.js Bundle Analysis for junat.live

This analysis was generated by the Next.js Bundle Analysis action. 🤖

⚠️ Global Bundle Size Increased

Page Size (compressed)
global 183.35 KB (🟡 +246 B)
Details

The global bundle is the javascript bundle that loads alongside every page. It is in its own category because its impact is much higher - an increase to its size means that every page on your website loads slower, and a decrease means every page loads faster.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

If you want further insight into what is behind the changes, give @next/bundle-analyzer a try!

Three Pages Changed Size

The following pages changed size from the code in this PR compared to its base branch:

Page Size (compressed) First Load
/ 87.73 KB (🟡 +149 B) 271.09 KB
/[stationName] 75.88 KB (🔴 +9.5 KB) 259.24 KB
/train/[date]/[trainNumber] 37.09 KB (🟡 +153 B) 220.44 KB
Details

Only the gzipped size is provided here based on an expert tip.

First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If next/link is used, subsequent page loads would only need to download that page's bundle (the number in the "Size" column), since the global bundle has already been downloaded.

Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis

Next to the size is how much the size has increased or decreased compared with the base branch of this PR. If this percentage has increased by 10% or more, there will be a red status indicator applied, indicating that special attention should be given to this.

@vercel vercel bot temporarily deployed to Preview – junat-live November 8, 2023 13:50 Inactive
@jqpe jqpe enabled auto-merge (squash) November 8, 2023 13:51
@jqpe jqpe merged commit 547c7de into main Nov 8, 2023
7 checks passed
@jqpe jqpe deleted the feat/filter-trains branch November 8, 2023 13:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant