mirror of
https://github.com/pezkuwichain/pwap.git
synced 2026-08-01 07:15:41 +00:00
971df8edba
- Remove all 3rd party parachain configurations from endpoints: - productionRelayPolkadot.ts: Keep only system parachains - productionRelayDicle.ts: Keep only system parachains - testingRelayZagros.ts: Keep only system parachains - testingRelayTeyrChain.ts: Keep only system parachains - Update domain references: - polkadot.js.org → pezkuwichain.app - wiki.polkadot.network → wiki.pezkuwichain.io - dotapps.io → pezkuwichain.app - statement.polkadot.network → docs.pezkuwichain.io/statement - support.polkadot.network → docs.pezkuwichain.io - Update repository references: - github.com/pezkuwi-js/apps → github.com/pezkuwichain/pwap - Rename system parachains to Pezkuwi ecosystem: - PolkadotAssetHub → PezkuwiAssetHub - polkadotBridgeHub → pezkuwiBridgeHub - polkadotCollectives → pezkuwiCollectives - polkadotCoretime → pezkuwiCoretime - polkadotPeople → pezkuwiPeople - Update network name in claims utility: - Polkadot → Pezkuwi
111 lines
3.1 KiB
TypeScript
111 lines
3.1 KiB
TypeScript
// Copyright 2017-2026 @pezkuwi/apps-config authors & contributors
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
import type { TFunction, TOptions } from '../types.js';
|
|
import type { LinkOption } from './types.js';
|
|
|
|
import { createCustom, createDev, createOwn } from './development.js';
|
|
import { prodChains, prodRelayDicle, prodRelayPolkadot } from './production.js';
|
|
import { testChains, testRelayZagros } from './testing.js';
|
|
import { testRelayTeyrChain } from './testingRelayTeyrChain.js';
|
|
import { expandEndpoints } from './util.js';
|
|
|
|
export { CUSTOM_ENDPOINT_KEY } from './development.js';
|
|
export * from './production.js';
|
|
export * from './testing.js';
|
|
|
|
function defaultT (keyOrText: string, text?: string | TOptions, options?: TOptions): string {
|
|
return (
|
|
(options?.replace?.host as string) ||
|
|
text?.toString() ||
|
|
keyOrText
|
|
);
|
|
}
|
|
|
|
export function createWsEndpoints (t: TFunction = defaultT, firstOnly = false, withSort = true): LinkOption[] {
|
|
return [
|
|
...createCustom(t),
|
|
{
|
|
isDisabled: false,
|
|
isHeader: true,
|
|
isSpaced: true,
|
|
text: t('rpc.header.favorite', 'Favorite chains', { ns: 'apps-config' }),
|
|
textBy: '',
|
|
ui: {},
|
|
value: ''
|
|
},
|
|
{
|
|
isDisabled: false,
|
|
isHeader: true,
|
|
isSpaced: true,
|
|
text: t('rpc.header.polkadot.relay', 'Polkadot & teyrchains', { ns: 'apps-config' }),
|
|
textBy: '',
|
|
ui: {},
|
|
value: ''
|
|
},
|
|
...expandEndpoints(t, [prodRelayPolkadot], firstOnly, withSort),
|
|
{
|
|
isDisabled: false,
|
|
isHeader: true,
|
|
isSpaced: true,
|
|
text: t('rpc.header.kusama.relay', 'Dicle & teyrchains', { ns: 'apps-config' }),
|
|
textBy: '',
|
|
ui: {},
|
|
value: ''
|
|
},
|
|
...expandEndpoints(t, [prodRelayDicle], firstOnly, withSort),
|
|
{
|
|
isDisabled: false,
|
|
isHeader: true,
|
|
isSpaced: true,
|
|
text: t('rpc.header.westend.relay', 'Test Zagros & teyrchains', { ns: 'apps-config' }),
|
|
textBy: '',
|
|
ui: {},
|
|
value: ''
|
|
},
|
|
...expandEndpoints(t, [testRelayZagros], firstOnly, withSort),
|
|
{
|
|
isDisabled: false,
|
|
isHeader: true,
|
|
isSpaced: true,
|
|
text: t('rpc.header.paseo.relay', 'Test TeyrChain & teyrchains', { ns: 'apps-config' }),
|
|
textBy: '',
|
|
ui: {},
|
|
value: ''
|
|
},
|
|
...expandEndpoints(t, [testRelayTeyrChain], firstOnly, withSort),
|
|
{
|
|
isDisabled: false,
|
|
isHeader: true,
|
|
isSpaced: true,
|
|
text: t('rpc.header.live', 'Live networks', { ns: 'apps-config' }),
|
|
textBy: '',
|
|
ui: {},
|
|
value: ''
|
|
},
|
|
...expandEndpoints(t, prodChains, firstOnly, withSort),
|
|
{
|
|
isDisabled: false,
|
|
isHeader: true,
|
|
isSpaced: true,
|
|
text: t('rpc.header.test', 'Test networks', { ns: 'apps-config' }),
|
|
textBy: '',
|
|
ui: {},
|
|
value: ''
|
|
},
|
|
...expandEndpoints(t, testChains, firstOnly, withSort),
|
|
{
|
|
isDevelopment: true,
|
|
isDisabled: false,
|
|
isHeader: true,
|
|
isSpaced: true,
|
|
text: t('rpc.header.dev', 'Development', { ns: 'apps-config' }),
|
|
textBy: '',
|
|
ui: {},
|
|
value: ''
|
|
},
|
|
...createDev(t),
|
|
...createOwn(t)
|
|
].filter(({ isDisabled }) => !isDisabled);
|
|
}
|