-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #505 from dolittle/command-parameters-appearance
Command parameters appearance
- Loading branch information
Showing
15 changed files
with
428 additions
and
308 deletions.
There are no files selected for viewing
159 changes: 0 additions & 159 deletions
159
Source/DesignSystem/helpers/DummyContents/DummyDataGridContent.tsx
This file was deleted.
Oops, something went wrong.
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
35 changes: 35 additions & 0 deletions
35
Source/DesignSystem/molecules/DataGrid/DataGridSelectCell.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 |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// Copyright (c) Aigonix. All rights reserved. | ||
// Licensed under the MIT license. See LICENSE file in the project root for full license information. | ||
|
||
import React from 'react'; | ||
|
||
import { GridRenderCellParams } from '@mui/x-data-grid-pro'; | ||
|
||
import { Button } from '../../index'; | ||
|
||
const styles = { | ||
width: 1, | ||
height: 1, | ||
typography: 'body2', | ||
textTransform: 'none', | ||
}; | ||
|
||
/** | ||
* These styles are required for DataGrid to make the select cell the same size as the other cells. | ||
*/ | ||
// const styles = { | ||
// // Hack for secret cell active state. Otherwise size is going to be different. | ||
// '& .MuiOutlinedInput-root': { | ||
// '& .MuiSelect-select': { p: '5px 15px' }, | ||
// '& fieldset': { border: 'none' }, | ||
// }, | ||
// }; | ||
|
||
// TODO: Styles should be moved to the theme. | ||
// TODO: How to display the selected value label in the select cell? | ||
|
||
/** | ||
* Renders a select cell in 'view' mode in the DataGrid. | ||
*/ | ||
export const DataGridSelectCellView = (params: GridRenderCellParams) => | ||
<Button label={params.value} color='subtle' endWithIcon='ArrowDropDownRounded' sx={styles} />; |
Oops, something went wrong.