mirror of
https://github.com/apache/superset.git
synced 2026-06-08 17:19:20 +00:00
* adding custom expressions to adhoc metrics * adjusted transitions and made the box expandable * adding adhoc filters * adjusted based on feedback
23 lines
580 B
JavaScript
23 lines
580 B
JavaScript
import React from 'react';
|
|
import PropTypes from 'prop-types';
|
|
|
|
import ColumnTypeLabel from '../../components/ColumnTypeLabel';
|
|
import adhocMetricType from '../propTypes/adhocMetricType';
|
|
|
|
const propTypes = {
|
|
adhocMetric: adhocMetricType,
|
|
showType: PropTypes.bool,
|
|
};
|
|
|
|
export default function AdhocMetricStaticOption({ adhocMetric, showType }) {
|
|
return (
|
|
<div>
|
|
{showType && <ColumnTypeLabel type="expression" />}
|
|
<span className="m-r-5 option-label">
|
|
{adhocMetric.label}
|
|
</span>
|
|
</div>
|
|
);
|
|
}
|
|
AdhocMetricStaticOption.propTypes = propTypes;
|