import { TokenType } from '@diplodoc/folding-headings-extension';
const ignoreTokenTypes = [
    TokenType.SectionOpen,
    TokenType.SectionClose,
    TokenType.ContentOpen,
    TokenType.ContentClose,
];
/** Filter heading section tokens, which are not needed in prosemirror-document */
export const skipSectionsPlugin = (md) => {
    md.core.ruler.push('skip-heading-sections', (state) => {
        state.tokens = state.tokens.filter((token) => !ignoreTokenTypes.includes(token.type));
    });
};
//# sourceMappingURL=skip-heading-sections.js.map
