Skip to content
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

Fix string refs #14

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Fix string refs #14

wants to merge 3 commits into from

Conversation

drdla
Copy link

@drdla drdla commented Dec 26, 2018

The timeline (v 0.4.0) did not render in my app, because of errors related to string refs.
I fixed the ref assignments and added two missing dependencies (moment and sizeme).
A few failing tests are fixed now, but there are still two failing tests.
Nevertheless, at least the build of this branch is now working in my app.

);
};
shouldComponentUpdate(nextProps, nextState) {
if (nextProps.value != this.props.value) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strict inequality operator should be used !==

Comment on lines +43 to +46
if (position == 'top') return 'MMMM YYYY';
else return 'MMMM';
case 'week':
if (position == 'top') return 'ww MMMM YYYY';

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strict equality operator should be used ===

let hourWidth = width / 24;
let iterLeft = 0;
for (let i = 0; i < 24; i++) {
result.push(<HeaderItem key={i} left={iterLeft} width={hourWidth} label={mode == 'shorttime' ? i : `${i}:00`} />);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strict equality operator should be used ===

currentBottom = currentDate.format(this.getFormat(bottom));
box = this.getBox(currentDate, bottom, lastLeft.bottom);
lastLeft.bottom = box.left + box.width;
if (bottom == 'shorttime' || bottom == 'fulltime') {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strict equality operator should be used ===

Comment on lines +195 to +199
//Check boundaries to see if wee need to recalcualte header
// if (this.needToRender()|| !this.cache){
// this.cache=this.renderHeader();
// this.setBoundaries();
// }

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commented code should not be pushed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants