eschutho commented on a change in pull request #13032:
URL: https://github.com/apache/superset/pull/13032#discussion_r575491667
##########
File path: superset-frontend/src/SqlLab/components/HighlightedSql.tsx
##########
@@ -27,93 +26,92 @@ import ModalTrigger from '../../components/ModalTrigger';
SyntaxHighlighter.registerLanguage('sql', sql);
-const defaultProps = {
- maxWidth: 50,
- maxLines: 5,
- shrink: false,
-};
+interface propTypes {
+ sql: string;
+ rawSql?: string;
+ maxWidth?: number;
+ maxLines?: number;
+ shrink?: any;
+}
-const propTypes = {
- sql: PropTypes.string.isRequired,
- rawSql: PropTypes.string,
- maxWidth: PropTypes.number,
- maxLines: PropTypes.number,
- shrink: PropTypes.bool,
-};
+interface modalTypes {
+ rawSql?: string;
+ sql: string;
+}
-class HighlightedSql extends React.Component {
- constructor(props) {
- super(props);
- this.state = {
- modalBody: null,
- };
- }
+interface nodeTypes {
Review comment:
This is great. The naming convention that we're using is
TriggerNodeProps, HighlightedSqlModalProps, etc.
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]