@fleox-agent-crm/agentcrm 0.0.0-stage → 0.3.1

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 (129) hide show
  1. package/LICENSE +143 -0
  2. package/README.md +223 -2
  3. package/changelog.json +76 -0
  4. package/dist/admin/admin-files.json +26 -0
  5. package/dist/admin/assets/chartsImpl-B45AAqnr.js +91 -0
  6. package/dist/admin/assets/firebase-C1x_l9P9.js +2 -0
  7. package/dist/admin/assets/gitJson-CAUSxl8d.js +3 -0
  8. package/dist/admin/assets/index-ChFauO8y.js +1181 -0
  9. package/dist/admin/assets/index-TcjySLVg.css +1 -0
  10. package/dist/admin/assets/index.esm-BFc7vwnl.js +400 -0
  11. package/dist/admin/assets/index.esm-CtEQZRb1.js +1651 -0
  12. package/dist/admin/assets/index.esm-Dum0J07z.js +16 -0
  13. package/dist/admin/assets/index.esm2017-EOzKbpUS.js +390 -0
  14. package/dist/admin/assets/lucide-react.min--rznIkmQ.js +6 -0
  15. package/dist/admin/assets/sdk-DgzLACmL.js +1717 -0
  16. package/dist/admin/config.js +3 -0
  17. package/dist/admin/favicon.svg +1 -0
  18. package/dist/admin/index.html +139 -0
  19. package/dist/admin/runtime/agentcrm-runtime.js +104 -0
  20. package/dist/admin/runtime/lucide-react.js +791 -0
  21. package/dist/admin/runtime/react-dom-client.js +17 -0
  22. package/dist/admin/runtime/react-dom.js +20 -0
  23. package/dist/admin/runtime/react-i18next.js +19 -0
  24. package/dist/admin/runtime/react-jsx-runtime.js +17 -0
  25. package/dist/admin/runtime/react.js +22 -0
  26. package/dist/agent/agentcrm.mjs +4057 -0
  27. package/dist/agent/chunks/_commonjsHelpers-ClciMIcB.mjs +14 -0
  28. package/dist/agent/chunks/activities-Cj_SIOay.mjs +227 -0
  29. package/dist/agent/chunks/api-Cz0Ubj-B.mjs +98 -0
  30. package/dist/agent/chunks/appearance-BloHbiLA.mjs +174 -0
  31. package/dist/agent/chunks/automations-DwWruxmu.mjs +698 -0
  32. package/dist/agent/chunks/backup-W3CjgkAJ.mjs +116 -0
  33. package/dist/agent/chunks/batch-CVETiJj5.mjs +142 -0
  34. package/dist/agent/chunks/compact-BGHI92tm.mjs +69 -0
  35. package/dist/agent/chunks/context-CxFfqS4D.mjs +65 -0
  36. package/dist/agent/chunks/core-Dy7vY9H6.mjs +255 -0
  37. package/dist/agent/chunks/dedupe-BepmsaHv.mjs +123 -0
  38. package/dist/agent/chunks/encoding-C9MzdP95.mjs +36 -0
  39. package/dist/agent/chunks/exportCsv-C6e6XEmB.mjs +130 -0
  40. package/dist/agent/chunks/extCheck-GgHG1dYB.mjs +200 -0
  41. package/dist/agent/chunks/extPackage-DuZ6GZhp.mjs +115 -0
  42. package/dist/agent/chunks/extScaffold-Aqyjf1nr.mjs +320 -0
  43. package/dist/agent/chunks/extensionActions-D2HtpQz4.mjs +48 -0
  44. package/dist/agent/chunks/extensions-Bp72uZ9a.mjs +164 -0
  45. package/dist/agent/chunks/featureRegistry-DSsZbhrh.mjs +149 -0
  46. package/dist/agent/chunks/fields-B0bitgmr.mjs +476 -0
  47. package/dist/agent/chunks/files-CjsPJSR6.mjs +158 -0
  48. package/dist/agent/chunks/files-D1daDgY0.mjs +367 -0
  49. package/dist/agent/chunks/firebase-DxGVQV9E.mjs +454 -0
  50. package/dist/agent/chunks/firebaseRules-iori-s7U.mjs +221 -0
  51. package/dist/agent/chunks/forms-BfuWaQjA.mjs +847 -0
  52. package/dist/agent/chunks/gitJson-fjr8mcHe.mjs +528 -0
  53. package/dist/agent/chunks/hosting-Bme7LxPc.mjs +144 -0
  54. package/dist/agent/chunks/http-Bk9ICb7I.mjs +127 -0
  55. package/dist/agent/chunks/ids-CvnmrMJX.mjs +59 -0
  56. package/dist/agent/chunks/ids-u-noYcy5.mjs +14 -0
  57. package/dist/agent/chunks/importCsv-LVmMTaWU.mjs +334 -0
  58. package/dist/agent/chunks/index-B-4W0-P4.mjs +535 -0
  59. package/dist/agent/chunks/index-BM8qeGOb.mjs +2489 -0
  60. package/dist/agent/chunks/index-Bnmav-Oh.mjs +311 -0
  61. package/dist/agent/chunks/index-CRkw3_iF.mjs +147 -0
  62. package/dist/agent/chunks/index-CWrrF1wl.mjs +111 -0
  63. package/dist/agent/chunks/index-DUSdTBkz.mjs +2988 -0
  64. package/dist/agent/chunks/index-RCmo-uld.mjs +26 -0
  65. package/dist/agent/chunks/index-w03ReRs4.mjs +9780 -0
  66. package/dist/agent/chunks/install-CbpD_7gd.mjs +188 -0
  67. package/dist/agent/chunks/jsx-runtime-Ca2uwGDr.mjs +76 -0
  68. package/dist/agent/chunks/loader-MPD9iAvh.mjs +184 -0
  69. package/dist/agent/chunks/lucide-react.min-Bt3gtepY.mjs +64 -0
  70. package/dist/agent/chunks/memory-WNR3VHUJ.mjs +56 -0
  71. package/dist/agent/chunks/migrate-CsClnnN8.mjs +182 -0
  72. package/dist/agent/chunks/modules-clWdE-K2.mjs +202 -0
  73. package/dist/agent/chunks/nodeImport-ylfRDvqt.mjs +38 -0
  74. package/dist/agent/chunks/package-B7mI6HGi.mjs +194 -0
  75. package/dist/agent/chunks/papaparse-Df7i1dHr.mjs +1309 -0
  76. package/dist/agent/chunks/pipelines-BAKpPk1w.mjs +234 -0
  77. package/dist/agent/chunks/plan-BmTat6-T.mjs +254 -0
  78. package/dist/agent/chunks/pluginRegistry-DyHtlkcr.mjs +83 -0
  79. package/dist/agent/chunks/query-C5nJB_3C.mjs +192 -0
  80. package/dist/agent/chunks/records-DcHFelq5.mjs +2195 -0
  81. package/dist/agent/chunks/registry-COfJrSmg.mjs +182 -0
  82. package/dist/agent/chunks/registry-DijAKZ24.mjs +431 -0
  83. package/dist/agent/chunks/relations-B9TynBmA.mjs +191 -0
  84. package/dist/agent/chunks/reports-BACHGccj.mjs +189 -0
  85. package/dist/agent/chunks/runtime-C0Xf0Axi.mjs +14873 -0
  86. package/dist/agent/chunks/runtimeConfig-CCOFg1RM.mjs +250 -0
  87. package/dist/agent/chunks/s3-Dz50-NuA.mjs +903 -0
  88. package/dist/agent/chunks/schema-C4lSslXv.mjs +373 -0
  89. package/dist/agent/chunks/schema-DnLj8dUO.mjs +213 -0
  90. package/dist/agent/chunks/sdk-whvfg786.mjs +43644 -0
  91. package/dist/agent/chunks/seed-6MRmQQBR.mjs +541 -0
  92. package/dist/agent/chunks/server-DC3t8r30.mjs +242 -0
  93. package/dist/agent/chunks/settings-Di8nzNEL.mjs +111 -0
  94. package/dist/agent/chunks/standardObjects-CheqfDqa.mjs +243 -0
  95. package/dist/agent/chunks/stats-BfuLWhVV.mjs +51 -0
  96. package/dist/agent/chunks/store-5gqRSKXg.mjs +122 -0
  97. package/dist/agent/chunks/themes-DPZFv3yc.mjs +43 -0
  98. package/dist/agent/chunks/tools-iSH-yMpl.mjs +884 -0
  99. package/dist/agent/chunks/types-BOy9PUl7.mjs +44 -0
  100. package/dist/agent/chunks/users-DI1BvS0f.mjs +107 -0
  101. package/dist/agent/chunks/utils-DmI8FtXP.mjs +83 -0
  102. package/dist/agent/chunks/views-DH1n9Lrt.mjs +109 -0
  103. package/dist/version.json +7 -0
  104. package/package.json +97 -4
  105. package/plugin/.claude-plugin/plugin.json +17 -0
  106. package/plugin/skills/agentcrm-admin/SKILL.md +191 -0
  107. package/plugin/skills/agentcrm-admin/references/appearance.md +26 -0
  108. package/plugin/skills/agentcrm-admin/references/import.md +16 -0
  109. package/plugin/skills/agentcrm-admin/references/records.md +30 -0
  110. package/plugin/skills/agentcrm-admin/references/schema.md +59 -0
  111. package/plugin/skills/agentcrm-extensions/SKILL.md +93 -0
  112. package/plugin/skills/agentcrm-extensions/references/module-recipes.md +213 -0
  113. package/plugin/skills/agentcrm-extensions/references/runtime-api.md +41 -0
  114. package/plugin/skills/agentcrm-extensions/references/testing.md +78 -0
  115. package/plugin/skills/agentcrm-extensions/references/theme-recipes.md +65 -0
  116. package/plugin/skills/agentcrm-install/SKILL.md +116 -0
  117. package/plugin/skills/agentcrm-install/references/firebase.md +18 -0
  118. package/plugin/skills/agentcrm-install/references/github.md +20 -0
  119. package/plugin/skills/agentcrm-install/references/mcp.md +17 -0
  120. package/plugin/skills/agentcrm-install/references/plans.md +45 -0
  121. package/plugin/skills/agentcrm-install/references/s3.md +24 -0
  122. package/plugin/skills/agentcrm-manage/SKILL.md +108 -0
  123. package/plugin/skills/agentcrm-manage/references/cron.md +11 -0
  124. package/plugin/skills/agentcrm-manage/references/doctor.md +18 -0
  125. package/plugin/skills/agentcrm-sales/SKILL.md +92 -0
  126. package/plugin/skills/agentcrm-sales/references/enrichment.md +13 -0
  127. package/plugin/skills/agentcrm-sales/references/playbooks.md +29 -0
  128. package/plugin/skills/agentcrm-sales/references/weekly-report.md +27 -0
  129. package/types/agentcrm-runtime.d.ts +894 -0
@@ -0,0 +1,3 @@
1
+ // Runtime configuration of this AgentCRM admin. Written by the setup
2
+ // wizard or `agentcrm install` next to the admin. Never contains secrets.
3
+ window.__AGENTCRM_CONFIG__ = null;
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32"><rect width="32" height="32" rx="8" fill="#18181b"/><path d="M9 22l7-12 7 12" fill="none" stroke="#fff" stroke-width="2.5" stroke-linecap="round" stroke-linejoin="round"/><circle cx="16" cy="19" r="2" fill="#598bff"/></svg>
@@ -0,0 +1,139 @@
1
+ <!doctype html>
2
+ <html lang="en">
3
+ <head>
4
+ <meta charset="UTF-8" />
5
+ <link rel="icon" type="image/svg+xml" href="./favicon.svg" />
6
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
+ <meta name="theme-color" content="#18181b" />
8
+ <meta name="google" content="notranslate" />
9
+ <!-- The CRM admin is internal-only: never index it. -->
10
+ <meta name="robots" content="noindex, nofollow, noarchive" />
11
+ <meta name="googlebot" content="noindex, nofollow, noarchive" />
12
+ <title>AgentCRM</title>
13
+ <!-- External extensions (src/extensions/) import these bare specifiers;
14
+ the stubs re-export the admin's own instances (one React). Must stay
15
+ before any module script. Kept in sync by src/extensions/runtime.test.ts. -->
16
+
17
+ <script>
18
+ // Anti-FOUC: apply the workspace appearance cached by the last visit
19
+ // (localStorage "agentcrm.appearance", written by
20
+ // src/appearance/apply.ts — same steps as applyAppearanceCache) and the
21
+ // light / dark mode synchronously, before React renders.
22
+ (function () {
23
+ var d = document,
24
+ root = d.documentElement,
25
+ cache = null;
26
+ try {
27
+ var raw = localStorage.getItem("agentcrm.appearance");
28
+ cache = raw ? JSON.parse(raw) : null;
29
+ if (!cache || cache.v !== 1) cache = null;
30
+ } catch (e) {}
31
+ function style(id, css) {
32
+ if (!css) return;
33
+ var el = d.createElement("style");
34
+ el.id = id;
35
+ el.textContent = css;
36
+ d.head.appendChild(el);
37
+ }
38
+ if (cache) {
39
+ try {
40
+ style("agentcrm-appearance", cache.css);
41
+ for (var k in cache.attrs) root.setAttribute(k, cache.attrs[k]);
42
+ if (cache.fontHref) {
43
+ var link = d.createElement("link");
44
+ link.id = "agentcrm-font";
45
+ link.rel = "stylesheet";
46
+ link.href = cache.fontHref;
47
+ d.head.appendChild(link);
48
+ }
49
+ style("agentcrm-theme-css", cache.themeCss);
50
+ style("agentcrm-custom-css", cache.customCss);
51
+ // Theme / custom CSS must come after the app stylesheet (parsed later).
52
+ d.addEventListener("DOMContentLoaded", function () {
53
+ ["agentcrm-theme-css", "agentcrm-custom-css"].forEach(function (id) {
54
+ var el = d.getElementById(id);
55
+ if (el) d.head.appendChild(el);
56
+ });
57
+ });
58
+ if (cache.favicon) {
59
+ var icon = d.querySelector('link[rel="icon"]');
60
+ if (icon) {
61
+ icon.setAttribute("data-default-href", icon.getAttribute("href") || "");
62
+ icon.removeAttribute("type");
63
+ icon.setAttribute("href", cache.favicon);
64
+ }
65
+ }
66
+ } catch (e) {}
67
+ }
68
+ try {
69
+ var stored = localStorage.getItem("agentcrm.theme");
70
+ var mode = cache && cache.defaultMode;
71
+ var prefersDark = window.matchMedia && window.matchMedia("(prefers-color-scheme: dark)").matches;
72
+ var theme = stored === "dark" || stored === "light" ? stored : mode === "dark" || mode === "light" ? mode : prefersDark ? "dark" : "light";
73
+ if (theme === "dark") root.classList.add("dark");
74
+ } catch (e) {}
75
+ })();
76
+ </script>
77
+ <style>
78
+ html,
79
+ body {
80
+ margin: 0;
81
+ padding: 0;
82
+ background: #ffffff;
83
+ }
84
+ html.dark,
85
+ html.dark body {
86
+ background: #0f0f11;
87
+ }
88
+ .agentcrm-boot {
89
+ position: fixed;
90
+ inset: 0;
91
+ display: flex;
92
+ align-items: center;
93
+ justify-content: center;
94
+ z-index: 9999;
95
+ }
96
+ .agentcrm-boot-spinner {
97
+ width: 32px;
98
+ height: 32px;
99
+ border: 3px solid rgba(113, 113, 122, 0.25);
100
+ border-top-color: rgb(var(--acc-500, 51 102 255));
101
+ border-radius: 50%;
102
+ animation: agentcrm-boot-spin 0.85s linear infinite;
103
+ }
104
+ @keyframes agentcrm-boot-spin {
105
+ to {
106
+ transform: rotate(360deg);
107
+ }
108
+ }
109
+ </style>
110
+ <script type="importmap">
111
+ {
112
+ "imports": {
113
+ "react": "./runtime/react.js",
114
+ "react/jsx-runtime": "./runtime/react-jsx-runtime.js",
115
+ "react-dom": "./runtime/react-dom.js",
116
+ "react-dom/client": "./runtime/react-dom-client.js",
117
+ "react-i18next": "./runtime/react-i18next.js",
118
+ "lucide-react": "./runtime/lucide-react.js",
119
+ "@agent-crm/runtime": "./runtime/agentcrm-runtime.js"
120
+ }
121
+ }
122
+ </script>
123
+ <script type="module" crossorigin src="./assets/index-ChFauO8y.js"></script>
124
+ <link rel="stylesheet" crossorigin href="./assets/index-TcjySLVg.css">
125
+ </head>
126
+ <body>
127
+ <div id="root">
128
+ <div class="agentcrm-boot" aria-hidden="true">
129
+ <div class="agentcrm-boot-spinner"></div>
130
+ </div>
131
+ </div>
132
+ <!-- Runtime config bootstrap — must load synchronously, before the
133
+ main bundle. Cache-busted so a freshly written config.js is never
134
+ shadowed by a cached null stub (same trick as cms-ia). -->
135
+ <script>
136
+ document.write('<script src="./config.js?_t=' + Date.now() + '"><\/script>');
137
+ </script>
138
+ </body>
139
+ </html>
@@ -0,0 +1,104 @@
1
+ // Runtime stub for "@agent-crm/runtime" — the public API of AgentCRM
2
+ // extensions. The import map of the admin's index.html (and the extension
3
+ // loader's specifier rewrite) points bundles here; every export reads the
4
+ // admin's live object globalThis.__AGENTCRM_RUNTIME__.api (populated by
5
+ // src/extensions/runtime.ts) — same React, store, router and i18n.
6
+ //
7
+ // Hand-written. Keep it identical to `runtimeApi` in
8
+ // src/extensions/runtime.ts and to types/agentcrm-runtime.d.ts
9
+ // (src/extensions/runtime.test.ts checks it).
10
+
11
+ const G = globalThis.__AGENTCRM_RUNTIME__;
12
+ const R = G ? G.api : null;
13
+ if (!R) {
14
+ throw new Error(
15
+ "[agentcrm] @agent-crm/runtime is not available: globalThis.__AGENTCRM_RUNTIME__ is not initialised (src/extensions/runtime.ts must be imported first).",
16
+ );
17
+ }
18
+
19
+ export const apiVersion = R.apiVersion;
20
+ export const minApiVersion = R.minApiVersion;
21
+ export const defineModule = R.defineModule;
22
+ export const defineTheme = R.defineTheme;
23
+ export const ops = R.ops;
24
+ export const useCrm = R.useCrm;
25
+ export const useOps = R.useOps;
26
+ export const useCan = R.useCan;
27
+ export const useCurrentUser = R.useCurrentUser;
28
+ export const useCollection = R.useCollection;
29
+ export const useObjects = R.useObjects;
30
+ export const useObject = R.useObject;
31
+ export const useRecords = R.useRecords;
32
+ export const useRecord = R.useRecord;
33
+ export const useActivities = R.useActivities;
34
+ export const usePipelines = R.usePipelines;
35
+ export const useViews = R.useViews;
36
+ export const useUsers = R.useUsers;
37
+ export const useSettings = R.useSettings;
38
+ export const useModuleConfig = R.useModuleConfig;
39
+ export const useModuleEnabled = R.useModuleEnabled;
40
+ export const useAppearance = R.useAppearance;
41
+ export const useNavigate = R.useNavigate;
42
+ export const useParams = R.useParams;
43
+ export const useSearchParams = R.useSearchParams;
44
+ export const useLocation = R.useLocation;
45
+ export const Link = R.Link;
46
+ export const NavLink = R.NavLink;
47
+ export const paths = R.paths;
48
+ export const recordHref = R.recordHref;
49
+ export const addAction = R.addAction;
50
+ export const removeAction = R.removeAction;
51
+ export const addFilter = R.addFilter;
52
+ export const removeFilter = R.removeFilter;
53
+ export const doAction = R.doAction;
54
+ export const applyFilters = R.applyFilters;
55
+ export const registerAiTool = R.registerAiTool;
56
+ export const registerAutomationAction = R.registerAutomationAction;
57
+ export const Button = R.Button;
58
+ export const IconButton = R.IconButton;
59
+ export const Input = R.Input;
60
+ export const Textarea = R.Textarea;
61
+ export const Select = R.Select;
62
+ export const Label = R.Label;
63
+ export const FormField = R.FormField;
64
+ export const Checkbox = R.Checkbox;
65
+ export const Switch = R.Switch;
66
+ export const Modal = R.Modal;
67
+ export const Drawer = R.Drawer;
68
+ export const Card = R.Card;
69
+ export const Badge = R.Badge;
70
+ export const Avatar = R.Avatar;
71
+ export const Tabs = R.Tabs;
72
+ export const Tooltip = R.Tooltip;
73
+ export const Spinner = R.Spinner;
74
+ export const EmptyState = R.EmptyState;
75
+ export const PageHeader = R.PageHeader;
76
+ export const Kbd = R.Kbd;
77
+ export const Dropdown = R.Dropdown;
78
+ export const Table = R.Table;
79
+ export const THead = R.THead;
80
+ export const TBody = R.TBody;
81
+ export const Tr = R.Tr;
82
+ export const Th = R.Th;
83
+ export const Td = R.Td;
84
+ export const FieldValue = R.FieldValue;
85
+ export const FieldInput = R.FieldInput;
86
+ export const ObjectIcon = R.ObjectIcon;
87
+ export const Markdown = R.Markdown;
88
+ export const confirmDialog = R.confirmDialog;
89
+ export const toast = R.toast;
90
+ export const cn = R.cn;
91
+ export const newId = R.newId;
92
+ export const i18n = R.i18n;
93
+ export const addBundles = R.addBundles;
94
+ export const activeLocale = R.activeLocale;
95
+ export const intlLocale = R.intlLocale;
96
+ export const formatFieldValue = R.formatFieldValue;
97
+ export const formatCurrency = R.formatCurrency;
98
+ export const formatNumber = R.formatNumber;
99
+ export const formatDate = R.formatDate;
100
+ export const formatDateTime = R.formatDateTime;
101
+ export const formatRelative = R.formatRelative;
102
+ export const recordLabel = R.recordLabel;
103
+ export const coerceFieldValue = R.coerceFieldValue;
104
+ export const isEmptyFieldValue = R.isEmptyFieldValue;