kristw commented on a change in pull request #9455: Migrating shared DeckGL 
controls
URL: 
https://github.com/apache/incubator-superset/pull/9455#discussion_r403157037
 
 

 ##########
 File path: superset-frontend/src/explore/controlPanels/DeckArc.js
 ##########
 @@ -26,44 +41,98 @@ export default {
       label: t('Query'),
       expanded: true,
       controlSetRows: [
-        ['start_spatial', 'end_spatial'],
-        ['row_limit', 'filter_nulls'],
+        [
+          {
+            name: 'start_spatial',
+            config: {
+              type: 'SpatialControl',
+              label: t('Start Longitude & Latitude'),
+              validators: [nonEmpty],
+              description: t('Point to your spatial columns'),
+              mapStateToProps: state => ({
+                choices: columnChoices(state.datasource),
+              }),
+            },
+          },
+          {
+            name: 'end_spatial',
+            config: {
+              type: 'SpatialControl',
+              label: t('End Longitude & Latitude'),
+              validators: [nonEmpty],
+              description: t('Point to your spatial columns'),
+              mapStateToProps: state => ({
+                choices: columnChoices(state.datasource),
+              }),
+            },
+          },
+        ],
+        ['row_limit', filterNulls],
         ['adhoc_filters'],
       ],
     },
     {
       label: t('Map'),
       controlSetRows: [
-        ['mapbox_style', 'viewport'],
-        ['autozoom', null],
+        ['mapbox_style', viewport],
+        [autozoom, null],
       ],
     },
     {
       label: t('Arc'),
       controlSetRows: [
-        ['color_picker', 'target_color_picker'],
-        ['dimension', 'color_scheme', 'label_colors'],
-        ['stroke_width', 'legend_position'],
-        ['legend_format', null],
+        [
+          'color_picker',
+          {
+            name: 'target_color_picker',
+            config: {
+              label: t('Target Color'),
+              description: t('Color of the target location'),
+              type: 'ColorPickerControl',
+              default: PRIMARY_COLOR,
+              renderTrigger: true,
+            },
+          },
+        ],
+        [
+          Object.assign({}, dimension, {
 
 Review comment:
   could do `{...dimension, { label: ... } }`

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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