@inizioevoke/veeva-astroclm-core 1.3.5 → 1.3.8

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.
@@ -21,26 +21,36 @@ Before using any free-text value (product name, presentation name, presentation
21
21
 
22
22
  Tell the user that some information is required to generate the config file. Gather **all** of the following before writing any files.
23
23
 
24
- Ask the free-text questions one at a time (steps 1–2). The predefined-option questions in step 3 are batched into a single `AskUserQuestion` call — that's intentional, since `AskUserQuestion` natively supports multiple questions per call.
24
+ Ask the free-text questions one at a time (steps 1–2). The predefined-option questions in step 3 are batched into a single `AskUserQuestion` call — that's intentional, since `AskUserQuestion` natively supports multiple questions per call. The Disable questions (step 4) are a separate `AskUserQuestion` call with three multi-select groups.
25
25
 
26
26
  Apply the [Clean input rule](#clean-input-rule) to every free-text value as you receive it.
27
27
 
28
28
  1. Ask for the `Product name` and `Presentation name` (one at a time).
29
29
  2. Ask for the `Presentation ID`. Suggest a value derived from the cleaned `Presentation name`: lowercased, with any non-alphanumeric character replaced by `_`. Ask the user to confirm or enter a new value.
30
- 3. Call `AskUserQuestion` with one call containing the following questions in order. Set `multiSelect: true` only on **Disable**; the other three are single-select.
30
+ 3. Call `AskUserQuestion` with one call containing the following three questions in order (all single-select):
31
31
  - **Dimensions**
32
32
  - Question: Select the IVA dimensions
33
33
  - Options: `1024 × 768`, `1366 × 1024` *(default)*, `1376 × 1032`
34
34
  - **Resolution**
35
35
  - Question: Select the iOS resolution
36
36
  - Options: `Default For Device` *(default)*, `Scale To Fit`, `Scale To 1024x768`
37
- - **Disable**
38
- - Question: Select any Veeva features to disable globally (multi-select)
39
- - Options: `History Buttons`, `Navigation Bar`, `Reactions`, `Swipe`
40
37
  - **Platform**
41
38
  - Question: Select the target Veeva platform
42
39
  - Options: `Salesforce` *(default)*, `Vault`
43
40
 
41
+ 4. Call `AskUserQuestion` with a separate call containing three questions, all `multiSelect: true`, to collect which Veeva features to disable. Each question covers a distinct group of features; `None` means the user wants nothing disabled from that group.
42
+ - **Disable 1/3**
43
+ - Question: Select any features to disable (group 1 of 3)
44
+ - Options: `Navigation Bar`, `Reactions`, `None`
45
+ - **Disable 2/3**
46
+ - Question: Select any features to disable (group 2 of 3)
47
+ - Options: `History Buttons`, `Swipe`, `None`
48
+ - **Disable 3/3**
49
+ - Question: Select any features to disable (group 3 of 3)
50
+ - Options: `Pinch to Exit`, `Rotation Lock`, `Zoom`, `None`
51
+
52
+ When building the `##DISABLE_ACTIONS##` array, collect all selected values across the three groups and exclude any `None` selections — they are a "nothing from this group" signal, not a feature name.
53
+
44
54
  For the **Dimensions** answer, split the selected option on `×` and trim each side to get the numeric width and height (e.g. `1366 × 1024` → width `1366`, height `1024`).
45
55
 
46
56
  ### Preferred collection strategy
@@ -52,9 +62,7 @@ For the **Dimensions** answer, split the selected option on `×` and trim each s
52
62
 
53
63
  ### Exceptions
54
64
 
55
- If `Other` is selected for `Dimensions`, `Resolution`, or `Platform`, reject the response and re-prompt the user asking them to choose only from the defined values.
56
-
57
- If `Other` is selected for `Disable`, ask the user which additional actions they want to disable. The only accepted values beyond the listed four are: `Pinch to Exit`, `Rotation Lock`, `Zoom`. Accept any combination of these. If the user enters anything else, reject and re-prompt with this list.
65
+ If `Other` is selected for `Dimensions`, `Resolution`, `Platform`, or any of the three Disable groups, reject the response and re-prompt the user asking them to choose only from the defined values.
58
66
 
59
67
  ## Generating IDs
60
68
 
@@ -109,7 +117,7 @@ export default function ({ veevaEnv = 'client', isTraining = false }: IVeevaConf
109
117
  // detailGroup: undefined
110
118
  };
111
119
 
112
- const queryStringParams: {
120
+ const queryStringParams = {
113
121
  screenshots: true
114
122
  };
115
123
 
@@ -138,7 +138,7 @@ function createSlideRow(headers, config, slide, additional) {
138
138
  addColumn(headers, row, HEADER_TYPE, VEEVA_TYPE_SLIDE);
139
139
  addColumn(headers, row, HEADER_NAME, slide.name ?? `${config.presentation.name} - ${slide.title ?? slide.path}`);
140
140
  addColumn(headers, row, HEADER_SLIDE_TITLE, slide.title ?? slide.path);
141
- addColumn(headers, row, HEADER_SLIDE_PRODUCT, config.presentation.product);
141
+ addColumn(headers, row, HEADER_SLIDE_PRODUCT, slide.product ?? config.presentation.product);
142
142
  addColumn(headers, row, HEADER_SLIDE_COUNTRY, config.presentation.country);
143
143
  addColumn(headers, row, HEADER_SLIDE_MEDIA_TYPE, slide.mediaType ?? config.presentation.slideSettings?.mediaType ?? config.slideSettings?.mediaType ?? VEEVA_MEDIATYPE_HTML);
144
144
  addColumn(headers, row, HEADER_SLIDE_IOS_RESOLUTION, slide.iosResolution ?? config.presentation.slideSettings?.iosResolution ?? config.slideSettings?.iosResolution ?? VEEVA_IOS_RESOLUTION_DEFAULT);
@@ -40,7 +40,9 @@ export interface IVeevaClmSlideSettings extends IVeevaClmMedia, IVeevaClmBinderF
40
40
  iosResolution?: iOSResolution;
41
41
  }
42
42
 
43
- export interface IVeevaClmSlide extends IVeevaClmItem, IVeevaClmMedia, IVeevaClmSlideSettings {}
43
+ export interface IVeevaClmSlide extends IVeevaClmItem, IVeevaClmSlideSettings {
44
+ product?: string | string[];
45
+ }
44
46
  export interface IVeevaClmSharedResource extends IVeevaClmItem, IVeevaClmMedia, IVeevaClmBinderFields {}
45
47
 
46
48
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inizioevoke/veeva-astroclm-core",
3
- "version": "1.3.5",
3
+ "version": "1.3.8",
4
4
  "description": "",
5
5
  "license": "ISC",
6
6
  "author": "",
@@ -35,7 +35,8 @@
35
35
  "@clack/prompts": "^1.4.0",
36
36
  "adm-zip": "^0.5.17",
37
37
  "puppeteer": "^24.43.1",
38
- "sharp": "^0.34.5"
38
+ "sharp": "^0.34.5",
39
+ "yaml": "^2.9.0"
39
40
  },
40
41
  "devDependencies": {
41
42
  "@astrojs/check": "^0.9.9",
@@ -44,7 +45,6 @@
44
45
  "@types/node": "^25.7.0",
45
46
  "astro": "^6.3.1",
46
47
  "tsx": "^4.21.0",
47
- "typescript": "^6.0.3",
48
- "yaml": "^2.9.0"
48
+ "typescript": "^6.0.3"
49
49
  }
50
50
  }
@@ -212,7 +212,7 @@ function createSlideRow(headers: string[], config: IVeevaConfig, slide: IVeevaCo
212
212
  addColumn(headers, row, HEADER_TYPE, VEEVA_TYPE_SLIDE);
213
213
  addColumn(headers, row, HEADER_NAME, slide.name ?? `${config.presentation.name} - ${slide.title ?? slide.path}`);
214
214
  addColumn(headers, row, HEADER_SLIDE_TITLE, slide.title ?? slide.path);
215
- addColumn(headers, row, HEADER_SLIDE_PRODUCT, config.presentation.product);
215
+ addColumn(headers, row, HEADER_SLIDE_PRODUCT, slide.product ?? config.presentation.product);
216
216
  addColumn(headers, row, HEADER_SLIDE_COUNTRY, config.presentation.country);
217
217
  addColumn(headers, row, HEADER_SLIDE_MEDIA_TYPE, slide.mediaType ?? config.presentation.slideSettings?.mediaType ?? config.slideSettings?.mediaType ?? VEEVA_MEDIATYPE_HTML);
218
218
  addColumn(headers, row, HEADER_SLIDE_IOS_RESOLUTION, slide.iosResolution ?? config.presentation.slideSettings?.iosResolution ?? config.slideSettings?.iosResolution ?? VEEVA_IOS_RESOLUTION_DEFAULT);
@@ -40,7 +40,9 @@ export interface IVeevaClmSlideSettings extends IVeevaClmMedia, IVeevaClmBinderF
40
40
  iosResolution?: iOSResolution;
41
41
  }
42
42
 
43
- export interface IVeevaClmSlide extends IVeevaClmItem, IVeevaClmMedia, IVeevaClmSlideSettings {}
43
+ export interface IVeevaClmSlide extends IVeevaClmItem, IVeevaClmSlideSettings {
44
+ product?: string | string[];
45
+ }
44
46
  export interface IVeevaClmSharedResource extends IVeevaClmItem, IVeevaClmMedia, IVeevaClmBinderFields {}
45
47
 
46
48