Skip to content

Commit

Permalink
fixed lint errors
Browse files Browse the repository at this point in the history
  • Loading branch information
Sagiv Ben Giat authored and Sagiv Ben Giat committed Apr 19, 2017
1 parent 1293a92 commit 83e7e85
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 15 deletions.
20 changes: 10 additions & 10 deletions src/components/DayPicker.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -404,12 +404,12 @@ export default class DayPicker extends React.Component {
if (this.props.onNextMonthClick) {
this.props.onNextMonthClick(e);
}

const convertedTranslationValueRTL = (this.dayPickerWidth + this.state.translationValueRTL);
let translationValue = this.props.isRTL ? convertedTranslationValueRTL : -this.dayPickerWidth;
if(this.isVertical()){
translationValue = this.getMonthHeightByIndex(1) * -1

if (this.isVertical()) {
translationValue = this.getMonthHeightByIndex(1) * -1;
}

this.setState({
Expand Down Expand Up @@ -502,12 +502,12 @@ export default class DayPicker extends React.Component {
}

updateStateAfterMonthTransition() {
const {
currentMonth,
monthTransition,
focusedDate,
nextFocusedDate,
translationValueRTL
const {
currentMonth,
monthTransition,
focusedDate,
nextFocusedDate,
translationValueRTL,
} = this.state;

if (!monthTransition) return;
Expand Down
5 changes: 0 additions & 5 deletions src/components/DayPickerNavigation.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,7 @@ const defaultProps = {

// internationalization
phrases: DayPickerNavigationPhrases,


isRTL: false,

};

export default function DayPickerNavigation(props) {
Expand All @@ -55,9 +52,7 @@ export default function DayPickerNavigation(props) {
onNextMonthClick,
orientation,
phrases,

isRTL,

} = props;

const isVertical = orientation !== HORIZONTAL_ORIENTATION;
Expand Down

0 comments on commit 83e7e85

Please sign in to comment.