@contractspec/example.crm-pipeline 1.57.0 → 1.59.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 (259) hide show
  1. package/.turbo/turbo-build.log +148 -164
  2. package/.turbo/turbo-prebuild.log +1 -0
  3. package/CHANGELOG.md +39 -0
  4. package/dist/browser/crm-pipeline.feature.js +75 -0
  5. package/dist/browser/deal/deal.enum.js +18 -0
  6. package/dist/browser/deal/deal.operation.js +396 -0
  7. package/dist/browser/deal/deal.schema.js +141 -0
  8. package/dist/browser/deal/deal.test-spec.js +58 -0
  9. package/dist/browser/deal/index.js +408 -0
  10. package/dist/browser/docs/crm-pipeline.docblock.js +113 -0
  11. package/dist/browser/docs/index.js +113 -0
  12. package/dist/browser/entities/company.entity.js +52 -0
  13. package/dist/browser/entities/contact.entity.js +66 -0
  14. package/dist/browser/entities/deal.entity.js +107 -0
  15. package/dist/browser/entities/index.js +343 -0
  16. package/dist/browser/entities/task.entity.js +99 -0
  17. package/dist/browser/events/contact.event.js +31 -0
  18. package/dist/browser/events/deal.event.js +101 -0
  19. package/dist/browser/events/index.js +158 -0
  20. package/dist/browser/events/task.event.js +28 -0
  21. package/dist/browser/example.js +39 -0
  22. package/dist/browser/handlers/crm.handlers.js +160 -0
  23. package/dist/browser/handlers/deal.handlers.js +293 -0
  24. package/dist/browser/handlers/index.js +456 -0
  25. package/dist/browser/handlers/mock-data.js +165 -0
  26. package/dist/browser/index.js +3279 -0
  27. package/dist/browser/operations/index.js +407 -0
  28. package/dist/browser/presentations/dashboard.presentation.js +52 -0
  29. package/dist/browser/presentations/index.js +284 -0
  30. package/dist/browser/presentations/pipeline.presentation.js +233 -0
  31. package/dist/browser/seeders/index.js +22 -0
  32. package/dist/browser/shared/overlay-types.js +0 -0
  33. package/dist/browser/ui/CrmDashboard.js +1325 -0
  34. package/dist/browser/ui/CrmDealCard.js +50 -0
  35. package/dist/browser/ui/CrmPipelineBoard.js +160 -0
  36. package/dist/browser/ui/hooks/index.js +186 -0
  37. package/dist/browser/ui/hooks/useDealList.js +84 -0
  38. package/dist/browser/ui/hooks/useDealMutations.js +100 -0
  39. package/dist/browser/ui/index.js +1972 -0
  40. package/dist/browser/ui/modals/CreateDealModal.js +211 -0
  41. package/dist/browser/ui/modals/DealActionsModal.js +428 -0
  42. package/dist/browser/ui/modals/index.js +638 -0
  43. package/dist/browser/ui/overlays/demo-overlays.js +55 -0
  44. package/dist/browser/ui/overlays/index.js +55 -0
  45. package/dist/browser/ui/renderers/index.js +827 -0
  46. package/dist/browser/ui/renderers/pipeline.markdown.js +564 -0
  47. package/dist/browser/ui/renderers/pipeline.renderer.js +264 -0
  48. package/dist/crm-pipeline.feature.d.ts +1 -6
  49. package/dist/crm-pipeline.feature.d.ts.map +1 -1
  50. package/dist/crm-pipeline.feature.js +74 -164
  51. package/dist/deal/deal.enum.d.ts +2 -7
  52. package/dist/deal/deal.enum.d.ts.map +1 -1
  53. package/dist/deal/deal.enum.js +16 -22
  54. package/dist/deal/deal.operation.d.ts +444 -450
  55. package/dist/deal/deal.operation.d.ts.map +1 -1
  56. package/dist/deal/deal.operation.js +390 -263
  57. package/dist/deal/deal.schema.d.ts +251 -256
  58. package/dist/deal/deal.schema.d.ts.map +1 -1
  59. package/dist/deal/deal.schema.js +131 -275
  60. package/dist/deal/deal.test-spec.d.ts +2 -7
  61. package/dist/deal/deal.test-spec.d.ts.map +1 -1
  62. package/dist/deal/deal.test-spec.js +56 -62
  63. package/dist/deal/index.d.ts +7 -4
  64. package/dist/deal/index.d.ts.map +1 -0
  65. package/dist/deal/index.js +408 -4
  66. package/dist/docs/crm-pipeline.docblock.d.ts +2 -1
  67. package/dist/docs/crm-pipeline.docblock.d.ts.map +1 -0
  68. package/dist/docs/crm-pipeline.docblock.js +45 -51
  69. package/dist/docs/index.d.ts +2 -1
  70. package/dist/docs/index.d.ts.map +1 -0
  71. package/dist/docs/index.js +114 -1
  72. package/dist/entities/company.entity.d.ts +27 -32
  73. package/dist/entities/company.entity.d.ts.map +1 -1
  74. package/dist/entities/company.entity.js +51 -61
  75. package/dist/entities/contact.entity.d.ts +31 -36
  76. package/dist/entities/contact.entity.d.ts.map +1 -1
  77. package/dist/entities/contact.entity.js +65 -76
  78. package/dist/entities/deal.entity.d.ts +52 -57
  79. package/dist/entities/deal.entity.d.ts.map +1 -1
  80. package/dist/entities/deal.entity.js +104 -116
  81. package/dist/entities/index.d.ts +6 -10
  82. package/dist/entities/index.d.ts.map +1 -1
  83. package/dist/entities/index.js +342 -31
  84. package/dist/entities/task.entity.d.ts +42 -47
  85. package/dist/entities/task.entity.d.ts.map +1 -1
  86. package/dist/entities/task.entity.js +95 -124
  87. package/dist/events/contact.event.d.ts +21 -27
  88. package/dist/events/contact.event.d.ts.map +1 -1
  89. package/dist/events/contact.event.js +29 -42
  90. package/dist/events/deal.event.d.ts +100 -106
  91. package/dist/events/deal.event.d.ts.map +1 -1
  92. package/dist/events/deal.event.js +93 -163
  93. package/dist/events/index.d.ts +4 -4
  94. package/dist/events/index.d.ts.map +1 -0
  95. package/dist/events/index.js +158 -4
  96. package/dist/events/task.event.d.ts +21 -27
  97. package/dist/events/task.event.d.ts.map +1 -1
  98. package/dist/events/task.event.js +26 -42
  99. package/dist/example.d.ts +2 -6
  100. package/dist/example.d.ts.map +1 -1
  101. package/dist/example.js +38 -50
  102. package/dist/handlers/crm.handlers.d.ts +80 -78
  103. package/dist/handlers/crm.handlers.d.ts.map +1 -1
  104. package/dist/handlers/crm.handlers.js +155 -166
  105. package/dist/handlers/deal.handlers.d.ts +58 -63
  106. package/dist/handlers/deal.handlers.d.ts.map +1 -1
  107. package/dist/handlers/deal.handlers.js +279 -105
  108. package/dist/handlers/index.d.ts +10 -4
  109. package/dist/handlers/index.d.ts.map +1 -0
  110. package/dist/handlers/index.js +456 -4
  111. package/dist/handlers/mock-data.d.ts +38 -41
  112. package/dist/handlers/mock-data.d.ts.map +1 -1
  113. package/dist/handlers/mock-data.js +162 -184
  114. package/dist/index.d.ts +13 -42
  115. package/dist/index.d.ts.map +1 -1
  116. package/dist/index.js +3277 -53
  117. package/dist/node/crm-pipeline.feature.js +75 -0
  118. package/dist/node/deal/deal.enum.js +18 -0
  119. package/dist/node/deal/deal.operation.js +396 -0
  120. package/dist/node/deal/deal.schema.js +141 -0
  121. package/dist/node/deal/deal.test-spec.js +58 -0
  122. package/dist/node/deal/index.js +408 -0
  123. package/dist/node/docs/crm-pipeline.docblock.js +113 -0
  124. package/dist/node/docs/index.js +113 -0
  125. package/dist/node/entities/company.entity.js +52 -0
  126. package/dist/node/entities/contact.entity.js +66 -0
  127. package/dist/node/entities/deal.entity.js +107 -0
  128. package/dist/node/entities/index.js +343 -0
  129. package/dist/node/entities/task.entity.js +99 -0
  130. package/dist/node/events/contact.event.js +31 -0
  131. package/dist/node/events/deal.event.js +101 -0
  132. package/dist/node/events/index.js +158 -0
  133. package/dist/node/events/task.event.js +28 -0
  134. package/dist/node/example.js +39 -0
  135. package/dist/node/handlers/crm.handlers.js +160 -0
  136. package/dist/node/handlers/deal.handlers.js +293 -0
  137. package/dist/node/handlers/index.js +456 -0
  138. package/dist/node/handlers/mock-data.js +165 -0
  139. package/dist/node/index.js +3279 -0
  140. package/dist/node/operations/index.js +407 -0
  141. package/dist/node/presentations/dashboard.presentation.js +52 -0
  142. package/dist/node/presentations/index.js +284 -0
  143. package/dist/node/presentations/pipeline.presentation.js +233 -0
  144. package/dist/node/seeders/index.js +22 -0
  145. package/dist/node/shared/overlay-types.js +0 -0
  146. package/dist/node/ui/CrmDashboard.js +1325 -0
  147. package/dist/node/ui/CrmDealCard.js +50 -0
  148. package/dist/node/ui/CrmPipelineBoard.js +160 -0
  149. package/dist/node/ui/hooks/index.js +186 -0
  150. package/dist/node/ui/hooks/useDealList.js +84 -0
  151. package/dist/node/ui/hooks/useDealMutations.js +100 -0
  152. package/dist/node/ui/index.js +1972 -0
  153. package/dist/node/ui/modals/CreateDealModal.js +211 -0
  154. package/dist/node/ui/modals/DealActionsModal.js +428 -0
  155. package/dist/node/ui/modals/index.js +638 -0
  156. package/dist/node/ui/overlays/demo-overlays.js +55 -0
  157. package/dist/node/ui/overlays/index.js +55 -0
  158. package/dist/node/ui/renderers/index.js +827 -0
  159. package/dist/node/ui/renderers/pipeline.markdown.js +564 -0
  160. package/dist/node/ui/renderers/pipeline.renderer.js +264 -0
  161. package/dist/operations/index.d.ts +2 -5
  162. package/dist/operations/index.d.ts.map +1 -0
  163. package/dist/operations/index.js +407 -5
  164. package/dist/presentations/dashboard.presentation.d.ts +2 -7
  165. package/dist/presentations/dashboard.presentation.d.ts.map +1 -1
  166. package/dist/presentations/dashboard.presentation.js +51 -60
  167. package/dist/presentations/index.d.ts +3 -3
  168. package/dist/presentations/index.d.ts.map +1 -0
  169. package/dist/presentations/index.js +284 -3
  170. package/dist/presentations/pipeline.presentation.d.ts +4 -9
  171. package/dist/presentations/pipeline.presentation.d.ts.map +1 -1
  172. package/dist/presentations/pipeline.presentation.js +228 -116
  173. package/dist/seeders/index.d.ts +4 -8
  174. package/dist/seeders/index.d.ts.map +1 -1
  175. package/dist/seeders/index.js +21 -45
  176. package/dist/shared/overlay-types.d.ts +25 -28
  177. package/dist/shared/overlay-types.d.ts.map +1 -1
  178. package/dist/shared/overlay-types.js +1 -0
  179. package/dist/ui/CrmDashboard.d.ts +1 -6
  180. package/dist/ui/CrmDashboard.d.ts.map +1 -1
  181. package/dist/ui/CrmDashboard.js +1318 -296
  182. package/dist/ui/CrmDealCard.d.ts +8 -12
  183. package/dist/ui/CrmDealCard.d.ts.map +1 -1
  184. package/dist/ui/CrmDealCard.js +47 -45
  185. package/dist/ui/CrmPipelineBoard.d.ts +11 -20
  186. package/dist/ui/CrmPipelineBoard.d.ts.map +1 -1
  187. package/dist/ui/CrmPipelineBoard.js +157 -94
  188. package/dist/ui/hooks/index.d.ts +3 -3
  189. package/dist/ui/hooks/index.d.ts.map +1 -0
  190. package/dist/ui/hooks/index.js +185 -4
  191. package/dist/ui/hooks/useDealList.d.ts +28 -32
  192. package/dist/ui/hooks/useDealList.d.ts.map +1 -1
  193. package/dist/ui/hooks/useDealList.js +81 -90
  194. package/dist/ui/hooks/useDealMutations.d.ts +18 -22
  195. package/dist/ui/hooks/useDealMutations.d.ts.map +1 -1
  196. package/dist/ui/hooks/useDealMutations.js +97 -155
  197. package/dist/ui/index.d.ts +8 -14
  198. package/dist/ui/index.d.ts.map +1 -0
  199. package/dist/ui/index.js +1973 -15
  200. package/dist/ui/modals/CreateDealModal.d.ts +19 -29
  201. package/dist/ui/modals/CreateDealModal.d.ts.map +1 -1
  202. package/dist/ui/modals/CreateDealModal.js +209 -180
  203. package/dist/ui/modals/DealActionsModal.d.ts +31 -44
  204. package/dist/ui/modals/DealActionsModal.d.ts.map +1 -1
  205. package/dist/ui/modals/DealActionsModal.js +424 -367
  206. package/dist/ui/modals/index.d.ts +3 -3
  207. package/dist/ui/modals/index.d.ts.map +1 -0
  208. package/dist/ui/modals/index.js +638 -3
  209. package/dist/ui/overlays/demo-overlays.d.ts +10 -8
  210. package/dist/ui/overlays/demo-overlays.d.ts.map +1 -1
  211. package/dist/ui/overlays/demo-overlays.js +54 -66
  212. package/dist/ui/overlays/index.d.ts +2 -2
  213. package/dist/ui/overlays/index.d.ts.map +1 -0
  214. package/dist/ui/overlays/index.js +56 -3
  215. package/dist/ui/renderers/index.d.ts +3 -3
  216. package/dist/ui/renderers/index.d.ts.map +1 -0
  217. package/dist/ui/renderers/index.js +827 -3
  218. package/dist/ui/renderers/pipeline.markdown.d.ts +12 -11
  219. package/dist/ui/renderers/pipeline.markdown.d.ts.map +1 -1
  220. package/dist/ui/renderers/pipeline.markdown.js +560 -114
  221. package/dist/ui/renderers/pipeline.renderer.d.ts +9 -7
  222. package/dist/ui/renderers/pipeline.renderer.d.ts.map +1 -1
  223. package/dist/ui/renderers/pipeline.renderer.js +261 -24
  224. package/package.json +476 -90
  225. package/tsdown.config.js +1 -2
  226. package/.turbo/turbo-build$colon$bundle.log +0 -164
  227. package/dist/crm-pipeline.feature.js.map +0 -1
  228. package/dist/deal/deal.enum.js.map +0 -1
  229. package/dist/deal/deal.operation.js.map +0 -1
  230. package/dist/deal/deal.schema.js.map +0 -1
  231. package/dist/deal/deal.test-spec.js.map +0 -1
  232. package/dist/docs/crm-pipeline.docblock.js.map +0 -1
  233. package/dist/entities/company.entity.js.map +0 -1
  234. package/dist/entities/contact.entity.js.map +0 -1
  235. package/dist/entities/deal.entity.js.map +0 -1
  236. package/dist/entities/index.js.map +0 -1
  237. package/dist/entities/task.entity.js.map +0 -1
  238. package/dist/events/contact.event.js.map +0 -1
  239. package/dist/events/deal.event.js.map +0 -1
  240. package/dist/events/task.event.js.map +0 -1
  241. package/dist/example.js.map +0 -1
  242. package/dist/handlers/crm.handlers.js.map +0 -1
  243. package/dist/handlers/deal.handlers.js.map +0 -1
  244. package/dist/handlers/mock-data.js.map +0 -1
  245. package/dist/index.js.map +0 -1
  246. package/dist/presentations/dashboard.presentation.js.map +0 -1
  247. package/dist/presentations/pipeline.presentation.js.map +0 -1
  248. package/dist/seeders/index.js.map +0 -1
  249. package/dist/ui/CrmDashboard.js.map +0 -1
  250. package/dist/ui/CrmDealCard.js.map +0 -1
  251. package/dist/ui/CrmPipelineBoard.js.map +0 -1
  252. package/dist/ui/hooks/useDealList.js.map +0 -1
  253. package/dist/ui/hooks/useDealMutations.js.map +0 -1
  254. package/dist/ui/modals/CreateDealModal.js.map +0 -1
  255. package/dist/ui/modals/DealActionsModal.js.map +0 -1
  256. package/dist/ui/overlays/demo-overlays.js.map +0 -1
  257. package/dist/ui/renderers/pipeline.markdown.js.map +0 -1
  258. package/dist/ui/renderers/pipeline.renderer.js.map +0 -1
  259. package/tsconfig.tsbuildinfo +0 -1
@@ -1,188 +1,166 @@
1
- //#region src/handlers/mock-data.ts
2
- const MOCK_STAGES = [
3
- {
4
- id: "stage-1",
5
- name: "Lead",
6
- position: 1,
7
- pipelineId: "pipeline-1"
8
- },
9
- {
10
- id: "stage-2",
11
- name: "Qualified",
12
- position: 2,
13
- pipelineId: "pipeline-1"
14
- },
15
- {
16
- id: "stage-3",
17
- name: "Proposal",
18
- position: 3,
19
- pipelineId: "pipeline-1"
20
- },
21
- {
22
- id: "stage-4",
23
- name: "Negotiation",
24
- position: 4,
25
- pipelineId: "pipeline-1"
26
- },
27
- {
28
- id: "stage-5",
29
- name: "Closed",
30
- position: 5,
31
- pipelineId: "pipeline-1"
32
- }
1
+ // @bun
2
+ // src/handlers/mock-data.ts
3
+ var MOCK_STAGES = [
4
+ { id: "stage-1", name: "Lead", position: 1, pipelineId: "pipeline-1" },
5
+ { id: "stage-2", name: "Qualified", position: 2, pipelineId: "pipeline-1" },
6
+ { id: "stage-3", name: "Proposal", position: 3, pipelineId: "pipeline-1" },
7
+ { id: "stage-4", name: "Negotiation", position: 4, pipelineId: "pipeline-1" },
8
+ { id: "stage-5", name: "Closed", position: 5, pipelineId: "pipeline-1" }
33
9
  ];
34
- const MOCK_DEALS = [
35
- {
36
- id: "deal-1",
37
- name: "Enterprise License - Acme Corp",
38
- value: 75e3,
39
- currency: "USD",
40
- pipelineId: "pipeline-1",
41
- stageId: "stage-3",
42
- status: "OPEN",
43
- contactId: "contact-1",
44
- companyId: "company-1",
45
- ownerId: "user-1",
46
- expectedCloseDate: /* @__PURE__ */ new Date("2024-05-15T00:00:00Z"),
47
- createdAt: /* @__PURE__ */ new Date("2024-02-01T10:00:00Z"),
48
- updatedAt: /* @__PURE__ */ new Date("2024-04-10T14:30:00Z")
49
- },
50
- {
51
- id: "deal-2",
52
- name: "Startup Plan - TechStart Inc",
53
- value: 12e3,
54
- currency: "USD",
55
- pipelineId: "pipeline-1",
56
- stageId: "stage-2",
57
- status: "OPEN",
58
- contactId: "contact-2",
59
- companyId: "company-2",
60
- ownerId: "user-2",
61
- expectedCloseDate: /* @__PURE__ */ new Date("2024-04-30T00:00:00Z"),
62
- createdAt: /* @__PURE__ */ new Date("2024-03-15T09:00:00Z"),
63
- updatedAt: /* @__PURE__ */ new Date("2024-04-08T11:15:00Z")
64
- },
65
- {
66
- id: "deal-3",
67
- name: "Professional Services - Global Ltd",
68
- value: 45e3,
69
- currency: "USD",
70
- pipelineId: "pipeline-1",
71
- stageId: "stage-4",
72
- status: "OPEN",
73
- contactId: "contact-3",
74
- companyId: "company-3",
75
- ownerId: "user-1",
76
- expectedCloseDate: /* @__PURE__ */ new Date("2024-04-20T00:00:00Z"),
77
- createdAt: /* @__PURE__ */ new Date("2024-01-20T08:00:00Z"),
78
- updatedAt: /* @__PURE__ */ new Date("2024-04-12T16:45:00Z")
79
- },
80
- {
81
- id: "deal-4",
82
- name: "Annual Contract - SmallBiz Co",
83
- value: 8500,
84
- currency: "USD",
85
- pipelineId: "pipeline-1",
86
- stageId: "stage-1",
87
- status: "OPEN",
88
- contactId: "contact-4",
89
- companyId: "company-4",
90
- ownerId: "user-3",
91
- createdAt: /* @__PURE__ */ new Date("2024-04-05T12:00:00Z"),
92
- updatedAt: /* @__PURE__ */ new Date("2024-04-05T12:00:00Z")
93
- },
94
- {
95
- id: "deal-5",
96
- name: "Custom Integration - MegaCorp",
97
- value: 125e3,
98
- currency: "USD",
99
- pipelineId: "pipeline-1",
100
- stageId: "stage-5",
101
- status: "WON",
102
- contactId: "contact-5",
103
- companyId: "company-5",
104
- ownerId: "user-1",
105
- expectedCloseDate: /* @__PURE__ */ new Date("2024-03-31T00:00:00Z"),
106
- createdAt: /* @__PURE__ */ new Date("2023-11-10T10:00:00Z"),
107
- updatedAt: /* @__PURE__ */ new Date("2024-03-28T09:00:00Z")
108
- },
109
- {
110
- id: "deal-6",
111
- name: "Pilot Project - NewCo",
112
- value: 5e3,
113
- currency: "USD",
114
- pipelineId: "pipeline-1",
115
- stageId: "stage-2",
116
- status: "LOST",
117
- contactId: "contact-6",
118
- companyId: "company-6",
119
- ownerId: "user-2",
120
- createdAt: /* @__PURE__ */ new Date("2024-01-15T14:00:00Z"),
121
- updatedAt: /* @__PURE__ */ new Date("2024-02-28T10:30:00Z")
122
- }
10
+ var MOCK_DEALS = [
11
+ {
12
+ id: "deal-1",
13
+ name: "Enterprise License - Acme Corp",
14
+ value: 75000,
15
+ currency: "USD",
16
+ pipelineId: "pipeline-1",
17
+ stageId: "stage-3",
18
+ status: "OPEN",
19
+ contactId: "contact-1",
20
+ companyId: "company-1",
21
+ ownerId: "user-1",
22
+ expectedCloseDate: new Date("2024-05-15T00:00:00Z"),
23
+ createdAt: new Date("2024-02-01T10:00:00Z"),
24
+ updatedAt: new Date("2024-04-10T14:30:00Z")
25
+ },
26
+ {
27
+ id: "deal-2",
28
+ name: "Startup Plan - TechStart Inc",
29
+ value: 12000,
30
+ currency: "USD",
31
+ pipelineId: "pipeline-1",
32
+ stageId: "stage-2",
33
+ status: "OPEN",
34
+ contactId: "contact-2",
35
+ companyId: "company-2",
36
+ ownerId: "user-2",
37
+ expectedCloseDate: new Date("2024-04-30T00:00:00Z"),
38
+ createdAt: new Date("2024-03-15T09:00:00Z"),
39
+ updatedAt: new Date("2024-04-08T11:15:00Z")
40
+ },
41
+ {
42
+ id: "deal-3",
43
+ name: "Professional Services - Global Ltd",
44
+ value: 45000,
45
+ currency: "USD",
46
+ pipelineId: "pipeline-1",
47
+ stageId: "stage-4",
48
+ status: "OPEN",
49
+ contactId: "contact-3",
50
+ companyId: "company-3",
51
+ ownerId: "user-1",
52
+ expectedCloseDate: new Date("2024-04-20T00:00:00Z"),
53
+ createdAt: new Date("2024-01-20T08:00:00Z"),
54
+ updatedAt: new Date("2024-04-12T16:45:00Z")
55
+ },
56
+ {
57
+ id: "deal-4",
58
+ name: "Annual Contract - SmallBiz Co",
59
+ value: 8500,
60
+ currency: "USD",
61
+ pipelineId: "pipeline-1",
62
+ stageId: "stage-1",
63
+ status: "OPEN",
64
+ contactId: "contact-4",
65
+ companyId: "company-4",
66
+ ownerId: "user-3",
67
+ createdAt: new Date("2024-04-05T12:00:00Z"),
68
+ updatedAt: new Date("2024-04-05T12:00:00Z")
69
+ },
70
+ {
71
+ id: "deal-5",
72
+ name: "Custom Integration - MegaCorp",
73
+ value: 125000,
74
+ currency: "USD",
75
+ pipelineId: "pipeline-1",
76
+ stageId: "stage-5",
77
+ status: "WON",
78
+ contactId: "contact-5",
79
+ companyId: "company-5",
80
+ ownerId: "user-1",
81
+ expectedCloseDate: new Date("2024-03-31T00:00:00Z"),
82
+ createdAt: new Date("2023-11-10T10:00:00Z"),
83
+ updatedAt: new Date("2024-03-28T09:00:00Z")
84
+ },
85
+ {
86
+ id: "deal-6",
87
+ name: "Pilot Project - NewCo",
88
+ value: 5000,
89
+ currency: "USD",
90
+ pipelineId: "pipeline-1",
91
+ stageId: "stage-2",
92
+ status: "LOST",
93
+ contactId: "contact-6",
94
+ companyId: "company-6",
95
+ ownerId: "user-2",
96
+ createdAt: new Date("2024-01-15T14:00:00Z"),
97
+ updatedAt: new Date("2024-02-28T10:30:00Z")
98
+ }
123
99
  ];
124
- const MOCK_COMPANIES = [
125
- {
126
- id: "company-1",
127
- name: "Acme Corporation",
128
- domain: "acme.com",
129
- industry: "Technology",
130
- size: "1000-5000",
131
- website: "https://acme.com",
132
- createdAt: /* @__PURE__ */ new Date("2024-01-01T00:00:00Z")
133
- },
134
- {
135
- id: "company-2",
136
- name: "TechStart Inc",
137
- domain: "techstart.io",
138
- industry: "Software",
139
- size: "10-50",
140
- website: "https://techstart.io",
141
- createdAt: /* @__PURE__ */ new Date("2024-02-15T00:00:00Z")
142
- },
143
- {
144
- id: "company-3",
145
- name: "Global Ltd",
146
- domain: "global.com",
147
- industry: "Consulting",
148
- size: "500-1000",
149
- website: "https://global.com",
150
- createdAt: /* @__PURE__ */ new Date("2023-12-01T00:00:00Z")
151
- }
100
+ var MOCK_COMPANIES = [
101
+ {
102
+ id: "company-1",
103
+ name: "Acme Corporation",
104
+ domain: "acme.com",
105
+ industry: "Technology",
106
+ size: "1000-5000",
107
+ website: "https://acme.com",
108
+ createdAt: new Date("2024-01-01T00:00:00Z")
109
+ },
110
+ {
111
+ id: "company-2",
112
+ name: "TechStart Inc",
113
+ domain: "techstart.io",
114
+ industry: "Software",
115
+ size: "10-50",
116
+ website: "https://techstart.io",
117
+ createdAt: new Date("2024-02-15T00:00:00Z")
118
+ },
119
+ {
120
+ id: "company-3",
121
+ name: "Global Ltd",
122
+ domain: "global.com",
123
+ industry: "Consulting",
124
+ size: "500-1000",
125
+ website: "https://global.com",
126
+ createdAt: new Date("2023-12-01T00:00:00Z")
127
+ }
152
128
  ];
153
- const MOCK_CONTACTS = [
154
- {
155
- id: "contact-1",
156
- firstName: "John",
157
- lastName: "Smith",
158
- email: "john.smith@acme.com",
159
- phone: "+1-555-0101",
160
- title: "VP of Engineering",
161
- companyId: "company-1",
162
- createdAt: /* @__PURE__ */ new Date("2024-01-05T00:00:00Z")
163
- },
164
- {
165
- id: "contact-2",
166
- firstName: "Sarah",
167
- lastName: "Johnson",
168
- email: "sarah@techstart.io",
169
- phone: "+1-555-0102",
170
- title: "CEO",
171
- companyId: "company-2",
172
- createdAt: /* @__PURE__ */ new Date("2024-02-20T00:00:00Z")
173
- },
174
- {
175
- id: "contact-3",
176
- firstName: "Michael",
177
- lastName: "Brown",
178
- email: "michael.brown@global.com",
179
- phone: "+1-555-0103",
180
- title: "CTO",
181
- companyId: "company-3",
182
- createdAt: /* @__PURE__ */ new Date("2023-12-10T00:00:00Z")
183
- }
129
+ var MOCK_CONTACTS = [
130
+ {
131
+ id: "contact-1",
132
+ firstName: "John",
133
+ lastName: "Smith",
134
+ email: "john.smith@acme.com",
135
+ phone: "+1-555-0101",
136
+ title: "VP of Engineering",
137
+ companyId: "company-1",
138
+ createdAt: new Date("2024-01-05T00:00:00Z")
139
+ },
140
+ {
141
+ id: "contact-2",
142
+ firstName: "Sarah",
143
+ lastName: "Johnson",
144
+ email: "sarah@techstart.io",
145
+ phone: "+1-555-0102",
146
+ title: "CEO",
147
+ companyId: "company-2",
148
+ createdAt: new Date("2024-02-20T00:00:00Z")
149
+ },
150
+ {
151
+ id: "contact-3",
152
+ firstName: "Michael",
153
+ lastName: "Brown",
154
+ email: "michael.brown@global.com",
155
+ phone: "+1-555-0103",
156
+ title: "CTO",
157
+ companyId: "company-3",
158
+ createdAt: new Date("2023-12-10T00:00:00Z")
159
+ }
184
160
  ];
185
-
186
- //#endregion
187
- export { MOCK_COMPANIES, MOCK_CONTACTS, MOCK_DEALS, MOCK_STAGES };
188
- //# sourceMappingURL=mock-data.js.map
161
+ export {
162
+ MOCK_STAGES,
163
+ MOCK_DEALS,
164
+ MOCK_CONTACTS,
165
+ MOCK_COMPANIES
166
+ };
package/dist/index.d.ts CHANGED
@@ -1,47 +1,18 @@
1
- import { CrmPipelineFeature } from "./crm-pipeline.feature.js";
2
- import { DealStatusFilterEnum } from "./deal/deal.enum.js";
3
- import { CreateDealContract, ListDealsContract, LoseDealContract, MoveDealContract, WinDealContract } from "./deal/deal.operation.js";
4
- import { CreateDealInputModel, DealLostPayloadModel, DealModel, DealMovedPayloadModel, DealWonPayloadModel, ListDealsInputModel, ListDealsOutputModel, LoseDealInputModel, MoveDealInputModel, WinDealInputModel } from "./deal/deal.schema.js";
5
- import { CompanyEntity, CompanySizeEnum } from "./entities/company.entity.js";
6
- import { ContactEntity, ContactStatusEnum } from "./entities/contact.entity.js";
7
- import { DealEntity, DealStatusEnum, PipelineEntity, StageEntity } from "./entities/deal.entity.js";
8
- import { ActivityEntity, TaskEntity, TaskPriorityEnum, TaskStatusEnum, TaskTypeEnum } from "./entities/task.entity.js";
9
- import { crmPipelineSchemaContribution } from "./entities/index.js";
10
- import { ContactCreatedEvent } from "./events/contact.event.js";
11
- import { DealCreatedEvent, DealLostEvent, DealMovedEvent, DealWonEvent } from "./events/deal.event.js";
12
- import { TaskCompletedEvent } from "./events/task.event.js";
13
- import "./events/index.js";
14
- import example from "./example.js";
15
- import { CrmHandlers, Stage, createCrmHandlers } from "./handlers/crm.handlers.js";
16
- import { MOCK_COMPANIES, MOCK_CONTACTS, MOCK_DEALS, MOCK_STAGES, MockDeal, MockStage } from "./handlers/mock-data.js";
17
- import { CreateDealInput, Deal, ListDealsInput, ListDealsOutput, LoseDealInput, MoveDealInput, WinDealInput, mockCreateDealHandler, mockGetDealsByStageHandler, mockGetPipelineStagesHandler, mockListDealsHandler, mockLoseDealHandler, mockMoveDealHandler, mockWinDealHandler } from "./handlers/deal.handlers.js";
18
- import "./handlers/index.js";
19
- import "./operations/index.js";
20
- import { CrmDashboardPresentation, PipelineMetricsPresentation } from "./presentations/dashboard.presentation.js";
21
- import { DealCardPresentation, DealDetailPresentation, DealListPresentation, PipelineKanbanPresentation } from "./presentations/pipeline.presentation.js";
22
- import "./presentations/index.js";
23
- import { CrmDashboard } from "./ui/CrmDashboard.js";
24
- import { UseDealListOptions, useDealList } from "./ui/hooks/useDealList.js";
25
- import { CrmPipelineBoard } from "./ui/CrmPipelineBoard.js";
26
- import { CrmDealCard } from "./ui/CrmDealCard.js";
27
- import { CreateDealModal } from "./ui/modals/CreateDealModal.js";
28
- import { DealActionsModal } from "./ui/modals/DealActionsModal.js";
29
- import { UseDealMutationsOptions, useDealMutations } from "./ui/hooks/useDealMutations.js";
30
- import { crmPipelineReactRenderer } from "./ui/renderers/pipeline.renderer.js";
31
- import { crmDashboardMarkdownRenderer, crmPipelineMarkdownRenderer } from "./ui/renderers/pipeline.markdown.js";
32
- import { crmDemoOverlay, crmOverlays, crmSalesRepOverlay } from "./ui/overlays/demo-overlays.js";
33
- import "./ui/index.js";
34
- import * as _contractspec_lib_schema0 from "@contractspec/lib.schema";
35
-
36
- //#region src/index.d.ts
1
+ export * from './entities';
2
+ export * from './operations';
3
+ export * from './events';
4
+ export * from './handlers';
5
+ export * from './presentations';
6
+ export * from './ui';
7
+ export * from './crm-pipeline.feature';
8
+ export { default as example } from './example';
9
+ import './docs';
37
10
  /**
38
11
  * Complete schema composition for CRM Pipeline.
39
12
  */
40
- declare const schemaComposition: {
41
- modules: _contractspec_lib_schema0.ModuleSchemaContribution[];
42
- provider: "postgresql";
43
- outputPath: string;
13
+ export declare const schemaComposition: {
14
+ modules: import("@contractspec/lib.schema").ModuleSchemaContribution[];
15
+ provider: "postgresql";
16
+ outputPath: string;
44
17
  };
45
- //#endregion
46
- export { ActivityEntity, CompanyEntity, CompanySizeEnum, ContactCreatedEvent, ContactEntity, ContactStatusEnum, CreateDealContract, CreateDealInput, CreateDealInputModel, CreateDealModal, CrmDashboard, CrmDashboardPresentation, CrmDealCard, CrmHandlers, CrmPipelineBoard, CrmPipelineFeature, Deal, DealActionsModal, DealCardPresentation, DealCreatedEvent, DealDetailPresentation, DealEntity, DealListPresentation, DealLostEvent, DealLostPayloadModel, DealModel, DealMovedEvent, DealMovedPayloadModel, DealStatusEnum, DealStatusFilterEnum, DealWonEvent, DealWonPayloadModel, ListDealsContract, ListDealsInput, ListDealsInputModel, ListDealsOutput, ListDealsOutputModel, LoseDealContract, LoseDealInput, LoseDealInputModel, MOCK_COMPANIES, MOCK_CONTACTS, MOCK_DEALS, MOCK_STAGES, MockDeal, MockStage, MoveDealContract, MoveDealInput, MoveDealInputModel, PipelineEntity, PipelineKanbanPresentation, PipelineMetricsPresentation, Stage, StageEntity, TaskCompletedEvent, TaskEntity, TaskPriorityEnum, TaskStatusEnum, TaskTypeEnum, UseDealListOptions, UseDealMutationsOptions, WinDealContract, WinDealInput, WinDealInputModel, createCrmHandlers, crmDashboardMarkdownRenderer, crmDemoOverlay, crmOverlays, crmPipelineMarkdownRenderer, crmPipelineReactRenderer, crmPipelineSchemaContribution, crmSalesRepOverlay, example, mockCreateDealHandler, mockGetDealsByStageHandler, mockGetPipelineStagesHandler, mockListDealsHandler, mockLoseDealHandler, mockMoveDealHandler, mockWinDealHandler, schemaComposition, useDealList, useDealMutations };
47
18
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;cAsBa,iBAAA;WASZ,yBAAA,CAAA,wBAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAGA,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,iBAAiB,CAAC;AAChC,cAAc,MAAM,CAAC;AACrB,cAAc,wBAAwB,CAAC;AACvC,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,WAAW,CAAC;AAC/C,OAAO,QAAQ,CAAC;AAQhB;;GAEG;AACH,eAAO,MAAM,iBAAiB;;;;CAS7B,CAAC"}