| Linux premium331.web-hosting.com 4.18.0-553.80.1.lve.el8.x86_64 #1 SMP Wed Oct 22 19:29:36 UTC 2025 x86_64 Path : /home/livedhms/lmgt/node_modules/zeptomatch/dist/normalize/ |
| Current File : /home/livedhms/lmgt/node_modules/zeptomatch/dist/normalize/grammar.js |
/* IMPORT */
import { match, or, star } from 'grammex';
import { identity } from '../utils.js';
/* MAIN */
const Escaped = match(/\\./, identity);
const Passthrough = match(/./, identity);
const StarStarStar = match(/\*\*\*+/, '*');
const StarStarNoLeft = match(/([^/{[(!])\*\*/, (_, $1) => `${$1}*`);
const StarStarNoRight = match(/(^|.)\*\*(?=[^*/)\]}])/, (_, $1) => `${$1}*`);
const Grammar = star(or([Escaped, StarStarStar, StarStarNoLeft, StarStarNoRight, Passthrough]));
/* EXPORT */
export default Grammar;