Reputation: 1288
I have Angular dialog and I am using Select2 as a plug-in for my dropdowns. Now, the select2 plugin is working well in some pages but not when I use ng-dialog.
$('.select2').select2();
<select class="js-example-basic-single form-control">
<option></option>
<option>Canada</option>
<option>Mexico</option>
<option>United States</option>
</select>
Plunker : http://plnkr.co/edit/XLdB6RKwAWlPkj7MGH6M?p=preview
Any help would be greatly appreciated. Thanks!
Upvotes: 3
Views: 603
Reputation: 1
The problem is that span field in select2 doesn't appear because "z-index" property in ngDialog css file, at .ngdialog class. You simply adjust his level to select2 works correctly.
Upvotes: 0
Reputation: 641
A better way to do this would be through the angular directive for select2. Which has been replaced by https://github.com/angular-ui/ui-select. You should have less issues with angular by using the directive.
Upvotes: 1