{"_id":"@crafter/mermaid-themes","_rev":"8-457c6866aba211ef0756019fbe5cf064","name":"@crafter/mermaid-themes","dist-tags":{"latest":"0.0.4"},"versions":{"0.0.1":{"name":"@crafter/mermaid-themes","version":"0.0.1","_id":"@crafter/mermaid-themes@0.0.1","maintainers":[{"name":"raillyhugo_","email":"railly_2009@hotmail.com"}],"dist":{"shasum":"2b135eafadf8637ea00389c80df6bf91bc01b050","tarball":"https://registry.npmjs.org/@crafter/mermaid-themes/-/mermaid-themes-0.0.1.tgz","fileCount":5,"integrity":"sha512-NF1aIZeU6Z2v1eOuHAiKOOx3waaaxVEsrgfNfXdn6LOud1P75B2VkBZR7BULrIunMNHNi0zAUxnrDx2u87ThAw==","signatures":[{"sig":"MEQCIGqhS9LrNMEIHHrrDq7/SRXV5HJP2tRnS/AUAgvfGRSsAiBkks67r7ZmADboHUUvFvjqTPvPc3ZsTqMN9UsPLS3rCg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":27117},"main":"./src/index.ts","type":"module","types":"./src/index.ts","exports":{".":{"bun":"./src/index.ts","types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"67933593e38dc834b0611f683ca1da6b6e08fa53","scripts":{"test":"bun test src/","build":"tsup"},"_npmUser":{"name":"raillyhugo_","email":"railly_2009@hotmail.com"},"_npmVersion":"10.9.2","description":"Zero-dependency theme system for Mermaid diagrams.","directories":{},"_nodeVersion":"22.14.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/mermaid-themes_0.0.1_1770395706839_0.14714023127458242","host":"s3://npm-registry-packages-npm-production"}},"0.0.2":{"name":"@crafter/mermaid-themes","version":"0.0.2","_id":"@crafter/mermaid-themes@0.0.2","maintainers":[{"name":"raillyhugo_","email":"railly_2009@hotmail.com"},{"name":"jibaru","email":"ignacioruedaboada@gmail.com"},{"name":"cris-fast","email":"cristian.correa.cs@gmail.com"}],"dist":{"shasum":"90d7911bf4319ef51ffba59babbc2620371baa63","tarball":"https://registry.npmjs.org/@crafter/mermaid-themes/-/mermaid-themes-0.0.2.tgz","fileCount":5,"integrity":"sha512-uI0wW3dbn7C70I+f1kWoOcT6RPhzfERH04ixhQhc8CtayqdM/0u3jm3CTj5QzpshuCnCJNTuiHnyNcJWvHsNbQ==","signatures":[{"sig":"MEYCIQDF3SC6GhZqAXfzF1Q056cz1UMSJ6jeHhvLKv0JlSF8TgIhANv9hE90mqWln77ChhS2bkH8vu+nrKyaG9a3GrMK8ojH","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":27117},"main":"./src/index.ts","type":"module","types":"./src/index.ts","exports":{".":{"bun":"./src/index.ts","types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"03381fd83ed25b249862d4b4d5a8b005dde621ab","scripts":{"test":"bun test src/","build":"tsup"},"_npmUser":{"name":"raillyhugo_","email":"railly_2009@hotmail.com"},"_npmVersion":"10.9.2","description":"Zero-dependency theme system for Mermaid diagrams.","directories":{},"_nodeVersion":"22.14.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/mermaid-themes_0.0.2_1773298048954_0.8420885012986594","host":"s3://npm-registry-packages-npm-production"}},"0.0.3":{"name":"@crafter/mermaid-themes","version":"0.0.3","_id":"@crafter/mermaid-themes@0.0.3","maintainers":[{"name":"raillyhugo_","email":"railly_2009@hotmail.com"},{"name":"jibaru","email":"ignacioruedaboada@gmail.com"},{"name":"cris-fast","email":"cristian.correa.cs@gmail.com"}],"dist":{"shasum":"4496f6bf4d5ed306c5fcb298b7fca1b310075374","tarball":"https://registry.npmjs.org/@crafter/mermaid-themes/-/mermaid-themes-0.0.3.tgz","fileCount":5,"integrity":"sha512-Wt+Pf2J30g7k7FHOgbmz8LLjkzAZyi1HZhQtOm4PBA/M5cX0iLD1pLMniT307RHCa1ANAcCDiFQA30BcW09Xeg==","signatures":[{"sig":"MEQCIF4bt0b2Fv9gMf9nj7tW4KklOgUS4d+y+xOTCUZ/Dp/MAiAJye02JsVyv9jvEErwp9NPBb9D1ST11B0kaNHvkLrWaA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":27117},"main":"./src/index.ts","type":"module","types":"./src/index.ts","exports":{".":{"bun":"./src/index.ts","types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"03381fd83ed25b249862d4b4d5a8b005dde621ab","scripts":{"test":"bun test src/","build":"tsup"},"_npmUser":{"name":"raillyhugo_","email":"railly_2009@hotmail.com"},"_npmVersion":"10.9.2","description":"Zero-dependency theme system for Mermaid diagrams.","directories":{},"_nodeVersion":"22.14.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/mermaid-themes_0.0.3_1773298207651_0.7932524304400115","host":"s3://npm-registry-packages-npm-production"}},"0.0.4":{"name":"@crafter/mermaid-themes","version":"0.0.4","_id":"@crafter/mermaid-themes@0.0.4","maintainers":[{"name":"raillyhugo_","email":"railly_2009@hotmail.com"},{"name":"jibaru","email":"ignacioruedaboada@gmail.com"},{"name":"cris-fast","email":"cristian.correa.cs@gmail.com"}],"homepage":"https://github.com/crafter-station/mermaid#readme","bugs":{"url":"https://github.com/crafter-station/mermaid/issues"},"dist":{"shasum":"e6a3076578a88bdf465c726846b2896f7e4e86e6","tarball":"https://registry.npmjs.org/@crafter/mermaid-themes/-/mermaid-themes-0.0.4.tgz","fileCount":5,"integrity":"sha512-6qUej0VU6a47LKsixToACUSJwPuGkuDHkOD94tEnFxEpA15LhIx6NakGiIkm5WGVkAcUJZxox8q3rEN7XWWiNw==","signatures":[{"sig":"MEQCIHZwcG/fFtjT9c3aRI2oZ9NNMcw+0GY4fSpGCbtdFek9AiBrCgs3QvyOX6hnAoAl9rEduEZ0dNQE8cQv/UHXGNCy7Q==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@crafter%2fmermaid-themes@0.0.4","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":27534},"main":"./src/index.ts","type":"module","types":"./src/index.ts","exports":{".":{"bun":"./src/index.ts","types":"./dist/index.d.ts","import":"./dist/index.js"}},"gitHead":"a5b105412a714d3fe3681114d867f16c6603e9d5","scripts":{"test":"bun test src/","build":"tsup","typecheck":"tsc --noEmit"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:a79ff4e9-9c9d-4009-9a1b-17b09f9ca343"}},"repository":{"url":"git+https://github.com/crafter-station/mermaid.git","type":"git","directory":"packages/themes"},"_npmVersion":"12.0.1","description":"Zero-dependency theme system for Mermaid diagrams.","directories":{},"_nodeVersion":"24.18.0","_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/mermaid-themes_0.0.4_1784827769100_0.8022870592098361","host":"s3://npm-registry-packages-npm-production"}}},"time":{"created":"2026-02-06T16:35:06.725Z","modified":"2026-09-06T05:34:08.275Z","0.0.1":"2026-02-06T16:35:06.993Z","0.0.2":"2026-03-12T06:47:29.106Z","0.0.3":"2026-03-12T06:50:07.836Z","0.0.4":"2026-07-23T17:29:29.234Z"},"bugs":{"url":"https://github.com/crafter-station/mermaid/issues"},"homepage":"https://github.com/crafter-station/mermaid#readme","repository":{"url":"git+https://github.com/crafter-station/mermaid.git","type":"git","directory":"packages/themes"},"description":"Zero-dependency theme system for Mermaid diagrams.","maintainers":[{"email":"railly_2009@hotmail.com","name":"raillyhugo_"},{"email":"ignacioruedaboada@gmail.com","name":"jibaru"},{"email":"cristian.correa.cs@gmail.com","name":"cris-fast"},{"email":"shiara.arauzo@gmail.com","name":"shiaraarauzo"},{"email":"hi@cueva.io","name":"cuevaio"}],"readme":"# @crafter/mermaid-themes\n\nZero-dependency theme system for Mermaid diagrams.\n\n## Features\n\n- 30+ built-in themes\n- CSS custom properties with color-mix fallbacks\n- Shiki theme extraction\n- Computed color resolution\n\n## Usage\n\n```typescript\nimport { THEMES, generateCssVars, resolveColors } from \"@crafter/mermaid-themes\";\n\nconst theme = THEMES[\"tokyo-night\"];\n\nconst cssVars = generateCssVars(theme);\n\nconst inlineStyle = generateInlineStyle(theme);\n\nconst colors = resolveColors(theme);\n```\n\n## API\n\n### Types\n\n- `DiagramColors` - Basic color properties (bg, fg, line, accent, etc.)\n- `DiagramTheme` - Extended theme with fonts and per-element colors\n- `ResolvedColors` - Computed colors with all fallbacks resolved\n\n### Functions\n\n- `generateCssVars(theme)` - Generate CSS custom properties for `<style>` blocks\n- `generateInlineStyle(theme)` - Generate inline style attribute value\n- `resolveColors(theme)` - Compute all colors to hex values\n- `fromShikiTheme(shikiTheme)` - Extract colors from Shiki theme objects\n\n### Presets\n\n- `THEMES` - 30+ built-in themes\n- `DEFAULTS` - Default theme (zinc-light)\n","readmeFilename":"README.md"}