williaster commented on a change in pull request #5707: [SIP-5] Refactor table
URL:
https://github.com/apache/incubator-superset/pull/5707#discussion_r214225087
##########
File path: superset/assets/src/visualizations/table.js
##########
@@ -1,103 +1,141 @@
import d3 from 'd3';
+import $ from 'jquery';
+import PropTypes from 'prop-types';
import dt from 'datatables.net-bs';
import 'datatables.net-bs/css/dataTables.bootstrap.css';
import dompurify from 'dompurify';
-
import { fixDataTableBodyHeight, d3TimeFormatPreset } from '../modules/utils';
import './table.css';
-const $ = require('jquery');
-
dt(window, $);
-function tableVis(slice, payload) {
- const container = $(slice.selector);
- const fC = d3.format('0,000');
+const propTypes = {
+ // Each object is { field1: value1, field2: value2 }
+ data: PropTypes.arrayOf(PropTypes.object),
+ height: PropTypes.number,
+ alignPn: PropTypes.bool,
Review comment:
"Pn" means positive/negative? could we update that variable name to be more
descriptive to indicate that?
----------------------------------------------------------------
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]