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

Add support for merging all networks in the layer selector #1688

Merged
merged 2 commits into from
Jan 21, 2025

Conversation

csillag
Copy link
Contributor

@csillag csillag commented Jan 14, 2025

This PR adds support for merging all networks in the layer selector,
so that instead of a hierarchical menu, we get a flat one.

On the Pontus-X instance, using this feature, instead of this:

image

and this:

image

We can have this:

image

Please note that you only want to activate this if you don't have
layers that are named the same on multiple networks.

(If you do, you can override names using the spacialScopeNames
config option in config.ts.)


Merging this PR doesn't change behavior, unless to turn the mergeNetworksInLayerSelector
flag from false to true.

Copy link

github-actions bot commented Jan 14, 2025

Deployed to Cloudflare Pages

Latest commit: c01a766c49d2fd5854eb432d7d26e889dc36a51a
Status:✅ Deploy successful!
Preview URL: https://91250e19.oasis-explorer.pages.dev
Alias: https://pr-1688.oasis-explorer.pages.dev

@csillag csillag force-pushed the csillag/support-flattened-layer-menu branch from 10c551a to 3455e63 Compare January 14, 2025 09:21
@csillag csillag marked this pull request as ready for review January 14, 2025 09:21
@csillag csillag force-pushed the csillag/support-flattened-layer-menu branch from 3455e63 to fb17ada Compare January 15, 2025 09:40
@csillag
Copy link
Contributor Author

csillag commented Jan 15, 2025

This can be seen in action at https://pr-1355.oasis-explorer.pages.dev/pontusx/dev

@csillag csillag force-pushed the csillag/support-flattened-layer-menu branch from fb17ada to b051b5b Compare January 18, 2025 02:54
@csillag csillag self-assigned this Jan 18, 2025
@csillag csillag force-pushed the csillag/support-flattened-layer-menu branch from b051b5b to 7b31f6e Compare January 20, 2025 14:52
.changelog/1866.trivial.md Outdated Show resolved Hide resolved
Include the name of the network for all layer menu items,
therefore eliminating the dependency of the layer menu
on the network menu.

The goal is that in the future, we can show the layer menu items
in other arrangements, not strictly following the separation
of the different networks.

Also, clean up internal architecture a naming a little bit.

There should be no functionality change.
@csillag csillag force-pushed the csillag/support-flattened-layer-menu branch 2 times, most recently from 81846df to 4ec03b8 Compare January 21, 2025 01:04
@csillag csillag requested a review from lukaw3d January 21, 2025 01:04
Please note that this only make sense if you don't have
layers that are named the same on multiple networks.

(If you do, you can override names using the spacialScopeNames
config option in config.ts.)
@csillag csillag force-pushed the csillag/support-flattened-layer-menu branch from 4ec03b8 to c01a766 Compare January 21, 2025 10:44
@csillag csillag enabled auto-merge January 21, 2025 10:45
@csillag csillag merged commit da46f7d into master Jan 21, 2025
8 checks passed
@csillag csillag deleted the csillag/support-flattened-layer-menu branch January 21, 2025 10:45
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