UNPKG

662 BSource Map (JSON)View Raw
1{"version":3,"sources":["../src/type-min-length.js"],"names":["parsed","when","value","input","type"],"mappings":";;;;;;AAAA;;kBAEe,UAACA,MAAD,EAASC,IAAT,EAAeC,KAAf,EAAyB;AACvC,KAAMC,QAAQH,OAAOI,IAArB;AACA,KAAI,CAACD,KAAL,EAAY;AACX,SAAO,CAAC,IAAD,CAAP;AACA;AACD,QAAO,CACN,uBAAUA,KAAV,EAAiBD,KAAjB,CADM,EAEL,iCAAgCA,KAAM,aAFjC,CAAP;AAIA,C","file":"type-min-length.js","sourcesContent":["import {minLength} from '@commitlint/ensure';\n\nexport default (parsed, when, value) => {\n\tconst input = parsed.type;\n\tif (!input) {\n\t\treturn [true];\n\t}\n\treturn [\n\t\tminLength(input, value),\n\t\t`type must not be shorter than ${value} characters`\n\t];\n};\n"]}
\No newline at end of file