import{d as u,s as l}from"./links.C2upUfsO.js";import{c as i}from"./postSlug.aEbF4K7B.js";const m={methods:{parseTags(e){const n=u();return!e||!n.tags?e:(n.tags.forEach(a=>{if(a.id==="custom_field"){const o=new RegExp(`#${a.id}-([a-zA-Z0-9_-]+)`),r=e.match(o);r&&r[1]&&(e=e.replace(o,i(r[1])));return}if(a.id==="tax_name"){const o=new RegExp(`#${a.id}-([a-zA-Z0-9_-]+)`,"g");e=e.replace(o,`[${a.name} - $1]`);return}const t=new RegExp(`#${a.id}(?![a-zA-Z0-9_])`,"g");a.id==="separator_sa"&&this.separator!==void 0&&(e=e.replace(t,this.separator));const c=e.match(t),s=n.liveTags[a.id]??a.value;c&&(e=e.replace(t,"%|%"+s))}),e=e.replace(/%\|%/g,""),l(e))}}};export{m as T};
