import { ExtractionRule , ExtractionScore } from './base' ; export class DynamicExtractionRule extends ExtractionRule { name = 'dynamic' ; shouldExtract ( str ) { if ( str . match ( /(?:^|[$.\b])t\w?\(/u ) ) return ExtractionScore . MustExclude ; if ( ! str . match ( /(?:['"`]|\$\{)/ ) ) return ExtractionScore . MustExclude ; return ExtractionScore . ShouldInclude ; } }