import { Lexer } from 'chevrotain';
import { KEYWORD } from './shared-tokens.js';
import createTokenFromConfig from './token-creator.js';
const mixMaxCategoryToken = createTokenFromConfig({ name: 'MIN_MAX_KEYWORD', pattern: Lexer.NA, categories: KEYWORD });
const minMaxTokens = [
    { name: 'MINLENGTH', pattern: 'minlength' },
    { name: 'MAXLENGTH', pattern: 'maxlength' },
    { name: 'MINBYTES', pattern: 'minbytes' },
    { name: 'MAXBYTES', pattern: 'maxbytes' },
    { name: 'MIN', pattern: 'min' },
    { name: 'MAX', pattern: 'max' },
].map(tokenConfig => {
    tokenConfig.categories = [mixMaxCategoryToken];
    return createTokenFromConfig(tokenConfig);
});
export default {
    categoryToken: mixMaxCategoryToken,
    tokens: [mixMaxCategoryToken, ...minMaxTokens],
};
