This is an automated email from the ASF dual-hosted git repository.
michaelsmolina pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/superset.git
The following commit(s) were added to refs/heads/master by this push:
new f6f93aad37 fix(cosmetic): cannot find m-r-10 class in superset.less
(#20276)
f6f93aad37 is described below
commit f6f93aad37e6258ec27af1b39335d0de9163210d
Author: jiAng <[email protected]>
AuthorDate: Fri Jun 17 19:54:27 2022 +0800
fix(cosmetic): cannot find m-r-10 class in superset.less (#20276)
* fix(cosmetic): cannot find m-r-10 class in superset.less
* fix: remove .m-r-10 class and use emotion instead
* Update superset-frontend/src/components/Datasource/CollectionTable.tsx
Co-authored-by: Michael S. Molina
<[email protected]>
* Update superset-frontend/src/components/Datasource/DatasourceEditor.jsx
Co-authored-by: Michael S. Molina
<[email protected]>
Co-authored-by: Michael S. Molina
<[email protected]>
---
.../src/components/Datasource/CollectionTable.tsx | 11 +++++++++--
.../src/components/Datasource/DatasourceEditor.jsx | 11 +++++++++--
2 files changed, 18 insertions(+), 4 deletions(-)
diff --git a/superset-frontend/src/components/Datasource/CollectionTable.tsx
b/superset-frontend/src/components/Datasource/CollectionTable.tsx
index 7ce0bfb95f..194d376579 100644
--- a/superset-frontend/src/components/Datasource/CollectionTable.tsx
+++ b/superset-frontend/src/components/Datasource/CollectionTable.tsx
@@ -130,6 +130,13 @@ const CrudButtonWrapper = styled.div`
${({ theme }) => `margin-bottom: ${theme.gridUnit * 2}px`}
`;
+const StyledButtonWrapper = styled.span`
+ ${({ theme }) => `
+ margin-top: ${theme.gridUnit * 3}px;
+ margin-left: ${theme.gridUnit * 3}px;
+ `}
+`;
+
export default class CRUDCollection extends React.PureComponent<
CRUDCollectionProps,
CRUDCollectionState
@@ -424,7 +431,7 @@ export default class CRUDCollection extends
React.PureComponent<
<>
<CrudButtonWrapper>
{this.props.allowAddItem && (
- <span className="m-t-10 m-r-10">
+ <StyledButtonWrapper>
<Button
buttonSize="small"
buttonStyle="tertiary"
@@ -434,7 +441,7 @@ export default class CRUDCollection extends
React.PureComponent<
<i data-test="crud-add-table-item" className="fa fa-plus" />{'
'}
{t('Add item')}
</Button>
- </span>
+ </StyledButtonWrapper>
)}
</CrudButtonWrapper>
<CrudTableWrapper
diff --git a/superset-frontend/src/components/Datasource/DatasourceEditor.jsx
b/superset-frontend/src/components/Datasource/DatasourceEditor.jsx
index 89ddcbdb81..94dd1241b0 100644
--- a/superset-frontend/src/components/Datasource/DatasourceEditor.jsx
+++ b/superset-frontend/src/components/Datasource/DatasourceEditor.jsx
@@ -123,6 +123,13 @@ const StyledColumnsTabWrapper = styled.div`
}
`;
+const StyledButtonWrapper = styled.span`
+ ${({ theme }) => `
+ margin-top: ${theme.gridUnit * 3}px;
+ margin-left: ${theme.gridUnit * 3}px;
+ `}
+`;
+
const checkboxGenerator = (d, onChange) => (
<CheckboxControl value={d} onChange={onChange} />
);
@@ -1361,7 +1368,7 @@ class DatasourceEditor extends React.PureComponent {
>
<StyledColumnsTabWrapper>
<ColumnButtonWrapper>
- <span className="m-t-10 m-r-10">
+ <StyledButtonWrapper>
<Button
buttonSize="small"
buttonStyle="tertiary"
@@ -1372,7 +1379,7 @@ class DatasourceEditor extends React.PureComponent {
<i className="fa fa-database" />{' '}
{t('Sync columns from source')}
</Button>
- </span>
+ </StyledButtonWrapper>
</ColumnButtonWrapper>
<ColumnCollectionTable
className="columns-table"