diff --git a/plugins/slack/out/server.js b/plugins/slack/out/server.js
index a83eb53..83784a1 100644
--- a/plugins/slack/out/server.js
+++ b/plugins/slack/out/server.js
@@ -1,12 +1,12 @@
"use strict";const b=e=>({plugin:e}),T="post-to-slack",_=e=>{const k=e!=null&&e.withLinear?'{{#linear-issue-exists}} - {{linear-issue-id}}{{/linear-issue-exists}}':"";return`Plan for today
{{#tasks}}
- - {{slack-status}} {{title}}${k}
+ - {{slack-status}} {{title-without-tags}}${k}
{{else}}
- No tasks
{{/tasks}}
{{! Do not remove the extra curly braces around the slack-future-tasks block.}}
{{{{slack-future-tasks}}}}
- - {{slack-status}} {{title}}${k}
+ - {{slack-status}} {{title-without-tags}}${k}
{{{{/slack-future-tasks}}}}
-
`},y="account-tokens",O=b(e=>{const k="update-slack-messages",S=async()=>{const t=await e.store.getPluginItem(y);if(!t)throw new e.GraphQLError("User not authenticated.",{extensions:{code:"NOT_AUTHENTICATED",userFriendlyMessage:"You are not authenticated and will need to connect your Slack account(s) first."}});return t.value},p={TODO:"",DONE:"✅",CANCELED:"❌"},I=async t=>{const n=e.html.parse(t).querySelectorAll("slack-status").map(l=>{var u;if(!l.attributes["data-task-id"])return null;const r=(u=e.decodeGlobalId(l.attributes["data-task-id"]))==null?void 0:u.id;return r?parseInt(r):null}).filter(l=>l!==null);return await e.prisma.task.findMany({where:{id:{in:n}}}).then(l=>new Map(l.map(r=>[r.id,r])))},N=t=>e.html.parse(t).querySelectorAll("slack-message").map(c=>({teamId:c.attributes["data-team-id"],channelId:c.attributes["data-channel-id"],ts:c.attributes["data-ts"]}));return{onRequest:async t=>{if(t.path==="/auth")return Response.redirect(`https://slack-api-flow-dev.vercel.app/api/auth?api_endpoint=${e.serverOrigin}/api/plugin/${e.pluginSlug}/auth/callback`);if(t.path==="/auth/callback"){const n=await e.store.getPluginItem(y),{ok:c,...l}=t.body;if(!c)return console.log("❌ Slack auth callback failed - req.body.ok is false"),new Response("req.body.ok is false",{status:500});const r=await fetch(`https://slack.com/api/team.info?team=${l.team.id}`,{headers:{Authorization:`Bearer ${l.access_token??l.authed_user.access_token}`}}).then(async d=>await d.json()).catch(()=>null);if(!r)return console.log("❌ Slack auth callback failed - teamInfo.ok is false"),new Response("Couldn't get user's workspace info.",{status:500});const u={...l,created_at:new Date().toISOString(),team:{...l.team,...r.team}};return await e.store.setSecretItem(y,{...(n==null?void 0:n.value)??{},[u.team.id]:u}),new Response}return new Response},operations:{workspaces:async()=>{const t=await S().catch(()=>null);return t?{data:{workspaces:Object.entries(t).map(([n,c])=>({connectedAt:c.created_at,teamId:n,teamName:c.team.name,teamIcon:c.team.icon.image_44}))}}:{data:{workspaces:[]}}},getChannels:async t=>{const n=await S().catch(()=>null),c=[];for(const l in n){const r=n[l],u=await fetch("https://slack.com/api/conversations.list",{headers:{Authorization:`Bearer ${r.authed_user.access_token}`}}).then(async d=>await d.json()).catch(()=>null);u!=null&&u.ok&&c.push(...u.channels.map(d=>({id:d.id,name:d.name,team:{id:r.team.id,name:r.team.name,icon:r.team.icon.image_44}})))}return{data:{channels:c}}},postMessage:async t=>{if(!t.channels.length)throw new e.GraphQLError("No channels provided.",{extensions:{code:"NO_CHANNELS_PROVIDED",userFriendlyMessage:"No channels selected. Please select at least one channel."}});const n=await S().catch(()=>null);if(!n)throw new e.GraphQLError("User not authenticated.",{extensions:{code:"NOT_AUTHENTICATED",userFriendlyMessage:"You are not authenticated and will need to connect your Slack account(s) first."}});const c=N(t.message);if(c.length){const a=e.dayjs(c[0].ts).toISOString();return e.pgBoss.send(k,{date:a},{startAfter:e.dayjs().add(10,"seconds").toISOString()}),{data:{ok:!0,messages:[]}}}const l=await I(t.message),r=e.html.parse(t.message);r.querySelectorAll("slack-status").forEach(a=>{var o;if(!a.attributes["data-task-id"])return;const h=(o=e.decodeGlobalId(a.attributes["data-task-id"]))==null?void 0:o.id;if(!h)return;const s=parseInt(h);if(!s)return;const i=l.get(s);i&&a.replaceWith(p[i.status])}),r.querySelectorAll("slack-message").forEach(a=>{a.replaceWith("")}),r.querySelectorAll("li").forEach(a=>{a.querySelectorAll("p").forEach(h=>{h.replaceWith(h.innerHTML)})}),r.querySelectorAll("slack-future-tasks").forEach(a=>{a.parentNode.tagName==="P"&&(a=a.parentNode),a.parentNode.tagName==="LI"&&(a=a.parentNode),a.replaceWith("")});const u=e.html.toSlack(r.toString()),d=[];for(const a of t.channels){const h=n[a.teamId].authed_user.access_token,s=await fetch(`https://slack.com/api/chat.postMessage?channel=${a.channelId}&blocks=${JSON.stringify(u)}`,{headers:{Authorization:`Bearer ${h}`}}).then(async i=>await i.json());if(!s.ok){const i=await fetch(`https://slack.com/api/conversations.info?channel=${a.channelId}`,{headers:{Authorization:`Bearer ${h}`}}).then(async o=>await o.json()).catch(()=>null);throw new e.GraphQLError("Couldn't post message.",{extensions:{code:"COULDNT_POST_MESSAGE",userFriendlyMessage:`Couldn't post message to channel ${i!=null&&i.channel.name?`#${i==null?void 0:i.channel.name}`:"Unknonwn"}. The message may be too complex.`}})}d.push({teamId:a.teamId,channelId:a.channelId,ts:s.ts})}return{data:{ok:!0,messages:d}}}},onUpdateTaskStatusEnd:async t=>{const n=e.dayjs(t.task.date);await e.pgBoss.send(k,{date:n.toISOString()})},onCreateTask:async t=>{const n=e.dayjs(t.task.date);await e.pgBoss.send(k,{date:n.toISOString()})},onAddRoutineStepEnd:async t=>{if(t.step.stepSlug===T){const n=await e.getInstalledPlugins();await e.prisma.template.upsert({where:{slug:`${e.pluginSlug}-${t.step.stepSlug}`},create:{slug:`${e.pluginSlug}-${t.step.stepSlug}`,template:_({withLinear:n.some(c=>c.slug==="linear")}),routineStepId:t.step.id},update:{routineStepId:t.step.id}})}},handlebars:{helpers:{status:function(){return!("status"in this)||!("id"in this)?"":new e.Handlebars.SafeString(`${p[this.status]}`)},"future-tasks":async function(t){if(!t||!("fn"in t))return"";const n=t.hash.filter??{},c=e.html.escape(JSON.stringify(n)),l=await t.fn({});return new e.Handlebars.SafeString(`${l}`)}}},handlePgBossWork:t=>[t(k,async n=>{const c=n.data,l=await S().catch(()=>null);if(!l)return;const r=await e.prisma.note.findFirst({where:{date:c.date}});if(!r)return;const u=await I(r.content),d=N(r.content);if(!d.length)return;const a=e.html.parse(r.content);for(let s of a.querySelectorAll("slack-future-tasks")){const i=s.innerHTML;let o={};try{const g=e.html.unescape(s.getAttribute("filter")??"{}"),w=await e.renderTemplate(g,{});o=JSON.parse(w)}catch{}const m=await e.prisma.task.findMany({where:{date:c.date,id:{notIn:Array.from(u.keys())},...(o==null?void 0:o.where)??{}},include:{tags:!0,pluginDatas:!0,item:{select:{id:!0}},...(o==null?void 0:o.include)??{}},...o}).then(g=>g.map(w=>{const A=e.html.parse(w.title);return A.querySelectorAll("p").forEach(E=>{E.replaceWith(E.innerHTML)}),{...w,title:new e.Handlebars.SafeString(A.toString())}}));let f="";for(const g of m)f+=await e.renderTemplate(i,g);s.parentNode.tagName==="P"&&(s=s.parentNode),s.parentNode.tagName==="LI"&&(s=s.parentNode),s.replaceWith(f)}a.querySelectorAll("slack-status").forEach(s=>{var f;if(!s.attributes["data-task-id"])return;const i=(f=e.decodeGlobalId(s.attributes["data-task-id"]))==null?void 0:f.id;if(!i)return;const o=parseInt(i);if(!o)return;const m=u.get(o);m?s.replaceWith(p[m.status]):s.replaceWith(s.innerHTML)}),a.querySelectorAll("slack-message").forEach(s=>{s.replaceWith("")}),a.querySelectorAll("li").forEach(s=>{s.querySelectorAll("p").forEach(i=>{i.replaceWith(i.innerHTML)})});const h=e.html.toSlack(a.toString());for(const s of d){const i=l[s.teamId].authed_user.access_token,o=await fetch(`https://slack.com/api/chat.update?channel=${s.channelId}&ts=${s.ts}&blocks=${JSON.stringify(h)}`,{headers:{Authorization:`Bearer ${i}`}}).then(async m=>await m.json());if(!o.ok){console.log("❌ Slack message update failed - res.ok is false",o.error);continue}console.log("✅ Slack message update successful")}})]}});module.exports=O;
+`},y="account-tokens",O=b(e=>{const k="update-slack-messages",S=async()=>{const t=await e.store.getPluginItem(y);if(!t)throw new e.GraphQLError("User not authenticated.",{extensions:{code:"NOT_AUTHENTICATED",userFriendlyMessage:"You are not authenticated and will need to connect your Slack account(s) first."}});return t.value},p={TODO:"",DONE:"✅",CANCELED:"❌"},I=async t=>{const n=e.html.parse(t).querySelectorAll("slack-status").map(i=>{var u;if(!i.attributes["data-task-id"])return null;const r=(u=e.decodeGlobalId(i.attributes["data-task-id"]))==null?void 0:u.id;return r?parseInt(r):null}).filter(i=>i!==null);return await e.prisma.task.findMany({where:{id:{in:n}}}).then(i=>new Map(i.map(r=>[r.id,r])))},N=t=>e.html.parse(t).querySelectorAll("slack-message").map(c=>({teamId:c.attributes["data-team-id"],channelId:c.attributes["data-channel-id"],ts:c.attributes["data-ts"]}));return{onRequest:async t=>{if(t.path==="/auth")return Response.redirect(`https://slack-api-flow-dev.vercel.app/api/auth?api_endpoint=${e.serverOrigin}/api/plugin/${e.pluginSlug}/auth/callback`);if(t.path==="/auth/callback"){const n=await e.store.getPluginItem(y),{ok:c,...i}=t.body;if(!c)return console.log("❌ Slack auth callback failed - req.body.ok is false"),new Response("req.body.ok is false",{status:500});const r=await fetch(`https://slack.com/api/team.info?team=${i.team.id}`,{headers:{Authorization:`Bearer ${i.access_token??i.authed_user.access_token}`}}).then(async d=>await d.json()).catch(()=>null);if(!r)return console.log("❌ Slack auth callback failed - teamInfo.ok is false"),new Response("Couldn't get user's workspace info.",{status:500});const u={...i,created_at:new Date().toISOString(),team:{...i.team,...r.team}};return await e.store.setSecretItem(y,{...(n==null?void 0:n.value)??{},[u.team.id]:u}),new Response}return new Response},operations:{workspaces:async()=>{const t=await S().catch(()=>null);return t?{data:{workspaces:Object.entries(t).map(([n,c])=>({connectedAt:c.created_at,teamId:n,teamName:c.team.name,teamIcon:c.team.icon.image_44}))}}:{data:{workspaces:[]}}},getChannels:async t=>{const n=await S().catch(()=>null),c=[];for(const i in n){const r=n[i],u=await fetch("https://slack.com/api/conversations.list",{headers:{Authorization:`Bearer ${r.authed_user.access_token}`}}).then(async d=>await d.json()).catch(()=>null);u!=null&&u.ok&&c.push(...u.channels.map(d=>({id:d.id,name:d.name,team:{id:r.team.id,name:r.team.name,icon:r.team.icon.image_44}})))}return{data:{channels:c}}},postMessage:async t=>{if(!t.channels.length)throw new e.GraphQLError("No channels provided.",{extensions:{code:"NO_CHANNELS_PROVIDED",userFriendlyMessage:"No channels selected. Please select at least one channel."}});const n=await S().catch(()=>null);if(!n)throw new e.GraphQLError("User not authenticated.",{extensions:{code:"NOT_AUTHENTICATED",userFriendlyMessage:"You are not authenticated and will need to connect your Slack account(s) first."}});const c=N(t.message);if(c.length){const a=e.dayjs(c[0].ts).toISOString();return e.pgBoss.send(k,{date:a},{startAfter:e.dayjs().add(10,"seconds").toISOString()}),{data:{ok:!0,messages:[]}}}const i=await I(t.message),r=e.html.parse(t.message);r.querySelectorAll("slack-status").forEach(a=>{var o;if(!a.attributes["data-task-id"])return;const h=(o=e.decodeGlobalId(a.attributes["data-task-id"]))==null?void 0:o.id;if(!h)return;const s=parseInt(h);if(!s)return;const l=i.get(s);l&&a.replaceWith(p[l.status])}),r.querySelectorAll("slack-message").forEach(a=>{a.replaceWith("")}),r.querySelectorAll("li").forEach(a=>{a.querySelectorAll("p").forEach(h=>{h.replaceWith(h.innerHTML)})}),r.querySelectorAll("slack-future-tasks").forEach(a=>{a.parentNode.tagName==="P"&&(a=a.parentNode),a.parentNode.tagName==="LI"&&(a=a.parentNode),a.replaceWith("")});const u=e.html.toSlack(r.toString()),d=[];for(const a of t.channels){const h=n[a.teamId].authed_user.access_token,s=await fetch(`https://slack.com/api/chat.postMessage?channel=${a.channelId}&blocks=${JSON.stringify(u)}`,{headers:{Authorization:`Bearer ${h}`}}).then(async l=>await l.json());if(!s.ok){const l=await fetch(`https://slack.com/api/conversations.info?channel=${a.channelId}`,{headers:{Authorization:`Bearer ${h}`}}).then(async o=>await o.json()).catch(()=>null);throw new e.GraphQLError("Couldn't post message.",{extensions:{code:"COULDNT_POST_MESSAGE",userFriendlyMessage:`Couldn't post message to channel ${l!=null&&l.channel.name?`#${l==null?void 0:l.channel.name}`:"Unknonwn"}. The message may be too complex.`}})}d.push({teamId:a.teamId,channelId:a.channelId,ts:s.ts})}return{data:{ok:!0,messages:d}}}},onUpdateTaskStatusEnd:async t=>{const n=e.dayjs(t.task.date);await e.pgBoss.send(k,{date:n.toISOString()})},onCreateTask:async t=>{const n=e.dayjs(t.task.date);await e.pgBoss.send(k,{date:n.toISOString()})},onAddRoutineStepEnd:async t=>{if(t.step.stepSlug===T){const n=await e.getInstalledPlugins();await e.prisma.template.upsert({where:{slug:`${e.pluginSlug}-${t.step.stepSlug}`},create:{slug:`${e.pluginSlug}-${t.step.stepSlug}`,template:_({withLinear:n.some(c=>c.slug==="linear")}),routineStepId:t.step.id},update:{routineStepId:t.step.id}})}},handlebars:{helpers:{status:function(){return!("status"in this)||!("id"in this)?"":new e.Handlebars.SafeString(`${p[this.status]}`)},"future-tasks":async function(t){if(!t||!("fn"in t))return"";const n=t.hash.filter??{},c=e.html.escape(JSON.stringify(n)),i=await t.fn({});return new e.Handlebars.SafeString(`${i}`)}}},handlePgBossWork:t=>[t(k,async n=>{const c=n.data,i=await S().catch(()=>null);if(!i)return;const r=await e.prisma.note.findFirst({where:{date:c.date}});if(!r)return;const u=await I(r.content),d=N(r.content);if(!d.length)return;const a=e.html.parse(r.content);for(let s of a.querySelectorAll("slack-future-tasks")){const l=s.innerHTML;let o={};try{const g=e.html.unescape(s.getAttribute("filter")??"{}"),w=await e.renderTemplate(g,{});o=JSON.parse(w)}catch{}const m=await e.prisma.task.findMany({...o,where:{date:c.date,id:{notIn:Array.from(u.keys())},...(o==null?void 0:o.where)??{}},include:{tags:!0,pluginDatas:!0,item:{select:{id:!0}},...(o==null?void 0:o.include)??{}}}).then(g=>g.map(w=>{const A=e.html.parse(w.title);return A.querySelectorAll("p").forEach(E=>{E.replaceWith(E.innerHTML)}),{...w,title:new e.Handlebars.SafeString(A.toString())}}));let f="";for(const g of m)f+=await e.renderTemplate(l,g);s.parentNode.tagName==="P"&&(s=s.parentNode),s.parentNode.tagName==="LI"&&(s=s.parentNode),s.replaceWith(f)}a.querySelectorAll("slack-status").forEach(s=>{var f;if(!s.attributes["data-task-id"])return;const l=(f=e.decodeGlobalId(s.attributes["data-task-id"]))==null?void 0:f.id;if(!l)return;const o=parseInt(l);if(!o)return;const m=u.get(o);m?s.replaceWith(p[m.status]):s.replaceWith(s.innerHTML)}),a.querySelectorAll("slack-message").forEach(s=>{s.replaceWith("")}),a.querySelectorAll("li").forEach(s=>{s.querySelectorAll("p").forEach(l=>{l.replaceWith(l.innerHTML)})});const h=e.html.toSlack(a.toString());for(const s of d){const l=i[s.teamId].authed_user.access_token,o=await fetch(`https://slack.com/api/chat.update?channel=${s.channelId}&ts=${s.ts}&blocks=${JSON.stringify(h)}`,{headers:{Authorization:`Bearer ${l}`}}).then(async m=>await m.json());if(!o.ok){console.log("❌ Slack message update failed - res.ok is false",o.error);continue}console.log("✅ Slack message update successful")}})]}});module.exports=O;
diff --git a/plugins/slack/out/web.js b/plugins/slack/out/web.js
index 02b7282..f217d8f 100644
--- a/plugins/slack/out/web.js
+++ b/plugins/slack/out/web.js
@@ -130,13 +130,13 @@ const ge = (e) => ({ plugin: e }), ee = "post-to-slack", ve = (e) => {
return `Plan for today
{{#tasks}}
- - {{slack-status}} {{title}}${t}
+ - {{slack-status}} {{title-without-tags}}${t}
{{else}}
- No tasks
{{/tasks}}
{{! Do not remove the extra curly braces around the slack-future-tasks block.}}
{{{{slack-future-tasks}}}}
- - {{slack-status}} {{title}}${t}
+ - {{slack-status}} {{title-without-tags}}${t}
{{{{/slack-future-tasks}}}}
`;
};