Skip to content

Commit 34ea55f

Browse files
committed
Fixed minor issue.
1 parent 9312cbe commit 34ea55f

File tree

2 files changed

+11
-15
lines changed

2 files changed

+11
-15
lines changed

example/DrillDown.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -149,11 +149,8 @@ class DrillDown extends React.Component {
149149
)}
150150
{ this.state.showOverlaybtn ?
151151
<button style={
152-
this.state.showDefaultOverlayBtn ?
153-
btnStyle : (
154-
this.props.customOverlayBtnStyle ?
155-
{cursor: 'pointer', ...this.props.customOverlayBtnStyle} : btnStyle
156-
)
152+
this.props.customOverlayBtnStyle === undefined ?
153+
btnStyle : {cursor: 'pointer', ...this.props.customOverlayBtnStyle}
157154
}
158155
onClick={this.onClickOverlayBtn.bind(this)}>
159156
{

example/Example.js

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ const thirdDataSource = {
119119
}]
120120
};
121121

122-
const mappedIdsIntegers = [0, 1, 2, 3, null];
122+
const mappedIdsIntegers = [0, 1, 2, 3, null]; // Index = plotPosition, array[Index] = childPosition
123123

124124
const mappedIdsObjects = [
125125
{
@@ -181,7 +181,7 @@ class Example extends React.Component {
181181
width='600'
182182
height='400'
183183
dataFormat="JSON"
184-
defaultOverlayBtnSettings={{ // This object holds the style of the overlay back button.
184+
defaultOverlayBtnSettings={{ // This object holds the configuration of the default overlay button.
185185
message: 'ESCAPE',
186186
color: '#FFFFFF',
187187
backgroundColor: '#512A44',
@@ -198,13 +198,12 @@ class Example extends React.Component {
198198
width='600'
199199
height='400'
200200
dataFormat="JSON"
201-
// defaultOverlayBtnSettings={{ // This object holds the style of the overlay back button.
202-
// message: 'REVERT',
203-
// fontSize: '14px',
204-
// placement: 'top-right',
205-
// margin: '10px'
206-
// }}
207-
customOverlayBtnStyle={{backgroundColor: 'red', color: 'white', padding: 8, fontSize: 16}}
201+
customOverlayBtnStyle={{ // This object holds the css for custom overlay button
202+
backgroundColor: 'red',
203+
color: 'white',
204+
padding: 8,
205+
fontSize: 16
206+
}}
208207
dataSource={zerothDataScource}
209208
mappedIds={[0, 1, 2]}>
210209
<DrillDown
@@ -283,7 +282,7 @@ class Example extends React.Component {
283282
dataFormat="JSON"
284283
dataSource={thirdDataSource} />
285284
</DrillDown>
286-
<div style={{ height: 300, backgroundColor: 'red', width: 400 }}></div>
285+
<div style={{ height: 300, width: 400 }}></div>
287286
</div>
288287
)
289288
}

0 commit comments

Comments
 (0)