I did some furhter tests:
$scope.setWidgetProp("modelItem-1", "color", "rgba(128,0,0,1);"); //brown
$scope.setWidgetProp("modelItem-1", "opacity", "0.3"); //set transparency to 0.3
//or this will also work
$scope.setWidgetProp("modelItem-1", "opacity", 0.3); //set transparency to 0.3
So seems that the better approach is to use for the transparency setting the opacity property. This is also the supported way to to set the transparency - and here also the setting of the alpha channel. Because the effect of this code on android device is the same:
$scope.setWidgetProp("modelItem-1", "color", "rgba(128,0,0,1);"); //brown
$scope.setWidgetProp("modelItem-1", "opacity", "0.3"); //set transparency to 0.3
with the call of
$scope.setWidgetProp("modelItem-1", "color", "rgba(128,0,0,0.3);"); //currently work only on Android device
On all other devices (IOS and HoloLens) the "alpha channel" setting will be ignored (it could be only = 1 - displayed or = 0 hidden)
Therefore , I think, is better if you set the opacity modelItem property , because this will work on the same way on all devices:
$scope.view.wdg['modelItem-1']['color'] = "rgba(128,0,0, 1);";//brown
$scope.view.wdg['modelItem-1']['opacity'] = 0.5;//set transparency to 0.5
//or for the same
$scope.setWidgetProp("modelItem-1", "color", "rgba(128,0,0,1);"); //brown
$scope.setWidgetProp("modelItem-1", "opacity", 0.5); //set transparency to 0.5