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

Splitter: collapsed two-way binding or CollapsedChanged event #1273

Closed
MaklaCof opened this issue Jan 30, 2018 · 6 comments
Closed

Splitter: collapsed two-way binding or CollapsedChanged event #1273

MaklaCof opened this issue Jan 30, 2018 · 6 comments

Comments

@MaklaCof
Copy link

I'm submitting a...

  • Suggestion for improvement

What is the motivation or use case for changing the behavior?

  • I would like to save (on server for example) in what collapsed state user leaved splitter pane.
  • I would like to control collapsed state from code. Current the only option is to do it without [collapsible]="true", because there is no way I can track if user changed collapsed property in UI.

I suggest two-way binding for collapsed property.
If for some reason this is not possible, I suggest adding event CollapsedChange.

Same is done for size property as described here.

@gyoshev
Copy link

gyoshev commented Feb 21, 2018

This functionality has been released on the development channel, version v2.1.0-dev.201802151013.

@MaklaCof
Copy link
Author

@gyoshev
Can I ask what was released. 2-way binding, event or both? I check documentation on DEVELOP channel but not find that information.

@gyoshev
Copy link

gyoshev commented Feb 21, 2018

@MaklaCof both, because two-way binding is implemented through an event 🙂 In Angular, two-way binding is available for the property propName when there's a @Output() public propNameChange event emitter.

The event is documented in the SplitterPaneComponent API page.

@Kevat
Copy link

Kevat commented Feb 26, 2018

When will this functionality be available on the main channel? Is there a workaround for using that functionality with the current stable release? How can I bind to the collapsed event without using a development build?

@gyoshev
Copy link

gyoshev commented Feb 26, 2018

@Kevat version 2.1.0 of the package has just been released, and includes the above functionality.

@Kevat
Copy link

Kevat commented Feb 26, 2018

@gyoshev Thank you Alex! I was able to update the package and use the new event emitter for collapsedChange.

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

No branches or pull requests

3 participants