{"version":3,"file":"static/npm.unist-util-visit-parents.4ce729d9.js","mappings":"2HAGAA,EAAOC,QAGP,SAAsBC,EAAMC,EAAMC,GAChC,IAAIC,EAAQ,GAEQ,oBAATF,IACTC,EAAUD,EACVA,EAAO,MAMT,SAASG,EAAIC,GACX,IAAIC,EAMJ,OAJKL,GAAQI,EAAKJ,OAASA,IACzBK,EAASJ,EAAQG,EAAMF,EAAMI,WAG3BF,EAAKG,WAAuB,IAAXF,EAQvB,SAAaE,EAAUC,GACrB,IAEIC,EAFAC,EAASH,EAASG,OAClBC,GAAS,EAGbT,EAAMU,KAAKJ,GAEX,OAASG,EAAQD,GAGf,IAFAD,EAAQF,EAASI,MAEW,IAAfR,EAAIM,GACf,OAAO,EAMX,OAFAP,EAAMW,OAEC,CACT,CAzBWC,CAAIV,EAAKG,SAAUH,GAGrBC,CACT,CAfAF,EAAIJ,EAqCN,C","sources":["../node_modules/unist-util-visit-parents/index.js"],"sourcesContent":["'use strict'\n\n/* Expose. */\nmodule.exports = visitParents\n\n/* Visit. */\nfunction visitParents(tree, type, visitor) {\n var stack = []\n\n if (typeof type === 'function') {\n visitor = type\n type = null\n }\n\n one(tree)\n\n /* Visit a single node. */\n function one(node) {\n var result\n\n if (!type || node.type === type) {\n result = visitor(node, stack.concat())\n }\n\n if (node.children && result !== false) {\n return all(node.children, node)\n }\n\n return result\n }\n\n /* Visit children in `parent`. */\n function all(children, parent) {\n var length = children.length\n var index = -1\n var child\n\n stack.push(parent)\n\n while (++index < length) {\n child = children[index]\n\n if (child && one(child) === false) {\n return false\n }\n }\n\n stack.pop()\n\n return true\n }\n}\n"],"names":["module","exports","tree","type","visitor","stack","one","node","result","concat","children","parent","child","length","index","push","pop","all"],"sourceRoot":""}