Skip to content

Commit

Permalink
Extract from 4c9bf4051299fe41259536bbfd00675e018e53a2
Browse files Browse the repository at this point in the history
  • Loading branch information
akeneo committed May 24, 2024
1 parent d5c1f1d commit 34b2a78
Show file tree
Hide file tree
Showing 44 changed files with 224 additions and 133 deletions.
15 changes: 8 additions & 7 deletions jest.unit.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module.exports = {
moduleFileExtensions: ['js', 'ts', 'tsx'],
moduleDirectories: ['node_modules', 'src'],
moduleNameMapper: {
"\\.(jpg|ico|jpeg|png|gif|svg|css)$": "<rootDir>/__mocks__/fileMock.js"
'\\.(jpg|ico|jpeg|png|gif|svg|css)$': '<rootDir>/__mocks__/fileMock.js',
},
roots: ['<rootDir>'],
setupFilesAfterEnv: ['@testing-library/jest-dom/extend-expect'],
Expand All @@ -18,12 +18,13 @@ module.exports = {
collectCoverageFrom: ['src/**/*.ts?(x)', '!**/*.visual.ts?(x)'],
cacheDirectory: '/tmp/jest',
coveragePathIgnorePatterns: [
'src/illustrations',
'src/icons',
'src/theme',
'src/storybook',
'generator',
'src/shared/PreviewGallery',
'src/illustrations',
'src/icons',
'src/theme',
'src/storybook',
'generator',
'src/shared/PreviewGallery',
'src/contexts',
],
coverageReporters: ['text-summary', 'html'],
coverageDirectory: 'coverage',
Expand Down
5 changes: 2 additions & 3 deletions lib/components/Input/TableInput/TableInput.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,10 @@ declare const TableInput: {
Body: React.ForwardRefExoticComponent<{
children?: React.ReactNode;
} & React.RefAttributes<HTMLTableSectionElement>>;
Row: React.ForwardRefExoticComponent<Omit<React.HTMLAttributes<HTMLTableRowElement>, "children" | "onDragEnd" | "onDragStart" | "highlighted" | "rowIndex"> & {
Row: React.ForwardRefExoticComponent<Omit<React.HTMLAttributes<HTMLTableRowElement>, "children" | "highlighted" | "rowIndex"> & {
children?: React.ReactNode;
highlighted?: boolean | undefined;
rowIndex?: number | undefined;
onDragStart?: ((rowIndex: number) => void) | undefined;
onDragEnd?: (() => void) | undefined;
} & React.RefAttributes<HTMLTableRowElement>>;
Cell: React.ForwardRefExoticComponent<React.TdHTMLAttributes<HTMLTableCellElement> & React.RefAttributes<HTMLTableCellElement>>;
CellContent: {
Expand Down Expand Up @@ -87,3 +85,4 @@ declare const TableInput: {
}>;
};
export { TableInput };
export type { TableInputProps };
4 changes: 3 additions & 1 deletion lib/components/Input/TableInput/TableInput.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/components/Input/TableInput/TableInput.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 4 additions & 6 deletions lib/components/Input/TableInput/TableInputBody/TableInputBody.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lib/components/Input/TableInput/TableInputContext.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
declare type TableInputContextType = {
readOnly: boolean;
isDragAndDroppable: boolean;
onReorder: ((reorderedIndices: number[]) => void) | undefined;
onReorder: ((reorderedIndices: number[], draggedIndex?: number, droppedIndex?: number) => void) | undefined;
};
declare const TableInputContext: import("react").Context<TableInputContextType>;
export { TableInputContext };
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,10 @@ export declare type TableInputRowProps = Override<HTMLAttributes<HTMLTableRowEle
children?: ReactNode;
highlighted?: boolean;
rowIndex?: number;
onDragStart?: (rowIndex: number) => void;
onDragEnd?: () => void;
}>;
declare const TableInputRow: React.ForwardRefExoticComponent<Omit<React.HTMLAttributes<HTMLTableRowElement>, "children" | "onDragEnd" | "onDragStart" | "highlighted" | "rowIndex"> & {
declare const TableInputRow: React.ForwardRefExoticComponent<Omit<React.HTMLAttributes<HTMLTableRowElement>, "children" | "highlighted" | "rowIndex"> & {
children?: ReactNode;
highlighted?: boolean | undefined;
rowIndex?: number | undefined;
onDragStart?: ((rowIndex: number) => void) | undefined;
onDragEnd?: (() => void) | undefined;
} & React.RefAttributes<HTMLTableRowElement>>;
export { TableInputRow };
12 changes: 7 additions & 5 deletions lib/components/Input/TableInput/TableInputRow/TableInputRow.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 34b2a78

Please sign in to comment.