mirror of
https://git.mirrors.martin98.com/https://github.com/SigNoz/signoz
synced 2025-08-01 01:14:03 +08:00

* fix: Chart data logic on dashboard reloads * fix: linting issues * fix: added right side loader & css config * fix: loader condition change * fix: linting issues * fix: error state of API * fix: Resolved suggested changes * fix: Error state for API Failed * fix: Default loading state * fix: linting issues * fix: Suggested changes * feat: Added common hook for previous value * chore: usePrevious is made type safety * chore: chart data set is updated * chore: removed eslint rule * fix: commitlint issue on commit Co-authored-by: Vishal Sharma <makeavish786@gmail.com> Co-authored-by: Palash Gupta <palashgdev@gmail.com> Co-authored-by: Srikanth Chekuri <srikanth.chekuri92@gmail.com>
29 lines
668 B
TypeScript
29 lines
668 B
TypeScript
import { LoadingOutlined } from '@ant-design/icons';
|
|
import { Spin, SpinProps } from 'antd';
|
|
import React from 'react';
|
|
|
|
import { SpinerStyle } from './styles';
|
|
|
|
function Spinner({ size, tip, height, style }: SpinnerProps): JSX.Element {
|
|
return (
|
|
<SpinerStyle height={height} style={style}>
|
|
<Spin spinning size={size} tip={tip} indicator={<LoadingOutlined spin />} />
|
|
</SpinerStyle>
|
|
);
|
|
}
|
|
|
|
interface SpinnerProps {
|
|
size?: SpinProps['size'];
|
|
tip?: SpinProps['tip'];
|
|
height?: React.CSSProperties['height'];
|
|
style?: React.CSSProperties;
|
|
}
|
|
Spinner.defaultProps = {
|
|
size: undefined,
|
|
tip: undefined,
|
|
height: undefined,
|
|
style: {},
|
|
};
|
|
|
|
export default Spinner;
|