Skip to content

Commit 66cfc73

Browse files
authored
change kanban group virtualization logic (#5664)
1 parent a4933b5 commit 66cfc73

File tree

6 files changed

+2
-10
lines changed

6 files changed

+2
-10
lines changed

web/core/components/core/render-if-visible-HOC.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ const RenderIfVisible: React.FC<Props> = (props) => {
7575
}, [isVisible, intersectionRef, shouldRecordHeights]);
7676

7777
const child = isVisible ? <>{children}</> : placeholderChildren;
78-
const style = isVisible || placeholderChildren ? {} : { height: placeholderHeight.current, width: "100%" };
78+
const style = isVisible || !shouldRecordHeights ? {} : { height: placeholderHeight.current, width: "100%" };
7979
const className = isVisible || placeholderChildren ? classNames : cn(classNames, "bg-custom-background-80");
8080

8181
return React.createElement(as, { ref: intersectionRef, style, className }, child);

web/core/components/issues/issue-layouts/kanban/default.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ export const KanBan: React.FC<IKanBan> = observer((props) => {
183183

184184
{groupByVisibilityToggle.showIssues && (
185185
<RenderIfVisible
186-
verticalOffset={0}
186+
verticalOffset={100}
187187
horizontalOffset={100}
188188
root={scrollableContainerRef}
189189
classNames="relative h-full"

web/core/components/issues/issue-layouts/list/block-root.tsx

-3
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ import { HIGHLIGHT_CLASS, getIssueBlockId, isIssueNew } from "../utils";
2323
import { TRenderQuickActions } from "./list-view-types";
2424

2525
type Props = {
26-
issueIds: string[];
2726
issueId: string;
2827
issuesMap: TIssueMap;
2928
updateIssue: ((projectId: string | null, issueId: string, data: Partial<TIssue>) => Promise<void>) | undefined;
@@ -44,7 +43,6 @@ type Props = {
4443

4544
export const IssueBlockRoot: FC<Props> = observer((props) => {
4645
const {
47-
issueIds,
4846
issueId,
4947
issuesMap,
5048
groupId,
@@ -161,7 +159,6 @@ export const IssueBlockRoot: FC<Props> = observer((props) => {
161159
subIssues?.map((subIssueId) => (
162160
<IssueBlockRoot
163161
key={`${subIssueId}`}
164-
issueIds={issueIds}
165162
issueId={subIssueId}
166163
issuesMap={issuesMap}
167164
updateIssue={updateIssue}

web/core/components/issues/issue-layouts/list/blocks-list.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ export const IssueBlocksList: FC<Props> = (props) => {
4343
issueIds.map((issueId: string, index: number) => (
4444
<IssueBlockRoot
4545
key={issueId}
46-
issueIds={issueIds}
4746
issueId={issueId}
4847
issuesMap={issuesMap}
4948
updateIssue={updateIssue}

web/core/components/issues/issue-layouts/spreadsheet/issue-row.tsx

-3
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,6 @@ interface Props {
3939
issueId: string;
4040
isScrolled: MutableRefObject<boolean>;
4141
containerRef: MutableRefObject<HTMLTableElement | null>;
42-
issueIds: string[];
4342
spreadsheetColumnsList: (keyof IIssueDisplayProperties)[];
4443
spacingLeft?: number;
4544
selectionHelpers: TSelectionHelper;
@@ -57,7 +56,6 @@ export const SpreadsheetIssueRow = observer((props: Props) => {
5756
canEditProperties,
5857
isScrolled,
5958
containerRef,
60-
issueIds,
6159
spreadsheetColumnsList,
6260
spacingLeft = 6,
6361
selectionHelpers,
@@ -124,7 +122,6 @@ export const SpreadsheetIssueRow = observer((props: Props) => {
124122
portalElement={portalElement}
125123
isScrolled={isScrolled}
126124
containerRef={containerRef}
127-
issueIds={issueIds}
128125
spreadsheetColumnsList={spreadsheetColumnsList}
129126
selectionHelpers={selectionHelpers}
130127
/>

web/core/components/issues/issue-layouts/spreadsheet/spreadsheet-table.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,6 @@ export const SpreadsheetTable = observer((props: Props) => {
125125
portalElement={portalElement}
126126
containerRef={containerRef}
127127
isScrolled={isScrolled}
128-
issueIds={issueIds}
129128
spreadsheetColumnsList={spreadsheetColumnsList}
130129
selectionHelpers={selectionHelpers}
131130
/>

0 commit comments

Comments
 (0)