license import { MDCFoundation } from '@material/base/foundation' ; import { MDCRadioAdapter } from './adapter' ; import { cssClasses , strings } from './constants' ; export class MDCRadioFoundation extends MDCFoundation < MDCRadioAdapter > { static override get cssClasses ( ) { return cssClasses ; } static override get strings ( ) { return strings ; } static override get defaultAdapter ( ) : MDCRadioAdapter { return { addClass : ( ) => undefined , removeClass : ( ) => undefined , setNativeControlDisabled : ( ) => undefined , } ; } constructor ( adapter ? ) { super ( { ... MDCRadioFoundation . defaultAdapter , ... adapter } ) ; } setDisabled ( disabled ) { const { DISABLED } = MDCRadioFoundation . cssClasses ; this . adapter . setNativeControlDisabled ( disabled ) ; if ( disabled ) { this . adapter . addClass ( DISABLED ) ; } else { this . adapter . removeClass ( DISABLED ) ; } } } export default MDCRadioFoundation ;