@coji/journal-mcp
Version:
MCP server for journal entries with web viewer
2 lines (1 loc) • 1.81 kB
JavaScript
import{w as n}from"./with-props-C5f5Zz1S.js";import{o as e,t as r}from"./chunk-DQRVZFIR-BjeRaiJT.js";function l({tags:t}){return t.length===0?e.jsxs("div",{className:"bg-white rounded-lg shadow-sm border border-gray-200 p-6",children:[e.jsx("h2",{className:"text-lg font-semibold text-gray-900 mb-4",children:"Tags"}),e.jsx("p",{className:"text-gray-500",children:"No tags found in journal entries."})]}):e.jsxs("div",{className:"bg-white rounded-lg shadow-sm border border-gray-200 p-6",children:[e.jsxs("h2",{className:"text-lg font-semibold text-gray-900 mb-4",children:["Tags (",t.length,")"]}),e.jsx("div",{className:"flex flex-wrap gap-2",children:t.map(({tag:s,count:a})=>e.jsxs(r,{to:`/search?tags=${encodeURIComponent(s)}`,className:"inline-flex items-center gap-2 px-3 py-2 bg-blue-50 text-blue-700 rounded-full hover:bg-blue-100 transition-colors",children:[e.jsxs("span",{children:["#",s]}),e.jsx("span",{className:"text-xs bg-blue-200 text-blue-800 px-2 py-0.5 rounded-full",children:a})]},s))})]})}function c({}){return[{title:"Journal - Tags"},{name:"description",content:"Browse journal entries by tags"}]}const d=n(function({loaderData:s}){const{tags:a}=s;return e.jsxs("div",{className:"space-y-8",children:[e.jsxs("div",{children:[e.jsx("h1",{className:"text-3xl font-bold text-gray-900 mb-2",children:"Tags"}),e.jsx("p",{className:"text-gray-600",children:"Browse and search journal entries by tags."})]}),e.jsx(l,{tags:a}),a.length>0&&e.jsxs("div",{className:"bg-blue-50 rounded-lg p-4",children:[e.jsx("h3",{className:"font-medium text-blue-900 mb-2",children:"💡 Tip"}),e.jsx("p",{className:"text-blue-800 text-sm",children:"Click on any tag to search for entries containing that tag. You can also combine multiple tags in the search page."})]})]})});export{d as default,c as meta};