fix: apps version build issue (#11678)
This commit is contained in:
parent
b5aa0e6de1
commit
df3b5caedf
@ -5,5 +5,6 @@ export * from './api/index.js';
|
||||
export * from './endpoints/index.js';
|
||||
export * from './extensions/index.js';
|
||||
export * from './links/index.js';
|
||||
export * from './packageInfo.js';
|
||||
export * from './settings/index.js';
|
||||
export * from './ui/index.js';
|
||||
|
||||
@ -1,7 +1,6 @@
|
||||
// Copyright 2017-2025 @polkadot/apps-config authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
import { packageInfo } from '../packageInfo.js';
|
||||
import { identityNodes, identitySpec } from './identityIcons/index.js';
|
||||
import { sanitize } from './util.js';
|
||||
|
||||
@ -12,7 +11,3 @@ export function getSystemIcon (systemName: string, specName: string): 'beachball
|
||||
'substrate'
|
||||
) as 'substrate';
|
||||
}
|
||||
|
||||
export function getPackageVersion () {
|
||||
return `apps v${packageInfo.version.replace('-x', '')}`;
|
||||
}
|
||||
|
||||
@ -5,14 +5,15 @@ import type { BareProps as Props } from '@polkadot/react-components/types';
|
||||
|
||||
import React from 'react';
|
||||
|
||||
import { getPackageVersion } from '@polkadot/apps-config';
|
||||
import { packageInfo } from '@polkadot/apps-config';
|
||||
import { styled } from '@polkadot/react-components';
|
||||
import { useApi } from '@polkadot/react-hooks';
|
||||
import { NodeName, NodeVersion } from '@polkadot/react-query';
|
||||
|
||||
const appsVersion = `apps v${packageInfo.version.replace('-x', '')}`;
|
||||
|
||||
function NodeInfo ({ className = '' }: Props): React.ReactElement<Props> {
|
||||
const { api, isApiReady } = useApi();
|
||||
const appsVersion = getPackageVersion();
|
||||
|
||||
return (
|
||||
<StyledDiv className={`${className} media--1400 highlight--color-contrast ui--NodeInfo`}>
|
||||
|
||||
@ -5,15 +5,16 @@ import type { BareProps as Props } from '@polkadot/react-components/types';
|
||||
|
||||
import React, { useRef } from 'react';
|
||||
|
||||
import { getPackageVersion } from '@polkadot/apps-config';
|
||||
import { packageInfo } from '@polkadot/apps-config';
|
||||
import { Input, Spinner, styled, Table } from '@polkadot/react-components';
|
||||
import { useApi } from '@polkadot/react-hooks';
|
||||
|
||||
import { useTranslation } from '../translate.js';
|
||||
|
||||
const appsVersion = `apps v${packageInfo.version.replace('-x', '')}`;
|
||||
|
||||
function SystemVersion ({ className }: Props): React.ReactElement<Props> {
|
||||
const { t } = useTranslation();
|
||||
const appsVersion = getPackageVersion();
|
||||
const { api, isApiReady, systemName, systemVersion } = useApi();
|
||||
|
||||
const headerRef = useRef<[React.ReactNode?, string?, number?][]>([
|
||||
|
||||
Loading…
Reference in New Issue
Block a user