Files
superset2/superset/assets/javascripts/explore/components/AggregateOption.jsx
Gabe Lyons 68dec24542 [Explore] Streamlined metric definitions for SQLA and Druid (#4663)
* adding streamlined metric editing

* addressing lint issues on new metrics control

* enabling druid
2018-03-28 17:41:29 -07:00

23 lines
578 B
JavaScript

import React from 'react';
import PropTypes from 'prop-types';
import ColumnTypeLabel from '../../components/ColumnTypeLabel';
import aggregateOptionType from '../propTypes/aggregateOptionType';
const propTypes = {
aggregate: aggregateOptionType,
showType: PropTypes.bool,
};
export default function AggregateOption({ aggregate, showType }) {
return (
<div>
{showType && <ColumnTypeLabel type="aggregate" />}
<span className="m-r-5 option-label">
{aggregate.aggregate_name}
</span>
</div>
);
}
AggregateOption.propTypes = propTypes;