-
Notifications
You must be signed in to change notification settings - Fork 0
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
Implementing downloading/previewing metrics and geometries #13
Merged
Merged
Changes from 40 commits
Commits
Show all changes
70 commits
Select commit
Hold shift + click to select a range
9c6c5ff
Add popgetter to backend, add example interface for countries
sgreenbury 138c0d2
Update popgetter and polars git deps
sgreenbury 0ca595b
Move get countries to title page
sgreenbury 93e1d34
Remove JSON parse and add todo
sgreenbury 415145f
Add buffer, return metdata as JSON string
sgreenbury e394056
Update deps
sgreenbury f252f82
Add API for searching metadata and downloading data
sgreenbury 84ace2b
Add JS API, add rust_backend as local dep
sgreenbury 116e43e
Remove local dep on `rust_backend`
sgreenbury 2ed76fa
Add CountriesMode and display dataframe
sgreenbury 17069bb
Initial search mode
sgreenbury 29ff1d4
doc: adding build info to `README.md`
spool f454700
fix: include `Cargo.lock` in repository
spool 5018f9e
Initial DownloadMode and SearchParams
sgreenbury 55a36f5
Begin selected country logic
sgreenbury 33212db
Adding example download for a data request spec
sgreenbury 562eba8
Begin metadata cache implementation
sgreenbury 5e2588b
Add download data request methods
sgreenbury cabaa34
Begin show data on map
sgreenbury b339a0a
Add tailwind
sgreenbury ba905a2
Revise workflow, add country and level selection
sgreenbury b9e5bd9
Remove class for levels dropdown
sgreenbury f6b4654
Add selected metrics and preview drawer
sgreenbury 49afde7
Remove search params and countries mode
sgreenbury dd9022f
Begin adding preview
sgreenbury 1e60d21
Add workflow back
sgreenbury 647e4c4
Fixing preview
sgreenbury 521e4d5
Revise style of country and geometry selection modes
sgreenbury 7ed0683
Fix preview
sgreenbury f5d5d9a
Begin adding preview for map
sgreenbury 866535f
Fix preview for map
sgreenbury dcba8fa
Begin fixing automated scaling, remove unused imports
sgreenbury b26e134
Set min max from data
sgreenbury 7d4de3a
Replace strings with constants
sgreenbury 191be79
Fix text colours
sgreenbury 9f15e04
Add github workflow from web app template
sgreenbury bab7d0b
Remove dep on duckdb api server for static site
sgreenbury 63e32af
Update request to use bound box from map bounds
sgreenbury 0ca69ed
Add publish to workflow
sgreenbury da0d496
Add rust_backend pkg
sgreenbury 6d736fa
Fix publish_dir for sveltekit
sgreenbury 542e7a3
Update cache path, remove map_err
sgreenbury 539b422
Add debounce
sgreenbury 746a7b3
Add line layer
sgreenbury a4cb4e1
Add subtitle
sgreenbury 4c994b7
Fix tailwind and flowbite, add reactivity, layout
sgreenbury 24290ea
Add wrapping and fix buttons style
sgreenbury d0731aa
Add duckdb-wasm for metric previews
sgreenbury ac421eb
Refactor duckdb-wasm metrics request
sgreenbury 5d3be72
Refactor and fix table style
sgreenbury 7190e33
Add pmtiles, implement client side join with color mapping
sgreenbury f1d80d6
Add backend functionality for pmtiles
sgreenbury ebfd763
Make map component reactive to URL updates
sgreenbury e3a0571
Fix config path
sgreenbury 90f8140
Format and remove obsolete code
sgreenbury 030f100
Refactor duckdb with backend
sgreenbury 205031b
Rename Map to TilesMap
sgreenbury 05af840
Replace map with object types
sgreenbury fa5ae80
Initial download tab
sgreenbury fb498e7
Add download button and impl
sgreenbury c3f2043
Add todos and hoverState filter
sgreenbury ee48310
Begin hover
sgreenbury 6de3c86
Fix bounding box impl
sgreenbury 4e79dbe
Refactor download and save
sgreenbury 9c4ec3b
Add description, consts for classes, remove obsolete code
sgreenbury 73a2ad3
Fix search when no selected metrics, add pagination
sgreenbury 21e090c
Update backends with throw method
sgreenbury 516312b
Set default tileUrl to null
sgreenbury d69ce60
Set tileUrl to null in TitleMode
sgreenbury 45f8814
Include VectorTileSource if tileUrl not null
sgreenbury File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
on: | ||
pull_request: | ||
branches: [main] | ||
|
||
push: | ||
branches: [main] | ||
|
||
defaults: | ||
run: | ||
working-directory: popgetter-browser | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Install pnpm | ||
uses: pnpm/action-setup@v4 | ||
with: | ||
version: 9 | ||
|
||
- name: Install wasm-pack | ||
uses: jetli/[email protected] | ||
|
||
- name: Cache WASM build | ||
uses: actions/cache@v3 | ||
with: | ||
path: rust_backend/target | ||
key: rust_backend | ||
|
||
- name: Install dependencies for all packages | ||
run: | | ||
cd web/ | ||
pnpm install | ||
|
||
- name: Build web app | ||
run: | | ||
cd web | ||
pnpm rust-release | ||
pnpm build | ||
|
||
- name: Publish | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
publish_dir: ./web/dist/ | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,5 +7,4 @@ test-results/ | |
package-lock.json | ||
.svelte-kit/ | ||
|
||
rust_backend/Cargo.lock | ||
rust_backend/target/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,13 @@ | ||
# My new web app! | ||
# Popgetter-browser | ||
|
||
This is a simple web app that I have created using the UATP template. | ||
A web interface for the Popgetter project ([popgetter (data)](https://www.github.com/Urban-Analytics-Technology-Platform/popgetter), [popgetter (CLI, library, Python)](https://github.com/Urban-Analytics-Technology-Platform/popgetter-cli)). | ||
|
||
## Quickstart | ||
- Install [Rust](https://doc.rust-lang.org/book/ch01-01-installation.html) (Minimum Supported Version: 1.80) | ||
- Install [pnpm](https://pnpm.io/installation) | ||
- Run: | ||
```shell | ||
cd web | ||
pnpm rust | ||
pnpm dev | ||
``` |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Drive-by comment cause I'm excited to try this (without having to build myself): this should be
./web/build/
for sveltekitThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Amazing, was just trying to figure this out, thanks so much!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For future debugging:
4)
I've spent hours debugging GH actions/pages nonsense before. :( The other random trick that can sometimes help is to check if something like
wasm-pack
is generating a.gitingore
file in a directory you're trying to publish, because the action to commit to agh-pages
branch will pay attention to thatThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot for the suggestions @dabreegster, they were very helpful. With the empty
gh-pages
, the build was not being committed in the publish step and it turns outpublish_dir
does not combine with the specified defaultworking-directory
I specified in the workflow. So updating topublish_dir: popgetter-browser/web/build
fixed it.