mirror of
https://github.com/makeplane/plane
synced 2024-06-14 14:31:34 +00:00
fix: progress chart x-axis values (#1409)
* fix: x-axis dates value in the progress chart * chore: loader for active cycle
This commit is contained in:
parent
7f1def2041
commit
7fbf0e6358
@ -52,7 +52,7 @@ const ProgressChart: React.FC<Props> = ({ distribution, startDate, endDate, tota
|
|||||||
const maxDates = 4;
|
const maxDates = 4;
|
||||||
const totalDates = dates.length;
|
const totalDates = dates.length;
|
||||||
|
|
||||||
if (totalDates <= maxDates) return dates;
|
if (totalDates <= maxDates) return dates.map((d) => renderShortNumericDateFormat(d));
|
||||||
else {
|
else {
|
||||||
const interval = Math.ceil(totalDates / maxDates);
|
const interval = Math.ceil(totalDates / maxDates);
|
||||||
const limitedDates = [];
|
const limitedDates = [];
|
||||||
|
@ -101,6 +101,13 @@ export const ActiveCycleDetails: React.FC = () => {
|
|||||||
: null
|
: null
|
||||||
) as { data: IIssue[] | undefined };
|
) as { data: IIssue[] | undefined };
|
||||||
|
|
||||||
|
if (!currentCycle)
|
||||||
|
return (
|
||||||
|
<Loader>
|
||||||
|
<Loader.Item height="250px" />
|
||||||
|
</Loader>
|
||||||
|
);
|
||||||
|
|
||||||
if (!cycle)
|
if (!cycle)
|
||||||
return (
|
return (
|
||||||
<div className="flex w-full items-center justify-start rounded-[10px] bg-brand-surface-2 px-6 py-4">
|
<div className="flex w-full items-center justify-start rounded-[10px] bg-brand-surface-2 px-6 py-4">
|
||||||
|
Loading…
Reference in New Issue
Block a user