{"version":3,"file":"remarkIgnoreMarkdown.mjs","names":[],"sources":["../../../../../../src/components/Message/renderText/remarkPlugins/remarkIgnoreMarkdown.ts"],"sourcesContent":["import type { Plugin } from 'unified';\nimport type { Paragraph, Root, Text } from 'mdast';\n\n/**\n * Replaces the parsed Markdown tree with a single paragraph holding the raw source as plain text,\n * so no Markdown formatting is interpreted.\n */\nexport const remarkIgnoreMarkdown: Plugin<[], Root> = () => (tree, file) => {\n  const source = String(file.value ?? '');\n\n  const text: Text = { type: 'text', value: source };\n  const paragraph: Paragraph = { children: [text], type: 'paragraph' };\n\n  tree.children = [paragraph];\n};\n"],"mappings":";;;;;AAOA,IAAa,8BAAgD,MAAM,SAAS;CAM1E,KAAK,WAAW,CAAC;EAFc,UAAU,CAAC;GADrB,MAAM;GAAQ,OAFpB,OAAO,KAAK,SAAS,EAEM;EACA,CAAI;EAAG,MAAM;CAEtC,CAAS;AAC5B"}