Skip to content

Bindable Placeholder #51

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

Open
gottfrois opened this issue Feb 27, 2015 · 1 comment
Open

Bindable Placeholder #51

gottfrois opened this issue Feb 27, 2015 · 1 comment

Comments

@gottfrois
Copy link

When setting a placeholder as a string, everything work as expected but when setting a placeholder using a scoped variable, the placeholder is evaluated for the select DOM element but not for the input DOM element. Please see the demo on the single select scenario here http://plnkr.co/edit/QZTxGG?p=preview

Output here http://d.pr/i/aoc8

@PhiLhoSoft
Copy link
Contributor

+1
I have an object tracking the state of the combo box (loading, loaded, empty, disabled...) and exposing a message for each state. It would be nice it I could just bind to the message field of this object.
Meanwhile, I just get the instance of Selectize and update the placeholder manually.
The way to do it isn't really documented (kind of using internal API), so I give it here for the record:

            updatePlaceholder: function(placeholder)
            {
                this.selectizeControl.settings.placeholder = placeholder;
                this.selectizeControl.updatePlaceholder();
            },

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

No branches or pull requests

2 participants