forked from datacommonsorg/website
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve "place in" box on dev place pages (datacommonsorg#4774)
## 1) Fix long list of child places on continent place pages On continent place pages, the list of child places will contain places that are more than one level down in containment (e.g, showing municipalities, not just countries). This PR adds a child place type entry for continents to the child place fetch logic. ### Before: ![Screenshot 2024-12-05 at 6 18 26 PM](https://github.com/user-attachments/assets/40ff5f18-107b-451e-9657-b2d9c970c534) ### After: ![Screenshot 2024-12-05 at 6 18 33 PM](https://github.com/user-attachments/assets/c18eacb7-d2a3-4108-b844-713a81533466) ## 2) Add a "show more" toggle when the list of child places is long Sometimes the list of child places is very long, which overwhelms the page. This PR also adds a "show more" toggle when the number of child places is greater than 15. ### Long lists are truncated initially ![Screenshot 2024-12-09 at 9 57 08 AM](https://github.com/user-attachments/assets/8cd0747d-5322-4d05-b1dc-69cb3fb7a376) ### Show full list after clicking "show more" ![Screenshot 2024-12-05 at 6 12 25 PM](https://github.com/user-attachments/assets/764e48ee-5cda-4dad-9cf6-4e674dd05ca4) ### Short lists don't show a toggle ![Screenshot 2024-12-05 at 6 11 53 PM](https://github.com/user-attachments/assets/127796db-0bb9-4d25-ba88-237025afc810) ## 3) Replace place search with link to knowledge graph on current place pages In preparation for the changes made in PR datacommonsorg#4740, this PR also removes the place search bar to avoid showing users double search bars, and instead shows the DCID and a link to the knowledge graph entry, fixing a longstanding feature regression. Before: ![Screenshot 2024-12-09 at 11 53 21 AM](https://github.com/user-attachments/assets/6c1be20b-aaa4-47cc-8b41-8c592d538082) After: ![Screenshot 2024-12-09 at 11 47 12 AM](https://github.com/user-attachments/assets/04305558-9c62-4bb1-a2a8-66e5f713dab5)
- Loading branch information
Showing
7 changed files
with
56 additions
and
69 deletions.
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
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
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
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
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
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
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