williaster closed pull request #6290: [reviewable] [refactor] Split visTypes 
into one file for each visualization type
URL: https://github.com/apache/incubator-superset/pull/6290
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/superset/assets/src/explore/components/ControlPanelsContainer.jsx 
b/superset/assets/src/explore/components/ControlPanelsContainer.jsx
index 7730a02eb9..ddc3b2365c 100644
--- a/superset/assets/src/explore/components/ControlPanelsContainer.jsx
+++ b/superset/assets/src/explore/components/ControlPanelsContainer.jsx
@@ -6,7 +6,7 @@ import { connect } from 'react-redux';
 import { Alert, Tab, Tabs } from 'react-bootstrap';
 import { t } from '@superset-ui/translation';
 
-import visTypes, { sectionsToRender } from '../visTypes';
+import controlPanelConfigs, { sectionsToRender } from '../controlPanels';
 import ControlPanelSection from './ControlPanelSection';
 import ControlRow from './ControlRow';
 import Control from './Control';
@@ -40,7 +40,8 @@ class ControlPanelsContainer extends React.Component {
     let mapF = controls[controlName].mapStateToProps;
 
     // Looking to find mapStateToProps override for this viz type
-    const controlOverrides = 
visTypes[this.props.controls.viz_type.value].controlOverrides || {};
+    const config = 
controlPanelConfigs[this.props.controls.viz_type.value].controlOverrides;
+    const controlOverrides = config || {};
     if (controlOverrides[controlName] && 
controlOverrides[controlName].mapStateToProps) {
       mapF = controlOverrides[controlName].mapStateToProps;
     }
diff --git a/superset/assets/src/explore/controlPanels/Area.js 
b/superset/assets/src/explore/controlPanels/Area.js
new file mode 100644
index 0000000000..2bf1e91660
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Area.js
@@ -0,0 +1,48 @@
+import { t } from '@superset-ui/translation';
+import { NVD3TimeSeries, annotations } from './sections';
+import { D3_TIME_FORMAT_OPTIONS } from '../controls';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    NVD3TimeSeries[0],
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['show_brush', 'show_legend'],
+        ['line_interpolation', 'stacked_style'],
+        ['color_scheme'],
+        ['rich_tooltip', 'show_controls'],
+      ],
+    },
+    {
+      label: t('X Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['x_axis_label', 'bottom_margin'],
+        ['x_ticks_layout', 'x_axis_format'],
+        ['x_axis_showminmax', null],
+      ],
+    },
+    {
+      label: t('Y Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['y_axis_format', 'y_axis_bounds'],
+        ['y_log_scale', null],
+      ],
+    },
+    NVD3TimeSeries[1],
+    annotations,
+  ],
+  controlOverrides: {
+    x_axis_format: {
+      default: 'smart_date',
+      choices: D3_TIME_FORMAT_OPTIONS,
+    },
+    color_scheme: {
+      renderTrigger: false,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Bar.js 
b/superset/assets/src/explore/controlPanels/Bar.js
new file mode 100644
index 0000000000..3629f6fe95
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Bar.js
@@ -0,0 +1,47 @@
+import { t } from '@superset-ui/translation';
+import { NVD3TimeSeries, annotations } from './sections';
+import { D3_TIME_FORMAT_OPTIONS } from '../controls';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    NVD3TimeSeries[0],
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['show_brush', 'show_legend', 'show_bar_value'],
+        ['rich_tooltip', 'bar_stacked'],
+        ['line_interpolation', 'show_controls'],
+        ['bottom_margin'],
+      ],
+    },
+    {
+      label: t('X Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['x_axis_label', 'bottom_margin'],
+        ['x_ticks_layout', 'x_axis_format'],
+        ['x_axis_showminmax', 'reduce_x_ticks'],
+      ],
+    },
+    {
+      label: t('Y Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['y_axis_label', 'left_margin'],
+        ['y_axis_showminmax', 'y_log_scale'],
+        ['y_axis_format', 'y_axis_bounds'],
+      ],
+    },
+    NVD3TimeSeries[1],
+    annotations,
+  ],
+  controlOverrides: {
+    x_axis_format: {
+      choices: D3_TIME_FORMAT_OPTIONS,
+      default: 'smart_date',
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/BigNumber.js 
b/superset/assets/src/explore/controlPanels/BigNumber.js
new file mode 100644
index 0000000000..9f3a978e0a
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/BigNumber.js
@@ -0,0 +1,29 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metric'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['compare_lag', 'compare_suffix'],
+        ['y_axis_format', null],
+        ['show_trend_line', 'start_y_axis_at_zero'],
+        ['color_picker', null],
+      ],
+    },
+  ],
+  controlOverrides: {
+    y_axis_format: {
+      label: t('Number format'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/BigNumberTotal.js 
b/superset/assets/src/explore/controlPanels/BigNumberTotal.js
new file mode 100644
index 0000000000..a0806c4e3f
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/BigNumberTotal.js
@@ -0,0 +1,27 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metric'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['subheader'],
+        ['y_axis_format'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    y_axis_format: {
+      label: t('Number format'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/BoxPlot.js 
b/superset/assets/src/explore/controlPanels/BoxPlot.js
new file mode 100644
index 0000000000..bf81f5e7a4
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/BoxPlot.js
@@ -0,0 +1,24 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metrics'],
+        ['adhoc_filters'],
+        ['groupby'],
+        ['limit'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['whisker_options'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/Bubble.js 
b/superset/assets/src/explore/controlPanels/Bubble.js
new file mode 100644
index 0000000000..051ee08d54
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Bubble.js
@@ -0,0 +1,54 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  label: t('Bubble Chart'),
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['series', 'entity'],
+        ['x'],
+        ['y'],
+        ['adhoc_filters'],
+        ['size'],
+        ['max_bubble_size'],
+        ['limit', null],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['show_legend', null],
+      ],
+    },
+    {
+      label: t('X Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['x_axis_label', 'left_margin'],
+        ['x_axis_format', 'x_ticks_layout'],
+        ['x_log_scale', 'x_axis_showminmax'],
+      ],
+    },
+    {
+      label: t('Y Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['y_axis_label', 'bottom_margin'],
+        ['y_axis_format', null],
+        ['y_log_scale', 'y_axis_showminmax'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    x_axis_format: {
+      default: '.3s',
+    },
+    color_scheme: {
+      renderTrigger: false,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Bullet.js 
b/superset/assets/src/explore/controlPanels/Bullet.js
new file mode 100644
index 0000000000..8c9fbdf200
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Bullet.js
@@ -0,0 +1,25 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  requiresTime: false,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metric'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['metric'],
+        ['ranges', 'range_labels'],
+        ['markers', 'marker_labels'],
+        ['marker_lines', 'marker_line_labels'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/CalHeatmap.js 
b/superset/assets/src/explore/controlPanels/CalHeatmap.js
new file mode 100644
index 0000000000..64f1b698bc
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/CalHeatmap.js
@@ -0,0 +1,39 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['domain_granularity', 'subdomain_granularity'],
+        ['metrics'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['linear_color_scheme'],
+        ['cell_size', 'cell_padding'],
+        ['cell_radius', 'steps'],
+        ['y_axis_format', 'x_axis_time_format'],
+        ['show_legend', 'show_values'],
+        ['show_metric_name', null],
+      ],
+    },
+  ],
+  controlOverrides: {
+    y_axis_format: {
+      label: t('Number Format'),
+    },
+    x_axis_time_format: {
+      label: t('Time Format'),
+    },
+    show_values: {
+      default: false,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Chord.js 
b/superset/assets/src/explore/controlPanels/Chord.js
new file mode 100644
index 0000000000..a0634ad134
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Chord.js
@@ -0,0 +1,44 @@
+import { t } from '@superset-ui/translation';
+import { nonEmpty } from '../validators';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['groupby'],
+        ['columns'],
+        ['metric'],
+        ['adhoc_filters'],
+        ['row_limit'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['y_axis_format', null],
+        ['color_scheme'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    y_axis_format: {
+      label: t('Number format'),
+      description: t('Choose a number format'),
+    },
+    groupby: {
+      label: t('Source'),
+      multi: false,
+      validators: [nonEmpty],
+      description: t('Choose a source'),
+    },
+    columns: {
+      label: t('Target'),
+      multi: false,
+      validators: [nonEmpty],
+      description: t('Choose a target'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Compare.js 
b/superset/assets/src/explore/controlPanels/Compare.js
new file mode 100644
index 0000000000..713a9e9651
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Compare.js
@@ -0,0 +1,43 @@
+import { t } from '@superset-ui/translation';
+import { NVD3TimeSeries, annotations } from './sections';
+import { D3_TIME_FORMAT_OPTIONS } from '../controls';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    NVD3TimeSeries[0],
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+      ],
+    },
+    {
+      label: t('X Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['x_axis_label', 'bottom_margin'],
+        ['x_ticks_layout', 'x_axis_format'],
+        ['x_axis_showminmax', null],
+      ],
+    },
+    {
+      label: t('Y Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['y_axis_label', 'left_margin'],
+        ['y_axis_showminmax', 'y_log_scale'],
+        ['y_axis_format', 'y_axis_bounds'],
+      ],
+    },
+    NVD3TimeSeries[1],
+    annotations,
+  ],
+  controlOverrides: {
+    x_axis_format: {
+      choices: D3_TIME_FORMAT_OPTIONS,
+      default: 'smart_date',
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/CountryMap.js 
b/superset/assets/src/explore/controlPanels/CountryMap.js
new file mode 100644
index 0000000000..8c26bfe66c
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/CountryMap.js
@@ -0,0 +1,36 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['entity'],
+        ['metric'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Options'),
+      expanded: true,
+      controlSetRows: [
+        ['select_country', 'number_format'],
+        ['linear_color_scheme'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    entity: {
+      label: t('ISO 3166-2 codes of region/province/department'),
+      description: t('It\'s ISO 3166-2 of your region/province/department in 
your table. (see documentation for list of ISO 3166-2)'),
+    },
+    metric: {
+      label: t('Metric'),
+      description: 'Metric to display bottom title',
+    },
+    linear_color_scheme: {
+      renderTrigger: false,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckArc.js 
b/superset/assets/src/explore/controlPanels/DeckArc.js
new file mode 100644
index 0000000000..63b8d59bf3
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckArc.js
@@ -0,0 +1,51 @@
+import { t } from '@superset-ui/translation';
+import timeGrainSqlaAnimationOverrides from 
'./timeGrainSqlaAnimationOverrides';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['start_spatial', 'end_spatial'],
+        ['row_limit', 'filter_nulls'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Map'),
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        ['autozoom', null],
+      ],
+    },
+    {
+      label: t('Arc'),
+      controlSetRows: [
+        ['color_picker', 'target_color_picker'],
+        ['dimension', 'color_scheme'],
+        ['stroke_width', 'legend_position'],
+      ],
+    },
+    {
+      label: t('Advanced'),
+      controlSetRows: [
+        ['js_columns'],
+        ['js_data_mutator'],
+        ['js_tooltip'],
+        ['js_onclick_href'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    dimension: {
+      label: t('Categorical Color'),
+      description: t('Pick a dimension from which categorical colors are 
defined'),
+    },
+    size: {
+      validators: [],
+    },
+    time_grain_sqla: timeGrainSqlaAnimationOverrides,
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckGeojson.js 
b/superset/assets/src/explore/controlPanels/DeckGeojson.js
new file mode 100644
index 0000000000..87ebd438f4
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckGeojson.js
@@ -0,0 +1,41 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['geojson', null],
+        ['row_limit', 'filter_nulls'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Map'),
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        // TODO ['autozoom', null],
+      ],
+    },
+    {
+      label: t('GeoJson Settings'),
+      controlSetRows: [
+        ['fill_color_picker', 'stroke_color_picker'],
+        ['filled', 'stroked'],
+        ['extruded', null],
+        ['point_radius_scale', null],
+      ],
+    },
+    {
+      label: t('Advanced'),
+      controlSetRows: [
+        ['js_columns'],
+        ['js_data_mutator'],
+        ['js_tooltip'],
+        ['js_onclick_href'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckGrid.js 
b/superset/assets/src/explore/controlPanels/DeckGrid.js
new file mode 100644
index 0000000000..a7deef0ddb
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckGrid.js
@@ -0,0 +1,41 @@
+import { t } from '@superset-ui/translation';
+import { nonEmpty } from '../validators';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['spatial', 'size'],
+        ['row_limit', 'filter_nulls'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Map'),
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        ['color_picker', 'autozoom'],
+        ['grid_size', 'extruded'],
+      ],
+    },
+    {
+      label: t('Advanced'),
+      controlSetRows: [
+        ['js_columns'],
+        ['js_data_mutator'],
+        ['js_tooltip'],
+        ['js_onclick_href'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    size: {
+      label: t('Height'),
+      description: t('Metric used to control height'),
+      validators: [nonEmpty],
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckHex.js 
b/superset/assets/src/explore/controlPanels/DeckHex.js
new file mode 100644
index 0000000000..7ddebb0ec8
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckHex.js
@@ -0,0 +1,40 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['spatial', 'size'],
+        ['row_limit', 'filter_nulls'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Map'),
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        ['color_picker', 'autozoom'],
+        ['grid_size', 'extruded'],
+        ['js_agg_function', null],
+      ],
+    },
+    {
+      label: t('Advanced'),
+      controlSetRows: [
+        ['js_columns'],
+        ['js_data_mutator'],
+        ['js_tooltip'],
+        ['js_onclick_href'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    size: {
+      label: t('Height'),
+      description: t('Metric used to control height'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckMulti.js 
b/superset/assets/src/explore/controlPanels/DeckMulti.js
new file mode 100644
index 0000000000..957e556b06
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckMulti.js
@@ -0,0 +1,22 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Map'),
+      expanded: true,
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        ['deck_slices', null],
+      ],
+    },
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['adhoc_filters'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckPath.js 
b/superset/assets/src/explore/controlPanels/DeckPath.js
new file mode 100644
index 0000000000..2e168445d6
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckPath.js
@@ -0,0 +1,42 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['line_column', 'line_type'],
+        ['row_limit', 'filter_nulls'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Map'),
+      expanded: true,
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        ['color_picker', 'line_width'],
+        ['reverse_long_lat', 'autozoom'],
+      ],
+    },
+    {
+      label: t('Advanced'),
+      controlSetRows: [
+        ['js_columns'],
+        ['js_data_mutator'],
+        ['js_tooltip'],
+        ['js_onclick_href'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    line_type: {
+      choices: [
+        ['polyline', 'Polyline'],
+        ['json', 'JSON'],
+      ],
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckPolygon.js 
b/superset/assets/src/explore/controlPanels/DeckPolygon.js
new file mode 100644
index 0000000000..71cc0c571a
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckPolygon.js
@@ -0,0 +1,65 @@
+import { t } from '@superset-ui/translation';
+import timeGrainSqlaAnimationOverrides from 
'./timeGrainSqlaAnimationOverrides';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['adhoc_filters'],
+        ['metric', 'point_radius_fixed'],
+        ['row_limit', null],
+        ['line_column', 'line_type'],
+        ['reverse_long_lat', 'filter_nulls'],
+      ],
+    },
+    {
+      label: t('Map'),
+      expanded: true,
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        ['autozoom', null],
+      ],
+    },
+    {
+      label: t('Polygon Settings'),
+      expanded: true,
+      controlSetRows: [
+        ['fill_color_picker', 'stroke_color_picker'],
+        ['filled', 'stroked'],
+        ['extruded', 'multiplier'],
+        ['line_width', null],
+        ['linear_color_scheme', 'opacity'],
+        ['num_buckets', 'break_points'],
+        ['table_filter', 'toggle_polygons'],
+        ['legend_position', null],
+      ],
+    },
+    {
+      label: t('Advanced'),
+      controlSetRows: [
+        ['js_columns'],
+        ['js_data_mutator'],
+        ['js_tooltip'],
+        ['js_onclick_href'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    metric: {
+      validators: [],
+    },
+    line_column: {
+      label: t('Polygon Column'),
+    },
+    line_type: {
+      label: t('Polygon Encoding'),
+    },
+    point_radius_fixed: {
+      label: t('Elevation'),
+    },
+    time_grain_sqla: timeGrainSqlaAnimationOverrides,
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckScatter.js 
b/superset/assets/src/explore/controlPanels/DeckScatter.js
new file mode 100644
index 0000000000..023abf964b
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckScatter.js
@@ -0,0 +1,70 @@
+import { t } from '@superset-ui/translation';
+import timeGrainSqlaAnimationOverrides from 
'./timeGrainSqlaAnimationOverrides';
+
+export default {
+  requiresTime: true,
+  onInit: controlState => ({
+    ...controlState,
+    time_grain_sqla: {
+      ...controlState.time_grain_sqla,
+      value: null,
+    },
+    granularity: {
+      ...controlState.granularity,
+      value: null,
+    },
+  }),
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['spatial', null],
+        ['row_limit', 'filter_nulls'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Map'),
+      expanded: true,
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        ['autozoom', null],
+      ],
+    },
+    {
+      label: t('Point Size'),
+      controlSetRows: [
+        ['point_radius_fixed', 'point_unit'],
+        ['min_radius', 'max_radius'],
+        ['multiplier', null],
+      ],
+    },
+    {
+      label: t('Point Color'),
+      controlSetRows: [
+        ['color_picker', 'legend_position'],
+        ['dimension', 'color_scheme'],
+      ],
+    },
+    {
+      label: t('Advanced'),
+      controlSetRows: [
+        ['js_columns'],
+        ['js_data_mutator'],
+        ['js_tooltip'],
+        ['js_onclick_href'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    dimension: {
+      label: t('Categorical Color'),
+      description: t('Pick a dimension from which categorical colors are 
defined'),
+    },
+    size: {
+      validators: [],
+    },
+    time_grain_sqla: timeGrainSqlaAnimationOverrides,
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DeckScreengrid.js 
b/superset/assets/src/explore/controlPanels/DeckScreengrid.js
new file mode 100644
index 0000000000..550876682f
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DeckScreengrid.js
@@ -0,0 +1,49 @@
+import { t } from '@superset-ui/translation';
+import { nonEmpty } from '../validators';
+import timeGrainSqlaAnimationOverrides from 
'./timeGrainSqlaAnimationOverrides';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['spatial', 'size'],
+        ['row_limit', 'filter_nulls'],
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Map'),
+      controlSetRows: [
+        ['mapbox_style', 'viewport'],
+        ['autozoom', null],
+      ],
+    },
+    {
+      label: t('Grid'),
+      expanded: true,
+      controlSetRows: [
+        ['grid_size', 'color_picker'],
+      ],
+    },
+    {
+      label: t('Advanced'),
+      controlSetRows: [
+        ['js_columns'],
+        ['js_data_mutator'],
+        ['js_tooltip'],
+        ['js_onclick_href'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    size: {
+      label: t('Weight'),
+      description: t("Metric used as a weight for the grid's coloring"),
+      validators: [nonEmpty],
+    },
+    time_grain_sqla: timeGrainSqlaAnimationOverrides,
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DirectedForce.js 
b/superset/assets/src/explore/controlPanels/DirectedForce.js
new file mode 100644
index 0000000000..0330b1219a
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DirectedForce.js
@@ -0,0 +1,29 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['groupby'],
+        ['metric'],
+        ['adhoc_filters'],
+        ['row_limit'],
+      ],
+    },
+    {
+      label: t('Options'),
+      controlSetRows: [
+        ['link_length'],
+        ['charge'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    groupby: {
+      label: t('Source / Target'),
+      description: t('Choose a source and a target'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DistBar.js 
b/superset/assets/src/explore/controlPanels/DistBar.js
new file mode 100644
index 0000000000..b58c9b9e7c
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DistBar.js
@@ -0,0 +1,46 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metrics'],
+        ['adhoc_filters'],
+        ['groupby'],
+        ['columns'],
+        ['row_limit'],
+        ['contribution'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['show_legend', 'show_bar_value'],
+        ['bar_stacked', 'order_bars'],
+        ['y_axis_format', 'y_axis_label'],
+        ['show_controls', null],
+      ],
+    },
+    {
+      label: t('X Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['x_axis_label', 'bottom_margin'],
+        ['x_ticks_layout', 'reduce_x_ticks'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    groupby: {
+      label: t('Series'),
+    },
+    columns: {
+      label: t('Breakdowns'),
+      description: t('Defines how each series is broken down'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/DualLine.js 
b/superset/assets/src/explore/controlPanels/DualLine.js
new file mode 100644
index 0000000000..fac2549493
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/DualLine.js
@@ -0,0 +1,52 @@
+import { t } from '@superset-ui/translation';
+import { annotations } from './sections';
+import { D3_TIME_FORMAT_OPTIONS } from '../controls';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['x_axis_format'],
+      ],
+    },
+    {
+      label: t('Y Axis 1'),
+      expanded: true,
+      controlSetRows: [
+        ['metric', 'y_axis_format'],
+      ],
+    },
+    {
+      label: t('Y Axis 2'),
+      expanded: true,
+      controlSetRows: [
+        ['metric_2', 'y_axis_2_format'],
+      ],
+    },
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['adhoc_filters'],
+      ],
+    },
+    annotations,
+  ],
+  controlOverrides: {
+    metric: {
+      label: t('Left Axis Metric'),
+      description: t('Choose a metric for left axis'),
+    },
+    y_axis_format: {
+      label: t('Left Axis Format'),
+    },
+    x_axis_format: {
+      choices: D3_TIME_FORMAT_OPTIONS,
+      default: 'smart_date',
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/EventFlow.js 
b/superset/assets/src/explore/controlPanels/EventFlow.js
new file mode 100644
index 0000000000..5cfa4c2516
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/EventFlow.js
@@ -0,0 +1,53 @@
+import { t } from '@superset-ui/translation';
+import { nonEmpty } from '../validators';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Event definition'),
+      controlSetRows: [
+        ['entity'],
+        ['all_columns_x'],
+        ['row_limit'],
+        ['order_by_entity'],
+        ['min_leaf_node_event_count'],
+      ],
+    },
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Additional metadata'),
+      controlSetRows: [
+        ['all_columns'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    entity: {
+      label: t('Column containing entity ids'),
+      description: t('e.g., a "user id" column'),
+    },
+    all_columns_x: {
+      label: t('Column containing event names'),
+      validators: [nonEmpty],
+      default: control => (
+        control.choices && control.choices.length > 0 ?
+          control.choices[0][0] : null
+      ),
+    },
+    row_limit: {
+      label: t('Event count limit'),
+      description: t('The maximum number of events to return, equivalent to 
the number of rows'),
+    },
+    all_columns: {
+      label: t('Meta data'),
+      description: t('Select any columns for metadata inspection'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/FilterBox.js 
b/superset/assets/src/explore/controlPanels/FilterBox.js
new file mode 100644
index 0000000000..529fbe2ad1
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/FilterBox.js
@@ -0,0 +1,29 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['groupby'],
+        ['metric'],
+        ['adhoc_filters'],
+        ['date_filter', 'instant_filtering'],
+        ['show_sqla_time_granularity', 'show_sqla_time_column'],
+        ['show_druid_time_granularity', 'show_druid_time_origin'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    groupby: {
+      label: t('Filter controls'),
+      description: t(
+        'The controls you want to filter on. Note that only columns ' +
+        'checked as "filterable" will show up on this list.'),
+      mapStateToProps: state => ({
+        options: (state.datasource) ? state.datasource.columns.filter(c => 
c.filterable) : [],
+      }),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Heatmap.js 
b/superset/assets/src/explore/controlPanels/Heatmap.js
new file mode 100644
index 0000000000..2709733172
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Heatmap.js
@@ -0,0 +1,50 @@
+import { t } from '@superset-ui/translation';
+import { nonEmpty } from '../validators';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['all_columns_x', 'all_columns_y'],
+        ['metric'],
+        ['adhoc_filters'],
+        ['row_limit'],
+      ],
+    },
+    {
+      label: t('Heatmap Options'),
+      expanded: true,
+      controlSetRows: [
+        ['linear_color_scheme'],
+        ['xscale_interval', 'yscale_interval'],
+        ['canvas_image_rendering', 'normalize_across'],
+        ['left_margin', 'bottom_margin'],
+        ['y_axis_bounds', 'y_axis_format'],
+        ['show_legend', 'show_perc'],
+        ['show_values', 'normalized'],
+        ['sort_x_axis', 'sort_y_axis'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    all_columns_x: {
+      validators: [nonEmpty],
+    },
+    all_columns_y: {
+      validators: [nonEmpty],
+    },
+    normalized: t('Whether to apply a normal distribution based on rank on the 
color scale'),
+    y_axis_bounds: {
+      label: t('Value bounds'),
+      renderTrigger: true,
+      description: t(
+        'Hard value bounds applied for color coding. Is only relevant ' +
+        'and applied when the normalization is applied against the whole 
heatmap.'),
+    },
+    y_axis_format: {
+      label: t('Value Format'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Histogram.js 
b/superset/assets/src/explore/controlPanels/Histogram.js
new file mode 100644
index 0000000000..52896149ef
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Histogram.js
@@ -0,0 +1,43 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['all_columns_x'],
+        ['adhoc_filters'],
+        ['row_limit'],
+        ['groupby'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['link_length'],
+        ['x_axis_label', 'y_axis_label'],
+        ['global_opacity'],
+        ['normalized'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    all_columns_x: {
+      label: t('Numeric Columns'),
+      description: t('Select the numeric columns to draw the histogram'),
+      multi: true,
+    },
+    link_length: {
+      label: t('No of Bins'),
+      description: t('Select the number of bins for the histogram'),
+      default: 5,
+    },
+    global_opacity: {
+      description: t('Opacity of the bars. Between 0 and 1'),
+      renderTrigger: true,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Horizon.js 
b/superset/assets/src/explore/controlPanels/Horizon.js
new file mode 100644
index 0000000000..13caee0665
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Horizon.js
@@ -0,0 +1,15 @@
+import { t } from '@superset-ui/translation';
+import { NVD3TimeSeries } from './sections';
+
+export default {
+  controlPanelSections: [
+    NVD3TimeSeries[0],
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['series_height', 'horizon_color_scale'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/Iframe.js 
b/superset/assets/src/explore/controlPanels/Iframe.js
new file mode 100644
index 0000000000..f1ebe992d8
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Iframe.js
@@ -0,0 +1,12 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Options'),
+      controlSetRows: [
+        ['url'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/Line.js 
b/superset/assets/src/explore/controlPanels/Line.js
new file mode 100644
index 0000000000..cbb2341a72
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Line.js
@@ -0,0 +1,49 @@
+import { t } from '@superset-ui/translation';
+import { NVD3TimeSeries, annotations } from './sections';
+import { D3_TIME_FORMAT_OPTIONS } from '../controls';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    NVD3TimeSeries[0],
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['show_brush', 'send_time_range', 'show_legend'],
+        ['rich_tooltip', 'show_markers'],
+        ['line_interpolation'],
+      ],
+    },
+    {
+      label: t('X Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['x_axis_label', 'bottom_margin'],
+        ['x_ticks_layout', 'x_axis_format'],
+        ['x_axis_showminmax', null],
+      ],
+    },
+    {
+      label: t('Y Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['y_axis_label', 'left_margin'],
+        ['y_axis_showminmax', 'y_log_scale'],
+        ['y_axis_format', 'y_axis_bounds'],
+      ],
+    },
+    NVD3TimeSeries[1],
+    annotations,
+  ],
+  controlOverrides: {
+    x_axis_format: {
+      choices: D3_TIME_FORMAT_OPTIONS,
+      default: 'smart_date',
+    },
+    row_limit: {
+      default: 50000,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/LineMulti.js 
b/superset/assets/src/explore/controlPanels/LineMulti.js
new file mode 100644
index 0000000000..a1ee5dd778
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/LineMulti.js
@@ -0,0 +1,75 @@
+import { t } from '@superset-ui/translation';
+import { annotations } from './sections';
+import { D3_TIME_FORMAT_OPTIONS } from '../controls';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['prefix_metric_with_slice_name', null],
+        ['show_legend', 'show_markers'],
+        ['line_interpolation', null],
+      ],
+    },
+    {
+      label: t('X Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['x_axis_label', 'bottom_margin'],
+        ['x_ticks_layout', 'x_axis_format'],
+        ['x_axis_showminmax', null],
+      ],
+    },
+    {
+      label: t('Y Axis 1'),
+      expanded: true,
+      controlSetRows: [
+        ['line_charts', 'y_axis_format'],
+      ],
+    },
+    {
+      label: t('Y Axis 2'),
+      expanded: false,
+      controlSetRows: [
+        ['line_charts_2', 'y_axis_2_format'],
+      ],
+    },
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['adhoc_filters'],
+      ],
+    },
+    annotations,
+  ],
+  controlOverrides: {
+    line_charts: {
+      label: t('Left Axis chart(s)'),
+      description: t('Choose one or more charts for left axis'),
+    },
+    y_axis_format: {
+      label: t('Left Axis Format'),
+    },
+    x_axis_format: {
+      choices: D3_TIME_FORMAT_OPTIONS,
+      default: 'smart_date',
+    },
+  },
+  sectionOverrides: {
+    sqlaTimeSeries: {
+      controlSetRows: [
+        ['time_range'],
+      ],
+    },
+    druidTimeSeries: {
+      controlSetRows: [
+        ['time_range'],
+      ],
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Mapbox.js 
b/superset/assets/src/explore/controlPanels/Mapbox.js
new file mode 100644
index 0000000000..a01b2b013e
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Mapbox.js
@@ -0,0 +1,72 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['all_columns_x', 'all_columns_y'],
+        ['clustering_radius'],
+        ['row_limit'],
+        ['adhoc_filters'],
+        ['groupby'],
+      ],
+    },
+    {
+      label: t('Points'),
+      controlSetRows: [
+        ['point_radius'],
+        ['point_radius_unit'],
+      ],
+    },
+    {
+      label: t('Labelling'),
+      controlSetRows: [
+        ['mapbox_label'],
+        ['pandas_aggfunc'],
+      ],
+    },
+    {
+      label: t('Visual Tweaks'),
+      controlSetRows: [
+        ['render_while_dragging'],
+        ['mapbox_style'],
+        ['global_opacity'],
+        ['mapbox_color'],
+      ],
+    },
+    {
+      label: t('Viewport'),
+      expanded: true,
+      controlSetRows: [
+        ['viewport_longitude', 'viewport_latitude'],
+        ['viewport_zoom', null],
+      ],
+    },
+  ],
+  controlOverrides: {
+    all_columns_x: {
+      label: t('Longitude'),
+      description: t('Column containing longitude data'),
+    },
+    all_columns_y: {
+      label: t('Latitude'),
+      description: t('Column containing latitude data'),
+    },
+    pandas_aggfunc: {
+      label: t('Cluster label aggregator'),
+      description: t('Aggregate function applied to the list of points ' +
+        'in each cluster to produce the cluster label.'),
+    },
+    rich_tooltip: {
+      label: t('Tooltip'),
+      description: t('Show a tooltip when hovering over points and clusters ' +
+        'describing the label'),
+    },
+    groupby: {
+      description: t('One or many controls to group by. If grouping, latitude 
' +
+        'and longitude columns must be present.'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Markup.js 
b/superset/assets/src/explore/controlPanels/Markup.js
new file mode 100644
index 0000000000..eba5ee2f18
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Markup.js
@@ -0,0 +1,14 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Code'),
+      expanded: true,
+      controlSetRows: [
+        ['markup_type'],
+        ['code'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/PairedTtest.js 
b/superset/assets/src/explore/controlPanels/PairedTtest.js
new file mode 100644
index 0000000000..0165f1fa54
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/PairedTtest.js
@@ -0,0 +1,18 @@
+import { t } from '@superset-ui/translation';
+import { NVD3TimeSeries } from './sections';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    NVD3TimeSeries[0],
+    {
+      label: t('Paired t-test'),
+      expanded: false,
+      controlSetRows: [
+        ['significance_level'],
+        ['pvalue_precision'],
+        ['liftvalue_precision'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/Para.js 
b/superset/assets/src/explore/controlPanels/Para.js
new file mode 100644
index 0000000000..4bf8ece35c
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Para.js
@@ -0,0 +1,25 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['series'],
+        ['metrics'],
+        ['secondary_metric'],
+        ['adhoc_filters'],
+        ['limit', 'row_limit'],
+      ],
+    },
+    {
+      label: t('Options'),
+      expanded: true,
+      controlSetRows: [
+        ['show_datatable', 'include_series'],
+        ['linear_color_scheme'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/Partition.js 
b/superset/assets/src/explore/controlPanels/Partition.js
new file mode 100644
index 0000000000..0decfe066d
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Partition.js
@@ -0,0 +1,27 @@
+import { t } from '@superset-ui/translation';
+import { NVD3TimeSeries } from './sections';
+
+export default {
+  controlPanelSections: [
+    NVD3TimeSeries[0],
+    {
+      label: t('Time Series Options'),
+      expanded: true,
+      controlSetRows: [
+        ['time_series_option'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['number_format', 'date_time_format'],
+        ['partition_limit', 'partition_threshold'],
+        ['log_scale', 'equal_date_size'],
+        ['rich_tooltip'],
+      ],
+    },
+    NVD3TimeSeries[1],
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/Pie.js 
b/superset/assets/src/explore/controlPanels/Pie.js
new file mode 100644
index 0000000000..b5eab4dcd9
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Pie.js
@@ -0,0 +1,31 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metric'],
+        ['adhoc_filters'],
+        ['groupby'],
+        ['row_limit'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['pie_label_type'],
+        ['donut', 'show_legend'],
+        ['show_labels', 'labels_outside'],
+        ['color_scheme'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    row_limit: {
+      default: 25,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/PivotTable.js 
b/superset/assets/src/explore/controlPanels/PivotTable.js
new file mode 100644
index 0000000000..f4f5724589
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/PivotTable.js
@@ -0,0 +1,28 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metrics'],
+        ['adhoc_filters'],
+        ['groupby'],
+        ['columns'],
+        ['row_limit', null],
+      ],
+    },
+    {
+      label: t('Pivot Options'),
+      controlSetRows: [
+        ['pandas_aggfunc', 'pivot_margins'],
+        ['number_format', 'combine_metric'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    groupby: { includeTime: true },
+    columns: { includeTime: true },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Rose.js 
b/superset/assets/src/explore/controlPanels/Rose.js
new file mode 100644
index 0000000000..a7d017c471
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Rose.js
@@ -0,0 +1,19 @@
+import { t } from '@superset-ui/translation';
+import { NVD3TimeSeries } from './sections';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    NVD3TimeSeries[0],
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['number_format', 'date_time_format'],
+        ['rich_tooltip', 'rose_area_proportion'],
+      ],
+    },
+    NVD3TimeSeries[1],
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/Sankey.js 
b/superset/assets/src/explore/controlPanels/Sankey.js
new file mode 100644
index 0000000000..6b97237f82
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Sankey.js
@@ -0,0 +1,29 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['groupby'],
+        ['metric'],
+        ['adhoc_filters'],
+        ['row_limit'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    groupby: {
+      label: t('Source / Target'),
+      description: t('Choose a source and a target'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Separator.js 
b/superset/assets/src/explore/controlPanels/Separator.js
new file mode 100644
index 0000000000..1571ddd5b6
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Separator.js
@@ -0,0 +1,22 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Code'),
+      controlSetRows: [
+        ['markup_type'],
+        ['code'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    code: {
+      default: '####Section Title\n' +
+      'A paragraph describing the section' +
+      'of the dashboard, right before the separator line ' +
+      '\n\n' +
+      '---------------',
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Sunburst.js 
b/superset/assets/src/explore/controlPanels/Sunburst.js
new file mode 100644
index 0000000000..e1831c67f3
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Sunburst.js
@@ -0,0 +1,41 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['groupby'],
+        ['metric'],
+        ['secondary_metric'],
+        ['adhoc_filters'],
+        ['row_limit'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    metric: {
+      label: t('Primary Metric'),
+      description: t('The primary metric is used to define the arc segment 
sizes'),
+    },
+    secondary_metric: {
+      label: t('Secondary Metric'),
+      default: null,
+      description: t('[optional] this secondary metric is used to ' +
+      'define the color as a ratio against the primary metric. ' +
+      'When omitted, the color is categorical and based on labels'),
+    },
+    groupby: {
+      label: t('Hierarchy'),
+      description: t('This defines the level of the hierarchy'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Table.js 
b/superset/assets/src/explore/controlPanels/Table.js
new file mode 100644
index 0000000000..aa6454044b
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Table.js
@@ -0,0 +1,50 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('GROUP BY'),
+      description: t('Use this section if you want a query that aggregates'),
+      expanded: true,
+      controlSetRows: [
+        ['groupby'],
+        ['metrics'],
+        ['percent_metrics'],
+        ['timeseries_limit_metric', 'row_limit'],
+        ['include_time', 'order_desc'],
+      ],
+    },
+    {
+      label: t('NOT GROUPED BY'),
+      description: t('Use this section if you want to query atomic rows'),
+      expanded: true,
+      controlSetRows: [
+        ['all_columns'],
+        ['order_by_cols'],
+        ['row_limit', null],
+      ],
+    },
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['adhoc_filters'],
+      ],
+    },
+    {
+      label: t('Options'),
+      expanded: true,
+      controlSetRows: [
+        ['table_timestamp_format'],
+        ['page_length', null],
+        ['include_search', 'table_filter'],
+        ['align_pn', 'color_pn'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    metrics: {
+      validators: [],
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/TimePivot.js 
b/superset/assets/src/explore/controlPanels/TimePivot.js
new file mode 100644
index 0000000000..c348c136c2
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/TimePivot.js
@@ -0,0 +1,51 @@
+import { t } from '@superset-ui/translation';
+import { D3_TIME_FORMAT_OPTIONS } from '../controls';
+
+export default {
+  requiresTime: true,
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metric'],
+        ['adhoc_filters'],
+        ['freq'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['show_legend', 'line_interpolation'],
+        ['color_picker', null],
+      ],
+    },
+    {
+      label: t('X Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['x_axis_label', 'bottom_margin'],
+        ['x_axis_showminmax', 'x_axis_format'],
+      ],
+    },
+    {
+      label: t('Y Axis'),
+      expanded: true,
+      controlSetRows: [
+        ['y_axis_label', 'left_margin'],
+        ['y_axis_showminmax', 'y_log_scale'],
+        ['y_axis_format', 'y_axis_bounds'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    x_axis_format: {
+      choices: D3_TIME_FORMAT_OPTIONS,
+      default: 'smart_date',
+    },
+    metric: {
+      clearable: false,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/TimeTable.js 
b/superset/assets/src/explore/controlPanels/TimeTable.js
new file mode 100644
index 0000000000..73d1e48197
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/TimeTable.js
@@ -0,0 +1,28 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metrics'],
+        ['adhoc_filters'],
+        ['groupby'],
+        ['limit'],
+        ['column_collection'],
+        ['url'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    groupby: {
+      multiple: false,
+    },
+    url: {
+      description: t(
+        "Templated link, it's possible to include {{ metric }} " +
+        'or other values coming from the controls.'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/Treemap.js 
b/superset/assets/src/explore/controlPanels/Treemap.js
new file mode 100644
index 0000000000..924b0de2d3
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/Treemap.js
@@ -0,0 +1,30 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['metrics'],
+        ['adhoc_filters'],
+        ['groupby'],
+        ['row_limit'],
+      ],
+    },
+    {
+      label: t('Chart Options'),
+      expanded: true,
+      controlSetRows: [
+        ['color_scheme'],
+        ['treemap_ratio'],
+        ['number_format'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    color_scheme: {
+      renderTrigger: false,
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/WordCloud.js 
b/superset/assets/src/explore/controlPanels/WordCloud.js
new file mode 100644
index 0000000000..daaec57977
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/WordCloud.js
@@ -0,0 +1,24 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['series'],
+        ['metric'],
+        ['adhoc_filters'],
+        ['row_limit', null],
+      ],
+    },
+    {
+      label: t('Options'),
+      controlSetRows: [
+        ['size_from', 'size_to'],
+        ['rotation'],
+        ['color_scheme'],
+      ],
+    },
+  ],
+};
diff --git a/superset/assets/src/explore/controlPanels/WorldMap.js 
b/superset/assets/src/explore/controlPanels/WorldMap.js
new file mode 100644
index 0000000000..f7f2ac03f8
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/WorldMap.js
@@ -0,0 +1,39 @@
+import { t } from '@superset-ui/translation';
+
+export default {
+  controlPanelSections: [
+    {
+      label: t('Query'),
+      expanded: true,
+      controlSetRows: [
+        ['entity'],
+        ['country_fieldtype'],
+        ['metric'],
+        ['adhoc_filters'],
+        ['row_limit'],
+      ],
+    },
+    {
+      label: t('Bubbles'),
+      controlSetRows: [
+        ['show_bubbles'],
+        ['secondary_metric'],
+        ['max_bubble_size'],
+      ],
+    },
+  ],
+  controlOverrides: {
+    entity: {
+      label: t('Country Control'),
+      description: t('3 letter code of the country'),
+    },
+    metric: {
+      label: t('Metric for color'),
+      description: t('Metric that defines the color of the country'),
+    },
+    secondary_metric: {
+      label: t('Bubble size'),
+      description: t('Metric that defines the size of the bubble'),
+    },
+  },
+};
diff --git a/superset/assets/src/explore/controlPanels/index.js 
b/superset/assets/src/explore/controlPanels/index.js
new file mode 100644
index 0000000000..ab3be2cf0f
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/index.js
@@ -0,0 +1,134 @@
+/**
+ * This file defines how controls (defined in controls.js) are structured into 
sections
+ * and associated with each and every visualization type.
+ */
+import { isFeatureEnabled, FeatureFlag } from 'src/featureFlags';
+import * as sections from './sections';
+
+import Area from './Area';
+import Bar from './Bar';
+import BigNumber from './BigNumber';
+import BigNumberTotal from './BigNumberTotal';
+import BoxPlot from './BoxPlot';
+import Bubble from './Bubble';
+import Bullet from './Bullet';
+import CalHeatmap from './CalHeatmap';
+import Chord from './Chord';
+import Compare from './Compare';
+import CountryMap from './CountryMap';
+import DirectedForce from './DirectedForce';
+import DistBar from './DistBar';
+import DualLine from './DualLine';
+import EventFlow from './EventFlow';
+import FilterBox from './FilterBox';
+import Heatmap from './Heatmap';
+import Histogram from './Histogram';
+import Horizon from './Horizon';
+import Iframe from './Iframe';
+import Line from './Line';
+import LineMulti from './LineMulti';
+import Mapbox from './Mapbox';
+import Markup from './Markup';
+import PairedTtest from './PairedTtest';
+import Para from './Para';
+import Partition from './Partition';
+import Pie from './Pie';
+import PivotTable from './PivotTable';
+import Rose from './Rose';
+import Sankey from './Sankey';
+import Sunburst from './Sunburst';
+import Separator from './Separator';
+import Table from './Table';
+import TimePivot from './TimePivot';
+import TimeTable from './TimeTable';
+import Treemap from './Treemap';
+import WordCloud from './WordCloud';
+import WorldMap from './WorldMap';
+import DeckArc from './DeckArc';
+import DeckGeojson from './DeckGeojson';
+import DeckGrid from './DeckGrid';
+import DeckHex from './DeckHex';
+import DeckMulti from './DeckMulti';
+import DeckPath from './DeckPath';
+import DeckPolygon from './DeckPolygon';
+import DeckScatter from './DeckScatter';
+import DeckScreengrid from './DeckScreengrid';
+
+export const controlPanelConfigs = {
+  area: Area,
+  bar: Bar,
+  big_number: BigNumber,
+  big_number_total: BigNumberTotal,
+  box_plot: BoxPlot,
+  bubble: Bubble,
+  bullet: Bullet,
+  cal_heatmap: CalHeatmap,
+  chord: Chord,
+  compare: Compare,
+  country_map: CountryMap,
+  directed_force: DirectedForce,
+  dist_bar: DistBar,
+  dual_line: DualLine,
+  event_flow: EventFlow,
+  filter_box: FilterBox,
+  heatmap: Heatmap,
+  histogram: Histogram,
+  horizon: Horizon,
+  iframe: Iframe,
+  line: Line,
+  line_multi: LineMulti,
+  mapbox: Mapbox,
+  markup: Markup,
+  paired_ttest: PairedTtest,
+  para: Para,
+  partition: Partition,
+  pie: Pie,
+  pivot_table: PivotTable,
+  rose: Rose,
+  sankey: Sankey,
+  separator: Separator,
+  sunburst: Sunburst,
+  table: Table,
+  time_pivot: TimePivot,
+  time_table: TimeTable,
+  treemap: Treemap,
+  word_cloud: WordCloud,
+  world_map: WorldMap,
+  deck_arc: DeckArc,
+  deck_geojson: DeckGeojson,
+  deck_grid: DeckGrid,
+  deck_hex: DeckHex,
+  deck_multi: DeckMulti,
+  deck_path: DeckPath,
+  deck_polygon: DeckPolygon,
+  deck_scatter: DeckScatter,
+  deck_screengrid: DeckScreengrid,
+
+};
+
+export default controlPanelConfigs;
+
+export function sectionsToRender(vizType, datasourceType) {
+  const config = controlPanelConfigs[vizType];
+
+  const sectionsCopy = { ...sections };
+  if (config.sectionOverrides) {
+    Object.entries(config.sectionOverrides).forEach(([section, overrides]) => {
+      if (typeof overrides === 'object' && overrides.constructor === Object) {
+        sectionsCopy[section] = {
+          ...sectionsCopy[section],
+          ...overrides,
+        };
+      } else {
+        sectionsCopy[section] = overrides;
+      }
+    });
+  }
+
+  return [].concat(
+    sectionsCopy.datasourceAndVizType,
+    datasourceType === 'table' ? sectionsCopy.sqlaTimeSeries : 
sectionsCopy.druidTimeSeries,
+    isFeatureEnabled(FeatureFlag.SCOPED_FILTER) ? sectionsCopy.filters : 
undefined,
+    config.controlPanelSections,
+  ).filter(section => section);
+}
diff --git a/superset/assets/src/explore/controlPanels/sections.jsx 
b/superset/assets/src/explore/controlPanels/sections.jsx
new file mode 100644
index 0000000000..d0983063ad
--- /dev/null
+++ b/superset/assets/src/explore/controlPanels/sections.jsx
@@ -0,0 +1,85 @@
+import React from 'react';
+import { t } from '@superset-ui/translation';
+
+export const druidTimeSeries = {
+  label: t('Time'),
+  expanded: true,
+  description: t('Time related form attributes'),
+  controlSetRows: [
+    ['granularity', 'druid_time_origin'],
+    ['time_range'],
+  ],
+};
+
+export const datasourceAndVizType = {
+  label: t('Datasource & Chart Type'),
+  expanded: true,
+  controlSetRows: [
+    ['datasource'],
+    ['viz_type'],
+    ['slice_id', 'cache_timeout', 'url_params'],
+  ],
+};
+
+export const colorScheme = {
+  label: t('Color Scheme'),
+  controlSetRows: [
+    ['color_scheme'],
+  ],
+};
+
+export const sqlaTimeSeries = {
+  label: t('Time'),
+  description: t('Time related form attributes'),
+  expanded: true,
+  controlSetRows: [
+    ['granularity_sqla', 'time_grain_sqla'],
+    ['time_range'],
+  ],
+};
+
+export const filters = {
+  label: t('Filters'),
+  expanded: true,
+  controlSetRows: [
+    ['filters'],
+  ],
+};
+
+export const annotations = {
+  label: t('Annotations and Layers'),
+  expanded: true,
+  controlSetRows: [
+    ['annotation_layers'],
+  ],
+};
+
+export const NVD3TimeSeries = [
+  {
+    label: t('Query'),
+    expanded: true,
+    controlSetRows: [
+      ['metrics'],
+      ['adhoc_filters'],
+      ['groupby'],
+      ['limit', 'timeseries_limit_metric'],
+      ['order_desc', 'contribution'],
+      ['row_limit', null],
+    ],
+  },
+  {
+    label: t('Advanced Analytics'),
+    description: t('This section contains options ' +
+    'that allow for advanced analytical post processing ' +
+    'of query results'),
+    controlSetRows: [
+      [<h1 className="section-header">{t('Moving Average')}</h1>],
+      ['rolling_type', 'rolling_periods', 'min_periods'],
+      [<h1 className="section-header">{t('Time Comparison')}</h1>],
+      ['time_compare', 'comparison_type'],
+      [<h1 className="section-header">{t('Python Functions')}</h1>],
+      [<h2 className="section-header">pandas.resample</h2>],
+      ['resample_how', 'resample_rule', 'resample_fillmethod'],
+    ],
+  },
+];
diff --git 
a/superset/assets/src/explore/controlPanels/timeGrainSqlaAnimationOverrides.js 
b/superset/assets/src/explore/controlPanels/timeGrainSqlaAnimationOverrides.js
new file mode 100644
index 0000000000..2c1ba84263
--- /dev/null
+++ 
b/superset/assets/src/explore/controlPanels/timeGrainSqlaAnimationOverrides.js
@@ -0,0 +1,8 @@
+export default {
+  default: null,
+  mapStateToProps: state => ({
+    choices: (state.datasource) ?
+      state.datasource.time_grain_sqla.filter(o => o[0] !== null) :
+      null,
+  }),
+};
diff --git a/superset/assets/src/explore/controls.jsx 
b/superset/assets/src/explore/controls.jsx
index 92dfb1c24a..3049dffee5 100644
--- a/superset/assets/src/explore/controls.jsx
+++ b/superset/assets/src/explore/controls.jsx
@@ -35,7 +35,7 @@
  *
  * Note that the keys defined in controls in this file that are not listed 
above represent
  * props specific for the React component defined as `type`. Also note that 
this module work
- * in tandem with `visTypes.js` that defines how controls are composed into 
sections for
+ * in tandem with `controlPanels/index.js` that defines how controls are 
composed into sections for
  * each and every visualization type.
  */
 import React from 'react';
diff --git a/superset/assets/src/explore/store.js 
b/superset/assets/src/explore/store.js
index 111954a3d2..63d456684e 100644
--- a/superset/assets/src/explore/store.js
+++ b/superset/assets/src/explore/store.js
@@ -1,7 +1,7 @@
 /* eslint camelcase: 0 */
 import React from 'react';
 import controls from './controls';
-import visTypes, { sectionsToRender } from './visTypes';
+import controlPanelConfigs, { sectionsToRender } from './controlPanels';
 
 export function getFormDataFromControls(controlsState) {
   const formData = {};
@@ -47,7 +47,7 @@ export function getControlsState(state, form_data) {
 
   const controlNames = getControlNames(vizType, state.datasource.type);
 
-  const viz = visTypes[vizType];
+  const viz = controlPanelConfigs[vizType];
   const controlOverrides = viz.controlOverrides || {};
   const controlsState = {};
   controlNames.forEach((k) => {
@@ -102,7 +102,7 @@ export function getControlsState(state, form_data) {
 export function applyDefaultFormData(form_data) {
   const datasourceType = form_data.datasource.split('__')[1];
   const vizType = form_data.viz_type || 'table';
-  const viz = visTypes[vizType];
+  const viz = controlPanelConfigs[vizType];
   const controlNames = getControlNames(vizType, datasourceType);
   const controlOverrides = viz.controlOverrides || {};
   const formData = {};
diff --git a/superset/assets/src/explore/visTypes.jsx 
b/superset/assets/src/explore/visTypes.jsx
deleted file mode 100644
index 67c0a1d4c2..0000000000
--- a/superset/assets/src/explore/visTypes.jsx
+++ /dev/null
@@ -1,1888 +0,0 @@
-/**
- * This file defines how controls (defined in controls.js) are structured into 
sections
- * and associated with each and every visualization type.
- */
-import React from 'react';
-import { t } from '@superset-ui/translation';
-
-import { isFeatureEnabled, FeatureFlag } from 'src/featureFlags';
-import { D3_TIME_FORMAT_OPTIONS } from './controls';
-import { nonEmpty } from './validators';
-
-export const sections = {
-  druidTimeSeries: {
-    label: t('Time'),
-    expanded: true,
-    description: t('Time related form attributes'),
-    controlSetRows: [
-      ['granularity', 'druid_time_origin'],
-      ['time_range'],
-    ],
-  },
-  datasourceAndVizType: {
-    label: t('Datasource & Chart Type'),
-    expanded: true,
-    controlSetRows: [
-      ['datasource'],
-      ['viz_type'],
-      ['slice_id', 'cache_timeout', 'url_params'],
-    ],
-  },
-  colorScheme: {
-    label: t('Color Scheme'),
-    controlSetRows: [
-      ['color_scheme'],
-    ],
-  },
-  sqlaTimeSeries: {
-    label: t('Time'),
-    description: t('Time related form attributes'),
-    expanded: true,
-    controlSetRows: [
-      ['granularity_sqla', 'time_grain_sqla'],
-      ['time_range'],
-    ],
-  },
-  filters: {
-    label: t('Filters'),
-    expanded: true,
-    controlSetRows: [
-      ['filters'],
-    ],
-  },
-  annotations: {
-    label: t('Annotations and Layers'),
-    expanded: true,
-    controlSetRows: [
-      ['annotation_layers'],
-    ],
-  },
-  NVD3TimeSeries: [
-    {
-      label: t('Query'),
-      expanded: true,
-      controlSetRows: [
-        ['metrics'],
-        ['adhoc_filters'],
-        ['groupby'],
-        ['limit', 'timeseries_limit_metric'],
-        ['order_desc', 'contribution'],
-        ['row_limit', null],
-      ],
-    },
-    {
-      label: t('Advanced Analytics'),
-      description: t('This section contains options ' +
-      'that allow for advanced analytical post processing ' +
-      'of query results'),
-      controlSetRows: [
-        [<h1 className="section-header">{t('Moving Average')}</h1>],
-        ['rolling_type', 'rolling_periods', 'min_periods'],
-        [<h1 className="section-header">{t('Time Comparison')}</h1>],
-        ['time_compare', 'comparison_type'],
-        [<h1 className="section-header">{t('Python Functions')}</h1>],
-        [<h2 className="section-header">pandas.resample</h2>],
-        ['resample_how', 'resample_rule', 'resample_fillmethod'],
-      ],
-    },
-  ],
-};
-
-const timeGrainSqlaAnimationOverrides = {
-  default: null,
-  mapStateToProps: state => ({
-    choices: (state.datasource) ?
-      state.datasource.time_grain_sqla.filter(o => o[0] !== null) :
-      null,
-  }),
-};
-
-export const visTypes = {
-  dist_bar: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metrics'],
-          ['adhoc_filters'],
-          ['groupby'],
-          ['columns'],
-          ['row_limit'],
-          ['contribution'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['show_legend', 'show_bar_value'],
-          ['bar_stacked', 'order_bars'],
-          ['y_axis_format', 'y_axis_label'],
-          ['show_controls', null],
-        ],
-      },
-      {
-        label: t('X Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['x_axis_label', 'bottom_margin'],
-          ['x_ticks_layout', 'reduce_x_ticks'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      groupby: {
-        label: t('Series'),
-      },
-      columns: {
-        label: t('Breakdowns'),
-        description: t('Defines how each series is broken down'),
-      },
-    },
-  },
-
-  pie: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metric'],
-          ['adhoc_filters'],
-          ['groupby'],
-          ['row_limit'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['pie_label_type'],
-          ['donut', 'show_legend'],
-          ['show_labels', 'labels_outside'],
-          ['color_scheme'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      row_limit: {
-        default: 25,
-      },
-    },
-  },
-
-  line: {
-    requiresTime: true,
-    controlPanelSections: [
-      sections.NVD3TimeSeries[0],
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['show_brush', 'send_time_range', 'show_legend'],
-          ['rich_tooltip', 'show_markers'],
-          ['line_interpolation'],
-        ],
-      },
-      {
-        label: t('X Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['x_axis_label', 'bottom_margin'],
-          ['x_ticks_layout', 'x_axis_format'],
-          ['x_axis_showminmax', null],
-        ],
-      },
-      {
-        label: t('Y Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['y_axis_label', 'left_margin'],
-          ['y_axis_showminmax', 'y_log_scale'],
-          ['y_axis_format', 'y_axis_bounds'],
-        ],
-      },
-      sections.NVD3TimeSeries[1],
-      sections.annotations,
-    ],
-    controlOverrides: {
-      x_axis_format: {
-        choices: D3_TIME_FORMAT_OPTIONS,
-        default: 'smart_date',
-      },
-      row_limit: {
-        default: 50000,
-      },
-    },
-  },
-
-  line_multi: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['prefix_metric_with_slice_name', null],
-          ['show_legend', 'show_markers'],
-          ['line_interpolation', null],
-        ],
-      },
-      {
-        label: t('X Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['x_axis_label', 'bottom_margin'],
-          ['x_ticks_layout', 'x_axis_format'],
-          ['x_axis_showminmax', null],
-        ],
-      },
-      {
-        label: t('Y Axis 1'),
-        expanded: true,
-        controlSetRows: [
-          ['line_charts', 'y_axis_format'],
-        ],
-      },
-      {
-        label: t('Y Axis 2'),
-        expanded: false,
-        controlSetRows: [
-          ['line_charts_2', 'y_axis_2_format'],
-        ],
-      },
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['adhoc_filters'],
-        ],
-      },
-      sections.annotations,
-    ],
-    controlOverrides: {
-      line_charts: {
-        label: t('Left Axis chart(s)'),
-        description: t('Choose one or more charts for left axis'),
-      },
-      y_axis_format: {
-        label: t('Left Axis Format'),
-      },
-      x_axis_format: {
-        choices: D3_TIME_FORMAT_OPTIONS,
-        default: 'smart_date',
-      },
-    },
-    sectionOverrides: {
-      sqlaTimeSeries: {
-        controlSetRows: [
-          ['time_range'],
-        ],
-      },
-      druidTimeSeries: {
-        controlSetRows: [
-          ['time_range'],
-        ],
-      },
-    },
-  },
-
-  time_pivot: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metric'],
-          ['adhoc_filters'],
-          ['freq'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['show_legend', 'line_interpolation'],
-          ['color_picker', null],
-        ],
-      },
-      {
-        label: t('X Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['x_axis_label', 'bottom_margin'],
-          ['x_axis_showminmax', 'x_axis_format'],
-        ],
-      },
-      {
-        label: t('Y Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['y_axis_label', 'left_margin'],
-          ['y_axis_showminmax', 'y_log_scale'],
-          ['y_axis_format', 'y_axis_bounds'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      x_axis_format: {
-        choices: D3_TIME_FORMAT_OPTIONS,
-        default: 'smart_date',
-      },
-      metric: {
-        clearable: false,
-      },
-    },
-  },
-
-  dual_line: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['x_axis_format'],
-        ],
-      },
-      {
-        label: t('Y Axis 1'),
-        expanded: true,
-        controlSetRows: [
-          ['metric', 'y_axis_format'],
-        ],
-      },
-      {
-        label: t('Y Axis 2'),
-        expanded: true,
-        controlSetRows: [
-          ['metric_2', 'y_axis_2_format'],
-        ],
-      },
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['adhoc_filters'],
-        ],
-      },
-      sections.annotations,
-    ],
-    controlOverrides: {
-      metric: {
-        label: t('Left Axis Metric'),
-        description: t('Choose a metric for left axis'),
-      },
-      y_axis_format: {
-        label: t('Left Axis Format'),
-      },
-      x_axis_format: {
-        choices: D3_TIME_FORMAT_OPTIONS,
-        default: 'smart_date',
-      },
-    },
-  },
-
-  bar: {
-    requiresTime: true,
-    controlPanelSections: [
-      sections.NVD3TimeSeries[0],
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['show_brush', 'show_legend', 'show_bar_value'],
-          ['rich_tooltip', 'bar_stacked'],
-          ['line_interpolation', 'show_controls'],
-          ['bottom_margin'],
-        ],
-      },
-      {
-        label: t('X Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['x_axis_label', 'bottom_margin'],
-          ['x_ticks_layout', 'x_axis_format'],
-          ['x_axis_showminmax', 'reduce_x_ticks'],
-        ],
-      },
-      {
-        label: t('Y Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['y_axis_label', 'left_margin'],
-          ['y_axis_showminmax', 'y_log_scale'],
-          ['y_axis_format', 'y_axis_bounds'],
-        ],
-      },
-      sections.NVD3TimeSeries[1],
-      sections.annotations,
-    ],
-    controlOverrides: {
-      x_axis_format: {
-        choices: D3_TIME_FORMAT_OPTIONS,
-        default: 'smart_date',
-      },
-    },
-  },
-
-  compare: {
-    requiresTime: true,
-    controlPanelSections: [
-      sections.NVD3TimeSeries[0],
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-        ],
-      },
-      {
-        label: t('X Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['x_axis_label', 'bottom_margin'],
-          ['x_ticks_layout', 'x_axis_format'],
-          ['x_axis_showminmax', null],
-        ],
-      },
-      {
-        label: t('Y Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['y_axis_label', 'left_margin'],
-          ['y_axis_showminmax', 'y_log_scale'],
-          ['y_axis_format', 'y_axis_bounds'],
-        ],
-      },
-      sections.NVD3TimeSeries[1],
-      sections.annotations,
-    ],
-    controlOverrides: {
-      x_axis_format: {
-        choices: D3_TIME_FORMAT_OPTIONS,
-        default: 'smart_date',
-      },
-    },
-  },
-
-  deck_multi: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Map'),
-        expanded: true,
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          ['deck_slices', null],
-        ],
-      },
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['adhoc_filters'],
-        ],
-      },
-    ],
-  },
-
-  deck_hex: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['spatial', 'size'],
-          ['row_limit', 'filter_nulls'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Map'),
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          ['color_picker', 'autozoom'],
-          ['grid_size', 'extruded'],
-          ['js_agg_function', null],
-        ],
-      },
-      {
-        label: t('Advanced'),
-        controlSetRows: [
-          ['js_columns'],
-          ['js_data_mutator'],
-          ['js_tooltip'],
-          ['js_onclick_href'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      size: {
-        label: t('Height'),
-        description: t('Metric used to control height'),
-      },
-    },
-  },
-
-  deck_grid: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['spatial', 'size'],
-          ['row_limit', 'filter_nulls'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Map'),
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          ['color_picker', 'autozoom'],
-          ['grid_size', 'extruded'],
-        ],
-      },
-      {
-        label: t('Advanced'),
-        controlSetRows: [
-          ['js_columns'],
-          ['js_data_mutator'],
-          ['js_tooltip'],
-          ['js_onclick_href'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      size: {
-        label: t('Height'),
-        description: t('Metric used to control height'),
-        validators: [nonEmpty],
-      },
-    },
-  },
-
-  deck_path: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['line_column', 'line_type'],
-          ['row_limit', 'filter_nulls'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Map'),
-        expanded: true,
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          ['color_picker', 'line_width'],
-          ['reverse_long_lat', 'autozoom'],
-        ],
-      },
-      {
-        label: t('Advanced'),
-        controlSetRows: [
-          ['js_columns'],
-          ['js_data_mutator'],
-          ['js_tooltip'],
-          ['js_onclick_href'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      line_type: {
-        choices: [
-          ['polyline', 'Polyline'],
-          ['json', 'JSON'],
-        ],
-      },
-    },
-  },
-
-  deck_screengrid: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['spatial', 'size'],
-          ['row_limit', 'filter_nulls'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Map'),
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          ['autozoom', null],
-        ],
-      },
-      {
-        label: t('Grid'),
-        expanded: true,
-        controlSetRows: [
-          ['grid_size', 'color_picker'],
-        ],
-      },
-      {
-        label: t('Advanced'),
-        controlSetRows: [
-          ['js_columns'],
-          ['js_data_mutator'],
-          ['js_tooltip'],
-          ['js_onclick_href'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      size: {
-        label: t('Weight'),
-        description: t("Metric used as a weight for the grid's coloring"),
-        validators: [nonEmpty],
-      },
-      time_grain_sqla: timeGrainSqlaAnimationOverrides,
-    },
-  },
-
-  deck_geojson: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['geojson', null],
-          ['row_limit', 'filter_nulls'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Map'),
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          // TODO ['autozoom', null],
-        ],
-      },
-      {
-        label: t('GeoJson Settings'),
-        controlSetRows: [
-          ['fill_color_picker', 'stroke_color_picker'],
-          ['filled', 'stroked'],
-          ['extruded', null],
-          ['point_radius_scale', null],
-        ],
-      },
-      {
-        label: t('Advanced'),
-        controlSetRows: [
-          ['js_columns'],
-          ['js_data_mutator'],
-          ['js_tooltip'],
-          ['js_onclick_href'],
-        ],
-      },
-    ],
-  },
-
-  deck_polygon: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['adhoc_filters'],
-          ['metric', 'point_radius_fixed'],
-          ['row_limit', null],
-          ['line_column', 'line_type'],
-          ['reverse_long_lat', 'filter_nulls'],
-        ],
-      },
-      {
-        label: t('Map'),
-        expanded: true,
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          ['autozoom', null],
-        ],
-      },
-      {
-        label: t('Polygon Settings'),
-        expanded: true,
-        controlSetRows: [
-          ['fill_color_picker', 'stroke_color_picker'],
-          ['filled', 'stroked'],
-          ['extruded', 'multiplier'],
-          ['line_width', null],
-          ['linear_color_scheme', 'opacity'],
-          ['num_buckets', 'break_points'],
-          ['table_filter', 'toggle_polygons'],
-          ['legend_position', null],
-        ],
-      },
-      {
-        label: t('Advanced'),
-        controlSetRows: [
-          ['js_columns'],
-          ['js_data_mutator'],
-          ['js_tooltip'],
-          ['js_onclick_href'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      metric: {
-        validators: [],
-      },
-      line_column: {
-        label: t('Polygon Column'),
-      },
-      line_type: {
-        label: t('Polygon Encoding'),
-      },
-      point_radius_fixed: {
-        label: t('Elevation'),
-      },
-      time_grain_sqla: timeGrainSqlaAnimationOverrides,
-    },
-  },
-
-  deck_arc: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['start_spatial', 'end_spatial'],
-          ['row_limit', 'filter_nulls'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Map'),
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          ['autozoom', null],
-        ],
-      },
-      {
-        label: t('Arc'),
-        controlSetRows: [
-          ['color_picker', 'target_color_picker'],
-          ['dimension', 'color_scheme'],
-          ['stroke_width', 'legend_position'],
-        ],
-      },
-      {
-        label: t('Advanced'),
-        controlSetRows: [
-          ['js_columns'],
-          ['js_data_mutator'],
-          ['js_tooltip'],
-          ['js_onclick_href'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      dimension: {
-        label: t('Categorical Color'),
-        description: t('Pick a dimension from which categorical colors are 
defined'),
-      },
-      size: {
-        validators: [],
-      },
-      time_grain_sqla: timeGrainSqlaAnimationOverrides,
-    },
-  },
-
-  deck_scatter: {
-    requiresTime: true,
-    onInit: controlState => ({
-      ...controlState,
-      time_grain_sqla: {
-        ...controlState.time_grain_sqla,
-        value: null,
-      },
-      granularity: {
-        ...controlState.granularity,
-        value: null,
-      },
-    }),
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['spatial', null],
-          ['row_limit', 'filter_nulls'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Map'),
-        expanded: true,
-        controlSetRows: [
-          ['mapbox_style', 'viewport'],
-          ['autozoom', null],
-        ],
-      },
-      {
-        label: t('Point Size'),
-        controlSetRows: [
-          ['point_radius_fixed', 'point_unit'],
-          ['min_radius', 'max_radius'],
-          ['multiplier', null],
-        ],
-      },
-      {
-        label: t('Point Color'),
-        controlSetRows: [
-          ['color_picker', 'legend_position'],
-          ['dimension', 'color_scheme'],
-        ],
-      },
-      {
-        label: t('Advanced'),
-        controlSetRows: [
-          ['js_columns'],
-          ['js_data_mutator'],
-          ['js_tooltip'],
-          ['js_onclick_href'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      dimension: {
-        label: t('Categorical Color'),
-        description: t('Pick a dimension from which categorical colors are 
defined'),
-      },
-      size: {
-        validators: [],
-      },
-      time_grain_sqla: timeGrainSqlaAnimationOverrides,
-    },
-  },
-
-  area: {
-    requiresTime: true,
-    controlPanelSections: [
-      sections.NVD3TimeSeries[0],
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['show_brush', 'show_legend'],
-          ['line_interpolation', 'stacked_style'],
-          ['color_scheme'],
-          ['rich_tooltip', 'show_controls'],
-        ],
-      },
-      {
-        label: t('X Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['x_axis_label', 'bottom_margin'],
-          ['x_ticks_layout', 'x_axis_format'],
-          ['x_axis_showminmax', null],
-        ],
-      },
-      {
-        label: t('Y Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['y_axis_format', 'y_axis_bounds'],
-          ['y_log_scale', null],
-        ],
-      },
-      sections.NVD3TimeSeries[1],
-      sections.annotations,
-    ],
-    controlOverrides: {
-      x_axis_format: {
-        default: 'smart_date',
-        choices: D3_TIME_FORMAT_OPTIONS,
-      },
-      color_scheme: {
-        renderTrigger: false,
-      },
-    },
-  },
-
-  table: {
-    controlPanelSections: [
-      {
-        label: t('GROUP BY'),
-        description: t('Use this section if you want a query that aggregates'),
-        expanded: true,
-        controlSetRows: [
-          ['groupby'],
-          ['metrics'],
-          ['percent_metrics'],
-          ['timeseries_limit_metric', 'row_limit'],
-          ['include_time', 'order_desc'],
-        ],
-      },
-      {
-        label: t('NOT GROUPED BY'),
-        description: t('Use this section if you want to query atomic rows'),
-        expanded: true,
-        controlSetRows: [
-          ['all_columns'],
-          ['order_by_cols'],
-          ['row_limit', null],
-        ],
-      },
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Options'),
-        expanded: true,
-        controlSetRows: [
-          ['table_timestamp_format'],
-          ['page_length', null],
-          ['include_search', 'table_filter'],
-          ['align_pn', 'color_pn'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      metrics: {
-        validators: [],
-      },
-    },
-  },
-
-  time_table: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metrics'],
-          ['adhoc_filters'],
-          ['groupby'],
-          ['limit'],
-          ['column_collection'],
-          ['url'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      groupby: {
-        multiple: false,
-      },
-      url: {
-        description: t(
-          "Templated link, it's possible to include {{ metric }} " +
-          'or other values coming from the controls.'),
-      },
-    },
-  },
-
-  markup: {
-    controlPanelSections: [
-      {
-        label: t('Code'),
-        expanded: true,
-        controlSetRows: [
-          ['markup_type'],
-          ['code'],
-        ],
-      },
-    ],
-  },
-
-  pivot_table: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metrics'],
-          ['adhoc_filters'],
-          ['groupby'],
-          ['columns'],
-          ['row_limit', null],
-        ],
-      },
-      {
-        label: t('Pivot Options'),
-        controlSetRows: [
-          ['pandas_aggfunc', 'pivot_margins'],
-          ['number_format', 'combine_metric'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      groupby: { includeTime: true },
-      columns: { includeTime: true },
-    },
-  },
-
-  separator: {
-    controlPanelSections: [
-      {
-        label: t('Code'),
-        controlSetRows: [
-          ['markup_type'],
-          ['code'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      code: {
-        default: '####Section Title\n' +
-        'A paragraph describing the section' +
-        'of the dashboard, right before the separator line ' +
-        '\n\n' +
-        '---------------',
-      },
-    },
-  },
-
-  word_cloud: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['series'],
-          ['metric'],
-          ['adhoc_filters'],
-          ['row_limit', null],
-        ],
-      },
-      {
-        label: t('Options'),
-        controlSetRows: [
-          ['size_from', 'size_to'],
-          ['rotation'],
-          ['color_scheme'],
-        ],
-      },
-    ],
-  },
-
-  treemap: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metrics'],
-          ['adhoc_filters'],
-          ['groupby'],
-          ['row_limit'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['treemap_ratio'],
-          ['number_format'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      color_scheme: {
-        renderTrigger: false,
-      },
-    },
-  },
-
-  cal_heatmap: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['domain_granularity', 'subdomain_granularity'],
-          ['metrics'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['linear_color_scheme'],
-          ['cell_size', 'cell_padding'],
-          ['cell_radius', 'steps'],
-          ['y_axis_format', 'x_axis_time_format'],
-          ['show_legend', 'show_values'],
-          ['show_metric_name', null],
-        ],
-      },
-    ],
-    controlOverrides: {
-      y_axis_format: {
-        label: t('Number Format'),
-      },
-      x_axis_time_format: {
-        label: t('Time Format'),
-      },
-      show_values: {
-        default: false,
-      },
-    },
-  },
-
-  box_plot: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metrics'],
-          ['adhoc_filters'],
-          ['groupby'],
-          ['limit'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['whisker_options'],
-        ],
-      },
-    ],
-  },
-
-  bubble: {
-    label: t('Bubble Chart'),
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['series', 'entity'],
-          ['x'],
-          ['y'],
-          ['adhoc_filters'],
-          ['size'],
-          ['max_bubble_size'],
-          ['limit', null],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['show_legend', null],
-        ],
-      },
-      {
-        label: t('X Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['x_axis_label', 'left_margin'],
-          ['x_axis_format', 'x_ticks_layout'],
-          ['x_log_scale', 'x_axis_showminmax'],
-        ],
-      },
-      {
-        label: t('Y Axis'),
-        expanded: true,
-        controlSetRows: [
-          ['y_axis_label', 'bottom_margin'],
-          ['y_axis_format', null],
-          ['y_log_scale', 'y_axis_showminmax'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      x_axis_format: {
-        default: '.3s',
-      },
-      color_scheme: {
-        renderTrigger: false,
-      },
-    },
-  },
-
-  bullet: {
-    requiresTime: false,
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metric'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['metric'],
-          ['ranges', 'range_labels'],
-          ['markers', 'marker_labels'],
-          ['marker_lines', 'marker_line_labels'],
-        ],
-      },
-    ],
-  },
-
-  big_number: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metric'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['compare_lag', 'compare_suffix'],
-          ['y_axis_format', null],
-          ['show_trend_line', 'start_y_axis_at_zero'],
-          ['color_picker', null],
-        ],
-      },
-    ],
-    controlOverrides: {
-      y_axis_format: {
-        label: t('Number format'),
-      },
-    },
-  },
-
-  big_number_total: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['metric'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['subheader'],
-          ['y_axis_format'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      y_axis_format: {
-        label: t('Number format'),
-      },
-    },
-  },
-
-  histogram: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['all_columns_x'],
-          ['adhoc_filters'],
-          ['row_limit'],
-          ['groupby'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['link_length'],
-          ['x_axis_label', 'y_axis_label'],
-          ['global_opacity'],
-          ['normalized'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      all_columns_x: {
-        label: t('Numeric Columns'),
-        description: t('Select the numeric columns to draw the histogram'),
-        multi: true,
-      },
-      link_length: {
-        label: t('No of Bins'),
-        description: t('Select the number of bins for the histogram'),
-        default: 5,
-      },
-      global_opacity: {
-        description: t('Opacity of the bars. Between 0 and 1'),
-        renderTrigger: true,
-      },
-    },
-  },
-
-  sunburst: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['groupby'],
-          ['metric'],
-          ['secondary_metric'],
-          ['adhoc_filters'],
-          ['row_limit'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      metric: {
-        label: t('Primary Metric'),
-        description: t('The primary metric is used to define the arc segment 
sizes'),
-      },
-      secondary_metric: {
-        label: t('Secondary Metric'),
-        default: null,
-        description: t('[optional] this secondary metric is used to ' +
-        'define the color as a ratio against the primary metric. ' +
-        'When omitted, the color is categorical and based on labels'),
-      },
-      groupby: {
-        label: t('Hierarchy'),
-        description: t('This defines the level of the hierarchy'),
-      },
-    },
-  },
-
-  sankey: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['groupby'],
-          ['metric'],
-          ['adhoc_filters'],
-          ['row_limit'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      groupby: {
-        label: t('Source / Target'),
-        description: t('Choose a source and a target'),
-      },
-    },
-  },
-
-  directed_force: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['groupby'],
-          ['metric'],
-          ['adhoc_filters'],
-          ['row_limit'],
-        ],
-      },
-      {
-        label: t('Options'),
-        controlSetRows: [
-          ['link_length'],
-          ['charge'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      groupby: {
-        label: t('Source / Target'),
-        description: t('Choose a source and a target'),
-      },
-    },
-  },
-  chord: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['groupby'],
-          ['columns'],
-          ['metric'],
-          ['adhoc_filters'],
-          ['row_limit'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['y_axis_format', null],
-          ['color_scheme'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      y_axis_format: {
-        label: t('Number format'),
-        description: t('Choose a number format'),
-      },
-      groupby: {
-        label: t('Source'),
-        multi: false,
-        validators: [nonEmpty],
-        description: t('Choose a source'),
-      },
-      columns: {
-        label: t('Target'),
-        multi: false,
-        validators: [nonEmpty],
-        description: t('Choose a target'),
-      },
-    },
-  },
-  country_map: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['entity'],
-          ['metric'],
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Options'),
-        expanded: true,
-        controlSetRows: [
-          ['select_country', 'number_format'],
-          ['linear_color_scheme'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      entity: {
-        label: t('ISO 3166-2 codes of region/province/department'),
-        description: t('It\'s ISO 3166-2 of your region/province/department in 
your table. (see documentation for list of ISO 3166-2)'),
-      },
-      metric: {
-        label: t('Metric'),
-        description: 'Metric to display bottom title',
-      },
-      linear_color_scheme: {
-        renderTrigger: false,
-      },
-    },
-  },
-  world_map: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['entity'],
-          ['country_fieldtype'],
-          ['metric'],
-          ['adhoc_filters'],
-          ['row_limit'],
-        ],
-      },
-      {
-        label: t('Bubbles'),
-        controlSetRows: [
-          ['show_bubbles'],
-          ['secondary_metric'],
-          ['max_bubble_size'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      entity: {
-        label: t('Country Control'),
-        description: t('3 letter code of the country'),
-      },
-      metric: {
-        label: t('Metric for color'),
-        description: t('Metric that defines the color of the country'),
-      },
-      secondary_metric: {
-        label: t('Bubble size'),
-        description: t('Metric that defines the size of the bubble'),
-      },
-    },
-  },
-
-  filter_box: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['groupby'],
-          ['metric'],
-          ['adhoc_filters'],
-          ['date_filter', 'instant_filtering'],
-          ['show_sqla_time_granularity', 'show_sqla_time_column'],
-          ['show_druid_time_granularity', 'show_druid_time_origin'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      groupby: {
-        label: t('Filter controls'),
-        description: t(
-          'The controls you want to filter on. Note that only columns ' +
-          'checked as "filterable" will show up on this list.'),
-        mapStateToProps: state => ({
-          options: (state.datasource) ? state.datasource.columns.filter(c => 
c.filterable) : [],
-        }),
-      },
-    },
-  },
-
-  iframe: {
-    controlPanelSections: [
-      {
-        label: t('Options'),
-        controlSetRows: [
-          ['url'],
-        ],
-      },
-    ],
-  },
-
-  para: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['series'],
-          ['metrics'],
-          ['secondary_metric'],
-          ['adhoc_filters'],
-          ['limit', 'row_limit'],
-        ],
-      },
-      {
-        label: t('Options'),
-        expanded: true,
-        controlSetRows: [
-          ['show_datatable', 'include_series'],
-          ['linear_color_scheme'],
-        ],
-      },
-    ],
-  },
-
-  heatmap: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['all_columns_x', 'all_columns_y'],
-          ['metric'],
-          ['adhoc_filters'],
-          ['row_limit'],
-        ],
-      },
-      {
-        label: t('Heatmap Options'),
-        expanded: true,
-        controlSetRows: [
-          ['linear_color_scheme'],
-          ['xscale_interval', 'yscale_interval'],
-          ['canvas_image_rendering', 'normalize_across'],
-          ['left_margin', 'bottom_margin'],
-          ['y_axis_bounds', 'y_axis_format'],
-          ['show_legend', 'show_perc'],
-          ['show_values', 'normalized'],
-          ['sort_x_axis', 'sort_y_axis'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      all_columns_x: {
-        validators: [nonEmpty],
-      },
-      all_columns_y: {
-        validators: [nonEmpty],
-      },
-      normalized: t('Whether to apply a normal distribution based on rank on 
the color scale'),
-      y_axis_bounds: {
-        label: t('Value bounds'),
-        renderTrigger: true,
-        description: t(
-          'Hard value bounds applied for color coding. Is only relevant ' +
-          'and applied when the normalization is applied against the whole 
heatmap.'),
-      },
-      y_axis_format: {
-        label: t('Value Format'),
-      },
-    },
-  },
-
-  horizon: {
-    controlPanelSections: [
-      sections.NVD3TimeSeries[0],
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['series_height', 'horizon_color_scale'],
-        ],
-      },
-    ],
-  },
-
-  mapbox: {
-    controlPanelSections: [
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['all_columns_x', 'all_columns_y'],
-          ['clustering_radius'],
-          ['row_limit'],
-          ['adhoc_filters'],
-          ['groupby'],
-        ],
-      },
-      {
-        label: t('Points'),
-        controlSetRows: [
-          ['point_radius'],
-          ['point_radius_unit'],
-        ],
-      },
-      {
-        label: t('Labelling'),
-        controlSetRows: [
-          ['mapbox_label'],
-          ['pandas_aggfunc'],
-        ],
-      },
-      {
-        label: t('Visual Tweaks'),
-        controlSetRows: [
-          ['render_while_dragging'],
-          ['mapbox_style'],
-          ['global_opacity'],
-          ['mapbox_color'],
-        ],
-      },
-      {
-        label: t('Viewport'),
-        expanded: true,
-        controlSetRows: [
-          ['viewport_longitude', 'viewport_latitude'],
-          ['viewport_zoom', null],
-        ],
-      },
-    ],
-    controlOverrides: {
-      all_columns_x: {
-        label: t('Longitude'),
-        description: t('Column containing longitude data'),
-      },
-      all_columns_y: {
-        label: t('Latitude'),
-        description: t('Column containing latitude data'),
-      },
-      pandas_aggfunc: {
-        label: t('Cluster label aggregator'),
-        description: t('Aggregate function applied to the list of points ' +
-          'in each cluster to produce the cluster label.'),
-      },
-      rich_tooltip: {
-        label: t('Tooltip'),
-        description: t('Show a tooltip when hovering over points and clusters 
' +
-          'describing the label'),
-      },
-      groupby: {
-        description: t('One or many controls to group by. If grouping, 
latitude ' +
-          'and longitude columns must be present.'),
-      },
-    },
-  },
-
-  event_flow: {
-    requiresTime: true,
-    controlPanelSections: [
-      {
-        label: t('Event definition'),
-        controlSetRows: [
-          ['entity'],
-          ['all_columns_x'],
-          ['row_limit'],
-          ['order_by_entity'],
-          ['min_leaf_node_event_count'],
-        ],
-      },
-      {
-        label: t('Query'),
-        expanded: true,
-        controlSetRows: [
-          ['adhoc_filters'],
-        ],
-      },
-      {
-        label: t('Additional metadata'),
-        controlSetRows: [
-          ['all_columns'],
-        ],
-      },
-    ],
-    controlOverrides: {
-      entity: {
-        label: t('Column containing entity ids'),
-        description: t('e.g., a "user id" column'),
-      },
-      all_columns_x: {
-        label: t('Column containing event names'),
-        validators: [nonEmpty],
-        default: control => (
-          control.choices && control.choices.length > 0 ?
-            control.choices[0][0] : null
-        ),
-      },
-      row_limit: {
-        label: t('Event count limit'),
-        description: t('The maximum number of events to return, equivalent to 
the number of rows'),
-      },
-      all_columns: {
-        label: t('Meta data'),
-        description: t('Select any columns for metadata inspection'),
-      },
-    },
-  },
-
-  paired_ttest: {
-    requiresTime: true,
-    controlPanelSections: [
-      sections.NVD3TimeSeries[0],
-      {
-        label: t('Paired t-test'),
-        expanded: false,
-        controlSetRows: [
-          ['significance_level'],
-          ['pvalue_precision'],
-          ['liftvalue_precision'],
-        ],
-      },
-    ],
-  },
-
-  rose: {
-    requiresTime: true,
-    controlPanelSections: [
-      sections.NVD3TimeSeries[0],
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['number_format', 'date_time_format'],
-          ['rich_tooltip', 'rose_area_proportion'],
-        ],
-      },
-      sections.NVD3TimeSeries[1],
-    ],
-  },
-
-  partition: {
-    controlPanelSections: [
-      sections.NVD3TimeSeries[0],
-      {
-        label: t('Time Series Options'),
-        expanded: true,
-        controlSetRows: [
-          ['time_series_option'],
-        ],
-      },
-      {
-        label: t('Chart Options'),
-        expanded: true,
-        controlSetRows: [
-          ['color_scheme'],
-          ['number_format', 'date_time_format'],
-          ['partition_limit', 'partition_threshold'],
-          ['log_scale', 'equal_date_size'],
-          ['rich_tooltip'],
-        ],
-      },
-      sections.NVD3TimeSeries[1],
-    ],
-  },
-};
-
-export default visTypes;
-
-export function sectionsToRender(vizType, datasourceType) {
-  const viz = visTypes[vizType];
-
-  const sectionsCopy = { ...sections };
-  if (viz.sectionOverrides) {
-    Object.entries(viz.sectionOverrides).forEach(([section, overrides]) => {
-      if (typeof overrides === 'object' && overrides.constructor === Object) {
-        sectionsCopy[section] = {
-          ...sectionsCopy[section],
-          ...overrides,
-        };
-      } else {
-        sectionsCopy[section] = overrides;
-      }
-    });
-  }
-
-  return [].concat(
-    sectionsCopy.datasourceAndVizType,
-    datasourceType === 'table' ? sectionsCopy.sqlaTimeSeries : 
sectionsCopy.druidTimeSeries,
-    isFeatureEnabled(FeatureFlag.SCOPED_FILTER) ? sectionsCopy.filters : 
undefined,
-    viz.controlPanelSections,
-  ).filter(section => section);
-}


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to