sending the alignment value straight from props instead of numbers
This commit is contained in:
@@ -92,13 +92,8 @@ class DataCell extends React.PureComponent {
|
||||
}
|
||||
let textAlignment = 'Right';
|
||||
const textAlignmentProp = styling.options.textAlignment;
|
||||
|
||||
if (textAlignmentProp === 1) {
|
||||
textAlignment = 'Left';
|
||||
} else if (textAlignmentProp === 2) {
|
||||
textAlignment = 'Center';
|
||||
} else {
|
||||
textAlignment = 'Right';
|
||||
if (textAlignmentProp) {
|
||||
textAlignment = textAlignmentProp;
|
||||
}
|
||||
|
||||
let cellStyle = {
|
||||
|
||||
@@ -189,19 +189,19 @@ const formatted = {
|
||||
component: 'buttongroup',
|
||||
options: [
|
||||
{
|
||||
value: 1,
|
||||
value: 'Left',
|
||||
label: 'Left'
|
||||
},
|
||||
{
|
||||
value: 2,
|
||||
value: 'Center',
|
||||
label: 'Center'
|
||||
},
|
||||
{
|
||||
value: 3,
|
||||
value: 'Right',
|
||||
label: 'Right'
|
||||
}
|
||||
],
|
||||
defaultValue: 3
|
||||
defaultValue: 'Right'
|
||||
},
|
||||
ColumnWidthSlider: {
|
||||
type: 'number',
|
||||
|
||||
Reference in New Issue
Block a user