From 92b6f6b0155ae75282ecf09f0703bd46ca16fe2d Mon Sep 17 00:00:00 2001 From: Nikita Poltoratsky Date: Mon, 1 Oct 2018 16:35:07 +0300 Subject: [PATCH] fix(radio): radio group ngModel doesn't setup initial value (#842) --- src/framework/theme/components/radio/radio-group.component.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/framework/theme/components/radio/radio-group.component.ts b/src/framework/theme/components/radio/radio-group.component.ts index 4e424dd853..c87ae88efc 100644 --- a/src/framework/theme/components/radio/radio-group.component.ts +++ b/src/framework/theme/components/radio/radio-group.component.ts @@ -127,6 +127,10 @@ export class NbRadioGroupComponent implements AfterContentInit, OnDestroy, Contr writeValue(value: any): void { this.value = value; + + if (typeof value !== 'undefined') { + this.updateValues(); + } } protected updateNames() {