File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
projects/coreui-angular/src/lib/tabs-2/tab Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ import { TabsService } from '../tabs.service';
28
28
role : 'tab' ,
29
29
'[attr.aria-selected]' : 'isActive()' ,
30
30
'[attr.aria-controls]' : 'attrAriaControls()' ,
31
+ '[attr.disabled]' : 'attrDisabled() || null' ,
31
32
'[id]' : 'propId()' ,
32
33
'[tabindex]' : 'isActive() ? 0 : -1'
33
34
}
@@ -52,6 +53,7 @@ export class TabDirective implements FocusableOption {
52
53
}
53
54
54
55
readonly #disabled = signal ( false ) ;
56
+ readonly attrDisabled = computed ( ( ) => this . #disabled( ) || null ) ;
55
57
56
58
/**
57
59
* Item key.
@@ -82,7 +84,8 @@ export class TabDirective implements FocusableOption {
82
84
83
85
readonly hostClasses = computed ( ( ) => ( {
84
86
'nav-link' : true ,
85
- active : this . isActive ( )
87
+ active : this . isActive ( ) ,
88
+ disabled : this . #disabled( )
86
89
} ) ) ;
87
90
88
91
readonly propId = computed ( ( ) => this . id ( ) ?? `${ this . #tabsService. id ( ) } -tab-${ this . itemKey ( ) } ` ) ;
You can’t perform that action at this time.
0 commit comments