mirror of
https://github.com/pezkuwichain/pwap.git
synced 2026-06-30 07:37:21 +00:00
c71ddb6e0d
- Clone Polkadot.js Apps repository - Update package.json with Pezkuwi branding - Add Pezkuwi endpoint to production chains (wss://pezkuwichain.app:9944) - Create comprehensive README for SDK UI - Set up project structure with all packages Next steps: - Apply Kurdistan colors (Kesk, Sor, Zer, Spi + Black) to UI theme - Replace logos with Pezkuwi branding - Test build and deployment
40 lines
1022 B
TypeScript
40 lines
1022 B
TypeScript
// Copyright 2017-2025 @polkadot/react-components authors & contributors
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
import React from 'react';
|
|
|
|
import { isString } from '@polkadot/util';
|
|
|
|
import Spinner from '../Spinner.js';
|
|
|
|
interface Props {
|
|
children?: React.ReactNode;
|
|
className?: string;
|
|
empty?: React.ReactNode | false;
|
|
emptySpinner?: React.ReactNode;
|
|
isEmpty: boolean;
|
|
noBodyTag?: boolean;
|
|
}
|
|
|
|
function Body ({ children, className = '', empty, emptySpinner, isEmpty, noBodyTag }: Props): React.ReactElement<Props> {
|
|
const bodyClassName = `${className} ui--Table-Body`;
|
|
|
|
return isEmpty
|
|
? (
|
|
<tbody className={bodyClassName}>
|
|
<tr>
|
|
<td colSpan={100}>{
|
|
isString(empty)
|
|
? <div className='empty'>{empty}</div>
|
|
: empty || <Spinner label={emptySpinner} />
|
|
}</td>
|
|
</tr>
|
|
</tbody>
|
|
)
|
|
: noBodyTag
|
|
? <>{children}</>
|
|
: <tbody className={bodyClassName}>{children}</tbody>;
|
|
}
|
|
|
|
export default React.memo(Body);
|