fc -> plain
This commit is contained in:
1 parent
660346d2bc
commit
666d522ee9
21 files changed
+45
-58
No files matched your search
@@ -12,13 +12,13 @@ type BaseChartProps = React.PropsWithChildren<{
|
||||
maxWidth?: number | string;
|
||||
}>;
|
||||
|
||||
export const BaseChart: React.FC<BaseChartProps> = ({
|
||||
export const BaseChart = ({
|
||||
children,
|
||||
icon,
|
||||
title,
|
||||
width = "100%",
|
||||
maxWidth = "100%",
|
||||
}) => {
|
||||
}: BaseChartProps) => {
|
||||
const theme = useTheme();
|
||||
|
||||
return (
|
||||
|
||||
@@ -29,7 +29,7 @@ type XTickProps = {
|
||||
range: string;
|
||||
};
|
||||
|
||||
export const XTick: React.FC<XTickProps> = ({ x, y, payload, range }) => {
|
||||
export const XTick = ({ x, y, payload, range }: XTickProps) => {
|
||||
const format = tickDateFormatLookup(range);
|
||||
const theme = useTheme();
|
||||
const uiTimezone = useAppSelector((state: any) => state.ui.timezone);
|
||||
@@ -56,14 +56,14 @@ type ResponseTimeToolTipProps = {
|
||||
uiTimezone: string;
|
||||
};
|
||||
|
||||
const ResponseTimeToolTip: React.FC<ResponseTimeToolTipProps> = ({
|
||||
const ResponseTimeToolTip = ({
|
||||
active,
|
||||
payload,
|
||||
label,
|
||||
range,
|
||||
theme,
|
||||
uiTimezone,
|
||||
}) => {
|
||||
}: ResponseTimeToolTipProps) => {
|
||||
if (!label) return null;
|
||||
if (!payload) return null;
|
||||
if (!active) return null;
|
||||
|
||||
@@ -88,7 +88,7 @@ export const HistogramInfrastructure = ({
|
||||
range,
|
||||
title,
|
||||
type,
|
||||
idx,
|
||||
idx: _idx,
|
||||
checks,
|
||||
xKey,
|
||||
yDomain,
|
||||
@@ -156,7 +156,7 @@ export const HistogramInfrastructure = ({
|
||||
{dataKeys?.map((dataKey, index) => {
|
||||
const gradientId = `gradient-${uniqueId}-${index}`;
|
||||
return (
|
||||
<Fragment key={dataKey}>
|
||||
<Fragment key={`${dataKey}-${index}`}>
|
||||
{gradient === true &&
|
||||
createGradient({
|
||||
id: gradientId,
|
||||
|
||||
Reference in new issue
Block a user