This means you can ignore the "flatui-radio.js" file and just use plain angular. Not had any problems so far.
Last active
December 19, 2015 17:39
-
-
Save petehamilton/5993366 to your computer and use it in GitHub Desktop.
FlatUI Radio Button Directive for AngularJS
@jules-winnfield Thanks! Just got it working myself through the same GIST post.
How are you guys using the value and model of the directive? Right now, I have my value inverting the value of the model which is the only way to get the radio to update.
Controller:
$scope.thing = {"name": "thing1", "id": 1, "selected": true};
View:
<fui-radio
model="thing.selected"
label="thing.name"
value="!thing.selected"
required="true"
name="valcontainer2">
</fui-radio>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Finally we got it working. A good help was this GIST
We have just copied this code here into an own directive called
fuiradio
. Than you can include it in any partials like:If you want to use simple strings in label and value (obey the single quotes):
Or if you want to use dynamic labels and values:
Hope this helps!