-
-
Notifications
You must be signed in to change notification settings - Fork 133
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
Example for ngx-mat-select-search with grouping option #15
Comments
@vjpc thanks for the suggestion. would you like to try and create such an example? |
@macjohnny I am new to angular and tried with your github code to modify it for group but finding difficult to do it. It will be really nice if you can share one. Thanks. |
@macjohnny @vjpc For @macjohnny, instead of using an array of inputs such as your Bank[] array, the shape of the input will now have to be like the one below:
An example is at https://material.angular.io/components/select/overview Were you succesful @vjpc? I would also like to see your example. For me the problem is discussed below:
For me to use groups, the same code would be similar to below:
The question is how do I convert the last snippet to be usable with ngx-mat-select? Cheers |
@st-clair-clarke You can place the |
Thanks. Looking forward to your working example ASAP. Cheers |
@st-clair-clarke I added an example: a07e911 It is not perfect yet as it needs to copy the option groups. If you have any suggestions to improve the example, please let me know! See also #66 |
Thanks for your help. Working great. I saw where I was making the mistakes. Still tweaking. I will suggest improvement as I go along. |
Hi. Compare your domain models to that of material2 for the select component:
... would/should ? represent the shape of a select option as shown below:
.. your
... would/should ? represent the shape of a select option group:
If this is done then your package would be using similar models to material2 select. For a long group, such as some of mine, the id property of the Bank model is creating a challenge for finding unique names. Do let me know what you think. And thanks again. NB: The reason I am proposing the tweak is because I have a lot of select models that I would have to port to your model. I don't know how the suggestion would affect you or others using the package. It would be nice to hear from them also. Cheers |
@st-clair-clarke Thanks for your suggestion. I think it could make sense to adopt the examples to the |
I will do that. NB. Could you please expose the place holder for the search box. Currently it is always saying 'Suche'. Cheers |
Adjust to material2 interface - Done! |
@st-clair-clarke Please see https://github.com/bithost-gmbh/ngx-mat-select-search#labels to change the placeholder label. |
@st-clair-clarke I had a very specific requirement for grouping and found it difficult to implement using ngx-mat-select. So instead used the mat-autocomplete. |
@vjpc Hi vjpc. Are you saying that you use the mat-autocomplete to implement a form of grouping selection? Could you please share an example, preferable a link to a stackblitz demo? |
example added in #66 |
Hi Mat,
It will be really helpful if you could please share example for ngx-mat-select-search with grouping option (Select with option groups).
Thanks,
Vijay
The text was updated successfully, but these errors were encountered: