File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -88,9 +88,9 @@ class DefaultEditor extends Component {
8888 { this . hasTransforms ( ) && (
8989 < GraphTransformsPanel group = { _ ( 'Structure' ) } name = { _ ( 'Transforms' ) } />
9090 ) }
91- < StyleLayoutPanel group = { _ ( 'Style' ) } name = { _ ( 'General' ) } />
91+ < StyleLayoutPanel group = { _ ( 'Style' ) } name = { _ ( 'General' ) } collapsedOnStart />
9292 < StyleTracesPanel group = { _ ( 'Style' ) } name = { _ ( 'Traces' ) } />
93- { this . hasAxes ( ) && < StyleAxesPanel group = { _ ( 'Style' ) } name = { _ ( 'Axes' ) } /> }
93+ { this . hasAxes ( ) && < StyleAxesPanel group = { _ ( 'Style' ) } name = { _ ( 'Axes' ) } collapsedOnStart /> }
9494 { this . hasMaps ( ) && < StyleMapsPanel group = { _ ( 'Style' ) } name = { _ ( 'Maps' ) } /> }
9595 { this . hasLegend ( ) && < StyleLegendPanel group = { _ ( 'Style' ) } name = { _ ( 'Legend' ) } /> }
9696 { this . hasColorbars ( ) && < StyleColorbarsPanel group = { _ ( 'Style' ) } name = { _ ( 'Color Bars' ) } /> }
Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ export class Panel extends Component {
6868 } ) ;
6969
7070 if ( this . state . individualFoldStates . length !== numFolds ) {
71- const newFoldStates = new Array ( numFolds ) . fill ( false ) ;
71+ const newFoldStates = new Array ( numFolds ) . fill ( this . props . collapsedOnStart ) ;
7272 this . setState ( {
7373 individualFoldStates : this . props . addAction
7474 ? newFoldStates . map ( ( e , i ) => i !== numFolds - 1 )
@@ -129,10 +129,12 @@ Panel.propTypes = {
129129 noPadding : PropTypes . bool ,
130130 showExpandCollapse : PropTypes . bool ,
131131 canReorder : PropTypes . bool ,
132+ collapsedOnStart : PropTypes . bool ,
132133} ;
133134
134135Panel . defaultProps = {
135136 showExpandCollapse : true ,
137+ collapsedOnStart : false ,
136138} ;
137139
138140Panel . contextTypes = {
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ class StyleAxesPanel extends Component {
2727 render ( ) {
2828 const { localize : _ } = this . context ;
2929 return (
30- < LayoutPanel >
30+ < LayoutPanel { ... this . props } >
3131 < AxesFold
3232 name = { _ ( 'Titles' ) }
3333 axisFilter = { ( axis ) => ! ( axis . _name . includes ( 'angular' ) || axis . _subplot . includes ( 'geo' ) ) }
Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ import {HoverColor} from '../components/fields/derived';
2121import DataSelector from '../components/fields/DataSelector' ;
2222
2323const StyleLayoutPanel = ( props , { localize : _ } ) => (
24- < LayoutPanel >
24+ < LayoutPanel { ... props } >
2525 < PlotlyFold name = { _ ( 'Defaults' ) } >
2626 < ColorPicker label = { _ ( 'Plot Background' ) } attr = "plot_bgcolor" />
2727 < ColorPicker label = { _ ( 'Margin Color' ) } attr = "paper_bgcolor" />
You can’t perform that action at this time.
0 commit comments