@contractspec/example.integration-hub 0.0.0-canary-20260113170453

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 (116) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +156 -0
  3. package/dist/connection/connection.enum.d.ts +10 -0
  4. package/dist/connection/connection.enum.d.ts.map +1 -0
  5. package/dist/connection/connection.enum.js +17 -0
  6. package/dist/connection/connection.enum.js.map +1 -0
  7. package/dist/connection/connection.operation.d.ts +107 -0
  8. package/dist/connection/connection.operation.d.ts.map +1 -0
  9. package/dist/connection/connection.operation.js +63 -0
  10. package/dist/connection/connection.operation.js.map +1 -0
  11. package/dist/connection/connection.presentation.d.ts +8 -0
  12. package/dist/connection/connection.presentation.d.ts.map +1 -0
  13. package/dist/connection/connection.presentation.js +60 -0
  14. package/dist/connection/connection.presentation.js.map +1 -0
  15. package/dist/connection/connection.schema.d.ts +68 -0
  16. package/dist/connection/connection.schema.d.ts.map +1 -0
  17. package/dist/connection/connection.schema.js +76 -0
  18. package/dist/connection/connection.schema.js.map +1 -0
  19. package/dist/connection/index.d.ts +4 -0
  20. package/dist/connection/index.js +5 -0
  21. package/dist/docs/index.d.ts +1 -0
  22. package/dist/docs/index.js +1 -0
  23. package/dist/docs/integration-hub.docblock.d.ts +1 -0
  24. package/dist/docs/integration-hub.docblock.js +115 -0
  25. package/dist/docs/integration-hub.docblock.js.map +1 -0
  26. package/dist/events.d.ts +153 -0
  27. package/dist/events.d.ts.map +1 -0
  28. package/dist/events.js +289 -0
  29. package/dist/events.js.map +1 -0
  30. package/dist/example.d.ts +7 -0
  31. package/dist/example.d.ts.map +1 -0
  32. package/dist/example.js +58 -0
  33. package/dist/example.js.map +1 -0
  34. package/dist/handlers/index.d.ts +2 -0
  35. package/dist/handlers/index.js +3 -0
  36. package/dist/handlers/integration.handlers.d.ts +130 -0
  37. package/dist/handlers/integration.handlers.d.ts.map +1 -0
  38. package/dist/handlers/integration.handlers.js +282 -0
  39. package/dist/handlers/integration.handlers.js.map +1 -0
  40. package/dist/index.d.ts +19 -0
  41. package/dist/index.js +20 -0
  42. package/dist/integration/index.d.ts +4 -0
  43. package/dist/integration/index.js +5 -0
  44. package/dist/integration/integration.enum.d.ts +10 -0
  45. package/dist/integration/integration.enum.d.ts.map +1 -0
  46. package/dist/integration/integration.enum.js +17 -0
  47. package/dist/integration/integration.enum.js.map +1 -0
  48. package/dist/integration/integration.operations.d.ts +99 -0
  49. package/dist/integration/integration.operations.d.ts.map +1 -0
  50. package/dist/integration/integration.operations.js +57 -0
  51. package/dist/integration/integration.operations.js.map +1 -0
  52. package/dist/integration/integration.presentation.d.ts +9 -0
  53. package/dist/integration/integration.presentation.d.ts.map +1 -0
  54. package/dist/integration/integration.presentation.js +77 -0
  55. package/dist/integration/integration.presentation.js.map +1 -0
  56. package/dist/integration/integration.schema.d.ts +68 -0
  57. package/dist/integration/integration.schema.d.ts.map +1 -0
  58. package/dist/integration/integration.schema.js +76 -0
  59. package/dist/integration/integration.schema.js.map +1 -0
  60. package/dist/integration-hub.capability.d.ts +9 -0
  61. package/dist/integration-hub.capability.d.ts.map +1 -0
  62. package/dist/integration-hub.capability.js +38 -0
  63. package/dist/integration-hub.capability.js.map +1 -0
  64. package/dist/integration-hub.feature.d.ts +7 -0
  65. package/dist/integration-hub.feature.d.ts.map +1 -0
  66. package/dist/integration-hub.feature.js +244 -0
  67. package/dist/integration-hub.feature.js.map +1 -0
  68. package/dist/seeders/index.d.ts +10 -0
  69. package/dist/seeders/index.d.ts.map +1 -0
  70. package/dist/seeders/index.js +19 -0
  71. package/dist/seeders/index.js.map +1 -0
  72. package/dist/sync/index.d.ts +4 -0
  73. package/dist/sync/index.js +5 -0
  74. package/dist/sync/sync.enum.d.ts +18 -0
  75. package/dist/sync/sync.enum.d.ts.map +1 -0
  76. package/dist/sync/sync.enum.js +35 -0
  77. package/dist/sync/sync.enum.js.map +1 -0
  78. package/dist/sync/sync.operations.d.ts +509 -0
  79. package/dist/sync/sync.operations.d.ts.map +1 -0
  80. package/dist/sync/sync.operations.js +203 -0
  81. package/dist/sync/sync.operations.js.map +1 -0
  82. package/dist/sync/sync.presentation.d.ts +12 -0
  83. package/dist/sync/sync.presentation.d.ts.map +1 -0
  84. package/dist/sync/sync.presentation.js +168 -0
  85. package/dist/sync/sync.presentation.js.map +1 -0
  86. package/dist/sync/sync.schema.d.ts +356 -0
  87. package/dist/sync/sync.schema.d.ts.map +1 -0
  88. package/dist/sync/sync.schema.js +304 -0
  89. package/dist/sync/sync.schema.js.map +1 -0
  90. package/dist/sync-engine/index.d.ts +109 -0
  91. package/dist/sync-engine/index.d.ts.map +1 -0
  92. package/dist/sync-engine/index.js +148 -0
  93. package/dist/sync-engine/index.js.map +1 -0
  94. package/dist/tests/operations.test-spec.d.ts +9 -0
  95. package/dist/tests/operations.test-spec.d.ts.map +1 -0
  96. package/dist/tests/operations.test-spec.js +94 -0
  97. package/dist/tests/operations.test-spec.js.map +1 -0
  98. package/dist/ui/IntegrationDashboard.d.ts +7 -0
  99. package/dist/ui/IntegrationDashboard.d.ts.map +1 -0
  100. package/dist/ui/IntegrationDashboard.js +266 -0
  101. package/dist/ui/IntegrationDashboard.js.map +1 -0
  102. package/dist/ui/hooks/index.d.ts +2 -0
  103. package/dist/ui/hooks/index.js +5 -0
  104. package/dist/ui/hooks/useIntegrationData.d.ts +23 -0
  105. package/dist/ui/hooks/useIntegrationData.d.ts.map +1 -0
  106. package/dist/ui/hooks/useIntegrationData.js +59 -0
  107. package/dist/ui/hooks/useIntegrationData.js.map +1 -0
  108. package/dist/ui/index.d.ts +6 -0
  109. package/dist/ui/index.js +6 -0
  110. package/dist/ui/renderers/index.d.ts +2 -0
  111. package/dist/ui/renderers/index.js +3 -0
  112. package/dist/ui/renderers/integration.markdown.d.ts +28 -0
  113. package/dist/ui/renderers/integration.markdown.d.ts.map +1 -0
  114. package/dist/ui/renderers/integration.markdown.js +256 -0
  115. package/dist/ui/renderers/integration.markdown.js.map +1 -0
  116. package/package.json +111 -0
@@ -0,0 +1,203 @@
1
+ import { AddFieldMappingInputModel, CreateSyncConfigInputModel, FieldMappingModel, ListSyncRunsInputModel, ListSyncRunsOutputModel, SyncConfigModel, SyncRunModel, TriggerSyncInputModel } from "./sync.schema.js";
2
+ import { defineCommand, defineQuery } from "@contractspec/lib.contracts/operations";
3
+
4
+ //#region src/sync/sync.operations.ts
5
+ const OWNERS = ["@example.integration-hub"];
6
+ /**
7
+ * Create a sync configuration.
8
+ */
9
+ const CreateSyncConfigContract = defineCommand({
10
+ meta: {
11
+ key: "integration.syncConfig.create",
12
+ version: "1.0.0",
13
+ stability: "stable",
14
+ owners: [...OWNERS],
15
+ tags: [
16
+ "integration",
17
+ "sync",
18
+ "config",
19
+ "create"
20
+ ],
21
+ description: "Create a sync configuration.",
22
+ goal: "Define how data should be synchronized.",
23
+ context: "Sync setup."
24
+ },
25
+ io: {
26
+ input: CreateSyncConfigInputModel,
27
+ output: SyncConfigModel
28
+ },
29
+ policy: { auth: "user" },
30
+ sideEffects: {
31
+ emits: [{
32
+ key: "integration.syncConfig.created",
33
+ version: "1.0.0",
34
+ when: "Sync config created",
35
+ payload: SyncConfigModel
36
+ }],
37
+ audit: ["integration.syncConfig.created"]
38
+ },
39
+ acceptance: {
40
+ scenarios: [{
41
+ key: "create-sync-happy-path",
42
+ given: ["User is authenticated"],
43
+ when: ["User creates sync config"],
44
+ then: ["Sync config is created", "SyncConfigCreated event is emitted"]
45
+ }],
46
+ examples: [{
47
+ key: "create-contact-sync",
48
+ input: {
49
+ name: "Contacts Sync",
50
+ sourceConnectionId: "conn-1",
51
+ targetConnectionId: "conn-2"
52
+ },
53
+ output: {
54
+ id: "sync-123",
55
+ status: "active"
56
+ }
57
+ }]
58
+ }
59
+ });
60
+ /**
61
+ * Add a field mapping to a sync config.
62
+ */
63
+ const AddFieldMappingContract = defineCommand({
64
+ meta: {
65
+ key: "integration.fieldMapping.add",
66
+ version: "1.0.0",
67
+ stability: "stable",
68
+ owners: [...OWNERS],
69
+ tags: [
70
+ "integration",
71
+ "mapping",
72
+ "field"
73
+ ],
74
+ description: "Add a field mapping to a sync config.",
75
+ goal: "Map fields between systems.",
76
+ context: "Mapping configuration."
77
+ },
78
+ io: {
79
+ input: AddFieldMappingInputModel,
80
+ output: FieldMappingModel
81
+ },
82
+ policy: { auth: "user" },
83
+ sideEffects: { emits: [{
84
+ key: "integration.fieldMapping.added",
85
+ version: "1.0.0",
86
+ when: "Mapping added",
87
+ payload: FieldMappingModel
88
+ }] },
89
+ acceptance: {
90
+ scenarios: [{
91
+ key: "add-mapping-happy-path",
92
+ given: ["Sync config exists"],
93
+ when: ["User adds field mapping"],
94
+ then: ["Mapping is added", "FieldMappingAdded event is emitted"]
95
+ }],
96
+ examples: [{
97
+ key: "map-email",
98
+ input: {
99
+ syncConfigId: "sync-123",
100
+ sourceField: "email",
101
+ targetField: "user_email"
102
+ },
103
+ output: {
104
+ id: "map-456",
105
+ type: "string"
106
+ }
107
+ }]
108
+ }
109
+ });
110
+ /**
111
+ * Trigger a manual sync.
112
+ */
113
+ const TriggerSyncContract = defineCommand({
114
+ meta: {
115
+ key: "integration.sync.trigger",
116
+ version: "1.0.0",
117
+ stability: "stable",
118
+ owners: [...OWNERS],
119
+ tags: [
120
+ "integration",
121
+ "sync",
122
+ "trigger"
123
+ ],
124
+ description: "Trigger a manual sync.",
125
+ goal: "Start data synchronization.",
126
+ context: "Manual sync or webhook trigger."
127
+ },
128
+ io: {
129
+ input: TriggerSyncInputModel,
130
+ output: SyncRunModel
131
+ },
132
+ policy: { auth: "user" },
133
+ sideEffects: {
134
+ emits: [{
135
+ key: "integration.sync.started",
136
+ version: "1.0.0",
137
+ when: "Sync starts",
138
+ payload: SyncRunModel
139
+ }],
140
+ audit: ["integration.sync.triggered"]
141
+ },
142
+ acceptance: {
143
+ scenarios: [{
144
+ key: "trigger-sync-happy-path",
145
+ given: ["Sync config exists"],
146
+ when: ["User triggers sync"],
147
+ then: ["Sync run starts", "SyncStarted event is emitted"]
148
+ }],
149
+ examples: [{
150
+ key: "manual-trigger",
151
+ input: { syncConfigId: "sync-123" },
152
+ output: {
153
+ id: "run-789",
154
+ status: "pending"
155
+ }
156
+ }]
157
+ }
158
+ });
159
+ /**
160
+ * List sync run history.
161
+ */
162
+ const ListSyncRunsContract = defineQuery({
163
+ meta: {
164
+ key: "integration.syncRun.list",
165
+ version: "1.0.0",
166
+ stability: "stable",
167
+ owners: [...OWNERS],
168
+ tags: [
169
+ "integration",
170
+ "sync",
171
+ "run",
172
+ "list"
173
+ ],
174
+ description: "List sync run history.",
175
+ goal: "View sync history and status.",
176
+ context: "Sync monitoring."
177
+ },
178
+ io: {
179
+ input: ListSyncRunsInputModel,
180
+ output: ListSyncRunsOutputModel
181
+ },
182
+ policy: { auth: "user" },
183
+ acceptance: {
184
+ scenarios: [{
185
+ key: "list-runs-happy-path",
186
+ given: ["User has access to syncs"],
187
+ when: ["User lists sync runs"],
188
+ then: ["List of runs is returned"]
189
+ }],
190
+ examples: [{
191
+ key: "list-recent",
192
+ input: { limit: 10 },
193
+ output: {
194
+ items: [],
195
+ total: 50
196
+ }
197
+ }]
198
+ }
199
+ });
200
+
201
+ //#endregion
202
+ export { AddFieldMappingContract, CreateSyncConfigContract, ListSyncRunsContract, TriggerSyncContract };
203
+ //# sourceMappingURL=sync.operations.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sync.operations.js","names":[],"sources":["../../src/sync/sync.operations.ts"],"sourcesContent":["import {\n defineCommand,\n defineQuery,\n} from '@contractspec/lib.contracts/operations';\nimport {\n SyncConfigModel,\n SyncRunModel,\n FieldMappingModel,\n CreateSyncConfigInputModel,\n AddFieldMappingInputModel,\n TriggerSyncInputModel,\n ListSyncRunsInputModel,\n ListSyncRunsOutputModel,\n} from './sync.schema';\n\nconst OWNERS = ['@example.integration-hub'] as const;\n\n/**\n * Create a sync configuration.\n */\nexport const CreateSyncConfigContract = defineCommand({\n meta: {\n key: 'integration.syncConfig.create',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['integration', 'sync', 'config', 'create'],\n description: 'Create a sync configuration.',\n goal: 'Define how data should be synchronized.',\n context: 'Sync setup.',\n },\n io: { input: CreateSyncConfigInputModel, output: SyncConfigModel },\n policy: { auth: 'user' },\n sideEffects: {\n emits: [\n {\n key: 'integration.syncConfig.created',\n version: '1.0.0',\n when: 'Sync config created',\n payload: SyncConfigModel,\n },\n ],\n audit: ['integration.syncConfig.created'],\n },\n acceptance: {\n scenarios: [\n {\n key: 'create-sync-happy-path',\n given: ['User is authenticated'],\n when: ['User creates sync config'],\n then: ['Sync config is created', 'SyncConfigCreated event is emitted'],\n },\n ],\n examples: [\n {\n key: 'create-contact-sync',\n input: {\n name: 'Contacts Sync',\n sourceConnectionId: 'conn-1',\n targetConnectionId: 'conn-2',\n },\n output: { id: 'sync-123', status: 'active' },\n },\n ],\n },\n});\n\n/**\n * Add a field mapping to a sync config.\n */\nexport const AddFieldMappingContract = defineCommand({\n meta: {\n key: 'integration.fieldMapping.add',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['integration', 'mapping', 'field'],\n description: 'Add a field mapping to a sync config.',\n goal: 'Map fields between systems.',\n context: 'Mapping configuration.',\n },\n io: { input: AddFieldMappingInputModel, output: FieldMappingModel },\n policy: { auth: 'user' },\n sideEffects: {\n emits: [\n {\n key: 'integration.fieldMapping.added',\n version: '1.0.0',\n when: 'Mapping added',\n payload: FieldMappingModel,\n },\n ],\n },\n acceptance: {\n scenarios: [\n {\n key: 'add-mapping-happy-path',\n given: ['Sync config exists'],\n when: ['User adds field mapping'],\n then: ['Mapping is added', 'FieldMappingAdded event is emitted'],\n },\n ],\n examples: [\n {\n key: 'map-email',\n input: {\n syncConfigId: 'sync-123',\n sourceField: 'email',\n targetField: 'user_email',\n },\n output: { id: 'map-456', type: 'string' },\n },\n ],\n },\n});\n\n/**\n * Trigger a manual sync.\n */\nexport const TriggerSyncContract = defineCommand({\n meta: {\n key: 'integration.sync.trigger',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['integration', 'sync', 'trigger'],\n description: 'Trigger a manual sync.',\n goal: 'Start data synchronization.',\n context: 'Manual sync or webhook trigger.',\n },\n io: { input: TriggerSyncInputModel, output: SyncRunModel },\n policy: { auth: 'user' },\n sideEffects: {\n emits: [\n {\n key: 'integration.sync.started',\n version: '1.0.0',\n when: 'Sync starts',\n payload: SyncRunModel,\n },\n ],\n audit: ['integration.sync.triggered'],\n },\n acceptance: {\n scenarios: [\n {\n key: 'trigger-sync-happy-path',\n given: ['Sync config exists'],\n when: ['User triggers sync'],\n then: ['Sync run starts', 'SyncStarted event is emitted'],\n },\n ],\n examples: [\n {\n key: 'manual-trigger',\n input: { syncConfigId: 'sync-123' },\n output: { id: 'run-789', status: 'pending' },\n },\n ],\n },\n});\n\n/**\n * List sync run history.\n */\nexport const ListSyncRunsContract = defineQuery({\n meta: {\n key: 'integration.syncRun.list',\n version: '1.0.0',\n stability: 'stable',\n owners: [...OWNERS],\n tags: ['integration', 'sync', 'run', 'list'],\n description: 'List sync run history.',\n goal: 'View sync history and status.',\n context: 'Sync monitoring.',\n },\n io: { input: ListSyncRunsInputModel, output: ListSyncRunsOutputModel },\n policy: { auth: 'user' },\n acceptance: {\n scenarios: [\n {\n key: 'list-runs-happy-path',\n given: ['User has access to syncs'],\n when: ['User lists sync runs'],\n then: ['List of runs is returned'],\n },\n ],\n examples: [\n {\n key: 'list-recent',\n input: { limit: 10 },\n output: { items: [], total: 50 },\n },\n ],\n },\n});\n"],"mappings":";;;;AAeA,MAAM,SAAS,CAAC,2BAA2B;;;;AAK3C,MAAa,2BAA2B,cAAc;CACpD,MAAM;EACJ,KAAK;EACL,SAAS;EACT,WAAW;EACX,QAAQ,CAAC,GAAG,OAAO;EACnB,MAAM;GAAC;GAAe;GAAQ;GAAU;GAAS;EACjD,aAAa;EACb,MAAM;EACN,SAAS;EACV;CACD,IAAI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AAU;EACxC,aAAa;EACb,MAAM;EACN,SAAS;EACV;CACD,IAAI;EAAE,OAAO;EAAuB,QAAQ;EAAc;CAC1D,QAAQ,EAAE,MAAM,QAAQ;CACxB,aAAa;EACX,OAAO,CACL;GACE,KAAK;GACL,SAAS;GACT,MAAM;GACN,SAAS;GACV,CACF;EACD,OAAO,CAAC,6BAA6B;EACtC;CACD,YAAY;EACV,WAAW,CACT;GACE,KAAK;GACL,OAAO,CAAC,qBAAqB;GAC7B,MAAM,CAAC,qBAAqB;GAC5B,MAAM,CAAC,mBAAmB,+BAA+B;GAC1D,CACF;EACD,UAAU,CACR;GACE,KAAK;GACL,OAAO,EAAE,cAAc,YAAY;GACnC,QAAQ;IAAE,IAAI;IAAW,QAAQ;IAAW;GAC7C,CACF;EACF;CACF,CAAC;;;;AAKF,MAAa,uBAAuB,YAAY;CAC9C,MAAM;EACJ,KAAK;EACL,SAAS;EACT,WAAW;EACX,QAAQ,CAAC,GAAG,OAAO;EACnB,MAAM;GAAC;GAAe;GAAQ;GAAO;GAAO;EAC5C,aAAa;EACb,MAAM;EACN,SAAS;EACV;CACD,IAAI;EAAE,OAAO;EAAwB,QAAQ;EAAyB;CACtE,QAAQ,EAAE,MAAM,QAAQ;CACxB,YAAY;EACV,WAAW,CACT;GACE,KAAK;GACL,OAAO,CAAC,2BAA2B;GACnC,MAAM,CAAC,uBAAuB;GAC9B,MAAM,CAAC,2BAA2B;GACnC,CACF;EACD,UAAU,CACR;GACE,KAAK;GACL,OAAO,EAAE,OAAO,IAAI;GACpB,QAAQ;IAAE,OAAO,EAAE;IAAE,OAAO;IAAI;GACjC,CACF;EACF;CACF,CAAC"}
@@ -0,0 +1,12 @@
1
+ import * as _contractspec_lib_contracts20 from "@contractspec/lib.contracts";
2
+
3
+ //#region src/sync/sync.presentation.d.ts
4
+ declare const SyncConfigListPresentation: _contractspec_lib_contracts20.PresentationSpec;
5
+ declare const SyncConfigEditorPresentation: _contractspec_lib_contracts20.PresentationSpec;
6
+ declare const FieldMappingEditorPresentation: _contractspec_lib_contracts20.PresentationSpec;
7
+ declare const SyncRunListPresentation: _contractspec_lib_contracts20.PresentationSpec;
8
+ declare const SyncRunDetailPresentation: _contractspec_lib_contracts20.PresentationSpec;
9
+ declare const SyncActivityPresentation: _contractspec_lib_contracts20.PresentationSpec;
10
+ //#endregion
11
+ export { FieldMappingEditorPresentation, SyncActivityPresentation, SyncConfigEditorPresentation, SyncConfigListPresentation, SyncRunDetailPresentation, SyncRunListPresentation };
12
+ //# sourceMappingURL=sync.presentation.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sync.presentation.d.ts","names":[],"sources":["../../src/sync/sync.presentation.ts"],"sourcesContent":[],"mappings":";;;cAOa,4BAuBX,6BAAA,CAvBqC;cAyB1B,8BAuBX,6BAAA,CAvBuC;cAyB5B,gCAuBX,6BAAA,CAvByC;AAlD9B,cA2EA,uBApDX,EA2EA,6BAAA,CAvBkC,gBApDlC;AAEW,cA2EA,yBApDX,EA2EA,6BAAA,CAvBoC,gBApDpC;AAEW,cA2EA,wBApDX,EA0EA,6BAAA,CAtBmC,gBApDnC"}
@@ -0,0 +1,168 @@
1
+ import { FieldMappingModel, SyncConfigModel, SyncRunModel } from "./sync.schema.js";
2
+ import { StabilityEnum, definePresentation } from "@contractspec/lib.contracts";
3
+
4
+ //#region src/sync/sync.presentation.ts
5
+ const SyncConfigListPresentation = definePresentation({
6
+ meta: {
7
+ key: "integration.syncConfig.list",
8
+ version: "1.0.0",
9
+ title: "Sync Config List",
10
+ description: "List of sync configurations",
11
+ domain: "integration",
12
+ owners: ["@integration-team"],
13
+ tags: [
14
+ "integration",
15
+ "sync",
16
+ "config",
17
+ "list"
18
+ ],
19
+ stability: StabilityEnum.Experimental,
20
+ goal: "Show users their current sync configurations.",
21
+ context: "Management view for data synchronization."
22
+ },
23
+ source: {
24
+ type: "component",
25
+ framework: "react",
26
+ componentKey: "SyncConfigList",
27
+ props: SyncConfigModel
28
+ },
29
+ targets: ["react", "markdown"],
30
+ policy: { flags: ["integration.sync.enabled"] }
31
+ });
32
+ const SyncConfigEditorPresentation = definePresentation({
33
+ meta: {
34
+ key: "integration.syncConfig.editor",
35
+ version: "1.0.0",
36
+ title: "Sync Config Editor",
37
+ description: "Editor for sync configuration settings",
38
+ domain: "integration",
39
+ owners: ["@integration-team"],
40
+ tags: [
41
+ "integration",
42
+ "sync",
43
+ "config",
44
+ "editor"
45
+ ],
46
+ stability: StabilityEnum.Experimental,
47
+ goal: "Allow users to configure schedule, filters, and settings for a sync.",
48
+ context: "Configuration interface for sync jobs."
49
+ },
50
+ source: {
51
+ type: "component",
52
+ framework: "react",
53
+ componentKey: "SyncConfigEditor",
54
+ props: SyncConfigModel
55
+ },
56
+ targets: ["react"],
57
+ policy: { flags: ["integration.sync.enabled"] }
58
+ });
59
+ const FieldMappingEditorPresentation = definePresentation({
60
+ meta: {
61
+ key: "integration.fieldMapping.editor",
62
+ version: "1.0.0",
63
+ title: "Field Mapping Editor",
64
+ description: "Visual field mapping editor",
65
+ domain: "integration",
66
+ owners: ["@integration-team"],
67
+ tags: [
68
+ "integration",
69
+ "field-mapping",
70
+ "editor"
71
+ ],
72
+ stability: StabilityEnum.Experimental,
73
+ goal: "Allow users to map source fields to target fields visually.",
74
+ context: "Schema mapping tool for data consistency."
75
+ },
76
+ source: {
77
+ type: "component",
78
+ framework: "react",
79
+ componentKey: "FieldMappingEditor",
80
+ props: FieldMappingModel
81
+ },
82
+ targets: ["react"],
83
+ policy: { flags: ["integration.sync.enabled"] }
84
+ });
85
+ const SyncRunListPresentation = definePresentation({
86
+ meta: {
87
+ key: "integration.syncRun.list",
88
+ version: "1.0.0",
89
+ title: "Sync Run History",
90
+ description: "History of sync runs",
91
+ domain: "integration",
92
+ owners: ["@integration-team"],
93
+ tags: [
94
+ "integration",
95
+ "sync",
96
+ "runs",
97
+ "history"
98
+ ],
99
+ stability: StabilityEnum.Experimental,
100
+ goal: "Provide a historical log of all sync attempts and their results.",
101
+ context: "Audit and troubleshooting view for sync jobs."
102
+ },
103
+ source: {
104
+ type: "component",
105
+ framework: "react",
106
+ componentKey: "SyncRunList",
107
+ props: SyncRunModel
108
+ },
109
+ targets: ["react", "markdown"],
110
+ policy: { flags: ["integration.sync.enabled"] }
111
+ });
112
+ const SyncRunDetailPresentation = definePresentation({
113
+ meta: {
114
+ key: "integration.syncRun.detail",
115
+ version: "1.0.0",
116
+ title: "Sync Run Details",
117
+ description: "Detailed view of a sync run with logs",
118
+ domain: "integration",
119
+ owners: ["@integration-team"],
120
+ tags: [
121
+ "integration",
122
+ "sync",
123
+ "run",
124
+ "detail"
125
+ ],
126
+ stability: StabilityEnum.Experimental,
127
+ goal: "Show granular details and logs for a specific sync run.",
128
+ context: "Detailed troubleshooting view."
129
+ },
130
+ source: {
131
+ type: "component",
132
+ framework: "react",
133
+ componentKey: "SyncRunDetail",
134
+ props: SyncRunModel
135
+ },
136
+ targets: ["react", "markdown"],
137
+ policy: { flags: ["integration.sync.enabled"] }
138
+ });
139
+ const SyncActivityPresentation = definePresentation({
140
+ meta: {
141
+ key: "integration.sync.activity",
142
+ version: "1.0.0",
143
+ title: "Sync Activity Monitor",
144
+ description: "Real-time sync activity monitor",
145
+ domain: "integration",
146
+ owners: ["@integration-team"],
147
+ tags: [
148
+ "integration",
149
+ "sync",
150
+ "activity",
151
+ "realtime"
152
+ ],
153
+ stability: StabilityEnum.Experimental,
154
+ goal: "Monitor live data flow and sync performance.",
155
+ context: "Real-time operations monitor."
156
+ },
157
+ source: {
158
+ type: "component",
159
+ framework: "react",
160
+ componentKey: "SyncActivity"
161
+ },
162
+ targets: ["react", "markdown"],
163
+ policy: { flags: ["integration.sync.enabled"] }
164
+ });
165
+
166
+ //#endregion
167
+ export { FieldMappingEditorPresentation, SyncActivityPresentation, SyncConfigEditorPresentation, SyncConfigListPresentation, SyncRunDetailPresentation, SyncRunListPresentation };
168
+ //# sourceMappingURL=sync.presentation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sync.presentation.js","names":[],"sources":["../../src/sync/sync.presentation.ts"],"sourcesContent":["import { definePresentation, StabilityEnum } from '@contractspec/lib.contracts';\nimport {\n SyncConfigModel,\n SyncRunModel,\n FieldMappingModel,\n} from './sync.schema';\n\nexport const SyncConfigListPresentation = definePresentation({\n meta: {\n key: 'integration.syncConfig.list',\n version: '1.0.0',\n title: 'Sync Config List',\n description: 'List of sync configurations',\n domain: 'integration',\n owners: ['@integration-team'],\n tags: ['integration', 'sync', 'config', 'list'],\n stability: StabilityEnum.Experimental,\n goal: 'Show users their current sync configurations.',\n context: 'Management view for data synchronization.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'SyncConfigList',\n props: SyncConfigModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['integration.sync.enabled'],\n },\n});\n\nexport const SyncConfigEditorPresentation = definePresentation({\n meta: {\n key: 'integration.syncConfig.editor',\n version: '1.0.0',\n title: 'Sync Config Editor',\n description: 'Editor for sync configuration settings',\n domain: 'integration',\n owners: ['@integration-team'],\n tags: ['integration', 'sync', 'config', 'editor'],\n stability: StabilityEnum.Experimental,\n goal: 'Allow users to configure schedule, filters, and settings for a sync.',\n context: 'Configuration interface for sync jobs.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'SyncConfigEditor',\n props: SyncConfigModel,\n },\n targets: ['react'],\n policy: {\n flags: ['integration.sync.enabled'],\n },\n});\n\nexport const FieldMappingEditorPresentation = definePresentation({\n meta: {\n key: 'integration.fieldMapping.editor',\n version: '1.0.0',\n title: 'Field Mapping Editor',\n description: 'Visual field mapping editor',\n domain: 'integration',\n owners: ['@integration-team'],\n tags: ['integration', 'field-mapping', 'editor'],\n stability: StabilityEnum.Experimental,\n goal: 'Allow users to map source fields to target fields visually.',\n context: 'Schema mapping tool for data consistency.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'FieldMappingEditor',\n props: FieldMappingModel,\n },\n targets: ['react'],\n policy: {\n flags: ['integration.sync.enabled'],\n },\n});\n\nexport const SyncRunListPresentation = definePresentation({\n meta: {\n key: 'integration.syncRun.list',\n version: '1.0.0',\n title: 'Sync Run History',\n description: 'History of sync runs',\n domain: 'integration',\n owners: ['@integration-team'],\n tags: ['integration', 'sync', 'runs', 'history'],\n stability: StabilityEnum.Experimental,\n goal: 'Provide a historical log of all sync attempts and their results.',\n context: 'Audit and troubleshooting view for sync jobs.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'SyncRunList',\n props: SyncRunModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['integration.sync.enabled'],\n },\n});\n\nexport const SyncRunDetailPresentation = definePresentation({\n meta: {\n key: 'integration.syncRun.detail',\n version: '1.0.0',\n title: 'Sync Run Details',\n description: 'Detailed view of a sync run with logs',\n domain: 'integration',\n owners: ['@integration-team'],\n tags: ['integration', 'sync', 'run', 'detail'],\n stability: StabilityEnum.Experimental,\n goal: 'Show granular details and logs for a specific sync run.',\n context: 'Detailed troubleshooting view.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'SyncRunDetail',\n props: SyncRunModel,\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['integration.sync.enabled'],\n },\n});\n\nexport const SyncActivityPresentation = definePresentation({\n meta: {\n key: 'integration.sync.activity',\n version: '1.0.0',\n title: 'Sync Activity Monitor',\n description: 'Real-time sync activity monitor',\n domain: 'integration',\n owners: ['@integration-team'],\n tags: ['integration', 'sync', 'activity', 'realtime'],\n stability: StabilityEnum.Experimental,\n goal: 'Monitor live data flow and sync performance.',\n context: 'Real-time operations monitor.',\n },\n source: {\n type: 'component',\n framework: 'react',\n componentKey: 'SyncActivity',\n },\n targets: ['react', 'markdown'],\n policy: {\n flags: ['integration.sync.enabled'],\n },\n});\n"],"mappings":";;;;AAOA,MAAa,6BAA6B,mBAAmB;CAC3D,MAAM;EACJ,KAAK;EACL,SAAS;EACT,OAAO;EACP,aAAa;EACb,QAAQ;EACR,QAAQ,CAAC,o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