@explorer02/cfm-survey-sdk 0.2.1 → 0.2.3

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 (95) hide show
  1. package/dist/cli/index.js +18 -18
  2. package/dist/cli/index.mjs +14 -14
  3. package/dist/index.d.mts +465 -580
  4. package/dist/index.d.ts +465 -580
  5. package/dist/index.js +1 -1
  6. package/dist/index.mjs +1 -1
  7. package/package.json +6 -4
  8. package/postinstall.js +96 -69
  9. package/templates/AGENT.md +18 -8
  10. package/templates/docs/00-integration/analytics-events-catalog.md +54 -0
  11. package/templates/docs/00-integration/answer-logic-and-navigation.md +50 -0
  12. package/templates/docs/00-integration/aws-deploy.md +281 -0
  13. package/templates/docs/00-integration/client-integration-guide.md +351 -0
  14. package/templates/docs/00-integration/component-checklist.md +55 -22
  15. package/templates/docs/00-integration/constraints.md +49 -4
  16. package/templates/docs/00-integration/custom-field-logic-and-navigation.md +174 -0
  17. package/templates/docs/00-integration/display-logic-and-navigation.md +64 -0
  18. package/templates/docs/00-integration/end-page-logic.md +64 -0
  19. package/templates/docs/00-integration/file-upload-aws.md +116 -0
  20. package/templates/docs/00-integration/logic-fields-catalog.md +105 -0
  21. package/templates/docs/00-integration/partial-save-and-recovery.md +98 -0
  22. package/templates/docs/00-integration/placeholders-and-tokens.md +116 -0
  23. package/templates/docs/00-integration/progress.md +61 -0
  24. package/templates/docs/00-integration/question-display-variants.md +65 -0
  25. package/templates/docs/00-integration/question-numbering.md +51 -0
  26. package/templates/docs/00-integration/question-type-sdk-matrix.md +244 -0
  27. package/templates/docs/00-integration/setup.md +84 -0
  28. package/templates/docs/00-integration/skip-logic-and-navigation.md +80 -0
  29. package/templates/docs/00-integration/survey-lifecycle-analytics.md +94 -0
  30. package/templates/docs/00-integration/useSurveySDK.md +151 -23
  31. package/templates/docs/01-components/01-survey-page.md +76 -54
  32. package/templates/docs/01-components/02-question.md +61 -58
  33. package/templates/docs/01-components/03-rating-scale.md +11 -1
  34. package/templates/docs/01-components/04-star-rating-scale.md +45 -0
  35. package/templates/docs/01-components/05-csat-matrix-scale.md +20 -11
  36. package/templates/docs/01-components/06-likert-matrix-scale.md +14 -4
  37. package/templates/docs/01-components/07-slider-matrix-scale.md +11 -2
  38. package/templates/docs/01-components/08-file-upload-scale.md +23 -51
  39. package/templates/docs/01-components/09-custom-slider-track.md +2 -2
  40. package/templates/docs/01-components/11-progress-bar.md +10 -4
  41. package/templates/docs/01-components/13-matrix-dropdown.md +29 -32
  42. package/templates/docs/01-components/14-intro-page.md +34 -0
  43. package/templates/docs/01-components/15-end-page.md +31 -0
  44. package/templates/docs/01-components/16-paused-page.md +27 -0
  45. package/templates/docs/01-components/17-heatmap-scale.md +75 -0
  46. package/templates/docs/01-components/18-rank-order-scale.md +93 -0
  47. package/templates/docs/01-components/README.md +42 -36
  48. package/templates/docs/02-reference/config-field-index.md +141 -139
  49. package/templates/docs/02-reference/exports.md +149 -0
  50. package/templates/docs/02-reference/question-types/01-rating.md +31 -32
  51. package/templates/docs/02-reference/question-types/04-csat.md +51 -42
  52. package/templates/docs/02-reference/question-types/05-rating-scale.md +16 -11
  53. package/templates/docs/02-reference/question-types/06-slider.md +2 -2
  54. package/templates/docs/02-reference/question-types/07-matrix-cfm.md +44 -30
  55. package/templates/docs/02-reference/question-types/08-matrix-csat.md +4 -26
  56. package/templates/docs/02-reference/question-types/09-matrix-rating.md +29 -13
  57. package/templates/docs/02-reference/question-types/10-slider-matrix.md +15 -4
  58. package/templates/docs/02-reference/question-types/11-file-upload.md +43 -17
  59. package/templates/docs/02-reference/question-types/12-heatmap.md +59 -0
  60. package/templates/docs/02-reference/question-types/13-rank-order.md +101 -0
  61. package/templates/docs/02-reference/question-types/README.md +96 -47
  62. package/templates/docs/02-reference/routing-table.md +33 -18
  63. package/templates/docs/02-reference/value-derivation.md +63 -0
  64. package/templates/docs/03-ui-specs/00-question-shell.md +19 -88
  65. package/templates/docs/03-ui-specs/01-rating.md +18 -52
  66. package/templates/docs/03-ui-specs/02-radio.md +80 -37
  67. package/templates/docs/03-ui-specs/03-text.md +2 -2
  68. package/templates/docs/03-ui-specs/04-csat.md +68 -33
  69. package/templates/docs/03-ui-specs/05-rating-scale.md +21 -18
  70. package/templates/docs/03-ui-specs/06-slider.md +3 -1
  71. package/templates/docs/03-ui-specs/07-matrix-cfm.md +44 -25
  72. package/templates/docs/03-ui-specs/08-matrix-csat-rating.md +19 -43
  73. package/templates/docs/03-ui-specs/09-slider-matrix.md +18 -1
  74. package/templates/docs/03-ui-specs/10-file-upload.md +42 -21
  75. package/templates/docs/03-ui-specs/11-text-and-media.md +29 -29
  76. package/templates/docs/03-ui-specs/12-survey-chrome.md +58 -14
  77. package/templates/docs/03-ui-specs/13-heatmap.md +80 -0
  78. package/templates/docs/03-ui-specs/14-rank-order.md +128 -0
  79. package/templates/docs/03-ui-specs/README.md +16 -14
  80. package/templates/docs/03-ui-specs/shared/custom-slider-track.md +28 -35
  81. package/templates/docs/03-ui-specs/shared/matrix-dropdown.md +5 -0
  82. package/templates/docs/MANIFEST.json +476 -69
  83. package/templates/docs/index.md +82 -30
  84. package/templates/docs/templates/CustomSliderTrack.tsx +144 -0
  85. package/templates/docs/templates/MatrixDropdown.tsx +216 -0
  86. package/templates/docs/templates/Question.tsx +221 -154
  87. package/templates/docs/templates/RankOrderScale.tsx +353 -0
  88. package/templates/docs/templates/deploy-to-aws.sh +114 -0
  89. package/templates/docs/templates/heatmapCoords.ts +58 -0
  90. package/templates/docs/templates/implementation_plan.md +126 -67
  91. package/templates/docs/templates/survey-inventory.schema.json +77 -0
  92. package/templates/docs/templates/surveyUiIcons.tsx +52 -0
  93. package/templates/docs/templates/verify-agent-build.sh +85 -0
  94. package/templates/docs/01-components/04-csat-scale.md +0 -40
  95. package/templates/docs/02-question-types/01-rating.md +0 -44
@@ -1,155 +1,562 @@
1
1
  {
2
- "version": "1.0.0",
2
+ "docsSchemaVersion": "2.4.0",
3
+ "sdkTypesVersion": "0.2.1",
3
4
  "packageNames": {
4
5
  "npm": "@explorer02/cfm-survey-sdk",
5
6
  "monorepo": "@repo/sdk"
6
7
  },
7
- "entryPoint": "index.md",
8
- "clientInputs": ["initialPrompt", "instanceIdJwt", "deployConfirmation"],
8
+ "entryPoints": {
9
+ "index": "index.md",
10
+ "agentMonorepo": "../AGENT.md",
11
+ "agentNpm": "node_modules/@explorer02/cfm-survey-sdk/templates/AGENT.md"
12
+ },
13
+ "clientInputs": [
14
+ "initialPrompt",
15
+ "instanceIdJwt",
16
+ "deployConfirmation"
17
+ ],
18
+ "hookContract": {
19
+ "answersField": "state.answers",
20
+ "customFieldValuesField": "options.customFieldValues",
21
+ "changePayload": {
22
+ "questionId": "string",
23
+ "answerValue": "AnswerValue"
24
+ },
25
+ "stableRefs": [
26
+ "placeholders",
27
+ "customFieldValues",
28
+ "surveyOptions useMemo"
29
+ ],
30
+ "lifecycleActions": [
31
+ "SCROLL",
32
+ "RECORD_QUESTION_VIEW"
33
+ ],
34
+ "visibilityHelpers": {
35
+ "getVisibleMcqOptionsForAnswers": "4th arg customFieldValues optional",
36
+ "getVisibleRankOrderOptionsForAnswers": "4th arg customFieldValues optional",
37
+ "getVisibleMatrixItemsForAnswers": "4th arg customFieldValues optional",
38
+ "getVisibleStatementRowsForAnswers": "4th arg customFieldValues optional",
39
+ "getVisibleScaleColumnsForAnswers": "4th arg customFieldValues optional"
40
+ },
41
+ "forbiddenImports": [
42
+ "@explorer02/cfm-survey-sdk/src/**",
43
+ "@repo/sdk/src/**"
44
+ ]
45
+ },
46
+ "integrationDocs": [
47
+ {
48
+ "path": "00-integration/client-integration-guide.md",
49
+ "purpose": "Master wiring map — start here for full client integration"
50
+ },
51
+ {
52
+ "path": "00-integration/useSurveySDK.md",
53
+ "purpose": "Hook signature, actions, validation, lifecycle, partial save"
54
+ },
55
+ {
56
+ "path": "00-integration/skip-logic-and-navigation.md",
57
+ "purpose": "Skip logic behavior and client nav responsibilities"
58
+ },
59
+ {
60
+ "path": "00-integration/display-logic-and-navigation.md",
61
+ "purpose": "Question-level display logic and currentQuestions"
62
+ },
63
+ {
64
+ "path": "00-integration/answer-logic-and-navigation.md",
65
+ "purpose": "Option/row/column answer logic and visibility helpers"
66
+ },
67
+ {
68
+ "path": "00-integration/custom-field-logic-and-navigation.md",
69
+ "purpose": "CRM custom fields in logic rules — two wiring points"
70
+ },
71
+ {
72
+ "path": "00-integration/question-display-variants.md",
73
+ "purpose": "Conditional question text variants — SDK resolves questionText on currentQuestions"
74
+ },
75
+ {
76
+ "path": "00-integration/question-numbering.md",
77
+ "purpose": "Active-path question ordinals on currentQuestions.questionNumber"
78
+ },
79
+ {
80
+ "path": "00-integration/end-page-logic.md",
81
+ "purpose": "Multiple end pages — display-logic selection at submit"
82
+ },
83
+ {
84
+ "path": "00-integration/progress.md",
85
+ "purpose": "Progress bar formula and active-path credits"
86
+ },
87
+ {
88
+ "path": "00-integration/constraints.md",
89
+ "purpose": "Non-negotiable rules and troubleshooting"
90
+ },
91
+ {
92
+ "path": "00-integration/aws-deploy.md",
93
+ "purpose": "Deploy static survey UI to AWS via EC2 middle API (S3 + CloudFront)"
94
+ },
95
+ {
96
+ "path": "00-integration/question-type-sdk-matrix.md",
97
+ "purpose": "Master 11-type SDK integration matrix"
98
+ },
99
+ {
100
+ "path": "00-integration/placeholders-and-tokens.md",
101
+ "purpose": "Placeholder token resolution"
102
+ },
103
+ {
104
+ "path": "00-integration/partial-save-and-recovery.md",
105
+ "purpose": "Debounced partial save wiring"
106
+ },
107
+ {
108
+ "path": "00-integration/survey-lifecycle-analytics.md",
109
+ "purpose": "Mark-as-started and question activity"
110
+ },
111
+ {
112
+ "path": "00-integration/logic-fields-catalog.md",
113
+ "purpose": "Logic field reference by question type for skip/display/answer/end"
114
+ },
115
+ {
116
+ "path": "00-integration/analytics-events-catalog.md",
117
+ "purpose": "Consolidated SDK analytics and client lifecycle events"
118
+ },
119
+ {
120
+ "path": "00-integration/file-upload-aws.md",
121
+ "purpose": "Presigned S3 upload flow for FILE_UPLOAD submit contract"
122
+ }
123
+ ],
124
+ "templateScaleFiles": [
125
+ "templates/RankOrderScale.tsx",
126
+ "templates/MatrixDropdown.tsx",
127
+ "templates/CustomSliderTrack.tsx",
128
+ "templates/surveyUiIcons.tsx",
129
+ "templates/heatmapCoords.ts"
130
+ ],
131
+ "deployTargets": {
132
+ "aws": {
133
+ "doc": "00-integration/aws-deploy.md",
134
+ "script": "templates/deploy-to-aws.sh",
135
+ "apiBaseEnv": "CFM_DEPLOY_API_BASE",
136
+ "apiBaseDefault": "http://43.204.26.213:3000",
137
+ "instanceIdEnv": "CFM_INSTANCE_ID",
138
+ "outDirEnv": "OUT_DIR",
139
+ "healthPath": "/health",
140
+ "startPath": "/deploy/start",
141
+ "completePath": "/deploy/complete",
142
+ "maxFiles": 500,
143
+ "staticOutputDir": "out",
144
+ "frameworkStaticExport": {
145
+ "nextjs": {
146
+ "output": "export",
147
+ "assetPrefix": "./",
148
+ "imagesUnoptimized": true,
149
+ "postBuildCopy": ["index.txt", "index.html.txt"]
150
+ }
151
+ }
152
+ },
153
+ "vercel": {
154
+ "doc": "00-integration/setup.md",
155
+ "command": "npx cfm-sdk deploy",
156
+ "prerequisites": ["npm run build passes", "VERCEL_TOKEN or Vercel CLI"]
157
+ }
158
+ },
159
+ "sdkFeatures": {
160
+ "customFieldLogic": true,
161
+ "skipLogic": true,
162
+ "displayLogic": true,
163
+ "answerLogic": true,
164
+ "partialSave": true,
165
+ "markAsStarted": true,
166
+ "questionActivity": true,
167
+ "progressBar": true,
168
+ "placeholderResolution": true,
169
+ "visibilityHelpers": true,
170
+ "questionDisplayVariants": true,
171
+ "questionNumbering": true,
172
+ "endPageLogic": true
173
+ },
174
+ "typeLiterals": [
175
+ "MCQ",
176
+ "TEXTFIELD",
177
+ "NPS_SCALE",
178
+ "CFM_MATRIX",
179
+ "CSAT_MATRIX",
180
+ "RATING_MATRIX",
181
+ "SLIDER_MATRIX",
182
+ "FILE_UPLOAD",
183
+ "TEXT_AND_MEDIA",
184
+ "HEATMAP",
185
+ "RANK_ORDER"
186
+ ],
9
187
  "phases": [
10
188
  {
11
189
  "id": 0,
12
190
  "name": "orient",
13
- "read": ["index.md", "../AGENT.md"],
14
- "actions": ["detectFramework", "extractBrandingFromClientPrompt"]
191
+ "read": [
192
+ "index.md",
193
+ "../AGENT.md"
194
+ ],
195
+ "actions": [
196
+ "detectFramework",
197
+ "extractBrandingFromClientPrompt"
198
+ ]
15
199
  },
16
200
  {
17
201
  "id": 1,
18
202
  "name": "scaffold",
19
- "read": ["00-integration/setup.md"],
20
- "frameworks": ["nextjs", "vite", "cra"]
203
+ "read": [
204
+ "00-integration/setup.md"
205
+ ],
206
+ "frameworks": [
207
+ "nextjs",
208
+ "vite",
209
+ "cra"
210
+ ]
21
211
  },
22
212
  {
23
213
  "id": 2,
24
214
  "name": "instanceId",
25
- "read": ["00-integration/useSurveySDK.md"]
215
+ "read": [
216
+ "00-integration/useSurveySDK.md"
217
+ ]
26
218
  },
27
219
  {
28
220
  "id": 3,
29
221
  "name": "sdkContract",
30
- "read": ["00-integration/useSurveySDK.md"]
222
+ "read": [
223
+ "00-integration/client-integration-guide.md",
224
+ "00-integration/useSurveySDK.md",
225
+ "00-integration/question-type-sdk-matrix.md",
226
+ "02-reference/exports.md",
227
+ "02-reference/value-derivation.md",
228
+ "00-integration/skip-logic-and-navigation.md",
229
+ "00-integration/display-logic-and-navigation.md",
230
+ "00-integration/answer-logic-and-navigation.md",
231
+ "00-integration/custom-field-logic-and-navigation.md",
232
+ "00-integration/question-display-variants.md",
233
+ "00-integration/question-numbering.md",
234
+ "00-integration/placeholders-and-tokens.md",
235
+ "00-integration/partial-save-and-recovery.md",
236
+ "00-integration/survey-lifecycle-analytics.md",
237
+ "00-integration/end-page-logic.md",
238
+ "00-integration/progress.md",
239
+ "00-integration/logic-fields-catalog.md",
240
+ "00-integration/analytics-events-catalog.md"
241
+ ]
31
242
  },
32
243
  {
33
244
  "id": 4,
34
245
  "name": "planAndIngest",
35
- "read": [
246
+ "readAlways": [
36
247
  "00-integration/component-checklist.md",
37
- "03-ui-specs/README.md",
38
- "01-components/README.md",
248
+ "00-integration/question-type-sdk-matrix.md",
249
+ "00-integration/logic-fields-catalog.md",
250
+ "03-ui-specs/00-question-shell.md",
251
+ "03-ui-specs/12-survey-chrome.md",
39
252
  "01-components/01-survey-page.md",
40
253
  "01-components/02-question.md",
41
- "01-components/03-rating-scale.md",
42
- "01-components/04-csat-scale.md",
43
- "01-components/05-csat-matrix-scale.md",
44
- "01-components/06-likert-matrix-scale.md",
45
- "01-components/07-slider-matrix-scale.md",
46
- "01-components/08-file-upload-scale.md",
47
- "01-components/09-custom-slider-track.md",
48
- "01-components/10-header-footer.md",
49
- "01-components/11-progress-bar.md",
50
- "01-components/12-language-selector.md",
51
- "01-components/13-matrix-dropdown.md"
254
+ "01-components/14-intro-page.md",
255
+ "01-components/15-end-page.md",
256
+ "01-components/16-paused-page.md"
52
257
  ],
258
+ "readPerType": "questionTypes.{type}.blueprint + questionTypes.{type}.reference + questionTypes.{type}.uiSpec",
259
+ "readSharedWhen": "sharedUiSpecTriggers",
53
260
  "template": "templates/implementation_plan.md",
261
+ "inventorySchema": "templates/survey-inventory.schema.json",
54
262
  "questionDispatcher": "templates/Question.tsx",
55
263
  "output": "implementation_plan.md"
56
264
  },
57
265
  {
58
266
  "id": 5,
59
267
  "name": "build",
60
- "read": ["00-integration/constraints.md", "02-reference/routing-table.md"],
268
+ "read": [
269
+ "00-integration/constraints.md",
270
+ "02-reference/routing-table.md"
271
+ ],
61
272
  "onDemand": "02-reference/question-types"
62
273
  },
63
274
  {
64
275
  "id": 6,
65
276
  "name": "verify",
66
- "read": ["00-integration/constraints.md"],
277
+ "read": [
278
+ "00-integration/constraints.md"
279
+ ],
280
+ "script": "templates/verify-agent-build.sh",
67
281
  "checklist": [
68
- "questionDispatcherCoversAll12Types",
69
- "matrixRoutesBySubType",
282
+ "questionDispatcherCoversAll11Types",
283
+ "flatTypeRoutingNoSubType",
70
284
  "noStubPlaceholderText",
71
285
  "everyQuestionWrapperHasId",
72
286
  "noInternalSdkImports",
73
- "surveyPageFiveStates",
74
- "npmRunBuildPasses"
287
+ "surveyPagePhaseRouter",
288
+ "lifecycleEffectsWired",
289
+ "placeholdersStableRef",
290
+ "customFieldValuesStableRef",
291
+ "customFieldValuesPassedToVisibilityHelpers",
292
+ "monorepoSdkBuilt",
293
+ "npmRunBuildPasses",
294
+ "nextStaticExportConfigured",
295
+ "outIndexHtmlExists",
296
+ "outFileCountUnder500",
297
+ "rankOrderScaleTemplateCopied",
298
+ "dndKitWhenRankOrder",
299
+ "fileUploadPresignedFlowWhenFileUpload"
75
300
  ]
76
301
  },
77
302
  {
78
303
  "id": 7,
79
304
  "name": "deploy",
80
- "command": "npx cfm-sdk deploy"
305
+ "requiresClientConfirmation": true,
306
+ "selectTargetFromPrompt": {
307
+ "awsKeywords": ["aws", "cloudfront", "s3", "ec2", "sprinklr"],
308
+ "default": "vercel"
309
+ },
310
+ "targets": {
311
+ "aws": {
312
+ "read": [
313
+ "00-integration/aws-deploy.md",
314
+ "00-integration/setup.md#nextjs-aws-static-export"
315
+ ],
316
+ "script": "templates/deploy-to-aws.sh",
317
+ "prerequisites": [
318
+ "phase6VerifyPassed",
319
+ "npmRunBuildPasses",
320
+ "instanceIdMatchesSurveyPage"
321
+ ],
322
+ "env": {
323
+ "CFM_DEPLOY_API_BASE": "http://43.204.26.213:3000",
324
+ "CFM_INSTANCE_ID": "same JWT as SurveyPage SURVEY_INSTANCE_ID",
325
+ "OUT_DIR": "absolute path to out/ (Next.js) or dist/ (Vite)"
326
+ },
327
+ "verifyAfterDeploy": [
328
+ "indexHtml200",
329
+ "nestedStaticAssets200",
330
+ "noRootAbsoluteAssetPaths"
331
+ ]
332
+ },
333
+ "vercel": {
334
+ "read": [],
335
+ "command": "npx cfm-sdk deploy",
336
+ "prerequisites": [
337
+ "npm run build passes",
338
+ "VERCEL_TOKEN or Vercel CLI authenticated"
339
+ ]
340
+ }
341
+ }
81
342
  }
82
343
  ],
83
344
  "questionTypes": {
84
- "rating": {
85
- "component": "01-components/03-rating-scale.md",
86
- "reference": "02-reference/question-types/01-rating.md"
345
+ "nps": {
346
+ "typeLiteral": "NPS_SCALE",
347
+ "sdkTypeFile": "fetchSurvey/types/nps.ts",
348
+ "componentFiles": [
349
+ "RatingScale.tsx"
350
+ ],
351
+ "blueprint": "01-components/03-rating-scale.md",
352
+ "reference": "02-reference/question-types/01-rating.md",
353
+ "uiSpec": "03-ui-specs/01-rating.md",
354
+ "answerShape": "number",
355
+ "blocking": false
87
356
  },
88
- "radio": {
89
- "component": "01-components/02-question.md",
90
- "reference": "02-reference/question-types/README.md#radio"
357
+ "mcq": {
358
+ "typeLiteral": "MCQ",
359
+ "sdkTypeFile": "fetchSurvey/types/mcq.ts",
360
+ "componentFiles": [],
361
+ "blueprint": "01-components/02-question.md",
362
+ "reference": "02-reference/question-types/README.md#mcq",
363
+ "uiSpec": "03-ui-specs/02-radio.md",
364
+ "answerShape": "string | number",
365
+ "blocking": false
91
366
  },
92
- "text": {
93
- "component": "01-components/02-question.md",
94
- "reference": "02-reference/question-types/README.md#text"
367
+ "text_input": {
368
+ "typeLiteral": "TEXTFIELD",
369
+ "sdkTypeFile": "fetchSurvey/types/textInput.ts",
370
+ "componentFiles": [],
371
+ "blueprint": "01-components/02-question.md",
372
+ "reference": "02-reference/question-types/README.md#text_input",
373
+ "uiSpec": "03-ui-specs/03-text.md",
374
+ "answerShape": "string",
375
+ "blocking": false
95
376
  },
96
377
  "csat": {
97
- "component": "01-components/04-csat-scale.md",
98
- "reference": "02-reference/question-types/04-csat.md"
378
+ "typeLiteral": "CSAT_MATRIX",
379
+ "sdkTypeFile": "fetchSurvey/types/csat.ts",
380
+ "componentFiles": [
381
+ "CsatMatrixScale.tsx",
382
+ "MatrixDropdown.tsx",
383
+ "CustomSliderTrack.tsx"
384
+ ],
385
+ "blueprint": "01-components/05-csat-matrix-scale.md",
386
+ "reference": "02-reference/question-types/04-csat.md",
387
+ "uiSpec": "03-ui-specs/04-csat.md",
388
+ "answerShape": "MatrixRowAnswers",
389
+ "blocking": true
99
390
  },
100
- "rating_scale": {
101
- "component": "01-components/03-rating-scale.md",
102
- "reference": "02-reference/question-types/05-rating-scale.md"
391
+ "star_rating": {
392
+ "deprecated": true,
393
+ "typeLiteral": "star_rating",
394
+ "sdkTypeFile": "fetchSurvey/types/starRating.ts",
395
+ "componentFiles": [
396
+ "RatingScale.tsx"
397
+ ],
398
+ "blueprint": "01-components/04-star-rating-scale.md",
399
+ "reference": "02-reference/question-types/05-rating-scale.md",
400
+ "uiSpec": "03-ui-specs/05-rating-scale.md",
401
+ "answerShape": "number",
402
+ "blocking": false
103
403
  },
104
404
  "slider": {
105
- "component": "01-components/09-custom-slider-track.md",
106
- "reference": "02-reference/question-types/06-slider.md"
405
+ "deprecated": true,
406
+ "typeLiteral": "slider",
407
+ "sdkTypeFile": "fetchSurvey/types/slider.ts",
408
+ "componentFiles": [
409
+ "CustomSliderTrack.tsx"
410
+ ],
411
+ "blueprint": "01-components/09-custom-slider-track.md",
412
+ "reference": "02-reference/question-types/06-slider.md",
413
+ "uiSpec": "03-ui-specs/06-slider.md",
414
+ "answerShape": "number",
415
+ "blocking": false
107
416
  },
108
- "matrix": {
109
- "component": "01-components/06-likert-matrix-scale.md",
417
+ "cfm_matrix": {
418
+ "typeLiteral": "CFM_MATRIX",
419
+ "sdkTypeFile": "fetchSurvey/types/cfmMatrix.ts",
420
+ "componentFiles": [
421
+ "LikertMatrixScale.tsx",
422
+ "MatrixDropdown.tsx"
423
+ ],
424
+ "blueprint": "01-components/06-likert-matrix-scale.md",
110
425
  "reference": "02-reference/question-types/07-matrix-cfm.md",
111
- "subTypes": {
112
- "CFM_MATRIX": "01-components/06-likert-matrix-scale.md",
113
- "CSAT_MATRIX": "01-components/05-csat-matrix-scale.md",
114
- "RATING_MATRIX": "01-components/05-csat-matrix-scale.md"
115
- }
426
+ "uiSpec": "03-ui-specs/07-matrix-cfm.md",
427
+ "answerShape": "MatrixRowAnswers",
428
+ "blocking": true
116
429
  },
117
430
  "rating_matrix": {
118
- "component": "01-components/05-csat-matrix-scale.md",
119
- "reference": "02-reference/question-types/09-matrix-rating.md"
431
+ "typeLiteral": "RATING_MATRIX",
432
+ "sdkTypeFile": "fetchSurvey/types/ratingMatrix.ts",
433
+ "componentFiles": [
434
+ "CsatMatrixScale.tsx",
435
+ "MatrixDropdown.tsx",
436
+ "CustomSliderTrack.tsx"
437
+ ],
438
+ "blueprint": "01-components/05-csat-matrix-scale.md",
439
+ "reference": "02-reference/question-types/09-matrix-rating.md",
440
+ "uiSpec": "03-ui-specs/08-matrix-csat-rating.md",
441
+ "answerShape": "MatrixRowAnswers",
442
+ "blocking": true
120
443
  },
121
444
  "slider_matrix": {
122
- "component": "01-components/07-slider-matrix-scale.md",
123
- "reference": "02-reference/question-types/10-slider-matrix.md"
445
+ "typeLiteral": "SLIDER_MATRIX",
446
+ "sdkTypeFile": "fetchSurvey/types/sliderMatrix.ts",
447
+ "componentFiles": [
448
+ "SliderMatrixScale.tsx",
449
+ "CustomSliderTrack.tsx"
450
+ ],
451
+ "blueprint": "01-components/07-slider-matrix-scale.md",
452
+ "reference": "02-reference/question-types/10-slider-matrix.md",
453
+ "uiSpec": "03-ui-specs/09-slider-matrix.md",
454
+ "answerShape": "MatrixRowAnswers",
455
+ "blocking": true
124
456
  },
125
457
  "file_upload": {
126
- "component": "01-components/08-file-upload-scale.md",
127
- "reference": "02-reference/question-types/11-file-upload.md"
458
+ "typeLiteral": "FILE_UPLOAD",
459
+ "sdkTypeFile": "fetchSurvey/types/fileUpload.ts",
460
+ "componentFiles": [
461
+ "FileUploadScale.tsx"
462
+ ],
463
+ "blueprint": "01-components/08-file-upload-scale.md",
464
+ "reference": "02-reference/question-types/11-file-upload.md",
465
+ "uiSpec": "03-ui-specs/10-file-upload.md",
466
+ "answerShape": "UploadedFile[]",
467
+ "blocking": true
128
468
  },
129
469
  "text_and_media": {
130
- "component": "01-components/02-question.md",
131
- "reference": "02-reference/question-types/README.md#text_and_media"
470
+ "typeLiteral": "TEXT_AND_MEDIA",
471
+ "sdkTypeFile": "fetchSurvey/types/textAndMedia.ts",
472
+ "componentFiles": [],
473
+ "blueprint": "01-components/02-question.md",
474
+ "reference": "02-reference/question-types/README.md#text_and_media",
475
+ "uiSpec": "03-ui-specs/11-text-and-media.md",
476
+ "answerShape": "none",
477
+ "blocking": false
478
+ },
479
+ "heatmap": {
480
+ "typeLiteral": "HEATMAP",
481
+ "sdkTypeFile": "fetchSurvey/types/heatmap.ts",
482
+ "componentFiles": [
483
+ "HeatmapScale.tsx"
484
+ ],
485
+ "blueprint": "01-components/17-heatmap-scale.md",
486
+ "reference": "02-reference/question-types/12-heatmap.md",
487
+ "uiSpec": "03-ui-specs/13-heatmap.md",
488
+ "answerShape": "HeatmapAnswer",
489
+ "blocking": false
490
+ },
491
+ "rank_order": {
492
+ "typeLiteral": "RANK_ORDER",
493
+ "sdkTypeFile": "fetchSurvey/types/rankOrder.ts",
494
+ "componentFiles": [
495
+ "RankOrderScale.tsx"
496
+ ],
497
+ "blueprint": "01-components/18-rank-order-scale.md",
498
+ "reference": "02-reference/question-types/13-rank-order.md",
499
+ "uiSpec": "03-ui-specs/14-rank-order.md",
500
+ "answerShape": "RankOrderAnswers",
501
+ "blocking": false
132
502
  }
133
503
  },
134
504
  "uiSpecs": {
135
505
  "questionShell": "03-ui-specs/00-question-shell.md",
136
- "rating": "03-ui-specs/01-rating.md",
137
- "radio": "03-ui-specs/02-radio.md",
138
- "text": "03-ui-specs/03-text.md",
506
+ "nps": "03-ui-specs/01-rating.md",
507
+ "mcq": "03-ui-specs/02-radio.md",
508
+ "text_input": "03-ui-specs/03-text.md",
139
509
  "csat": "03-ui-specs/04-csat.md",
140
- "rating_scale": "03-ui-specs/05-rating-scale.md",
510
+ "star_rating": "03-ui-specs/05-rating-scale.md",
141
511
  "slider": "03-ui-specs/06-slider.md",
142
- "matrix_CFM_MATRIX": "03-ui-specs/07-matrix-cfm.md",
143
- "matrix_CSAT_MATRIX": "03-ui-specs/08-matrix-csat-rating.md",
144
- "matrix_RATING_MATRIX": "03-ui-specs/08-matrix-csat-rating.md",
512
+ "cfm_matrix": "03-ui-specs/07-matrix-cfm.md",
513
+ "rating_matrix": "03-ui-specs/08-matrix-csat-rating.md",
145
514
  "slider_matrix": "03-ui-specs/09-slider-matrix.md",
146
515
  "file_upload": "03-ui-specs/10-file-upload.md",
147
516
  "text_and_media": "03-ui-specs/11-text-and-media.md",
517
+ "heatmap": "03-ui-specs/13-heatmap.md",
518
+ "rank_order": "03-ui-specs/14-rank-order.md",
148
519
  "surveyChrome": "03-ui-specs/12-survey-chrome.md"
149
520
  },
150
521
  "sharedUiSpecs": {
151
522
  "customSliderTrack": "03-ui-specs/shared/custom-slider-track.md",
152
523
  "matrixDropdown": "03-ui-specs/shared/matrix-dropdown.md"
153
524
  },
154
- "configFieldIndex": "02-reference/config-field-index.md"
525
+ "sharedUiSpecTriggers": {
526
+ "gridLayout:dropdown": [
527
+ "matrixDropdown"
528
+ ],
529
+ "displayStyle:dropdown": [
530
+ "matrixDropdown"
531
+ ],
532
+ "displayStyle:selectbox": [
533
+ "matrixDropdown"
534
+ ],
535
+ "displayStyle:graphics": [
536
+ "customSliderTrack"
537
+ ],
538
+ "statementLayout:bipolar": []
539
+ },
540
+ "configFieldIndex": "02-reference/config-field-index.md",
541
+ "verify": {
542
+ "grepStubText": "grep -r \"not yet implemented\" src/ components/ app/ 2>/dev/null || true",
543
+ "grepInternalImports": "grep -r \"@explorer02/cfm-survey-sdk/src\\|@repo/sdk/src\" src/ components/ app/ 2>/dev/null || true",
544
+ "requiredDispatcherTypes": [
545
+ "MCQ",
546
+ "TEXTFIELD",
547
+ "NPS_SCALE",
548
+ "CFM_MATRIX",
549
+ "CSAT_MATRIX",
550
+ "RATING_MATRIX",
551
+ "SLIDER_MATRIX",
552
+ "FILE_UPLOAD",
553
+ "TEXT_AND_MEDIA",
554
+ "HEATMAP",
555
+ "RANK_ORDER"
556
+ ]
557
+ },
558
+ "doNotRead": [
559
+ "packages/sdk/src/**",
560
+ "node_modules/@explorer02/cfm-survey-sdk/src/**"
561
+ ]
155
562
  }