More configuration options for paratimes#1441
Merged
Conversation
Deployed to Cloudflare Pages
|
1d2f7a7 to
b372e50
Compare
b372e50 to
a95185d
Compare
d265ec3 to
9e54fc2
Compare
Contributor
Author
|
Here is an example of using some of these features: b3f4ce9#diff-c3095d5010e65c52737a98a5d618ea24049ebe90c8470752426081d70ed6e012. (The resulting behavior can be seen at #1355) |
Contributor
Author
|
Since there are multiple, loosely connected things, I suggest reviewing commit by commit. |
01e6a93 to
fbe90b4
Compare
lukaw3d
approved these changes
Jun 6, 2024
| [Network.testnet]: {}, | ||
| } | ||
|
|
||
| export const specialScopePaths: Partial<Record<Network, Partial<Record<Layer, [string, string]>>>> = { |
Contributor
There was a problem hiding this comment.
idk how to clarify the structure better. Maybe:
Suggested change
| export const specialScopePaths: Partial<Record<Network, Partial<Record<Layer, [string, string]>>>> = { | |
| export const specialScopePaths: Partial<Record<Network, Partial<Record<Layer, [/** renamed network */ string, /** renamed layer */ string]>>>> = { |
or
Suggested change
| export const specialScopePaths: Partial<Record<Network, Partial<Record<Layer, [string, string]>>>> = { | |
| export const specialScopePaths: Partial<Record<`${Network}/${Layer}`, `${string}/${string}`>> = { | |
| 'testnet/pontusx': 'pontusx/test', | |
| } |
Normally, the name of a scope is derived by concatenating the name of the layer (i.e. "Sapphire") and the name of the network (i.e. "Testnet") ==> "Sapphire Testnet" However, in some specific cases, we might want to have something different. This can be achieved by this override function.
fbe90b4 to
669e4ec
Compare
Normally the "sapphire" paratime on the "testnet" network will be available via "testnet/sapphire". This commit adds a config option to override the paths for specific paratimes with any two-word constant. (So that we can use "magic/kingdom" instead of "testnet/sapphire", if we want to.)
This is mostly useful if we want to restrict a deployment to display only a few layers.
Up to now, this function has returned all the themes, for all networks. Now it will only return one theme, for the requested network.
669e4ec to
04a6871
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This PR adds support for: