Skip to content

added scroll to the Name column of the ClassTable #175

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/components/ClassTable.scss
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,8 @@
.ag-cell-normal-text {
color: var(--chakra-colors-fg);
}

.ag-cell.ag-column-last span{
overflow-x: auto;
text-overflow: unset;
}
15 changes: 5 additions & 10 deletions src/components/ClassTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -119,13 +119,10 @@ function ClassInput(props: {
const [classInput, setClassInput] = useState("");

// Search results for classes.
const searchResults = useRef<
Array<{
numbers: Array<string>;
name: string;
class: Class;
}>
>(undefined);
const searchResults =
useRef<Array<{ numbers: Array<string>; name: string; class: Class }>>(
undefined,
);

const processedRows = useMemo(
() =>
Expand Down Expand Up @@ -489,9 +486,7 @@ export function ClassTable(props: {
}, [state]);

const defaultColDef: ColDef<ClassTableRow, string> = useMemo(() => {
return {
resizable: false,
};
return { resizable: false };
}, []);

// Setup rows
Expand Down