Skip to content

Commit

Permalink
fix(dashboardeditor): bug fix in attribute form item
Browse files Browse the repository at this point in the history
  • Loading branch information
bryancboyd committed Sep 24, 2020
1 parent 0b65442 commit 9dcf741
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/components/CardEditor/CardEditForm/CardEditForm.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,17 @@ const AttributesFormItem = ({ value, onChange }) => {
size="small"
iconDescription="Add"
key="expandable-list-button-add"
onClick={() => onChange({})}
onClick={() =>
onChange(
value.concat([
{
dataSourceId: 'newAttr',
label: 'New',
unit: '%',
},
])
)
}
/>,
]}
items={value.map(attr => ({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
flex: 1;
overflow-y: auto;
margin: -$spacing-05;
height: 100%;
}
&--input {
padding: $spacing-05;
Expand Down

0 comments on commit 9dcf741

Please sign in to comment.