export type AcrValues = Partial < { acr_values : any ; } > ; export function pickAcr ( knownAcrValues , acrValues , defaultAcrValue ) { note const intersection = knownAcrValues . filter ( ( acr ) => acrValues . includes ( acr ) ) ; const hasCommonValues = Boolean ( intersection . length ) ; if ( ! hasCommonValues ) { return defaultAcrValue ; } const lowestEidasValue = intersection . shift ( ) ; return lowestEidasValue ; }