Skip to content
This repository has been archived by the owner on Nov 16, 2017. It is now read-only.

T/10: Provide necessary UI components for Classic Creator #11

Merged
merged 14 commits into from
May 19, 2016
Merged

Conversation

oleq
Copy link
Member

@oleq oleq commented May 9, 2016

As in ckeditor/ckeditor5#135.

Closes #10.

@oleq oleq added this to the 0.1.0 milestone May 9, 2016
marginLeft: -window.scrollX - 1 + 'px'
} );

this.model.isSticky = true;
Copy link
Member

Choose a reason for hiding this comment

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

I don't like the view changing the model. This in fact isn't needed in the model at all. This is view's property (internal at this point).

Copy link
Member Author

Choose a reason for hiding this comment

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

It is a thing of a model because of:

this.template.attributes.class.push( bind.if( 'isSticky', 'ck-toolbar_sticky' ) );

Copy link
Member

Choose a reason for hiding this comment

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

That's a super bad smell for me unfortunately ;/. If we need to add something to the model only to make bindings work, it's wrong.

Copy link
Member

Choose a reason for hiding this comment

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

PS. Note that isSticky is a totally presentational property.

@Reinmar
Copy link
Member

Reinmar commented May 13, 2016

Beside these two issue which I commented, it's ready for merge.

@Reinmar Reinmar removed this from the 0.1.0 milestone May 13, 2016
@oleq
Copy link
Member Author

oleq commented May 13, 2016

I suppose I also forgot about tests for StyckyToolbarView.

@Reinmar
Copy link
Member

Reinmar commented May 13, 2016

Surprisingly, 0 tests means 100% CC :P.

@Reinmar
Copy link
Member

Reinmar commented May 17, 2016

For me #11 (comment) still makes it R-.

@Reinmar
Copy link
Member

Reinmar commented May 17, 2016

For me #11 (comment) still makes it R-.

OK, we talked with @oleq that this needs a bigger refactoring in couple of existing components at once. We decided to try to implement MVVM in all components, because this pattern should fit best, but needs to be implement more consistently.

So, for now we're going to ignore this issue. We'll address it later in https://github.com/ckeditor/ckeditor5-ui/issues/26

@Reinmar Reinmar merged commit f1ef58d into master May 19, 2016
@Reinmar Reinmar deleted the t/10 branch May 19, 2016 08:19
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants