This is an automated email from the ASF dual-hosted git repository.
yongjiezhao 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 4f000cc fix: bringing metric type icon styles into SelectControl
(#14531)
4f000cc is described below
commit 4f000cc8d1752f600d6dbff63a423294558948fe
Author: Evan Rusackas <[email protected]>
AuthorDate: Sat May 8 00:47:25 2021 -0700
fix: bringing metric type icon styles into SelectControl (#14531)
---
.../src/explore/components/controls/SelectControl.jsx | 14 ++++++++++++--
1 file changed, 12 insertions(+), 2 deletions(-)
diff --git
a/superset-frontend/src/explore/components/controls/SelectControl.jsx
b/superset-frontend/src/explore/components/controls/SelectControl.jsx
index 08b6e85..e310da2 100644
--- a/superset-frontend/src/explore/components/controls/SelectControl.jsx
+++ b/superset-frontend/src/explore/components/controls/SelectControl.jsx
@@ -18,7 +18,7 @@
*/
import React from 'react';
import PropTypes from 'prop-types';
-import { t } from '@superset-ui/core';
+import { t, css } from '@superset-ui/core';
import { Select, CreatableSelect, OnPasteSelect } from 'src/components/Select';
import ControlHeader from 'src/explore/components/ControlHeader';
@@ -294,7 +294,17 @@ export default class SelectControl extends
React.PureComponent {
}
return (
- <div>
+ <div
+ css={theme => css`
+ .type-label {
+ margin-right: ${theme.gridUnit * 2}px;
+ width: ${theme.gridUnit * 7}px;
+ display: inline-block;
+ text-align: center;
+ font-weight: ${theme.typography.weights.bold};
+ }
+ `}
+ >
{this.props.showHeader && <ControlHeader {...this.props} />}
{isMulti ? (
<OnPasteSelect {...selectProps} selectWrap={SelectComponent} />