If you're looking to ensure that the selected button appears active when clicked, and you're utilizing Bootstrap styles without the Bootstrap javascript component, you'll need to handle this within Angular yourself.
To show a radio button as "checked," you need to apply the active style to the label's class list.
Applying .active for Preselected Options:
To mark preselected options, you'll have to manually add the .active class to the input's label.
In Angular, dynamically modifying an element's class list can be accomplished using ng-class. Refer to the directive documentation for various options on how to implement it effectively.
I've made adjustments to your example by incorporating the ng-class directive, resulting in the button reflecting its active state upon clicking.
Although I don't suggest directly assigning CSS classes in your controller, this serves as a starting point for determining the optimal approach based on your scenario.
View
<div>poiType is set to 0, hence the first button will be selected
<div ng-controller="TodoCtrl as ctrl" style="margin-bottom: 5px; padding: 5px; width:100%;">
<div class="btn-group btn-group-justified">
<label ng-class="ctrl.class(ctrl.TYPE_POI)">
<input type="radio" ng-value="ctrl.TYPE_POI" ng-model="ctrl.poiType" />POI</label>
<label ng-class="ctrl.class(ctrl.TYPE_TRIP)">
<input type="radio" autocomplete="off" ng-value="ctrl.TYPE_TRIP" ng-model="ctrl.poiType" />itinerari</label>
<label ng-class="ctrl.class(ctrl.TYPE_EVENT)">
<input type="radio" autocomplete="off" ng-value="ctrl.TYPE_EVENT" ng-model="ctrl.poiType" />eventi</label>
</div>ctrl.poiType = {{ctrl.poiType}}</div>
</div>
Controller
angular.module('epoiApp', [])
.controller('TodoCtrl', function () {
this.poiType = 0; // initializing first button selection
this.TYPE_POI = 0;
this.TYPE_TRIP = 1;
this.TYPE_WAYPOINT = 2;
this.TYPE_EVENT = 3;
this.class = function (poiType) {
if (poiType == this.poiType) {
return 'btn btn-default active';
} else {
return 'btn btn-default';
}
}
});
Check out the working example on fiddle.