@rubytech/create-maxy-code 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1821) hide show
  1. package/dist/__tests__/account-id-env.test.js +48 -0
  2. package/dist/__tests__/apt-resolve.test.js +179 -0
  3. package/dist/__tests__/brew-install.test.js +141 -0
  4. package/dist/__tests__/brew-resolve.test.js +103 -0
  5. package/dist/__tests__/cdp-port-no-silent-fallback.test.js +53 -0
  6. package/dist/__tests__/launchd-plist.test.js +149 -0
  7. package/dist/__tests__/macos-version.test.js +96 -0
  8. package/dist/__tests__/peer-brand-detect.test.js +103 -0
  9. package/dist/__tests__/platform-detect.test.js +50 -0
  10. package/dist/__tests__/port-canonicalisation.test.js +200 -0
  11. package/dist/__tests__/preflight-port-classifier.test.js +330 -0
  12. package/dist/__tests__/snap-chromium.test.js +115 -0
  13. package/dist/apt-resolve.js +73 -0
  14. package/dist/brew-install.js +175 -0
  15. package/dist/brew-resolve.js +68 -0
  16. package/dist/index.js +3325 -0
  17. package/dist/launchd-plist.js +68 -0
  18. package/dist/macos-version.js +53 -0
  19. package/dist/peer-brand-detect.js +39 -0
  20. package/dist/pinned-binaries.js +12 -0
  21. package/dist/platform-detect.js +36 -0
  22. package/dist/port-resolution.js +153 -0
  23. package/dist/preflight-port-classifier.js +222 -0
  24. package/dist/snap-chromium.js +89 -0
  25. package/dist/uninstall.js +861 -0
  26. package/package.json +32 -0
  27. package/payload/platform/config/brand-registry.json +20 -0
  28. package/payload/platform/config/brand.json +54 -0
  29. package/payload/platform/lib/account-enumeration/dist/__tests__/enumerate.test.d.ts +2 -0
  30. package/payload/platform/lib/account-enumeration/dist/__tests__/enumerate.test.d.ts.map +1 -0
  31. package/payload/platform/lib/account-enumeration/dist/__tests__/enumerate.test.js +88 -0
  32. package/payload/platform/lib/account-enumeration/dist/__tests__/enumerate.test.js.map +1 -0
  33. package/payload/platform/lib/account-enumeration/dist/__tests__/validate-env.test.d.ts +2 -0
  34. package/payload/platform/lib/account-enumeration/dist/__tests__/validate-env.test.d.ts.map +1 -0
  35. package/payload/platform/lib/account-enumeration/dist/__tests__/validate-env.test.js +55 -0
  36. package/payload/platform/lib/account-enumeration/dist/__tests__/validate-env.test.js.map +1 -0
  37. package/payload/platform/lib/account-enumeration/dist/index.d.ts +49 -0
  38. package/payload/platform/lib/account-enumeration/dist/index.d.ts.map +1 -0
  39. package/payload/platform/lib/account-enumeration/dist/index.js +109 -0
  40. package/payload/platform/lib/account-enumeration/dist/index.js.map +1 -0
  41. package/payload/platform/lib/account-enumeration/src/__tests__/enumerate.test.ts +94 -0
  42. package/payload/platform/lib/account-enumeration/src/__tests__/validate-env.test.ts +57 -0
  43. package/payload/platform/lib/account-enumeration/src/index.ts +140 -0
  44. package/payload/platform/lib/account-enumeration/tsconfig.json +8 -0
  45. package/payload/platform/lib/admins-write/dist/index.d.ts +87 -0
  46. package/payload/platform/lib/admins-write/dist/index.d.ts.map +1 -0
  47. package/payload/platform/lib/admins-write/dist/index.js +248 -0
  48. package/payload/platform/lib/admins-write/dist/index.js.map +1 -0
  49. package/payload/platform/lib/admins-write/src/index.ts +311 -0
  50. package/payload/platform/lib/admins-write/tsconfig.json +8 -0
  51. package/payload/platform/lib/anthropic-key/dist/index.d.ts +22 -0
  52. package/payload/platform/lib/anthropic-key/dist/index.d.ts.map +1 -0
  53. package/payload/platform/lib/anthropic-key/dist/index.js +232 -0
  54. package/payload/platform/lib/anthropic-key/dist/index.js.map +1 -0
  55. package/payload/platform/lib/brand-templating/dist/index.d.ts +18 -0
  56. package/payload/platform/lib/brand-templating/dist/index.d.ts.map +1 -0
  57. package/payload/platform/lib/brand-templating/dist/index.js +69 -0
  58. package/payload/platform/lib/brand-templating/dist/index.js.map +1 -0
  59. package/payload/platform/lib/brand-templating/src/index.ts +76 -0
  60. package/payload/platform/lib/brand-templating/tsconfig.json +8 -0
  61. package/payload/platform/lib/device-url/dist/index.d.ts +44 -0
  62. package/payload/platform/lib/device-url/dist/index.d.ts.map +1 -0
  63. package/payload/platform/lib/device-url/dist/index.js +68 -0
  64. package/payload/platform/lib/device-url/dist/index.js.map +1 -0
  65. package/payload/platform/lib/device-url/src/index.ts +78 -0
  66. package/payload/platform/lib/device-url/tsconfig.json +8 -0
  67. package/payload/platform/lib/entitlement/PUBKEY-HASH.txt +1 -0
  68. package/payload/platform/lib/entitlement/dist/canonicalize.d.ts +26 -0
  69. package/payload/platform/lib/entitlement/dist/canonicalize.d.ts.map +1 -0
  70. package/payload/platform/lib/entitlement/dist/canonicalize.js +54 -0
  71. package/payload/platform/lib/entitlement/dist/canonicalize.js.map +1 -0
  72. package/payload/platform/lib/entitlement/dist/index.d.ts +76 -0
  73. package/payload/platform/lib/entitlement/dist/index.d.ts.map +1 -0
  74. package/payload/platform/lib/entitlement/dist/index.js +293 -0
  75. package/payload/platform/lib/entitlement/dist/index.js.map +1 -0
  76. package/payload/platform/lib/entitlement/rubytech-pubkey.pem +3 -0
  77. package/payload/platform/lib/graph-mcp/dist/__tests__/cypher-validate-write.test.d.ts +2 -0
  78. package/payload/platform/lib/graph-mcp/dist/__tests__/cypher-validate-write.test.d.ts.map +1 -0
  79. package/payload/platform/lib/graph-mcp/dist/__tests__/cypher-validate-write.test.js +97 -0
  80. package/payload/platform/lib/graph-mcp/dist/__tests__/cypher-validate-write.test.js.map +1 -0
  81. package/payload/platform/lib/graph-mcp/dist/__tests__/cypher-validate.test.d.ts +2 -0
  82. package/payload/platform/lib/graph-mcp/dist/__tests__/cypher-validate.test.d.ts.map +1 -0
  83. package/payload/platform/lib/graph-mcp/dist/__tests__/cypher-validate.test.js +112 -0
  84. package/payload/platform/lib/graph-mcp/dist/__tests__/cypher-validate.test.js.map +1 -0
  85. package/payload/platform/lib/graph-mcp/dist/__tests__/schema-cache.test.d.ts +2 -0
  86. package/payload/platform/lib/graph-mcp/dist/__tests__/schema-cache.test.d.ts.map +1 -0
  87. package/payload/platform/lib/graph-mcp/dist/__tests__/schema-cache.test.js +163 -0
  88. package/payload/platform/lib/graph-mcp/dist/__tests__/schema-cache.test.js.map +1 -0
  89. package/payload/platform/lib/graph-mcp/dist/__tests__/schema-cypher-parser.test.d.ts +2 -0
  90. package/payload/platform/lib/graph-mcp/dist/__tests__/schema-cypher-parser.test.d.ts.map +1 -0
  91. package/payload/platform/lib/graph-mcp/dist/__tests__/schema-cypher-parser.test.js +89 -0
  92. package/payload/platform/lib/graph-mcp/dist/__tests__/schema-cypher-parser.test.js.map +1 -0
  93. package/payload/platform/lib/graph-mcp/dist/__tests__/warnings-envelope.test.d.ts +2 -0
  94. package/payload/platform/lib/graph-mcp/dist/__tests__/warnings-envelope.test.d.ts.map +1 -0
  95. package/payload/platform/lib/graph-mcp/dist/__tests__/warnings-envelope.test.js +140 -0
  96. package/payload/platform/lib/graph-mcp/dist/__tests__/warnings-envelope.test.js.map +1 -0
  97. package/payload/platform/lib/graph-mcp/dist/cypher-rewrite-stamp.d.ts +37 -0
  98. package/payload/platform/lib/graph-mcp/dist/cypher-rewrite-stamp.d.ts.map +1 -0
  99. package/payload/platform/lib/graph-mcp/dist/cypher-rewrite-stamp.js +333 -0
  100. package/payload/platform/lib/graph-mcp/dist/cypher-rewrite-stamp.js.map +1 -0
  101. package/payload/platform/lib/graph-mcp/dist/cypher-shim-read.d.ts +85 -0
  102. package/payload/platform/lib/graph-mcp/dist/cypher-shim-read.d.ts.map +1 -0
  103. package/payload/platform/lib/graph-mcp/dist/cypher-shim-read.js +93 -0
  104. package/payload/platform/lib/graph-mcp/dist/cypher-shim-read.js.map +1 -0
  105. package/payload/platform/lib/graph-mcp/dist/cypher-shim-write.d.ts +71 -0
  106. package/payload/platform/lib/graph-mcp/dist/cypher-shim-write.d.ts.map +1 -0
  107. package/payload/platform/lib/graph-mcp/dist/cypher-shim-write.js +168 -0
  108. package/payload/platform/lib/graph-mcp/dist/cypher-shim-write.js.map +1 -0
  109. package/payload/platform/lib/graph-mcp/dist/cypher-validate.d.ts +50 -0
  110. package/payload/platform/lib/graph-mcp/dist/cypher-validate.d.ts.map +1 -0
  111. package/payload/platform/lib/graph-mcp/dist/cypher-validate.js +197 -0
  112. package/payload/platform/lib/graph-mcp/dist/cypher-validate.js.map +1 -0
  113. package/payload/platform/lib/graph-mcp/dist/index.d.ts +26 -0
  114. package/payload/platform/lib/graph-mcp/dist/index.d.ts.map +1 -0
  115. package/payload/platform/lib/graph-mcp/dist/index.js +847 -0
  116. package/payload/platform/lib/graph-mcp/dist/index.js.map +1 -0
  117. package/payload/platform/lib/graph-mcp/dist/schema-cache.d.ts +75 -0
  118. package/payload/platform/lib/graph-mcp/dist/schema-cache.d.ts.map +1 -0
  119. package/payload/platform/lib/graph-mcp/dist/schema-cache.js +217 -0
  120. package/payload/platform/lib/graph-mcp/dist/schema-cache.js.map +1 -0
  121. package/payload/platform/lib/graph-mcp/dist/schema-cypher-parser.d.ts +42 -0
  122. package/payload/platform/lib/graph-mcp/dist/schema-cypher-parser.d.ts.map +1 -0
  123. package/payload/platform/lib/graph-mcp/dist/schema-cypher-parser.js +87 -0
  124. package/payload/platform/lib/graph-mcp/dist/schema-cypher-parser.js.map +1 -0
  125. package/payload/platform/lib/graph-mcp/src/__tests__/cypher-validate-write.test.ts +150 -0
  126. package/payload/platform/lib/graph-mcp/src/__tests__/cypher-validate.test.ts +141 -0
  127. package/payload/platform/lib/graph-mcp/src/__tests__/schema-cache.test.ts +169 -0
  128. package/payload/platform/lib/graph-mcp/src/__tests__/schema-cypher-parser.test.ts +99 -0
  129. package/payload/platform/lib/graph-mcp/src/__tests__/warnings-envelope.test.ts +151 -0
  130. package/payload/platform/lib/graph-mcp/src/cypher-rewrite-stamp.ts +349 -0
  131. package/payload/platform/lib/graph-mcp/src/cypher-shim-read.ts +141 -0
  132. package/payload/platform/lib/graph-mcp/src/cypher-shim-write.ts +240 -0
  133. package/payload/platform/lib/graph-mcp/src/cypher-validate.ts +249 -0
  134. package/payload/platform/lib/graph-mcp/src/index.ts +1076 -0
  135. package/payload/platform/lib/graph-mcp/src/schema-cache.ts +242 -0
  136. package/payload/platform/lib/graph-mcp/src/schema-cypher-parser.ts +84 -0
  137. package/payload/platform/lib/graph-mcp/tsconfig.json +8 -0
  138. package/payload/platform/lib/graph-search/dist/index.d.ts +227 -0
  139. package/payload/platform/lib/graph-search/dist/index.d.ts.map +1 -0
  140. package/payload/platform/lib/graph-search/dist/index.js +525 -0
  141. package/payload/platform/lib/graph-search/dist/index.js.map +1 -0
  142. package/payload/platform/lib/graph-search/src/__tests__/bm25-label-gate.test.ts +88 -0
  143. package/payload/platform/lib/graph-search/src/__tests__/bm25-only.test.ts +129 -0
  144. package/payload/platform/lib/graph-search/src/__tests__/bm25-strong-bypass-threshold.test.ts +126 -0
  145. package/payload/platform/lib/graph-search/src/__tests__/brochure-threshold.test.ts +136 -0
  146. package/payload/platform/lib/graph-search/src/__tests__/escape-and-normalise.test.ts +53 -0
  147. package/payload/platform/lib/graph-search/src/__tests__/expand-batch.test.ts +206 -0
  148. package/payload/platform/lib/graph-search/src/__tests__/fulltext-coverage.test.ts +280 -0
  149. package/payload/platform/lib/graph-search/src/__tests__/hybrid.test.ts +262 -0
  150. package/payload/platform/lib/graph-search/src/__tests__/vector-threshold.test.ts +170 -0
  151. package/payload/platform/lib/graph-search/src/index.ts +718 -0
  152. package/payload/platform/lib/graph-search/tsconfig.json +9 -0
  153. package/payload/platform/lib/graph-search/vitest.config.ts +9 -0
  154. package/payload/platform/lib/graph-trash/dist/index.d.ts +99 -0
  155. package/payload/platform/lib/graph-trash/dist/index.d.ts.map +1 -0
  156. package/payload/platform/lib/graph-trash/dist/index.js +333 -0
  157. package/payload/platform/lib/graph-trash/dist/index.js.map +1 -0
  158. package/payload/platform/lib/graph-trash/src/index.ts +475 -0
  159. package/payload/platform/lib/graph-trash/tsconfig.json +8 -0
  160. package/payload/platform/lib/graph-write/dist/__tests__/account-id-gate.test.d.ts +2 -0
  161. package/payload/platform/lib/graph-write/dist/__tests__/account-id-gate.test.d.ts.map +1 -0
  162. package/payload/platform/lib/graph-write/dist/__tests__/account-id-gate.test.js +165 -0
  163. package/payload/platform/lib/graph-write/dist/__tests__/account-id-gate.test.js.map +1 -0
  164. package/payload/platform/lib/graph-write/dist/__tests__/action-provenance-gate.test.d.ts +2 -0
  165. package/payload/platform/lib/graph-write/dist/__tests__/action-provenance-gate.test.d.ts.map +1 -0
  166. package/payload/platform/lib/graph-write/dist/__tests__/action-provenance-gate.test.js +226 -0
  167. package/payload/platform/lib/graph-write/dist/__tests__/action-provenance-gate.test.js.map +1 -0
  168. package/payload/platform/lib/graph-write/dist/__tests__/audit.test.d.ts +2 -0
  169. package/payload/platform/lib/graph-write/dist/__tests__/audit.test.d.ts.map +1 -0
  170. package/payload/platform/lib/graph-write/dist/__tests__/audit.test.js +147 -0
  171. package/payload/platform/lib/graph-write/dist/__tests__/audit.test.js.map +1 -0
  172. package/payload/platform/lib/graph-write/dist/audit.d.ts +84 -0
  173. package/payload/platform/lib/graph-write/dist/audit.d.ts.map +1 -0
  174. package/payload/platform/lib/graph-write/dist/audit.js +129 -0
  175. package/payload/platform/lib/graph-write/dist/audit.js.map +1 -0
  176. package/payload/platform/lib/graph-write/dist/conversation-provenance.d.ts +26 -0
  177. package/payload/platform/lib/graph-write/dist/conversation-provenance.d.ts.map +1 -0
  178. package/payload/platform/lib/graph-write/dist/conversation-provenance.js +81 -0
  179. package/payload/platform/lib/graph-write/dist/conversation-provenance.js.map +1 -0
  180. package/payload/platform/lib/graph-write/dist/index.d.ts +124 -0
  181. package/payload/platform/lib/graph-write/dist/index.d.ts.map +1 -0
  182. package/payload/platform/lib/graph-write/dist/index.js +288 -0
  183. package/payload/platform/lib/graph-write/dist/index.js.map +1 -0
  184. package/payload/platform/lib/graph-write/src/__tests__/account-id-gate.test.ts +189 -0
  185. package/payload/platform/lib/graph-write/src/__tests__/action-provenance-gate.test.ts +252 -0
  186. package/payload/platform/lib/graph-write/src/__tests__/audit.test.ts +162 -0
  187. package/payload/platform/lib/graph-write/src/audit.ts +182 -0
  188. package/payload/platform/lib/graph-write/src/conversation-provenance.ts +140 -0
  189. package/payload/platform/lib/graph-write/src/index.ts +386 -0
  190. package/payload/platform/lib/graph-write/tsconfig.json +8 -0
  191. package/payload/platform/lib/mcp-eager/dist/index.d.ts +61 -0
  192. package/payload/platform/lib/mcp-eager/dist/index.d.ts.map +1 -0
  193. package/payload/platform/lib/mcp-eager/dist/index.js +49 -0
  194. package/payload/platform/lib/mcp-eager/dist/index.js.map +1 -0
  195. package/payload/platform/lib/mcp-eager/src/index.ts +78 -0
  196. package/payload/platform/lib/mcp-eager/tsconfig.json +8 -0
  197. package/payload/platform/lib/mcp-spawn-tee/dist/index.d.ts +53 -0
  198. package/payload/platform/lib/mcp-spawn-tee/dist/index.d.ts.map +1 -0
  199. package/payload/platform/lib/mcp-spawn-tee/dist/index.js +132 -0
  200. package/payload/platform/lib/mcp-spawn-tee/dist/index.js.map +1 -0
  201. package/payload/platform/lib/mcp-spawn-tee/src/index.ts +134 -0
  202. package/payload/platform/lib/mcp-spawn-tee/tsconfig.json +8 -0
  203. package/payload/platform/lib/mcp-stderr-tee/dist/index.d.ts +51 -0
  204. package/payload/platform/lib/mcp-stderr-tee/dist/index.d.ts.map +1 -0
  205. package/payload/platform/lib/mcp-stderr-tee/dist/index.js +196 -0
  206. package/payload/platform/lib/mcp-stderr-tee/dist/index.js.map +1 -0
  207. package/payload/platform/lib/mcp-stderr-tee/src/index.ts +206 -0
  208. package/payload/platform/lib/mcp-stderr-tee/tsconfig.json +8 -0
  209. package/payload/platform/lib/models/dist/index.d.ts +7 -0
  210. package/payload/platform/lib/models/dist/index.d.ts.map +1 -0
  211. package/payload/platform/lib/models/dist/index.js +20 -0
  212. package/payload/platform/lib/models/dist/index.js.map +1 -0
  213. package/payload/platform/lib/models/src/index.ts +18 -0
  214. package/payload/platform/lib/models/tsconfig.json +8 -0
  215. package/payload/platform/lib/oauth-llm/dist/index.d.ts +118 -0
  216. package/payload/platform/lib/oauth-llm/dist/index.d.ts.map +1 -0
  217. package/payload/platform/lib/oauth-llm/dist/index.js +388 -0
  218. package/payload/platform/lib/oauth-llm/dist/index.js.map +1 -0
  219. package/payload/platform/lib/oauth-llm/src/index.ts +585 -0
  220. package/payload/platform/lib/oauth-llm/tsconfig.json +8 -0
  221. package/payload/platform/lib/persistent-components/dist/index.d.ts +21 -0
  222. package/payload/platform/lib/persistent-components/dist/index.d.ts.map +1 -0
  223. package/payload/platform/lib/persistent-components/dist/index.js +32 -0
  224. package/payload/platform/lib/persistent-components/dist/index.js.map +1 -0
  225. package/payload/platform/lib/persistent-components/src/index.ts +28 -0
  226. package/payload/platform/lib/persistent-components/tsconfig.json +8 -0
  227. package/payload/platform/lib/screening-patterns/dist/index.d.ts +29 -0
  228. package/payload/platform/lib/screening-patterns/dist/index.d.ts.map +1 -0
  229. package/payload/platform/lib/screening-patterns/dist/index.js +48 -0
  230. package/payload/platform/lib/screening-patterns/dist/index.js.map +1 -0
  231. package/payload/platform/lib/screening-patterns/src/index.ts +51 -0
  232. package/payload/platform/lib/screening-patterns/tsconfig.json +8 -0
  233. package/payload/platform/lib/task-secrets/dist/index.d.ts +40 -0
  234. package/payload/platform/lib/task-secrets/dist/index.d.ts.map +1 -0
  235. package/payload/platform/lib/task-secrets/dist/index.js +44 -0
  236. package/payload/platform/lib/task-secrets/dist/index.js.map +1 -0
  237. package/payload/platform/lib/task-secrets/src/__tests__/redact-secrets.test.ts +127 -0
  238. package/payload/platform/lib/task-secrets/src/index.ts +77 -0
  239. package/payload/platform/lib/task-secrets/tsconfig.json +9 -0
  240. package/payload/platform/lib/task-secrets/vitest.config.ts +9 -0
  241. package/payload/platform/neo4j/edge-annotations.json +154 -0
  242. package/payload/platform/neo4j/schema.cypher +1104 -0
  243. package/payload/platform/package-lock.json +3576 -0
  244. package/payload/platform/package.json +25 -0
  245. package/payload/platform/plugins/admin/PLUGIN.md +81 -0
  246. package/payload/platform/plugins/admin/hooks/__tests__/archive-ingest-surface-gate.test.sh +191 -0
  247. package/payload/platform/plugins/admin/hooks/__tests__/playwright-file-guard.test.sh +278 -0
  248. package/payload/platform/plugins/admin/hooks/__tests__/pre-tool-use-base64-guard.test.sh +204 -0
  249. package/payload/platform/plugins/admin/hooks/archive-ingest-surface-gate.sh +225 -0
  250. package/payload/platform/plugins/admin/hooks/playwright-file-guard.sh +214 -0
  251. package/payload/platform/plugins/admin/hooks/pre-tool-use.sh +294 -0
  252. package/payload/platform/plugins/admin/hooks/webfetch-preflight.mjs +363 -0
  253. package/payload/platform/plugins/admin/mcp/dist/__tests__/plugin-read-skill-resolution.test.d.ts +2 -0
  254. package/payload/platform/plugins/admin/mcp/dist/__tests__/plugin-read-skill-resolution.test.d.ts.map +1 -0
  255. package/payload/platform/plugins/admin/mcp/dist/__tests__/plugin-read-skill-resolution.test.js +91 -0
  256. package/payload/platform/plugins/admin/mcp/dist/__tests__/plugin-read-skill-resolution.test.js.map +1 -0
  257. package/payload/platform/plugins/admin/mcp/dist/__tests__/public-hostname.test.d.ts +2 -0
  258. package/payload/platform/plugins/admin/mcp/dist/__tests__/public-hostname.test.d.ts.map +1 -0
  259. package/payload/platform/plugins/admin/mcp/dist/__tests__/public-hostname.test.js +98 -0
  260. package/payload/platform/plugins/admin/mcp/dist/__tests__/public-hostname.test.js.map +1 -0
  261. package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-load-required-inputs.test.d.ts +2 -0
  262. package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-load-required-inputs.test.d.ts.map +1 -0
  263. package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-load-required-inputs.test.js +141 -0
  264. package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-load-required-inputs.test.js.map +1 -0
  265. package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-load.test.d.ts +2 -0
  266. package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-load.test.d.ts.map +1 -0
  267. package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-load.test.js +88 -0
  268. package/payload/platform/plugins/admin/mcp/dist/__tests__/skill-load.test.js.map +1 -0
  269. package/payload/platform/plugins/admin/mcp/dist/index.d.ts +2 -0
  270. package/payload/platform/plugins/admin/mcp/dist/index.d.ts.map +1 -0
  271. package/payload/platform/plugins/admin/mcp/dist/index.js +3495 -0
  272. package/payload/platform/plugins/admin/mcp/dist/index.js.map +1 -0
  273. package/payload/platform/plugins/admin/mcp/dist/lib/neo4j.d.ts +5 -0
  274. package/payload/platform/plugins/admin/mcp/dist/lib/neo4j.d.ts.map +1 -0
  275. package/payload/platform/plugins/admin/mcp/dist/lib/neo4j.js +40 -0
  276. package/payload/platform/plugins/admin/mcp/dist/lib/neo4j.js.map +1 -0
  277. package/payload/platform/plugins/admin/mcp/dist/lib/onboarding.d.ts +39 -0
  278. package/payload/platform/plugins/admin/mcp/dist/lib/onboarding.d.ts.map +1 -0
  279. package/payload/platform/plugins/admin/mcp/dist/lib/onboarding.js +249 -0
  280. package/payload/platform/plugins/admin/mcp/dist/lib/onboarding.js.map +1 -0
  281. package/payload/platform/plugins/admin/mcp/dist/lib/public-hostname.d.ts +15 -0
  282. package/payload/platform/plugins/admin/mcp/dist/lib/public-hostname.d.ts.map +1 -0
  283. package/payload/platform/plugins/admin/mcp/dist/lib/public-hostname.js +73 -0
  284. package/payload/platform/plugins/admin/mcp/dist/lib/public-hostname.js.map +1 -0
  285. package/payload/platform/plugins/admin/mcp/dist/skill-resolution.d.ts +35 -0
  286. package/payload/platform/plugins/admin/mcp/dist/skill-resolution.d.ts.map +1 -0
  287. package/payload/platform/plugins/admin/mcp/dist/skill-resolution.js +140 -0
  288. package/payload/platform/plugins/admin/mcp/dist/skill-resolution.js.map +1 -0
  289. package/payload/platform/plugins/admin/mcp/package.json +23 -0
  290. package/payload/platform/plugins/admin/mcp/vitest.config.ts +9 -0
  291. package/payload/platform/plugins/admin/references/chat-ui-guide.md +31 -0
  292. package/payload/platform/plugins/admin/references/contextual-ui.md +107 -0
  293. package/payload/platform/plugins/admin/skills/a4-print-documents/SKILL.md +241 -0
  294. package/payload/platform/plugins/admin/skills/access-manager/SKILL.md +28 -0
  295. package/payload/platform/plugins/admin/skills/access-manager/references/operations.md +197 -0
  296. package/payload/platform/plugins/admin/skills/business-profile/SKILL.md +53 -0
  297. package/payload/platform/plugins/admin/skills/datetime/SKILL.md +91 -0
  298. package/payload/platform/plugins/admin/skills/deck-pages/SKILL.md +418 -0
  299. package/payload/platform/plugins/admin/skills/onboarding/SKILL.md +255 -0
  300. package/payload/platform/plugins/admin/skills/plainly/SKILL.md +105 -0
  301. package/payload/platform/plugins/admin/skills/plainly/references/worked-examples.md +301 -0
  302. package/payload/platform/plugins/admin/skills/plugin-management/SKILL.md +99 -0
  303. package/payload/platform/plugins/admin/skills/public-agent-manager/SKILL.md +277 -0
  304. package/payload/platform/plugins/admin/skills/publish-site/SKILL.md +72 -0
  305. package/payload/platform/plugins/admin/skills/qr-code/SKILL.md +35 -0
  306. package/payload/platform/plugins/admin/skills/qr-code/references/data-formats.md +113 -0
  307. package/payload/platform/plugins/admin/skills/skill-builder/SKILL.md +113 -0
  308. package/payload/platform/plugins/admin/skills/skill-builder/references/lean-pattern.md +110 -0
  309. package/payload/platform/plugins/admin/skills/skill-builder/references/pdf-generation.md +30 -0
  310. package/payload/platform/plugins/admin/skills/specialist-management/SKILL.md +44 -0
  311. package/payload/platform/plugins/admin/skills/stream-log-review/SKILL.md +71 -0
  312. package/payload/platform/plugins/admin/skills/stream-log-review/references/analysis-patterns.md +189 -0
  313. package/payload/platform/plugins/admin/skills/unzip-attachment/SKILL.md +79 -0
  314. package/payload/platform/plugins/admin/skills/unzip-attachment/__tests__/preflight.sh +148 -0
  315. package/payload/platform/plugins/admin/skills/unzip-attachment/references/safety.md +116 -0
  316. package/payload/platform/plugins/admin/skills/update-knowledge/SKILL.md +47 -0
  317. package/payload/platform/plugins/anthropic/PLUGIN.md +40 -0
  318. package/payload/platform/plugins/anthropic/references/console-api.md +186 -0
  319. package/payload/platform/plugins/anthropic/references/setup-guide.md +36 -0
  320. package/payload/platform/plugins/anthropic/skills/get-api-key/SKILL.md +138 -0
  321. package/payload/platform/plugins/business-assistant/PLUGIN.md +59 -0
  322. package/payload/platform/plugins/business-assistant/references/crm.md +112 -0
  323. package/payload/platform/plugins/business-assistant/references/document-management.md +96 -0
  324. package/payload/platform/plugins/business-assistant/references/escalation.md +126 -0
  325. package/payload/platform/plugins/business-assistant/references/invoicing.md +163 -0
  326. package/payload/platform/plugins/business-assistant/references/profiling.md +50 -0
  327. package/payload/platform/plugins/business-assistant/references/quoting.md +56 -0
  328. package/payload/platform/plugins/business-assistant/references/scheduling.md +127 -0
  329. package/payload/platform/plugins/business-assistant/references/task-management.md +163 -0
  330. package/payload/platform/plugins/cloudflare/PLUGIN.md +73 -0
  331. package/payload/platform/plugins/cloudflare/mcp/dist/index.d.ts +2 -0
  332. package/payload/platform/plugins/cloudflare/mcp/dist/index.d.ts.map +1 -0
  333. package/payload/platform/plugins/cloudflare/mcp/dist/index.js +29 -0
  334. package/payload/platform/plugins/cloudflare/mcp/dist/index.js.map +1 -0
  335. package/payload/platform/plugins/cloudflare/mcp/dist/lib/cloudflared.d.ts +283 -0
  336. package/payload/platform/plugins/cloudflare/mcp/dist/lib/cloudflared.d.ts.map +1 -0
  337. package/payload/platform/plugins/cloudflare/mcp/dist/lib/cloudflared.js +1155 -0
  338. package/payload/platform/plugins/cloudflare/mcp/dist/lib/cloudflared.js.map +1 -0
  339. package/payload/platform/plugins/cloudflare/mcp/dist/lib/setup-orchestrator.d.ts +90 -0
  340. package/payload/platform/plugins/cloudflare/mcp/dist/lib/setup-orchestrator.d.ts.map +1 -0
  341. package/payload/platform/plugins/cloudflare/mcp/dist/lib/setup-orchestrator.js +550 -0
  342. package/payload/platform/plugins/cloudflare/mcp/dist/lib/setup-orchestrator.js.map +1 -0
  343. package/payload/platform/plugins/cloudflare/mcp/package.json +18 -0
  344. package/payload/platform/plugins/cloudflare/mcp/vitest.config.ts +10 -0
  345. package/payload/platform/plugins/cloudflare/references/dashboard-guide.md +108 -0
  346. package/payload/platform/plugins/cloudflare/references/manual-setup.md +481 -0
  347. package/payload/platform/plugins/cloudflare/references/reset-guide.md +118 -0
  348. package/payload/platform/plugins/cloudflare/scripts/_stream-log.sh +154 -0
  349. package/payload/platform/plugins/cloudflare/scripts/list-cf-domains.sh +98 -0
  350. package/payload/platform/plugins/cloudflare/scripts/list-cf-domains.ts +751 -0
  351. package/payload/platform/plugins/cloudflare/scripts/reset-tunnel.sh +107 -0
  352. package/payload/platform/plugins/cloudflare/scripts/setup-tunnel.sh +826 -0
  353. package/payload/platform/plugins/cloudflare/skills/setup-tunnel/SKILL.md +107 -0
  354. package/payload/platform/plugins/contacts/PLUGIN.md +31 -0
  355. package/payload/platform/plugins/contacts/mcp/dist/index.d.ts +2 -0
  356. package/payload/platform/plugins/contacts/mcp/dist/index.d.ts.map +1 -0
  357. package/payload/platform/plugins/contacts/mcp/dist/index.js +433 -0
  358. package/payload/platform/plugins/contacts/mcp/dist/index.js.map +1 -0
  359. package/payload/platform/plugins/contacts/mcp/dist/lib/neo4j.d.ts +5 -0
  360. package/payload/platform/plugins/contacts/mcp/dist/lib/neo4j.d.ts.map +1 -0
  361. package/payload/platform/plugins/contacts/mcp/dist/lib/neo4j.js +40 -0
  362. package/payload/platform/plugins/contacts/mcp/dist/lib/neo4j.js.map +1 -0
  363. package/payload/platform/plugins/contacts/mcp/dist/lib/resolve-person.d.ts +33 -0
  364. package/payload/platform/plugins/contacts/mcp/dist/lib/resolve-person.d.ts.map +1 -0
  365. package/payload/platform/plugins/contacts/mcp/dist/lib/resolve-person.js +53 -0
  366. package/payload/platform/plugins/contacts/mcp/dist/lib/resolve-person.js.map +1 -0
  367. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-create.d.ts +23 -0
  368. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-create.d.ts.map +1 -0
  369. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-create.js +123 -0
  370. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-create.js.map +1 -0
  371. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-delete.d.ts +28 -0
  372. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-delete.d.ts.map +1 -0
  373. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-delete.js +39 -0
  374. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-delete.js.map +1 -0
  375. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-erase.d.ts +41 -0
  376. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-erase.d.ts.map +1 -0
  377. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-erase.js +142 -0
  378. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-erase.js.map +1 -0
  379. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-export.d.ts +52 -0
  380. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-export.d.ts.map +1 -0
  381. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-export.js +119 -0
  382. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-export.js.map +1 -0
  383. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-list.d.ts +23 -0
  384. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-list.d.ts.map +1 -0
  385. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-list.js +49 -0
  386. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-list.js.map +1 -0
  387. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-lookup.d.ts +21 -0
  388. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-lookup.d.ts.map +1 -0
  389. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-lookup.js +70 -0
  390. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-lookup.js.map +1 -0
  391. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-update.d.ts +14 -0
  392. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-update.d.ts.map +1 -0
  393. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-update.js +43 -0
  394. package/payload/platform/plugins/contacts/mcp/dist/tools/contact-update.js.map +1 -0
  395. package/payload/platform/plugins/contacts/mcp/dist/tools/group-create.d.ts +18 -0
  396. package/payload/platform/plugins/contacts/mcp/dist/tools/group-create.d.ts.map +1 -0
  397. package/payload/platform/plugins/contacts/mcp/dist/tools/group-create.js +95 -0
  398. package/payload/platform/plugins/contacts/mcp/dist/tools/group-create.js.map +1 -0
  399. package/payload/platform/plugins/contacts/mcp/dist/tools/group-manage.d.ts +15 -0
  400. package/payload/platform/plugins/contacts/mcp/dist/tools/group-manage.d.ts.map +1 -0
  401. package/payload/platform/plugins/contacts/mcp/dist/tools/group-manage.js +72 -0
  402. package/payload/platform/plugins/contacts/mcp/dist/tools/group-manage.js.map +1 -0
  403. package/payload/platform/plugins/contacts/mcp/package.json +19 -0
  404. package/payload/platform/plugins/deep-research/PLUGIN.md +13 -0
  405. package/payload/platform/plugins/deep-research/skills/deep-research/SKILL.md +46 -0
  406. package/payload/platform/plugins/deep-research/skills/deep-research/references/citation-styles.md +52 -0
  407. package/payload/platform/plugins/deep-research/skills/deep-research/references/research-modes.md +22 -0
  408. package/payload/platform/plugins/deep-research/skills/deep-research/references/search-strategy.md +24 -0
  409. package/payload/platform/plugins/docs/PLUGIN.md +52 -0
  410. package/payload/platform/plugins/docs/references/access-control.md +73 -0
  411. package/payload/platform/plugins/docs/references/admin-session.md +80 -0
  412. package/payload/platform/plugins/docs/references/attachments.md +44 -0
  413. package/payload/platform/plugins/docs/references/cloudflare.md +111 -0
  414. package/payload/platform/plugins/docs/references/contacts-guide.md +102 -0
  415. package/payload/platform/plugins/docs/references/deployment.md +150 -0
  416. package/payload/platform/plugins/docs/references/getting-started.md +82 -0
  417. package/payload/platform/plugins/docs/references/graph.md +149 -0
  418. package/payload/platform/plugins/docs/references/internals.md +512 -0
  419. package/payload/platform/plugins/docs/references/memory-guide.md +119 -0
  420. package/payload/platform/plugins/docs/references/migration-guide.md +90 -0
  421. package/payload/platform/plugins/docs/references/outlook-guide.md +69 -0
  422. package/payload/platform/plugins/docs/references/platform.md +111 -0
  423. package/payload/platform/plugins/docs/references/plugins-guide.md +174 -0
  424. package/payload/platform/plugins/docs/references/projects-guide.md +73 -0
  425. package/payload/platform/plugins/docs/references/settings.md +82 -0
  426. package/payload/platform/plugins/docs/references/telegram-guide.md +58 -0
  427. package/payload/platform/plugins/docs/references/troubleshooting.md +532 -0
  428. package/payload/platform/plugins/email/PLUGIN.md +49 -0
  429. package/payload/platform/plugins/email/mcp/dist/index.d.ts +2 -0
  430. package/payload/platform/plugins/email/mcp/dist/index.d.ts.map +1 -0
  431. package/payload/platform/plugins/email/mcp/dist/index.js +291 -0
  432. package/payload/platform/plugins/email/mcp/dist/index.js.map +1 -0
  433. package/payload/platform/plugins/email/mcp/dist/lib/credentials.d.ts +118 -0
  434. package/payload/platform/plugins/email/mcp/dist/lib/credentials.d.ts.map +1 -0
  435. package/payload/platform/plugins/email/mcp/dist/lib/credentials.js +364 -0
  436. package/payload/platform/plugins/email/mcp/dist/lib/credentials.js.map +1 -0
  437. package/payload/platform/plugins/email/mcp/dist/lib/embedding.d.ts +2 -0
  438. package/payload/platform/plugins/email/mcp/dist/lib/embedding.d.ts.map +1 -0
  439. package/payload/platform/plugins/email/mcp/dist/lib/embedding.js +24 -0
  440. package/payload/platform/plugins/email/mcp/dist/lib/embedding.js.map +1 -0
  441. package/payload/platform/plugins/email/mcp/dist/lib/graph.d.ts +87 -0
  442. package/payload/platform/plugins/email/mcp/dist/lib/graph.d.ts.map +1 -0
  443. package/payload/platform/plugins/email/mcp/dist/lib/graph.js +324 -0
  444. package/payload/platform/plugins/email/mcp/dist/lib/graph.js.map +1 -0
  445. package/payload/platform/plugins/email/mcp/dist/lib/imap.d.ts +215 -0
  446. package/payload/platform/plugins/email/mcp/dist/lib/imap.d.ts.map +1 -0
  447. package/payload/platform/plugins/email/mcp/dist/lib/imap.js +735 -0
  448. package/payload/platform/plugins/email/mcp/dist/lib/imap.js.map +1 -0
  449. package/payload/platform/plugins/email/mcp/dist/lib/neo4j.d.ts +5 -0
  450. package/payload/platform/plugins/email/mcp/dist/lib/neo4j.d.ts.map +1 -0
  451. package/payload/platform/plugins/email/mcp/dist/lib/neo4j.js +40 -0
  452. package/payload/platform/plugins/email/mcp/dist/lib/neo4j.js.map +1 -0
  453. package/payload/platform/plugins/email/mcp/dist/lib/providers.d.ts +32 -0
  454. package/payload/platform/plugins/email/mcp/dist/lib/providers.d.ts.map +1 -0
  455. package/payload/platform/plugins/email/mcp/dist/lib/providers.js +569 -0
  456. package/payload/platform/plugins/email/mcp/dist/lib/providers.js.map +1 -0
  457. package/payload/platform/plugins/email/mcp/dist/lib/screening.d.ts +29 -0
  458. package/payload/platform/plugins/email/mcp/dist/lib/screening.d.ts.map +1 -0
  459. package/payload/platform/plugins/email/mcp/dist/lib/screening.js +105 -0
  460. package/payload/platform/plugins/email/mcp/dist/lib/screening.js.map +1 -0
  461. package/payload/platform/plugins/email/mcp/dist/lib/smtp.d.ts +21 -0
  462. package/payload/platform/plugins/email/mcp/dist/lib/smtp.d.ts.map +1 -0
  463. package/payload/platform/plugins/email/mcp/dist/lib/smtp.js +77 -0
  464. package/payload/platform/plugins/email/mcp/dist/lib/smtp.js.map +1 -0
  465. package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.d.ts +38 -0
  466. package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.d.ts.map +1 -0
  467. package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.js +894 -0
  468. package/payload/platform/plugins/email/mcp/dist/scripts/email-auto-respond.js.map +1 -0
  469. package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.d.ts +25 -0
  470. package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.d.ts.map +1 -0
  471. package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.js +227 -0
  472. package/payload/platform/plugins/email/mcp/dist/scripts/email-fetch.js.map +1 -0
  473. package/payload/platform/plugins/email/mcp/dist/tools/email-auto-respond-config.d.ts +19 -0
  474. package/payload/platform/plugins/email/mcp/dist/tools/email-auto-respond-config.d.ts.map +1 -0
  475. package/payload/platform/plugins/email/mcp/dist/tools/email-auto-respond-config.js +151 -0
  476. package/payload/platform/plugins/email/mcp/dist/tools/email-auto-respond-config.js.map +1 -0
  477. package/payload/platform/plugins/email/mcp/dist/tools/email-graph-query.d.ts +22 -0
  478. package/payload/platform/plugins/email/mcp/dist/tools/email-graph-query.d.ts.map +1 -0
  479. package/payload/platform/plugins/email/mcp/dist/tools/email-graph-query.js +188 -0
  480. package/payload/platform/plugins/email/mcp/dist/tools/email-graph-query.js.map +1 -0
  481. package/payload/platform/plugins/email/mcp/dist/tools/email-otp-extract.d.ts +15 -0
  482. package/payload/platform/plugins/email/mcp/dist/tools/email-otp-extract.d.ts.map +1 -0
  483. package/payload/platform/plugins/email/mcp/dist/tools/email-otp-extract.js +142 -0
  484. package/payload/platform/plugins/email/mcp/dist/tools/email-otp-extract.js.map +1 -0
  485. package/payload/platform/plugins/email/mcp/dist/tools/email-read.d.ts +14 -0
  486. package/payload/platform/plugins/email/mcp/dist/tools/email-read.d.ts.map +1 -0
  487. package/payload/platform/plugins/email/mcp/dist/tools/email-read.js +75 -0
  488. package/payload/platform/plugins/email/mcp/dist/tools/email-read.js.map +1 -0
  489. package/payload/platform/plugins/email/mcp/dist/tools/email-reply.d.ts +10 -0
  490. package/payload/platform/plugins/email/mcp/dist/tools/email-reply.d.ts.map +1 -0
  491. package/payload/platform/plugins/email/mcp/dist/tools/email-reply.js +83 -0
  492. package/payload/platform/plugins/email/mcp/dist/tools/email-reply.js.map +1 -0
  493. package/payload/platform/plugins/email/mcp/dist/tools/email-search.d.ts +15 -0
  494. package/payload/platform/plugins/email/mcp/dist/tools/email-search.d.ts.map +1 -0
  495. package/payload/platform/plugins/email/mcp/dist/tools/email-search.js +63 -0
  496. package/payload/platform/plugins/email/mcp/dist/tools/email-search.js.map +1 -0
  497. package/payload/platform/plugins/email/mcp/dist/tools/email-send.d.ts +10 -0
  498. package/payload/platform/plugins/email/mcp/dist/tools/email-send.d.ts.map +1 -0
  499. package/payload/platform/plugins/email/mcp/dist/tools/email-send.js +31 -0
  500. package/payload/platform/plugins/email/mcp/dist/tools/email-send.js.map +1 -0
  501. package/payload/platform/plugins/email/mcp/dist/tools/email-setup.d.ts +22 -0
  502. package/payload/platform/plugins/email/mcp/dist/tools/email-setup.d.ts.map +1 -0
  503. package/payload/platform/plugins/email/mcp/dist/tools/email-setup.js +183 -0
  504. package/payload/platform/plugins/email/mcp/dist/tools/email-setup.js.map +1 -0
  505. package/payload/platform/plugins/email/mcp/dist/tools/email-status.d.ts +6 -0
  506. package/payload/platform/plugins/email/mcp/dist/tools/email-status.d.ts.map +1 -0
  507. package/payload/platform/plugins/email/mcp/dist/tools/email-status.js +43 -0
  508. package/payload/platform/plugins/email/mcp/dist/tools/email-status.js.map +1 -0
  509. package/payload/platform/plugins/email/mcp/package.json +23 -0
  510. package/payload/platform/plugins/email/references/email-reference.md +204 -0
  511. package/payload/platform/plugins/linkedin-import/PLUGIN.md +27 -0
  512. package/payload/platform/plugins/linkedin-import/skills/linkedin-import/SKILL.md +142 -0
  513. package/payload/platform/plugins/linkedin-import/skills/linkedin-import/references/connections.md +135 -0
  514. package/payload/platform/plugins/linkedin-import/skills/linkedin-import/references/profile.md +95 -0
  515. package/payload/platform/plugins/memory/PLUGIN.md +146 -0
  516. package/payload/platform/plugins/memory/bin/conversation-archive-ingest.mjs +879 -0
  517. package/payload/platform/plugins/memory/bin/conversation-archive-ingest.sh +138 -0
  518. package/payload/platform/plugins/memory/mcp/dist/index.d.ts +2 -0
  519. package/payload/platform/plugins/memory/mcp/dist/index.d.ts.map +1 -0
  520. package/payload/platform/plugins/memory/mcp/dist/index.js +1813 -0
  521. package/payload/platform/plugins/memory/mcp/dist/index.js.map +1 -0
  522. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/live-schema-source.test.d.ts +2 -0
  523. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/live-schema-source.test.d.ts.map +1 -0
  524. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/live-schema-source.test.js +92 -0
  525. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/live-schema-source.test.js.map +1 -0
  526. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/llm-classifier.test.d.ts +2 -0
  527. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/llm-classifier.test.d.ts.map +1 -0
  528. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/llm-classifier.test.js +225 -0
  529. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/llm-classifier.test.js.map +1 -0
  530. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/schema-loader.test.d.ts +2 -0
  531. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/schema-loader.test.d.ts.map +1 -0
  532. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/schema-loader.test.js +100 -0
  533. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/schema-loader.test.js.map +1 -0
  534. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/schema-validator.test.d.ts +2 -0
  535. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/schema-validator.test.d.ts.map +1 -0
  536. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/schema-validator.test.js +448 -0
  537. package/payload/platform/plugins/memory/mcp/dist/lib/__tests__/schema-validator.test.js.map +1 -0
  538. package/payload/platform/plugins/memory/mcp/dist/lib/attachments.d.ts +37 -0
  539. package/payload/platform/plugins/memory/mcp/dist/lib/attachments.d.ts.map +1 -0
  540. package/payload/platform/plugins/memory/mcp/dist/lib/attachments.js +69 -0
  541. package/payload/platform/plugins/memory/mcp/dist/lib/attachments.js.map +1 -0
  542. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/index.d.ts +5 -0
  543. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/index.d.ts.map +1 -0
  544. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/index.js +30 -0
  545. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/index.js.map +1 -0
  546. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/timestamp-scanner.d.ts +49 -0
  547. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/timestamp-scanner.d.ts.map +1 -0
  548. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/timestamp-scanner.js +35 -0
  549. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/timestamp-scanner.js.map +1 -0
  550. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/types.d.ts +47 -0
  551. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/types.d.ts.map +1 -0
  552. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/types.js +31 -0
  553. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/types.js.map +1 -0
  554. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/whatsapp-text.d.ts +3 -0
  555. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/whatsapp-text.d.ts.map +1 -0
  556. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/whatsapp-text.js +155 -0
  557. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-normalisers/whatsapp-text.js.map +1 -0
  558. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/delta-cursor.d.ts +11 -0
  559. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/delta-cursor.d.ts.map +1 -0
  560. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/delta-cursor.js +20 -0
  561. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/delta-cursor.js.map +1 -0
  562. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/derive-keys.d.ts +14 -0
  563. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/derive-keys.d.ts.map +1 -0
  564. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/derive-keys.js +38 -0
  565. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/derive-keys.js.map +1 -0
  566. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/sender-bind.d.ts +16 -0
  567. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/sender-bind.d.ts.map +1 -0
  568. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/sender-bind.js +59 -0
  569. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/sender-bind.js.map +1 -0
  570. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/sessionize.d.ts +9 -0
  571. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/sessionize.d.ts.map +1 -0
  572. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/sessionize.js +32 -0
  573. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/sessionize.js.map +1 -0
  574. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/to-turn-text.d.ts +3 -0
  575. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/to-turn-text.d.ts.map +1 -0
  576. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/to-turn-text.js +29 -0
  577. package/payload/platform/plugins/memory/mcp/dist/lib/conversation-pipeline/to-turn-text.js.map +1 -0
  578. package/payload/platform/plugins/memory/mcp/dist/lib/document-chunker.d.ts +45 -0
  579. package/payload/platform/plugins/memory/mcp/dist/lib/document-chunker.d.ts.map +1 -0
  580. package/payload/platform/plugins/memory/mcp/dist/lib/document-chunker.js +125 -0
  581. package/payload/platform/plugins/memory/mcp/dist/lib/document-chunker.js.map +1 -0
  582. package/payload/platform/plugins/memory/mcp/dist/lib/document-hierarchy.d.ts +9 -0
  583. package/payload/platform/plugins/memory/mcp/dist/lib/document-hierarchy.d.ts.map +1 -0
  584. package/payload/platform/plugins/memory/mcp/dist/lib/document-hierarchy.js +61 -0
  585. package/payload/platform/plugins/memory/mcp/dist/lib/document-hierarchy.js.map +1 -0
  586. package/payload/platform/plugins/memory/mcp/dist/lib/embeddings.d.ts +3 -0
  587. package/payload/platform/plugins/memory/mcp/dist/lib/embeddings.d.ts.map +1 -0
  588. package/payload/platform/plugins/memory/mcp/dist/lib/embeddings.js +29 -0
  589. package/payload/platform/plugins/memory/mcp/dist/lib/embeddings.js.map +1 -0
  590. package/payload/platform/plugins/memory/mcp/dist/lib/filter-token.d.ts +36 -0
  591. package/payload/platform/plugins/memory/mcp/dist/lib/filter-token.d.ts.map +1 -0
  592. package/payload/platform/plugins/memory/mcp/dist/lib/filter-token.js +86 -0
  593. package/payload/platform/plugins/memory/mcp/dist/lib/filter-token.js.map +1 -0
  594. package/payload/platform/plugins/memory/mcp/dist/lib/graph-prune.d.ts +42 -0
  595. package/payload/platform/plugins/memory/mcp/dist/lib/graph-prune.d.ts.map +1 -0
  596. package/payload/platform/plugins/memory/mcp/dist/lib/graph-prune.js +114 -0
  597. package/payload/platform/plugins/memory/mcp/dist/lib/graph-prune.js.map +1 -0
  598. package/payload/platform/plugins/memory/mcp/dist/lib/graph-write-gate.d.ts +38 -0
  599. package/payload/platform/plugins/memory/mcp/dist/lib/graph-write-gate.d.ts.map +1 -0
  600. package/payload/platform/plugins/memory/mcp/dist/lib/graph-write-gate.js +89 -0
  601. package/payload/platform/plugins/memory/mcp/dist/lib/graph-write-gate.js.map +1 -0
  602. package/payload/platform/plugins/memory/mcp/dist/lib/live-schema-source.d.ts +136 -0
  603. package/payload/platform/plugins/memory/mcp/dist/lib/live-schema-source.d.ts.map +1 -0
  604. package/payload/platform/plugins/memory/mcp/dist/lib/live-schema-source.js +180 -0
  605. package/payload/platform/plugins/memory/mcp/dist/lib/live-schema-source.js.map +1 -0
  606. package/payload/platform/plugins/memory/mcp/dist/lib/llm-classifier.d.ts +246 -0
  607. package/payload/platform/plugins/memory/mcp/dist/lib/llm-classifier.d.ts.map +1 -0
  608. package/payload/platform/plugins/memory/mcp/dist/lib/llm-classifier.js +828 -0
  609. package/payload/platform/plugins/memory/mcp/dist/lib/llm-classifier.js.map +1 -0
  610. package/payload/platform/plugins/memory/mcp/dist/lib/llm-ranker.d.ts +63 -0
  611. package/payload/platform/plugins/memory/mcp/dist/lib/llm-ranker.d.ts.map +1 -0
  612. package/payload/platform/plugins/memory/mcp/dist/lib/llm-ranker.js +210 -0
  613. package/payload/platform/plugins/memory/mcp/dist/lib/llm-ranker.js.map +1 -0
  614. package/payload/platform/plugins/memory/mcp/dist/lib/neo4j.d.ts +5 -0
  615. package/payload/platform/plugins/memory/mcp/dist/lib/neo4j.d.ts.map +1 -0
  616. package/payload/platform/plugins/memory/mcp/dist/lib/neo4j.js +40 -0
  617. package/payload/platform/plugins/memory/mcp/dist/lib/neo4j.js.map +1 -0
  618. package/payload/platform/plugins/memory/mcp/dist/lib/schema-loader.d.ts +113 -0
  619. package/payload/platform/plugins/memory/mcp/dist/lib/schema-loader.d.ts.map +1 -0
  620. package/payload/platform/plugins/memory/mcp/dist/lib/schema-loader.js +455 -0
  621. package/payload/platform/plugins/memory/mcp/dist/lib/schema-loader.js.map +1 -0
  622. package/payload/platform/plugins/memory/mcp/dist/lib/schema-validator.d.ts +83 -0
  623. package/payload/platform/plugins/memory/mcp/dist/lib/schema-validator.d.ts.map +1 -0
  624. package/payload/platform/plugins/memory/mcp/dist/lib/schema-validator.js +209 -0
  625. package/payload/platform/plugins/memory/mcp/dist/lib/schema-validator.js.map +1 -0
  626. package/payload/platform/plugins/memory/mcp/dist/lib/uuid.d.ts +3 -0
  627. package/payload/platform/plugins/memory/mcp/dist/lib/uuid.d.ts.map +1 -0
  628. package/payload/platform/plugins/memory/mcp/dist/lib/uuid.js +12 -0
  629. package/payload/platform/plugins/memory/mcp/dist/lib/uuid.js.map +1 -0
  630. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-derive-insights.test.d.ts +2 -0
  631. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-derive-insights.test.d.ts.map +1 -0
  632. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-derive-insights.test.js +97 -0
  633. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-derive-insights.test.js.map +1 -0
  634. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-enrich-rejection.test.d.ts +2 -0
  635. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-enrich-rejection.test.d.ts.map +1 -0
  636. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-enrich-rejection.test.js +184 -0
  637. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-archive-enrich-rejection.test.js.map +1 -0
  638. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-normalisers-source-agnosticism.test.d.ts +2 -0
  639. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-normalisers-source-agnosticism.test.d.ts.map +1 -0
  640. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-normalisers-source-agnosticism.test.js +73 -0
  641. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-normalisers-source-agnosticism.test.js.map +1 -0
  642. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-normalisers-whatsapp-text.test.d.ts +2 -0
  643. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-normalisers-whatsapp-text.test.d.ts.map +1 -0
  644. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-normalisers-whatsapp-text.test.js +109 -0
  645. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/conversation-normalisers-whatsapp-text.test.js.map +1 -0
  646. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-archive-write.test.d.ts +2 -0
  647. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-archive-write.test.d.ts.map +1 -0
  648. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-archive-write.test.js +84 -0
  649. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-archive-write.test.js.map +1 -0
  650. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest.test.d.ts +2 -0
  651. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest.test.d.ts.map +1 -0
  652. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest.test.js +106 -0
  653. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/memory-ingest.test.js.map +1 -0
  654. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/profile-update-not-applicable.test.d.ts +2 -0
  655. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/profile-update-not-applicable.test.d.ts.map +1 -0
  656. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/profile-update-not-applicable.test.js +87 -0
  657. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/profile-update-not-applicable.test.js.map +1 -0
  658. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/profile-update-personfields-open.test.d.ts +2 -0
  659. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/profile-update-personfields-open.test.d.ts.map +1 -0
  660. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/profile-update-personfields-open.test.js +148 -0
  661. package/payload/platform/plugins/memory/mcp/dist/tools/__tests__/profile-update-personfields-open.test.js.map +1 -0
  662. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-archive-derive-insights.d.ts +89 -0
  663. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-archive-derive-insights.d.ts.map +1 -0
  664. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-archive-derive-insights.js +542 -0
  665. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-archive-derive-insights.js.map +1 -0
  666. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-archive-enrich-rejection.d.ts +41 -0
  667. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-archive-enrich-rejection.d.ts.map +1 -0
  668. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-archive-enrich-rejection.js +116 -0
  669. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-archive-enrich-rejection.js.map +1 -0
  670. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-memory-expunge.d.ts +8 -0
  671. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-memory-expunge.d.ts.map +1 -0
  672. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-memory-expunge.js +7 -0
  673. package/payload/platform/plugins/memory/mcp/dist/tools/conversation-memory-expunge.js.map +1 -0
  674. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-add.d.ts +7 -0
  675. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-add.d.ts.map +1 -0
  676. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-add.js +28 -0
  677. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-add.js.map +1 -0
  678. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-list.d.ts +7 -0
  679. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-list.d.ts.map +1 -0
  680. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-list.js +7 -0
  681. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-list.js.map +1 -0
  682. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-remove.d.ts +7 -0
  683. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-remove.d.ts.map +1 -0
  684. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-remove.js +27 -0
  685. package/payload/platform/plugins/memory/mcp/dist/tools/graph-prune-denylist-remove.js.map +1 -0
  686. package/payload/platform/plugins/memory/mcp/dist/tools/memory-archive-write.d.ts +54 -0
  687. package/payload/platform/plugins/memory/mcp/dist/tools/memory-archive-write.d.ts.map +1 -0
  688. package/payload/platform/plugins/memory/mcp/dist/tools/memory-archive-write.js +231 -0
  689. package/payload/platform/plugins/memory/mcp/dist/tools/memory-archive-write.js.map +1 -0
  690. package/payload/platform/plugins/memory/mcp/dist/tools/memory-classify.d.ts +34 -0
  691. package/payload/platform/plugins/memory/mcp/dist/tools/memory-classify.d.ts.map +1 -0
  692. package/payload/platform/plugins/memory/mcp/dist/tools/memory-classify.js +58 -0
  693. package/payload/platform/plugins/memory/mcp/dist/tools/memory-classify.js.map +1 -0
  694. package/payload/platform/plugins/memory/mcp/dist/tools/memory-delete.d.ts +57 -0
  695. package/payload/platform/plugins/memory/mcp/dist/tools/memory-delete.d.ts.map +1 -0
  696. package/payload/platform/plugins/memory/mcp/dist/tools/memory-delete.js +106 -0
  697. package/payload/platform/plugins/memory/mcp/dist/tools/memory-delete.js.map +1 -0
  698. package/payload/platform/plugins/memory/mcp/dist/tools/memory-edit-attachment.d.ts +16 -0
  699. package/payload/platform/plugins/memory/mcp/dist/tools/memory-edit-attachment.d.ts.map +1 -0
  700. package/payload/platform/plugins/memory/mcp/dist/tools/memory-edit-attachment.js +91 -0
  701. package/payload/platform/plugins/memory/mcp/dist/tools/memory-edit-attachment.js.map +1 -0
  702. package/payload/platform/plugins/memory/mcp/dist/tools/memory-empty-trash.d.ts +22 -0
  703. package/payload/platform/plugins/memory/mcp/dist/tools/memory-empty-trash.d.ts.map +1 -0
  704. package/payload/platform/plugins/memory/mcp/dist/tools/memory-empty-trash.js +36 -0
  705. package/payload/platform/plugins/memory/mcp/dist/tools/memory-empty-trash.js.map +1 -0
  706. package/payload/platform/plugins/memory/mcp/dist/tools/memory-find-candidates.d.ts +58 -0
  707. package/payload/platform/plugins/memory/mcp/dist/tools/memory-find-candidates.d.ts.map +1 -0
  708. package/payload/platform/plugins/memory/mcp/dist/tools/memory-find-candidates.js +125 -0
  709. package/payload/platform/plugins/memory/mcp/dist/tools/memory-find-candidates.js.map +1 -0
  710. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest-extract.d.ts +28 -0
  711. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest-extract.d.ts.map +1 -0
  712. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest-extract.js +93 -0
  713. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest-extract.js.map +1 -0
  714. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest-web.d.ts +20 -0
  715. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest-web.d.ts.map +1 -0
  716. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest-web.js +87 -0
  717. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest-web.js.map +1 -0
  718. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest.d.ts +129 -0
  719. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest.d.ts.map +1 -0
  720. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest.js +827 -0
  721. package/payload/platform/plugins/memory/mcp/dist/tools/memory-ingest.js.map +1 -0
  722. package/payload/platform/plugins/memory/mcp/dist/tools/memory-list-attachments.d.ts +19 -0
  723. package/payload/platform/plugins/memory/mcp/dist/tools/memory-list-attachments.d.ts.map +1 -0
  724. package/payload/platform/plugins/memory/mcp/dist/tools/memory-list-attachments.js +125 -0
  725. package/payload/platform/plugins/memory/mcp/dist/tools/memory-list-attachments.js.map +1 -0
  726. package/payload/platform/plugins/memory/mcp/dist/tools/memory-rank.d.ts +61 -0
  727. package/payload/platform/plugins/memory/mcp/dist/tools/memory-rank.d.ts.map +1 -0
  728. package/payload/platform/plugins/memory/mcp/dist/tools/memory-rank.js +102 -0
  729. package/payload/platform/plugins/memory/mcp/dist/tools/memory-rank.js.map +1 -0
  730. package/payload/platform/plugins/memory/mcp/dist/tools/memory-read-attachment.d.ts +12 -0
  731. package/payload/platform/plugins/memory/mcp/dist/tools/memory-read-attachment.d.ts.map +1 -0
  732. package/payload/platform/plugins/memory/mcp/dist/tools/memory-read-attachment.js +100 -0
  733. package/payload/platform/plugins/memory/mcp/dist/tools/memory-read-attachment.js.map +1 -0
  734. package/payload/platform/plugins/memory/mcp/dist/tools/memory-reindex.d.ts +9 -0
  735. package/payload/platform/plugins/memory/mcp/dist/tools/memory-reindex.d.ts.map +1 -0
  736. package/payload/platform/plugins/memory/mcp/dist/tools/memory-reindex.js +84 -0
  737. package/payload/platform/plugins/memory/mcp/dist/tools/memory-reindex.js.map +1 -0
  738. package/payload/platform/plugins/memory/mcp/dist/tools/memory-rename-attachment.d.ts +13 -0
  739. package/payload/platform/plugins/memory/mcp/dist/tools/memory-rename-attachment.d.ts.map +1 -0
  740. package/payload/platform/plugins/memory/mcp/dist/tools/memory-rename-attachment.js +63 -0
  741. package/payload/platform/plugins/memory/mcp/dist/tools/memory-rename-attachment.js.map +1 -0
  742. package/payload/platform/plugins/memory/mcp/dist/tools/memory-restore.d.ts +24 -0
  743. package/payload/platform/plugins/memory/mcp/dist/tools/memory-restore.d.ts.map +1 -0
  744. package/payload/platform/plugins/memory/mcp/dist/tools/memory-restore.js +40 -0
  745. package/payload/platform/plugins/memory/mcp/dist/tools/memory-restore.js.map +1 -0
  746. package/payload/platform/plugins/memory/mcp/dist/tools/memory-search.d.ts +5 -0
  747. package/payload/platform/plugins/memory/mcp/dist/tools/memory-search.d.ts.map +1 -0
  748. package/payload/platform/plugins/memory/mcp/dist/tools/memory-search.js +42 -0
  749. package/payload/platform/plugins/memory/mcp/dist/tools/memory-search.js.map +1 -0
  750. package/payload/platform/plugins/memory/mcp/dist/tools/memory-update.d.ts +13 -0
  751. package/payload/platform/plugins/memory/mcp/dist/tools/memory-update.d.ts.map +1 -0
  752. package/payload/platform/plugins/memory/mcp/dist/tools/memory-update.js +77 -0
  753. package/payload/platform/plugins/memory/mcp/dist/tools/memory-update.js.map +1 -0
  754. package/payload/platform/plugins/memory/mcp/dist/tools/memory-write.d.ts +47 -0
  755. package/payload/platform/plugins/memory/mcp/dist/tools/memory-write.d.ts.map +1 -0
  756. package/payload/platform/plugins/memory/mcp/dist/tools/memory-write.js +173 -0
  757. package/payload/platform/plugins/memory/mcp/dist/tools/memory-write.js.map +1 -0
  758. package/payload/platform/plugins/memory/mcp/dist/tools/profile-delete.d.ts +24 -0
  759. package/payload/platform/plugins/memory/mcp/dist/tools/profile-delete.d.ts.map +1 -0
  760. package/payload/platform/plugins/memory/mcp/dist/tools/profile-delete.js +31 -0
  761. package/payload/platform/plugins/memory/mcp/dist/tools/profile-delete.js.map +1 -0
  762. package/payload/platform/plugins/memory/mcp/dist/tools/profile-read.d.ts +44 -0
  763. package/payload/platform/plugins/memory/mcp/dist/tools/profile-read.d.ts.map +1 -0
  764. package/payload/platform/plugins/memory/mcp/dist/tools/profile-read.js +322 -0
  765. package/payload/platform/plugins/memory/mcp/dist/tools/profile-read.js.map +1 -0
  766. package/payload/platform/plugins/memory/mcp/dist/tools/profile-update.d.ts +65 -0
  767. package/payload/platform/plugins/memory/mcp/dist/tools/profile-update.d.ts.map +1 -0
  768. package/payload/platform/plugins/memory/mcp/dist/tools/profile-update.js +369 -0
  769. package/payload/platform/plugins/memory/mcp/dist/tools/profile-update.js.map +1 -0
  770. package/payload/platform/plugins/memory/mcp/package.json +24 -0
  771. package/payload/platform/plugins/memory/mcp/scripts/boot-smoke.sh +69 -0
  772. package/payload/platform/plugins/memory/mcp/scripts/graph/accept.sh +217 -0
  773. package/payload/platform/plugins/memory/mcp/scripts/graph/fixture.cypher +59 -0
  774. package/payload/platform/plugins/memory/mcp/vitest.config.ts +15 -0
  775. package/payload/platform/plugins/memory/references/graph-primitives.md +342 -0
  776. package/payload/platform/plugins/memory/references/schema-base.md +234 -0
  777. package/payload/platform/plugins/memory/references/schema-creator.md +35 -0
  778. package/payload/platform/plugins/memory/references/schema-estate-agent.md +35 -0
  779. package/payload/platform/plugins/memory/references/schema-food-beverage.md +32 -0
  780. package/payload/platform/plugins/memory/references/schema-hospitality.md +31 -0
  781. package/payload/platform/plugins/memory/references/schema-logistics.md +30 -0
  782. package/payload/platform/plugins/memory/references/schema-professional-services.md +33 -0
  783. package/payload/platform/plugins/memory/references/schema-retail.md +33 -0
  784. package/payload/platform/plugins/memory/references/schema-trades.md +36 -0
  785. package/payload/platform/plugins/memory/skills/conversation-archive/SKILL.md +202 -0
  786. package/payload/platform/plugins/memory/skills/conversation-archive-enrich/SKILL.md +159 -0
  787. package/payload/platform/plugins/memory/skills/conversational-memory/SKILL.md +108 -0
  788. package/payload/platform/plugins/memory/skills/document-ingest/SKILL.md +267 -0
  789. package/payload/platform/plugins/outlook/PLUGIN.md +48 -0
  790. package/payload/platform/plugins/outlook/mcp/dist/__tests__/graph-client.test.d.ts +2 -0
  791. package/payload/platform/plugins/outlook/mcp/dist/__tests__/graph-client.test.d.ts.map +1 -0
  792. package/payload/platform/plugins/outlook/mcp/dist/__tests__/graph-client.test.js +94 -0
  793. package/payload/platform/plugins/outlook/mcp/dist/__tests__/graph-client.test.js.map +1 -0
  794. package/payload/platform/plugins/outlook/mcp/dist/__tests__/log.test.d.ts +2 -0
  795. package/payload/platform/plugins/outlook/mcp/dist/__tests__/log.test.d.ts.map +1 -0
  796. package/payload/platform/plugins/outlook/mcp/dist/__tests__/log.test.js +31 -0
  797. package/payload/platform/plugins/outlook/mcp/dist/__tests__/log.test.js.map +1 -0
  798. package/payload/platform/plugins/outlook/mcp/dist/__tests__/pkce-flow.test.d.ts +2 -0
  799. package/payload/platform/plugins/outlook/mcp/dist/__tests__/pkce-flow.test.d.ts.map +1 -0
  800. package/payload/platform/plugins/outlook/mcp/dist/__tests__/pkce-flow.test.js +213 -0
  801. package/payload/platform/plugins/outlook/mcp/dist/__tests__/pkce-flow.test.js.map +1 -0
  802. package/payload/platform/plugins/outlook/mcp/dist/__tests__/token-store.test.d.ts +2 -0
  803. package/payload/platform/plugins/outlook/mcp/dist/__tests__/token-store.test.d.ts.map +1 -0
  804. package/payload/platform/plugins/outlook/mcp/dist/__tests__/token-store.test.js +130 -0
  805. package/payload/platform/plugins/outlook/mcp/dist/__tests__/token-store.test.js.map +1 -0
  806. package/payload/platform/plugins/outlook/mcp/dist/auth/pkce-flow.d.ts +65 -0
  807. package/payload/platform/plugins/outlook/mcp/dist/auth/pkce-flow.d.ts.map +1 -0
  808. package/payload/platform/plugins/outlook/mcp/dist/auth/pkce-flow.js +261 -0
  809. package/payload/platform/plugins/outlook/mcp/dist/auth/pkce-flow.js.map +1 -0
  810. package/payload/platform/plugins/outlook/mcp/dist/auth/token-store.d.ts +61 -0
  811. package/payload/platform/plugins/outlook/mcp/dist/auth/token-store.d.ts.map +1 -0
  812. package/payload/platform/plugins/outlook/mcp/dist/auth/token-store.js +170 -0
  813. package/payload/platform/plugins/outlook/mcp/dist/auth/token-store.js.map +1 -0
  814. package/payload/platform/plugins/outlook/mcp/dist/index.d.ts +18 -0
  815. package/payload/platform/plugins/outlook/mcp/dist/index.d.ts.map +1 -0
  816. package/payload/platform/plugins/outlook/mcp/dist/index.js +152 -0
  817. package/payload/platform/plugins/outlook/mcp/dist/index.js.map +1 -0
  818. package/payload/platform/plugins/outlook/mcp/dist/lib/graph-client.d.ts +60 -0
  819. package/payload/platform/plugins/outlook/mcp/dist/lib/graph-client.d.ts.map +1 -0
  820. package/payload/platform/plugins/outlook/mcp/dist/lib/graph-client.js +189 -0
  821. package/payload/platform/plugins/outlook/mcp/dist/lib/graph-client.js.map +1 -0
  822. package/payload/platform/plugins/outlook/mcp/dist/lib/log.d.ts +23 -0
  823. package/payload/platform/plugins/outlook/mcp/dist/lib/log.d.ts.map +1 -0
  824. package/payload/platform/plugins/outlook/mcp/dist/lib/log.js +53 -0
  825. package/payload/platform/plugins/outlook/mcp/dist/lib/log.js.map +1 -0
  826. package/payload/platform/plugins/outlook/mcp/dist/tools/account-register.d.ts +26 -0
  827. package/payload/platform/plugins/outlook/mcp/dist/tools/account-register.d.ts.map +1 -0
  828. package/payload/platform/plugins/outlook/mcp/dist/tools/account-register.js +50 -0
  829. package/payload/platform/plugins/outlook/mcp/dist/tools/account-register.js.map +1 -0
  830. package/payload/platform/plugins/outlook/mcp/dist/tools/calendar-event.d.ts +12 -0
  831. package/payload/platform/plugins/outlook/mcp/dist/tools/calendar-event.d.ts.map +1 -0
  832. package/payload/platform/plugins/outlook/mcp/dist/tools/calendar-event.js +32 -0
  833. package/payload/platform/plugins/outlook/mcp/dist/tools/calendar-event.js.map +1 -0
  834. package/payload/platform/plugins/outlook/mcp/dist/tools/calendar-list.d.ts +59 -0
  835. package/payload/platform/plugins/outlook/mcp/dist/tools/calendar-list.d.ts.map +1 -0
  836. package/payload/platform/plugins/outlook/mcp/dist/tools/calendar-list.js +54 -0
  837. package/payload/platform/plugins/outlook/mcp/dist/tools/calendar-list.js.map +1 -0
  838. package/payload/platform/plugins/outlook/mcp/dist/tools/contacts-list.d.ts +14 -0
  839. package/payload/platform/plugins/outlook/mcp/dist/tools/contacts-list.d.ts.map +1 -0
  840. package/payload/platform/plugins/outlook/mcp/dist/tools/contacts-list.js +45 -0
  841. package/payload/platform/plugins/outlook/mcp/dist/tools/contacts-list.js.map +1 -0
  842. package/payload/platform/plugins/outlook/mcp/dist/tools/mail-list.d.ts +15 -0
  843. package/payload/platform/plugins/outlook/mcp/dist/tools/mail-list.d.ts.map +1 -0
  844. package/payload/platform/plugins/outlook/mcp/dist/tools/mail-list.js +48 -0
  845. package/payload/platform/plugins/outlook/mcp/dist/tools/mail-list.js.map +1 -0
  846. package/payload/platform/plugins/outlook/mcp/dist/tools/mail-search.d.ts +8 -0
  847. package/payload/platform/plugins/outlook/mcp/dist/tools/mail-search.d.ts.map +1 -0
  848. package/payload/platform/plugins/outlook/mcp/dist/tools/mail-search.js +49 -0
  849. package/payload/platform/plugins/outlook/mcp/dist/tools/mail-search.js.map +1 -0
  850. package/payload/platform/plugins/outlook/mcp/dist/tools/mailbox-info.d.ts +19 -0
  851. package/payload/platform/plugins/outlook/mcp/dist/tools/mailbox-info.d.ts.map +1 -0
  852. package/payload/platform/plugins/outlook/mcp/dist/tools/mailbox-info.js +58 -0
  853. package/payload/platform/plugins/outlook/mcp/dist/tools/mailbox-info.js.map +1 -0
  854. package/payload/platform/plugins/outlook/mcp/package.json +20 -0
  855. package/payload/platform/plugins/outlook/mcp/scripts/verify-doc-impl.sh +109 -0
  856. package/payload/platform/plugins/outlook/references/auth.md +118 -0
  857. package/payload/platform/plugins/outlook/references/graph-surfaces.md +114 -0
  858. package/payload/platform/plugins/outlook/skills/outlook/SKILL.md +65 -0
  859. package/payload/platform/plugins/projects/PLUGIN.md +90 -0
  860. package/payload/platform/plugins/projects/references/investigation.md +63 -0
  861. package/payload/platform/plugins/projects/references/retrospective.md +71 -0
  862. package/payload/platform/plugins/projects/references/review.md +51 -0
  863. package/payload/platform/plugins/projects/references/sprint.md +168 -0
  864. package/payload/platform/plugins/replicate/PLUGIN.md +23 -0
  865. package/payload/platform/plugins/replicate/mcp/dist/index.d.ts +2 -0
  866. package/payload/platform/plugins/replicate/mcp/dist/index.d.ts.map +1 -0
  867. package/payload/platform/plugins/replicate/mcp/dist/index.js +106 -0
  868. package/payload/platform/plugins/replicate/mcp/dist/index.js.map +1 -0
  869. package/payload/platform/plugins/replicate/mcp/dist/lib/replicate-key.d.ts +15 -0
  870. package/payload/platform/plugins/replicate/mcp/dist/lib/replicate-key.d.ts.map +1 -0
  871. package/payload/platform/plugins/replicate/mcp/dist/lib/replicate-key.js +73 -0
  872. package/payload/platform/plugins/replicate/mcp/dist/lib/replicate-key.js.map +1 -0
  873. package/payload/platform/plugins/replicate/mcp/dist/tools/image-generate.d.ts +14 -0
  874. package/payload/platform/plugins/replicate/mcp/dist/tools/image-generate.d.ts.map +1 -0
  875. package/payload/platform/plugins/replicate/mcp/dist/tools/image-generate.js +191 -0
  876. package/payload/platform/plugins/replicate/mcp/dist/tools/image-generate.js.map +1 -0
  877. package/payload/platform/plugins/replicate/mcp/package.json +21 -0
  878. package/payload/platform/plugins/sales/PLUGIN.md +106 -0
  879. package/payload/platform/plugins/sales/references/close-tracking.md +69 -0
  880. package/payload/platform/plugins/sales/references/comparisons.md +99 -0
  881. package/payload/platform/plugins/sales/references/competitive-positioning.md +51 -0
  882. package/payload/platform/plugins/sales/references/faq.md +77 -0
  883. package/payload/platform/plugins/sales/references/objection-handling.md +157 -0
  884. package/payload/platform/plugins/sales/references/pricing.md +101 -0
  885. package/payload/platform/plugins/scheduling/PLUGIN.md +103 -0
  886. package/payload/platform/plugins/scheduling/mcp/dist/__tests__/time-resolve-description.test.d.ts +2 -0
  887. package/payload/platform/plugins/scheduling/mcp/dist/__tests__/time-resolve-description.test.d.ts.map +1 -0
  888. package/payload/platform/plugins/scheduling/mcp/dist/__tests__/time-resolve-description.test.js +16 -0
  889. package/payload/platform/plugins/scheduling/mcp/dist/__tests__/time-resolve-description.test.js.map +1 -0
  890. package/payload/platform/plugins/scheduling/mcp/dist/index.d.ts +2 -0
  891. package/payload/platform/plugins/scheduling/mcp/dist/index.d.ts.map +1 -0
  892. package/payload/platform/plugins/scheduling/mcp/dist/index.js +315 -0
  893. package/payload/platform/plugins/scheduling/mcp/dist/index.js.map +1 -0
  894. package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/getUserTimezone.test.d.ts +2 -0
  895. package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/getUserTimezone.test.d.ts.map +1 -0
  896. package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/getUserTimezone.test.js +119 -0
  897. package/payload/platform/plugins/scheduling/mcp/dist/lib/__tests__/getUserTimezone.test.js.map +1 -0
  898. package/payload/platform/plugins/scheduling/mcp/dist/lib/embedding.d.ts +2 -0
  899. package/payload/platform/plugins/scheduling/mcp/dist/lib/embedding.d.ts.map +1 -0
  900. package/payload/platform/plugins/scheduling/mcp/dist/lib/embedding.js +19 -0
  901. package/payload/platform/plugins/scheduling/mcp/dist/lib/embedding.js.map +1 -0
  902. package/payload/platform/plugins/scheduling/mcp/dist/lib/ics.d.ts +47 -0
  903. package/payload/platform/plugins/scheduling/mcp/dist/lib/ics.d.ts.map +1 -0
  904. package/payload/platform/plugins/scheduling/mcp/dist/lib/ics.js +362 -0
  905. package/payload/platform/plugins/scheduling/mcp/dist/lib/ics.js.map +1 -0
  906. package/payload/platform/plugins/scheduling/mcp/dist/lib/neo4j.d.ts +30 -0
  907. package/payload/platform/plugins/scheduling/mcp/dist/lib/neo4j.d.ts.map +1 -0
  908. package/payload/platform/plugins/scheduling/mcp/dist/lib/neo4j.js +89 -0
  909. package/payload/platform/plugins/scheduling/mcp/dist/lib/neo4j.js.map +1 -0
  910. package/payload/platform/plugins/scheduling/mcp/dist/lib/time-format.d.ts +48 -0
  911. package/payload/platform/plugins/scheduling/mcp/dist/lib/time-format.d.ts.map +1 -0
  912. package/payload/platform/plugins/scheduling/mcp/dist/lib/time-format.js +140 -0
  913. package/payload/platform/plugins/scheduling/mcp/dist/lib/time-format.js.map +1 -0
  914. package/payload/platform/plugins/scheduling/mcp/dist/scripts/check-due-events.d.ts +20 -0
  915. package/payload/platform/plugins/scheduling/mcp/dist/scripts/check-due-events.d.ts.map +1 -0
  916. package/payload/platform/plugins/scheduling/mcp/dist/scripts/check-due-events.js +568 -0
  917. package/payload/platform/plugins/scheduling/mcp/dist/scripts/check-due-events.js.map +1 -0
  918. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-cancel.d.ts +7 -0
  919. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-cancel.d.ts.map +1 -0
  920. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-cancel.js +23 -0
  921. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-cancel.js.map +1 -0
  922. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-event.d.ts +25 -0
  923. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-event.d.ts.map +1 -0
  924. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-event.js +121 -0
  925. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-event.js.map +1 -0
  926. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-export-ics.d.ts +9 -0
  927. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-export-ics.d.ts.map +1 -0
  928. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-export-ics.js +76 -0
  929. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-export-ics.js.map +1 -0
  930. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-get.d.ts +25 -0
  931. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-get.d.ts.map +1 -0
  932. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-get.js +53 -0
  933. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-get.js.map +1 -0
  934. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-import-ics.d.ts +8 -0
  935. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-import-ics.d.ts.map +1 -0
  936. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-import-ics.js +48 -0
  937. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-import-ics.js.map +1 -0
  938. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-list.d.ts +20 -0
  939. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-list.d.ts.map +1 -0
  940. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-list.js +76 -0
  941. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-list.js.map +1 -0
  942. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-update.d.ts +18 -0
  943. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-update.d.ts.map +1 -0
  944. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-update.js +167 -0
  945. package/payload/platform/plugins/scheduling/mcp/dist/tools/schedule-update.js.map +1 -0
  946. package/payload/platform/plugins/scheduling/mcp/package.json +23 -0
  947. package/payload/platform/plugins/scheduling/mcp/vitest.config.ts +9 -0
  948. package/payload/platform/plugins/tasks/.claude-plugin/plugin.json +17 -0
  949. package/payload/platform/plugins/tasks/.mcp.json +13 -0
  950. package/payload/platform/plugins/tasks/PLUGIN.md +81 -0
  951. package/payload/platform/plugins/tasks/mcp/dist/index.d.ts +2 -0
  952. package/payload/platform/plugins/tasks/mcp/dist/index.d.ts.map +1 -0
  953. package/payload/platform/plugins/tasks/mcp/dist/index.js +503 -0
  954. package/payload/platform/plugins/tasks/mcp/dist/index.js.map +1 -0
  955. package/payload/platform/plugins/tasks/mcp/dist/lib/embeddings.d.ts +7 -0
  956. package/payload/platform/plugins/tasks/mcp/dist/lib/embeddings.d.ts.map +1 -0
  957. package/payload/platform/plugins/tasks/mcp/dist/lib/embeddings.js +24 -0
  958. package/payload/platform/plugins/tasks/mcp/dist/lib/embeddings.js.map +1 -0
  959. package/payload/platform/plugins/tasks/mcp/dist/lib/neo4j.d.ts +5 -0
  960. package/payload/platform/plugins/tasks/mcp/dist/lib/neo4j.d.ts.map +1 -0
  961. package/payload/platform/plugins/tasks/mcp/dist/lib/neo4j.js +40 -0
  962. package/payload/platform/plugins/tasks/mcp/dist/lib/neo4j.js.map +1 -0
  963. package/payload/platform/plugins/tasks/mcp/dist/tools/project-complete.d.ts +17 -0
  964. package/payload/platform/plugins/tasks/mcp/dist/tools/project-complete.d.ts.map +1 -0
  965. package/payload/platform/plugins/tasks/mcp/dist/tools/project-complete.js +76 -0
  966. package/payload/platform/plugins/tasks/mcp/dist/tools/project-complete.js.map +1 -0
  967. package/payload/platform/plugins/tasks/mcp/dist/tools/project-create.d.ts +29 -0
  968. package/payload/platform/plugins/tasks/mcp/dist/tools/project-create.d.ts.map +1 -0
  969. package/payload/platform/plugins/tasks/mcp/dist/tools/project-create.js +235 -0
  970. package/payload/platform/plugins/tasks/mcp/dist/tools/project-create.js.map +1 -0
  971. package/payload/platform/plugins/tasks/mcp/dist/tools/project-get.d.ts +40 -0
  972. package/payload/platform/plugins/tasks/mcp/dist/tools/project-get.d.ts.map +1 -0
  973. package/payload/platform/plugins/tasks/mcp/dist/tools/project-get.js +125 -0
  974. package/payload/platform/plugins/tasks/mcp/dist/tools/project-get.js.map +1 -0
  975. package/payload/platform/plugins/tasks/mcp/dist/tools/project-list.d.ts +26 -0
  976. package/payload/platform/plugins/tasks/mcp/dist/tools/project-list.d.ts.map +1 -0
  977. package/payload/platform/plugins/tasks/mcp/dist/tools/project-list.js +81 -0
  978. package/payload/platform/plugins/tasks/mcp/dist/tools/project-list.js.map +1 -0
  979. package/payload/platform/plugins/tasks/mcp/dist/tools/project-update.d.ts +19 -0
  980. package/payload/platform/plugins/tasks/mcp/dist/tools/project-update.d.ts.map +1 -0
  981. package/payload/platform/plugins/tasks/mcp/dist/tools/project-update.js +102 -0
  982. package/payload/platform/plugins/tasks/mcp/dist/tools/project-update.js.map +1 -0
  983. package/payload/platform/plugins/tasks/mcp/dist/tools/session-list.d.ts +20 -0
  984. package/payload/platform/plugins/tasks/mcp/dist/tools/session-list.d.ts.map +1 -0
  985. package/payload/platform/plugins/tasks/mcp/dist/tools/session-list.js +37 -0
  986. package/payload/platform/plugins/tasks/mcp/dist/tools/session-list.js.map +1 -0
  987. package/payload/platform/plugins/tasks/mcp/dist/tools/session-name.d.ts +12 -0
  988. package/payload/platform/plugins/tasks/mcp/dist/tools/session-name.d.ts.map +1 -0
  989. package/payload/platform/plugins/tasks/mcp/dist/tools/session-name.js +28 -0
  990. package/payload/platform/plugins/tasks/mcp/dist/tools/session-name.js.map +1 -0
  991. package/payload/platform/plugins/tasks/mcp/dist/tools/task-complete.d.ts +16 -0
  992. package/payload/platform/plugins/tasks/mcp/dist/tools/task-complete.d.ts.map +1 -0
  993. package/payload/platform/plugins/tasks/mcp/dist/tools/task-complete.js +33 -0
  994. package/payload/platform/plugins/tasks/mcp/dist/tools/task-complete.js.map +1 -0
  995. package/payload/platform/plugins/tasks/mcp/dist/tools/task-create.d.ts +63 -0
  996. package/payload/platform/plugins/tasks/mcp/dist/tools/task-create.d.ts.map +1 -0
  997. package/payload/platform/plugins/tasks/mcp/dist/tools/task-create.js +141 -0
  998. package/payload/platform/plugins/tasks/mcp/dist/tools/task-create.js.map +1 -0
  999. package/payload/platform/plugins/tasks/mcp/dist/tools/task-get.d.ts +19 -0
  1000. package/payload/platform/plugins/tasks/mcp/dist/tools/task-get.d.ts.map +1 -0
  1001. package/payload/platform/plugins/tasks/mcp/dist/tools/task-get.js +51 -0
  1002. package/payload/platform/plugins/tasks/mcp/dist/tools/task-get.js.map +1 -0
  1003. package/payload/platform/plugins/tasks/mcp/dist/tools/task-list.d.ts +18 -0
  1004. package/payload/platform/plugins/tasks/mcp/dist/tools/task-list.d.ts.map +1 -0
  1005. package/payload/platform/plugins/tasks/mcp/dist/tools/task-list.js +66 -0
  1006. package/payload/platform/plugins/tasks/mcp/dist/tools/task-list.js.map +1 -0
  1007. package/payload/platform/plugins/tasks/mcp/dist/tools/task-ready.d.ts +21 -0
  1008. package/payload/platform/plugins/tasks/mcp/dist/tools/task-ready.d.ts.map +1 -0
  1009. package/payload/platform/plugins/tasks/mcp/dist/tools/task-ready.js +54 -0
  1010. package/payload/platform/plugins/tasks/mcp/dist/tools/task-ready.js.map +1 -0
  1011. package/payload/platform/plugins/tasks/mcp/dist/tools/task-relate.d.ts +12 -0
  1012. package/payload/platform/plugins/tasks/mcp/dist/tools/task-relate.d.ts.map +1 -0
  1013. package/payload/platform/plugins/tasks/mcp/dist/tools/task-relate.js +59 -0
  1014. package/payload/platform/plugins/tasks/mcp/dist/tools/task-relate.js.map +1 -0
  1015. package/payload/platform/plugins/tasks/mcp/dist/tools/task-update.d.ts +32 -0
  1016. package/payload/platform/plugins/tasks/mcp/dist/tools/task-update.d.ts.map +1 -0
  1017. package/payload/platform/plugins/tasks/mcp/dist/tools/task-update.js +112 -0
  1018. package/payload/platform/plugins/tasks/mcp/dist/tools/task-update.js.map +1 -0
  1019. package/payload/platform/plugins/tasks/mcp/package.json +20 -0
  1020. package/payload/platform/plugins/telegram/PLUGIN.md +35 -0
  1021. package/payload/platform/plugins/telegram/mcp/dist/index.d.ts +2 -0
  1022. package/payload/platform/plugins/telegram/mcp/dist/index.d.ts.map +1 -0
  1023. package/payload/platform/plugins/telegram/mcp/dist/index.js +198 -0
  1024. package/payload/platform/plugins/telegram/mcp/dist/index.js.map +1 -0
  1025. package/payload/platform/plugins/telegram/mcp/dist/lib/telegram.d.ts +41 -0
  1026. package/payload/platform/plugins/telegram/mcp/dist/lib/telegram.d.ts.map +1 -0
  1027. package/payload/platform/plugins/telegram/mcp/dist/lib/telegram.js +70 -0
  1028. package/payload/platform/plugins/telegram/mcp/dist/lib/telegram.js.map +1 -0
  1029. package/payload/platform/plugins/telegram/mcp/dist/tools/message-history.d.ts +16 -0
  1030. package/payload/platform/plugins/telegram/mcp/dist/tools/message-history.d.ts.map +1 -0
  1031. package/payload/platform/plugins/telegram/mcp/dist/tools/message-history.js +68 -0
  1032. package/payload/platform/plugins/telegram/mcp/dist/tools/message-history.js.map +1 -0
  1033. package/payload/platform/plugins/telegram/mcp/dist/tools/message.d.ts +20 -0
  1034. package/payload/platform/plugins/telegram/mcp/dist/tools/message.d.ts.map +1 -0
  1035. package/payload/platform/plugins/telegram/mcp/dist/tools/message.js +34 -0
  1036. package/payload/platform/plugins/telegram/mcp/dist/tools/message.js.map +1 -0
  1037. package/payload/platform/plugins/telegram/mcp/package.json +19 -0
  1038. package/payload/platform/plugins/telegram/references/setup-guide.md +50 -0
  1039. package/payload/platform/plugins/waitlist/PLUGIN.md +63 -0
  1040. package/payload/platform/plugins/waitlist/mcp/dist/index.d.ts +2 -0
  1041. package/payload/platform/plugins/waitlist/mcp/dist/index.d.ts.map +1 -0
  1042. package/payload/platform/plugins/waitlist/mcp/dist/index.js +328 -0
  1043. package/payload/platform/plugins/waitlist/mcp/dist/index.js.map +1 -0
  1044. package/payload/platform/plugins/waitlist/mcp/dist/lib/embedding.d.ts +3 -0
  1045. package/payload/platform/plugins/waitlist/mcp/dist/lib/embedding.d.ts.map +1 -0
  1046. package/payload/platform/plugins/waitlist/mcp/dist/lib/embedding.js +48 -0
  1047. package/payload/platform/plugins/waitlist/mcp/dist/lib/embedding.js.map +1 -0
  1048. package/payload/platform/plugins/waitlist/mcp/dist/lib/neo4j.d.ts +5 -0
  1049. package/payload/platform/plugins/waitlist/mcp/dist/lib/neo4j.d.ts.map +1 -0
  1050. package/payload/platform/plugins/waitlist/mcp/dist/lib/neo4j.js +40 -0
  1051. package/payload/platform/plugins/waitlist/mcp/dist/lib/neo4j.js.map +1 -0
  1052. package/payload/platform/plugins/waitlist/mcp/dist/tools/__tests__/waitlist-persist.test.d.ts +2 -0
  1053. package/payload/platform/plugins/waitlist/mcp/dist/tools/__tests__/waitlist-persist.test.d.ts.map +1 -0
  1054. package/payload/platform/plugins/waitlist/mcp/dist/tools/__tests__/waitlist-persist.test.js +70 -0
  1055. package/payload/platform/plugins/waitlist/mcp/dist/tools/__tests__/waitlist-persist.test.js.map +1 -0
  1056. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-heal.d.ts +33 -0
  1057. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-heal.d.ts.map +1 -0
  1058. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-heal.js +124 -0
  1059. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-heal.js.map +1 -0
  1060. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-list.d.ts +23 -0
  1061. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-list.d.ts.map +1 -0
  1062. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-list.js +58 -0
  1063. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-list.js.map +1 -0
  1064. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-persist.d.ts +83 -0
  1065. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-persist.d.ts.map +1 -0
  1066. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-persist.js +433 -0
  1067. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-persist.js.map +1 -0
  1068. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-review.d.ts +19 -0
  1069. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-review.d.ts.map +1 -0
  1070. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-review.js +81 -0
  1071. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-review.js.map +1 -0
  1072. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-scan.d.ts +28 -0
  1073. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-scan.d.ts.map +1 -0
  1074. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-scan.js +50 -0
  1075. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-scan.js.map +1 -0
  1076. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-setup.d.ts +33 -0
  1077. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-setup.d.ts.map +1 -0
  1078. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-setup.js +335 -0
  1079. package/payload/platform/plugins/waitlist/mcp/dist/tools/waitlist-setup.js.map +1 -0
  1080. package/payload/platform/plugins/waitlist/mcp/package.json +23 -0
  1081. package/payload/platform/plugins/waitlist/mcp/vitest.config.ts +9 -0
  1082. package/payload/platform/plugins/whatsapp/PLUGIN.md +71 -0
  1083. package/payload/platform/plugins/whatsapp/mcp/dist/call-api.d.ts +14 -0
  1084. package/payload/platform/plugins/whatsapp/mcp/dist/call-api.d.ts.map +1 -0
  1085. package/payload/platform/plugins/whatsapp/mcp/dist/call-api.js +42 -0
  1086. package/payload/platform/plugins/whatsapp/mcp/dist/call-api.js.map +1 -0
  1087. package/payload/platform/plugins/whatsapp/mcp/dist/index.d.ts +8 -0
  1088. package/payload/platform/plugins/whatsapp/mcp/dist/index.d.ts.map +1 -0
  1089. package/payload/platform/plugins/whatsapp/mcp/dist/index.js +469 -0
  1090. package/payload/platform/plugins/whatsapp/mcp/dist/index.js.map +1 -0
  1091. package/payload/platform/plugins/whatsapp/mcp/package.json +19 -0
  1092. package/payload/platform/plugins/whatsapp/references/channels-whatsapp.md +257 -0
  1093. package/payload/platform/plugins/whatsapp/skills/connect-whatsapp/SKILL.md +82 -0
  1094. package/payload/platform/plugins/whatsapp/skills/manage-whatsapp-config/SKILL.md +99 -0
  1095. package/payload/platform/plugins/workflows/.claude-plugin/plugin.json +16 -0
  1096. package/payload/platform/plugins/workflows/.mcp.json +12 -0
  1097. package/payload/platform/plugins/workflows/PLUGIN.md +297 -0
  1098. package/payload/platform/plugins/workflows/mcp/dist/index.d.ts +2 -0
  1099. package/payload/platform/plugins/workflows/mcp/dist/index.d.ts.map +1 -0
  1100. package/payload/platform/plugins/workflows/mcp/dist/index.js +536 -0
  1101. package/payload/platform/plugins/workflows/mcp/dist/index.js.map +1 -0
  1102. package/payload/platform/plugins/workflows/mcp/dist/lib/active-runs.d.ts +38 -0
  1103. package/payload/platform/plugins/workflows/mcp/dist/lib/active-runs.d.ts.map +1 -0
  1104. package/payload/platform/plugins/workflows/mcp/dist/lib/active-runs.js +83 -0
  1105. package/payload/platform/plugins/workflows/mcp/dist/lib/active-runs.js.map +1 -0
  1106. package/payload/platform/plugins/workflows/mcp/dist/lib/embeddings.d.ts +2 -0
  1107. package/payload/platform/plugins/workflows/mcp/dist/lib/embeddings.d.ts.map +1 -0
  1108. package/payload/platform/plugins/workflows/mcp/dist/lib/embeddings.js +19 -0
  1109. package/payload/platform/plugins/workflows/mcp/dist/lib/embeddings.js.map +1 -0
  1110. package/payload/platform/plugins/workflows/mcp/dist/lib/llm-call.d.ts +151 -0
  1111. package/payload/platform/plugins/workflows/mcp/dist/lib/llm-call.d.ts.map +1 -0
  1112. package/payload/platform/plugins/workflows/mcp/dist/lib/llm-call.js +299 -0
  1113. package/payload/platform/plugins/workflows/mcp/dist/lib/llm-call.js.map +1 -0
  1114. package/payload/platform/plugins/workflows/mcp/dist/lib/neo4j.d.ts +5 -0
  1115. package/payload/platform/plugins/workflows/mcp/dist/lib/neo4j.d.ts.map +1 -0
  1116. package/payload/platform/plugins/workflows/mcp/dist/lib/neo4j.js +40 -0
  1117. package/payload/platform/plugins/workflows/mcp/dist/lib/neo4j.js.map +1 -0
  1118. package/payload/platform/plugins/workflows/mcp/dist/lib/step-resolver.d.ts +153 -0
  1119. package/payload/platform/plugins/workflows/mcp/dist/lib/step-resolver.d.ts.map +1 -0
  1120. package/payload/platform/plugins/workflows/mcp/dist/lib/step-resolver.js +273 -0
  1121. package/payload/platform/plugins/workflows/mcp/dist/lib/step-resolver.js.map +1 -0
  1122. package/payload/platform/plugins/workflows/mcp/dist/lib/validate-capabilities.d.ts +32 -0
  1123. package/payload/platform/plugins/workflows/mcp/dist/lib/validate-capabilities.d.ts.map +1 -0
  1124. package/payload/platform/plugins/workflows/mcp/dist/lib/validate-capabilities.js +97 -0
  1125. package/payload/platform/plugins/workflows/mcp/dist/lib/validate-capabilities.js.map +1 -0
  1126. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-create.d.ts +48 -0
  1127. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-create.d.ts.map +1 -0
  1128. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-create.js +166 -0
  1129. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-create.js.map +1 -0
  1130. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-delete.d.ts +28 -0
  1131. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-delete.d.ts.map +1 -0
  1132. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-delete.js +57 -0
  1133. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-delete.js.map +1 -0
  1134. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-execute.d.ts +64 -0
  1135. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-execute.d.ts.map +1 -0
  1136. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-execute.js +605 -0
  1137. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-execute.js.map +1 -0
  1138. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-get.d.ts +29 -0
  1139. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-get.d.ts.map +1 -0
  1140. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-get.js +55 -0
  1141. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-get.js.map +1 -0
  1142. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-list.d.ts +16 -0
  1143. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-list.d.ts.map +1 -0
  1144. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-list.js +44 -0
  1145. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-list.js.map +1 -0
  1146. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-runs.d.ts +28 -0
  1147. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-runs.d.ts.map +1 -0
  1148. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-runs.js +71 -0
  1149. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-runs.js.map +1 -0
  1150. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-update.d.ts +11 -0
  1151. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-update.d.ts.map +1 -0
  1152. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-update.js +198 -0
  1153. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-update.js.map +1 -0
  1154. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-validate.d.ts +13 -0
  1155. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-validate.d.ts.map +1 -0
  1156. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-validate.js +71 -0
  1157. package/payload/platform/plugins/workflows/mcp/dist/tools/workflow-validate.js.map +1 -0
  1158. package/payload/platform/plugins/workflows/mcp/package.json +20 -0
  1159. package/payload/platform/plugins/workflows/mcp/test-runner.mjs +710 -0
  1160. package/payload/platform/plugins/workflows/mcp/test-workflows.sh +77 -0
  1161. package/payload/platform/plugins/workflows/skills/workflow-manager/SKILL.md +88 -0
  1162. package/payload/platform/scripts/__tests__/admin-persist-audit.test.ts +182 -0
  1163. package/payload/platform/scripts/__tests__/first-token-creates-stream-log.test.sh +37 -0
  1164. package/payload/platform/scripts/__tests__/logs-read-prefix.sh +237 -0
  1165. package/payload/platform/scripts/admin-conversation-recover.mjs +386 -0
  1166. package/payload/platform/scripts/admin-persist-audit.ts +217 -0
  1167. package/payload/platform/scripts/check-no-conversation-id-leaks.mjs +165 -0
  1168. package/payload/platform/scripts/check-no-task-id-leaks.mjs +110 -0
  1169. package/payload/platform/scripts/check-sdk-oauth.mjs +185 -0
  1170. package/payload/platform/scripts/check-skill-load-coverage.mjs +100 -0
  1171. package/payload/platform/scripts/component-knowledgedoc-backfill.ts +214 -0
  1172. package/payload/platform/scripts/conversation-id-allowlist.txt +151 -0
  1173. package/payload/platform/scripts/dedupe-userprofile-ghosts.sh +388 -0
  1174. package/payload/platform/scripts/generate-entitlement-fixture.mjs +152 -0
  1175. package/payload/platform/scripts/installer-device-verify.sh +249 -0
  1176. package/payload/platform/scripts/lib/resolve-account-dir.sh +186 -0
  1177. package/payload/platform/scripts/log-adherence-check.sh +125 -0
  1178. package/payload/platform/scripts/logs-read.sh +577 -0
  1179. package/payload/platform/scripts/logs-read.test.sh +159 -0
  1180. package/payload/platform/scripts/migrate-import.sh +437 -0
  1181. package/payload/platform/scripts/redact-install-logs.sh +87 -0
  1182. package/payload/platform/scripts/resume-tunnel.sh +117 -0
  1183. package/payload/platform/scripts/seed-neo4j.sh +590 -0
  1184. package/payload/platform/scripts/taskmaster-export.sh +388 -0
  1185. package/payload/platform/scripts/test-laptop-vnc-boot.sh +88 -0
  1186. package/payload/platform/scripts/verify-skill-tool-surface.sh +255 -0
  1187. package/payload/platform/scripts/vnc.sh +475 -0
  1188. package/payload/platform/scripts/wifi-provision-server/server.js +743 -0
  1189. package/payload/platform/scripts/wifi-provision.sh +492 -0
  1190. package/payload/platform/services/claude-session-manager/dist/config.d.ts +12 -0
  1191. package/payload/platform/services/claude-session-manager/dist/config.d.ts.map +1 -0
  1192. package/payload/platform/services/claude-session-manager/dist/config.js +27 -0
  1193. package/payload/platform/services/claude-session-manager/dist/config.js.map +1 -0
  1194. package/payload/platform/services/claude-session-manager/dist/http-server.d.ts +10 -0
  1195. package/payload/platform/services/claude-session-manager/dist/http-server.d.ts.map +1 -0
  1196. package/payload/platform/services/claude-session-manager/dist/http-server.js +186 -0
  1197. package/payload/platform/services/claude-session-manager/dist/http-server.js.map +1 -0
  1198. package/payload/platform/services/claude-session-manager/dist/index.d.ts +2 -0
  1199. package/payload/platform/services/claude-session-manager/dist/index.d.ts.map +1 -0
  1200. package/payload/platform/services/claude-session-manager/dist/index.js +64 -0
  1201. package/payload/platform/services/claude-session-manager/dist/index.js.map +1 -0
  1202. package/payload/platform/services/claude-session-manager/dist/jsonl-path.d.ts +4 -0
  1203. package/payload/platform/services/claude-session-manager/dist/jsonl-path.d.ts.map +1 -0
  1204. package/payload/platform/services/claude-session-manager/dist/jsonl-path.js +31 -0
  1205. package/payload/platform/services/claude-session-manager/dist/jsonl-path.js.map +1 -0
  1206. package/payload/platform/services/claude-session-manager/dist/pty-spawner.d.ts +34 -0
  1207. package/payload/platform/services/claude-session-manager/dist/pty-spawner.d.ts.map +1 -0
  1208. package/payload/platform/services/claude-session-manager/dist/pty-spawner.js +91 -0
  1209. package/payload/platform/services/claude-session-manager/dist/pty-spawner.js.map +1 -0
  1210. package/payload/platform/services/claude-session-manager/dist/session-store.d.ts +23 -0
  1211. package/payload/platform/services/claude-session-manager/dist/session-store.d.ts.map +1 -0
  1212. package/payload/platform/services/claude-session-manager/dist/session-store.js +31 -0
  1213. package/payload/platform/services/claude-session-manager/dist/session-store.js.map +1 -0
  1214. package/payload/platform/services/claude-session-manager/dist/types.d.ts +33 -0
  1215. package/payload/platform/services/claude-session-manager/dist/types.d.ts.map +1 -0
  1216. package/payload/platform/services/claude-session-manager/dist/types.js +2 -0
  1217. package/payload/platform/services/claude-session-manager/dist/types.js.map +1 -0
  1218. package/payload/platform/services/claude-session-manager/dist/url-capture.d.ts +12 -0
  1219. package/payload/platform/services/claude-session-manager/dist/url-capture.d.ts.map +1 -0
  1220. package/payload/platform/services/claude-session-manager/dist/url-capture.js +68 -0
  1221. package/payload/platform/services/claude-session-manager/dist/url-capture.js.map +1 -0
  1222. package/payload/platform/services/claude-session-manager/package.json +22 -0
  1223. package/payload/platform/templates/account.json +12 -0
  1224. package/payload/platform/templates/agents/admin/AGENTS.md +12 -0
  1225. package/payload/platform/templates/agents/admin/IDENTITY.md +320 -0
  1226. package/payload/platform/templates/agents/admin/LEARNINGS.md +3 -0
  1227. package/payload/platform/templates/agents/admin/SOUL.md +23 -0
  1228. package/payload/platform/templates/agents/public/IDENTITY.md +56 -0
  1229. package/payload/platform/templates/agents/public/SOUL.md +19 -0
  1230. package/payload/platform/templates/agents/public/config.json +9 -0
  1231. package/payload/platform/templates/specialists/.claude-plugin/plugin.json +4 -0
  1232. package/payload/platform/templates/specialists/agents/content-producer.md +104 -0
  1233. package/payload/platform/templates/specialists/agents/database-operator.md +199 -0
  1234. package/payload/platform/templates/specialists/agents/personal-assistant.md +209 -0
  1235. package/payload/platform/templates/specialists/agents/project-manager.md +132 -0
  1236. package/payload/platform/templates/specialists/agents/research-assistant.md +115 -0
  1237. package/payload/platform/templates/systemd/edge.service.template +38 -0
  1238. package/payload/platform/tsconfig.base.json +18 -0
  1239. package/payload/premium-plugins/real-agency/BUNDLE.md +44 -0
  1240. package/payload/premium-plugins/real-agency/agents/buyer-enquiry/IDENTITY.md +13 -0
  1241. package/payload/premium-plugins/real-agency/agents/buyer-enquiry/SOUL.md +9 -0
  1242. package/payload/premium-plugins/real-agency/agents/buyer-enquiry/template.json +9 -0
  1243. package/payload/premium-plugins/real-agency/agents/compliance.md +303 -0
  1244. package/payload/premium-plugins/real-agency/agents/negotiator.md +145 -0
  1245. package/payload/premium-plugins/real-agency/agents/valuer.md +140 -0
  1246. package/payload/premium-plugins/real-agency/plugins/brochures/PLUGIN.md +36 -0
  1247. package/payload/premium-plugins/real-agency/plugins/brochures/commands/make-brochure.md +11 -0
  1248. package/payload/premium-plugins/real-agency/plugins/brochures/skills/a4-print-documents/SKILL.md +478 -0
  1249. package/payload/premium-plugins/real-agency/plugins/brochures/skills/brand-design/SKILL.md +192 -0
  1250. package/payload/premium-plugins/real-agency/plugins/brochures/skills/make-brochure/SKILL.md +354 -0
  1251. package/payload/premium-plugins/real-agency/plugins/brochures/skills/make-brochure/references/seller-brief-template.md +115 -0
  1252. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/SKILL.md +119 -0
  1253. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/build.md +270 -0
  1254. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/copy.md +211 -0
  1255. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/images.md +166 -0
  1256. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/page-landing.md +376 -0
  1257. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/page.html +1288 -0
  1258. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/placeholders.md +250 -0
  1259. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/registers.md +47 -0
  1260. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/seller-brief.md +56 -0
  1261. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/structure.md +249 -0
  1262. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-brochure/references/template.html +2370 -0
  1263. package/payload/premium-plugins/real-agency/plugins/brochures/skills/property-extract/SKILL.md +372 -0
  1264. package/payload/premium-plugins/real-agency/plugins/buyers/PLUGIN.md +35 -0
  1265. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-feedback/SKILL.md +109 -0
  1266. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/SKILL.md +42 -0
  1267. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/references/buyer-qualification-questions.md +16 -0
  1268. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/references/buyer-qualification.md +59 -0
  1269. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/references/buyer-scripts.md +63 -0
  1270. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/references/buyer-working-scripts.md +54 -0
  1271. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/references/feedback-collection.md +42 -0
  1272. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/references/offer-capture.md +38 -0
  1273. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/references/viewing-booking.md +32 -0
  1274. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-management/references/viewing-management.md +52 -0
  1275. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-seller-guides/SKILL.md +407 -0
  1276. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-seller-guides/references/care-fees-guide.md +68 -0
  1277. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-seller-guides/references/divorce-sales-guide.md +61 -0
  1278. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-seller-guides/references/downsizing-guide.md +45 -0
  1279. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-seller-guides/references/first-time-buyers.md +92 -0
  1280. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-seller-guides/references/first-time-sellers.md +78 -0
  1281. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-seller-guides/references/probate-guide.md +53 -0
  1282. package/payload/premium-plugins/real-agency/plugins/buyers/skills/buyer-seller-guides/references/upsizing-guide.md +41 -0
  1283. package/payload/premium-plugins/real-agency/plugins/buyers/skills/property-enquiry/SKILL.md +126 -0
  1284. package/payload/premium-plugins/real-agency/plugins/buyers/skills/viewing-management/SKILL.md +111 -0
  1285. package/payload/premium-plugins/real-agency/plugins/estate-business/PLUGIN.md +34 -0
  1286. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/SKILL.md +133 -0
  1287. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/buy-back-your-time.md +37 -0
  1288. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/firewave-gost-scorecards.md +14 -0
  1289. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/keller-org-model.md +17 -0
  1290. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/lencioni-team-models.md +22 -0
  1291. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/listing-management-system.md +11 -0
  1292. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/net-figure-form.md +11 -0
  1293. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/serhant-bizinbox-notes.md +13 -0
  1294. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/team-roles-commission.md +14 -0
  1295. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/va-2026-ops.md +43 -0
  1296. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-growth/references/wingman-structure.md +13 -0
  1297. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-operations/SKILL.md +32 -0
  1298. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-operations/references/crm-systems.md +57 -0
  1299. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-operations/references/hiring-guide.md +59 -0
  1300. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-operations/references/impact-framework.md +47 -0
  1301. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-operations/references/minutes-equal-money.md +55 -0
  1302. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/business-operations/references/team-management.md +48 -0
  1303. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/exp-partnership/SKILL.md +52 -0
  1304. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/exp-partnership/references/12-reasons.md +39 -0
  1305. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/exp-partnership/references/95-5-system.md +66 -0
  1306. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/exp-partnership/references/agent-attraction-scripts.md +90 -0
  1307. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/exp-partnership/references/business-partnership.md +92 -0
  1308. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/exp-partnership/references/exp-model-overview.md +66 -0
  1309. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/exp-partnership/references/model-comparison.md +66 -0
  1310. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/exp-partnership/references/revenue-share-explained.md +57 -0
  1311. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/SKILL.md +117 -0
  1312. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/attraction-agent-notes.md +31 -0
  1313. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/attraction-agent.md +58 -0
  1314. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/authenticity-boundaries.md +28 -0
  1315. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/become-a-brand-leader-notes.md +19 -0
  1316. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/blast-formula.md +42 -0
  1317. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/brand-leader.md +48 -0
  1318. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/brand-strategy-system.md +59 -0
  1319. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/content-engine.md +49 -0
  1320. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/firewave-blast-and-blogging.md +23 -0
  1321. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/gary-v-content.md +52 -0
  1322. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/gary-v-principles.md +20 -0
  1323. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/oversubscribed-positioning.md +18 -0
  1324. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/platforms.md +41 -0
  1325. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/priestley-oversubscribed.md +54 -0
  1326. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/storeys-style-examples.md +25 -0
  1327. package/payload/premium-plugins/real-agency/plugins/estate-business/skills/personal-branding/references/visual-identity.md +27 -0
  1328. package/payload/premium-plugins/real-agency/plugins/estate-coaching/PLUGIN.md +55 -0
  1329. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/agent-performance/SKILL.md +371 -0
  1330. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/agent-performance/references/atomic-habits.md +52 -0
  1331. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/agent-performance/references/daily-routine-scorecard.md +104 -0
  1332. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/agent-performance/references/hp6-model.md +63 -0
  1333. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/agent-performance/references/twelve-week-year.md +71 -0
  1334. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/bespoke-coaching/SKILL.md +36 -0
  1335. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/bespoke-coaching/references/coaching-boundaries.md +56 -0
  1336. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/bespoke-coaching/references/feedback-framework.md +61 -0
  1337. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/bespoke-coaching/references/performance-framework.md +109 -0
  1338. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/coaching-toolkit/SKILL.md +421 -0
  1339. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/coaching-toolkit/references/coaching-exercises.md +86 -0
  1340. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/coaching-toolkit/references/goal-setting.md +78 -0
  1341. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/coaching-toolkit/references/one-to-one-framework.md +92 -0
  1342. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/coaching-toolkit/references/soi-workbook.md +103 -0
  1343. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/serhant-training/SKILL.md +410 -0
  1344. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/serhant-training/references/agent-training-guide.md +70 -0
  1345. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/serhant-training/references/business-in-a-box.md +72 -0
  1346. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/serhant-training/references/buyers-guide.md +53 -0
  1347. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/serhant-training/references/codo-method.md +72 -0
  1348. package/payload/premium-plugins/real-agency/plugins/estate-coaching/skills/serhant-training/references/website-planning-guide.md +79 -0
  1349. package/payload/premium-plugins/real-agency/plugins/estate-onboarding/PLUGIN.md +31 -0
  1350. package/payload/premium-plugins/real-agency/plugins/estate-onboarding/skills/bootstrap/SKILL.md +26 -0
  1351. package/payload/premium-plugins/real-agency/plugins/estate-onboarding/skills/bootstrap/references/onboarding-flow.md +63 -0
  1352. package/payload/premium-plugins/real-agency/plugins/estate-sales/PLUGIN.md +34 -0
  1353. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/negotiation/SKILL.md +35 -0
  1354. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/negotiation/references/deal-saving.md +47 -0
  1355. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/negotiation/references/negotiation-deep-guide.md +64 -0
  1356. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/negotiation/references/negotiation-prep-principles.md +29 -0
  1357. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/negotiation/references/negotiation-techniques.md +42 -0
  1358. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/negotiation/references/offer-presentation.md +43 -0
  1359. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-closer/SKILL.md +24 -0
  1360. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-closer/references/serhant-emotion-stages.md +36 -0
  1361. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-discovery/SKILL.md +30 -0
  1362. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-discovery/references/chris-voss-discovery.md +88 -0
  1363. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-discovery/references/firewave-gost-journey.md +68 -0
  1364. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-discovery/references/phil-jones-openers.md +78 -0
  1365. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-discovery/references/pre-listing-checklist.md +77 -0
  1366. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-discovery/references/serhant-improv.md +22 -0
  1367. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-discovery/references/tom-ferry-discovery.md +103 -0
  1368. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-discovery/references/vendor-motivation-competitor.md +52 -0
  1369. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-negotiation/SKILL.md +29 -0
  1370. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-negotiation/references/chris-voss-negotiation.md +70 -0
  1371. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-negotiation/references/phil-jones-price-words.md +40 -0
  1372. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-negotiation/references/serhant-negotiation-plus.md +55 -0
  1373. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-negotiation/references/tom-panos-commission-pricing.md +57 -0
  1374. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-negotiation/references/tony-morris-questioning.md +54 -0
  1375. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-progression/SKILL.md +27 -0
  1376. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-progression/references/conveyancing-guide.md +54 -0
  1377. package/payload/premium-plugins/real-agency/plugins/estate-sales/skills/sales-progression/references/transaction-tracking.md +66 -0
  1378. package/payload/premium-plugins/real-agency/plugins/estate-teaching/PLUGIN.md +31 -0
  1379. package/payload/premium-plugins/real-agency/plugins/estate-teaching/skills/content-directory/SKILL.md +39 -0
  1380. package/payload/premium-plugins/real-agency/plugins/estate-teaching/skills/content-directory/references/module-delivery.md +65 -0
  1381. package/payload/premium-plugins/real-agency/plugins/estate-teaching/skills/content-directory/references/progress-tracking.md +47 -0
  1382. package/payload/premium-plugins/real-agency/plugins/leads/PLUGIN.md +32 -0
  1383. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/SKILL.md +137 -0
  1384. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/buyer-search-letter.md +28 -0
  1385. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/buyer-search-letters.md +37 -0
  1386. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/database-reactivation.md +30 -0
  1387. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/email-nurture-sequences.md +45 -0
  1388. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/facebook-referrals.md +30 -0
  1389. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/firewave-email-nurture-sequences.md +41 -0
  1390. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/keller-33-touch.md +34 -0
  1391. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/neighbour-letters.md +31 -0
  1392. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/neighbour-notification-letter.md +20 -0
  1393. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/ofi-follow-up-dialogue.md +22 -0
  1394. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/ofi-follow-up.md +26 -0
  1395. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/serhant-three-fs-plus.md +21 -0
  1396. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/sharran-10x10x10.md +18 -0
  1397. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/sms-templates.md +40 -0
  1398. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/sphere-of-influence-notes.md +34 -0
  1399. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/sphere-of-influence.md +60 -0
  1400. package/payload/premium-plugins/real-agency/plugins/leads/skills/lead-nurturing/references/tom-panos-sms-templates.md +59 -0
  1401. package/payload/premium-plugins/real-agency/plugins/leads/skills/prospecting/SKILL.md +33 -0
  1402. package/payload/premium-plugins/real-agency/plugins/leads/skills/prospecting/references/database-matching.md +30 -0
  1403. package/payload/premium-plugins/real-agency/plugins/leads/skills/prospecting/references/database-value.md +53 -0
  1404. package/payload/premium-plugins/real-agency/plugins/leads/skills/prospecting/references/prospecting-dialogues.md +24 -0
  1405. package/payload/premium-plugins/real-agency/plugins/leads/skills/prospecting/references/reactivation.md +34 -0
  1406. package/payload/premium-plugins/real-agency/plugins/listings/PLUGIN.md +33 -0
  1407. package/payload/premium-plugins/real-agency/plugins/listings/skills/home-preparation/SKILL.md +28 -0
  1408. package/payload/premium-plugins/real-agency/plugins/listings/skills/home-preparation/references/kerb-appeal.md +38 -0
  1409. package/payload/premium-plugins/real-agency/plugins/listings/skills/home-preparation/references/photo-day.md +59 -0
  1410. package/payload/premium-plugins/real-agency/plugins/listings/skills/home-preparation/references/situational-tips.md +50 -0
  1411. package/payload/premium-plugins/real-agency/plugins/listings/skills/home-preparation/references/staging-guide.md +52 -0
  1412. package/payload/premium-plugins/real-agency/plugins/listings/skills/listing-presentation/SKILL.md +286 -0
  1413. package/payload/premium-plugins/real-agency/plugins/listings/skills/listing-presentation/references/booking-script.md +51 -0
  1414. package/payload/premium-plugins/real-agency/plugins/listings/skills/listing-presentation/references/objection-scripts.md +193 -0
  1415. package/payload/premium-plugins/real-agency/plugins/listings/skills/listing-presentation/references/penhaul-presentation.md +123 -0
  1416. package/payload/premium-plugins/real-agency/plugins/listings/skills/listing-presentation/references/pre-listing-kit.md +139 -0
  1417. package/payload/premium-plugins/real-agency/plugins/listings/skills/listing-presentation/references/set-to-sell.md +55 -0
  1418. package/payload/premium-plugins/real-agency/plugins/listings/skills/listing-presentation/references/sharran-frameworks.md +107 -0
  1419. package/payload/premium-plugins/real-agency/plugins/listings/skills/property-marketing/SKILL.md +337 -0
  1420. package/payload/premium-plugins/real-agency/plugins/listings/skills/property-marketing/references/auction-report-template.md +41 -0
  1421. package/payload/premium-plugins/real-agency/plugins/listings/skills/property-marketing/references/coming-soon-campaign.md +43 -0
  1422. package/payload/premium-plugins/real-agency/plugins/listings/skills/property-marketing/references/direct-mail-templates.md +121 -0
  1423. package/payload/premium-plugins/real-agency/plugins/listings/skills/property-marketing/references/eoi-form-template.md +62 -0
  1424. package/payload/premium-plugins/real-agency/plugins/listings/skills/property-marketing/references/monthly-scorecard.md +63 -0
  1425. package/payload/premium-plugins/real-agency/plugins/loop/PLUGIN.md +73 -0
  1426. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/index.d.ts +2 -0
  1427. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/index.d.ts.map +1 -0
  1428. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/index.js +293 -0
  1429. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/index.js.map +1 -0
  1430. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/crypto.d.ts +10 -0
  1431. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/crypto.d.ts.map +1 -0
  1432. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/crypto.js +88 -0
  1433. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/crypto.js.map +1 -0
  1434. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/loop-api.d.ts +82 -0
  1435. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/loop-api.d.ts.map +1 -0
  1436. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/loop-api.js +427 -0
  1437. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/loop-api.js.map +1 -0
  1438. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/neo4j.d.ts +5 -0
  1439. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/neo4j.d.ts.map +1 -0
  1440. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/neo4j.js +40 -0
  1441. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/lib/neo4j.js.map +1 -0
  1442. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/customer-preferences.d.ts +10 -0
  1443. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/customer-preferences.d.ts.map +1 -0
  1444. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/customer-preferences.js +24 -0
  1445. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/customer-preferences.js.map +1 -0
  1446. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/feedback.d.ts +16 -0
  1447. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/feedback.d.ts.map +1 -0
  1448. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/feedback.js +35 -0
  1449. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/feedback.js.map +1 -0
  1450. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-deregister.d.ts +5 -0
  1451. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-deregister.d.ts.map +1 -0
  1452. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-deregister.js +19 -0
  1453. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-deregister.js.map +1 -0
  1454. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-list.d.ts +4 -0
  1455. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-list.d.ts.map +1 -0
  1456. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-list.js +14 -0
  1457. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-list.js.map +1 -0
  1458. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-register.d.ts +9 -0
  1459. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-register.d.ts.map +1 -0
  1460. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-register.js +60 -0
  1461. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/key-register.js.map +1 -0
  1462. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-enquiry.d.ts +13 -0
  1463. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-enquiry.d.ts.map +1 -0
  1464. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-enquiry.js +41 -0
  1465. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-enquiry.js.map +1 -0
  1466. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match-batch.d.ts +9 -0
  1467. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match-batch.d.ts.map +1 -0
  1468. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match-batch.js +16 -0
  1469. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match-batch.js.map +1 -0
  1470. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match-request.d.ts +15 -0
  1471. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match-request.d.ts.map +1 -0
  1472. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match-request.js +11 -0
  1473. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match-request.js.map +1 -0
  1474. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match.d.ts +10 -0
  1475. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match.d.ts.map +1 -0
  1476. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match.js +39 -0
  1477. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/marketing-match.js.map +1 -0
  1478. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/people-detail.d.ts +9 -0
  1479. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/people-detail.d.ts.map +1 -0
  1480. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/people-detail.js +125 -0
  1481. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/people-detail.js.map +1 -0
  1482. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/people-search.d.ts +18 -0
  1483. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/people-search.d.ts.map +1 -0
  1484. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/people-search.js +87 -0
  1485. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/people-search.js.map +1 -0
  1486. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-detail.d.ts +10 -0
  1487. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-detail.d.ts.map +1 -0
  1488. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-detail.js +82 -0
  1489. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-detail.js.map +1 -0
  1490. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-listed.d.ts +12 -0
  1491. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-listed.d.ts.map +1 -0
  1492. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-listed.js +32 -0
  1493. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-listed.js.map +1 -0
  1494. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-request.d.ts +15 -0
  1495. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-request.d.ts.map +1 -0
  1496. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-request.js +11 -0
  1497. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-request.js.map +1 -0
  1498. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-search.d.ts +16 -0
  1499. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-search.d.ts.map +1 -0
  1500. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-search.js +41 -0
  1501. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/property-search.js.map +1 -0
  1502. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/supplier.d.ts +13 -0
  1503. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/supplier.d.ts.map +1 -0
  1504. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/supplier.js +49 -0
  1505. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/supplier.js.map +1 -0
  1506. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/team-availability.d.ts +7 -0
  1507. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/team-availability.d.ts.map +1 -0
  1508. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/team-availability.js +19 -0
  1509. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/team-availability.js.map +1 -0
  1510. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/team-info.d.ts +5 -0
  1511. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/team-info.d.ts.map +1 -0
  1512. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/team-info.js +32 -0
  1513. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/team-info.js.map +1 -0
  1514. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-create.d.ts +14 -0
  1515. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-create.d.ts.map +1 -0
  1516. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-create.js +11 -0
  1517. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-create.js.map +1 -0
  1518. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-detail.d.ts +9 -0
  1519. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-detail.d.ts.map +1 -0
  1520. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-detail.js +85 -0
  1521. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-detail.js.map +1 -0
  1522. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-search.d.ts +13 -0
  1523. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-search.d.ts.map +1 -0
  1524. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-search.js +44 -0
  1525. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-search.js.map +1 -0
  1526. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-update.d.ts +14 -0
  1527. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-update.d.ts.map +1 -0
  1528. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-update.js +18 -0
  1529. package/payload/premium-plugins/real-agency/plugins/loop/mcp/dist/tools/viewing-update.js.map +1 -0
  1530. package/payload/premium-plugins/real-agency/plugins/loop/mcp/package-lock.json +2549 -0
  1531. package/payload/premium-plugins/real-agency/plugins/loop/mcp/package.json +21 -0
  1532. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/__tests__/loop-swagger.snapshot.json +26467 -0
  1533. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/__tests__/swagger-write-coverage.test.ts +153 -0
  1534. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/index.ts +444 -0
  1535. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/lib/crypto.ts +105 -0
  1536. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/lib/loop-api.ts +604 -0
  1537. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/lib/neo4j.ts +51 -0
  1538. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/customer-preferences.ts +66 -0
  1539. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/feedback.ts +86 -0
  1540. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/key-deregister.ts +27 -0
  1541. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/key-list.ts +19 -0
  1542. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/key-register.ts +95 -0
  1543. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/marketing-enquiry.ts +113 -0
  1544. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/marketing-match-batch.ts +53 -0
  1545. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/marketing-match-request.ts +42 -0
  1546. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/marketing-match.ts +84 -0
  1547. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/people-detail.ts +245 -0
  1548. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/people-search.ts +180 -0
  1549. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/property-detail.ts +145 -0
  1550. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/property-listed.ts +88 -0
  1551. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/property-request.ts +42 -0
  1552. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/property-search.ts +92 -0
  1553. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/supplier.ts +129 -0
  1554. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/team-availability.ts +52 -0
  1555. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/team-info.ts +95 -0
  1556. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/viewing-create.ts +41 -0
  1557. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/viewing-detail.ts +171 -0
  1558. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/viewing-search.ts +92 -0
  1559. package/payload/premium-plugins/real-agency/plugins/loop/mcp/src/tools/viewing-update.ts +53 -0
  1560. package/payload/premium-plugins/real-agency/plugins/loop/mcp/tsconfig.json +20 -0
  1561. package/payload/premium-plugins/real-agency/plugins/loop/mcp/vitest.config.ts +9 -0
  1562. package/payload/premium-plugins/real-agency/plugins/vendors/PLUGIN.md +34 -0
  1563. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/SKILL.md +42 -0
  1564. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/fee-protection-and-agenda.md +28 -0
  1565. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/listing-scripts.md +44 -0
  1566. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/negotiation-deep-guide.md +70 -0
  1567. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/price-alignment-scripts.md +33 -0
  1568. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/price-alignment.md +34 -0
  1569. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/scenario-scripts.md +38 -0
  1570. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/seller-engagement.md +51 -0
  1571. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/valuation-booking.md +76 -0
  1572. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/vendor-scripts.md +63 -0
  1573. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-communication/references/vendor-updates.md +41 -0
  1574. package/payload/premium-plugins/real-agency/plugins/vendors/skills/vendor-updates/SKILL.md +153 -0
  1575. package/payload/premium-plugins/teaching/PLUGIN.md +57 -0
  1576. package/payload/premium-plugins/teaching/skills/interactive-tutor/SKILL.md +59 -0
  1577. package/payload/premium-plugins/teaching/skills/interactive-tutor/references/assessment.md +70 -0
  1578. package/payload/premium-plugins/teaching/skills/interactive-tutor/references/classroom-conduct.md +43 -0
  1579. package/payload/premium-plugins/teaching/skills/interactive-tutor/references/teaching-modes.md +83 -0
  1580. package/payload/premium-plugins/teaching/skills/lesson-planner/SKILL.md +48 -0
  1581. package/payload/premium-plugins/teaching/skills/lesson-planner/references/context-gathering.md +41 -0
  1582. package/payload/premium-plugins/teaching/skills/lesson-planner/references/plan-structure.md +94 -0
  1583. package/payload/premium-plugins/teaching/skills/study-pack-builder/SKILL.md +52 -0
  1584. package/payload/premium-plugins/teaching/skills/study-pack-builder/references/disaggregation.md +49 -0
  1585. package/payload/premium-plugins/teaching/skills/study-pack-builder/references/materials.md +116 -0
  1586. package/payload/premium-plugins/writer-craft/PLUGIN.md +87 -0
  1587. package/payload/premium-plugins/writer-craft/agents/writer-craft--manuscript-reviewer.md +92 -0
  1588. package/payload/premium-plugins/writer-craft/skills/citation-style/SKILL.md +94 -0
  1589. package/payload/premium-plugins/writer-craft/skills/citation-style/references/book-and-chapter-models.md +77 -0
  1590. package/payload/premium-plugins/writer-craft/skills/citation-style/references/citation-rules.md +103 -0
  1591. package/payload/premium-plugins/writer-craft/skills/citation-style/references/journal-article-models.md +74 -0
  1592. package/payload/premium-plugins/writer-craft/skills/citation-style/references/other-source-models.md +146 -0
  1593. package/payload/premium-plugins/writer-craft/skills/citation-style/references/reference-list-rules.md +70 -0
  1594. package/payload/premium-plugins/writer-craft/skills/editorial-practice/SKILL.md +108 -0
  1595. package/payload/premium-plugins/writer-craft/skills/editorial-practice/references/copyediting.md +73 -0
  1596. package/payload/premium-plugins/writer-craft/skills/editorial-practice/references/developmental-editing.md +85 -0
  1597. package/payload/premium-plugins/writer-craft/skills/editorial-practice/references/genre-specific-editing.md +78 -0
  1598. package/payload/premium-plugins/writer-craft/skills/editorial-practice/references/line-editing.md +55 -0
  1599. package/payload/premium-plugins/writer-craft/skills/editorial-practice/references/self-editing.md +89 -0
  1600. package/payload/premium-plugins/writer-craft/skills/persuasive-storytelling/SKILL.md +114 -0
  1601. package/payload/premium-plugins/writer-craft/skills/persuasive-storytelling/references/audience-analysis.md +73 -0
  1602. package/payload/premium-plugins/writer-craft/skills/persuasive-storytelling/references/crafting-persuasive-story.md +76 -0
  1603. package/payload/premium-plugins/writer-craft/skills/persuasive-storytelling/references/persuasion-case-studies.md +67 -0
  1604. package/payload/premium-plugins/writer-craft/skills/persuasive-storytelling/references/transformation-framework.md +86 -0
  1605. package/payload/premium-plugins/writer-craft/skills/point-of-view/SKILL.md +97 -0
  1606. package/payload/premium-plugins/writer-craft/skills/point-of-view/references/indirect-narration.md +72 -0
  1607. package/payload/premium-plugins/writer-craft/skills/point-of-view/references/pov-types-and-voice.md +91 -0
  1608. package/payload/premium-plugins/writer-craft/skills/point-of-view/references/protagonist-filter.md +71 -0
  1609. package/payload/premium-plugins/writer-craft/skills/point-of-view/references/tense-and-person.md +85 -0
  1610. package/payload/premium-plugins/writer-craft/skills/prose-craft/SKILL.md +100 -0
  1611. package/payload/premium-plugins/writer-craft/skills/prose-craft/references/punctuation-and-grammar.md +72 -0
  1612. package/payload/premium-plugins/writer-craft/skills/prose-craft/references/repetition.md +71 -0
  1613. package/payload/premium-plugins/writer-craft/skills/prose-craft/references/sound-and-rhythm.md +64 -0
  1614. package/payload/premium-plugins/writer-craft/skills/prose-craft/references/word-economy.md +93 -0
  1615. package/payload/premium-plugins/writer-craft/skills/reader-engagement/SKILL.md +100 -0
  1616. package/payload/premium-plugins/writer-craft/skills/reader-engagement/references/cause-effect-setup-payoff.md +79 -0
  1617. package/payload/premium-plugins/writer-craft/skills/reader-engagement/references/conflict-escalation.md +81 -0
  1618. package/payload/premium-plugins/writer-craft/skills/reader-engagement/references/hooking-readers.md +67 -0
  1619. package/payload/premium-plugins/writer-craft/skills/reader-engagement/references/neurochemistry-of-engagement.md +94 -0
  1620. package/payload/premium-plugins/writer-craft/skills/review-manuscript/SKILL.md +111 -0
  1621. package/payload/premium-plugins/writer-craft/skills/review-manuscript/references/review-manuscript-checklist.md +119 -0
  1622. package/payload/premium-plugins/writer-craft/skills/review-prose/SKILL.md +99 -0
  1623. package/payload/premium-plugins/writer-craft/skills/review-prose/references/prose-review-checklist.md +112 -0
  1624. package/payload/premium-plugins/writer-craft/skills/review-scene/SKILL.md +99 -0
  1625. package/payload/premium-plugins/writer-craft/skills/review-scene/references/scene-analysis-framework.md +95 -0
  1626. package/payload/premium-plugins/writer-craft/skills/story-architecture/SKILL.md +106 -0
  1627. package/payload/premium-plugins/writer-craft/skills/story-architecture/references/blueprinting-and-scene-cards.md +118 -0
  1628. package/payload/premium-plugins/writer-craft/skills/story-architecture/references/inner-issue-and-protagonist-goal.md +66 -0
  1629. package/payload/premium-plugins/writer-craft/skills/story-architecture/references/misbelief-desire-worldview.md +87 -0
  1630. package/payload/premium-plugins/writer-craft/skills/story-architecture/references/origin-scenes-and-escalation.md +82 -0
  1631. package/payload/premium-plugins/writer-craft/skills/story-blueprint/SKILL.md +133 -0
  1632. package/payload/premium-plugins/writer-craft/skills/story-blueprint/references/blueprinting-exercises.md +118 -0
  1633. package/payload/premium-plugins/writer-craft/skills/story-blueprint/references/blueprinting-process.md +128 -0
  1634. package/payload/server/adminuser-self-heal-QAWOZ3JV.js +45 -0
  1635. package/payload/server/chunk-5FM432JB.js +4148 -0
  1636. package/payload/server/chunk-6S5JTXAN.js +1544 -0
  1637. package/payload/server/chunk-JSBRDJBE.js +30 -0
  1638. package/payload/server/chunk-RNW625CL.js +759 -0
  1639. package/payload/server/cloudflare-task-tracker-VC7QVU5H.js +22 -0
  1640. package/payload/server/maxy-edge.js +1021 -0
  1641. package/payload/server/package.json +13 -0
  1642. package/payload/server/public/assets/Checkbox-C6ZCsPvl.js +1 -0
  1643. package/payload/server/public/assets/_baseFor-BHtDrjIo.js +1 -0
  1644. package/payload/server/public/assets/admin-CWMpccrR.css +1 -0
  1645. package/payload/server/public/assets/admin-DVGJmN-k.js +216 -0
  1646. package/payload/server/public/assets/arc-DMDAZHAN.js +1 -0
  1647. package/payload/server/public/assets/architecture-YZFGNWBL-COhEvUpo.js +1 -0
  1648. package/payload/server/public/assets/architectureDiagram-Q4EWVU46-DwN6H0y2.js +36 -0
  1649. package/payload/server/public/assets/array-DetWRiSa.js +1 -0
  1650. package/payload/server/public/assets/blockDiagram-DXYQGD6D-TUk_F7H6.js +132 -0
  1651. package/payload/server/public/assets/c4Diagram-AHTNJAMY-CTjGko0X.js +10 -0
  1652. package/payload/server/public/assets/channel-Cv-65bLZ.js +1 -0
  1653. package/payload/server/public/assets/chunk-2KRD3SAO-Di4bO8ir.js +1 -0
  1654. package/payload/server/public/assets/chunk-336JU56O-DulT46bV.js +2 -0
  1655. package/payload/server/public/assets/chunk-426QAEUC-BwKj8yqp.js +1 -0
  1656. package/payload/server/public/assets/chunk-4BX2VUAB-DyEhFk-Z.js +1 -0
  1657. package/payload/server/public/assets/chunk-4TB4RGXK-CewO8YaZ.js +206 -0
  1658. package/payload/server/public/assets/chunk-55IACEB6-BRJOZLpU.js +1 -0
  1659. package/payload/server/public/assets/chunk-5FUZZQ4R-B3IWYz-k.js +62 -0
  1660. package/payload/server/public/assets/chunk-5PVQY5BW-DyiDEtXY.js +2 -0
  1661. package/payload/server/public/assets/chunk-67CJDMHE-BG6-9r6c.js +1 -0
  1662. package/payload/server/public/assets/chunk-7N4EOEYR-BvMbitX7.js +1 -0
  1663. package/payload/server/public/assets/chunk-AA7GKIK3-CE8mGBD5.js +1 -0
  1664. package/payload/server/public/assets/chunk-BSJP7CBP-DP7LTBll.js +1 -0
  1665. package/payload/server/public/assets/chunk-CIAEETIT-VfnIdN-h.js +1 -0
  1666. package/payload/server/public/assets/chunk-DD-I1_y5.js +1 -0
  1667. package/payload/server/public/assets/chunk-EDXVE4YY-B3u7wU36.js +1 -0
  1668. package/payload/server/public/assets/chunk-ENJZ2VHE-BesS5YY4.js +10 -0
  1669. package/payload/server/public/assets/chunk-FMBD7UC4-w-yBZsN2.js +15 -0
  1670. package/payload/server/public/assets/chunk-FOC6F5B3-f9cFywhd.js +1 -0
  1671. package/payload/server/public/assets/chunk-ICPOFSXX-C5_hbB6H.js +122 -0
  1672. package/payload/server/public/assets/chunk-K5T4RW27-B_ZUrFUq.js +94 -0
  1673. package/payload/server/public/assets/chunk-KGLVRYIC-CcWTvRlI.js +1 -0
  1674. package/payload/server/public/assets/chunk-LIHQZDEY-D-5-peQw.js +1 -0
  1675. package/payload/server/public/assets/chunk-ORNJ4GCN-B4Z5L25I.js +1 -0
  1676. package/payload/server/public/assets/chunk-OYMX7WX6-CrL4rhBa.js +231 -0
  1677. package/payload/server/public/assets/chunk-QZHKN3VN-CWh_0JsP.js +1 -0
  1678. package/payload/server/public/assets/chunk-U2HBQHQK-CQpbcqRS.js +70 -0
  1679. package/payload/server/public/assets/chunk-X2U36JSP-1HG7T4gX.js +1 -0
  1680. package/payload/server/public/assets/chunk-XPW4576I-m1Y_r88I.js +32 -0
  1681. package/payload/server/public/assets/chunk-YZCP3GAM-boN5wjX9.js +1 -0
  1682. package/payload/server/public/assets/chunk-ZZ45TVLE-D6CiPO0Q.js +1 -0
  1683. package/payload/server/public/assets/classDiagram-6PBFFD2Q-wQ2-BRyB.js +1 -0
  1684. package/payload/server/public/assets/classDiagram-v2-HSJHXN6E-B_YLNNHy.js +1 -0
  1685. package/payload/server/public/assets/clone-VLK-GPZZ.js +1 -0
  1686. package/payload/server/public/assets/cormorant-cyrillic-300-normal-CzPHYadL.woff +0 -0
  1687. package/payload/server/public/assets/cormorant-cyrillic-300-normal-DFUoTmrg.woff2 +0 -0
  1688. package/payload/server/public/assets/cormorant-cyrillic-400-normal-C8QS47vb.woff2 +0 -0
  1689. package/payload/server/public/assets/cormorant-cyrillic-400-normal-D3EsxgFc.woff +0 -0
  1690. package/payload/server/public/assets/cormorant-cyrillic-500-normal-B7dJQtg-.woff +0 -0
  1691. package/payload/server/public/assets/cormorant-cyrillic-500-normal-BLlg2W5x.woff2 +0 -0
  1692. package/payload/server/public/assets/cormorant-cyrillic-ext-300-normal-BXl3lXsi.woff2 +0 -0
  1693. package/payload/server/public/assets/cormorant-cyrillic-ext-300-normal-DmxSOTe3.woff +0 -0
  1694. package/payload/server/public/assets/cormorant-cyrillic-ext-400-normal-Bgrpe4p1.woff +0 -0
  1695. package/payload/server/public/assets/cormorant-cyrillic-ext-400-normal-BlcaxZtM.woff2 +0 -0
  1696. package/payload/server/public/assets/cormorant-cyrillic-ext-500-normal-CdQuyvtc.woff +0 -0
  1697. package/payload/server/public/assets/cormorant-cyrillic-ext-500-normal-pZw22qtS.woff2 +0 -0
  1698. package/payload/server/public/assets/cormorant-latin-300-normal-CJ5dfen0.woff2 +0 -0
  1699. package/payload/server/public/assets/cormorant-latin-300-normal-DQZObO_3.woff +0 -0
  1700. package/payload/server/public/assets/cormorant-latin-400-normal-BGH8Vunh.woff2 +0 -0
  1701. package/payload/server/public/assets/cormorant-latin-400-normal-C3_-2Ua-.woff +0 -0
  1702. package/payload/server/public/assets/cormorant-latin-500-normal-Dj3SQ6fR.woff +0 -0
  1703. package/payload/server/public/assets/cormorant-latin-500-normal-EBdSCOD3.woff2 +0 -0
  1704. package/payload/server/public/assets/cormorant-latin-ext-300-normal-CkiUx0UG.woff +0 -0
  1705. package/payload/server/public/assets/cormorant-latin-ext-300-normal-De3D72RL.woff2 +0 -0
  1706. package/payload/server/public/assets/cormorant-latin-ext-400-normal-DuQ88yz3.woff2 +0 -0
  1707. package/payload/server/public/assets/cormorant-latin-ext-400-normal-DuXFa1Dr.woff +0 -0
  1708. package/payload/server/public/assets/cormorant-latin-ext-500-normal-AH9qog1s.woff2 +0 -0
  1709. package/payload/server/public/assets/cormorant-latin-ext-500-normal-DAuUCO41.woff +0 -0
  1710. package/payload/server/public/assets/cormorant-vietnamese-300-normal-BVqIp_mg.woff2 +0 -0
  1711. package/payload/server/public/assets/cormorant-vietnamese-300-normal-CEMS9Pw-.woff +0 -0
  1712. package/payload/server/public/assets/cormorant-vietnamese-400-normal-C-RiYxEf.woff2 +0 -0
  1713. package/payload/server/public/assets/cormorant-vietnamese-400-normal-DmUuA7Y2.woff +0 -0
  1714. package/payload/server/public/assets/cormorant-vietnamese-500-normal-DsPuwQHi.woff2 +0 -0
  1715. package/payload/server/public/assets/cormorant-vietnamese-500-normal-tGBW_mI7.woff +0 -0
  1716. package/payload/server/public/assets/cose-bilkent-S5V4N54A-BhtgY3T7.js +1 -0
  1717. package/payload/server/public/assets/cytoscape.esm-C9yNhe1u.js +321 -0
  1718. package/payload/server/public/assets/dagre-CncXYNX1.js +1 -0
  1719. package/payload/server/public/assets/dagre-KV5264BT-C0CcgCHW.js +4 -0
  1720. package/payload/server/public/assets/data-Bt4Wsocg.js +1 -0
  1721. package/payload/server/public/assets/defaultLocale-_WRwicXn.js +1 -0
  1722. package/payload/server/public/assets/diagram-5BDNPKRD-CkUlWbsI.js +10 -0
  1723. package/payload/server/public/assets/diagram-G4DWMVQ6-DVZBG1Ul.js +24 -0
  1724. package/payload/server/public/assets/diagram-MMDJMWI5-BIb06ZkK.js +43 -0
  1725. package/payload/server/public/assets/diagram-TYMM5635-BcT0_WR8.js +24 -0
  1726. package/payload/server/public/assets/dist-Bd4S37oi.js +1 -0
  1727. package/payload/server/public/assets/dm-sans-latin-400-normal-BwCSEQnW.woff +0 -0
  1728. package/payload/server/public/assets/dm-sans-latin-400-normal-CW0RaeGs.woff2 +0 -0
  1729. package/payload/server/public/assets/dm-sans-latin-500-normal-B9HHJjqV.woff2 +0 -0
  1730. package/payload/server/public/assets/dm-sans-latin-500-normal-Dr3UlScf.woff +0 -0
  1731. package/payload/server/public/assets/dm-sans-latin-ext-400-normal-BjWJ59Pq.woff +0 -0
  1732. package/payload/server/public/assets/dm-sans-latin-ext-400-normal-BtiwyxMk.woff2 +0 -0
  1733. package/payload/server/public/assets/dm-sans-latin-ext-500-normal-BJfUCQsA.woff2 +0 -0
  1734. package/payload/server/public/assets/dm-sans-latin-ext-500-normal-DR84L5F-.woff +0 -0
  1735. package/payload/server/public/assets/erDiagram-SMLLAGMA-BHk6lxIT.js +85 -0
  1736. package/payload/server/public/assets/flatten-BsWEYbBB.js +1 -0
  1737. package/payload/server/public/assets/flowDiagram-DWJPFMVM-CjeJn490.js +162 -0
  1738. package/payload/server/public/assets/ganttDiagram-T4ZO3ILL-BGYvX3Lv.js +292 -0
  1739. package/payload/server/public/assets/gitGraph-7Q5UKJZL-DeTNsAO0.js +1 -0
  1740. package/payload/server/public/assets/gitGraphDiagram-UUTBAWPF-Br4WLGzW.js +106 -0
  1741. package/payload/server/public/assets/graph-CRSLozxc.js +1 -0
  1742. package/payload/server/public/assets/graph-labels-CQyZQ0u6.js +1 -0
  1743. package/payload/server/public/assets/graphlib-BWd9sMeP.js +1 -0
  1744. package/payload/server/public/assets/info-OMHHGYJF-DJJ9GlS6.js +1 -0
  1745. package/payload/server/public/assets/infoDiagram-42DDH7IO-BjZeQoNZ.js +2 -0
  1746. package/payload/server/public/assets/init-sTEcj9YX.js +1 -0
  1747. package/payload/server/public/assets/isEmpty-BWl67LAZ.js +1 -0
  1748. package/payload/server/public/assets/ishikawaDiagram-UXIWVN3A-POMae6Ni.js +70 -0
  1749. package/payload/server/public/assets/jetbrains-mono-cyrillic-400-normal-BEIGL1Tu.woff2 +0 -0
  1750. package/payload/server/public/assets/jetbrains-mono-cyrillic-400-normal-ugxPyKxw.woff +0 -0
  1751. package/payload/server/public/assets/jetbrains-mono-cyrillic-500-normal-DJqRU3vO.woff +0 -0
  1752. package/payload/server/public/assets/jetbrains-mono-cyrillic-500-normal-DmUKJPL_.woff2 +0 -0
  1753. package/payload/server/public/assets/jetbrains-mono-greek-400-normal-B9oWc5Lo.woff +0 -0
  1754. package/payload/server/public/assets/jetbrains-mono-greek-400-normal-C190GLew.woff2 +0 -0
  1755. package/payload/server/public/assets/jetbrains-mono-greek-500-normal-D7SFKleX.woff +0 -0
  1756. package/payload/server/public/assets/jetbrains-mono-greek-500-normal-JpySY46c.woff2 +0 -0
  1757. package/payload/server/public/assets/jetbrains-mono-latin-400-normal-6-qcROiO.woff +0 -0
  1758. package/payload/server/public/assets/jetbrains-mono-latin-400-normal-V6pRDFza.woff2 +0 -0
  1759. package/payload/server/public/assets/jetbrains-mono-latin-500-normal-BWZEU5yA.woff2 +0 -0
  1760. package/payload/server/public/assets/jetbrains-mono-latin-500-normal-CJOVTJB7.woff +0 -0
  1761. package/payload/server/public/assets/jetbrains-mono-latin-ext-400-normal-Bc8Ftmh3.woff2 +0 -0
  1762. package/payload/server/public/assets/jetbrains-mono-latin-ext-400-normal-fXTG6kC5.woff +0 -0
  1763. package/payload/server/public/assets/jetbrains-mono-latin-ext-500-normal-Cut-4mMH.woff2 +0 -0
  1764. package/payload/server/public/assets/jetbrains-mono-latin-ext-500-normal-ckzbgY84.woff +0 -0
  1765. package/payload/server/public/assets/jetbrains-mono-vietnamese-400-normal-CqNFfHCs.woff +0 -0
  1766. package/payload/server/public/assets/jetbrains-mono-vietnamese-500-normal-DNRqzVM1.woff +0 -0
  1767. package/payload/server/public/assets/journeyDiagram-VCZTEJTY-ledtLV6x.js +139 -0
  1768. package/payload/server/public/assets/jsx-runtime-DvanDPKm.css +1 -0
  1769. package/payload/server/public/assets/jsx-runtime-vPsBTwUp.js +9 -0
  1770. package/payload/server/public/assets/kanban-definition-6JOO6SKY-DI0T4W9z.js +89 -0
  1771. package/payload/server/public/assets/katex-s61Rgv6l.js +257 -0
  1772. package/payload/server/public/assets/lib-W5Jcz4p8.js +33 -0
  1773. package/payload/server/public/assets/line-D1281H12.js +1 -0
  1774. package/payload/server/public/assets/linear-0O14Y6uf.js +1 -0
  1775. package/payload/server/public/assets/mermaid-parser.core-Dt95U7zk.js +4 -0
  1776. package/payload/server/public/assets/mermaid.core-BuYSs1fU.js +11 -0
  1777. package/payload/server/public/assets/mindmap-definition-QFDTVHPH-CFE1lmfX.js +96 -0
  1778. package/payload/server/public/assets/ordinal-krseTxxN.js +1 -0
  1779. package/payload/server/public/assets/packet-4T2RLAQJ-CGbvGkvF.js +1 -0
  1780. package/payload/server/public/assets/page-CSUcuVW0.js +1 -0
  1781. package/payload/server/public/assets/page-TARBO-Yr.js +50 -0
  1782. package/payload/server/public/assets/path-B0Ik7Tu9.js +1 -0
  1783. package/payload/server/public/assets/pie-ZZUOXDRM-BZy8rjFn.js +1 -0
  1784. package/payload/server/public/assets/pieDiagram-DEJITSTG-BSd9xa7v.js +30 -0
  1785. package/payload/server/public/assets/public-5r6aRXrb.js +8 -0
  1786. package/payload/server/public/assets/quadrantDiagram-34T5L4WZ-xYehPVw5.js +7 -0
  1787. package/payload/server/public/assets/radar-PYXPWWZC-DcfWIVXr.js +1 -0
  1788. package/payload/server/public/assets/reduce-tk-xY6Fv.js +1 -0
  1789. package/payload/server/public/assets/requirementDiagram-MS252O5E-C6n77V1S.js +84 -0
  1790. package/payload/server/public/assets/rough.esm-DKRO8IF-.js +1 -0
  1791. package/payload/server/public/assets/sankeyDiagram-XADWPNL6-CWIfeO1M.js +10 -0
  1792. package/payload/server/public/assets/sequenceDiagram-FGHM5R23-DDv2DuMo.js +157 -0
  1793. package/payload/server/public/assets/src-B6XdH6xq.js +1 -0
  1794. package/payload/server/public/assets/stateDiagram-FHFEXIEX-BPZdmsww.js +1 -0
  1795. package/payload/server/public/assets/stateDiagram-v2-QKLJ7IA2-33eC4TwE.js +1 -0
  1796. package/payload/server/public/assets/timeline-definition-GMOUNBTQ-BpRT_wSX.js +120 -0
  1797. package/payload/server/public/assets/treeView-SZITEDCU-3WugwVdj.js +1 -0
  1798. package/payload/server/public/assets/treemap-W4RFUUIX-Cf5mDLlu.js +1 -0
  1799. package/payload/server/public/assets/vennDiagram-DHZGUBPP-BG8ubucH.js +34 -0
  1800. package/payload/server/public/assets/wardley-RL74JXVD-Bv4md4b3.js +1 -0
  1801. package/payload/server/public/assets/wardleyDiagram-NUSXRM2D-D4E7PU1B.js +20 -0
  1802. package/payload/server/public/assets/xychartDiagram-5P7HB3ND-Ur2xVM-c.js +7 -0
  1803. package/payload/server/public/brand/claude.png +0 -0
  1804. package/payload/server/public/brand/favicon.ico +0 -0
  1805. package/payload/server/public/brand/maxy-black.png +0 -0
  1806. package/payload/server/public/brand/maxy-horizontal.png +0 -0
  1807. package/payload/server/public/brand/maxy-monochrome.png +0 -0
  1808. package/payload/server/public/brand/maxy-square.png +0 -0
  1809. package/payload/server/public/brand/maxy.png +0 -0
  1810. package/payload/server/public/brand/star.png +0 -0
  1811. package/payload/server/public/brand-constants.json +8 -0
  1812. package/payload/server/public/brand-defaults.css +12 -0
  1813. package/payload/server/public/data.html +18 -0
  1814. package/payload/server/public/favicon.ico +0 -0
  1815. package/payload/server/public/graph.html +19 -0
  1816. package/payload/server/public/index.html +23 -0
  1817. package/payload/server/public/public.html +19 -0
  1818. package/payload/server/public/robots.txt +5 -0
  1819. package/payload/server/public/vnc-popout.html +63 -0
  1820. package/payload/server/server-init.cjs +115 -0
  1821. package/payload/server/server.js +14960 -0
@@ -0,0 +1 @@
1
+ var e=Math.PI,t=2*e,n=1e-6,r=t-n;function i(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function a(e){let t=Math.floor(e);if(!(t>=0))throw Error(`invalid digits: ${e}`);if(t>15)return i;let n=10**t;return function(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=Math.round(arguments[t]*n)/n+e[t]}}var o=class{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._=``,this._append=e==null?i:a(e)}moveTo(e,t){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,t){this._append`L${this._x1=+e},${this._y1=+t}`}quadraticCurveTo(e,t,n,r){this._append`Q${+e},${+t},${this._x1=+n},${this._y1=+r}`}bezierCurveTo(e,t,n,r,i,a){this._append`C${+e},${+t},${+n},${+r},${this._x1=+i},${this._y1=+a}`}arcTo(t,r,i,a,o){if(t=+t,r=+r,i=+i,a=+a,o=+o,o<0)throw Error(`negative radius: ${o}`);let s=this._x1,c=this._y1,l=i-t,u=a-r,d=s-t,f=c-r,p=d*d+f*f;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(p>n)if(!(Math.abs(f*l-u*d)>n)||!o)this._append`L${this._x1=t},${this._y1=r}`;else{let m=i-s,h=a-c,g=l*l+u*u,_=m*m+h*h,v=Math.sqrt(g),y=Math.sqrt(p),b=o*Math.tan((e-Math.acos((g+p-_)/(2*v*y)))/2),x=b/y,S=b/v;Math.abs(x-1)>n&&this._append`L${t+x*d},${r+x*f}`,this._append`A${o},${o},0,0,${+(f*m>d*h)},${this._x1=t+S*l},${this._y1=r+S*u}`}}arc(i,a,o,s,c,l){if(i=+i,a=+a,o=+o,l=!!l,o<0)throw Error(`negative radius: ${o}`);let u=o*Math.cos(s),d=o*Math.sin(s),f=i+u,p=a+d,m=1^l,h=l?s-c:c-s;this._x1===null?this._append`M${f},${p}`:(Math.abs(this._x1-f)>n||Math.abs(this._y1-p)>n)&&this._append`L${f},${p}`,o&&(h<0&&(h=h%t+t),h>r?this._append`A${o},${o},0,1,${m},${i-u},${a-d}A${o},${o},0,1,${m},${this._x1=f},${this._y1=p}`:h>n&&this._append`A${o},${o},0,${+(h>=e)},${m},${this._x1=i+o*Math.cos(c)},${this._y1=a+o*Math.sin(c)}`)}rect(e,t,n,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}};function s(){return new o}s.prototype=o.prototype;function c(e){return function(){return e}}function l(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{let e=Math.floor(n);if(!(e>=0))throw RangeError(`invalid digits: ${n}`);t=e}return e},()=>new o(t)}export{c as n,l as t};
@@ -0,0 +1 @@
1
+ import"./chunk-K5T4RW27-B_ZUrFUq.js";import{n as e}from"./chunk-AA7GKIK3-CE8mGBD5.js";export{e as createPieServices};
@@ -0,0 +1,30 @@
1
+ import"./chunk-K5T4RW27-B_ZUrFUq.js";import"./chunk-7N4EOEYR-BvMbitX7.js";import"./chunk-67CJDMHE-BG6-9r6c.js";import"./chunk-KGLVRYIC-CcWTvRlI.js";import"./chunk-FOC6F5B3-f9cFywhd.js";import"./chunk-AA7GKIK3-CE8mGBD5.js";import"./chunk-2KRD3SAO-Di4bO8ir.js";import"./chunk-ORNJ4GCN-B4Z5L25I.js";import"./chunk-LIHQZDEY-D-5-peQw.js";import"./chunk-CIAEETIT-VfnIdN-h.js";import{g as e,h as t}from"./src-B6XdH6xq.js";import{B as n,C as r,V as i,W as a,_ as o,a as s,b as c,c as l,d as u,v as d}from"./chunk-ICPOFSXX-C5_hbB6H.js";import{t as f}from"./ordinal-krseTxxN.js";import{n as p}from"./path-B0Ik7Tu9.js";import{m}from"./dist-Bd4S37oi.js";import{t as h}from"./arc-DMDAZHAN.js";import{t as g}from"./array-DetWRiSa.js";import{f as _,r as v}from"./chunk-5PVQY5BW-DyiDEtXY.js";import{t as y}from"./chunk-426QAEUC-BwKj8yqp.js";import{t as b}from"./chunk-4BX2VUAB-DyEhFk-Z.js";import{t as x}from"./mermaid-parser.core-Dt95U7zk.js";function S(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function C(e){return e}function w(){var e=C,t=S,n=null,r=p(0),i=p(m),a=p(0);function o(o){var s,c=(o=g(o)).length,l,u,d=0,f=Array(c),p=Array(c),h=+r.apply(this,arguments),_=Math.min(m,Math.max(-m,i.apply(this,arguments)-h)),v,y=Math.min(Math.abs(_)/c,a.apply(this,arguments)),b=y*(_<0?-1:1),x;for(s=0;s<c;++s)(x=p[f[s]=s]=+e(o[s],s,o))>0&&(d+=x);for(t==null?n!=null&&f.sort(function(e,t){return n(o[e],o[t])}):f.sort(function(e,n){return t(p[e],p[n])}),s=0,u=d?(_-c*b)/d:0;s<c;++s,h=v)l=f[s],x=p[l],v=h+(x>0?x*u:0)+b,p[l]={data:o[l],index:s,value:x,startAngle:h,endAngle:v,padAngle:y};return p}return o.value=function(t){return arguments.length?(e=typeof t==`function`?t:p(+t),o):e},o.sortValues=function(e){return arguments.length?(t=e,n=null,o):t},o.sort=function(e){return arguments.length?(n=e,t=null,o):n},o.startAngle=function(e){return arguments.length?(r=typeof e==`function`?e:p(+e),o):r},o.endAngle=function(e){return arguments.length?(i=typeof e==`function`?e:p(+e),o):i},o.padAngle=function(e){return arguments.length?(a=typeof e==`function`?e:p(+e),o):a},o}var T=u.pie,E={sections:new Map,showData:!1,config:T},D=E.sections,O=E.showData,k=structuredClone(T),A={getConfig:t(()=>structuredClone(k),`getConfig`),clear:t(()=>{D=new Map,O=E.showData,s()},`clear`),setDiagramTitle:a,getDiagramTitle:r,setAccTitle:i,getAccTitle:d,setAccDescription:n,getAccDescription:o,addSection:t(({label:t,value:n})=>{if(n<0)throw Error(`"${t}" has invalid value: ${n}. Negative values are not allowed in pie charts. All slice values must be >= 0.`);D.has(t)||(D.set(t,n),e.debug(`added new section: ${t}, with value: ${n}`))},`addSection`),getSections:t(()=>D,`getSections`),setShowData:t(e=>{O=e},`setShowData`),getShowData:t(()=>O,`getShowData`)},j=t((e,t)=>{b(e,t),t.setShowData(e.showData),e.sections.map(t.addSection)},`populateDb`),M={parse:t(async t=>{let n=await x(`pie`,t);e.debug(n),j(n,A)},`parse`)},N=t(e=>`
2
+ .pieCircle{
3
+ stroke: ${e.pieStrokeColor};
4
+ stroke-width : ${e.pieStrokeWidth};
5
+ opacity : ${e.pieOpacity};
6
+ }
7
+ .pieOuterCircle{
8
+ stroke: ${e.pieOuterStrokeColor};
9
+ stroke-width: ${e.pieOuterStrokeWidth};
10
+ fill: none;
11
+ }
12
+ .pieTitleText {
13
+ text-anchor: middle;
14
+ font-size: ${e.pieTitleTextSize};
15
+ fill: ${e.pieTitleTextColor};
16
+ font-family: ${e.fontFamily};
17
+ }
18
+ .slice {
19
+ font-family: ${e.fontFamily};
20
+ fill: ${e.pieSectionTextColor};
21
+ font-size:${e.pieSectionTextSize};
22
+ // fill: white;
23
+ }
24
+ .legend text {
25
+ fill: ${e.pieLegendTextColor};
26
+ font-family: ${e.fontFamily};
27
+ font-size: ${e.pieLegendTextSize};
28
+ }
29
+ `,`getStyles`),P=t(e=>{let t=[...e.values()].reduce((e,t)=>e+t,0),n=[...e.entries()].map(([e,t])=>({label:e,value:t})).filter(e=>e.value/t*100>=1);return w().value(e=>e.value).sort(null)(n)},`createPieArcs`),F={parser:M,db:A,renderer:{draw:t((t,n,r,i)=>{e.debug(`rendering pie chart
30
+ `+t);let a=i.db,o=c(),s=v(a.getConfig(),o.pie),u=y(n),d=u.append(`g`);d.attr(`transform`,`translate(225,225)`);let{themeVariables:p}=o,[m]=_(p.pieOuterStrokeWidth);m??=2;let g=s.textPosition,b=h().innerRadius(0).outerRadius(185),x=h().innerRadius(185*g).outerRadius(185*g);d.append(`circle`).attr(`cx`,0).attr(`cy`,0).attr(`r`,185+m/2).attr(`class`,`pieOuterCircle`);let S=a.getSections(),C=P(S),w=[p.pie1,p.pie2,p.pie3,p.pie4,p.pie5,p.pie6,p.pie7,p.pie8,p.pie9,p.pie10,p.pie11,p.pie12],T=0;S.forEach(e=>{T+=e});let E=C.filter(e=>(e.data.value/T*100).toFixed(0)!==`0`),D=f(w).domain([...S.keys()]);d.selectAll(`mySlices`).data(E).enter().append(`path`).attr(`d`,b).attr(`fill`,e=>D(e.data.label)).attr(`class`,`pieCircle`),d.selectAll(`mySlices`).data(E).enter().append(`text`).text(e=>(e.data.value/T*100).toFixed(0)+`%`).attr(`transform`,e=>`translate(`+x.centroid(e)+`)`).style(`text-anchor`,`middle`).attr(`class`,`slice`);let O=d.append(`text`).text(a.getDiagramTitle()).attr(`x`,0).attr(`y`,-400/2).attr(`class`,`pieTitleText`),k=[...S.entries()].map(([e,t])=>({label:e,value:t})),A=d.selectAll(`.legend`).data(k).enter().append(`g`).attr(`class`,`legend`).attr(`transform`,(e,t)=>{let n=22*k.length/2;return`translate(216,`+(t*22-n)+`)`});A.append(`rect`).attr(`width`,18).attr(`height`,18).style(`fill`,e=>D(e.label)).style(`stroke`,e=>D(e.label)),A.append(`text`).attr(`x`,22).attr(`y`,14).text(e=>a.getShowData()?`${e.label} [${e.value}]`:e.label);let j=512+Math.max(...A.selectAll(`text`).nodes().map(e=>e?.getBoundingClientRect().width??0)),M=O.node()?.getBoundingClientRect().width??0,N=450/2-M/2,F=450/2+M/2,I=Math.min(0,N),L=Math.max(j,F)-I;u.attr(`viewBox`,`${I} 0 ${L} 450`),l(u,450,L,s.useMaxWidth)},`draw`)},styles:N};export{F as diagram};
@@ -0,0 +1,8 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/mermaid.core-BuYSs1fU.js","assets/dist-Bd4S37oi.js","assets/chunk-DD-I1_y5.js","assets/chunk-U2HBQHQK-CQpbcqRS.js","assets/src-B6XdH6xq.js","assets/chunk-5PVQY5BW-DyiDEtXY.js","assets/chunk-ICPOFSXX-C5_hbB6H.js","assets/_baseFor-BHtDrjIo.js","assets/isEmpty-BWl67LAZ.js","assets/chunk-336JU56O-DulT46bV.js","assets/chunk-5FUZZQ4R-B3IWYz-k.js","assets/chunk-X2U36JSP-1HG7T4gX.js","assets/chunk-ZZ45TVLE-D6CiPO0Q.js","assets/rough.esm-DKRO8IF-.js","assets/chunk-ENJZ2VHE-BesS5YY4.js","assets/line-D1281H12.js","assets/path-B0Ik7Tu9.js","assets/array-DetWRiSa.js","assets/chunk-BSJP7CBP-DP7LTBll.js","assets/chunk-426QAEUC-BwKj8yqp.js","assets/chunk-XPW4576I-m1Y_r88I.js"])))=>i.map(i=>d[i]);
2
+ import{o as e}from"./chunk-DD-I1_y5.js";import{i as t,n,o as r,r as i,t as a}from"./jsx-runtime-vPsBTwUp.js";import{_ as o,a as s,c,f as l,g as u,h as d,i as f,l as p,m,n as h,o as g,p as _,s as v,t as y,u as b,v as x,y as S}from"./lib-W5Jcz4p8.js";import{t as C}from"./Checkbox-C6ZCsPvl.js";var w=i(`chevron-down`,[[`path`,{d:`m6 9 6 6 6-6`,key:`qrunsl`}]]),T=i(`file-code`,[[`path`,{d:`M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z`,key:`1oefj6`}],[`path`,{d:`M14 2v5a1 1 0 0 0 1 1h5`,key:`wfsgrz`}],[`path`,{d:`M10 12.5 8 15l2 2.5`,key:`1tg20x`}],[`path`,{d:`m14 12.5 2 2.5-2 2.5`,key:`yinavb`}]]),E=i(`mic`,[[`path`,{d:`M12 19v3`,key:`npa21l`}],[`path`,{d:`M19 10v2a7 7 0 0 1-14 0v-2`,key:`1vc78b`}],[`rect`,{x:`9`,y:`2`,width:`6`,height:`13`,rx:`3`,key:`s6n7sd`}]]),D=i(`paperclip`,[[`path`,{d:`m16 6-8.414 8.586a2 2 0 0 0 2.829 2.829l8.414-8.586a4 4 0 1 0-5.657-5.657l-8.379 8.551a6 6 0 1 0 8.485 8.485l8.379-8.551`,key:`1miecu`}]]),O=i(`pause`,[[`rect`,{x:`14`,y:`3`,width:`5`,height:`18`,rx:`1`,key:`kaeet6`}],[`rect`,{x:`5`,y:`3`,width:`5`,height:`18`,rx:`1`,key:`1wsw3u`}]]),k=i(`square-check-big`,[[`path`,{d:`M21 10.656V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.344`,key:`2acyp4`}],[`path`,{d:`m9 11 3 3L22 4`,key:`1pflzl`}]]),A=i(`square-plus`,[[`rect`,{width:`18`,height:`18`,x:`3`,y:`3`,rx:`2`,key:`afitv7`}],[`path`,{d:`M8 12h8`,key:`1wcyev`}],[`path`,{d:`M12 8v8`,key:`napkw2`}]]),j=t(),M=e(r(),1),N=`image/jpeg,image/png,image/gif,image/webp,application/pdf,text/plain,text/markdown,text/csv,text/html,text/calendar,audio/ogg,audio/opus,audio/mp4,audio/mpeg,audio/webm,audio/wav,.opus,.ogg,.m4a,.mp3,.wav,.webm`,P=new Set(N.split(`,`).filter(e=>!e.startsWith(`.`))),F=50*1024*1024,I=typeof window<`u`&&/^(localhost|127\.0\.0\.1|[a-z0-9-]+\.local)(:|$)/.test(window.location.hostname);function L(){let e=crypto.getRandomValues(new Uint8Array(16));e[6]=e[6]&15|64,e[8]=e[8]&63|128;let t=[...e].map(e=>e.toString(16).padStart(2,`0`)).join(``);return`${t.slice(0,8)}-${t.slice(8,12)}-${t.slice(12,16)}-${t.slice(16,20)}-${t.slice(20)}`}function R(){let e=window.location.pathname;if(e.startsWith(`/g/`))return;let t=e.match(/^\/([a-z][a-z0-9-]{2,49})$/);return t?t[1]:void 0}function z(){let e=window.location.pathname.match(/^\/g\/([a-z0-9][a-z0-9-]{0,49})$/);return e?e[1]:void 0}function B(e){return[{key:`length`,label:`At least 8 characters`,met:e.length>=8},{key:`number`,label:`Contains a number`,met:/\d/.test(e)},{key:`special`,label:`Contains a special character`,met:/[^A-Za-z0-9]/.test(e)},{key:`whitespace`,label:`No spaces`,met:e.length>0&&!/\s/.test(e)}]}function ee(e,t){if(t===`phone`)return e.length>4?e.slice(0,e.length-4).replace(/\d/g,`•`)+` `+e.slice(-4):e;let n=e.indexOf(`@`);return n<=2?e:e.slice(0,2)+`•••`+e.slice(n)}function te(e){let[t,n]=(0,M.useState)(null),[r,i]=(0,M.useState)(null),[a,o]=(0,M.useState)(`loading`),[s,c]=(0,M.useState)(``),[l,u]=(0,M.useState)(null),[d,f]=(0,M.useState)(null),[p,m]=(0,M.useState)(!1),[h,g]=(0,M.useState)(null),_=(0,M.useMemo)(()=>R(),[]),v=(0,M.useMemo)(()=>z(),[]),[y,b]=(0,M.useState)(null),x=(0,M.useRef)(_||``),S=(0,M.useRef)(null),C=(0,M.useRef)(null),w=(0,M.useRef)(!1),T=(0,M.useRef)(null),[E,D]=(0,M.useState)(`sign-in`),[O,k]=(0,M.useState)(null),A=(0,M.useRef)(null),j=(0,M.useRef)(null);(0,M.useEffect)(()=>{try{let e=sessionStorage.getItem(`maxy_session`);e&&(j.current=e)}catch{}},[]);let N=(0,M.useCallback)(t=>{S.current=t,n(t);try{sessionStorage.setItem(`maxy_session`,t)}catch{}o(`chat`),e(t)},[e]),P=(0,M.useCallback)(()=>{S.current=null;try{sessionStorage.removeItem(`maxy_session`)}catch{}n(null),o(`auth-required`),D(`sign-in`)},[]),F=(0,M.useCallback)(async e=>{try{let t=x.current,n=await fetch(`/api/access/verify-token`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({token:e,agentSlug:t})}),r=await n.json();n.ok?(A.current=r.session_key,k(r.grant),D(`set-password`),window.history.replaceState({},``,window.location.pathname)):D(`link-expired`)}catch{D(`sign-in`)}},[]),B=(0,M.useCallback)(async()=>{if(S.current)return S.current;if(C.current)return C.current;let e=(async()=>{try{let e=j.current,t=await fetch(`/api/session`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({session_id:L(),..._?{agent:_}:{},...v?{group_slug:v}:{},...e?{session_key:e}:{}})});if(!t.ok){let e=await t.json().catch(()=>({error:``}));return I&&console.error(`[session] POST /api/session failed: ${t.status} ${t.statusText}`,e),t.status===404?i(e.error||`Agent not found`):t.status===503&&i(e.error||`Service unavailable`),null}let r=await t.json();if(r.auth_required){r.agent_id&&(x.current=r.agent_id),c(r.displayName||``),r.agentImage&&u(r.agentImage),r.agentImageShape&&f(r.agentImageShape),r.showAgentName&&m(r.showAgentName),r.branding&&g(r.branding),o(`auth-required`);let e=new URLSearchParams(window.location.search).get(`token`);return e?F(e):D(`sign-in`),null}S.current=r.session_key,n(r.session_key),r.displayName&&c(r.displayName),r.agentImage&&u(r.agentImage),r.agentImageShape&&f(r.agentImageShape),r.showAgentName&&m(r.showAgentName),r.branding&&g(r.branding),o(`chat`),r.resumed&&r.messages&&(w.current=!0,T.current=r.messages),r.group&&b({groupSlug:r.groupSlug,groupName:r.groupName,participants:r.participants??[]});try{sessionStorage.setItem(`maxy_session`,r.session_key)}catch{}return r.session_key}catch(e){return I&&console.error(`[session] fetch /api/session threw:`,e),i(`Unable to connect. Please check your connection and try again.`),null}finally{C.current=null}})();return C.current=e,e},[_,v,F]);return{sessionId:t,cacheKeyRef:S,sessionError:r,pageState:a,setPageState:o,agentDisplayName:s,agentImage:l,agentImageShape:d,showAgentName:p,agentSlug:_,branding:h,resolvedSlugRef:x,ensureSession:B,startNewSession:(0,M.useCallback)(async()=>{S.current=null,C.current=null,j.current=null,w.current=!1,T.current=null,n(null),i(null);try{sessionStorage.removeItem(`maxy_session`)}catch{}let t=await B();t&&e(t)},[B,e]),enterChat:N,enterGate:P,resumedRef:w,resumeMessagesRef:T,gateState:E,setGateState:D,grantInfo:O,setGrantInfo:k,gateCacheKeyRef:A,groupContext:y,groupSlug:v}}async function*V(e){let t=e.body?.getReader();if(!t)throw Error(`No response stream`);let n=new TextDecoder,r=``;try{for(;;){let{done:e,value:i}=await t.read();if(e)break;r+=n.decode(i,{stream:!0});let a=r.split(`
3
+ `);r=a.pop();for(let e of a){if(!e.startsWith(`data: `))continue;let t=e.slice(6);if(t===`[DONE]`)continue;let n;try{n=JSON.parse(t)}catch{continue}yield n}}}finally{t.cancel()}}function ne({cacheKeyRef:e,ensureSession:t,sessionError:n,pageState:r,inputRef:i}){let[a,o]=(0,M.useState)([]),[s,c]=(0,M.useState)(!1),l=(0,M.useRef)(!1),u=e=>{l.current=e,c(e)},d=(0,M.useCallback)(async a=>{if(!l.current){u(!0),o([{role:`maxy`,content:``,timestamp:Date.now()}]);try{let n=await fetch(`/api/chat`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({greeting:!0,session_key:a})});if(n.status===401){e.current=null;try{sessionStorage.removeItem(`maxy_session`)}catch{}I&&console.warn(`[greeting] stale session, retrying with fresh session`);let r=await t();if(!r)return;n=await fetch(`/api/chat`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({greeting:!0,session_key:r})})}if(!n.ok){let e=await n.json().catch(()=>({}));throw Error(e.error||`Something went wrong`)}let r=``,i=``,s=()=>{i&&(r+=i,i=``,o(e=>{let t=[...e];return t[0]={...t[0],content:r},t}))},c=setInterval(s,60);try{for await(let e of V(n)){if(e.error)throw Object.assign(Error(e.error),{fromSSE:!0});e.text&&(i+=e.text),e.type===`component`&&(s(),o(t=>{let n=[...t],r={...n[0]},i=[...r.components||[]];return i.push({name:e.name,data:e.data,submitted:!1}),n[0]={...r,components:i},n}))}}finally{clearInterval(c),s()}}catch(e){if(I&&console.error(`[chat] greeting failed:`,e),r===`auth-required`)return;let t=e instanceof Error?e.message:String(e);o([{role:`maxy`,content:e instanceof Error&&e.fromSSE?t:n??`I'm having trouble connecting right now. Try refreshing the page.`,timestamp:Date.now()}])}finally{u(!1),r===`chat`&&i.current?.focus()}}},[e,t,n,r,i]),f=(0,M.useCallback)(async(a,s)=>{let c=s?.hidden??!1,d=s?.files??[];if(!a&&d.length===0||l.current)return;u(!0);let f=d.map(e=>({filename:e.name,mimeType:e.type})),p={role:`visitor`,content:a,attachments:f.length>0?f:void 0,timestamp:Date.now(),hidden:c},m;o(e=>{let t=[...e,p,{role:`maxy`,content:``,timestamp:Date.now()}];return m=t.length-1,t});try{let n=await t();if(!n)throw Error(`session`);let r=e=>{if(d.length>0){let t=new FormData;t.append(`message`,a),t.append(`session_key`,e);for(let e of d)t.append(`attachments`,e);return{body:t,headers:{}}}return{body:JSON.stringify({message:a,session_key:e}),headers:{"Content-Type":`application/json`}}},{body:i,headers:s}=r(n),c=await fetch(`/api/chat`,{method:`POST`,headers:s,body:i});if(c.status===401){e.current=null;try{sessionStorage.removeItem(`maxy_session`)}catch{}I&&console.warn(`[session-expired] stale key cleared, retrying with fresh session`);let n=await t();if(!n)throw Error(`session`);({body:i,headers:s}=r(n)),c=await fetch(`/api/chat`,{method:`POST`,headers:s,body:i})}if(!c.ok){let e=await c.json().catch(()=>({}));throw Error(e.error||`Something went wrong`)}let l=``,u=``,f=()=>{u&&(l+=u,u=``,o(e=>{let t=[...e];return t[m]={...t[m],content:l},t}))},p=setInterval(f,60);try{for await(let e of V(c)){if(e.error)throw Object.assign(Error(e.error),{fromSSE:!0});e.text&&(u+=e.text),e.type===`component`&&(f(),o(t=>{let n=[...t],r={...n[m]},i=[...r.components||[]];return i.push({name:e.name,data:e.data,submitted:!1}),n[m]={...r,components:i},n}))}}finally{clearInterval(p),f()}}catch(e){if(I&&console.error(`[chat] sendMessage failed:`,e),r===`auth-required`)return;let t=e instanceof Error?e.message:String(e),i=e instanceof Error&&e.fromSSE;o(e=>{let r=[...e];return r[m]={...r[m],content:i?t:t===`session`?n??`I'm having trouble connecting right now. Try refreshing the page.`:`Sorry, I hit a snag. Try again in a moment.`},r})}finally{u(!1),r===`chat`&&i.current?.focus()}},[e,t,n,r,i]);return{messages:a,setMessages:o,isStreaming:s,sendMessage:f,sendGreeting:d,handleComponentSubmit:(0,M.useCallback)((e,t,n)=>{o(n=>{let r=[...n],i={...r[e]},a=[...i.components||[]];return a[t]={...a[t],submitted:!0},r[e]={...i,components:a},r}),f(n,{hidden:!0})},[f])}}function re({cacheKeyRef:e,groupSlug:t,isStreaming:n,setMessages:r}){let i=(0,M.useRef)(new Date().toISOString()),a=(0,M.useRef)(!0);(0,M.useEffect)(()=>{let e=()=>{a.current=document.visibilityState===`visible`};return document.addEventListener(`visibilitychange`,e),()=>document.removeEventListener(`visibilitychange`,e)},[]);let o=(0,M.useCallback)(async()=>{let n=e.current;if(!(!n||!t))try{let e=await fetch(`/api/group/messages?session_key=${encodeURIComponent(n)}&since=${encodeURIComponent(i.current)}`);if(!e.ok)return;let t=await e.json();if(!t.messages||t.messages.length===0)return;let a=t.messages[t.messages.length-1];a.timestamp&&(i.current=new Date(a.timestamp).toISOString()),r(e=>{let n=new Set(e.filter(e=>e.messageId).map(e=>e.messageId)),r=t.messages.filter(e=>!n.has(e.messageId)).map(e=>({role:e.role,content:e.content,timestamp:e.timestamp,senderName:e.senderName??void 0,senderVisitorId:e.senderVisitorId??void 0,messageId:e.messageId}));if(r.length===0)return e;let i=[...e,...r];return i.sort((e,t)=>e.timestamp-t.timestamp),i})}catch(e){console.error(`[group-poll] failed: ${e instanceof Error?e.message:String(e)}`)}},[e,t,r]);(0,M.useEffect)(()=>{if(!t)return;let e,r=!1;function i(){if(r)return;let t=a.current?3e3:3e4;e=setTimeout(async()=>{n||await o(),i()},t)}return i(),()=>{r=!0,clearTimeout(e)}},[t,n,o])}var H=a();function U({value:e,onChange:t,onComplete:n,disabled:r}){let i=(0,M.useRef)([]);function a(n,r){r.key===`Backspace`?(r.preventDefault(),e[n]?t(e.slice(0,n)+e.slice(n+1)):n>0&&(t(e.slice(0,n-1)+e.slice(n)),i.current[n-1]?.focus())):r.key===`ArrowLeft`&&n>0?i.current[n-1]?.focus():r.key===`ArrowRight`&&n<5&&i.current[n+1]?.focus()}function o(r,a){let o=a.nativeEvent.data;if(!o||!/^\d$/.test(o))return;let s=e.split(``);for(s[r]=o;s.length<r;)s.push(``);let c=s.join(``).replace(/\D/g,``).slice(0,6);t(c),c.length===6?n(c):r<5&&i.current[r+1]?.focus()}function s(e){e.preventDefault();let r=e.clipboardData.getData(`text`).replace(/\D/g,``).slice(0,6);r&&(t(r),r.length===6?n(r):i.current[r.length]?.focus())}return(0,H.jsx)(`div`,{className:`gate-otp-field`,children:Array.from({length:6}).map((t,n)=>(0,H.jsx)(`input`,{ref:e=>{i.current[n]=e},type:`text`,inputMode:`numeric`,className:`pin-box${e[n]?` pin-box-filled`:``}`,value:e[n]||``,onKeyDown:e=>a(n,e),onInput:e=>o(n,e),onPaste:s,onFocus:e=>e.target.select(),autoFocus:n===0,autoComplete:`off`,maxLength:1,disabled:r,"aria-label":`Code digit ${n+1}`},n))})}function ie({gateState:e,setGateState:t,grantInfo:n,setGrantInfo:r,gateCacheKeyRef:i,resolvedSlugRef:a,onAuthenticated:o}){let[c,l]=(0,M.useState)(``),[u,d]=(0,M.useState)(``),[f,p]=(0,M.useState)(``),[m,h]=(0,M.useState)(!1),[g,_]=(0,M.useState)(``),[v,y]=(0,M.useState)(``),[b,x]=(0,M.useState)(!1),[S,w]=(0,M.useState)(null),[T,E]=(0,M.useState)(null),[D,O]=(0,M.useState)(!1);async function k(e){if(e.preventDefault(),!D){w(null),O(!0);try{let e=a.current,n=await fetch(`/api/access/login`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({contact:c,password:u,agentSlug:e})}),i=await n.json();n.ok?o(i.session_key):n.status===401?i.error?.includes(`setup not complete`)||i.error?.includes(`invitation link`)?(t(`private-agent`),w(null)):w(i.error||`Invalid credentials`):n.status===403?(t(`access-expired`),i.expiresAt&&r(e=>e?{...e,expiresAt:i.expiresAt}:{displayName:null,contactValue:c,contactMethod:`email`,expiresAt:i.expiresAt,status:`expired`})):n.status===429?w(i.error||`Too many attempts. Please try again later.`):w(i.error||`Something went wrong`)}catch{w(`Unable to connect. Please try again.`)}finally{O(!1)}}}async function A(e){if(!D){w(null),O(!0);try{let n=a.current,o=await fetch(`/api/access/verify-otp`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({phone:v,code:e,agentSlug:n})}),s=await o.json();o.ok?(i.current=s.session_key,r(s.grant),t(`set-password`)):o.status===429?t(`otp-failed`):(w(s.error||`Invalid code`),_(``))}catch{w(`Unable to connect. Please try again.`)}finally{O(!1)}}}async function j(e){if(e.preventDefault(),!D){if(w(null),u!==f){w(`Passwords do not match`);return}if(!B(u).every(e=>e.met)){w(`Password does not meet requirements`);return}O(!0);try{let e=i.current;if(!e){w(`Session expired. Please use your invitation link again.`);return}let t=await fetch(`/api/access/create-credentials`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({session_key:e,password:u})}),n=await t.json();t.ok?o(n.session_key):t.status===400&&n.requirements?w(n.requirements.filter(e=>!e.met).map(e=>e.label).join(`, `)):w(n.error||`Something went wrong`)}catch{w(`Unable to connect. Please try again.`)}finally{O(!1)}}}async function N(e){if(e.preventDefault(),!(D||!c)){w(null),O(!0);try{let e=a.current,t=await fetch(`/api/access/forgot-password`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({contact:c,agentSlug:e})});t.status===429?w((await t.json()).error||`Too many attempts. Please try again later.`):(E(`If an account exists, a reset link has been sent.`),setTimeout(()=>{x(!1),E(null)},4e3))}catch{w(`Unable to connect. Please try again.`)}finally{O(!1)}}}switch(e){case`set-password`:{let e=B(u),t=e.every(e=>e.met),r=u===f,i=t&&r&&f.length>0;return(0,H.jsx)(`div`,{className:`gate-wrap`,children:(0,H.jsxs)(`div`,{className:`gate-card`,children:[n?.expiresAt&&(0,H.jsxs)(`div`,{className:`gate-expiry-badge`,children:[`Access until `,new Date(n.expiresAt).toLocaleDateString(`en-GB`,{day:`numeric`,month:`short`,year:`numeric`})]}),(0,H.jsxs)(`h2`,{className:`gate-title`,children:[`Welcome, `,n?.displayName||`there`]}),(0,H.jsx)(`p`,{className:`gate-subtitle`,children:`Create a password to access this agent in the future.`}),(0,H.jsxs)(`form`,{className:`gate-form`,onSubmit:j,children:[(0,H.jsxs)(`div`,{className:`gate-field`,children:[(0,H.jsx)(`label`,{htmlFor:`gate-display-name`,children:`Display name`}),(0,H.jsx)(`input`,{id:`gate-display-name`,type:`text`,value:n?.displayName||``,disabled:!0})]}),(0,H.jsxs)(`div`,{className:`gate-field gate-pw-row`,children:[(0,H.jsx)(`label`,{htmlFor:`gate-pw`,children:`Password`}),(0,H.jsx)(`div`,{className:`gate-pw-toggle`,children:(0,H.jsx)(C,{checked:m,onChange:h,label:`Show`})}),(0,H.jsx)(`input`,{id:`gate-pw`,type:m?`text`:`password`,value:u,onChange:e=>d(e.target.value),placeholder:`Your password`,autoFocus:!0,autoComplete:`new-password`}),u.length>0&&(0,H.jsx)(`div`,{className:`gate-strength`,children:e.map(e=>(0,H.jsxs)(`span`,{className:`gate-strength-item${e.met?` met`:``}`,children:[e.met?`✓`:`○`,` `,e.label]},e.key))})]}),(0,H.jsxs)(`div`,{className:`gate-field`,children:[(0,H.jsx)(`label`,{htmlFor:`gate-pw-confirm`,children:`Confirm password`}),(0,H.jsx)(`input`,{id:`gate-pw-confirm`,type:m?`text`:`password`,value:f,onChange:e=>p(e.target.value),placeholder:`Confirm your password`,autoComplete:`new-password`}),f.length>0&&!r&&(0,H.jsx)(`div`,{className:`gate-error`,children:`Passwords do not match`})]}),S&&(0,H.jsx)(`div`,{className:`gate-error`,children:S}),(0,H.jsx)(`div`,{className:`gate-submit`,children:(0,H.jsx)(s,{variant:`primary`,type:`submit`,fullWidth:!0,disabled:!i||D,loading:D,children:`Create account & enter chat`})})]})]})})}case`enter-otp`:return(0,H.jsx)(`div`,{className:`gate-wrap`,children:(0,H.jsxs)(`div`,{className:`gate-card`,children:[(0,H.jsx)(`h2`,{className:`gate-title`,children:`Enter your code`}),(0,H.jsxs)(`p`,{className:`gate-subtitle`,children:[`Enter the 6-digit code sent to `,ee(v,`phone`)]}),(0,H.jsx)(U,{value:g,onChange:_,onComplete:A,disabled:D}),S&&(0,H.jsx)(`div`,{className:`gate-error`,children:S}),D&&(0,H.jsxs)(`div`,{className:`gate-loading`,children:[(0,H.jsx)(`span`,{className:`spinner`}),`Verifying...`]}),(0,H.jsx)(`div`,{className:`gate-resend`,children:(0,H.jsx)(`button`,{type:`button`,className:`gate-link`,onClick:()=>{t(`sign-in`),_(``),w(null)},children:`Use a different number`})})]})});case`sign-in`:case`private-agent`:return(0,H.jsx)(`div`,{className:`gate-wrap`,children:(0,H.jsxs)(`div`,{className:`gate-card`,children:[(0,H.jsx)(`h2`,{className:`gate-title`,children:e===`private-agent`?`Private Agent`:`Welcome back`}),(0,H.jsx)(`p`,{className:`gate-subtitle`,children:e===`private-agent`?`This agent is invitation-only. If you have an account, sign in below.`:`Sign in to continue your conversation.`}),b?(0,H.jsxs)(`form`,{className:`gate-form`,onSubmit:N,children:[(0,H.jsxs)(`div`,{className:`gate-field`,children:[(0,H.jsx)(`label`,{htmlFor:`gate-forgot-contact`,children:`Email or phone`}),(0,H.jsx)(`input`,{id:`gate-forgot-contact`,type:`text`,value:c,onChange:e=>l(e.target.value),placeholder:`you@example.com`,autoFocus:!0,autoComplete:`email`})]}),S&&(0,H.jsx)(`div`,{className:`gate-error`,children:S}),T&&(0,H.jsx)(`div`,{className:`gate-success`,children:T}),(0,H.jsx)(`div`,{className:`gate-submit`,children:(0,H.jsx)(s,{variant:`primary`,type:`submit`,fullWidth:!0,disabled:!c.trim()||D,loading:D,children:`Send reset link`})}),(0,H.jsx)(`div`,{className:`gate-actions`,children:(0,H.jsx)(`button`,{type:`button`,className:`gate-link`,onClick:()=>{x(!1),w(null),E(null)},children:`Back to sign in`})})]}):(0,H.jsxs)(`form`,{className:`gate-form`,onSubmit:k,children:[(0,H.jsxs)(`div`,{className:`gate-field`,children:[(0,H.jsx)(`label`,{htmlFor:`gate-contact`,children:`Email or phone`}),(0,H.jsx)(`input`,{id:`gate-contact`,type:`text`,value:c,onChange:e=>l(e.target.value),placeholder:`you@example.com`,autoFocus:!0,autoComplete:`email`})]}),(0,H.jsxs)(`div`,{className:`gate-field gate-pw-row`,children:[(0,H.jsx)(`label`,{htmlFor:`gate-login-pw`,children:`Password`}),(0,H.jsx)(`div`,{className:`gate-pw-toggle`,children:(0,H.jsx)(C,{checked:m,onChange:h,label:`Show`})}),(0,H.jsx)(`input`,{id:`gate-login-pw`,type:m?`text`:`password`,value:u,onChange:e=>d(e.target.value),placeholder:`Your password`,autoComplete:`current-password`})]}),S&&(0,H.jsx)(`div`,{className:`gate-error`,children:S}),(0,H.jsx)(`div`,{className:`gate-submit`,children:(0,H.jsx)(s,{variant:`primary`,type:`submit`,fullWidth:!0,disabled:!c.trim()||!u||D,loading:D,children:`Sign in`})}),(0,H.jsx)(`div`,{className:`gate-actions`,children:(0,H.jsx)(`button`,{type:`button`,className:`gate-link`,onClick:()=>{x(!0),w(null)},children:`Forgot password?`})})]}),e===`private-agent`&&(0,H.jsx)(`p`,{className:`gate-hint`,children:`No account? You need an invitation from the agent owner.`})]})});case`access-expired`:return(0,H.jsx)(`div`,{className:`gate-wrap`,children:(0,H.jsxs)(`div`,{className:`gate-card`,children:[(0,H.jsx)(`div`,{className:`gate-icon`,children:`⏰`}),(0,H.jsx)(`h2`,{className:`gate-title`,children:`Access expired`}),(0,H.jsxs)(`p`,{className:`gate-subtitle`,children:[n?.expiresAt?`Your access expired on ${new Date(n.expiresAt).toLocaleDateString(`en-GB`,{day:`numeric`,month:`long`,year:`numeric`})}.`:`Your access to this agent has expired.`,` `,`Contact the agent owner to renew.`]}),(0,H.jsx)(`div`,{className:`gate-actions`,children:(0,H.jsx)(s,{variant:`secondary`,onClick:()=>{t(`sign-in`),w(null),d(``)},children:`Sign in with a different account`})})]})});case`link-expired`:return(0,H.jsx)(`div`,{className:`gate-wrap`,children:(0,H.jsxs)(`div`,{className:`gate-card`,children:[(0,H.jsx)(`div`,{className:`gate-icon`,children:`⚠️`}),(0,H.jsx)(`h2`,{className:`gate-title`,children:`Link expired`}),(0,H.jsx)(`p`,{className:`gate-subtitle`,children:`This invitation link has expired or has already been used. If you already set your password, sign in below. Otherwise, ask the agent owner to send a new invitation.`}),(0,H.jsx)(`div`,{className:`gate-actions`,children:(0,H.jsx)(s,{variant:`primary`,onClick:()=>{t(`sign-in`),w(null)},children:`Go to sign in`})})]})});case`otp-failed`:return(0,H.jsx)(`div`,{className:`gate-wrap`,children:(0,H.jsxs)(`div`,{className:`gate-card`,children:[(0,H.jsx)(`div`,{className:`gate-icon`,children:`⛔`}),(0,H.jsx)(`h2`,{className:`gate-title`,children:`Too many attempts`}),(0,H.jsx)(`p`,{className:`gate-subtitle`,children:`You've entered the wrong code too many times. Ask the agent owner to send a new code.`}),(0,H.jsx)(`div`,{className:`gate-actions`,children:(0,H.jsx)(s,{variant:`secondary`,onClick:()=>{t(`sign-in`),w(null),_(``)},children:`Back to sign in`})})]})})}}var W=100;function ae(e){let t;try{t=JSON.parse(e)}catch(e){return{ok:!1,reason:`invalid JSON: ${e instanceof Error?e.message:String(e)}`}}if(typeof t!=`object`||!t||Array.isArray(t))return{ok:!1,reason:`payload is not a JSON object`};let n=t;if(typeof n.url!=`string`||n.url.length===0)return{ok:!1,reason:`url is required`};let r;try{r=new URL(n.url)}catch{return{ok:!1,reason:`url is not a valid URL`}}if(r.protocol!==`http:`&&r.protocol!==`https:`)return{ok:!1,reason:`url scheme ${r.protocol} is not permitted (http/https only)`};if(typeof n.intent!=`string`||n.intent.length===0)return{ok:!1,reason:`intent is required`};if(n.intent.length>W)return{ok:!1,reason:`intent exceeds ${W} chars`};let i;if(n.hostname!==void 0){if(typeof n.hostname!=`string`)return{ok:!1,reason:`hostname must be a string when provided`};i=n.hostname}return{ok:!0,payload:i?{url:n.url,intent:n.intent,hostname:i}:{url:n.url,intent:n.intent}}}var G={ok:`succeeded`,timeout:`navigation timed out`,"cdp-unreachable":`device browser is not responding`,error:`navigation error`};async function K(e,t){try{await fetch(`/api/admin/events`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({event:e,fields:t})})}catch(t){console.error(`[device-url:event] failed to post event`,e,t)}}function q({raw:e,reason:t}){return(0,M.useEffect)(()=>{K(`device-url:malformed`,{reason:t.slice(0,200),length:e.length})},[e,t]),(0,H.jsx)(`pre`,{className:`md-pre md-device-url-malformed`,children:(0,H.jsxs)(`code`,{className:`md-code`,children:[(0,H.jsxs)(`span`,{className:`md-device-url-malformed-label`,children:[(0,H.jsx)(m,{size:12}),` device-URL block is malformed: `,t]}),`
4
+ `,e]})})}function J({payload:e,reason:t}){let[n,r]=(0,M.useState)(`idle`);(0,M.useEffect)(()=>{K(`device-url:fallback-shown`,{intent:e.intent,reason:t,hostname:e.hostname??``})},[e.intent,e.hostname,t]);let i=async()=>{try{await navigator.clipboard.writeText(e.url),r(`copied`),window.setTimeout(()=>r(`idle`),2e3)}catch(t){r(`failed`),K(`device-url:fallback-shown`,{intent:e.intent,reason:`clipboard-api-unavailable`,hostname:e.hostname??``,detail:t instanceof Error?t.message.slice(0,200):String(t).slice(0,200)})}},a=e.hostname?` on the device (${e.hostname})`:` on the device`;return(0,H.jsxs)(`div`,{className:`md-device-url md-device-url-fallback`,role:`group`,children:[(0,H.jsxs)(`div`,{className:`md-device-url-fallback-message`,children:[(0,H.jsx)(m,{size:14}),(0,H.jsxs)(`span`,{children:[`Could not open `,(0,H.jsx)(`strong`,{children:e.intent}),a,` automatically (`,t,`). Copy the URL and open it in a browser on the device:`]})]}),(0,H.jsxs)(`div`,{className:`md-device-url-fallback-url`,children:[(0,H.jsx)(`code`,{children:e.url}),(0,H.jsxs)(`button`,{type:`button`,className:`md-device-url-fallback-copy`,onClick:i,"aria-label":`Copy URL`,children:[n===`copied`?(0,H.jsx)(S,{size:14}):(0,H.jsx)(x,{size:14}),n===`copied`?`Copied`:n===`failed`?`Copy failed`:`Copy`]})]}),n===`failed`&&(0,H.jsx)(`div`,{className:`md-device-url-fallback-copy-failed`,children:`Your browser blocked the copy action. Select the URL text above manually to copy it.`})]})}function Y({payload:e}){let t=f(),[n,r]=(0,M.useState)({phase:`idle`});(0,M.useEffect)(()=>{K(`device-url:render`,{intent:e.intent,url:e.url,hostname:e.hostname??``,origin:`tool`})},[e.intent,e.url,e.hostname]);let i=async()=>{if(n.phase!==`navigating`){r({phase:`navigating`});try{let n=await fetch(`/api/admin/device-browser/navigate`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify(e)}),i=await n.json().catch(()=>({}));if(n.ok&&i.ok){r({phase:`succeeded`}),t&&(t.onShowVnc(),K(`device-url:vnc-surface-shown`,{intent:e.intent})),window.setTimeout(()=>r({phase:`idle`}),2500);return}r({phase:`fallback`,reason:i.navigateResult?G[i.navigateResult]:i.detail?i.detail.slice(0,80):`navigation failed`})}catch(e){r({phase:`fallback`,reason:(e instanceof Error?e.message:String(e)).slice(0,80)})}}},a=n.phase===`navigating`,o=n.phase===`succeeded`;return(0,H.jsxs)(`div`,{className:`md-device-url`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`md-device-url-button`,onClick:i,disabled:a,"aria-label":`Open ${e.intent} on the device's browser`,title:e.hostname?`Opens on device: ${e.hostname}`:`Opens on the device running Maxy`,children:[(0,H.jsx)(u,{size:16,className:`md-device-url-icon`}),(0,H.jsx)(`span`,{className:`md-device-url-label`,children:a?`Opening…`:o?`Opened on device`:`Open ${e.intent} on device`})]}),n.phase===`fallback`&&(0,H.jsx)(J,{payload:e,reason:n.reason})]})}function oe({source:e}){let t=ae(e.trim());return t.ok?(0,H.jsx)(Y,{payload:t.payload}):(0,H.jsx)(q,{raw:e,reason:t.reason})}var se=`modulepreload`,X=function(e){return`/`+e},Z={},ce=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}r=o(t.map(t=>{if(t=X(t,n),t in Z)return;Z[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:se,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},le=null;function ue(){return le||=ce(async()=>{let{default:e}=await import(`./mermaid.core-BuYSs1fU.js`);return{default:e}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20])).then(({default:e})=>(e.initialize({startOnLoad:!1,theme:`neutral`}),e)),le}function de({source:e}){let t=(0,M.useRef)(null),[n,r]=(0,M.useState)(null);return(0,M.useEffect)(()=>{let n=!1,i=`mermaid-${Math.random().toString(36).slice(2,9)}`;return ue().then(t=>t.render(i,e)).then(({svg:e})=>{!n&&t.current&&(t.current.innerHTML=e)}).catch(t=>{n||(console.error(`[MermaidBlock] render failed:`,e,t),r(t instanceof Error?t.message:`Diagram render failed`))}),()=>{n=!0}},[e]),n?(0,H.jsxs)(`div`,{className:`md-mermaid md-mermaid-error`,children:[(0,H.jsx)(`div`,{className:`md-mermaid-error-label`,children:`Diagram render error`}),(0,H.jsx)(`pre`,{className:`md-pre`,children:(0,H.jsx)(`code`,{className:`md-code`,children:e})})]}):(0,H.jsx)(`div`,{className:`md-mermaid`,ref:t})}var fe=/\.(mp4|webm|mov)(\?.*)?$/i,pe=/(?:youtube\.com\/watch\?v=|youtu\.be\/)([\w-]+)/,me=/vimeo\.com\/(\d+)/;function he(e){return!!e&&fe.test(e)}function ge(e){if(!e)return null;let t=e.match(pe);return t?t[1]:null}function _e(e){if(!e)return null;let t=e.match(me);return t?t[1]:null}function ve({src:e}){return(0,H.jsx)(`video`,{className:`md-video`,controls:!0,playsInline:!0,preload:`metadata`,children:(0,H.jsx)(`source`,{src:e})})}function ye({videoId:e}){return(0,H.jsx)(`div`,{className:`md-video-iframe`,children:(0,H.jsx)(`iframe`,{src:`https://www.youtube-nocookie.com/embed/${e}`,allow:`accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture`,allowFullScreen:!0,loading:`lazy`})})}function be({videoId:e}){return(0,H.jsx)(`div`,{className:`md-video-iframe`,children:(0,H.jsx)(`iframe`,{src:`https://player.vimeo.com/video/${e}`,allow:`autoplay; fullscreen; picture-in-picture`,allowFullScreen:!0,loading:`lazy`})})}function xe(e){if(he(e))return(0,H.jsx)(ve,{src:e});let t=ge(e);if(t)return(0,H.jsx)(ye,{videoId:t});let n=_e(e);return n?(0,H.jsx)(be,{videoId:n}):null}var Se={p:({children:e})=>(0,H.jsx)(`p`,{className:`md-p`,children:e}),h1:({children:e})=>(0,H.jsx)(`h1`,{className:`md-heading`,children:e}),h2:({children:e})=>(0,H.jsx)(`h2`,{className:`md-heading`,children:e}),h3:({children:e})=>(0,H.jsx)(`h3`,{className:`md-heading`,children:e}),code:({children:e,className:t})=>t===`language-mermaid`?(0,H.jsx)(de,{source:String(e).replace(/\n$/,``)}):t===`language-maxy-device-url`?(0,H.jsx)(oe,{source:String(e).replace(/\n$/,``)}):(0,H.jsx)(`code`,{className:`md-code ${t||``}`.trim(),children:e}),pre:({children:e,node:t})=>{let n=t?.children?.[0];if(n?.type===`element`&&n.tagName===`code`){let t=n.properties?.className??[];if(t.includes(`language-mermaid`)||t.includes(`language-maxy-device-url`))return(0,H.jsx)(H.Fragment,{children:e})}return(0,H.jsx)(`pre`,{className:`md-pre`,children:e})},ul:({children:e})=>(0,H.jsx)(`ul`,{className:`md-list`,children:e}),ol:({children:e})=>(0,H.jsx)(`ol`,{className:`md-list md-list-ordered`,children:e}),li:({children:e})=>(0,H.jsx)(`li`,{className:`md-list-item`,children:e}),hr:()=>(0,H.jsx)(`hr`,{className:`md-hr`}),strong:({children:e})=>(0,H.jsx)(`strong`,{className:`md-strong`,children:e}),img:({src:e,alt:t})=>xe(e)||(0,H.jsx)(`a`,{href:e,target:`_blank`,rel:`noopener noreferrer`,children:(0,H.jsx)(`img`,{className:`md-img`,src:e,alt:t||``,loading:`lazy`})}),a:({href:e,children:t})=>xe(e)||(0,H.jsx)(`a`,{href:e,className:`md-link`,target:`_blank`,rel:`noopener noreferrer`,children:t}),table:({children:e})=>(0,H.jsx)(`table`,{className:`md-table`,children:e}),thead:({children:e})=>(0,H.jsx)(`thead`,{className:`md-thead`,children:e}),tbody:({children:e})=>(0,H.jsx)(`tbody`,{children:e}),tr:({children:e})=>(0,H.jsx)(`tr`,{className:`md-tr`,children:e}),th:({children:e})=>(0,H.jsx)(`th`,{className:`md-th`,children:e}),td:({children:e})=>(0,H.jsx)(`td`,{className:`md-td`,children:e})};function Ce({content:e,elapsedSeconds:t,timestamp:n}){return(0,H.jsxs)(`div`,{className:`markdown-message`,children:[(0,H.jsx)(h,{remarkPlugins:[y],components:Se,children:e}),t!==void 0&&(0,H.jsxs)(`div`,{className:`message-meta`,children:[t,`s`]}),n&&(0,H.jsx)(`span`,{className:`message-timestamp`,children:n})]})}function Q({submitted:e,submittedLabel:t=`Submitted`,actions:n,children:r}){return(0,H.jsxs)(`div`,{className:`component-card${e?` component-card--submitted`:``}`,children:[r,(0,H.jsx)(`div`,{className:`component-card__actions`,children:e?(0,H.jsx)(`span`,{className:`component-card__done-label`,children:t}):n.map((e,t)=>(0,H.jsx)(s,{variant:e.variant,size:`sm`,disabled:e.disabled,onClick:e.onClick,children:e.label},t))})]})}function we({data:e,onSubmit:t,submitted:n}){let r=e,i=Array.isArray(r?.options)?r.options:[],[a,o]=(0,M.useState)(null),[s,c]=(0,M.useState)(`Submitted`);if(i.length===0)return null;let l=e=>{n||o(e)},u=()=>{if(!a||n)return;let e=i.find(e=>e.value===a);c(e?.label??`Submitted`),t((r?.submitMessage??`Selected: {{value}}`).replace(`{{value}}`,a).replace(`{{label}}`,e?.label??a))},d=()=>{n||(c(r?.backLabel??`Back`),t(r?.backMessage??``))},f=(e,t)=>{if(!n)if(e.key===`ArrowDown`||e.key===`ArrowRight`){e.preventDefault();let n=(t+1)%i.length;l(i[n].value),(e.currentTarget.parentElement?.children[n])?.focus()}else if(e.key===`ArrowUp`||e.key===`ArrowLeft`){e.preventDefault();let n=(t-1+i.length)%i.length;l(i[n].value),(e.currentTarget.parentElement?.children[n])?.focus()}else (e.key===` `||e.key===`Enter`)&&(e.preventDefault(),l(i[t].value))};return(0,H.jsx)(Q,{submitted:n,submittedLabel:s,actions:[...r?.backLabel&&r?.backMessage?[{label:r.backLabel,variant:`ghost`,onClick:d}]:[],{label:r?.submitLabel??`Confirm`,variant:`primary`,disabled:!a,onClick:u}],children:(0,H.jsxs)(`div`,{className:`single-select`,role:`radiogroup`,"aria-label":r?.title??`Select one`,children:[r?.title&&(0,H.jsx)(`div`,{className:`single-select__title`,children:r.title}),i.map((e,t)=>(0,H.jsxs)(`div`,{className:`single-select__row${a===e.value?` single-select__row--selected`:``}`,role:`radio`,"aria-checked":a===e.value,tabIndex:a===e.value||!a&&t===0?0:-1,onClick:()=>l(e.value),onKeyDown:e=>f(e,t),children:[(0,H.jsx)(`span`,{className:`single-select__radio${a===e.value?` single-select__radio--checked`:``}`}),(0,H.jsxs)(`div`,{className:`single-select__info`,children:[(0,H.jsxs)(`span`,{className:`single-select__label`,children:[e.icon&&(0,H.jsx)(`span`,{className:`single-select__icon`,children:e.icon}),e.label]}),e.description&&(0,H.jsx)(`span`,{className:`single-select__desc`,children:e.description})]})]},e.value))]})})}function Te({data:e,onSubmit:t,submitted:n}){let r=e,i=Array.isArray(r?.options)?r.options:[],[a,o]=(0,M.useState)(i.map(e=>!!e.locked||!!e.defaultSelected)),[s,c]=(0,M.useState)(`Submitted`);if(i.length===0)return null;let l=i.some(e=>e.locked),u=i.every((e,t)=>e.locked||a[t]),d=e=>{n||i[e].locked||o(t=>t.map((t,n)=>n===e?!t:t))},f=()=>{n||o(i.map((e,t)=>e.locked?a[t]:!u))},p=i.filter((e,t)=>!e.locked&&a[t]).map(e=>e.value),m=p.length>0||l,h=()=>{if(!(!m||n)){if(c(`Submitted`),p.length===0){t(`No optional plugins selected`);return}t((r?.submitMessage??`Selected: {{values}}`).replace(`{{values}}`,p.join(`, `)))}},g=()=>{n||(c(`Skipped`),t(r?.skipMessage??`Skipped`))},_=()=>{n||(c(r?.backLabel??`Back`),t(r?.backMessage??``))},v=[];return r?.backLabel&&r?.backMessage&&v.push({label:r.backLabel,variant:`ghost`,onClick:_}),r?.skipLabel&&v.push({label:r.skipLabel,variant:`ghost`,onClick:g}),v.push({label:r?.submitLabel??`Confirm`,variant:`primary`,disabled:!m,onClick:h}),(0,H.jsx)(Q,{submitted:n,submittedLabel:s,actions:v,children:(0,H.jsxs)(`div`,{className:`multi-select`,children:[r?.title&&(0,H.jsx)(`div`,{className:`multi-select__title`,children:r.title}),r?.selectAll&&(0,H.jsx)(`div`,{className:`multi-select__header`,children:(0,H.jsx)(C,{checked:u,onChange:f,label:`Select all`,disabled:n})}),(0,H.jsx)(`div`,{className:`multi-select__list`,role:`group`,"aria-label":r?.title??`Select options`,children:i.map((e,t)=>{let r=e.group&&(t===0||e.group!==i[t-1].group),o=!!e.locked;return(0,H.jsxs)(M.Fragment,{children:[r&&(0,H.jsx)(`div`,{className:`multi-select__group-header`,children:e.group}),(0,H.jsxs)(`div`,{className:`multi-select__row${o?` multi-select__row--locked`:``}`,role:`checkbox`,"aria-checked":a[t],"aria-disabled":o||void 0,tabIndex:o?-1:0,onClick:()=>d(t),onKeyDown:e=>{n||o||(e.key===` `||e.key===`Enter`)&&(e.preventDefault(),d(t))},children:[(0,H.jsx)(C,{checked:a[t],onChange:()=>d(t),disabled:n||o}),(0,H.jsxs)(`div`,{className:`multi-select__info`,children:[(0,H.jsxs)(`span`,{className:`multi-select__label`,children:[e.label,e.badge&&(0,H.jsx)(`span`,{className:`multi-select__badge`,children:e.badge})]}),e.description&&(0,H.jsx)(`span`,{className:`multi-select__desc`,children:e.description})]})]})]},e.value)})})]})})}function Ee({data:e,onSubmit:t,submitted:n}){let r=e,i=Array.isArray(r?.buttons)?r.buttons:[],[a,o]=(0,M.useState)(`Submitted`);if(i.length===0)return null;let s=e=>{n||(o(e.label),t(e.value))};return(0,H.jsx)(Q,{submitted:n,submittedLabel:a,actions:i.map(e=>({label:e.label,variant:`primary`,onClick:()=>s(e)})),children:(0,H.jsx)(H.Fragment,{})})}var De={"single-select":we,"multi-select":Te,"action-buttons":Ee};function Oe({name:e,data:t,onSubmit:n,submitted:r}){let i=De[e];return i?(0,H.jsx)(i,{data:t,onSubmit:n,submitted:r}):(console.warn(`[PublicComponentRenderer] Unknown component: "${e}". Registered: ${Object.keys(De).join(`, `)}`),(0,H.jsx)(`div`,{className:`component-card component-card--error`,children:(0,H.jsxs)(`p`,{style:{fontFamily:`var(--font-body)`,fontSize:12,color:`var(--text-secondary)`},children:[`Component “`,e,`” is not available. This may require a platform update.`]})}))}function ke(e){let t=new Date(e),n=new Date,r=String(t.getHours()).padStart(2,`0`),i=String(t.getMinutes()).padStart(2,`0`),a=String(t.getSeconds()).padStart(2,`0`);return t.toDateString()===n.toDateString()?`${r}:${i}:${a}`:`${String(t.getDate()).padStart(2,`0`)}-${String(t.getMonth()+1).padStart(2,`0`)}-${t.getFullYear()} ${r}:${i}:${a}`}function Ae({messages:e,isStreaming:t,sessionError:n,selectionMode:r,selectedItems:i,toggleSelectItem:a,onComponentSubmit:c,remainingSuggestions:l,onSuggestionClick:u,isAtBottom:d,setIsAtBottom:f,isGroup:p,sessionId:m}){let[h,g]=(0,M.useState)(new Set),[_,v]=(0,M.useState)(new Set),y=(0,M.useRef)(null),b=(0,M.useRef)(null),x=(0,M.useRef)(null),S=(0,M.useRef)(!1),E=(0,M.useRef)(!1),D=(0,M.useRef)(!1),O=(0,M.useRef)(0),k=(0,M.useRef)(!1),A=(0,M.useRef)(new Map);k.current=t,(0,M.useEffect)(()=>{t&&!S.current&&d&&(E.current=!0)},[t,d]),(0,M.useEffect)(()=>{if(!E.current&&!d){S.current=t,D.current=!1;return}if(S.current&&!t&&x.current&&b.current){let e=x.current;if(e.offsetHeight>b.current.clientHeight){E.current=!1,D.current=!0,e.scrollIntoView({behavior:`smooth`,block:`start`}),S.current=t;return}}(d||E.current)&&!D.current&&y.current?.scrollIntoView({behavior:`smooth`}),S.current&&!t&&(E.current=!1),S.current=t},[e,d,t]),(0,M.useEffect)(()=>{let e=b.current;if(!e)return;let t=()=>{let t=e.scrollTop;k.current&&t<O.current&&(E.current=!1),O.current=t,f(e.scrollHeight-e.scrollTop-e.clientHeight<80)};return e.addEventListener(`scroll`,t,{passive:!0}),t(),()=>e.removeEventListener(`scroll`,t)},[f]),(0,M.useEffect)(()=>{function e(){v(e=>{let t=new Set;return A.current.forEach((n,r)=>{n.isConnected&&(h.has(r)?e.has(r)&&t.add(r):n.scrollHeight>n.clientHeight+2&&t.add(r))}),e.size===t.size&&[...e].every(e=>t.has(e))?e:t})}e();let t=new ResizeObserver(e);return A.current.forEach(e=>t.observe(e)),()=>t.disconnect()},[e.length,h]);let j=[...e].sort((e,t)=>e.timestamp-t.timestamp);(0,M.useEffect)(()=>{r&&console.log(`[selection] entered`,{conversationId:m??`unknown`,order:j.map(e=>({ts:e.timestamp,role:e.role,id:e.messageId}))})},[r]);let N=j.reduce((e,t,n)=>t.role===`maxy`&&!t.hidden?n:e,-1);return(0,H.jsxs)(`div`,{className:`chat-messages-wrap`,children:[r&&(0,H.jsx)(`div`,{className:`selection-overlay-band`}),(0,H.jsxs)(`div`,{className:`chat-messages`,ref:b,children:[n&&e.length===0&&(0,H.jsx)(`div`,{className:`session-error`,children:(0,H.jsx)(`p`,{children:n})}),j.map((e,n)=>{if(e.hidden)return null;let l=t&&n===j.length-1,u=`${e.timestamp}_${e.role}`,d=i.has(u);return(0,H.jsxs)(`div`,{ref:n===N?x:void 0,className:`message ${e.role}${d?` selected`:``}`,children:[r&&!l&&(0,H.jsx)(`div`,{className:`message-select-check`,children:(0,H.jsx)(C,{checked:d,onChange:()=>a(u)})}),(0,H.jsxs)(`div`,{className:`bubble`,children:[p&&e.role===`visitor`&&e.senderName&&(0,H.jsx)(`span`,{className:`bubble-sender`,children:e.senderName}),e.role===`visitor`&&e.content?(()=>{let t=h.has(n),r=_.has(n);return(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(`div`,{ref:e=>{e?A.current.set(n,e):A.current.delete(n)},className:t?`bubble-content`:`bubble-content clamped${r?` overflowing`:``}`,children:e.content}),r&&(0,H.jsx)(`div`,{className:`bubble-expand`,children:(0,H.jsx)(s,{variant:`icon`,className:t?`expanded`:``,onClick:()=>g(e=>{let t=new Set(e);return t.has(n)?t.delete(n):t.add(n),t}),"aria-label":t?`Collapse message`:`Expand message`,children:(0,H.jsx)(w,{size:14})})})]})})():e.content?(0,H.jsx)(Ce,{content:e.content,timestamp:ke(e.timestamp)}):(0,H.jsxs)(`span`,{className:`typing-indicator`,children:[(0,H.jsx)(`span`,{className:`typing-dot`}),(0,H.jsx)(`span`,{className:`typing-dot`}),(0,H.jsx)(`span`,{className:`typing-dot`})]}),e.attachments&&e.attachments.length>0&&(0,H.jsx)(`div`,{className:`message-attachments`,children:e.attachments.map((e,t)=>(0,H.jsxs)(`span`,{className:`message-attachment-chip no-action`,children:[e.mimeType===`application/pdf`?(0,H.jsx)(o,{size:12}):e.mimeType.startsWith(`text/`)?(0,H.jsx)(T,{size:12}):null,(0,H.jsx)(`span`,{children:e.filename})]},t))}),e.role===`visitor`&&(0,H.jsx)(`span`,{className:`message-timestamp`,children:ke(e.timestamp)})]}),e.role===`maxy`&&e.components&&e.components.length>0&&(0,H.jsx)(`div`,{className:`public-components`,children:e.components.map((e,t)=>(0,H.jsx)(`div`,{className:`public-component-enter`,children:(0,H.jsx)(Oe,{name:e.name,data:e.data,onSubmit:e=>c(n,t,e),submitted:e.submitted})},t))})]},n)}),!t&&l.length>0&&(0,H.jsx)(`div`,{className:`chat-suggestions`,children:l.map(e=>(0,H.jsx)(s,{variant:`suggestion`,onClick:()=>u(e),children:e},e))}),(0,H.jsx)(`div`,{ref:y})]}),!d&&(0,H.jsx)(`button`,{className:`scroll-to-bottom`,onClick:()=>y.current?.scrollIntoView({behavior:`smooth`}),"aria-label":`Scroll to bottom`,children:(0,H.jsx)(w,{size:18})})]})}function je({selectedItems:e,messages:t,isStreaming:n,copySelected:r,selectAll:i,exitSelection:a,showCopyToast:o}){let[s,c]=(0,M.useState)(!1),u=(0,M.useRef)(null),d=(0,M.useRef)(!1);function f(e){let n=e.lastIndexOf(`_`),r=e.slice(0,n),i=e.slice(n+1),a=parseInt(r,10);return t.find(e=>e.timestamp===a&&e.role===i)?.content??``}function p(e,t){return parseInt(e.slice(0,e.lastIndexOf(`_`)),10)-parseInt(t.slice(0,t.lastIndexOf(`_`)),10)}function m(){let e=[...t].sort((e,t)=>e.timestamp-t.timestamp),n=[];for(let t of e){if(t.hidden||!t.content)continue;let e=t.role===`visitor`?`Visitor`:`Maxy`;n.push(`${e}:\n${t.content}`)}return n.join(`
5
+
6
+ ---
7
+
8
+ `)}M.useEffect(()=>{if(!s)return;let e=e=>{e.target.closest(`.selection-copy-wrap`)||c(!1)};return document.addEventListener(`pointerdown`,e),()=>document.removeEventListener(`pointerdown`,e)},[s]);function h(){u.current!==null&&(clearTimeout(u.current),u.current=null)}let g=[...t].sort((e,t)=>e.timestamp-t.timestamp),_=g.reduce((e,t,r)=>(t.hidden||n&&r===g.length-1||e.push(`${t.timestamp}_${t.role}`),e),[]),v=_.length>0&&_.every(t=>e.has(t));return(0,H.jsx)(`div`,{className:`chat-input-area`,children:(0,H.jsxs)(`div`,{className:`selection-bar`,children:[(0,H.jsxs)(`div`,{className:`selection-bar-left`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`selection-select-all`,onClick:()=>i(_),disabled:_.length===0,"aria-label":v?`Deselect all`:`Select all`,title:v?`Deselect all`:`Select all`,children:[(0,H.jsx)(k,{size:16}),(0,H.jsx)(`span`,{children:v?`Deselect all`:`Select all`})]}),(0,H.jsxs)(`span`,{className:`selection-count`,children:[e.size,` Selected`]})]}),(0,H.jsxs)(`div`,{className:`selection-copy-wrap`,children:[(0,H.jsxs)(`button`,{type:`button`,className:`selection-copy`,onPointerDown:()=>{if(s){c(!1);return}d.current=!1,u.current=setTimeout(()=>{d.current=!0,c(!0),u.current=null},500)},onPointerUp:h,onPointerLeave:h,onPointerCancel:h,onClick:async()=>{d.current||await r(f,p)},children:[(0,H.jsx)(x,{size:18}),(0,H.jsx)(`span`,{children:`Copy`})]}),s&&(0,H.jsx)(`div`,{className:`copy-menu`,children:(0,H.jsx)(`button`,{type:`button`,className:`copy-menu-item`,onClick:async()=>{let e=m();e&&o(await l(e)),a()},children:`Copy all`})})]}),(0,H.jsx)(`button`,{type:`button`,className:`selection-cancel`,onClick:a,children:`Cancel`})]})})}var Me=44,Ne=(0,M.forwardRef)(function({value:e,onChange:t,placeholder:n,disabled:r},i){let a=(0,M.useRef)(null),o=(0,M.useRef)(!1),s=(0,M.useCallback)((e,t)=>{let n=e.closest(`.chat-form`);n&&(n.dataset.expanded=t>Me?`true`:``)},[]),c=(0,M.useCallback)(e=>{if(o.current)return;let t=window.innerHeight*.75;e.style.height=`auto`;let n=Math.min(e.scrollHeight,t);e.style.height=`${n}px`,e.style.overflowY=e.scrollHeight>t?`auto`:`hidden`,s(e,n)},[s]);return(0,M.useImperativeHandle)(i,()=>({focus(){a.current?.focus()},resetHeight(){if(!a.current)return;o.current=!1,a.current.style.height=``,a.current.style.overflowY=``;let e=a.current.closest(`.chat-form`);e&&(e.dataset.expanded=``)},getOffsetHeight(){return a.current?.offsetHeight??36},setHeight(e){a.current&&(o.current=!0,a.current.style.height=`${e}px`,s(a.current,e))}})),(0,H.jsx)(`textarea`,{ref:a,className:`chat-input`,rows:1,value:e,onChange:e=>{t(e.target.value),c(e.target)},onKeyDown:e=>{e.key===`Enter`&&!e.shiftKey&&!e.nativeEvent.isComposing&&(e.preventDefault(),e.currentTarget.closest(`form`)?.requestSubmit())},placeholder:n,disabled:r,"aria-label":n||`Type a message...`})});function Pe({inputRef:e}){let t=(0,M.useRef)(null);function n(n){e.current&&(n.preventDefault(),n.target.setPointerCapture(n.pointerId),t.current={startY:n.clientY,startH:e.current.getOffsetHeight()})}function r(n){if(!t.current||!e.current)return;let r=t.current.startY-n.clientY,i=window.innerHeight*.75,a=Math.max(36,Math.min(i,t.current.startH+r));e.current.setHeight(a)}function i(){t.current=null}return(0,H.jsx)(`div`,{className:`chat-resize-handle`,onPointerDown:n,onPointerMove:r,onPointerUp:i,"aria-label":`Resize input`,children:(0,H.jsx)(`div`,{className:`chat-resize-handle-bar`})})}function Fe(e){return`${Math.floor(e/60)}:${(e%60).toString().padStart(2,`0`)}`}function Ie({data:e,active:t}){let n=[];if(e&&e.length>0&&t){let t=Math.floor(e.length/24);for(let r=0;r<24;r++){let i=e[r*t]??128,a=Math.abs(i-128)/128;n.push(Math.max(.15,a))}}else for(let e=0;e<24;e++)n.push(.15);return(0,H.jsx)(`div`,{className:`voice-waveform`,"aria-hidden":`true`,children:n.map((e,t)=>(0,H.jsx)(`div`,{className:`voice-waveform-bar`,style:{height:`${Math.round(e*100)}%`}},t))})}function Le({state:e,elapsedSeconds:t,waveform:r,onTogglePause:i,onDiscard:a,onSend:o}){if(e===`idle`||e===`error`)return null;let c=e===`recording`,l=e===`paused`,u=e===`sending`;return(0,H.jsxs)(`div`,{className:`voice-recorder`,role:`region`,"aria-label":`Voice recording`,"aria-live":`polite`,children:[(0,H.jsx)(`button`,{type:`button`,className:`voice-trash`,onClick:a,disabled:u,"aria-label":`Discard recording`,children:(0,H.jsx)(n,{size:16})}),(0,H.jsx)(`span`,{className:`voice-timer`,"aria-live":`polite`,"aria-atomic":`true`,children:Fe(t)}),(0,H.jsx)(Ie,{data:r,active:c}),(0,H.jsx)(`button`,{type:`button`,className:`voice-pause`,onClick:i,disabled:u,"aria-label":l?`Resume recording`:`Pause recording`,children:l?(0,H.jsx)(d,{size:14}):(0,H.jsx)(O,{size:14})}),(0,H.jsx)(s,{variant:`send`,type:`button`,onClick:o,disabled:u,loading:u,"aria-label":`Send voice note`,children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`line`,{x1:`5`,y1:`12`,x2:`19`,y2:`12`}),(0,H.jsx)(`polyline`,{points:`12 5 19 12 12 19`})]})})]})}var Re=[`audio/ogg;codecs=opus`,`audio/webm;codecs=opus`,`audio/webm`,`audio/mp4`];function ze(){for(let e of Re)if(MediaRecorder.isTypeSupported(e))return e;return``}function Be(e){return e.split(`;`)[0]}function Ve(){let[e,t]=(0,M.useState)(`idle`),[n,r]=(0,M.useState)(0),[i,a]=(0,M.useState)(null),[o,s]=(0,M.useState)(null),c=(0,M.useRef)(null),l=(0,M.useRef)(null),u=(0,M.useRef)([]),d=(0,M.useRef)(``),f=(0,M.useRef)(null),p=(0,M.useRef)(0),m=(0,M.useRef)(0),h=(0,M.useRef)(null),g=(0,M.useRef)(null),_=(0,M.useRef)(0),v=(0,M.useCallback)(()=>{if(f.current&&=(clearInterval(f.current),null),_.current&&=(cancelAnimationFrame(_.current),0),c.current&&c.current.state!==`inactive`)try{c.current.stop()}catch{}c.current=null,u.current=[],l.current&&=(l.current.getTracks().forEach(e=>e.stop()),null),h.current&&(h.current.close().catch(()=>{}),h.current=null,g.current=null),m.current=0,p.current=0},[]);(0,M.useEffect)(()=>v,[v]);let y=(0,M.useCallback)(()=>{p.current=Date.now(),f.current=setInterval(()=>{let e=Date.now()-p.current,t=m.current+e;r(Math.floor(t/1e3))},200)},[]),b=(0,M.useCallback)(()=>{f.current&&=(clearInterval(f.current),null);let e=Date.now()-p.current;m.current+=e},[]),x=(0,M.useCallback)(()=>{let e=g.current;if(!e)return;let t=new Uint8Array(e.frequencyBinCount),n=()=>{e.getByteTimeDomainData(t),a(new Uint8Array(t)),_.current=requestAnimationFrame(n)};n()},[]),S=(0,M.useCallback)(()=>{_.current&&=(cancelAnimationFrame(_.current),0)},[]),C=(0,M.useCallback)(async()=>{if(!(e!==`idle`&&e!==`error`)){if(s(null),typeof window<`u`&&!window.isSecureContext){t(`error`),s(`Voice recording requires a secure connection (HTTPS). Use your tunnel URL for voice notes.`);return}if(typeof navigator>`u`||!navigator.mediaDevices?.getUserMedia){t(`error`),s(`Voice recording is not supported in this browser.`);return}if(typeof MediaRecorder>`u`){t(`error`),s(`Voice recording is not supported in this browser.`);return}try{let e=await navigator.mediaDevices.getUserMedia({audio:!0});l.current=e;let n=new AudioContext;h.current=n;let i=n.createMediaStreamSource(e),o=n.createAnalyser();o.fftSize=256,i.connect(o),g.current=o;let s=ze();d.current=s;let f=new MediaRecorder(e,s?{mimeType:s}:void 0);c.current=f,u.current=[],f.ondataavailable=e=>{e.data.size>0&&u.current.push(e.data)},e.getAudioTracks()[0]?.addEventListener(`ended`,()=>{v(),t(`idle`),r(0),a(null)}),f.start(1e3),t(`recording`),r(0),y(),x()}catch(e){v(),t(`error`),e instanceof DOMException?e.name===`NotAllowedError`?s(`Microphone access was denied. Check your browser permissions to enable voice recording.`):e.name===`NotFoundError`?s(`No microphone found. Connect a microphone to use voice recording.`):s(`Microphone error: ${e.message}`):s(`Could not start recording.`)}}},[e,v,y,x]),w=(0,M.useCallback)(()=>{let n=c.current;n&&(e===`recording`&&n.state===`recording`?(n.pause(),b(),S(),t(`paused`)):e===`paused`&&n.state===`paused`&&(n.resume(),y(),x(),t(`recording`)))},[e,b,y,x,S]),T=(0,M.useCallback)(()=>{e!==`recording`&&e!==`paused`||(v(),t(`idle`),r(0),a(null))},[e,v]),E=(0,M.useCallback)(async()=>{if(e!==`recording`&&e!==`paused`)return null;let n=c.current;if(!n)return null;let i=e===`recording`?Date.now()-p.current:0;return m.current+i<1e3?(T(),null):(t(`sending`),b(),S(),new Promise(e=>{n.onstop=()=>{let i=d.current||n.mimeType||`audio/webm`,o=new Blob(u.current,{type:Be(i)});v(),t(`idle`),r(0),a(null),e(o.size>0?o:null)},n.stop()}))},[e,T,b,S,v]);return(0,M.useEffect)(()=>{if(e!==`error`)return;let n=setTimeout(()=>{t(`idle`),s(null)},8e3);return()=>clearTimeout(n)},[e]),{state:e,elapsedSeconds:n,waveform:i,errorMessage:o,start:C,togglePause:w,discard:T,send:E}}function He({input:e,setInput:t,isStreaming:n,pendingFiles:r,setPendingFiles:i,attachError:a,setAttachError:c,isDragOver:l,setIsDragOver:u,inputRef:d,onSubmit:f,onSendVoiceNote:p}){let m=(0,M.useRef)(null),h=Ve(),_=h.state===`recording`||h.state===`paused`||h.state===`sending`,y=!_&&!n&&!e.trim()&&r.length===0;async function b(){let e=await h.send();if(!e)return;let t=e.type===`audio/ogg`?`.ogg`:e.type===`audio/mp4`?`.m4a`:`.webm`;p(new File([e],`voice-note${t}`,{type:e.type}))}function x(e){c(null);let t=e.map(g),n=t.find(e=>!v(e.type,P));if(n){c(`Unsupported file type: "${n.type}". Supported: images, PDF, plain text, markdown, CSV, calendar, voice notes.`);return}let r=t.find(e=>e.size>F);if(r){c(`"${r.name}" exceeds the 50 MB limit.`);return}i(e=>[...e,...t].slice(0,5))}function S(e){e.preventDefault(),u(!0)}function C(){u(!1)}function w(e){e.preventDefault(),u(!1),x([...e.dataTransfer.files])}return(0,H.jsxs)(`div`,{className:`chat-input-area`,children:[(0,H.jsx)(`input`,{ref:m,type:`file`,multiple:!0,accept:N,style:{display:`none`},onChange:e=>{e.target.files&&x([...e.target.files]),e.target.value=``}}),r.length>0&&(0,H.jsx)(`div`,{className:`attachment-strip`,children:r.map((e,t)=>(0,H.jsxs)(`div`,{className:`attachment-chip`,children:[e.type.startsWith(`image/`)?(0,H.jsx)(`img`,{src:URL.createObjectURL(e),alt:e.name,className:`attachment-chip-thumb`}):e.type.startsWith(`audio/`)?(0,H.jsx)(E,{size:14}):e.type===`application/pdf`?(0,H.jsx)(o,{size:14}):(0,H.jsx)(T,{size:14}),(0,H.jsx)(`span`,{className:`attachment-chip-name`,children:e.name}),(0,H.jsx)(`button`,{type:`button`,className:`attachment-chip-remove`,onClick:()=>i(e=>e.filter((e,n)=>n!==t)),"aria-label":`Remove ${e.name}`,children:`×`})]},t))}),a&&(0,H.jsx)(`p`,{className:`attach-error`,children:a}),h.state===`error`&&h.errorMessage&&(0,H.jsxs)(`p`,{className:`voice-error`,role:`alert`,children:[(0,H.jsx)(E,{size:14}),h.errorMessage]}),(0,H.jsx)(Pe,{inputRef:d}),_?(0,H.jsx)(`div`,{className:`chat-form voice-active`,children:(0,H.jsx)(Le,{state:h.state,elapsedSeconds:h.elapsedSeconds,waveform:h.waveform,onTogglePause:h.togglePause,onDiscard:h.discard,onSend:b})}):(0,H.jsxs)(`form`,{className:`chat-form${l?` drag-over`:``}`,onSubmit:f,onDragOver:S,onDragLeave:C,onDrop:w,onPaste:e=>{let t=e.clipboardData?.items;if(!t)return;let n=[];for(let e of t){if(e.kind!==`file`)continue;let t=e.getAsFile();if(!t)continue;let r=t.type.split(`/`)[1]?.replace(`jpeg`,`jpg`)||`png`;n.push(new File([t],`pasted-image-${Date.now()}.${r}`,{type:t.type}))}n.length>0&&x(n)},children:[(0,H.jsx)(s,{variant:`icon`,type:`button`,onClick:()=>m.current?.click(),disabled:n,"aria-label":`Attach file`,children:(0,H.jsx)(D,{size:14})}),(0,H.jsx)(Ne,{ref:d,value:e,onChange:t}),y?(0,H.jsx)(s,{variant:`send`,type:`button`,onClick:h.start,disabled:n,"aria-label":`Record voice note`,children:(0,H.jsx)(E,{size:14})}):(0,H.jsx)(s,{variant:`send`,type:`submit`,disabled:n||!e.trim()&&r.length===0,"aria-label":`Send message`,children:(0,H.jsxs)(`svg`,{viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,H.jsx)(`line`,{x1:`5`,y1:`12`,x2:`19`,y2:`12`}),(0,H.jsx)(`polyline`,{points:`12 5 19 12 12 19`})]})})]})]})}var $=[];function Ue(){let[e,t]=(0,M.useState)(``),[n,r]=(0,M.useState)([]),[i,a]=(0,M.useState)(!1),[o,s]=(0,M.useState)(null),[l,u]=(0,M.useState)($),[d,f]=(0,M.useState)(!0),m=(0,M.useRef)(null),{selectionMode:h,selectedItems:g,copyToast:v,exitSelection:y,enterSelection:x,toggleSelectItem:S,selectAll:C,copySelected:w,showCopyToast:T}=_(),E=(0,M.useRef)(()=>{}),D=te((0,M.useCallback)(e=>{E.current(e)},[])),{sessionId:O,cacheKeyRef:j,sessionError:N,pageState:P,agentDisplayName:F,agentImage:I,agentImageShape:L,showAgentName:R,branding:z,ensureSession:B,startNewSession:ee,resumedRef:V,resumeMessagesRef:U,groupContext:W,groupSlug:ae}=D,{messages:G,setMessages:K,isStreaming:q,sendMessage:J,sendGreeting:Y,handleComponentSubmit:oe}=ne({cacheKeyRef:j,ensureSession:B,sessionError:N,pageState:P,inputRef:m});(0,M.useEffect)(()=>{E.current=Y},[Y]),re({cacheKeyRef:j,groupSlug:ae,isStreaming:q,setMessages:K}),(0,M.useEffect)(()=>{let e=!1;return(async()=>{let t=await B();if(!e&&t){if(V.current&&U.current&&U.current.length>0){let e=U.current.map(e=>({role:e.role,content:e.content,timestamp:e.timestamp}));e.sort((e,t)=>e.timestamp-t.timestamp),K(e),U.current=null;return}Y(t)}})(),()=>{e=!0}},[]),(0,M.useEffect)(()=>{P===`chat`&&m.current?.focus()},[P]),(0,M.useEffect)(()=>{if(P!==`chat`)return;history.pushState({maxyChat:!0},``);function e(){history.pushState({maxyChat:!0},``)}return window.addEventListener(`popstate`,e),()=>window.removeEventListener(`popstate`,e)},[P]),(0,M.useEffect)(()=>{if(!z)return;let e=document.documentElement;if(z.primaryColor&&(e.style.setProperty(`--sage`,z.primaryColor),e.style.setProperty(`--sage-hover`,z.primaryColor),e.style.setProperty(`--sage-subtle`,z.primaryColor+`14`),e.style.setProperty(`--sage-glow`,z.primaryColor+`26`)),z.accentColor&&e.style.setProperty(`--visitor-bubble`,z.accentColor),z.backgroundColor&&e.style.setProperty(`--bg`,z.backgroundColor),document.title=z.name,z.primaryColor){let e=document.querySelector(`meta[name="theme-color"]`);e||(e=document.createElement(`meta`),e.name=`theme-color`,document.head.appendChild(e)),e.content=z.primaryColor}if(z.faviconUrl){let e=document.querySelector(`link[rel="icon"]`);e||(e=document.createElement(`link`),e.rel=`icon`,document.head.appendChild(e)),e.href=z.faviconUrl}},[z]),(0,M.useEffect)(()=>{function e(e){e.key===`Escape`&&h&&y()}return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[h,y]);function se(){q||(K([]),u($),ee())}function X(e){if(!e&&n.length===0||q)return;K(e=>e.map(e=>e.components?.some(e=>!e.submitted)?{...e,components:e.components.map(e=>e.submitted?e:{...e,submitted:!0})}:e)),u(t=>t.filter(t=>t!==e)),f(!0);let i=[...n];t(``),r([]),s(null),J(e,{files:i})}function Z(t){t.preventDefault(),X(e.trim()),m.current?.resetHeight()}return(0,H.jsxs)(`div`,{className:`chat-page`,children:[(0,H.jsxs)(`header`,{className:`chat-header`,children:[(0,H.jsx)(`img`,{src:I||z?.logoUrl||b,alt:z?.name||c.productName,className:`chat-logo${I&&L===`circle`?` chat-logo--circle`:``}${I&&L===`rounded`?` chat-logo--rounded`:``}`,onError:e=>{e.target.src=z?.logoUrl||b}}),(0,H.jsxs)(`div`,{className:`chat-header-text`,children:[R!==`none`&&(0,H.jsx)(`h1`,{className:`chat-tagline`,children:W?.groupName||R&&F||z?.name||c.productName}),(0,H.jsx)(`p`,{className:`chat-intro`,children:W?`${W.participants.length} participants`:z?.tagline||``}),(0,H.jsx)(`p`,{className:`chat-ai-indicator`,children:`AI assistant`})]}),P===`chat`&&!h&&(0,H.jsxs)(`div`,{className:`chat-header-actions`,children:[(0,H.jsx)(`button`,{className:`chat-header-action`,onClick:se,disabled:q,title:`New conversation`,"aria-label":`New conversation`,children:(0,H.jsx)(A,{size:16})}),(0,H.jsx)(`button`,{className:`chat-header-action`,onClick:x,title:`Select messages`,"aria-label":`Select messages`,children:(0,H.jsx)(k,{size:16})})]})]}),P===`loading`&&(0,H.jsx)(`div`,{className:`gate-wrap`,children:(0,H.jsx)(`div`,{className:`gate-loading`,children:(0,H.jsx)(`span`,{className:`spinner`})})}),P===`auth-required`&&(0,H.jsx)(ie,{gateState:D.gateState,setGateState:D.setGateState,grantInfo:D.grantInfo,setGrantInfo:D.setGrantInfo,gateCacheKeyRef:D.gateCacheKeyRef,resolvedSlugRef:D.resolvedSlugRef,onAuthenticated:D.enterChat}),P===`chat`&&(0,H.jsxs)(H.Fragment,{children:[(0,H.jsx)(Ae,{messages:G,isStreaming:q,sessionError:N,selectionMode:h,selectedItems:g,toggleSelectItem:S,onComponentSubmit:oe,remainingSuggestions:l,onSuggestionClick:X,isAtBottom:d,setIsAtBottom:f,isGroup:!!W,sessionId:O}),h?(0,H.jsx)(je,{selectedItems:g,messages:G,isStreaming:q,copySelected:w,selectAll:C,exitSelection:y,showCopyToast:T}):(0,H.jsx)(He,{input:e,setInput:t,isStreaming:q,pendingFiles:n,setPendingFiles:r,attachError:o,setAttachError:s,isDragOver:i,setIsDragOver:a,inputRef:m,onSubmit:Z,onSendVoiceNote:e=>{t(``),r([]),s(null),J(`[Voice note]`,{files:[e]})}})]}),v&&(0,H.jsx)(`span`,{className:`copy-toast${v===`failed`?` copy-toast-failed`:``}`,children:v===`copied`?`Copied`:`Copy failed`}),(0,H.jsxs)(`footer`,{className:`chat-footer`,children:[(0,H.jsxs)(`a`,{href:p,children:[c.domain,` `,`↗`]}),O&&(0,H.jsxs)(`span`,{style:{opacity:.35,fontSize:`10px`,fontFamily:`monospace`,marginLeft:`1rem`},children:[`Conversation · `,O.slice(0,8)]})]})]})}(0,j.createRoot)(document.getElementById(`root`)).render((0,H.jsx)(Ue,{}));export{ce as t};
@@ -0,0 +1,7 @@
1
+ import{g as e,h as t,p as n}from"./src-B6XdH6xq.js";import{B as r,C as i,E as a,L as o,V as s,W as c,_ as l,a as u,b as d,c as f,d as p,v as m}from"./chunk-ICPOFSXX-C5_hbB6H.js";import{t as h}from"./linear-0O14Y6uf.js";import"./defaultLocale-_WRwicXn.js";var g=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,3],r=[1,4],i=[1,5],a=[1,6],o=[1,7],s=[1,4,5,10,12,13,14,18,25,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],c=[1,4,5,10,12,13,14,18,25,28,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],l=[55,56,57],u=[2,36],d=[1,37],f=[1,36],p=[1,38],m=[1,35],h=[1,43],g=[1,41],_=[1,14],v=[1,23],y=[1,18],b=[1,19],x=[1,20],S=[1,21],C=[1,22],w=[1,24],T=[1,25],E=[1,26],D=[1,27],O=[1,28],k=[1,29],A=[1,32],j=[1,33],M=[1,34],N=[1,39],P=[1,40],F=[1,42],I=[1,44],L=[1,62],R=[1,61],z=[4,5,8,10,12,13,14,18,44,47,49,55,56,57,63,64,65,66,67],B=[1,65],ee=[1,66],te=[1,67],ne=[1,68],re=[1,69],ie=[1,70],ae=[1,71],oe=[1,72],se=[1,73],ce=[1,74],le=[1,75],ue=[1,76],V=[4,5,6,7,8,9,10,11,12,13,14,15,18],H=[1,90],U=[1,91],W=[1,92],G=[1,99],K=[1,93],q=[1,96],J=[1,94],Y=[1,95],X=[1,97],Z=[1,98],de=[1,102],fe=[10,55,56,57],Q=[4,5,6,8,10,11,13,17,18,19,20,55,56,57],pe={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,idStringToken:3,ALPHA:4,NUM:5,NODE_STRING:6,DOWN:7,MINUS:8,DEFAULT:9,COMMA:10,COLON:11,AMP:12,BRKT:13,MULT:14,UNICODE_TEXT:15,styleComponent:16,UNIT:17,SPACE:18,STYLE:19,PCT:20,idString:21,style:22,stylesOpt:23,classDefStatement:24,CLASSDEF:25,start:26,eol:27,QUADRANT:28,document:29,line:30,statement:31,axisDetails:32,quadrantDetails:33,points:34,title:35,title_value:36,acc_title:37,acc_title_value:38,acc_descr:39,acc_descr_value:40,acc_descr_multiline_value:41,section:42,text:43,point_start:44,point_x:45,point_y:46,class_name:47,"X-AXIS":48,"AXIS-TEXT-DELIMITER":49,"Y-AXIS":50,QUADRANT_1:51,QUADRANT_2:52,QUADRANT_3:53,QUADRANT_4:54,NEWLINE:55,SEMI:56,EOF:57,alphaNumToken:58,textNoTagsToken:59,STR:60,MD_STR:61,alphaNum:62,PUNCTUATION:63,PLUS:64,EQUALS:65,DOT:66,UNDERSCORE:67,$accept:0,$end:1},terminals_:{2:`error`,4:`ALPHA`,5:`NUM`,6:`NODE_STRING`,7:`DOWN`,8:`MINUS`,9:`DEFAULT`,10:`COMMA`,11:`COLON`,12:`AMP`,13:`BRKT`,14:`MULT`,15:`UNICODE_TEXT`,17:`UNIT`,18:`SPACE`,19:`STYLE`,20:`PCT`,25:`CLASSDEF`,28:`QUADRANT`,35:`title`,36:`title_value`,37:`acc_title`,38:`acc_title_value`,39:`acc_descr`,40:`acc_descr_value`,41:`acc_descr_multiline_value`,42:`section`,44:`point_start`,45:`point_x`,46:`point_y`,47:`class_name`,48:`X-AXIS`,49:`AXIS-TEXT-DELIMITER`,50:`Y-AXIS`,51:`QUADRANT_1`,52:`QUADRANT_2`,53:`QUADRANT_3`,54:`QUADRANT_4`,55:`NEWLINE`,56:`SEMI`,57:`EOF`,60:`STR`,61:`MD_STR`,63:`PUNCTUATION`,64:`PLUS`,65:`EQUALS`,66:`DOT`,67:`UNDERSCORE`},productions_:[0,[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[21,1],[21,2],[22,1],[22,2],[23,1],[23,3],[24,5],[26,2],[26,2],[26,2],[29,0],[29,2],[30,2],[31,0],[31,1],[31,2],[31,1],[31,1],[31,1],[31,2],[31,2],[31,2],[31,1],[31,1],[34,4],[34,5],[34,5],[34,6],[32,4],[32,3],[32,2],[32,4],[32,3],[32,2],[33,2],[33,2],[33,2],[33,2],[27,1],[27,1],[27,1],[43,1],[43,2],[43,1],[43,1],[62,1],[62,2],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[59,1],[59,1],[59,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 23:this.$=a[s];break;case 24:this.$=a[s-1]+``+a[s];break;case 26:this.$=a[s-1]+a[s];break;case 27:this.$=[a[s].trim()];break;case 28:a[s-2].push(a[s].trim()),this.$=a[s-2];break;case 29:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 37:this.$=[];break;case 42:this.$=a[s].trim(),r.setDiagramTitle(this.$);break;case 43:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 44:case 45:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 46:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 47:r.addPoint(a[s-3],``,a[s-1],a[s],[]);break;case 48:r.addPoint(a[s-4],a[s-3],a[s-1],a[s],[]);break;case 49:r.addPoint(a[s-4],``,a[s-2],a[s-1],a[s]);break;case 50:r.addPoint(a[s-5],a[s-4],a[s-2],a[s-1],a[s]);break;case 51:r.setXAxisLeftText(a[s-2]),r.setXAxisRightText(a[s]);break;case 52:a[s-1].text+=` ⟶ `,r.setXAxisLeftText(a[s-1]);break;case 53:r.setXAxisLeftText(a[s]);break;case 54:r.setYAxisBottomText(a[s-2]),r.setYAxisTopText(a[s]);break;case 55:a[s-1].text+=` ⟶ `,r.setYAxisBottomText(a[s-1]);break;case 56:r.setYAxisBottomText(a[s]);break;case 57:r.setQuadrant1Text(a[s]);break;case 58:r.setQuadrant2Text(a[s]);break;case 59:r.setQuadrant3Text(a[s]);break;case 60:r.setQuadrant4Text(a[s]);break;case 64:this.$={text:a[s],type:`text`};break;case 65:this.$={text:a[s-1].text+``+a[s],type:a[s-1].type};break;case 66:this.$={text:a[s],type:`text`};break;case 67:this.$={text:a[s],type:`markdown`};break;case 68:this.$=a[s];break;case 69:this.$=a[s-1]+``+a[s];break}},`anonymous`),table:[{18:n,26:1,27:2,28:r,55:i,56:a,57:o},{1:[3]},{18:n,26:8,27:2,28:r,55:i,56:a,57:o},{18:n,26:9,27:2,28:r,55:i,56:a,57:o},e(s,[2,33],{29:10}),e(c,[2,61]),e(c,[2,62]),e(c,[2,63]),{1:[2,30]},{1:[2,31]},e(l,u,{30:11,31:12,24:13,32:15,33:16,34:17,43:30,58:31,1:[2,32],4:d,5:f,10:p,12:m,13:h,14:g,18:_,25:v,35:y,37:b,39:x,41:S,42:C,48:w,50:T,51:E,52:D,53:O,54:k,60:A,61:j,63:M,64:N,65:P,66:F,67:I}),e(s,[2,34]),{27:45,55:i,56:a,57:o},e(l,[2,37]),e(l,u,{24:13,32:15,33:16,34:17,43:30,58:31,31:46,4:d,5:f,10:p,12:m,13:h,14:g,18:_,25:v,35:y,37:b,39:x,41:S,42:C,48:w,50:T,51:E,52:D,53:O,54:k,60:A,61:j,63:M,64:N,65:P,66:F,67:I}),e(l,[2,39]),e(l,[2,40]),e(l,[2,41]),{36:[1,47]},{38:[1,48]},{40:[1,49]},e(l,[2,45]),e(l,[2,46]),{18:[1,50]},{4:d,5:f,10:p,12:m,13:h,14:g,43:51,58:31,60:A,61:j,63:M,64:N,65:P,66:F,67:I},{4:d,5:f,10:p,12:m,13:h,14:g,43:52,58:31,60:A,61:j,63:M,64:N,65:P,66:F,67:I},{4:d,5:f,10:p,12:m,13:h,14:g,43:53,58:31,60:A,61:j,63:M,64:N,65:P,66:F,67:I},{4:d,5:f,10:p,12:m,13:h,14:g,43:54,58:31,60:A,61:j,63:M,64:N,65:P,66:F,67:I},{4:d,5:f,10:p,12:m,13:h,14:g,43:55,58:31,60:A,61:j,63:M,64:N,65:P,66:F,67:I},{4:d,5:f,10:p,12:m,13:h,14:g,43:56,58:31,60:A,61:j,63:M,64:N,65:P,66:F,67:I},{4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,44:[1,57],47:[1,58],58:60,59:59,63:M,64:N,65:P,66:F,67:I},e(z,[2,64]),e(z,[2,66]),e(z,[2,67]),e(z,[2,70]),e(z,[2,71]),e(z,[2,72]),e(z,[2,73]),e(z,[2,74]),e(z,[2,75]),e(z,[2,76]),e(z,[2,77]),e(z,[2,78]),e(z,[2,79]),e(z,[2,80]),e(s,[2,35]),e(l,[2,38]),e(l,[2,42]),e(l,[2,43]),e(l,[2,44]),{3:64,4:B,5:ee,6:te,7:ne,8:re,9:ie,10:ae,11:oe,12:se,13:ce,14:le,15:ue,21:63},e(l,[2,53],{59:59,58:60,4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,49:[1,77],63:M,64:N,65:P,66:F,67:I}),e(l,[2,56],{59:59,58:60,4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,49:[1,78],63:M,64:N,65:P,66:F,67:I}),e(l,[2,57],{59:59,58:60,4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,63:M,64:N,65:P,66:F,67:I}),e(l,[2,58],{59:59,58:60,4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,63:M,64:N,65:P,66:F,67:I}),e(l,[2,59],{59:59,58:60,4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,63:M,64:N,65:P,66:F,67:I}),e(l,[2,60],{59:59,58:60,4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,63:M,64:N,65:P,66:F,67:I}),{45:[1,79]},{44:[1,80]},e(z,[2,65]),e(z,[2,81]),e(z,[2,82]),e(z,[2,83]),{3:82,4:B,5:ee,6:te,7:ne,8:re,9:ie,10:ae,11:oe,12:se,13:ce,14:le,15:ue,18:[1,81]},e(V,[2,23]),e(V,[2,1]),e(V,[2,2]),e(V,[2,3]),e(V,[2,4]),e(V,[2,5]),e(V,[2,6]),e(V,[2,7]),e(V,[2,8]),e(V,[2,9]),e(V,[2,10]),e(V,[2,11]),e(V,[2,12]),e(l,[2,52],{58:31,43:83,4:d,5:f,10:p,12:m,13:h,14:g,60:A,61:j,63:M,64:N,65:P,66:F,67:I}),e(l,[2,55],{58:31,43:84,4:d,5:f,10:p,12:m,13:h,14:g,60:A,61:j,63:M,64:N,65:P,66:F,67:I}),{46:[1,85]},{45:[1,86]},{4:H,5:U,6:W,8:G,11:K,13:q,16:89,17:J,18:Y,19:X,20:Z,22:88,23:87},e(V,[2,24]),e(l,[2,51],{59:59,58:60,4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,63:M,64:N,65:P,66:F,67:I}),e(l,[2,54],{59:59,58:60,4:d,5:f,8:L,10:p,12:m,13:h,14:g,18:R,63:M,64:N,65:P,66:F,67:I}),e(l,[2,47],{22:88,16:89,23:100,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),{46:[1,101]},e(l,[2,29],{10:de}),e(fe,[2,27],{16:103,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),e(Q,[2,25]),e(Q,[2,13]),e(Q,[2,14]),e(Q,[2,15]),e(Q,[2,16]),e(Q,[2,17]),e(Q,[2,18]),e(Q,[2,19]),e(Q,[2,20]),e(Q,[2,21]),e(Q,[2,22]),e(l,[2,49],{10:de}),e(l,[2,48],{22:88,16:89,23:104,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z}),{4:H,5:U,6:W,8:G,11:K,13:q,16:89,17:J,18:Y,19:X,20:Z,22:105},e(Q,[2,26]),e(l,[2,50],{10:de}),e(fe,[2,28],{16:103,4:H,5:U,6:W,8:G,11:K,13:q,17:J,18:Y,19:X,20:Z})],defaultActions:{8:[2,30],9:[2,31]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;typeof g.yy.parseError==`function`?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`:
2
+ `+h.showPosition()+`
3
+ Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};pe.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
+ `+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
5
+ `+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}else return!1}else if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e===!1?!1:e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
6
+ `+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:break;case 1:break;case 2:return 55;case 3:break;case 4:return this.begin(`title`),35;case 5:return this.popState(),`title_value`;case 6:return this.begin(`acc_title`),37;case 7:return this.popState(),`acc_title_value`;case 8:return this.begin(`acc_descr`),39;case 9:return this.popState(),`acc_descr_value`;case 10:this.begin(`acc_descr_multiline`);break;case 11:this.popState();break;case 12:return`acc_descr_multiline_value`;case 13:return 48;case 14:return 50;case 15:return 49;case 16:return 51;case 17:return 52;case 18:return 53;case 19:return 54;case 20:return 25;case 21:this.begin(`md_string`);break;case 22:return`MD_STR`;case 23:this.popState();break;case 24:this.begin(`string`);break;case 25:this.popState();break;case 26:return`STR`;case 27:this.begin(`class_name`);break;case 28:return this.popState(),47;case 29:return this.begin(`point_start`),44;case 30:return this.begin(`point_x`),45;case 31:this.popState();break;case 32:this.popState(),this.begin(`point_y`);break;case 33:return this.popState(),46;case 34:return 28;case 35:return 4;case 36:return 11;case 37:return 64;case 38:return 10;case 39:return 65;case 40:return 65;case 41:return 14;case 42:return 13;case 43:return 67;case 44:return 66;case 45:return 12;case 46:return 8;case 47:return 5;case 48:return 18;case 49:return 56;case 50:return 63;case 51:return 57}},`anonymous`),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?: *x-axis *)/i,/^(?: *y-axis *)/i,/^(?: *--+> *)/i,/^(?: *quadrant-1 *)/i,/^(?: *quadrant-2 *)/i,/^(?: *quadrant-3 *)/i,/^(?: *quadrant-4 *)/i,/^(?:classDef\b)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?::::)/i,/^(?:^\w+)/i,/^(?:\s*:\s*\[\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?:\s*\] *)/i,/^(?:\s*,\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?: *quadrantChart *)/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s)/i,/^(?:;)/i,/^(?:[!"#$%&'*+,-.`?\\_/])/i,/^(?:$)/i],conditions:{class_name:{rules:[28],inclusive:!1},point_y:{rules:[33],inclusive:!1},point_x:{rules:[32],inclusive:!1},point_start:{rules:[30,31],inclusive:!1},acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},title:{rules:[5],inclusive:!1},md_string:{rules:[22,23],inclusive:!1},string:{rules:[25,26],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,6,8,10,13,14,15,16,17,18,19,20,21,24,27,29,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51],inclusive:!0}}}})();function $(){this.yy={}}return t($,`Parser`),$.prototype=pe,pe.Parser=$,new $})();g.parser=g;var _=g,v=a(),y=class{constructor(){this.classes=new Map,this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData()}static{t(this,`QuadrantBuilder`)}getDefaultData(){return{titleText:``,quadrant1Text:``,quadrant2Text:``,quadrant3Text:``,quadrant4Text:``,xAxisLeftText:``,xAxisRightText:``,yAxisBottomText:``,yAxisTopText:``,points:[]}}getDefaultConfig(){return{showXAxis:!0,showYAxis:!0,showTitle:!0,chartHeight:p.quadrantChart?.chartWidth||500,chartWidth:p.quadrantChart?.chartHeight||500,titlePadding:p.quadrantChart?.titlePadding||10,titleFontSize:p.quadrantChart?.titleFontSize||20,quadrantPadding:p.quadrantChart?.quadrantPadding||5,xAxisLabelPadding:p.quadrantChart?.xAxisLabelPadding||5,yAxisLabelPadding:p.quadrantChart?.yAxisLabelPadding||5,xAxisLabelFontSize:p.quadrantChart?.xAxisLabelFontSize||16,yAxisLabelFontSize:p.quadrantChart?.yAxisLabelFontSize||16,quadrantLabelFontSize:p.quadrantChart?.quadrantLabelFontSize||16,quadrantTextTopPadding:p.quadrantChart?.quadrantTextTopPadding||5,pointTextPadding:p.quadrantChart?.pointTextPadding||5,pointLabelFontSize:p.quadrantChart?.pointLabelFontSize||12,pointRadius:p.quadrantChart?.pointRadius||5,xAxisPosition:p.quadrantChart?.xAxisPosition||`top`,yAxisPosition:p.quadrantChart?.yAxisPosition||`left`,quadrantInternalBorderStrokeWidth:p.quadrantChart?.quadrantInternalBorderStrokeWidth||1,quadrantExternalBorderStrokeWidth:p.quadrantChart?.quadrantExternalBorderStrokeWidth||2}}getDefaultThemeConfig(){return{quadrant1Fill:v.quadrant1Fill,quadrant2Fill:v.quadrant2Fill,quadrant3Fill:v.quadrant3Fill,quadrant4Fill:v.quadrant4Fill,quadrant1TextFill:v.quadrant1TextFill,quadrant2TextFill:v.quadrant2TextFill,quadrant3TextFill:v.quadrant3TextFill,quadrant4TextFill:v.quadrant4TextFill,quadrantPointFill:v.quadrantPointFill,quadrantPointTextFill:v.quadrantPointTextFill,quadrantXAxisTextFill:v.quadrantXAxisTextFill,quadrantYAxisTextFill:v.quadrantYAxisTextFill,quadrantTitleFill:v.quadrantTitleFill,quadrantInternalBorderStrokeFill:v.quadrantInternalBorderStrokeFill,quadrantExternalBorderStrokeFill:v.quadrantExternalBorderStrokeFill}}clear(){this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData(),this.classes=new Map,e.info(`clear called`)}setData(e){this.data={...this.data,...e}}addPoints(e){this.data.points=[...e,...this.data.points]}addClass(e,t){this.classes.set(e,t)}setConfig(t){e.trace(`setConfig called with: `,t),this.config={...this.config,...t}}setThemeConfig(t){e.trace(`setThemeConfig called with: `,t),this.themeConfig={...this.themeConfig,...t}}calculateSpace(e,t,n,r){let i=this.config.xAxisLabelPadding*2+this.config.xAxisLabelFontSize,a={top:e===`top`&&t?i:0,bottom:e===`bottom`&&t?i:0},o=this.config.yAxisLabelPadding*2+this.config.yAxisLabelFontSize,s={left:this.config.yAxisPosition===`left`&&n?o:0,right:this.config.yAxisPosition===`right`&&n?o:0},c=this.config.titleFontSize+this.config.titlePadding*2,l={top:r?c:0},u=this.config.quadrantPadding+s.left,d=this.config.quadrantPadding+a.top+l.top,f=this.config.chartWidth-this.config.quadrantPadding*2-s.left-s.right,p=this.config.chartHeight-this.config.quadrantPadding*2-a.top-a.bottom-l.top;return{xAxisSpace:a,yAxisSpace:s,titleSpace:l,quadrantSpace:{quadrantLeft:u,quadrantTop:d,quadrantWidth:f,quadrantHalfWidth:f/2,quadrantHeight:p,quadrantHalfHeight:p/2}}}getAxisLabels(e,t,n,r){let{quadrantSpace:i,titleSpace:a}=r,{quadrantHalfHeight:o,quadrantHeight:s,quadrantLeft:c,quadrantHalfWidth:l,quadrantTop:u,quadrantWidth:d}=i,f=!!this.data.xAxisRightText,p=!!this.data.yAxisTopText,m=[];return this.data.xAxisLeftText&&t&&m.push({text:this.data.xAxisLeftText,fill:this.themeConfig.quadrantXAxisTextFill,x:c+(f?l/2:0),y:e===`top`?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+u+s+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:f?`center`:`left`,horizontalPos:`top`,rotation:0}),this.data.xAxisRightText&&t&&m.push({text:this.data.xAxisRightText,fill:this.themeConfig.quadrantXAxisTextFill,x:c+l+(f?l/2:0),y:e===`top`?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+u+s+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:f?`center`:`left`,horizontalPos:`top`,rotation:0}),this.data.yAxisBottomText&&n&&m.push({text:this.data.yAxisBottomText,fill:this.themeConfig.quadrantYAxisTextFill,x:this.config.yAxisPosition===`left`?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+c+d+this.config.quadrantPadding,y:u+s-(p?o/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?`center`:`left`,horizontalPos:`top`,rotation:-90}),this.data.yAxisTopText&&n&&m.push({text:this.data.yAxisTopText,fill:this.themeConfig.quadrantYAxisTextFill,x:this.config.yAxisPosition===`left`?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+c+d+this.config.quadrantPadding,y:u+o-(p?o/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?`center`:`left`,horizontalPos:`top`,rotation:-90}),m}getQuadrants(e){let{quadrantSpace:t}=e,{quadrantHalfHeight:n,quadrantLeft:r,quadrantHalfWidth:i,quadrantTop:a}=t,o=[{text:{text:this.data.quadrant1Text,fill:this.themeConfig.quadrant1TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r+i,y:a,width:i,height:n,fill:this.themeConfig.quadrant1Fill},{text:{text:this.data.quadrant2Text,fill:this.themeConfig.quadrant2TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r,y:a,width:i,height:n,fill:this.themeConfig.quadrant2Fill},{text:{text:this.data.quadrant3Text,fill:this.themeConfig.quadrant3TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant3Fill},{text:{text:this.data.quadrant4Text,fill:this.themeConfig.quadrant4TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:`center`,horizontalPos:`middle`,rotation:0},x:r+i,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant4Fill}];for(let e of o)e.text.x=e.x+e.width/2,this.data.points.length===0?(e.text.y=e.y+e.height/2,e.text.horizontalPos=`middle`):(e.text.y=e.y+this.config.quadrantTextTopPadding,e.text.horizontalPos=`top`);return o}getQuadrantPoints(e){let{quadrantSpace:t}=e,{quadrantHeight:n,quadrantLeft:r,quadrantTop:i,quadrantWidth:a}=t,o=h().domain([0,1]).range([r,a+r]),s=h().domain([0,1]).range([n+i,i]);return this.data.points.map(e=>{let t=this.classes.get(e.className);return t&&(e={...t,...e}),{x:o(e.x),y:s(e.y),fill:e.color??this.themeConfig.quadrantPointFill,radius:e.radius??this.config.pointRadius,text:{text:e.text,fill:this.themeConfig.quadrantPointTextFill,x:o(e.x),y:s(e.y)+this.config.pointTextPadding,verticalPos:`center`,horizontalPos:`top`,fontSize:this.config.pointLabelFontSize,rotation:0},strokeColor:e.strokeColor??this.themeConfig.quadrantPointFill,strokeWidth:e.strokeWidth??`0px`}})}getBorders(e){let t=this.config.quadrantExternalBorderStrokeWidth/2,{quadrantSpace:n}=e,{quadrantHalfHeight:r,quadrantHeight:i,quadrantLeft:a,quadrantHalfWidth:o,quadrantTop:s,quadrantWidth:c}=n;return[{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-t,y1:s,x2:a+c+t,y2:s},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a+c,y1:s+t,x2:a+c,y2:s+i-t},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-t,y1:s+i,x2:a+c+t,y2:s+i},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a,y1:s+t,x2:a,y2:s+i-t},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+o,y1:s+t,x2:a+o,y2:s+i-t},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+t,y1:s+r,x2:a+c-t,y2:s+r}]}getTitle(e){if(e)return{text:this.data.titleText,fill:this.themeConfig.quadrantTitleFill,fontSize:this.config.titleFontSize,horizontalPos:`top`,verticalPos:`center`,rotation:0,y:this.config.titlePadding,x:this.config.chartWidth/2}}build(){let e=this.config.showXAxis&&!!(this.data.xAxisLeftText||this.data.xAxisRightText),t=this.config.showYAxis&&!!(this.data.yAxisTopText||this.data.yAxisBottomText),n=this.config.showTitle&&!!this.data.titleText,r=this.data.points.length>0?`bottom`:this.config.xAxisPosition,i=this.calculateSpace(r,e,t,n);return{points:this.getQuadrantPoints(i),quadrants:this.getQuadrants(i),axisLabels:this.getAxisLabels(r,e,t,i),borderLines:this.getBorders(i),title:this.getTitle(n)}}},b=class extends Error{static{t(this,`InvalidStyleError`)}constructor(e,t,n){super(`value for ${e} ${t} is invalid, please use a valid ${n}`),this.name=`InvalidStyleError`}};function x(e){return!/^#?([\dA-Fa-f]{6}|[\dA-Fa-f]{3})$/.test(e)}t(x,`validateHexCode`);function S(e){return!/^\d+$/.test(e)}t(S,`validateNumber`);function C(e){return!/^\d+px$/.test(e)}t(C,`validateSizeInPixels`);var w=d();function T(e){return o(e.trim(),w)}t(T,`textSanitizer`);var E=new y;function D(e){E.setData({quadrant1Text:T(e.text)})}t(D,`setQuadrant1Text`);function O(e){E.setData({quadrant2Text:T(e.text)})}t(O,`setQuadrant2Text`);function k(e){E.setData({quadrant3Text:T(e.text)})}t(k,`setQuadrant3Text`);function A(e){E.setData({quadrant4Text:T(e.text)})}t(A,`setQuadrant4Text`);function j(e){E.setData({xAxisLeftText:T(e.text)})}t(j,`setXAxisLeftText`);function M(e){E.setData({xAxisRightText:T(e.text)})}t(M,`setXAxisRightText`);function N(e){E.setData({yAxisTopText:T(e.text)})}t(N,`setYAxisTopText`);function P(e){E.setData({yAxisBottomText:T(e.text)})}t(P,`setYAxisBottomText`);function F(e){let t={};for(let n of e){let[e,r]=n.trim().split(/\s*:\s*/);if(e===`radius`){if(S(r))throw new b(e,r,`number`);t.radius=parseInt(r)}else if(e===`color`){if(x(r))throw new b(e,r,`hex code`);t.color=r}else if(e===`stroke-color`){if(x(r))throw new b(e,r,`hex code`);t.strokeColor=r}else if(e===`stroke-width`){if(C(r))throw new b(e,r,`number of pixels (eg. 10px)`);t.strokeWidth=r}else throw Error(`style named ${e} is not supported.`)}return t}t(F,`parseStyles`);function I(e,t,n,r,i){let a=F(i);E.addPoints([{x:n,y:r,text:T(e.text),className:t,...a}])}t(I,`addPoint`);function L(e,t){E.addClass(e,F(t))}t(L,`addClass`);function R(e){E.setConfig({chartWidth:e})}t(R,`setWidth`);function z(e){E.setConfig({chartHeight:e})}t(z,`setHeight`);function B(){let{themeVariables:e,quadrantChart:t}=d();return t&&E.setConfig(t),E.setThemeConfig({quadrant1Fill:e.quadrant1Fill,quadrant2Fill:e.quadrant2Fill,quadrant3Fill:e.quadrant3Fill,quadrant4Fill:e.quadrant4Fill,quadrant1TextFill:e.quadrant1TextFill,quadrant2TextFill:e.quadrant2TextFill,quadrant3TextFill:e.quadrant3TextFill,quadrant4TextFill:e.quadrant4TextFill,quadrantPointFill:e.quadrantPointFill,quadrantPointTextFill:e.quadrantPointTextFill,quadrantXAxisTextFill:e.quadrantXAxisTextFill,quadrantYAxisTextFill:e.quadrantYAxisTextFill,quadrantExternalBorderStrokeFill:e.quadrantExternalBorderStrokeFill,quadrantInternalBorderStrokeFill:e.quadrantInternalBorderStrokeFill,quadrantTitleFill:e.quadrantTitleFill}),E.setData({titleText:i()}),E.build()}t(B,`getQuadrantData`);var ee={parser:_,db:{setWidth:R,setHeight:z,setQuadrant1Text:D,setQuadrant2Text:O,setQuadrant3Text:k,setQuadrant4Text:A,setXAxisLeftText:j,setXAxisRightText:M,setYAxisTopText:N,setYAxisBottomText:P,parseStyles:F,addPoint:I,addClass:L,getQuadrantData:B,clear:t(function(){E.clear(),u()},`clear`),setAccTitle:s,getAccTitle:m,setDiagramTitle:c,getDiagramTitle:i,getAccDescription:l,setAccDescription:r},renderer:{draw:t((r,i,a,o)=>{function s(e){return e===`top`?`hanging`:`middle`}t(s,`getDominantBaseLine`);function c(e){return e===`left`?`start`:`middle`}t(c,`getTextAnchor`);function l(e){return`translate(${e.x}, ${e.y}) rotate(${e.rotation||0})`}t(l,`getTransformation`);let u=d();e.debug(`Rendering quadrant chart
7
+ `+r);let p=u.securityLevel,m;p===`sandbox`&&(m=n(`#i`+i));let h=n(p===`sandbox`?m.nodes()[0].contentDocument.body:`body`).select(`[id="${i}"]`),g=h.append(`g`).attr(`class`,`main`),_=u.quadrantChart?.chartWidth??500,v=u.quadrantChart?.chartHeight??500;f(h,v,_,u.quadrantChart?.useMaxWidth??!0),h.attr(`viewBox`,`0 0 `+_+` `+v),o.db.setHeight(v),o.db.setWidth(_);let y=o.db.getQuadrantData(),b=g.append(`g`).attr(`class`,`quadrants`),x=g.append(`g`).attr(`class`,`border`),S=g.append(`g`).attr(`class`,`data-points`),C=g.append(`g`).attr(`class`,`labels`),w=g.append(`g`).attr(`class`,`title`);y.title&&w.append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,y.title.fill).attr(`font-size`,y.title.fontSize).attr(`dominant-baseline`,s(y.title.horizontalPos)).attr(`text-anchor`,c(y.title.verticalPos)).attr(`transform`,l(y.title)).text(y.title.text),y.borderLines&&x.selectAll(`line`).data(y.borderLines).enter().append(`line`).attr(`x1`,e=>e.x1).attr(`y1`,e=>e.y1).attr(`x2`,e=>e.x2).attr(`y2`,e=>e.y2).style(`stroke`,e=>e.strokeFill).style(`stroke-width`,e=>e.strokeWidth);let T=b.selectAll(`g.quadrant`).data(y.quadrants).enter().append(`g`).attr(`class`,`quadrant`);T.append(`rect`).attr(`x`,e=>e.x).attr(`y`,e=>e.y).attr(`width`,e=>e.width).attr(`height`,e=>e.height).attr(`fill`,e=>e.fill),T.append(`text`).attr(`x`,0).attr(`y`,0).attr(`fill`,e=>e.text.fill).attr(`font-size`,e=>e.text.fontSize).attr(`dominant-baseline`,e=>s(e.text.horizontalPos)).attr(`text-anchor`,e=>c(e.text.verticalPos)).attr(`transform`,e=>l(e.text)).text(e=>e.text.text),C.selectAll(`g.label`).data(y.axisLabels).enter().append(`g`).attr(`class`,`label`).append(`text`).attr(`x`,0).attr(`y`,0).text(e=>e.text).attr(`fill`,e=>e.fill).attr(`font-size`,e=>e.fontSize).attr(`dominant-baseline`,e=>s(e.horizontalPos)).attr(`text-anchor`,e=>c(e.verticalPos)).attr(`transform`,e=>l(e));let E=S.selectAll(`g.data-point`).data(y.points).enter().append(`g`).attr(`class`,`data-point`);E.append(`circle`).attr(`cx`,e=>e.x).attr(`cy`,e=>e.y).attr(`r`,e=>e.radius).attr(`fill`,e=>e.fill).attr(`stroke`,e=>e.strokeColor).attr(`stroke-width`,e=>e.strokeWidth),E.append(`text`).attr(`x`,0).attr(`y`,0).text(e=>e.text.text).attr(`fill`,e=>e.text.fill).attr(`font-size`,e=>e.text.fontSize).attr(`dominant-baseline`,e=>s(e.text.horizontalPos)).attr(`text-anchor`,e=>c(e.text.verticalPos)).attr(`transform`,e=>l(e.text))},`draw`)},styles:t(()=>``,`styles`)};export{ee as diagram};
@@ -0,0 +1 @@
1
+ import"./chunk-K5T4RW27-B_ZUrFUq.js";import{n as e}from"./chunk-2KRD3SAO-Di4bO8ir.js";export{e as createRadarServices};
@@ -0,0 +1 @@
1
+ import{E as e,O as t,T as n,_ as r,c as i,d as a,f as o,g as s,h as c,i as l,m as u,n as d,p as f,r as p,s as m,t as h,v as g,w as _,y as v}from"./_baseFor-BHtDrjIo.js";import{i as y,n as b,r as x}from"./isEmpty-BWl67LAZ.js";function ee(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var te=`__lodash_hash_undefined__`;function ne(e){return this.__data__.set(e,te),this}function re(e){return this.__data__.has(e)}function S(e){var t=-1,n=e==null?0:e.length;for(this.__data__=new v;++t<n;)this.add(e[t])}S.prototype.add=S.prototype.push=ne,S.prototype.has=re;function ie(e,t){for(var n=-1,r=e==null?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function C(e,t){return e.has(t)}var ae=1,oe=2;function w(e,t,n,r,i,a){var o=n&ae,s=e.length,c=t.length;if(s!=c&&!(o&&c>s))return!1;var l=a.get(e),u=a.get(t);if(l&&u)return l==t&&u==e;var d=-1,f=!0,p=n&oe?new S:void 0;for(a.set(e,t),a.set(t,e);++d<s;){var m=e[d],h=t[d];if(r)var g=o?r(h,m,d,t,e,a):r(m,h,d,e,t,a);if(g!==void 0){if(g)continue;f=!1;break}if(p){if(!ie(t,function(e,t){if(!C(p,t)&&(m===e||i(m,e,n,r,a)))return p.push(t)})){f=!1;break}}else if(!(m===h||i(m,h,n,r,a))){f=!1;break}}return a.delete(e),a.delete(t),f}function se(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function T(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var ce=1,le=2,ue=`[object Boolean]`,de=`[object Date]`,fe=`[object Error]`,pe=`[object Map]`,me=`[object Number]`,he=`[object RegExp]`,ge=`[object Set]`,_e=`[object String]`,ve=`[object Symbol]`,ye=`[object ArrayBuffer]`,be=`[object DataView]`,E=e?e.prototype:void 0,D=E?E.valueOf:void 0;function xe(e,n,i,a,o,s,c){switch(i){case be:if(e.byteLength!=n.byteLength||e.byteOffset!=n.byteOffset)return!1;e=e.buffer,n=n.buffer;case ye:return!(e.byteLength!=n.byteLength||!s(new r(e),new r(n)));case ue:case de:case me:return t(+e,+n);case fe:return e.name==n.name&&e.message==n.message;case he:case _e:return e==n+``;case pe:var l=se;case ge:var u=a&ce;if(l||=T,e.size!=n.size&&!u)return!1;var d=c.get(e);if(d)return d==n;a|=le,c.set(e,n);var f=w(l(e),l(n),a,o,s,c);return c.delete(e),f;case ve:if(D)return D.call(e)==D.call(n)}return!1}function O(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function k(e,t,n){var r=t(e);return s(e)?r:O(r,n(e))}function A(e,t){for(var n=-1,r=e==null?0:e.length,i=0,a=[];++n<r;){var o=e[n];t(o,n,e)&&(a[i++]=o)}return a}function j(){return[]}var Se=Object.prototype.propertyIsEnumerable,M=Object.getOwnPropertySymbols,N=M?function(e){return e==null?[]:(e=Object(e),A(M(e),function(t){return Se.call(e,t)}))}:j;function P(e){return l(e)?m(e):y(e)}function F(e){return k(e,P,N)}var Ce=1,we=Object.prototype.hasOwnProperty;function Te(e,t,n,r,i,a){var o=n&Ce,s=F(e),c=s.length;if(c!=F(t).length&&!o)return!1;for(var l=c;l--;){var u=s[l];if(!(o?u in t:we.call(t,u)))return!1}var d=a.get(e),f=a.get(t);if(d&&f)return d==t&&f==e;var p=!0;a.set(e,t),a.set(t,e);for(var m=o;++l<c;){u=s[l];var h=e[u],g=t[u];if(r)var _=o?r(g,h,u,t,e,a):r(h,g,u,e,t,a);if(!(_===void 0?h===g||i(h,g,n,r,a):_)){p=!1;break}m||=u==`constructor`}if(p&&!m){var v=e.constructor,y=t.constructor;v!=y&&`constructor`in e&&`constructor`in t&&!(typeof v==`function`&&v instanceof v&&typeof y==`function`&&y instanceof y)&&(p=!1)}return a.delete(e),a.delete(t),p}var Ee=1,I=`[object Arguments]`,L=`[object Array]`,R=`[object Object]`,z=Object.prototype.hasOwnProperty;function De(e,t,n,r,a,o){var c=s(e),l=s(t),u=c?L:b(e),d=l?L:b(t);u=u==I?R:u,d=d==I?R:d;var p=u==R,m=d==R,h=u==d;if(h&&f(e)){if(!f(t))return!1;c=!0,p=!1}if(h&&!p)return o||=new g,c||i(e)?w(e,t,n,r,a,o):xe(e,t,u,n,r,a,o);if(!(n&Ee)){var _=p&&z.call(e,`__wrapped__`),v=m&&z.call(t,`__wrapped__`);if(_||v){var y=_?e.value():e,x=v?t.value():t;return o||=new g,a(y,x,n,r,o)}}return h?(o||=new g,Te(e,t,n,r,a,o)):!1}function B(e,t,n,r,i){return e===t?!0:e==null||t==null||!c(e)&&!c(t)?e!==e&&t!==t:De(e,t,n,r,B,i)}var Oe=1,ke=2;function Ae(e,t,n,r){var i=n.length,a=i,o=!r;if(e==null)return!a;for(e=Object(e);i--;){var s=n[i];if(o&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<a;){s=n[i];var c=s[0],l=e[c],u=s[1];if(o&&s[2]){if(l===void 0&&!(c in e))return!1}else{var d=new g;if(r)var f=r(l,u,c,e,t,d);if(!(f===void 0?B(u,l,Oe|ke,r,d):f))return!1}}return!0}function V(e){return e===e&&!_(e)}function je(e){for(var t=P(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,V(i)]}return t}function H(e,t){return function(n){return n==null?!1:n[e]===t&&(t!==void 0||e in Object(n))}}function Me(e){var t=je(e);return t.length==1&&t[0][2]?H(t[0][0],t[0][1]):function(n){return n===e||Ae(n,e,t)}}var Ne=`[object Symbol]`;function U(e){return typeof e==`symbol`||c(e)&&n(e)==Ne}var Pe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Fe=/^\w*$/;function W(e,t){if(s(e))return!1;var n=typeof e;return n==`number`||n==`symbol`||n==`boolean`||e==null||U(e)?!0:Fe.test(e)||!Pe.test(e)||t!=null&&e in Object(t)}var Ie=500;function Le(e){var t=p(e,function(e){return n.size===Ie&&n.clear(),e}),n=t.cache;return t}var Re=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ze=/\\(\\)?/g,Be=Le(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(``),e.replace(Re,function(e,n,r,i){t.push(r?i.replace(ze,`$1`):n||e)}),t}),Ve=1/0,G=e?e.prototype:void 0,K=G?G.toString:void 0;function q(e){if(typeof e==`string`)return e;if(s(e))return ee(e,q)+``;if(U(e))return K?K.call(e):``;var t=e+``;return t==`0`&&1/e==-Ve?`-0`:t}function He(e){return e==null?``:q(e)}function J(e,t){return s(e)?e:W(e,t)?[e]:Be(He(e))}var Ue=1/0;function Y(e){if(typeof e==`string`||U(e))return e;var t=e+``;return t==`0`&&1/e==-Ue?`-0`:t}function X(e,t){t=J(t,e);for(var n=0,r=t.length;e!=null&&n<r;)e=e[Y(t[n++])];return n&&n==r?e:void 0}function We(e,t,n){var r=e==null?void 0:X(e,t);return r===void 0?n:r}function Ge(e,t){return e!=null&&t in Object(e)}function Ke(e,t,n){t=J(t,e);for(var r=-1,i=t.length,c=!1;++r<i;){var l=Y(t[r]);if(!(c=e!=null&&n(e,l)))break;e=e[l]}return c||++r!=i?c:(i=e==null?0:e.length,!!i&&a(i)&&o(l,i)&&(s(e)||u(e)))}function qe(e,t){return e!=null&&Ke(e,t,Ge)}var Je=1,Ye=2;function Xe(e,t){return W(e)&&V(t)?H(Y(e),t):function(n){var r=We(n,e);return r===void 0&&r===t?qe(n,e):B(t,r,Je|Ye)}}function Ze(e){return function(t){return t?.[e]}}function Qe(e){return function(t){return X(t,e)}}function $e(e){return W(e)?Ze(Y(e)):Qe(e)}function Z(e){return typeof e==`function`?e:e==null?d:typeof e==`object`?s(e)?Xe(e[0],e[1]):Me(e):$e(e)}function et(e,t){return e&&h(e,t,P)}function tt(e,t){return function(n,r){if(n==null)return n;if(!l(n))return e(n,r);for(var i=n.length,a=t?i:-1,o=Object(n);(t?a--:++a<i)&&r(o[a],a,o)!==!1;);return n}}var Q=tt(et);function nt(e,t){var n=[];return Q(e,function(e,r,i){t(e,r,i)&&n.push(e)}),n}function rt(e,t){return(s(e)?A:nt)(e,Z(t,3))}var it=e?e.isConcatSpreadable:void 0;function at(e){return s(e)||u(e)||!!(it&&e&&e[it])}function ot(e,t,n,r,i){var a=-1,o=e.length;for(n||=at,i||=[];++a<o;){var s=e[a];t>0&&n(s)?t>1?ot(s,t-1,n,r,i):O(i,s):r||(i[i.length]=s)}return i}function st(e,t,n,r){for(var i=e.length,a=n+(r?1:-1);r?a--:++a<i;)if(t(e[a],a,e))return a;return-1}function ct(e){return e!==e}function lt(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}function ut(e,t,n){return t===t?lt(e,t,n):st(e,ct,n)}function dt(e,t){return!!(e!=null&&e.length)&&ut(e,t,0)>-1}function ft(e,t,n){for(var r=-1,i=e==null?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}function pt(){}var mt=x&&1/T(new x([,-0]))[1]==1/0?function(e){return new x(e)}:pt,ht=200;function gt(e,t,n){var r=-1,i=dt,a=e.length,o=!0,s=[],c=s;if(n)o=!1,i=ft;else if(a>=ht){var l=t?null:mt(e);if(l)return T(l);o=!1,i=C,c=new S}else c=t?[]:s;outer:for(;++r<a;){var u=e[r],d=t?t(u):u;if(u=n||u!==0?u:0,o&&d===d){for(var f=c.length;f--;)if(c[f]===d)continue outer;t&&c.push(d),s.push(u)}else i(c,d,n)||(c!==s&&c.push(d),s.push(u))}return s}function _t(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}function $(e){return typeof e==`function`?e:d}function vt(e,t){return(s(e)?_t:Q)(e,$(t))}function yt(e,t,n,r){var i=-1,a=e==null?0:e.length;for(r&&a&&(n=e[++i]);++i<a;)n=t(n,e[i],i,e);return n}function bt(e,t,n,r,i){return i(e,function(e,i,a){n=r?(r=!1,e):t(n,e,i,a)}),n}function xt(e,t,n){var r=s(e)?yt:bt,i=arguments.length<3;return r(e,Z(t,4),n,i,Q)}export{j as C,ee as E,N as S,O as T,J as _,gt as a,F as b,rt as c,Z as d,Ze as f,Y as g,X as h,_t as i,Q as l,Ke as m,vt as n,st as o,qe as p,$ as r,ot as s,xt as t,et as u,He as v,k as w,P as x,U as y};
@@ -0,0 +1,84 @@
1
+ import{g as e,h as t,m as n}from"./src-B6XdH6xq.js";import{B as r,C as i,V as a,W as o,_ as s,a as c,b as l,v as u,y as d}from"./chunk-ICPOFSXX-C5_hbB6H.js";import"./dist-Bd4S37oi.js";import{h as f}from"./chunk-5PVQY5BW-DyiDEtXY.js";import"./chunk-U2HBQHQK-CQpbcqRS.js";import"./chunk-BSJP7CBP-DP7LTBll.js";import"./chunk-ZZ45TVLE-D6CiPO0Q.js";import{t as p}from"./chunk-55IACEB6-BRJOZLpU.js";import{t as m}from"./chunk-EDXVE4YY-B3u7wU36.js";import"./chunk-X2U36JSP-1HG7T4gX.js";import"./chunk-5FUZZQ4R-B3IWYz-k.js";import"./chunk-ENJZ2VHE-BesS5YY4.js";import{r as h,t as g}from"./chunk-336JU56O-DulT46bV.js";var _=(function(){var e=t(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,3],r=[1,4],i=[1,5],a=[1,6],o=[5,6,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],s=[1,22],c=[2,7],l=[1,26],u=[1,27],d=[1,28],f=[1,29],p=[1,33],m=[1,34],h=[1,35],g=[1,36],_=[1,37],v=[1,38],y=[1,24],b=[1,31],x=[1,32],S=[1,30],C=[1,39],w=[1,40],T=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],E=[1,61],D=[89,90],O=[5,8,9,11,13,21,22,23,24,27,29,41,42,43,44,45,46,54,61,63,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],k=[27,29],ee=[1,70],A=[1,71],te=[1,72],ne=[1,73],re=[1,74],ie=[1,75],ae=[1,76],j=[1,83],M=[1,80],N=[1,84],P=[1,85],F=[1,86],I=[1,87],L=[1,88],R=[1,89],z=[1,90],B=[1,91],V=[1,92],oe=[5,8,9,11,13,21,22,23,24,27,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],H=[63,64],se=[1,101],ce=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,76,77,89,90],U=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],W=[1,110],G=[1,106],K=[1,107],q=[1,108],J=[1,109],Y=[1,111],X=[1,116],Z=[1,117],Q=[1,114],$=[1,115],le={trace:t(function(){},`trace`),yy:{},symbols_:{error:2,start:3,directive:4,NEWLINE:5,RD:6,diagram:7,EOF:8,acc_title:9,acc_title_value:10,acc_descr:11,acc_descr_value:12,acc_descr_multiline_value:13,requirementDef:14,elementDef:15,relationshipDef:16,direction:17,styleStatement:18,classDefStatement:19,classStatement:20,direction_tb:21,direction_bt:22,direction_rl:23,direction_lr:24,requirementType:25,requirementName:26,STRUCT_START:27,requirementBody:28,STYLE_SEPARATOR:29,idList:30,ID:31,COLONSEP:32,id:33,TEXT:34,text:35,RISK:36,riskLevel:37,VERIFYMTHD:38,verifyType:39,STRUCT_STOP:40,REQUIREMENT:41,FUNCTIONAL_REQUIREMENT:42,INTERFACE_REQUIREMENT:43,PERFORMANCE_REQUIREMENT:44,PHYSICAL_REQUIREMENT:45,DESIGN_CONSTRAINT:46,LOW_RISK:47,MED_RISK:48,HIGH_RISK:49,VERIFY_ANALYSIS:50,VERIFY_DEMONSTRATION:51,VERIFY_INSPECTION:52,VERIFY_TEST:53,ELEMENT:54,elementName:55,elementBody:56,TYPE:57,type:58,DOCREF:59,ref:60,END_ARROW_L:61,relationship:62,LINE:63,END_ARROW_R:64,CONTAINS:65,COPIES:66,DERIVES:67,SATISFIES:68,VERIFIES:69,REFINES:70,TRACES:71,CLASSDEF:72,stylesOpt:73,CLASS:74,ALPHA:75,COMMA:76,STYLE:77,style:78,styleComponent:79,NUM:80,COLON:81,UNIT:82,SPACE:83,BRKT:84,PCT:85,MINUS:86,LABEL:87,SEMICOLON:88,unqString:89,qString:90,$accept:0,$end:1},terminals_:{2:`error`,5:`NEWLINE`,6:`RD`,8:`EOF`,9:`acc_title`,10:`acc_title_value`,11:`acc_descr`,12:`acc_descr_value`,13:`acc_descr_multiline_value`,21:`direction_tb`,22:`direction_bt`,23:`direction_rl`,24:`direction_lr`,27:`STRUCT_START`,29:`STYLE_SEPARATOR`,31:`ID`,32:`COLONSEP`,34:`TEXT`,36:`RISK`,38:`VERIFYMTHD`,40:`STRUCT_STOP`,41:`REQUIREMENT`,42:`FUNCTIONAL_REQUIREMENT`,43:`INTERFACE_REQUIREMENT`,44:`PERFORMANCE_REQUIREMENT`,45:`PHYSICAL_REQUIREMENT`,46:`DESIGN_CONSTRAINT`,47:`LOW_RISK`,48:`MED_RISK`,49:`HIGH_RISK`,50:`VERIFY_ANALYSIS`,51:`VERIFY_DEMONSTRATION`,52:`VERIFY_INSPECTION`,53:`VERIFY_TEST`,54:`ELEMENT`,57:`TYPE`,59:`DOCREF`,61:`END_ARROW_L`,63:`LINE`,64:`END_ARROW_R`,65:`CONTAINS`,66:`COPIES`,67:`DERIVES`,68:`SATISFIES`,69:`VERIFIES`,70:`REFINES`,71:`TRACES`,72:`CLASSDEF`,74:`CLASS`,75:`ALPHA`,76:`COMMA`,77:`STYLE`,80:`NUM`,81:`COLON`,82:`UNIT`,83:`SPACE`,84:`BRKT`,85:`PCT`,86:`MINUS`,87:`LABEL`,88:`SEMICOLON`,89:`unqString`,90:`qString`},productions_:[0,[3,3],[3,2],[3,4],[4,2],[4,2],[4,1],[7,0],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[17,1],[17,1],[17,1],[17,1],[14,5],[14,7],[28,5],[28,5],[28,5],[28,5],[28,2],[28,1],[25,1],[25,1],[25,1],[25,1],[25,1],[25,1],[37,1],[37,1],[37,1],[39,1],[39,1],[39,1],[39,1],[15,5],[15,7],[56,5],[56,5],[56,2],[56,1],[16,5],[16,5],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[19,3],[20,3],[20,3],[30,1],[30,3],[30,1],[30,3],[18,3],[73,1],[73,3],[78,1],[78,2],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[26,1],[26,1],[33,1],[33,1],[35,1],[35,1],[55,1],[55,1],[58,1],[58,1],[60,1],[60,1]],performAction:t(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 4:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 5:case 6:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 7:this.$=[];break;case 17:r.setDirection(`TB`);break;case 18:r.setDirection(`BT`);break;case 19:r.setDirection(`RL`);break;case 20:r.setDirection(`LR`);break;case 21:r.addRequirement(a[s-3],a[s-4]);break;case 22:r.addRequirement(a[s-5],a[s-6]),r.setClass([a[s-5]],a[s-3]);break;case 23:r.setNewReqId(a[s-2]);break;case 24:r.setNewReqText(a[s-2]);break;case 25:r.setNewReqRisk(a[s-2]);break;case 26:r.setNewReqVerifyMethod(a[s-2]);break;case 29:this.$=r.RequirementType.REQUIREMENT;break;case 30:this.$=r.RequirementType.FUNCTIONAL_REQUIREMENT;break;case 31:this.$=r.RequirementType.INTERFACE_REQUIREMENT;break;case 32:this.$=r.RequirementType.PERFORMANCE_REQUIREMENT;break;case 33:this.$=r.RequirementType.PHYSICAL_REQUIREMENT;break;case 34:this.$=r.RequirementType.DESIGN_CONSTRAINT;break;case 35:this.$=r.RiskLevel.LOW_RISK;break;case 36:this.$=r.RiskLevel.MED_RISK;break;case 37:this.$=r.RiskLevel.HIGH_RISK;break;case 38:this.$=r.VerifyType.VERIFY_ANALYSIS;break;case 39:this.$=r.VerifyType.VERIFY_DEMONSTRATION;break;case 40:this.$=r.VerifyType.VERIFY_INSPECTION;break;case 41:this.$=r.VerifyType.VERIFY_TEST;break;case 42:r.addElement(a[s-3]);break;case 43:r.addElement(a[s-5]),r.setClass([a[s-5]],a[s-3]);break;case 44:r.setNewElementType(a[s-2]);break;case 45:r.setNewElementDocRef(a[s-2]);break;case 48:r.addRelationship(a[s-2],a[s],a[s-4]);break;case 49:r.addRelationship(a[s-2],a[s-4],a[s]);break;case 50:this.$=r.Relationships.CONTAINS;break;case 51:this.$=r.Relationships.COPIES;break;case 52:this.$=r.Relationships.DERIVES;break;case 53:this.$=r.Relationships.SATISFIES;break;case 54:this.$=r.Relationships.VERIFIES;break;case 55:this.$=r.Relationships.REFINES;break;case 56:this.$=r.Relationships.TRACES;break;case 57:this.$=a[s-2],r.defineClass(a[s-1],a[s]);break;case 58:r.setClass(a[s-1],a[s]);break;case 59:r.setClass([a[s-2]],a[s]);break;case 60:case 62:this.$=[a[s]];break;case 61:case 63:this.$=a[s-2].concat([a[s]]);break;case 64:this.$=a[s-2],r.setCssStyle(a[s-1],a[s]);break;case 65:this.$=[a[s]];break;case 66:a[s-2].push(a[s]),this.$=a[s-2];break;case 68:this.$=a[s-1]+a[s];break}},`anonymous`),table:[{3:1,4:2,6:n,9:r,11:i,13:a},{1:[3]},{3:8,4:2,5:[1,7],6:n,9:r,11:i,13:a},{5:[1,9]},{10:[1,10]},{12:[1,11]},e(o,[2,6]),{3:12,4:2,6:n,9:r,11:i,13:a},{1:[2,2]},{4:17,5:s,7:13,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},e(o,[2,4]),e(o,[2,5]),{1:[2,1]},{8:[1,41]},{4:17,5:s,7:42,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:43,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:44,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:45,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:46,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:47,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:48,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:49,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{4:17,5:s,7:50,8:c,9:r,11:i,13:a,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:l,22:u,23:d,24:f,25:23,33:25,41:p,42:m,43:h,44:g,45:_,46:v,54:y,72:b,74:x,77:S,89:C,90:w},{26:51,89:[1,52],90:[1,53]},{55:54,89:[1,55],90:[1,56]},{29:[1,59],61:[1,57],63:[1,58]},e(T,[2,17]),e(T,[2,18]),e(T,[2,19]),e(T,[2,20]),{30:60,33:62,75:E,89:C,90:w},{30:63,33:62,75:E,89:C,90:w},{30:64,33:62,75:E,89:C,90:w},e(D,[2,29]),e(D,[2,30]),e(D,[2,31]),e(D,[2,32]),e(D,[2,33]),e(D,[2,34]),e(O,[2,81]),e(O,[2,82]),{1:[2,3]},{8:[2,8]},{8:[2,9]},{8:[2,10]},{8:[2,11]},{8:[2,12]},{8:[2,13]},{8:[2,14]},{8:[2,15]},{8:[2,16]},{27:[1,65],29:[1,66]},e(k,[2,79]),e(k,[2,80]),{27:[1,67],29:[1,68]},e(k,[2,85]),e(k,[2,86]),{62:69,65:ee,66:A,67:te,68:ne,69:re,70:ie,71:ae},{62:77,65:ee,66:A,67:te,68:ne,69:re,70:ie,71:ae},{30:78,33:62,75:E,89:C,90:w},{73:79,75:j,76:M,78:81,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},e(oe,[2,60]),e(oe,[2,62]),{73:93,75:j,76:M,78:81,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},{30:94,33:62,75:E,76:M,89:C,90:w},{5:[1,95]},{30:96,33:62,75:E,89:C,90:w},{5:[1,97]},{30:98,33:62,75:E,89:C,90:w},{63:[1,99]},e(H,[2,50]),e(H,[2,51]),e(H,[2,52]),e(H,[2,53]),e(H,[2,54]),e(H,[2,55]),e(H,[2,56]),{64:[1,100]},e(T,[2,59],{76:M}),e(T,[2,64],{76:se}),{33:103,75:[1,102],89:C,90:w},e(ce,[2,65],{79:104,75:j,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V}),e(U,[2,67]),e(U,[2,69]),e(U,[2,70]),e(U,[2,71]),e(U,[2,72]),e(U,[2,73]),e(U,[2,74]),e(U,[2,75]),e(U,[2,76]),e(U,[2,77]),e(U,[2,78]),e(T,[2,57],{76:se}),e(T,[2,58],{76:M}),{5:W,28:105,31:G,34:K,36:q,38:J,40:Y},{27:[1,112],76:M},{5:X,40:Z,56:113,57:Q,59:$},{27:[1,118],76:M},{33:119,89:C,90:w},{33:120,89:C,90:w},{75:j,78:121,79:82,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V},e(oe,[2,61]),e(oe,[2,63]),e(U,[2,68]),e(T,[2,21]),{32:[1,122]},{32:[1,123]},{32:[1,124]},{32:[1,125]},{5:W,28:126,31:G,34:K,36:q,38:J,40:Y},e(T,[2,28]),{5:[1,127]},e(T,[2,42]),{32:[1,128]},{32:[1,129]},{5:X,40:Z,56:130,57:Q,59:$},e(T,[2,47]),{5:[1,131]},e(T,[2,48]),e(T,[2,49]),e(ce,[2,66],{79:104,75:j,80:N,81:P,82:F,83:I,84:L,85:R,86:z,87:B,88:V}),{33:132,89:C,90:w},{35:133,89:[1,134],90:[1,135]},{37:136,47:[1,137],48:[1,138],49:[1,139]},{39:140,50:[1,141],51:[1,142],52:[1,143],53:[1,144]},e(T,[2,27]),{5:W,28:145,31:G,34:K,36:q,38:J,40:Y},{58:146,89:[1,147],90:[1,148]},{60:149,89:[1,150],90:[1,151]},e(T,[2,46]),{5:X,40:Z,56:152,57:Q,59:$},{5:[1,153]},{5:[1,154]},{5:[2,83]},{5:[2,84]},{5:[1,155]},{5:[2,35]},{5:[2,36]},{5:[2,37]},{5:[1,156]},{5:[2,38]},{5:[2,39]},{5:[2,40]},{5:[2,41]},e(T,[2,22]),{5:[1,157]},{5:[2,87]},{5:[2,88]},{5:[1,158]},{5:[2,89]},{5:[2,90]},e(T,[2,43]),{5:W,28:159,31:G,34:K,36:q,38:J,40:Y},{5:W,28:160,31:G,34:K,36:q,38:J,40:Y},{5:W,28:161,31:G,34:K,36:q,38:J,40:Y},{5:W,28:162,31:G,34:K,36:q,38:J,40:Y},{5:X,40:Z,56:163,57:Q,59:$},{5:X,40:Z,56:164,57:Q,59:$},e(T,[2,23]),e(T,[2,24]),e(T,[2,25]),e(T,[2,26]),e(T,[2,44]),e(T,[2,45])],defaultActions:{8:[2,2],12:[2,1],41:[2,3],42:[2,8],43:[2,9],44:[2,10],45:[2,11],46:[2,12],47:[2,13],48:[2,14],49:[2,15],50:[2,16],134:[2,83],135:[2,84],137:[2,35],138:[2,36],139:[2,37],141:[2,38],142:[2,39],143:[2,40],144:[2,41],147:[2,87],148:[2,88],150:[2,89],151:[2,90]},parseError:t(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:t(function(e){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(e,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;typeof g.yy.parseError==`function`?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}t(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}t(x,`lex`);for(var S,C,w,T,E,D={},O,k,ee,A;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var te=``;for(O in A=[],s[w])this.terminals_[O]&&O>f&&A.push(`'`+this.terminals_[O]+`'`);te=h.showPosition?`Parse error on line `+(l+1)+`:
2
+ `+h.showPosition()+`
3
+ Expecting `+A.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(te,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:A})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),ee=s[r[r.length-2]][r[r.length-1]],r.push(ee);break;case 3:return!0}}return!0},`parse`)};le.lexer=(function(){return{EOF:1,parseError:t(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:t(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:t(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:t(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:t(function(){return this._more=!0,this},`more`),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
+ `+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:t(function(e){this.unput(this.match.slice(e))},`less`),pastInput:t(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:t(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:t(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
5
+ `+t+`^`},`showPosition`),test_match:t(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:t(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}else return!1}else if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e===!1?!1:e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
6
+ `+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:t(function(){return this.next()||this.lex()},`lex`),begin:t(function(e){this.conditionStack.push(e)},`begin`),popState:t(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:t(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:t(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:t(function(e){this.begin(e)},`pushState`),stateStackSize:t(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:t(function(e,t,n,r){switch(n){case 0:return`title`;case 1:return this.begin(`acc_title`),9;case 2:return this.popState(),`acc_title_value`;case 3:return this.begin(`acc_descr`),11;case 4:return this.popState(),`acc_descr_value`;case 5:this.begin(`acc_descr_multiline`);break;case 6:this.popState();break;case 7:return`acc_descr_multiline_value`;case 8:return 21;case 9:return 22;case 10:return 23;case 11:return 24;case 12:return 5;case 13:break;case 14:break;case 15:break;case 16:return 8;case 17:return 6;case 18:return 27;case 19:return 40;case 20:return 29;case 21:return 32;case 22:return 31;case 23:return 34;case 24:return 36;case 25:return 38;case 26:return 41;case 27:return 42;case 28:return 43;case 29:return 44;case 30:return 45;case 31:return 46;case 32:return 47;case 33:return 48;case 34:return 49;case 35:return 50;case 36:return 51;case 37:return 52;case 38:return 53;case 39:return 54;case 40:return 65;case 41:return 66;case 42:return 67;case 43:return 68;case 44:return 69;case 45:return 70;case 46:return 71;case 47:return 57;case 48:return 59;case 49:return this.begin(`style`),77;case 50:return 75;case 51:return 81;case 52:return 88;case 53:return`PERCENT`;case 54:return 86;case 55:return 84;case 56:break;case 57:this.begin(`string`);break;case 58:this.popState();break;case 59:return this.begin(`style`),72;case 60:return this.begin(`style`),74;case 61:return 61;case 62:return 64;case 63:return 63;case 64:this.begin(`string`);break;case 65:this.popState();break;case 66:return`qString`;case 67:return t.yytext=t.yytext.trim(),89;case 68:return 75;case 69:return 80;case 70:return 76}},`anonymous`),rules:[/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:(\r?\n)+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:$)/i,/^(?:requirementDiagram\b)/i,/^(?:\{)/i,/^(?:\})/i,/^(?::{3})/i,/^(?::)/i,/^(?:id\b)/i,/^(?:text\b)/i,/^(?:risk\b)/i,/^(?:verifyMethod\b)/i,/^(?:requirement\b)/i,/^(?:functionalRequirement\b)/i,/^(?:interfaceRequirement\b)/i,/^(?:performanceRequirement\b)/i,/^(?:physicalRequirement\b)/i,/^(?:designConstraint\b)/i,/^(?:low\b)/i,/^(?:medium\b)/i,/^(?:high\b)/i,/^(?:analysis\b)/i,/^(?:demonstration\b)/i,/^(?:inspection\b)/i,/^(?:test\b)/i,/^(?:element\b)/i,/^(?:contains\b)/i,/^(?:copies\b)/i,/^(?:derives\b)/i,/^(?:satisfies\b)/i,/^(?:verifies\b)/i,/^(?:refines\b)/i,/^(?:traces\b)/i,/^(?:type\b)/i,/^(?:docref\b)/i,/^(?:style\b)/i,/^(?:\w+)/i,/^(?::)/i,/^(?:;)/i,/^(?:%)/i,/^(?:-)/i,/^(?:#)/i,/^(?: )/i,/^(?:["])/i,/^(?:\n)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:<-)/i,/^(?:->)/i,/^(?:-)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[\w][^:,\r\n\{\<\>\-\=]*)/i,/^(?:\w+)/i,/^(?:[0-9]+)/i,/^(?:,)/i],conditions:{acc_descr_multiline:{rules:[6,7,68,69,70],inclusive:!1},acc_descr:{rules:[4,68,69,70],inclusive:!1},acc_title:{rules:[2,68,69,70],inclusive:!1},style:{rules:[50,51,52,53,54,55,56,57,58,68,69,70],inclusive:!1},unqString:{rules:[68,69,70],inclusive:!1},token:{rules:[68,69,70],inclusive:!1},string:{rules:[65,66,68,69,70],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,59,60,61,62,63,64,67,68,69,70],inclusive:!0}}}})();function ue(){this.yy={}}return t(ue,`Parser`),ue.prototype=le,le.Parser=ue,new ue})();_.parser=_;var v=_,y=class{constructor(){this.relations=[],this.latestRequirement=this.getInitialRequirement(),this.requirements=new Map,this.latestElement=this.getInitialElement(),this.elements=new Map,this.classes=new Map,this.direction=`TB`,this.RequirementType={REQUIREMENT:`Requirement`,FUNCTIONAL_REQUIREMENT:`Functional Requirement`,INTERFACE_REQUIREMENT:`Interface Requirement`,PERFORMANCE_REQUIREMENT:`Performance Requirement`,PHYSICAL_REQUIREMENT:`Physical Requirement`,DESIGN_CONSTRAINT:`Design Constraint`},this.RiskLevel={LOW_RISK:`Low`,MED_RISK:`Medium`,HIGH_RISK:`High`},this.VerifyType={VERIFY_ANALYSIS:`Analysis`,VERIFY_DEMONSTRATION:`Demonstration`,VERIFY_INSPECTION:`Inspection`,VERIFY_TEST:`Test`},this.Relationships={CONTAINS:`contains`,COPIES:`copies`,DERIVES:`derives`,SATISFIES:`satisfies`,VERIFIES:`verifies`,REFINES:`refines`,TRACES:`traces`},this.setAccTitle=a,this.getAccTitle=u,this.setAccDescription=r,this.getAccDescription=s,this.setDiagramTitle=o,this.getDiagramTitle=i,this.getConfig=t(()=>l().requirement,`getConfig`),this.clear(),this.setDirection=this.setDirection.bind(this),this.addRequirement=this.addRequirement.bind(this),this.setNewReqId=this.setNewReqId.bind(this),this.setNewReqRisk=this.setNewReqRisk.bind(this),this.setNewReqText=this.setNewReqText.bind(this),this.setNewReqVerifyMethod=this.setNewReqVerifyMethod.bind(this),this.addElement=this.addElement.bind(this),this.setNewElementType=this.setNewElementType.bind(this),this.setNewElementDocRef=this.setNewElementDocRef.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setCssStyle=this.setCssStyle.bind(this),this.setClass=this.setClass.bind(this),this.defineClass=this.defineClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{t(this,`RequirementDB`)}getDirection(){return this.direction}setDirection(e){this.direction=e}resetLatestRequirement(){this.latestRequirement=this.getInitialRequirement()}resetLatestElement(){this.latestElement=this.getInitialElement()}getInitialRequirement(){return{requirementId:``,text:``,risk:``,verifyMethod:``,name:``,type:``,cssStyles:[],classes:[`default`]}}getInitialElement(){return{name:``,type:``,docRef:``,cssStyles:[],classes:[`default`]}}addRequirement(e,t){return this.requirements.has(e)||this.requirements.set(e,{name:e,type:t,requirementId:this.latestRequirement.requirementId,text:this.latestRequirement.text,risk:this.latestRequirement.risk,verifyMethod:this.latestRequirement.verifyMethod,cssStyles:[],classes:[`default`]}),this.resetLatestRequirement(),this.requirements.get(e)}getRequirements(){return this.requirements}setNewReqId(e){this.latestRequirement!==void 0&&(this.latestRequirement.requirementId=e)}setNewReqText(e){this.latestRequirement!==void 0&&(this.latestRequirement.text=e)}setNewReqRisk(e){this.latestRequirement!==void 0&&(this.latestRequirement.risk=e)}setNewReqVerifyMethod(e){this.latestRequirement!==void 0&&(this.latestRequirement.verifyMethod=e)}addElement(t){return this.elements.has(t)||(this.elements.set(t,{name:t,type:this.latestElement.type,docRef:this.latestElement.docRef,cssStyles:[],classes:[`default`]}),e.info(`Added new element: `,t)),this.resetLatestElement(),this.elements.get(t)}getElements(){return this.elements}setNewElementType(e){this.latestElement!==void 0&&(this.latestElement.type=e)}setNewElementDocRef(e){this.latestElement!==void 0&&(this.latestElement.docRef=e)}addRelationship(e,t,n){this.relations.push({type:e,src:t,dst:n})}getRelationships(){return this.relations}clear(){this.relations=[],this.resetLatestRequirement(),this.requirements=new Map,this.resetLatestElement(),this.elements=new Map,this.classes=new Map,c()}setCssStyle(e,t){for(let n of e){let e=this.requirements.get(n)??this.elements.get(n);if(!t||!e)return;for(let n of t)n.includes(`,`)?e.cssStyles.push(...n.split(`,`)):e.cssStyles.push(n)}}setClass(e,t){for(let n of e){let e=this.requirements.get(n)??this.elements.get(n);if(e)for(let n of t){e.classes.push(n);let t=this.classes.get(n)?.styles;t&&e.cssStyles.push(...t)}}}defineClass(e,t){for(let n of e){let e=this.classes.get(n);e===void 0&&(e={id:n,styles:[],textStyles:[]},this.classes.set(n,e)),t&&t.forEach(function(t){if(/color/.exec(t)){let n=t.replace(`fill`,`bgFill`);e.textStyles.push(n)}e.styles.push(t)}),this.requirements.forEach(e=>{e.classes.includes(n)&&e.cssStyles.push(...t.flatMap(e=>e.split(`,`)))}),this.elements.forEach(e=>{e.classes.includes(n)&&e.cssStyles.push(...t.flatMap(e=>e.split(`,`)))})}}getClasses(){return this.classes}getData(){let e=l(),t=[],n=[];for(let n of this.requirements.values()){let r=n;r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(` `),r.shape=`requirementBox`,r.look=e.look,r.colorIndex=t.length,t.push(r)}for(let n of this.elements.values()){let r=n;r.shape=`requirementBox`,r.look=e.look,r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(` `),r.colorIndex=t.length,t.push(r)}for(let t of this.relations){let r=0,i=t.type===this.Relationships.CONTAINS,a={id:`${t.src}-${t.dst}-${r}`,start:this.requirements.get(t.src)?.name??this.elements.get(t.src)?.name,end:this.requirements.get(t.dst)?.name??this.elements.get(t.dst)?.name,label:`&lt;&lt;${t.type}&gt;&gt;`,classes:`relationshipLine`,style:[`fill:none`,i?``:`stroke-dasharray: 10,7`],labelpos:`c`,thickness:`normal`,type:`normal`,pattern:i?`normal`:`dashed`,arrowTypeStart:i?`requirement_contains`:``,arrowTypeEnd:i?``:`requirement_arrow`,look:e.look,labelType:`markdown`};n.push(a),r++}return{nodes:t,edges:n,other:{},config:e,direction:this.getDirection()}}},b=t(e=>{let{themeVariables:t,look:n}=d(),{bkgColorArray:r,borderColorArray:i}=t;if(!i?.length)return``;let a=``;for(let t=0;t<e.THEME_COLOR_LIMIT;t++)a+=`
7
+
8
+ [data-look="${n}"][data-color-id="color-${t}"].node path {
9
+ stroke: ${i[t]};
10
+ fill: ${r?.length?r[t]:``};
11
+ }
12
+
13
+ [data-look="${n}"][data-color-id="color-${t}"].node rect {
14
+ stroke: ${i[t]};
15
+ fill: ${r?.length?r[t]:``};
16
+ }
17
+ `;return a},`genColor`),x=t(e=>{let{look:t,themeVariables:n}=d(),{requirementEdgeLabelBackground:r}=n;return`
18
+ ${b(e)}
19
+ marker {
20
+ fill: ${e.relationColor};
21
+ stroke: ${e.relationColor};
22
+ }
23
+
24
+ marker.cross {
25
+ stroke: ${e.lineColor};
26
+ }
27
+
28
+ svg {
29
+ font-family: ${e.fontFamily};
30
+ font-size: ${e.fontSize};
31
+ }
32
+
33
+ .reqBox {
34
+ fill: ${e.requirementBackground};
35
+ fill-opacity: 1.0;
36
+ stroke: ${e.requirementBorderColor};
37
+ stroke-width: ${e.requirementBorderSize};
38
+ }
39
+
40
+ .reqTitle, .reqLabel{
41
+ fill: ${e.requirementTextColor};
42
+ }
43
+ .reqLabelBox {
44
+ fill: ${e.relationLabelBackground};
45
+ fill-opacity: 1.0;
46
+ }
47
+
48
+ .req-title-line {
49
+ stroke: ${e.requirementBorderColor};
50
+ stroke-width: ${e.requirementBorderSize};
51
+ }
52
+ .relationshipLine {
53
+ stroke: ${e.relationColor};
54
+ stroke-width: ${t===`neo`?e.strokeWidth:`1px`};
55
+ }
56
+ .relationshipLabel {
57
+ fill: ${e.relationLabelColor};
58
+ }
59
+ .edgeLabel {
60
+ background-color: ${e.edgeLabelBackground};
61
+ }
62
+ .edgeLabel .label rect {
63
+ fill: ${e.edgeLabelBackground};
64
+ }
65
+ .edgeLabel .label text {
66
+ fill: ${e.relationLabelColor};
67
+ }
68
+ .divider {
69
+ stroke: ${e.nodeBorder};
70
+ stroke-width: 1;
71
+ }
72
+ .label {
73
+ font-family: ${e.fontFamily};
74
+ color: ${e.nodeTextColor||e.textColor};
75
+ }
76
+ .label text,span {
77
+ fill: ${e.nodeTextColor||e.textColor};
78
+ color: ${e.nodeTextColor||e.textColor};
79
+ }
80
+ .labelBkg {
81
+ background-color: ${r??e.edgeLabelBackground};
82
+ }
83
+
84
+ `},`getStyles`),S={};n(S,{draw:()=>C});var C=t(async function(t,n,r,i){e.info(`REF0:`),e.info(`Drawing requirement diagram (unified)`,n);let{securityLevel:a,state:o,layout:s,look:c}=l(),u=i.db.getData(),d=p(n,a);u.type=i.type,u.layoutAlgorithm=g(s),u.nodeSpacing=o?.nodeSpacing??50,u.rankSpacing=o?.rankSpacing??50,u.markers=c===`neo`?[`requirement_contains_neo`,`requirement_arrow_neo`]:[`requirement_contains`,`requirement_arrow`],u.diagramId=n,await h(u,d),f.insertTitle(d,`requirementDiagramTitleText`,o?.titleTopMargin??25,i.db.getDiagramTitle()),m(d,8,`requirementDiagram`,o?.useMaxWidth??!0)},`draw`),w={parser:v,get db(){return new y},renderer:S,styles:x};export{w as diagram};
@@ -0,0 +1 @@
1
+ function e(e,t,n){if(e&&e.length){let[r,i]=t,a=Math.PI/180*n,o=Math.cos(a),s=Math.sin(a);for(let t of e){let[e,n]=t;t[0]=(e-r)*o-(n-i)*s+r,t[1]=(e-r)*s+(n-i)*o+i}}}function t(e,t){return e[0]===t[0]&&e[1]===t[1]}function n(n,r,i,a=1){let o=i,s=Math.max(r,.1),c=n[0]&&n[0][0]&&typeof n[0][0]==`number`?[n]:n,l=[0,0];if(o)for(let t of c)e(t,l,o);let u=function(e,n,r){let i=[];for(let n of e){let e=[...n];t(e[0],e[e.length-1])||e.push([e[0][0],e[0][1]]),e.length>2&&i.push(e)}let a=[];n=Math.max(n,.1);let o=[];for(let e of i)for(let t=0;t<e.length-1;t++){let n=e[t],r=e[t+1];if(n[1]!==r[1]){let e=Math.min(n[1],r[1]);o.push({ymin:e,ymax:Math.max(n[1],r[1]),x:e===n[1]?n[0]:r[0],islope:(r[0]-n[0])/(r[1]-n[1])})}}if(o.sort(((e,t)=>e.ymin<t.ymin?-1:e.ymin>t.ymin?1:e.x<t.x?-1:e.x>t.x?1:e.ymax===t.ymax?0:(e.ymax-t.ymax)/Math.abs(e.ymax-t.ymax))),!o.length)return a;let s=[],c=o[0].ymin,l=0;for(;s.length||o.length;){if(o.length){let e=-1;for(let t=0;t<o.length&&!(o[t].ymin>c);t++)e=t;o.splice(0,e+1).forEach((e=>{s.push({s:c,edge:e})}))}if(s=s.filter((e=>!(e.edge.ymax<=c))),s.sort(((e,t)=>e.edge.x===t.edge.x?0:(e.edge.x-t.edge.x)/Math.abs(e.edge.x-t.edge.x))),(r!==1||l%n==0)&&s.length>1)for(let e=0;e<s.length;e+=2){let t=e+1;if(t>=s.length)break;let n=s[e].edge,r=s[t].edge;a.push([[Math.round(n.x),c],[Math.round(r.x),c]])}c+=r,s.forEach((e=>{e.edge.x=e.edge.x+r*e.edge.islope})),l++}return a}(c,s,a);if(o){for(let t of c)e(t,l,-o);(function(t,n,r){let i=[];t.forEach((e=>i.push(...e))),e(i,n,r)})(u,l,-o)}return u}function r(e,t){let r=t.hachureAngle+90,i=t.hachureGap;i<0&&(i=4*t.strokeWidth),i=Math.round(Math.max(i,.1));let a=1;return t.roughness>=1&&(t.randomizer?.next()||Math.random())>.7&&(a=i),n(e,i,r,a||1)}var i=class{constructor(e){this.helper=e}fillPolygons(e,t){return this._fillPolygons(e,t)}_fillPolygons(e,t){let n=r(e,t);return{type:`fillSketch`,ops:this.renderLines(n,t)}}renderLines(e,t){let n=[];for(let r of e)n.push(...this.helper.doubleLineOps(r[0][0],r[0][1],r[1][0],r[1][1],t));return n}};function a(e){let t=e[0],n=e[1];return Math.sqrt((t[0]-n[0])**2+(t[1]-n[1])**2)}var o=class extends i{fillPolygons(e,t){let n=t.hachureGap;n<0&&(n=4*t.strokeWidth),n=Math.max(n,.1);let i=r(e,Object.assign({},t,{hachureGap:n})),o=Math.PI/180*t.hachureAngle,s=[],c=.5*n*Math.cos(o),l=.5*n*Math.sin(o);for(let[e,t]of i)a([e,t])&&s.push([[e[0]-c,e[1]+l],[...t]],[[e[0]+c,e[1]-l],[...t]]);return{type:`fillSketch`,ops:this.renderLines(s,t)}}},s=class extends i{fillPolygons(e,t){let n=this._fillPolygons(e,t),r=Object.assign({},t,{hachureAngle:t.hachureAngle+90}),i=this._fillPolygons(e,r);return n.ops=n.ops.concat(i.ops),n}},c=class{constructor(e){this.helper=e}fillPolygons(e,t){let n=r(e,t=Object.assign({},t,{hachureAngle:0}));return this.dotsOnLines(n,t)}dotsOnLines(e,t){let n=[],r=t.hachureGap;r<0&&(r=4*t.strokeWidth),r=Math.max(r,.1);let i=t.fillWeight;i<0&&(i=t.strokeWidth/2);let o=r/4;for(let s of e){let e=a(s),c=e/r,l=Math.ceil(c)-1,u=e-l*r,d=(s[0][0]+s[1][0])/2-r/4,f=Math.min(s[0][1],s[1][1]);for(let e=0;e<l;e++){let a=f+u+e*r,s=d-o+2*Math.random()*o,c=a-o+2*Math.random()*o,l=this.helper.ellipse(s,c,i,i,t);n.push(...l.ops)}}return{type:`fillSketch`,ops:n}}},l=class{constructor(e){this.helper=e}fillPolygons(e,t){let n=r(e,t);return{type:`fillSketch`,ops:this.dashedLine(n,t)}}dashedLine(e,t){let n=t.dashOffset<0?t.hachureGap<0?4*t.strokeWidth:t.hachureGap:t.dashOffset,r=t.dashGap<0?t.hachureGap<0?4*t.strokeWidth:t.hachureGap:t.dashGap,i=[];return e.forEach((e=>{let o=a(e),s=Math.floor(o/(n+r)),c=(o+r-s*(n+r))/2,l=e[0],u=e[1];l[0]>u[0]&&(l=e[1],u=e[0]);let d=Math.atan((u[1]-l[1])/(u[0]-l[0]));for(let e=0;e<s;e++){let a=e*(n+r),o=a+n,s=[l[0]+a*Math.cos(d)+c*Math.cos(d),l[1]+a*Math.sin(d)+c*Math.sin(d)],u=[l[0]+o*Math.cos(d)+c*Math.cos(d),l[1]+o*Math.sin(d)+c*Math.sin(d)];i.push(...this.helper.doubleLineOps(s[0],s[1],u[0],u[1],t))}})),i}},u=class{constructor(e){this.helper=e}fillPolygons(e,t){let n=t.hachureGap<0?4*t.strokeWidth:t.hachureGap,i=t.zigzagOffset<0?n:t.zigzagOffset,a=r(e,t=Object.assign({},t,{hachureGap:n+i}));return{type:`fillSketch`,ops:this.zigzagLines(a,i,t)}}zigzagLines(e,t,n){let r=[];return e.forEach((e=>{let i=a(e),o=Math.round(i/(2*t)),s=e[0],c=e[1];s[0]>c[0]&&(s=e[1],c=e[0]);let l=Math.atan((c[1]-s[1])/(c[0]-s[0]));for(let e=0;e<o;e++){let i=2*e*t,a=2*(e+1)*t,o=Math.sqrt(2*t**2),c=[s[0]+i*Math.cos(l),s[1]+i*Math.sin(l)],u=[s[0]+a*Math.cos(l),s[1]+a*Math.sin(l)],d=[c[0]+o*Math.cos(l+Math.PI/4),c[1]+o*Math.sin(l+Math.PI/4)];r.push(...this.helper.doubleLineOps(c[0],c[1],d[0],d[1],n),...this.helper.doubleLineOps(d[0],d[1],u[0],u[1],n))}})),r}},d={},f=class{constructor(e){this.seed=e}next(){return this.seed?(2**31-1&(this.seed=Math.imul(48271,this.seed)))/2**31:Math.random()}},p=0,m=1,h=2,g={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function _(e,t){return e.type===t}function v(e){let t=[],n=function(e){let t=[];for(;e!==``;)if(e.match(/^([ \t\r\n,]+)/))e=e.substr(RegExp.$1.length);else if(e.match(/^([aAcChHlLmMqQsStTvVzZ])/))t[t.length]={type:p,text:RegExp.$1},e=e.substr(RegExp.$1.length);else{if(!e.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];t[t.length]={type:m,text:`${parseFloat(RegExp.$1)}`},e=e.substr(RegExp.$1.length)}return t[t.length]={type:h,text:``},t}(e),r=`BOD`,i=0,a=n[i];for(;!_(a,h);){let o=0,s=[];if(r===`BOD`){if(a.text!==`M`&&a.text!==`m`)return v(`M0,0`+e);i++,o=g[a.text],r=a.text}else _(a,m)?o=g[r]:(i++,o=g[a.text],r=a.text);if(!(i+o<n.length))throw Error(`Path data ended short`);for(let e=i;e<i+o;e++){let t=n[e];if(!_(t,m))throw Error(`Param not a number: `+r+`,`+t.text);s[s.length]=+t.text}if(typeof g[r]!=`number`)throw Error(`Bad segment: `+r);{let e={key:r,data:s};t.push(e),i+=o,a=n[i],r===`M`&&(r=`L`),r===`m`&&(r=`l`)}}return t}function y(e){let t=0,n=0,r=0,i=0,a=[];for(let{key:o,data:s}of e)switch(o){case`M`:a.push({key:`M`,data:[...s]}),[t,n]=s,[r,i]=s;break;case`m`:t+=s[0],n+=s[1],a.push({key:`M`,data:[t,n]}),r=t,i=n;break;case`L`:a.push({key:`L`,data:[...s]}),[t,n]=s;break;case`l`:t+=s[0],n+=s[1],a.push({key:`L`,data:[t,n]});break;case`C`:a.push({key:`C`,data:[...s]}),t=s[4],n=s[5];break;case`c`:{let e=s.map(((e,r)=>r%2?e+n:e+t));a.push({key:`C`,data:e}),t=e[4],n=e[5];break}case`Q`:a.push({key:`Q`,data:[...s]}),t=s[2],n=s[3];break;case`q`:{let e=s.map(((e,r)=>r%2?e+n:e+t));a.push({key:`Q`,data:e}),t=e[2],n=e[3];break}case`A`:a.push({key:`A`,data:[...s]}),t=s[5],n=s[6];break;case`a`:t+=s[5],n+=s[6],a.push({key:`A`,data:[s[0],s[1],s[2],s[3],s[4],t,n]});break;case`H`:a.push({key:`H`,data:[...s]}),t=s[0];break;case`h`:t+=s[0],a.push({key:`H`,data:[t]});break;case`V`:a.push({key:`V`,data:[...s]}),n=s[0];break;case`v`:n+=s[0],a.push({key:`V`,data:[n]});break;case`S`:a.push({key:`S`,data:[...s]}),t=s[2],n=s[3];break;case`s`:{let e=s.map(((e,r)=>r%2?e+n:e+t));a.push({key:`S`,data:e}),t=e[2],n=e[3];break}case`T`:a.push({key:`T`,data:[...s]}),t=s[0],n=s[1];break;case`t`:t+=s[0],n+=s[1],a.push({key:`T`,data:[t,n]});break;case`Z`:case`z`:a.push({key:`Z`,data:[]}),t=r,n=i}return a}function b(e){let t=[],n=``,r=0,i=0,a=0,o=0,s=0,c=0;for(let{key:l,data:u}of e){switch(l){case`M`:t.push({key:`M`,data:[...u]}),[r,i]=u,[a,o]=u;break;case`C`:t.push({key:`C`,data:[...u]}),r=u[4],i=u[5],s=u[2],c=u[3];break;case`L`:t.push({key:`L`,data:[...u]}),[r,i]=u;break;case`H`:r=u[0],t.push({key:`L`,data:[r,i]});break;case`V`:i=u[0],t.push({key:`L`,data:[r,i]});break;case`S`:{let e=0,a=0;n===`C`||n===`S`?(e=r+(r-s),a=i+(i-c)):(e=r,a=i),t.push({key:`C`,data:[e,a,...u]}),s=u[0],c=u[1],r=u[2],i=u[3];break}case`T`:{let[e,a]=u,o=0,l=0;n===`Q`||n===`T`?(o=r+(r-s),l=i+(i-c)):(o=r,l=i);let d=r+2*(o-r)/3,f=i+2*(l-i)/3,p=e+2*(o-e)/3,m=a+2*(l-a)/3;t.push({key:`C`,data:[d,f,p,m,e,a]}),s=o,c=l,r=e,i=a;break}case`Q`:{let[e,n,a,o]=u,l=r+2*(e-r)/3,d=i+2*(n-i)/3,f=a+2*(e-a)/3,p=o+2*(n-o)/3;t.push({key:`C`,data:[l,d,f,p,a,o]}),s=e,c=n,r=a,i=o;break}case`A`:{let e=Math.abs(u[0]),n=Math.abs(u[1]),a=u[2],o=u[3],s=u[4],c=u[5],l=u[6];e===0||n===0?(t.push({key:`C`,data:[r,i,c,l,c,l]}),r=c,i=l):(r!==c||i!==l)&&(S(r,i,c,l,e,n,a,o,s).forEach((function(e){t.push({key:`C`,data:e})})),r=c,i=l);break}case`Z`:t.push({key:`Z`,data:[]}),r=a,i=o}n=l}return t}function x(e,t,n){return[e*Math.cos(n)-t*Math.sin(n),e*Math.sin(n)+t*Math.cos(n)]}function S(e,t,n,r,i,a,o,s,c,l){let u=(d=o,Math.PI*d/180);var d;let f=[],p=0,m=0,h=0,g=0;if(l)[p,m,h,g]=l;else{[e,t]=x(e,t,-u),[n,r]=x(n,r,-u);let o=(e-n)/2,l=(t-r)/2,d=o*o/(i*i)+l*l/(a*a);d>1&&(d=Math.sqrt(d),i*=d,a*=d);let f=i*i,_=a*a,v=f*_-f*l*l-_*o*o,y=f*l*l+_*o*o,b=(s===c?-1:1)*Math.sqrt(Math.abs(v/y));h=b*i*l/a+(e+n)/2,g=b*-a*o/i+(t+r)/2,p=Math.asin(parseFloat(((t-g)/a).toFixed(9))),m=Math.asin(parseFloat(((r-g)/a).toFixed(9))),e<h&&(p=Math.PI-p),n<h&&(m=Math.PI-m),p<0&&(p=2*Math.PI+p),m<0&&(m=2*Math.PI+m),c&&p>m&&(p-=2*Math.PI),!c&&m>p&&(m-=2*Math.PI)}let _=m-p;if(Math.abs(_)>120*Math.PI/180){let e=m,t=n,s=r;m=c&&m>p?p+120*Math.PI/180*1:p+120*Math.PI/180*-1,f=S(n=h+i*Math.cos(m),r=g+a*Math.sin(m),t,s,i,a,o,0,c,[m,e,h,g])}_=m-p;let v=Math.cos(p),y=Math.sin(p),b=Math.cos(m),C=Math.sin(m),w=Math.tan(_/4),T=4/3*i*w,E=4/3*a*w,D=[e,t],O=[e+T*y,t-E*v],k=[n+T*C,r-E*b],A=[n,r];if(O[0]=2*D[0]-O[0],O[1]=2*D[1]-O[1],l)return[O,k,A].concat(f);{f=[O,k,A].concat(f);let e=[];for(let t=0;t<f.length;t+=3){let n=x(f[t][0],f[t][1],u),r=x(f[t+1][0],f[t+1][1],u),i=x(f[t+2][0],f[t+2][1],u);e.push([n[0],n[1],r[0],r[1],i[0],i[1]])}return e}}var C={randOffset:function(e,t){return L(e,t)},randOffsetWithRange:function(e,t,n){return I(e,t,n)},ellipse:function(e,t,n,r,i){return k(e,t,i,O(n,r,i)).opset},doubleLineOps:function(e,t,n,r,i){return R(e,t,n,r,i,!0)}};function w(e,t,n,r,i){return{type:`path`,ops:R(e,t,n,r,i)}}function T(e,t,n){let r=(e||[]).length;if(r>2){let i=[];for(let t=0;t<r-1;t++)i.push(...R(e[t][0],e[t][1],e[t+1][0],e[t+1][1],n));return t&&i.push(...R(e[r-1][0],e[r-1][1],e[0][0],e[0][1],n)),{type:`path`,ops:i}}return r===2?w(e[0][0],e[0][1],e[1][0],e[1][1],n):{type:`path`,ops:[]}}function E(e,t,n,r,i){return function(e,t){return T(e,!0,t)}([[e,t],[e+n,t],[e+n,t+r],[e,t+r]],i)}function D(e,t){if(e.length){let n=typeof e[0][0]==`number`?[e]:e,r=B(n[0],1*(1+.2*t.roughness),t),i=t.disableMultiStroke?[]:B(n[0],1.5*(1+.22*t.roughness),P(t));for(let e=1;e<n.length;e++){let a=n[e];if(a.length){let e=B(a,1*(1+.2*t.roughness),t),n=t.disableMultiStroke?[]:B(a,1.5*(1+.22*t.roughness),P(t));for(let t of e)t.op!==`move`&&r.push(t);for(let e of n)e.op!==`move`&&i.push(e)}}return{type:`path`,ops:r.concat(i)}}return{type:`path`,ops:[]}}function O(e,t,n){let r=Math.sqrt(2*Math.PI*Math.sqrt(((e/2)**2+(t/2)**2)/2)),i=Math.ceil(Math.max(n.curveStepCount,n.curveStepCount/Math.sqrt(200)*r)),a=2*Math.PI/i,o=Math.abs(e/2),s=Math.abs(t/2),c=1-n.curveFitting;return o+=L(o*c,n),s+=L(s*c,n),{increment:a,rx:o,ry:s}}function k(e,t,n,r){let[i,a]=H(r.increment,e,t,r.rx,r.ry,1,r.increment*I(.1,I(.4,1,n),n),n),o=V(i,null,n);if(!n.disableMultiStroke&&n.roughness!==0){let[i]=H(r.increment,e,t,r.rx,r.ry,1.5,0,n),a=V(i,null,n);o=o.concat(a)}return{estimatedPoints:a,opset:{type:`path`,ops:o}}}function A(e,t,n,r,i,a,o,s,c){let l=e,u=t,d=Math.abs(n/2),f=Math.abs(r/2);d+=L(.01*d,c),f+=L(.01*f,c);let p=i,m=a;for(;p<0;)p+=2*Math.PI,m+=2*Math.PI;m-p>2*Math.PI&&(p=0,m=2*Math.PI);let h=2*Math.PI/c.curveStepCount,g=Math.min(h/2,(m-p)/2),_=U(g,l,u,d,f,p,m,1,c);if(!c.disableMultiStroke){let e=U(g,l,u,d,f,p,m,1.5,c);_.push(...e)}return o&&(s?_.push(...R(l,u,l+d*Math.cos(p),u+f*Math.sin(p),c),...R(l,u,l+d*Math.cos(m),u+f*Math.sin(m),c)):_.push({op:`lineTo`,data:[l,u]},{op:`lineTo`,data:[l+d*Math.cos(p),u+f*Math.sin(p)]})),{type:`path`,ops:_}}function j(e,t){let n=b(y(v(e))),r=[],i=[0,0],a=[0,0];for(let{key:e,data:o}of n)switch(e){case`M`:a=[o[0],o[1]],i=[o[0],o[1]];break;case`L`:r.push(...R(a[0],a[1],o[0],o[1],t)),a=[o[0],o[1]];break;case`C`:{let[e,n,i,s,c,l]=o;r.push(...ee(e,n,i,s,c,l,a,t)),a=[c,l];break}case`Z`:r.push(...R(a[0],a[1],i[0],i[1],t)),a=[i[0],i[1]]}return{type:`path`,ops:r}}function M(e,t){let n=[];for(let r of e)if(r.length){let e=t.maxRandomnessOffset||0,i=r.length;if(i>2){n.push({op:`move`,data:[r[0][0]+L(e,t),r[0][1]+L(e,t)]});for(let a=1;a<i;a++)n.push({op:`lineTo`,data:[r[a][0]+L(e,t),r[a][1]+L(e,t)]})}}return{type:`fillPath`,ops:n}}function N(e,t){return function(e,t){let n=e.fillStyle||`hachure`;if(!d[n])switch(n){case`zigzag`:d[n]||(d[n]=new o(t));break;case`cross-hatch`:d[n]||(d[n]=new s(t));break;case`dots`:d[n]||(d[n]=new c(t));break;case`dashed`:d[n]||(d[n]=new l(t));break;case`zigzag-line`:d[n]||(d[n]=new u(t));break;default:n=`hachure`,d[n]||(d[n]=new i(t))}return d[n]}(t,C).fillPolygons(e,t)}function P(e){let t=Object.assign({},e);return t.randomizer=void 0,e.seed&&(t.seed=e.seed+1),t}function F(e){return e.randomizer||=new f(e.seed||0),e.randomizer.next()}function I(e,t,n,r=1){return n.roughness*r*(F(n)*(t-e)+e)}function L(e,t,n=1){return I(-e,e,t,n)}function R(e,t,n,r,i,a=!1){let o=a?i.disableMultiStrokeFill:i.disableMultiStroke,s=z(e,t,n,r,i,!0,!1);if(o)return s;let c=z(e,t,n,r,i,!0,!0);return s.concat(c)}function z(e,t,n,r,i,a,o){let s=(e-n)**2+(t-r)**2,c=Math.sqrt(s),l=1;l=c<200?1:c>500?.4:-.0016668*c+1.233334;let u=i.maxRandomnessOffset||0;u*u*100>s&&(u=c/10);let d=u/2,f=.2+.2*F(i),p=i.bowing*i.maxRandomnessOffset*(r-t)/200,m=i.bowing*i.maxRandomnessOffset*(e-n)/200;p=L(p,i,l),m=L(m,i,l);let h=[],g=()=>L(d,i,l),_=()=>L(u,i,l),v=i.preserveVertices;return a&&(o?h.push({op:`move`,data:[e+(v?0:g()),t+(v?0:g())]}):h.push({op:`move`,data:[e+(v?0:L(u,i,l)),t+(v?0:L(u,i,l))]})),o?h.push({op:`bcurveTo`,data:[p+e+(n-e)*f+g(),m+t+(r-t)*f+g(),p+e+2*(n-e)*f+g(),m+t+2*(r-t)*f+g(),n+(v?0:g()),r+(v?0:g())]}):h.push({op:`bcurveTo`,data:[p+e+(n-e)*f+_(),m+t+(r-t)*f+_(),p+e+2*(n-e)*f+_(),m+t+2*(r-t)*f+_(),n+(v?0:_()),r+(v?0:_())]}),h}function B(e,t,n){if(!e.length)return[];let r=[];r.push([e[0][0]+L(t,n),e[0][1]+L(t,n)]),r.push([e[0][0]+L(t,n),e[0][1]+L(t,n)]);for(let i=1;i<e.length;i++)r.push([e[i][0]+L(t,n),e[i][1]+L(t,n)]),i===e.length-1&&r.push([e[i][0]+L(t,n),e[i][1]+L(t,n)]);return V(r,null,n)}function V(e,t,n){let r=e.length,i=[];if(r>3){let a=[],o=1-n.curveTightness;i.push({op:`move`,data:[e[1][0],e[1][1]]});for(let t=1;t+2<r;t++){let n=e[t];a[0]=[n[0],n[1]],a[1]=[n[0]+(o*e[t+1][0]-o*e[t-1][0])/6,n[1]+(o*e[t+1][1]-o*e[t-1][1])/6],a[2]=[e[t+1][0]+(o*e[t][0]-o*e[t+2][0])/6,e[t+1][1]+(o*e[t][1]-o*e[t+2][1])/6],a[3]=[e[t+1][0],e[t+1][1]],i.push({op:`bcurveTo`,data:[a[1][0],a[1][1],a[2][0],a[2][1],a[3][0],a[3][1]]})}if(t&&t.length===2){let e=n.maxRandomnessOffset;i.push({op:`lineTo`,data:[t[0]+L(e,n),t[1]+L(e,n)]})}}else r===3?(i.push({op:`move`,data:[e[1][0],e[1][1]]}),i.push({op:`bcurveTo`,data:[e[1][0],e[1][1],e[2][0],e[2][1],e[2][0],e[2][1]]})):r===2&&i.push(...z(e[0][0],e[0][1],e[1][0],e[1][1],n,!0,!0));return i}function H(e,t,n,r,i,a,o,s){let c=[],l=[];if(s.roughness===0){e/=4,l.push([t+r*Math.cos(-e),n+i*Math.sin(-e)]);for(let a=0;a<=2*Math.PI;a+=e){let e=[t+r*Math.cos(a),n+i*Math.sin(a)];c.push(e),l.push(e)}l.push([t+r*Math.cos(0),n+i*Math.sin(0)]),l.push([t+r*Math.cos(e),n+i*Math.sin(e)])}else{let u=L(.5,s)-Math.PI/2;l.push([L(a,s)+t+.9*r*Math.cos(u-e),L(a,s)+n+.9*i*Math.sin(u-e)]);let d=2*Math.PI+u-.01;for(let o=u;o<d;o+=e){let e=[L(a,s)+t+r*Math.cos(o),L(a,s)+n+i*Math.sin(o)];c.push(e),l.push(e)}l.push([L(a,s)+t+r*Math.cos(u+2*Math.PI+.5*o),L(a,s)+n+i*Math.sin(u+2*Math.PI+.5*o)]),l.push([L(a,s)+t+.98*r*Math.cos(u+o),L(a,s)+n+.98*i*Math.sin(u+o)]),l.push([L(a,s)+t+.9*r*Math.cos(u+.5*o),L(a,s)+n+.9*i*Math.sin(u+.5*o)])}return[l,c]}function U(e,t,n,r,i,a,o,s,c){let l=a+L(.1,c),u=[];u.push([L(s,c)+t+.9*r*Math.cos(l-e),L(s,c)+n+.9*i*Math.sin(l-e)]);for(let a=l;a<=o;a+=e)u.push([L(s,c)+t+r*Math.cos(a),L(s,c)+n+i*Math.sin(a)]);return u.push([t+r*Math.cos(o),n+i*Math.sin(o)]),u.push([t+r*Math.cos(o),n+i*Math.sin(o)]),V(u,null,c)}function ee(e,t,n,r,i,a,o,s){let c=[],l=[s.maxRandomnessOffset||1,(s.maxRandomnessOffset||1)+.3],u=[0,0],d=s.disableMultiStroke?1:2,f=s.preserveVertices;for(let p=0;p<d;p++)p===0?c.push({op:`move`,data:[o[0],o[1]]}):c.push({op:`move`,data:[o[0]+(f?0:L(l[0],s)),o[1]+(f?0:L(l[0],s))]}),u=f?[i,a]:[i+L(l[p],s),a+L(l[p],s)],c.push({op:`bcurveTo`,data:[e+L(l[p],s),t+L(l[p],s),n+L(l[p],s),r+L(l[p],s),u[0],u[1]]});return c}function W(e){return[...e]}function G(e,t=0){let n=e.length;if(n<3)throw Error(`A curve must have at least three points.`);let r=[];if(n===3)r.push(W(e[0]),W(e[1]),W(e[2]),W(e[2]));else{let n=[];n.push(e[0],e[0]);for(let t=1;t<e.length;t++)n.push(e[t]),t===e.length-1&&n.push(e[t]);let i=[],a=1-t;r.push(W(n[0]));for(let e=1;e+2<n.length;e++){let t=n[e];i[0]=[t[0],t[1]],i[1]=[t[0]+(a*n[e+1][0]-a*n[e-1][0])/6,t[1]+(a*n[e+1][1]-a*n[e-1][1])/6],i[2]=[n[e+1][0]+(a*n[e][0]-a*n[e+2][0])/6,n[e+1][1]+(a*n[e][1]-a*n[e+2][1])/6],i[3]=[n[e+1][0],n[e+1][1]],r.push(i[1],i[2],i[3])}}return r}function K(e,t){return(e[0]-t[0])**2+(e[1]-t[1])**2}function te(e,t,n){let r=K(t,n);if(r===0)return K(e,t);let i=((e[0]-t[0])*(n[0]-t[0])+(e[1]-t[1])*(n[1]-t[1]))/r;return i=Math.max(0,Math.min(1,i)),K(e,q(t,n,i))}function q(e,t,n){return[e[0]+(t[0]-e[0])*n,e[1]+(t[1]-e[1])*n]}function J(e,t,n,r){let i=r||[];if(function(e,t){let n=e[t+0],r=e[t+1],i=e[t+2],a=e[t+3],o=3*r[0]-2*n[0]-a[0];o*=o;let s=3*r[1]-2*n[1]-a[1];s*=s;let c=3*i[0]-2*a[0]-n[0];c*=c;let l=3*i[1]-2*a[1]-n[1];return l*=l,o<c&&(o=c),s<l&&(s=l),o+s}(e,t)<n){let n=e[t+0];i.length?(a=i[i.length-1],o=n,Math.sqrt(K(a,o)))>1&&i.push(n):i.push(n),i.push(e[t+3])}else{let r=.5,a=e[t+0],o=e[t+1],s=e[t+2],c=e[t+3],l=q(a,o,r),u=q(o,s,r),d=q(s,c,r),f=q(l,u,r),p=q(u,d,r),m=q(f,p,r);J([a,l,f,m],0,n,i),J([m,p,d,c],0,n,i)}var a,o;return i}function ne(e,t){return Y(e,0,e.length,t)}function Y(e,t,n,r,i){let a=i||[],o=e[t],s=e[n-1],c=0,l=1;for(let r=t+1;r<n-1;++r){let t=te(e[r],o,s);t>c&&(c=t,l=r)}return Math.sqrt(c)>r?(Y(e,t,l+1,r,a),Y(e,l,n,r,a)):(a.length||a.push(o),a.push(s)),a}function X(e,t=.15,n){let r=[],i=(e.length-1)/3;for(let n=0;n<i;n++)J(e,3*n,t,r);return n&&n>0?Y(r,0,r.length,n):r}var Z=`none`,Q=class{constructor(e){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:`#000`,strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:`hachure`,fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=e||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(e){return e?Object.assign({},this.defaultOptions,e):this.defaultOptions}_d(e,t,n){return{shape:e,sets:t||[],options:n||this.defaultOptions}}line(e,t,n,r,i){let a=this._o(i);return this._d(`line`,[w(e,t,n,r,a)],a)}rectangle(e,t,n,r,i){let a=this._o(i),o=[],s=E(e,t,n,r,a);if(a.fill){let i=[[e,t],[e+n,t],[e+n,t+r],[e,t+r]];a.fillStyle===`solid`?o.push(M([i],a)):o.push(N([i],a))}return a.stroke!==Z&&o.push(s),this._d(`rectangle`,o,a)}ellipse(e,t,n,r,i){let a=this._o(i),o=[],s=O(n,r,a),c=k(e,t,a,s);if(a.fill)if(a.fillStyle===`solid`){let n=k(e,t,a,s).opset;n.type=`fillPath`,o.push(n)}else o.push(N([c.estimatedPoints],a));return a.stroke!==Z&&o.push(c.opset),this._d(`ellipse`,o,a)}circle(e,t,n,r){let i=this.ellipse(e,t,n,n,r);return i.shape=`circle`,i}linearPath(e,t){let n=this._o(t);return this._d(`linearPath`,[T(e,!1,n)],n)}arc(e,t,n,r,i,a,o=!1,s){let c=this._o(s),l=[],u=A(e,t,n,r,i,a,o,!0,c);if(o&&c.fill)if(c.fillStyle===`solid`){let o=Object.assign({},c);o.disableMultiStroke=!0;let s=A(e,t,n,r,i,a,!0,!1,o);s.type=`fillPath`,l.push(s)}else l.push(function(e,t,n,r,i,a,o){let s=e,c=t,l=Math.abs(n/2),u=Math.abs(r/2);l+=L(.01*l,o),u+=L(.01*u,o);let d=i,f=a;for(;d<0;)d+=2*Math.PI,f+=2*Math.PI;f-d>2*Math.PI&&(d=0,f=2*Math.PI);let p=(f-d)/o.curveStepCount,m=[];for(let e=d;e<=f;e+=p)m.push([s+l*Math.cos(e),c+u*Math.sin(e)]);return m.push([s+l*Math.cos(f),c+u*Math.sin(f)]),m.push([s,c]),N([m],o)}(e,t,n,r,i,a,c));return c.stroke!==Z&&l.push(u),this._d(`arc`,l,c)}curve(e,t){let n=this._o(t),r=[],i=D(e,n);if(n.fill&&n.fill!==Z)if(n.fillStyle===`solid`){let t=D(e,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));r.push({type:`fillPath`,ops:this._mergedShape(t.ops)})}else{let t=[],i=e;if(i.length){let e=typeof i[0][0]==`number`?[i]:i;for(let r of e)r.length<3?t.push(...r):r.length===3?t.push(...X(G([r[0],r[0],r[1],r[2]]),10,(1+n.roughness)/2)):t.push(...X(G(r),10,(1+n.roughness)/2))}t.length&&r.push(N([t],n))}return n.stroke!==Z&&r.push(i),this._d(`curve`,r,n)}polygon(e,t){let n=this._o(t),r=[],i=T(e,!0,n);return n.fill&&(n.fillStyle===`solid`?r.push(M([e],n)):r.push(N([e],n))),n.stroke!==Z&&r.push(i),this._d(`polygon`,r,n)}path(e,t){let n=this._o(t),r=[];if(!e)return this._d(`path`,r,n);e=(e||``).replace(/\n/g,` `).replace(/(-\s)/g,`-`).replace(`/(ss)/g`,` `);let i=n.fill&&n.fill!==`transparent`&&n.fill!==Z,a=n.stroke!==Z,o=!!(n.simplification&&n.simplification<1),s=function(e,t,n){let r=b(y(v(e))),i=[],a=[],o=[0,0],s=[],c=()=>{s.length>=4&&a.push(...X(s,t)),s=[]},l=()=>{c(),a.length&&(i.push(a),a=[])};for(let{key:e,data:t}of r)switch(e){case`M`:l(),o=[t[0],t[1]],a.push(o);break;case`L`:c(),a.push([t[0],t[1]]);break;case`C`:if(!s.length){let e=a.length?a[a.length-1]:o;s.push([e[0],e[1]])}s.push([t[0],t[1]]),s.push([t[2],t[3]]),s.push([t[4],t[5]]);break;case`Z`:c(),a.push([o[0],o[1]])}if(l(),!n)return i;let u=[];for(let e of i){let t=ne(e,n);t.length&&u.push(t)}return u}(e,1,o?4-4*(n.simplification||1):(1+n.roughness)/2),c=j(e,n);if(i)if(n.fillStyle===`solid`)if(s.length===1){let t=j(e,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));r.push({type:`fillPath`,ops:this._mergedShape(t.ops)})}else r.push(M(s,n));else r.push(N(s,n));return a&&(o?s.forEach((e=>{r.push(T(e,!1,n))})):r.push(c)),this._d(`path`,r,n)}opsToPath(e,t){let n=``;for(let r of e.ops){let e=typeof t==`number`&&t>=0?r.data.map((e=>+e.toFixed(t))):r.data;switch(r.op){case`move`:n+=`M${e[0]} ${e[1]} `;break;case`bcurveTo`:n+=`C${e[0]} ${e[1]}, ${e[2]} ${e[3]}, ${e[4]} ${e[5]} `;break;case`lineTo`:n+=`L${e[0]} ${e[1]} `}}return n.trim()}toPaths(e){let t=e.sets||[],n=e.options||this.defaultOptions,r=[];for(let e of t){let t=null;switch(e.type){case`path`:t={d:this.opsToPath(e),stroke:n.stroke,strokeWidth:n.strokeWidth,fill:Z};break;case`fillPath`:t={d:this.opsToPath(e),stroke:Z,strokeWidth:0,fill:n.fill||Z};break;case`fillSketch`:t=this.fillSketch(e,n)}t&&r.push(t)}return r}fillSketch(e,t){let n=t.fillWeight;return n<0&&(n=t.strokeWidth/2),{d:this.opsToPath(e),stroke:t.fill||Z,strokeWidth:n,fill:Z}}_mergedShape(e){return e.filter(((e,t)=>t===0||e.op!==`move`))}},re=class{constructor(e,t){this.canvas=e,this.ctx=this.canvas.getContext(`2d`),this.gen=new Q(t)}draw(e){let t=e.sets||[],n=e.options||this.getDefaultOptions(),r=this.ctx,i=e.options.fixedDecimalPlaceDigits;for(let a of t)switch(a.type){case`path`:r.save(),r.strokeStyle=n.stroke===`none`?`transparent`:n.stroke,r.lineWidth=n.strokeWidth,n.strokeLineDash&&r.setLineDash(n.strokeLineDash),n.strokeLineDashOffset&&(r.lineDashOffset=n.strokeLineDashOffset),this._drawToContext(r,a,i),r.restore();break;case`fillPath`:{r.save(),r.fillStyle=n.fill||``;let t=e.shape===`curve`||e.shape===`polygon`||e.shape===`path`?`evenodd`:`nonzero`;this._drawToContext(r,a,i,t),r.restore();break}case`fillSketch`:this.fillSketch(r,a,n)}}fillSketch(e,t,n){let r=n.fillWeight;r<0&&(r=n.strokeWidth/2),e.save(),n.fillLineDash&&e.setLineDash(n.fillLineDash),n.fillLineDashOffset&&(e.lineDashOffset=n.fillLineDashOffset),e.strokeStyle=n.fill||``,e.lineWidth=r,this._drawToContext(e,t,n.fixedDecimalPlaceDigits),e.restore()}_drawToContext(e,t,n,r=`nonzero`){e.beginPath();for(let r of t.ops){let t=typeof n==`number`&&n>=0?r.data.map((e=>+e.toFixed(n))):r.data;switch(r.op){case`move`:e.moveTo(t[0],t[1]);break;case`bcurveTo`:e.bezierCurveTo(t[0],t[1],t[2],t[3],t[4],t[5]);break;case`lineTo`:e.lineTo(t[0],t[1])}}t.type===`fillPath`?e.fill(r):e.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(e,t,n,r,i){let a=this.gen.line(e,t,n,r,i);return this.draw(a),a}rectangle(e,t,n,r,i){let a=this.gen.rectangle(e,t,n,r,i);return this.draw(a),a}ellipse(e,t,n,r,i){let a=this.gen.ellipse(e,t,n,r,i);return this.draw(a),a}circle(e,t,n,r){let i=this.gen.circle(e,t,n,r);return this.draw(i),i}linearPath(e,t){let n=this.gen.linearPath(e,t);return this.draw(n),n}polygon(e,t){let n=this.gen.polygon(e,t);return this.draw(n),n}arc(e,t,n,r,i,a,o=!1,s){let c=this.gen.arc(e,t,n,r,i,a,o,s);return this.draw(c),c}curve(e,t){let n=this.gen.curve(e,t);return this.draw(n),n}path(e,t){let n=this.gen.path(e,t);return this.draw(n),n}},$=`http://www.w3.org/2000/svg`,ie=class{constructor(e,t){this.svg=e,this.gen=new Q(t)}draw(e){let t=e.sets||[],n=e.options||this.getDefaultOptions(),r=this.svg.ownerDocument||window.document,i=r.createElementNS($,`g`),a=e.options.fixedDecimalPlaceDigits;for(let o of t){let t=null;switch(o.type){case`path`:t=r.createElementNS($,`path`),t.setAttribute(`d`,this.opsToPath(o,a)),t.setAttribute(`stroke`,n.stroke),t.setAttribute(`stroke-width`,n.strokeWidth+``),t.setAttribute(`fill`,`none`),n.strokeLineDash&&t.setAttribute(`stroke-dasharray`,n.strokeLineDash.join(` `).trim()),n.strokeLineDashOffset&&t.setAttribute(`stroke-dashoffset`,`${n.strokeLineDashOffset}`);break;case`fillPath`:t=r.createElementNS($,`path`),t.setAttribute(`d`,this.opsToPath(o,a)),t.setAttribute(`stroke`,`none`),t.setAttribute(`stroke-width`,`0`),t.setAttribute(`fill`,n.fill||``),e.shape!==`curve`&&e.shape!==`polygon`||t.setAttribute(`fill-rule`,`evenodd`);break;case`fillSketch`:t=this.fillSketch(r,o,n)}t&&i.appendChild(t)}return i}fillSketch(e,t,n){let r=n.fillWeight;r<0&&(r=n.strokeWidth/2);let i=e.createElementNS($,`path`);return i.setAttribute(`d`,this.opsToPath(t,n.fixedDecimalPlaceDigits)),i.setAttribute(`stroke`,n.fill||``),i.setAttribute(`stroke-width`,r+``),i.setAttribute(`fill`,`none`),n.fillLineDash&&i.setAttribute(`stroke-dasharray`,n.fillLineDash.join(` `).trim()),n.fillLineDashOffset&&i.setAttribute(`stroke-dashoffset`,`${n.fillLineDashOffset}`),i}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(e,t){return this.gen.opsToPath(e,t)}line(e,t,n,r,i){let a=this.gen.line(e,t,n,r,i);return this.draw(a)}rectangle(e,t,n,r,i){let a=this.gen.rectangle(e,t,n,r,i);return this.draw(a)}ellipse(e,t,n,r,i){let a=this.gen.ellipse(e,t,n,r,i);return this.draw(a)}circle(e,t,n,r){let i=this.gen.circle(e,t,n,r);return this.draw(i)}linearPath(e,t){let n=this.gen.linearPath(e,t);return this.draw(n)}polygon(e,t){let n=this.gen.polygon(e,t);return this.draw(n)}arc(e,t,n,r,i,a,o=!1,s){let c=this.gen.arc(e,t,n,r,i,a,o,s);return this.draw(c)}curve(e,t){let n=this.gen.curve(e,t);return this.draw(n)}path(e,t){let n=this.gen.path(e,t);return this.draw(n)}},ae={canvas:(e,t)=>new re(e,t),svg:(e,t)=>new ie(e,t),generator:e=>new Q(e),newSeed:()=>Q.newSeed()};export{ae as t};
@@ -0,0 +1,10 @@
1
+ import{h as e,p as t}from"./src-B6XdH6xq.js";import{B as n,C as r,K as i,V as a,W as o,_ as s,a as c,b as l,s as u,u as d,v as f}from"./chunk-ICPOFSXX-C5_hbB6H.js";import{t as p}from"./ordinal-krseTxxN.js";function m(e){for(var t=e.length/6|0,n=Array(t),r=0;r<t;)n[r]=`#`+e.slice(r*6,++r*6);return n}var h=m(`4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab`);function g(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n<t||n===void 0&&t>=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n<i||n===void 0&&i>=i)&&(n=i)}return n}function _(e,t){let n;if(t===void 0)for(let t of e)t!=null&&(n>t||n===void 0&&t>=t)&&(n=t);else{let r=-1;for(let i of e)(i=t(i,++r,e))!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}return n}function v(e,t){let n=0;if(t===void 0)for(let t of e)(t=+t)&&(n+=t);else{let r=-1;for(let i of e)(i=+t(i,++r,e))&&(n+=i)}return n}function y(e){return e.target.depth}function b(e){return e.depth}function x(e,t){return t-1-e.height}function S(e,t){return e.sourceLinks.length?e.depth:t-1}function C(e){return e.targetLinks.length?e.depth:e.sourceLinks.length?_(e.sourceLinks,y)-1:0}function w(e){return function(){return e}}function T(e,t){return D(e.source,t.source)||e.index-t.index}function E(e,t){return D(e.target,t.target)||e.index-t.index}function D(e,t){return e.y0-t.y0}function O(e){return e.value}function k(e){return e.index}function A(e){return e.nodes}function j(e){return e.links}function M(e,t){let n=e.get(t);if(!n)throw Error(`missing: `+t);return n}function N({nodes:e}){for(let t of e){let e=t.y0,n=e;for(let n of t.sourceLinks)n.y0=e+n.width/2,e+=n.width;for(let e of t.targetLinks)e.y1=n+e.width/2,n+=e.width}}function P(){let e=0,t=0,n=1,r=1,i=24,a=8,o,s=k,c=S,l,u,d=A,f=j,p=6;function m(){let e={nodes:d.apply(null,arguments),links:f.apply(null,arguments)};return h(e),y(e),b(e),x(e),F(e),N(e),e}m.update=function(e){return N(e),e},m.nodeId=function(e){return arguments.length?(s=typeof e==`function`?e:w(e),m):s},m.nodeAlign=function(e){return arguments.length?(c=typeof e==`function`?e:w(e),m):c},m.nodeSort=function(e){return arguments.length?(l=e,m):l},m.nodeWidth=function(e){return arguments.length?(i=+e,m):i},m.nodePadding=function(e){return arguments.length?(a=o=+e,m):a},m.nodes=function(e){return arguments.length?(d=typeof e==`function`?e:w(e),m):d},m.links=function(e){return arguments.length?(f=typeof e==`function`?e:w(e),m):f},m.linkSort=function(e){return arguments.length?(u=e,m):u},m.size=function(i){return arguments.length?(e=t=0,n=+i[0],r=+i[1],m):[n-e,r-t]},m.extent=function(i){return arguments.length?(e=+i[0][0],n=+i[1][0],t=+i[0][1],r=+i[1][1],m):[[e,t],[n,r]]},m.iterations=function(e){return arguments.length?(p=+e,m):p};function h({nodes:e,links:t}){for(let[t,n]of e.entries())n.index=t,n.sourceLinks=[],n.targetLinks=[];let n=new Map(e.map((t,n)=>[s(t,n,e),t]));for(let[e,r]of t.entries()){r.index=e;let{source:t,target:i}=r;typeof t!=`object`&&(t=r.source=M(n,t)),typeof i!=`object`&&(i=r.target=M(n,i)),t.sourceLinks.push(r),i.targetLinks.push(r)}if(u!=null)for(let{sourceLinks:t,targetLinks:n}of e)t.sort(u),n.sort(u)}function y({nodes:e}){for(let t of e)t.value=t.fixedValue===void 0?Math.max(v(t.sourceLinks,O),v(t.targetLinks,O)):t.fixedValue}function b({nodes:e}){let t=e.length,n=new Set(e),r=new Set,i=0;for(;n.size;){for(let e of n){e.depth=i;for(let{target:t}of e.sourceLinks)r.add(t)}if(++i>t)throw Error(`circular link`);n=r,r=new Set}}function x({nodes:e}){let t=e.length,n=new Set(e),r=new Set,i=0;for(;n.size;){for(let e of n){e.height=i;for(let{source:t}of e.targetLinks)r.add(t)}if(++i>t)throw Error(`circular link`);n=r,r=new Set}}function C({nodes:t}){let r=g(t,e=>e.depth)+1,a=(n-e-i)/(r-1),o=Array(r);for(let n of t){let t=Math.max(0,Math.min(r-1,Math.floor(c.call(null,n,r))));n.layer=t,n.x0=e+t*a,n.x1=n.x0+i,o[t]?o[t].push(n):o[t]=[n]}if(l)for(let e of o)e.sort(l);return o}function P(e){let n=_(e,e=>(r-t-(e.length-1)*o)/v(e,O));for(let i of e){let e=t;for(let t of i){t.y0=e,t.y1=e+t.value*n,e=t.y1+o;for(let e of t.sourceLinks)e.width=e.value*n}e=(r-e+o)/(i.length+1);for(let t=0;t<i.length;++t){let n=i[t];n.y0+=e*(t+1),n.y1+=e*(t+1)}H(i)}}function F(e){let n=C(e);o=Math.min(a,(r-t)/(g(n,e=>e.length)-1)),P(n);for(let e=0;e<p;++e){let t=.99**e,r=Math.max(1-t,(e+1)/p);L(n,t,r),I(n,t,r)}}function I(e,t,n){for(let r=1,i=e.length;r<i;++r){let i=e[r];for(let e of i){let n=0,r=0;for(let{source:t,value:i}of e.targetLinks){let a=i*(e.layer-t.layer);n+=U(t,e)*a,r+=a}if(!(r>0))continue;let i=(n/r-e.y0)*t;e.y0+=i,e.y1+=i,V(e)}l===void 0&&i.sort(D),R(i,n)}}function L(e,t,n){for(let r=e.length-2;r>=0;--r){let i=e[r];for(let e of i){let n=0,r=0;for(let{target:t,value:i}of e.sourceLinks){let a=i*(t.layer-e.layer);n+=W(e,t)*a,r+=a}if(!(r>0))continue;let i=(n/r-e.y0)*t;e.y0+=i,e.y1+=i,V(e)}l===void 0&&i.sort(D),R(i,n)}}function R(e,n){let i=e.length>>1,a=e[i];B(e,a.y0-o,i-1,n),z(e,a.y1+o,i+1,n),B(e,r,e.length-1,n),z(e,t,0,n)}function z(e,t,n,r){for(;n<e.length;++n){let i=e[n],a=(t-i.y0)*r;a>1e-6&&(i.y0+=a,i.y1+=a),t=i.y1+o}}function B(e,t,n,r){for(;n>=0;--n){let i=e[n],a=(i.y1-t)*r;a>1e-6&&(i.y0-=a,i.y1-=a),t=i.y0-o}}function V({sourceLinks:e,targetLinks:t}){if(u===void 0){for(let{source:{sourceLinks:e}}of t)e.sort(E);for(let{target:{targetLinks:t}}of e)t.sort(T)}}function H(e){if(u===void 0)for(let{sourceLinks:t,targetLinks:n}of e)t.sort(E),n.sort(T)}function U(e,t){let n=e.y0-(e.sourceLinks.length-1)*o/2;for(let{target:r,width:i}of e.sourceLinks){if(r===t)break;n+=i+o}for(let{source:r,width:i}of t.targetLinks){if(r===e)break;n-=i}return n}function W(e,t){let n=t.y0-(t.targetLinks.length-1)*o/2;for(let{source:r,width:i}of t.targetLinks){if(r===e)break;n+=i+o}for(let{target:r,width:i}of e.sourceLinks){if(r===t)break;n-=i}return n}return m}var F=Math.PI,I=2*F,L=1e-6,R=I-L;function z(){this._x0=this._y0=this._x1=this._y1=null,this._=``}function B(){return new z}z.prototype=B.prototype={constructor:z,moveTo:function(e,t){this._+=`M`+(this._x0=this._x1=+e)+`,`+(this._y0=this._y1=+t)},closePath:function(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+=`Z`)},lineTo:function(e,t){this._+=`L`+(this._x1=+e)+`,`+(this._y1=+t)},quadraticCurveTo:function(e,t,n,r){this._+=`Q`+ +e+`,`+ +t+`,`+(this._x1=+n)+`,`+(this._y1=+r)},bezierCurveTo:function(e,t,n,r,i,a){this._+=`C`+ +e+`,`+ +t+`,`+ +n+`,`+ +r+`,`+(this._x1=+i)+`,`+(this._y1=+a)},arcTo:function(e,t,n,r,i){e=+e,t=+t,n=+n,r=+r,i=+i;var a=this._x1,o=this._y1,s=n-e,c=r-t,l=a-e,u=o-t,d=l*l+u*u;if(i<0)throw Error(`negative radius: `+i);if(this._x1===null)this._+=`M`+(this._x1=e)+`,`+(this._y1=t);else if(d>L)if(!(Math.abs(u*s-c*l)>L)||!i)this._+=`L`+(this._x1=e)+`,`+(this._y1=t);else{var f=n-a,p=r-o,m=s*s+c*c,h=f*f+p*p,g=Math.sqrt(m),_=Math.sqrt(d),v=i*Math.tan((F-Math.acos((m+d-h)/(2*g*_)))/2),y=v/_,b=v/g;Math.abs(y-1)>L&&(this._+=`L`+(e+y*l)+`,`+(t+y*u)),this._+=`A`+i+`,`+i+`,0,0,`+ +(u*f>l*p)+`,`+(this._x1=e+b*s)+`,`+(this._y1=t+b*c)}},arc:function(e,t,n,r,i,a){e=+e,t=+t,n=+n,a=!!a;var o=n*Math.cos(r),s=n*Math.sin(r),c=e+o,l=t+s,u=1^a,d=a?r-i:i-r;if(n<0)throw Error(`negative radius: `+n);this._x1===null?this._+=`M`+c+`,`+l:(Math.abs(this._x1-c)>L||Math.abs(this._y1-l)>L)&&(this._+=`L`+c+`,`+l),n&&(d<0&&(d=d%I+I),d>R?this._+=`A`+n+`,`+n+`,0,1,`+u+`,`+(e-o)+`,`+(t-s)+`A`+n+`,`+n+`,0,1,`+u+`,`+(this._x1=c)+`,`+(this._y1=l):d>L&&(this._+=`A`+n+`,`+n+`,0,`+ +(d>=F)+`,`+u+`,`+(this._x1=e+n*Math.cos(i))+`,`+(this._y1=t+n*Math.sin(i))))},rect:function(e,t,n,r){this._+=`M`+(this._x0=this._x1=+e)+`,`+(this._y0=this._y1=+t)+`h`+ +n+`v`+ +r+`h`+-n+`Z`},toString:function(){return this._}};function V(e){return function(){return e}}function H(e){return e[0]}function U(e){return e[1]}var W=Array.prototype.slice;function ee(e){return e.source}function G(e){return e.target}function K(e){var t=ee,n=G,r=H,i=U,a=null;function o(){var o,s=W.call(arguments),c=t.apply(this,s),l=n.apply(this,s);if(a||=o=B(),e(a,+r.apply(this,(s[0]=c,s)),+i.apply(this,s),+r.apply(this,(s[0]=l,s)),+i.apply(this,s)),o)return a=null,o+``||null}return o.source=function(e){return arguments.length?(t=e,o):t},o.target=function(e){return arguments.length?(n=e,o):n},o.x=function(e){return arguments.length?(r=typeof e==`function`?e:V(+e),o):r},o.y=function(e){return arguments.length?(i=typeof e==`function`?e:V(+e),o):i},o.context=function(e){return arguments.length?(a=e??null,o):a},o}function q(e,t,n,r,i){e.moveTo(t,n),e.bezierCurveTo(t=(t+r)/2,n,t,i,r,i)}function te(){return K(q)}function ne(e){return[e.source.x1,e.y0]}function re(e){return[e.target.x0,e.y1]}function ie(){return te().source(ne).target(re)}var J=(function(){var t=e(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,9],r=[1,10],i=[1,5,10,12],a={trace:e(function(){},`trace`),yy:{},symbols_:{error:2,start:3,SANKEY:4,NEWLINE:5,csv:6,opt_eof:7,record:8,csv_tail:9,EOF:10,"field[source]":11,COMMA:12,"field[target]":13,"field[value]":14,field:15,escaped:16,non_escaped:17,DQUOTE:18,ESCAPED_TEXT:19,NON_ESCAPED_TEXT:20,$accept:0,$end:1},terminals_:{2:`error`,4:`SANKEY`,5:`NEWLINE`,10:`EOF`,11:`field[source]`,12:`COMMA`,13:`field[target]`,14:`field[value]`,18:`DQUOTE`,19:`ESCAPED_TEXT`,20:`NON_ESCAPED_TEXT`},productions_:[0,[3,4],[6,2],[9,2],[9,0],[7,1],[7,0],[8,5],[15,1],[15,1],[16,3],[17,1]],performAction:e(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 7:let e=r.findOrCreateNode(a[s-4].trim().replaceAll(`""`,`"`)),t=r.findOrCreateNode(a[s-2].trim().replaceAll(`""`,`"`)),n=parseFloat(a[s].trim());r.addLink(e,t,n);break;case 8:case 9:case 11:this.$=a[s];break;case 10:this.$=a[s-1];break}},`anonymous`),table:[{3:1,4:[1,2]},{1:[3]},{5:[1,3]},{6:4,8:5,15:6,16:7,17:8,18:n,20:r},{1:[2,6],7:11,10:[1,12]},t(r,[2,4],{9:13,5:[1,14]}),{12:[1,15]},t(i,[2,8]),t(i,[2,9]),{19:[1,16]},t(i,[2,11]),{1:[2,1]},{1:[2,5]},t(r,[2,2]),{6:17,8:5,15:6,16:7,17:8,18:n,20:r},{15:18,16:7,17:8,18:n,20:r},{18:[1,19]},t(r,[2,3]),{12:[1,20]},t(i,[2,10]),{15:21,16:7,17:8,18:n,20:r},t([1,5,10],[2,7])],defaultActions:{11:[2,1],12:[2,5]},parseError:e(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:e(function(t){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(t,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;typeof g.yy.parseError==`function`?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}e(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}e(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`:
2
+ `+h.showPosition()+`
3
+ Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};a.lexer=(function(){return{EOF:1,parseError:e(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:e(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:e(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:e(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:e(function(){return this._more=!0,this},`more`),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
+ `+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:e(function(e){this.unput(this.match.slice(e))},`less`),pastInput:e(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:e(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:e(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
5
+ `+t+`^`},`showPosition`),test_match:e(function(e,t){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),r=e[0].match(/(?:\r\n?|\n).*/g),r&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],n=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},`test_match`),next:e(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var e,t,n,r;this._more||(this.yytext=``,this.match=``);for(var i=this._currentRules(),a=0;a<i.length;a++)if(n=this._input.match(this.rules[i[a]]),n&&(!t||n[0].length>t[0].length)){if(t=n,r=a,this.options.backtrack_lexer){if(e=this.test_match(n,i[a]),e!==!1)return e;if(this._backtrack){t=!1;continue}else return!1}else if(!this.options.flex)break}return t?(e=this.test_match(t,i[r]),e===!1?!1:e):this._input===``?this.EOF:this.parseError(`Lexical error on line `+(this.yylineno+1)+`. Unrecognized text.
6
+ `+this.showPosition(),{text:``,token:null,line:this.yylineno})},`next`),lex:e(function(){return this.next()||this.lex()},`lex`),begin:e(function(e){this.conditionStack.push(e)},`begin`),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},`popState`),_currentRules:e(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},`_currentRules`),topState:e(function(e){return e=this.conditionStack.length-1-Math.abs(e||0),e>=0?this.conditionStack[e]:`INITIAL`},`topState`),pushState:e(function(e){this.begin(e)},`pushState`),stateStackSize:e(function(){return this.conditionStack.length},`stateStackSize`),options:{"case-insensitive":!0},performAction:e(function(e,t,n,r){switch(n){case 0:return this.pushState(`csv`),4;case 1:return this.pushState(`csv`),4;case 2:return 10;case 3:return 5;case 4:return 12;case 5:return this.pushState(`escaped_text`),18;case 6:return 20;case 7:return this.popState(`escaped_text`),18;case 8:return 19}},`anonymous`),rules:[/^(?:sankey-beta\b)/i,/^(?:sankey\b)/i,/^(?:$)/i,/^(?:((\u000D\u000A)|(\u000A)))/i,/^(?:(\u002C))/i,/^(?:(\u0022))/i,/^(?:([\u0020-\u0021\u0023-\u002B\u002D-\u007E])*)/i,/^(?:(\u0022)(?!(\u0022)))/i,/^(?:(([\u0020-\u0021\u0023-\u002B\u002D-\u007E])|(\u002C)|(\u000D)|(\u000A)|(\u0022)(\u0022))*)/i],conditions:{csv:{rules:[2,3,4,5,6,7,8],inclusive:!1},escaped_text:{rules:[7,8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8],inclusive:!0}}}})();function o(){this.yy={}}return e(o,`Parser`),o.prototype=a,a.Parser=o,new o})();J.parser=J;var Y=J,X=[],Z=[],Q=new Map,ae=e(()=>{X=[],Z=[],Q=new Map,c()},`clear`),oe=class{constructor(e,t,n=0){this.source=e,this.target=t,this.value=n}static{e(this,`SankeyLink`)}},se=e((e,t,n)=>{X.push(new oe(e,t,n))},`addLink`),ce=class{constructor(e){this.ID=e}static{e(this,`SankeyNode`)}},le={nodesMap:Q,getConfig:e(()=>l().sankey,`getConfig`),getNodes:e(()=>Z,`getNodes`),getLinks:e(()=>X,`getLinks`),getGraph:e(()=>({nodes:Z.map(e=>({id:e.ID})),links:X.map(e=>({source:e.source.ID,target:e.target.ID,value:e.value}))}),`getGraph`),addLink:se,findOrCreateNode:e(e=>{e=u.sanitizeText(e,l());let t=Q.get(e);return t===void 0&&(t=new ce(e),Q.set(e,t),Z.push(t)),t},`findOrCreateNode`),getAccTitle:f,setAccTitle:a,getAccDescription:s,setAccDescription:n,getDiagramTitle:r,setDiagramTitle:o,clear:ae},$=class t{static{e(this,`Uid`)}static{this.count=0}static next(e){return new t(e+ ++t.count)}constructor(e){this.id=e,this.href=`#${e}`}toString(){return`url(`+this.href+`)`}},ue={left:b,right:x,center:C,justify:S},de={draw:e(function(n,r,a,o){let{securityLevel:s,sankey:c}=l(),u=d.sankey,f;s===`sandbox`&&(f=t(`#i`+r));let m=t(s===`sandbox`?f.nodes()[0].contentDocument.body:`body`),g=s===`sandbox`?m.select(`[id="${r}"]`):t(`[id="${r}"]`),_=c?.width??u.width,v=c?.height??u.width,y=c?.useMaxWidth??u.useMaxWidth,b=c?.nodeAlignment??u.nodeAlignment,x=c?.prefix??u.prefix,S=c?.suffix??u.suffix,C=c?.showValues??u.showValues,w=o.db.getGraph(),T=ue[b];P().nodeId(e=>e.id).nodeWidth(10).nodePadding(10+(C?15:0)).nodeAlign(T).extent([[0,0],[_,v]])(w);let E=p(h);g.append(`g`).attr(`class`,`nodes`).selectAll(`.node`).data(w.nodes).join(`g`).attr(`class`,`node`).attr(`id`,e=>(e.uid=$.next(`node-`)).id).attr(`transform`,function(e){return`translate(`+e.x0+`,`+e.y0+`)`}).attr(`x`,e=>e.x0).attr(`y`,e=>e.y0).append(`rect`).attr(`height`,e=>e.y1-e.y0).attr(`width`,e=>e.x1-e.x0).attr(`fill`,e=>E(e.id));let D=e(({id:e,value:t})=>C?`${e}
7
+ ${x}${Math.round(t*100)/100}${S}`:e,`getText`);g.append(`g`).attr(`class`,`node-labels`).attr(`font-size`,14).selectAll(`text`).data(w.nodes).join(`text`).attr(`x`,e=>e.x0<_/2?e.x1+6:e.x0-6).attr(`y`,e=>(e.y1+e.y0)/2).attr(`dy`,`${C?`0`:`0.35`}em`).attr(`text-anchor`,e=>e.x0<_/2?`start`:`end`).text(D);let O=g.append(`g`).attr(`class`,`links`).attr(`fill`,`none`).attr(`stroke-opacity`,.5).selectAll(`.link`).data(w.links).join(`g`).attr(`class`,`link`).style(`mix-blend-mode`,`multiply`),k=c?.linkColor??`gradient`;if(k===`gradient`){let e=O.append(`linearGradient`).attr(`id`,e=>(e.uid=$.next(`linearGradient-`)).id).attr(`gradientUnits`,`userSpaceOnUse`).attr(`x1`,e=>e.source.x1).attr(`x2`,e=>e.target.x0);e.append(`stop`).attr(`offset`,`0%`).attr(`stop-color`,e=>E(e.source.id)),e.append(`stop`).attr(`offset`,`100%`).attr(`stop-color`,e=>E(e.target.id))}let A;switch(k){case`gradient`:A=e(e=>e.uid,`coloring`);break;case`source`:A=e(e=>E(e.source.id),`coloring`);break;case`target`:A=e(e=>E(e.target.id),`coloring`);break;default:A=k}O.append(`path`).attr(`d`,ie()).attr(`stroke`,A).attr(`stroke-width`,e=>Math.max(1,e.width)),i(void 0,g,0,y)},`draw`)},fe=e(e=>e.replaceAll(/^[^\S\n\r]+|[^\S\n\r]+$/g,``).replaceAll(/([\n\r])+/g,`
8
+ `).trim(),`prepareTextForParsing`),pe=e(e=>`.label {
9
+ font-family: ${e.fontFamily};
10
+ }`,`getStyles`),me=Y.parse.bind(Y);Y.parse=e=>me(fe(e));var he={styles:pe,parser:Y,db:le,renderer:de};export{he as diagram};