-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
220 Frontend deps: Material UI and React upgrade (#417)
* Upgrade React, Material UI * remove deprecated React 17 methods, fix styling lint errors * package-lock files * drop package-lock files * re-add notistack upgrade, package-lock * fix styled root applied by codemod * update types/react
- Loading branch information
1 parent
efe3435
commit d8b2e6a
Showing
57 changed files
with
2,439 additions
and
1,482 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
64 changes: 32 additions & 32 deletions
64
ccm_web/client/src/components/BulkEnrollUMUserConfirmationTable.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,32 @@ | ||
import React, { useState } from 'react' | ||
|
||
import CustomTable from './CustomTable' | ||
import { RowNumberedAddEnrollment } from '../models/enrollment' | ||
|
||
interface BulkEnrollUMUserConfirmationTableProps { | ||
enrollments: RowNumberedAddEnrollment[] | ||
} | ||
|
||
interface TableHeaderColumnInfoShouldUseMatUIType { | ||
id: keyof RowNumberedAddEnrollment | ||
label: string | ||
minWidth: number | ||
align?: 'left' | 'right' | undefined | ||
} | ||
|
||
const columns: TableHeaderColumnInfoShouldUseMatUIType[] = [ | ||
{ id: 'rowNumber', label: 'Row Number', minWidth: 25 }, | ||
{ id: 'loginId', label: 'Login ID', minWidth: 100 }, | ||
{ id: 'role', label: 'Role', minWidth: 100 } | ||
] | ||
|
||
function BulkEnrollUMUserConfirmationTable (props: BulkEnrollUMUserConfirmationTableProps): JSX.Element { | ||
const [page, setPage] = useState<number>(0) | ||
|
||
const tableRows = props.enrollments | ||
const caption = `Data was found for ${props.enrollments.length} enrollments.` | ||
|
||
return <CustomTable<RowNumberedAddEnrollment> {...{ tableRows, columns, page, setPage, caption }} /> | ||
} | ||
|
||
export default BulkEnrollUMUserConfirmationTable | ||
import React, { useState } from 'react' | ||
|
||
import CustomTable from './CustomTable' | ||
import { RowNumberedAddEnrollment } from '../models/enrollment' | ||
|
||
interface BulkEnrollUMUserConfirmationTableProps { | ||
enrollments: RowNumberedAddEnrollment[] | ||
} | ||
|
||
interface TableHeaderColumnInfoShouldUseMatUIType { | ||
id: keyof RowNumberedAddEnrollment | ||
label: string | ||
minWidth: number | ||
align?: 'left' | 'right' | undefined | ||
} | ||
|
||
const columns: TableHeaderColumnInfoShouldUseMatUIType[] = [ | ||
{ id: 'rowNumber', label: 'Row Number', minWidth: 25 }, | ||
{ id: 'loginId', label: 'Login ID', minWidth: 100 }, | ||
{ id: 'role', label: 'Role', minWidth: 100 } | ||
] | ||
|
||
function BulkEnrollUMUserConfirmationTable (props: BulkEnrollUMUserConfirmationTableProps): JSX.Element { | ||
const [page, setPage] = useState<number>(0) | ||
|
||
const tableRows = props.enrollments | ||
const caption = `Data was found for ${props.enrollments.length} enrollments.` | ||
|
||
return <CustomTable<RowNumberedAddEnrollment> {...{ tableRows, columns, page, setPage, caption }} /> | ||
} | ||
|
||
export default BulkEnrollUMUserConfirmationTable |
70 changes: 35 additions & 35 deletions
70
ccm_web/client/src/components/BulkSectionCreateUploadConfirmationTable.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,35 @@ | ||
import React, { useState } from 'react' | ||
import CustomTable from './CustomTable' | ||
|
||
interface Section { | ||
rowNumber: number | ||
sectionName: string | ||
} | ||
|
||
interface BulkSectionCreateUploadConfirmationTableProps { | ||
sectionNames: Section[] | ||
} | ||
|
||
interface TableHeaderColumnInfoShouldUseMatUIType { | ||
id: keyof Section | ||
label: string | ||
minWidth: number | ||
align?: 'left' | 'right' | undefined | ||
} | ||
|
||
const columns: TableHeaderColumnInfoShouldUseMatUIType[] = [ | ||
{ id: 'rowNumber', label: 'Row Number', minWidth: 25 }, | ||
{ id: 'sectionName', label: 'Section Name', minWidth: 100 } | ||
] | ||
|
||
function BulkSectionCreateUploadConfirmationTable (props: BulkSectionCreateUploadConfirmationTableProps): JSX.Element { | ||
const [page, setPage] = useState<number>(0) | ||
|
||
const tableRows = props.sectionNames.sort((a, b) => (a.rowNumber < b.rowNumber ? -1 : 1)) | ||
const caption = `Data was found for ${props.sectionNames.length} sections.` | ||
|
||
return <CustomTable<Section> {...{ tableRows, columns, page, setPage, caption }} /> | ||
} | ||
|
||
export type { BulkSectionCreateUploadConfirmationTableProps, Section } | ||
export default BulkSectionCreateUploadConfirmationTable | ||
import React, { useState } from 'react' | ||
import CustomTable from './CustomTable' | ||
|
||
interface Section { | ||
rowNumber: number | ||
sectionName: string | ||
} | ||
|
||
interface BulkSectionCreateUploadConfirmationTableProps { | ||
sectionNames: Section[] | ||
} | ||
|
||
interface TableHeaderColumnInfoShouldUseMatUIType { | ||
id: keyof Section | ||
label: string | ||
minWidth: number | ||
align?: 'left' | 'right' | undefined | ||
} | ||
|
||
const columns: TableHeaderColumnInfoShouldUseMatUIType[] = [ | ||
{ id: 'rowNumber', label: 'Row Number', minWidth: 25 }, | ||
{ id: 'sectionName', label: 'Section Name', minWidth: 100 } | ||
] | ||
|
||
function BulkSectionCreateUploadConfirmationTable (props: BulkSectionCreateUploadConfirmationTableProps): JSX.Element { | ||
const [page, setPage] = useState<number>(0) | ||
|
||
const tableRows = props.sectionNames.sort((a, b) => (a.rowNumber < b.rowNumber ? -1 : 1)) | ||
const caption = `Data was found for ${props.sectionNames.length} sections.` | ||
|
||
return <CustomTable<Section> {...{ tableRows, columns, page, setPage, caption }} /> | ||
} | ||
|
||
export type { BulkSectionCreateUploadConfirmationTableProps, Section } | ||
export default BulkSectionCreateUploadConfirmationTable |
Oops, something went wrong.