-
Notifications
You must be signed in to change notification settings - Fork 14.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
style: DOCTYPE tag, and related CSS cleanup/refactoring #10302
Changes from all commits
671a1b4
1627074
eafff37
626fd48
f7e710a
dcb56b6
5061f7b
4ec06bc
e61eb18
9825574
fc806a8
1f9e961
d62975a
f3ec1b0
f056bae
e0e15da
12e5b98
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,8 +18,8 @@ | |
*/ | ||
import React from 'react'; | ||
import PropTypes from 'prop-types'; | ||
import { Panel } from 'react-bootstrap'; | ||
import { ParentSize } from '@vx/responsive'; | ||
import styled from '@superset-ui/style'; | ||
import { chartPropShape } from '../../dashboard/util/propShapes'; | ||
import ChartContainer from '../../chart/ChartContainer'; | ||
import ExploreChartHeader from './ExploreChartHeader'; | ||
|
@@ -49,6 +49,19 @@ const propTypes = { | |
triggerRender: PropTypes.bool, | ||
}; | ||
|
||
const Styles = styled.div` | ||
background-color: ${({ theme }) => theme.colors.grayscale.light5}; | ||
padding: ${({ theme }) => theme.gridUnit * 4}px; | ||
height: 100%; | ||
display: flex; | ||
flex-direction: column; | ||
align-items: stretch; | ||
align-content: stretch; | ||
div:last-of-type { | ||
flex-basis: 100%; | ||
} | ||
`; | ||
|
||
class ExploreChartPanel extends React.PureComponent { | ||
renderChart() { | ||
const { chart } = this.props; | ||
|
@@ -113,13 +126,12 @@ class ExploreChartPanel extends React.PureComponent { | |
chart={this.props.chart} | ||
/> | ||
); | ||
|
||
return ( | ||
<div className="chart-container"> | ||
<Panel style={{ height: this.props.height }}> | ||
<Panel.Heading>{header}</Panel.Heading> | ||
<Panel.Body>{this.renderChart()}</Panel.Body> | ||
</Panel> | ||
</div> | ||
<Styles className="chart-container"> | ||
<div>{header}</div> | ||
<div>{this.renderChart()}</div> | ||
</Styles> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @rusackas by not using the AfterBeforeThere was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Just pushed a fix. I'm using the raw boostrap classes for now. Let's refactor it into Antd components or a more self-contained styled component in the future. |
||
); | ||
} | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is breaking FilterBox in Explore page. @rusackas
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dang! Thanks for the quick catch. I'll take a look.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Didn't get to fix it entirely last night... but it's not just that style... there are some dimensions that need to be added to a div... they're being added to other viz components, but not this one for some reason. Hope to have a PR soon.