Skip to content

Commit

Permalink
Add Jamton (#11123)
Browse files Browse the repository at this point in the history
* jamton endpoint and ui

* jamton apps-config

* lint
  • Loading branch information
alexxxkny authored Dec 10, 2024
1 parent 507107f commit a7212c7
Show file tree
Hide file tree
Showing 7 changed files with 140 additions and 1 deletion.
2 changes: 2 additions & 0 deletions packages/apps-config/src/api/spec/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ import imbue from './imbue.js';
import integritee from './integritee.js';
import interbtc from './interbtc.js';
import ipse from './ipse.js';
import jamton from './jamton.js';
import jupiter from './jupiter.js';
import jupiterRococo from './jupiter-rococo.js';
import jur from './jur.js';
Expand Down Expand Up @@ -220,6 +221,7 @@ const spec: Record<string, OverrideBundleDefinition> = {
'interbtc-standalone': interbtc,
'interlay-parachain': interbtc,
'ipse-node': ipse,
'jamton-runtime': jamton,
'jupiter-prep': jupiter,
'jupiter-rococo': jupiterRococo,
'jur-chain': jur,
Expand Down
59 changes: 59 additions & 0 deletions packages/apps-config/src/api/spec/jamton.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
// Copyright 2017-2024 @polkadot/apps-config authors & contributors
// SPDX-License-Identifier: Apache-2.0

import type { OverrideBundleDefinition } from '@polkadot/types/types';

/* eslint-disable sort-keys */
const definitions: OverrideBundleDefinition = {
types: [
{
// on all versions
minmax: [0, undefined],
types: {
StakingRates: {
collatorStakingRate: 'Perquintill',
collatorRewardRate: 'Perquintill',
delegatorStakingRate: 'Perquintill',
delegatorRewardRate: 'Perquintill'
},
AssetId: 'u32',
Balance: 'u128'
}
}
],
runtime: {
ParachainStaking: [
{
methods: {
get_staking_rates: {
description: 'Calculate the current staking and reward rates for collators and delegators',
params: [],
type: 'StakingRates'
},
get_unclaimed_staking_rewards: {
description: 'Calculate the claimable staking rewards for a given account address',
params: [
{
name: 'account',
type: 'AccountId32'
}
],
type: 'Balance'
}
},
version: 1
}
]
},
signedExtensions: {
ChargeAssetTxPayment: {
extrinsic: {
tip: 'Compact<Balance>',
assetId: 'Option<AssetId>'
},
payload: {}
}
}
};

export default definitions;
53 changes: 53 additions & 0 deletions packages/apps-config/src/api/typesBundle.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30120,6 +30120,59 @@ export const typesBundle = {
}
]
},
"jamton-runtime": {
"types": [
{
"minmax": [
0,
null
],
"types": {
"StakingRates": {
"collatorStakingRate": "Perquintill",
"collatorRewardRate": "Perquintill",
"delegatorStakingRate": "Perquintill",
"delegatorRewardRate": "Perquintill"
},
"AssetId": "u32",
"Balance": "u128"
}
}
],
"runtime": {
"ParachainStaking": [
{
"methods": {
"get_staking_rates": {
"description": "Calculate the current staking and reward rates for collators and delegators",
"params": [],
"type": "StakingRates"
},
"get_unclaimed_staking_rewards": {
"description": "Calculate the claimable staking rewards for a given account address",
"params": [
{
"name": "account",
"type": "AccountId32"
}
],
"type": "Balance"
}
},
"version": 1
}
]
},
"signedExtensions": {
"ChargeAssetTxPayment": {
"extrinsic": {
"tip": "Compact<Balance>",
"assetId": "Option<AssetId>"
},
"payload": {}
}
}
},
"jupiter-prep": {
"types": [
{
Expand Down
15 changes: 14 additions & 1 deletion packages/apps-config/src/endpoints/productionRelayPolkadot.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import type { EndpointOption } from './types.js';

import { POLKADOT_GENESIS } from '../api/constants.js';
import { chainsAcalaSVG, chainsBitgreenPNG, chainsComposableFinancePNG, chainsEquilibriumSVG, chainsFrequencySVG, chainsGeminisPNG, chainsHydrationSVG, chainsInvarchJPEG, chainsLaosPNG, chainsLogionPNG, chainsNeurowebPNG, chainsOakPNG, chainsPeaqPNG, chainsPendulumSVG, chainsPeoplePolkadotSVG, chainsPolkadotCircleSVG, chainsTotemSVG, chainsWatrPNG } from '../ui/logos/chains/index.js';
import { nodesAjunaPNG, nodesAresOdysseySVG, nodesAssetHubSVG, nodesAstarPNG, nodesAventusSVG, nodesBifrostSVG, nodesBridgeHubSVG, nodesCentrifugePNG, nodesCloverSVG, nodesCoinversationPNG, nodesContinuumPNG, nodesCrustParachainSVG, nodesDarwiniaSVG, nodesEfinitySVG, nodesEwxSVG, nodesHashedPNG, nodesHyperbridgePNG, nodesIntegriteeSVG, nodesInterlaySVG, nodesKiltPNG, nodesKylinPNG, nodesLitentryPNG, nodesMantaPNG, nodesMoonbeamSVG, nodesMoonsamaSVG, nodesMythosPNG, nodesNodleSVG, nodesOmnibtcSVG, nodesParallelSVG, nodesPhalaSVG, nodesPolimecSVG, nodesPolkadexSVG, nodesRobonomicsSVG, nodesSoraSubstrateSVG, nodesSubdaoPNG, nodesSubgameSVG, nodesSubsocialSVG, nodesT3rnPNG, nodesUniqueSVG, nodesZeitgeistPNG } from '../ui/logos/nodes/index.js';
import { nodesAjunaPNG, nodesAresOdysseySVG, nodesAssetHubSVG, nodesAstarPNG, nodesAventusSVG, nodesBifrostSVG, nodesBridgeHubSVG, nodesCentrifugePNG, nodesCloverSVG, nodesCoinversationPNG, nodesContinuumPNG, nodesCrustParachainSVG, nodesDarwiniaSVG, nodesEfinitySVG, nodesEwxSVG, nodesHashedPNG, nodesHyperbridgePNG, nodesIntegriteeSVG, nodesInterlaySVG, nodesJamtonSVG, nodesKiltPNG, nodesKylinPNG, nodesLitentryPNG, nodesMantaPNG, nodesMoonbeamSVG, nodesMoonsamaSVG, nodesMythosPNG, nodesNodleSVG, nodesOmnibtcSVG, nodesParallelSVG, nodesPhalaSVG, nodesPolimecSVG, nodesPolkadexSVG, nodesRobonomicsSVG, nodesSoraSubstrateSVG, nodesSubdaoPNG, nodesSubgameSVG, nodesSubsocialSVG, nodesT3rnPNG, nodesUniqueSVG, nodesZeitgeistPNG } from '../ui/logos/nodes/index.js';
import { getTeleports } from './util.js';

// The available endpoints that will show in the dropdown. For the most part (with the exception of
Expand Down Expand Up @@ -421,6 +421,19 @@ export const prodParasPolkadot: Omit<EndpointOption, 'teleport'>[] = [
logo: chainsInvarchJPEG
}
},
{
homepage: 'https://jamton.network/',
info: 'jamton',
paraId: 3397,
providers: {
Jamton: 'wss://rpc.jamton.network'
},
text: 'JAMTON',
ui: {
color: '#D33AD6',
logo: nodesJamtonSVG
}
},
{
homepage: 'https://totemaccounting.com/',
info: 'kapex',
Expand Down

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions packages/apps-config/src/ui/logos/nodes/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ export { nodesInvoPNG } from './generated/invoPNG.js';
export { nodesIpciSVG } from './generated/ipciSVG.js';
export { nodesIpsePNG } from './generated/ipsePNG.js';
export { nodesIpseSVG } from './generated/ipseSVG.js';
export { nodesJamtonSVG } from './generated/jamtonSVG.js';
export { nodesJazPNG } from './generated/jazPNG.js';
export { nodesJoystreamSVG } from './generated/joystreamSVG.js';
export { nodesJupiterSVG } from './generated/jupiterSVG.js';
Expand Down
5 changes: 5 additions & 0 deletions packages/apps-config/src/ui/logos/nodes/jamton.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit a7212c7

Please sign in to comment.