n8n-nodes-h2i 1.0.3 → 1.0.4
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.
- package/dist/nodes/DavixH2I/DavixH2I.node.js +417 -511
- package/package.json +1 -1
|
@@ -35,6 +35,7 @@ class DavixH2I {
|
|
|
35
35
|
name: 'resource',
|
|
36
36
|
type: 'options',
|
|
37
37
|
default: 'h2i',
|
|
38
|
+
description: 'Choose which PixLab endpoint to call (H2I, Image, PDF, or Tools). Sends action-specific parameters to that resource.',
|
|
38
39
|
options: [
|
|
39
40
|
{ name: 'H2I (HTML → Image)', value: 'h2i' },
|
|
40
41
|
{ name: 'Image (Transform / Export PDF)', value: 'image' },
|
|
@@ -49,6 +50,7 @@ class DavixH2I {
|
|
|
49
50
|
type: 'options',
|
|
50
51
|
default: 'image',
|
|
51
52
|
displayOptions: { show: { resource: ['h2i'] } },
|
|
53
|
+
description: 'Select the PixLab H2I action. The node sends action=image or action=pdf accordingly.',
|
|
52
54
|
options: [
|
|
53
55
|
{ name: 'Render HTML to Image', value: 'image' },
|
|
54
56
|
{ name: 'Render HTML to PDF', value: 'pdf' },
|
|
@@ -61,6 +63,7 @@ class DavixH2I {
|
|
|
61
63
|
type: 'options',
|
|
62
64
|
default: 'format',
|
|
63
65
|
displayOptions: { show: { resource: ['image'] } },
|
|
66
|
+
description: 'Select the PixLab Image action to run (sent as action=<value>).',
|
|
64
67
|
options: [
|
|
65
68
|
{ name: 'Format', value: 'format' },
|
|
66
69
|
{ name: 'Resize', value: 'resize' },
|
|
@@ -84,6 +87,7 @@ class DavixH2I {
|
|
|
84
87
|
type: 'options',
|
|
85
88
|
default: 'merge',
|
|
86
89
|
displayOptions: { show: { resource: ['pdf'] } },
|
|
90
|
+
description: 'Select the PixLab PDF action to run (sent as action=<value>).',
|
|
87
91
|
options: [
|
|
88
92
|
{ name: 'To Images', value: 'to-images' },
|
|
89
93
|
{ name: 'Merge', value: 'merge' },
|
|
@@ -108,6 +112,7 @@ class DavixH2I {
|
|
|
108
112
|
type: 'options',
|
|
109
113
|
default: 'single',
|
|
110
114
|
displayOptions: { show: { resource: ['tools'] } },
|
|
115
|
+
description: 'Select whether to run one tool or multiple tools in a single PixLab Tools request.',
|
|
111
116
|
options: [
|
|
112
117
|
{ name: 'Single Tool', value: 'single' },
|
|
113
118
|
{ name: 'Multitask', value: 'multitask' },
|
|
@@ -123,6 +128,8 @@ class DavixH2I {
|
|
|
123
128
|
default: '',
|
|
124
129
|
required: true,
|
|
125
130
|
typeOptions: { rows: 6 },
|
|
131
|
+
placeholder: '<div>Hello</div>',
|
|
132
|
+
description: 'HTML markup to render via PixLab H2I.',
|
|
126
133
|
displayOptions: { show: { resource: ['h2i'], operation: ['image', 'pdf'] } },
|
|
127
134
|
},
|
|
128
135
|
{
|
|
@@ -131,6 +138,8 @@ class DavixH2I {
|
|
|
131
138
|
type: 'string',
|
|
132
139
|
default: '',
|
|
133
140
|
typeOptions: { rows: 4 },
|
|
141
|
+
placeholder: 'body { background: #fff; }',
|
|
142
|
+
description: 'Optional CSS styles applied to the HTML before rendering.',
|
|
134
143
|
displayOptions: { show: { resource: ['h2i'], operation: ['image', 'pdf'] } },
|
|
135
144
|
},
|
|
136
145
|
{
|
|
@@ -138,6 +147,7 @@ class DavixH2I {
|
|
|
138
147
|
name: 'width',
|
|
139
148
|
type: 'number',
|
|
140
149
|
default: 1000,
|
|
150
|
+
description: 'Output width in pixels.',
|
|
141
151
|
displayOptions: { show: { resource: ['h2i'], operation: ['image', 'pdf'] } },
|
|
142
152
|
},
|
|
143
153
|
{
|
|
@@ -145,6 +155,7 @@ class DavixH2I {
|
|
|
145
155
|
name: 'height',
|
|
146
156
|
type: 'number',
|
|
147
157
|
default: 1500,
|
|
158
|
+
description: 'Output height in pixels.',
|
|
148
159
|
displayOptions: { show: { resource: ['h2i'], operation: ['image', 'pdf'] } },
|
|
149
160
|
},
|
|
150
161
|
{
|
|
@@ -152,6 +163,7 @@ class DavixH2I {
|
|
|
152
163
|
name: 'format',
|
|
153
164
|
type: 'options',
|
|
154
165
|
default: 'png',
|
|
166
|
+
description: 'Image format when rendering HTML to an image.',
|
|
155
167
|
options: [
|
|
156
168
|
{ name: 'PNG', value: 'png' },
|
|
157
169
|
{ name: 'JPEG', value: 'jpeg' },
|
|
@@ -163,6 +175,7 @@ class DavixH2I {
|
|
|
163
175
|
name: 'h2iPdfPageSize',
|
|
164
176
|
type: 'options',
|
|
165
177
|
default: 'auto',
|
|
178
|
+
description: 'Page size when rendering HTML to PDF.',
|
|
166
179
|
options: [
|
|
167
180
|
{ name: 'Auto', value: 'auto' },
|
|
168
181
|
{ name: 'A4', value: 'a4' },
|
|
@@ -175,6 +188,7 @@ class DavixH2I {
|
|
|
175
188
|
name: 'h2iPdfOrientation',
|
|
176
189
|
type: 'options',
|
|
177
190
|
default: 'portrait',
|
|
191
|
+
description: 'PDF orientation for H2I PDF output.',
|
|
178
192
|
options: [
|
|
179
193
|
{ name: 'Portrait', value: 'portrait' },
|
|
180
194
|
{ name: 'Landscape', value: 'landscape' },
|
|
@@ -186,6 +200,7 @@ class DavixH2I {
|
|
|
186
200
|
name: 'h2iPdfMargin',
|
|
187
201
|
type: 'number',
|
|
188
202
|
default: 0,
|
|
203
|
+
description: 'Page margin in pixels for H2I PDF.',
|
|
189
204
|
displayOptions: { show: { resource: ['h2i'], operation: ['pdf'] } },
|
|
190
205
|
},
|
|
191
206
|
{
|
|
@@ -193,6 +208,7 @@ class DavixH2I {
|
|
|
193
208
|
name: 'h2iPdfEmbedFormat',
|
|
194
209
|
type: 'options',
|
|
195
210
|
default: 'png',
|
|
211
|
+
description: 'Image format embedded inside the generated PDF.',
|
|
196
212
|
options: [
|
|
197
213
|
{ name: 'PNG', value: 'png' },
|
|
198
214
|
{ name: 'JPEG', value: 'jpeg' },
|
|
@@ -204,6 +220,7 @@ class DavixH2I {
|
|
|
204
220
|
name: 'h2iPdfJpegQuality',
|
|
205
221
|
type: 'number',
|
|
206
222
|
default: 85,
|
|
223
|
+
description: 'JPEG quality used when embedding images into the PDF.',
|
|
207
224
|
displayOptions: { show: { resource: ['h2i'], operation: ['pdf'] } },
|
|
208
225
|
},
|
|
209
226
|
{
|
|
@@ -211,6 +228,7 @@ class DavixH2I {
|
|
|
211
228
|
name: 'downloadBinary',
|
|
212
229
|
type: 'boolean',
|
|
213
230
|
default: false,
|
|
231
|
+
description: 'If enabled, downloads the first result URL into a binary property.',
|
|
214
232
|
displayOptions: { show: { resource: ['h2i'], operation: ['image', 'pdf'] } },
|
|
215
233
|
},
|
|
216
234
|
{
|
|
@@ -218,6 +236,7 @@ class DavixH2I {
|
|
|
218
236
|
name: 'outputBinaryProperty',
|
|
219
237
|
type: 'string',
|
|
220
238
|
default: 'data',
|
|
239
|
+
description: 'Name of the binary property to store the downloaded file.',
|
|
221
240
|
displayOptions: { show: { resource: ['h2i'], operation: ['image', 'pdf'], downloadBinary: [true] } },
|
|
222
241
|
},
|
|
223
242
|
// -------------------------
|
|
@@ -229,7 +248,7 @@ class DavixH2I {
|
|
|
229
248
|
type: 'string',
|
|
230
249
|
default: 'data',
|
|
231
250
|
placeholder: 'data OR image1,image2',
|
|
232
|
-
description: 'Comma-separated binary
|
|
251
|
+
description: 'Comma-separated binary properties containing images to upload (e.g. data,image1). Each entry is sent as an images file.',
|
|
233
252
|
displayOptions: { show: { resource: ['image'] } },
|
|
234
253
|
},
|
|
235
254
|
{
|
|
@@ -237,6 +256,7 @@ class DavixH2I {
|
|
|
237
256
|
name: 'imageFormat',
|
|
238
257
|
type: 'options',
|
|
239
258
|
default: 'webp',
|
|
259
|
+
description: 'Output image format for non-multitask actions.',
|
|
240
260
|
options: [
|
|
241
261
|
{ name: 'JPEG', value: 'jpeg' },
|
|
242
262
|
{ name: 'PNG', value: 'png' },
|
|
@@ -248,26 +268,27 @@ class DavixH2I {
|
|
|
248
268
|
],
|
|
249
269
|
displayOptions: { show: { resource: ['image'] }, hide: { operation: ['multitask'] } },
|
|
250
270
|
},
|
|
251
|
-
{ displayName: 'Width', name: 'imageWidth', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['resize', 'format'] } } },
|
|
252
|
-
{ displayName: 'Height', name: 'imageHeight', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['resize', 'format'] } } },
|
|
253
|
-
{ displayName: 'Enlarge', name: 'enlarge', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['resize'] } } },
|
|
254
|
-
{ displayName: 'Normalize Orientation', name: 'normalizeOrientation', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['resize', 'crop', 'enhance', 'metadata'] } } },
|
|
255
|
-
{ displayName: 'Crop X', name: 'cropX', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['crop'] } } },
|
|
256
|
-
{ displayName: 'Crop Y', name: 'cropY', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['crop'] } } },
|
|
257
|
-
{ displayName: 'Crop Width', name: 'cropWidth', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['crop'] } } },
|
|
258
|
-
{ displayName: 'Crop Height', name: 'cropHeight', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['crop'] } } },
|
|
259
|
-
{ displayName: 'Background Color', name: 'backgroundColor', type: 'string', default: '', displayOptions: { show: { resource: ['image'], operation: ['crop', 'compress', 'background'] } } },
|
|
260
|
-
{ displayName: 'Rotate (degrees)', name: 'rotate', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['transform'] } } },
|
|
261
|
-
{ displayName: 'Flip Horizontal', name: 'flipH', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['transform'] } } },
|
|
262
|
-
{ displayName: 'Flip Vertical', name: 'flipV', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['transform'] } } },
|
|
263
|
-
{ displayName: 'Color Space', name: 'colorSpace', type: 'options', default: 'srgb', options: [{ name: 'sRGB', value: 'srgb' }, { name: 'Display P3', value: 'display-p3' }], displayOptions: { show: { resource: ['image'], operation: ['transform', 'compress'] } } },
|
|
264
|
-
{ displayName: 'Target Size (KB)', name: 'targetSizeKB', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['compress'] } } },
|
|
265
|
-
{ displayName: 'Quality', name: 'quality', type: 'number', default: 82, displayOptions: { show: { resource: ['image'], operation: ['compress'] } } },
|
|
271
|
+
{ displayName: 'Width', name: 'imageWidth', type: 'number', default: 0, description: 'Resize width in pixels (0 to auto).', displayOptions: { show: { resource: ['image'], operation: ['resize', 'format'] } } },
|
|
272
|
+
{ displayName: 'Height', name: 'imageHeight', type: 'number', default: 0, description: 'Resize height in pixels (0 to auto).', displayOptions: { show: { resource: ['image'], operation: ['resize', 'format'] } } },
|
|
273
|
+
{ displayName: 'Enlarge', name: 'enlarge', type: 'boolean', default: false, description: 'Allow upscaling when resizing.', displayOptions: { show: { resource: ['image'], operation: ['resize'] } } },
|
|
274
|
+
{ displayName: 'Normalize Orientation', name: 'normalizeOrientation', type: 'boolean', default: false, description: 'Auto-rotate based on EXIF orientation.', displayOptions: { show: { resource: ['image'], operation: ['resize', 'crop', 'enhance', 'metadata'] } } },
|
|
275
|
+
{ displayName: 'Crop X', name: 'cropX', type: 'number', default: 0, description: 'Left offset for crop (requires crop width/height).', displayOptions: { show: { resource: ['image'], operation: ['crop'] } } },
|
|
276
|
+
{ displayName: 'Crop Y', name: 'cropY', type: 'number', default: 0, description: 'Top offset for crop (requires crop width/height).', displayOptions: { show: { resource: ['image'], operation: ['crop'] } } },
|
|
277
|
+
{ displayName: 'Crop Width', name: 'cropWidth', type: 'number', default: 0, description: 'Crop width in pixels.', displayOptions: { show: { resource: ['image'], operation: ['crop'] } } },
|
|
278
|
+
{ displayName: 'Crop Height', name: 'cropHeight', type: 'number', default: 0, description: 'Crop height in pixels.', displayOptions: { show: { resource: ['image'], operation: ['crop'] } } },
|
|
279
|
+
{ displayName: 'Background Color', name: 'backgroundColor', type: 'string', default: '', description: 'Background color to use for some actions (e.g. crop fill, compress, background).', displayOptions: { show: { resource: ['image'], operation: ['crop', 'compress', 'background'] } } },
|
|
280
|
+
{ displayName: 'Rotate (degrees)', name: 'rotate', type: 'number', default: 0, description: 'Rotate image by degrees.', displayOptions: { show: { resource: ['image'], operation: ['transform'] } } },
|
|
281
|
+
{ displayName: 'Flip Horizontal', name: 'flipH', type: 'boolean', default: false, description: 'Flip image horizontally.', displayOptions: { show: { resource: ['image'], operation: ['transform'] } } },
|
|
282
|
+
{ displayName: 'Flip Vertical', name: 'flipV', type: 'boolean', default: false, description: 'Flip image vertically.', displayOptions: { show: { resource: ['image'], operation: ['transform'] } } },
|
|
283
|
+
{ displayName: 'Color Space', name: 'colorSpace', type: 'options', default: 'srgb', description: 'Color space to use for transforms/compress.', options: [{ name: 'sRGB', value: 'srgb' }, { name: 'Display P3', value: 'display-p3' }], displayOptions: { show: { resource: ['image'], operation: ['transform', 'compress'] } } },
|
|
284
|
+
{ displayName: 'Target Size (KB)', name: 'targetSizeKB', type: 'number', default: 0, description: 'Target output size in KB for compression (optional).', displayOptions: { show: { resource: ['image'], operation: ['compress'] } } },
|
|
285
|
+
{ displayName: 'Quality', name: 'quality', type: 'number', default: 82, description: 'Compression quality (1-100).', displayOptions: { show: { resource: ['image'], operation: ['compress'] } } },
|
|
266
286
|
{
|
|
267
287
|
displayName: 'Keep Metadata',
|
|
268
288
|
name: 'keepMetadata',
|
|
269
289
|
type: 'boolean',
|
|
270
290
|
default: false,
|
|
291
|
+
description: 'Preserve EXIF/metadata when possible.',
|
|
271
292
|
displayOptions: {
|
|
272
293
|
show: {
|
|
273
294
|
resource: ['image'],
|
|
@@ -275,27 +296,27 @@ class DavixH2I {
|
|
|
275
296
|
},
|
|
276
297
|
},
|
|
277
298
|
},
|
|
278
|
-
{ displayName: 'Blur', name: 'blur', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
279
|
-
{ displayName: 'Sharpen', name: 'sharpen', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
280
|
-
{ displayName: 'Grayscale', name: 'grayscale', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
281
|
-
{ displayName: 'Sepia', name: 'sepia', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
282
|
-
{ displayName: 'Brightness', name: 'brightness', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
283
|
-
{ displayName: 'Contrast', name: 'contrast', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
284
|
-
{ displayName: 'Saturation', name: 'saturation', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
285
|
-
{ displayName: 'Pad', name: 'pad', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['padding', 'frame'] } } },
|
|
286
|
-
{ displayName: 'Pad Top', name: 'padTop', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['padding'] } } },
|
|
287
|
-
{ displayName: 'Pad Right', name: 'padRight', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['padding'] } } },
|
|
288
|
-
{ displayName: 'Pad Bottom', name: 'padBottom', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['padding'] } } },
|
|
289
|
-
{ displayName: 'Pad Left', name: 'padLeft', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['padding'] } } },
|
|
290
|
-
{ displayName: 'Pad Color', name: 'padColor', type: 'string', default: '', displayOptions: { show: { resource: ['image'], operation: ['padding', 'frame', 'background'] } } },
|
|
291
|
-
{ displayName: 'Border', name: 'border', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['frame'] } } },
|
|
292
|
-
{ displayName: 'Border Color', name: 'borderColor', type: 'string', default: '', displayOptions: { show: { resource: ['image'], operation: ['frame'] } } },
|
|
293
|
-
{ displayName: 'Border Radius', name: 'borderRadius', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['padding', 'background'] } } },
|
|
294
|
-
{ displayName: 'Background Blur', name: 'backgroundBlur', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['background'] } } },
|
|
295
|
-
{ displayName: 'Watermark Text', name: 'watermarkText', type: 'string', default: '', displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
296
|
-
{ displayName: 'Watermark Font Size', name: 'watermarkFontSize', type: 'number', default: 24, displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
297
|
-
{ displayName: 'Watermark Color', name: 'watermarkColor', type: 'string', default: '#000000', displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
298
|
-
{ displayName: 'Watermark Opacity', name: 'watermarkOpacity', type: 'number', default: 0.35, displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
299
|
+
{ displayName: 'Blur', name: 'blur', type: 'number', default: 0, description: 'Apply blur radius (0 to skip).', displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
300
|
+
{ displayName: 'Sharpen', name: 'sharpen', type: 'number', default: 0, description: 'Sharpen amount (0 to skip).', displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
301
|
+
{ displayName: 'Grayscale', name: 'grayscale', type: 'boolean', default: false, description: 'Convert image to grayscale.', displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
302
|
+
{ displayName: 'Sepia', name: 'sepia', type: 'boolean', default: false, description: 'Apply sepia tone.', displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
303
|
+
{ displayName: 'Brightness', name: 'brightness', type: 'number', default: 0, description: 'Adjust brightness (-100 to 100).', displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
304
|
+
{ displayName: 'Contrast', name: 'contrast', type: 'number', default: 0, description: 'Adjust contrast (-100 to 100).', displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
305
|
+
{ displayName: 'Saturation', name: 'saturation', type: 'number', default: 0, description: 'Adjust saturation (-100 to 100).', displayOptions: { show: { resource: ['image'], operation: ['enhance'] } } },
|
|
306
|
+
{ displayName: 'Pad', name: 'pad', type: 'number', default: 0, description: 'Uniform padding size.', displayOptions: { show: { resource: ['image'], operation: ['padding', 'frame'] } } },
|
|
307
|
+
{ displayName: 'Pad Top', name: 'padTop', type: 'number', default: 0, description: 'Top padding (overrides uniform pad).', displayOptions: { show: { resource: ['image'], operation: ['padding'] } } },
|
|
308
|
+
{ displayName: 'Pad Right', name: 'padRight', type: 'number', default: 0, description: 'Right padding (overrides uniform pad).', displayOptions: { show: { resource: ['image'], operation: ['padding'] } } },
|
|
309
|
+
{ displayName: 'Pad Bottom', name: 'padBottom', type: 'number', default: 0, description: 'Bottom padding (overrides uniform pad).', displayOptions: { show: { resource: ['image'], operation: ['padding'] } } },
|
|
310
|
+
{ displayName: 'Pad Left', name: 'padLeft', type: 'number', default: 0, description: 'Left padding (overrides uniform pad).', displayOptions: { show: { resource: ['image'], operation: ['padding'] } } },
|
|
311
|
+
{ displayName: 'Pad Color', name: 'padColor', type: 'string', default: '', description: 'Padding color (e.g. #ffffff).', displayOptions: { show: { resource: ['image'], operation: ['padding', 'frame', 'background'] } } },
|
|
312
|
+
{ displayName: 'Border', name: 'border', type: 'number', default: 0, description: 'Border thickness in pixels.', displayOptions: { show: { resource: ['image'], operation: ['frame'] } } },
|
|
313
|
+
{ displayName: 'Border Color', name: 'borderColor', type: 'string', default: '', description: 'Border color (e.g. #000000).', displayOptions: { show: { resource: ['image'], operation: ['frame'] } } },
|
|
314
|
+
{ displayName: 'Border Radius', name: 'borderRadius', type: 'number', default: 0, description: 'Rounded corner radius.', displayOptions: { show: { resource: ['image'], operation: ['padding', 'background'] } } },
|
|
315
|
+
{ displayName: 'Background Blur', name: 'backgroundBlur', type: 'number', default: 0, description: 'Blur background by this radius.', displayOptions: { show: { resource: ['image'], operation: ['background'] } } },
|
|
316
|
+
{ displayName: 'Watermark Text', name: 'watermarkText', type: 'string', default: '', description: 'Text watermark to overlay.', displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
317
|
+
{ displayName: 'Watermark Font Size', name: 'watermarkFontSize', type: 'number', default: 24, description: 'Font size for text watermark.', displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
318
|
+
{ displayName: 'Watermark Color', name: 'watermarkColor', type: 'string', default: '#000000', description: 'Text watermark color.', displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
319
|
+
{ displayName: 'Watermark Opacity', name: 'watermarkOpacity', type: 'number', default: 0.35, description: 'Watermark opacity between 0 and 1.', displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
299
320
|
{
|
|
300
321
|
displayName: 'Watermark Position',
|
|
301
322
|
name: 'watermarkPosition',
|
|
@@ -308,16 +329,18 @@ class DavixH2I {
|
|
|
308
329
|
{ name: 'Bottom Left', value: 'bottom-left' },
|
|
309
330
|
{ name: 'Bottom Right', value: 'bottom-right' },
|
|
310
331
|
],
|
|
332
|
+
description: 'Position for text/image watermark.',
|
|
311
333
|
displayOptions: { show: { resource: ['image'], operation: ['watermark'] } },
|
|
312
334
|
},
|
|
313
|
-
{ displayName: 'Watermark Margin', name: 'watermarkMargin', type: 'number', default: 8, displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
314
|
-
{ displayName: 'Watermark Scale', name: 'watermarkScale', type: 'number', default: 1, displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
335
|
+
{ displayName: 'Watermark Margin', name: 'watermarkMargin', type: 'number', default: 8, description: 'Margin/padding around watermark.', displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
336
|
+
{ displayName: 'Watermark Scale', name: 'watermarkScale', type: 'number', default: 1, description: 'Scale factor for watermark size.', displayOptions: { show: { resource: ['image'], operation: ['watermark'] } } },
|
|
315
337
|
{
|
|
316
338
|
displayName: 'Watermark Image Binary Property',
|
|
317
339
|
name: 'watermarkImageBinaryProp',
|
|
318
340
|
type: 'string',
|
|
319
341
|
default: '',
|
|
320
342
|
placeholder: 'watermarkImage',
|
|
343
|
+
description: 'Binary property containing an image watermark (optional).',
|
|
321
344
|
displayOptions: { show: { resource: ['image'], operation: ['watermark'] } },
|
|
322
345
|
},
|
|
323
346
|
{
|
|
@@ -379,221 +402,166 @@ class DavixH2I {
|
|
|
379
402
|
default: 85,
|
|
380
403
|
displayOptions: { show: { resource: ['image'], operation: ['pdf'] } },
|
|
381
404
|
},
|
|
382
|
-
{ displayName: 'Include Raw EXIF', name: 'includeRawExif', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['metadata'] } } },
|
|
405
|
+
{ displayName: 'Include Raw EXIF', name: 'includeRawExif', type: 'boolean', default: false, description: 'Include raw EXIF data when available.', displayOptions: { show: { resource: ['image'], operation: ['metadata'] } } },
|
|
383
406
|
{
|
|
384
|
-
displayName: '
|
|
385
|
-
name: '
|
|
386
|
-
type: '
|
|
387
|
-
default:
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
{ name: 'Width', value: 'width' },
|
|
391
|
-
{ name: 'Height', value: 'height' },
|
|
392
|
-
{ name: 'Enlarge', value: 'enlarge' },
|
|
393
|
-
{ name: 'Normalize Orientation', value: 'normalizeOrientation' },
|
|
394
|
-
{ name: 'Crop', value: 'crop' },
|
|
395
|
-
{ name: 'Background Color', value: 'backgroundColor' },
|
|
396
|
-
{ name: 'Rotate', value: 'rotate' },
|
|
397
|
-
{ name: 'Flip Horizontal', value: 'flipH' },
|
|
398
|
-
{ name: 'Flip Vertical', value: 'flipV' },
|
|
399
|
-
{ name: 'Color Space', value: 'colorSpace' },
|
|
400
|
-
{ name: 'Target Size (KB)', value: 'targetSizeKB' },
|
|
401
|
-
{ name: 'Quality', value: 'quality' },
|
|
402
|
-
{ name: 'Keep Metadata', value: 'keepMetadata' },
|
|
403
|
-
{ name: 'Blur', value: 'blur' },
|
|
404
|
-
{ name: 'Sharpen', value: 'sharpen' },
|
|
405
|
-
{ name: 'Grayscale', value: 'grayscale' },
|
|
406
|
-
{ name: 'Sepia', value: 'sepia' },
|
|
407
|
-
{ name: 'Brightness', value: 'brightness' },
|
|
408
|
-
{ name: 'Contrast', value: 'contrast' },
|
|
409
|
-
{ name: 'Saturation', value: 'saturation' },
|
|
410
|
-
{ name: 'Pad', value: 'pad' },
|
|
411
|
-
{ name: 'Pad Sides', value: 'padSides' },
|
|
412
|
-
{ name: 'Pad Color', value: 'padColor' },
|
|
413
|
-
{ name: 'Border', value: 'border' },
|
|
414
|
-
{ name: 'Border Color', value: 'borderColor' },
|
|
415
|
-
{ name: 'Border Radius', value: 'borderRadius' },
|
|
416
|
-
{ name: 'Background Blur', value: 'backgroundBlur' },
|
|
417
|
-
{ name: 'Watermark', value: 'watermark' },
|
|
418
|
-
{ name: 'PDF Options', value: 'pdf' },
|
|
419
|
-
{ name: 'Include Raw EXIF', value: 'includeRawExif' },
|
|
420
|
-
],
|
|
407
|
+
displayName: 'Options',
|
|
408
|
+
name: 'options',
|
|
409
|
+
type: 'collection',
|
|
410
|
+
default: {},
|
|
411
|
+
placeholder: 'Add option',
|
|
412
|
+
description: 'Optional PixLab multitask parameters. Only selected options are sent.',
|
|
421
413
|
displayOptions: { show: { resource: ['image'], operation: ['multitask'] } },
|
|
422
|
-
},
|
|
423
|
-
// Conditional image fields for multitask
|
|
424
|
-
{
|
|
425
|
-
displayName: 'Format',
|
|
426
|
-
name: 'multiFormat',
|
|
427
|
-
type: 'options',
|
|
428
|
-
default: 'webp',
|
|
429
|
-
options: [
|
|
430
|
-
{ name: 'JPEG', value: 'jpeg' },
|
|
431
|
-
{ name: 'PNG', value: 'png' },
|
|
432
|
-
{ name: 'WebP', value: 'webp' },
|
|
433
|
-
{ name: 'AVIF', value: 'avif' },
|
|
434
|
-
{ name: 'GIF', value: 'gif' },
|
|
435
|
-
{ name: 'SVG', value: 'svg' },
|
|
436
|
-
{ name: 'PDF', value: 'pdf' },
|
|
437
|
-
],
|
|
438
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['format'] } },
|
|
439
|
-
},
|
|
440
|
-
{ displayName: 'Width', name: 'multiWidth', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['width'] } } },
|
|
441
|
-
{ displayName: 'Height', name: 'multiHeight', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['height'] } } },
|
|
442
|
-
{ displayName: 'Enlarge', name: 'multiEnlarge', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['enlarge'] } } },
|
|
443
|
-
{
|
|
444
|
-
displayName: 'Normalize Orientation',
|
|
445
|
-
name: 'multiNormalizeOrientation',
|
|
446
|
-
type: 'boolean',
|
|
447
|
-
default: false,
|
|
448
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['normalizeOrientation'] } },
|
|
449
|
-
},
|
|
450
|
-
{ displayName: 'Crop X', name: 'multiCropX', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['crop'] } } },
|
|
451
|
-
{ displayName: 'Crop Y', name: 'multiCropY', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['crop'] } } },
|
|
452
|
-
{ displayName: 'Crop Width', name: 'multiCropWidth', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['crop'] } } },
|
|
453
|
-
{ displayName: 'Crop Height', name: 'multiCropHeight', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['crop'] } } },
|
|
454
|
-
{ displayName: 'Background Color', name: 'multiBackgroundColor', type: 'string', default: '', displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['backgroundColor'] } } },
|
|
455
|
-
{ displayName: 'Rotate (degrees)', name: 'multiRotate', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['rotate'] } } },
|
|
456
|
-
{ displayName: 'Flip Horizontal', name: 'multiFlipH', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['flipH'] } } },
|
|
457
|
-
{ displayName: 'Flip Vertical', name: 'multiFlipV', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['flipV'] } } },
|
|
458
|
-
{
|
|
459
|
-
displayName: 'Color Space',
|
|
460
|
-
name: 'multiColorSpace',
|
|
461
|
-
type: 'options',
|
|
462
|
-
default: 'srgb',
|
|
463
|
-
options: [{ name: 'sRGB', value: 'srgb' }, { name: 'Display P3', value: 'display-p3' }],
|
|
464
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['colorSpace'] } },
|
|
465
|
-
},
|
|
466
|
-
{ displayName: 'Target Size (KB)', name: 'multiTargetSizeKB', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['targetSizeKB'] } } },
|
|
467
|
-
{ displayName: 'Quality', name: 'multiQuality', type: 'number', default: 82, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['quality'] } } },
|
|
468
|
-
{
|
|
469
|
-
displayName: 'Keep Metadata',
|
|
470
|
-
name: 'multiKeepMetadata',
|
|
471
|
-
type: 'boolean',
|
|
472
|
-
default: false,
|
|
473
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['keepMetadata'] } },
|
|
474
|
-
},
|
|
475
|
-
{ displayName: 'Blur', name: 'multiBlur', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['blur'] } } },
|
|
476
|
-
{ displayName: 'Sharpen', name: 'multiSharpen', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['sharpen'] } } },
|
|
477
|
-
{ displayName: 'Grayscale', name: 'multiGrayscale', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['grayscale'] } } },
|
|
478
|
-
{ displayName: 'Sepia', name: 'multiSepia', type: 'boolean', default: false, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['sepia'] } } },
|
|
479
|
-
{ displayName: 'Brightness', name: 'multiBrightness', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['brightness'] } } },
|
|
480
|
-
{ displayName: 'Contrast', name: 'multiContrast', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['contrast'] } } },
|
|
481
|
-
{ displayName: 'Saturation', name: 'multiSaturation', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['saturation'] } } },
|
|
482
|
-
{ displayName: 'Pad', name: 'multiPad', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['pad'] } } },
|
|
483
|
-
{
|
|
484
|
-
displayName: 'Pad Sides',
|
|
485
|
-
name: 'multiPadSides',
|
|
486
|
-
type: 'boolean',
|
|
487
|
-
default: false,
|
|
488
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['padSides'] } },
|
|
489
|
-
},
|
|
490
|
-
{ displayName: 'Pad Top', name: 'multiPadTop', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['padSides'] } } },
|
|
491
|
-
{ displayName: 'Pad Right', name: 'multiPadRight', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['padSides'] } } },
|
|
492
|
-
{ displayName: 'Pad Bottom', name: 'multiPadBottom', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['padSides'] } } },
|
|
493
|
-
{ displayName: 'Pad Left', name: 'multiPadLeft', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['padSides'] } } },
|
|
494
|
-
{ displayName: 'Pad Color', name: 'multiPadColor', type: 'string', default: '', displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['padColor'] } } },
|
|
495
|
-
{ displayName: 'Border', name: 'multiBorder', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['border'] } } },
|
|
496
|
-
{ displayName: 'Border Color', name: 'multiBorderColor', type: 'string', default: '', displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['borderColor'] } } },
|
|
497
|
-
{ displayName: 'Border Radius', name: 'multiBorderRadius', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['borderRadius'] } } },
|
|
498
|
-
{ displayName: 'Background Blur', name: 'multiBackgroundBlur', type: 'number', default: 0, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['backgroundBlur'] } } },
|
|
499
|
-
{ displayName: 'Watermark Text', name: 'multiWatermarkText', type: 'string', default: '', displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['watermark'] } } },
|
|
500
|
-
{ displayName: 'Watermark Font Size', name: 'multiWatermarkFontSize', type: 'number', default: 24, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['watermark'] } } },
|
|
501
|
-
{ displayName: 'Watermark Color', name: 'multiWatermarkColor', type: 'string', default: '#000000', displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['watermark'] } } },
|
|
502
|
-
{ displayName: 'Watermark Opacity', name: 'multiWatermarkOpacity', type: 'number', default: 0.35, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['watermark'] } } },
|
|
503
|
-
{
|
|
504
|
-
displayName: 'Watermark Position',
|
|
505
|
-
name: 'multiWatermarkPosition',
|
|
506
|
-
type: 'options',
|
|
507
|
-
default: 'center',
|
|
508
414
|
options: [
|
|
509
|
-
{
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
415
|
+
{
|
|
416
|
+
displayName: 'Format',
|
|
417
|
+
name: 'format',
|
|
418
|
+
type: 'options',
|
|
419
|
+
default: 'webp',
|
|
420
|
+
description: 'Output format for the multitask result.',
|
|
421
|
+
options: [
|
|
422
|
+
{ name: 'JPEG', value: 'jpeg' },
|
|
423
|
+
{ name: 'PNG', value: 'png' },
|
|
424
|
+
{ name: 'WebP', value: 'webp' },
|
|
425
|
+
{ name: 'AVIF', value: 'avif' },
|
|
426
|
+
{ name: 'GIF', value: 'gif' },
|
|
427
|
+
{ name: 'SVG', value: 'svg' },
|
|
428
|
+
{ name: 'PDF', value: 'pdf' },
|
|
429
|
+
],
|
|
430
|
+
},
|
|
431
|
+
{ displayName: 'Width', name: 'width', type: 'number', default: 0, description: 'Resize width in pixels.' },
|
|
432
|
+
{ displayName: 'Height', name: 'height', type: 'number', default: 0, description: 'Resize height in pixels.' },
|
|
433
|
+
{ displayName: 'Enlarge', name: 'enlarge', type: 'boolean', default: false, description: 'Allow upscaling when resizing.' },
|
|
434
|
+
{
|
|
435
|
+
displayName: 'Normalize Orientation',
|
|
436
|
+
name: 'normalizeOrientation',
|
|
437
|
+
type: 'boolean',
|
|
438
|
+
default: false,
|
|
439
|
+
description: 'Auto-rotate based on EXIF orientation.',
|
|
440
|
+
},
|
|
441
|
+
{ displayName: 'Crop X', name: 'cropX', type: 'number', default: 0, description: 'Left offset for crop.' },
|
|
442
|
+
{ displayName: 'Crop Y', name: 'cropY', type: 'number', default: 0, description: 'Top offset for crop.' },
|
|
443
|
+
{ displayName: 'Crop Width', name: 'cropWidth', type: 'number', default: 0, description: 'Crop width in pixels.' },
|
|
444
|
+
{ displayName: 'Crop Height', name: 'cropHeight', type: 'number', default: 0, description: 'Crop height in pixels.' },
|
|
445
|
+
{ displayName: 'Background Color', name: 'backgroundColor', type: 'string', default: '', description: 'Background color used for fills or padding.' },
|
|
446
|
+
{ displayName: 'Rotate (degrees)', name: 'rotate', type: 'number', default: 0, description: 'Rotate image by degrees.' },
|
|
447
|
+
{ displayName: 'Flip Horizontal', name: 'flipH', type: 'boolean', default: false, description: 'Flip image horizontally.' },
|
|
448
|
+
{ displayName: 'Flip Vertical', name: 'flipV', type: 'boolean', default: false, description: 'Flip image vertically.' },
|
|
449
|
+
{
|
|
450
|
+
displayName: 'Color Space',
|
|
451
|
+
name: 'colorSpace',
|
|
452
|
+
type: 'options',
|
|
453
|
+
default: 'srgb',
|
|
454
|
+
description: 'Color space for processing.',
|
|
455
|
+
options: [
|
|
456
|
+
{ name: 'sRGB', value: 'srgb' },
|
|
457
|
+
{ name: 'Display P3', value: 'display-p3' },
|
|
458
|
+
],
|
|
459
|
+
},
|
|
460
|
+
{ displayName: 'Target Size (KB)', name: 'targetSizeKB', type: 'number', default: 0, description: 'Target compressed size in KB.' },
|
|
461
|
+
{ displayName: 'Quality', name: 'quality', type: 'number', default: 82, description: 'Output quality (1-100).' },
|
|
462
|
+
{ displayName: 'Keep Metadata', name: 'keepMetadata', type: 'boolean', default: false, description: 'Keep EXIF/metadata when possible.' },
|
|
463
|
+
{ displayName: 'Blur', name: 'blur', type: 'number', default: 0, description: 'Blur radius.' },
|
|
464
|
+
{ displayName: 'Sharpen', name: 'sharpen', type: 'number', default: 0, description: 'Sharpen amount.' },
|
|
465
|
+
{ displayName: 'Grayscale', name: 'grayscale', type: 'boolean', default: false, description: 'Convert to grayscale.' },
|
|
466
|
+
{ displayName: 'Sepia', name: 'sepia', type: 'boolean', default: false, description: 'Apply sepia tone.' },
|
|
467
|
+
{ displayName: 'Brightness', name: 'brightness', type: 'number', default: 0, description: 'Brightness adjustment (-100 to 100).' },
|
|
468
|
+
{ displayName: 'Contrast', name: 'contrast', type: 'number', default: 0, description: 'Contrast adjustment (-100 to 100).' },
|
|
469
|
+
{ displayName: 'Saturation', name: 'saturation', type: 'number', default: 0, description: 'Saturation adjustment (-100 to 100).' },
|
|
470
|
+
{ displayName: 'Pad', name: 'pad', type: 'number', default: 0, description: 'Uniform padding size.' },
|
|
471
|
+
{ displayName: 'Pad Color', name: 'padColor', type: 'string', default: '', description: 'Padding color (e.g. #ffffff).' },
|
|
472
|
+
{ displayName: 'Pad Top', name: 'padTop', type: 'number', default: 0, description: 'Top padding override.' },
|
|
473
|
+
{ displayName: 'Pad Right', name: 'padRight', type: 'number', default: 0, description: 'Right padding override.' },
|
|
474
|
+
{ displayName: 'Pad Bottom', name: 'padBottom', type: 'number', default: 0, description: 'Bottom padding override.' },
|
|
475
|
+
{ displayName: 'Pad Left', name: 'padLeft', type: 'number', default: 0, description: 'Left padding override.' },
|
|
476
|
+
{ displayName: 'Border Radius', name: 'borderRadius', type: 'number', default: 0, description: 'Rounded corner radius.' },
|
|
477
|
+
{ displayName: 'Border', name: 'border', type: 'number', default: 0, description: 'Border thickness in pixels.' },
|
|
478
|
+
{ displayName: 'Border Color', name: 'borderColor', type: 'string', default: '', description: 'Border color (e.g. #000000).' },
|
|
479
|
+
{ displayName: 'Background Blur', name: 'backgroundBlur', type: 'number', default: 0, description: 'Background blur radius.' },
|
|
480
|
+
{ displayName: 'Watermark Text', name: 'watermarkText', type: 'string', default: '', description: 'Text watermark content.' },
|
|
481
|
+
{ displayName: 'Watermark Font Size', name: 'watermarkFontSize', type: 'number', default: 24, description: 'Font size for text watermark.' },
|
|
482
|
+
{ displayName: 'Watermark Color', name: 'watermarkColor', type: 'string', default: '#000000', description: 'Color for text watermark.' },
|
|
483
|
+
{ displayName: 'Watermark Opacity', name: 'watermarkOpacity', type: 'number', default: 0.35, description: 'Watermark opacity (0-1).' },
|
|
484
|
+
{
|
|
485
|
+
displayName: 'Watermark Position',
|
|
486
|
+
name: 'watermarkPosition',
|
|
487
|
+
type: 'options',
|
|
488
|
+
default: 'center',
|
|
489
|
+
description: 'Placement for watermark.',
|
|
490
|
+
options: [
|
|
491
|
+
{ name: 'Center', value: 'center' },
|
|
492
|
+
{ name: 'Top Left', value: 'top-left' },
|
|
493
|
+
{ name: 'Top Right', value: 'top-right' },
|
|
494
|
+
{ name: 'Bottom Left', value: 'bottom-left' },
|
|
495
|
+
{ name: 'Bottom Right', value: 'bottom-right' },
|
|
496
|
+
],
|
|
497
|
+
},
|
|
498
|
+
{ displayName: 'Watermark Margin', name: 'watermarkMargin', type: 'number', default: 8, description: 'Margin/padding around watermark.' },
|
|
499
|
+
{ displayName: 'Watermark Scale', name: 'watermarkScale', type: 'number', default: 1, description: 'Scale factor for watermark.' },
|
|
500
|
+
{
|
|
501
|
+
displayName: 'PDF Mode',
|
|
502
|
+
name: 'pdfMode',
|
|
503
|
+
type: 'options',
|
|
504
|
+
default: 'single',
|
|
505
|
+
description: 'Single or multi-page PDF export.',
|
|
506
|
+
options: [
|
|
507
|
+
{ name: 'Single', value: 'single' },
|
|
508
|
+
{ name: 'Multi', value: 'multi' },
|
|
509
|
+
],
|
|
510
|
+
},
|
|
511
|
+
{
|
|
512
|
+
displayName: 'PDF Page Size',
|
|
513
|
+
name: 'pdfPageSize',
|
|
514
|
+
type: 'options',
|
|
515
|
+
default: 'auto',
|
|
516
|
+
description: 'Page size for PDF output.',
|
|
517
|
+
options: [
|
|
518
|
+
{ name: 'Auto', value: 'auto' },
|
|
519
|
+
{ name: 'A4', value: 'a4' },
|
|
520
|
+
{ name: 'Letter', value: 'letter' },
|
|
521
|
+
],
|
|
522
|
+
},
|
|
523
|
+
{
|
|
524
|
+
displayName: 'PDF Orientation',
|
|
525
|
+
name: 'pdfOrientation',
|
|
526
|
+
type: 'options',
|
|
527
|
+
default: 'portrait',
|
|
528
|
+
description: 'Orientation for PDF pages.',
|
|
529
|
+
options: [
|
|
530
|
+
{ name: 'Portrait', value: 'portrait' },
|
|
531
|
+
{ name: 'Landscape', value: 'landscape' },
|
|
532
|
+
],
|
|
533
|
+
},
|
|
534
|
+
{ displayName: 'PDF Margin', name: 'pdfMargin', type: 'number', default: 0, description: 'Page margin for PDF output.' },
|
|
535
|
+
{
|
|
536
|
+
displayName: 'PDF Embed Format',
|
|
537
|
+
name: 'pdfEmbedFormat',
|
|
538
|
+
type: 'options',
|
|
539
|
+
default: 'png',
|
|
540
|
+
description: 'Image format embedded in the PDF.',
|
|
541
|
+
options: [
|
|
542
|
+
{ name: 'PNG', value: 'png' },
|
|
543
|
+
{ name: 'JPEG', value: 'jpeg' },
|
|
544
|
+
],
|
|
545
|
+
},
|
|
546
|
+
{ displayName: 'PDF JPEG Quality', name: 'pdfJpegQuality', type: 'number', default: 85, description: 'JPEG quality for PDF embedding.' },
|
|
547
|
+
{ displayName: 'Include Raw EXIF', name: 'includeRawExif', type: 'boolean', default: false, description: 'Include raw EXIF data when available.' },
|
|
514
548
|
],
|
|
515
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['watermark'] } },
|
|
516
549
|
},
|
|
517
|
-
{ displayName: 'Watermark Margin', name: 'multiWatermarkMargin', type: 'number', default: 8, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['watermark'] } } },
|
|
518
|
-
{ displayName: 'Watermark Scale', name: 'multiWatermarkScale', type: 'number', default: 1, displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['watermark'] } } },
|
|
519
550
|
{
|
|
520
551
|
displayName: 'Watermark Image Binary Property',
|
|
521
|
-
name: '
|
|
552
|
+
name: 'watermarkBinaryProperty',
|
|
522
553
|
type: 'string',
|
|
523
554
|
default: '',
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
displayName: 'PDF Mode',
|
|
528
|
-
name: 'multiPdfMode',
|
|
529
|
-
type: 'options',
|
|
530
|
-
default: 'single',
|
|
531
|
-
options: [
|
|
532
|
-
{ name: 'Single', value: 'single' },
|
|
533
|
-
{ name: 'Multi', value: 'multi' },
|
|
534
|
-
],
|
|
535
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['pdf'] } },
|
|
536
|
-
},
|
|
537
|
-
{
|
|
538
|
-
displayName: 'PDF Page Size',
|
|
539
|
-
name: 'multiPdfPageSize',
|
|
540
|
-
type: 'options',
|
|
541
|
-
default: 'auto',
|
|
542
|
-
options: [
|
|
543
|
-
{ name: 'Auto', value: 'auto' },
|
|
544
|
-
{ name: 'A4', value: 'a4' },
|
|
545
|
-
{ name: 'Letter', value: 'letter' },
|
|
546
|
-
],
|
|
547
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['pdf'] } },
|
|
548
|
-
},
|
|
549
|
-
{
|
|
550
|
-
displayName: 'PDF Orientation',
|
|
551
|
-
name: 'multiPdfOrientation',
|
|
552
|
-
type: 'options',
|
|
553
|
-
default: 'portrait',
|
|
554
|
-
options: [
|
|
555
|
-
{ name: 'Portrait', value: 'portrait' },
|
|
556
|
-
{ name: 'Landscape', value: 'landscape' },
|
|
557
|
-
],
|
|
558
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['pdf'] } },
|
|
559
|
-
},
|
|
560
|
-
{
|
|
561
|
-
displayName: 'PDF Margin',
|
|
562
|
-
name: 'multiPdfMargin',
|
|
563
|
-
type: 'number',
|
|
564
|
-
default: 0,
|
|
565
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['pdf'] } },
|
|
566
|
-
},
|
|
567
|
-
{
|
|
568
|
-
displayName: 'PDF Embed Format',
|
|
569
|
-
name: 'multiPdfEmbedFormat',
|
|
570
|
-
type: 'options',
|
|
571
|
-
default: 'png',
|
|
572
|
-
options: [
|
|
573
|
-
{ name: 'PNG', value: 'png' },
|
|
574
|
-
{ name: 'JPEG', value: 'jpeg' },
|
|
575
|
-
],
|
|
576
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['pdf'] } },
|
|
577
|
-
},
|
|
578
|
-
{
|
|
579
|
-
displayName: 'PDF JPEG Quality',
|
|
580
|
-
name: 'multiPdfJpegQuality',
|
|
581
|
-
type: 'number',
|
|
582
|
-
default: 85,
|
|
583
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['pdf'] } },
|
|
584
|
-
},
|
|
585
|
-
{
|
|
586
|
-
displayName: 'Include Raw EXIF',
|
|
587
|
-
name: 'multiIncludeRawExif',
|
|
588
|
-
type: 'boolean',
|
|
589
|
-
default: false,
|
|
590
|
-
displayOptions: { show: { resource: ['image'], operation: ['multitask'], imageMultitaskOptions: ['includeRawExif'] } },
|
|
555
|
+
placeholder: 'watermarkImage',
|
|
556
|
+
description: 'Binary property containing an image watermark (used if watermark options are set).',
|
|
557
|
+
displayOptions: { show: { resource: ['image'], operation: ['multitask'] } },
|
|
591
558
|
},
|
|
592
559
|
{
|
|
593
560
|
displayName: 'Download Result(s) as Binary',
|
|
594
561
|
name: 'imageDownloadBinary',
|
|
595
562
|
type: 'boolean',
|
|
596
563
|
default: false,
|
|
564
|
+
description: 'Download the first returned URL into binary data (results remain in JSON).',
|
|
597
565
|
displayOptions: {
|
|
598
566
|
show: {
|
|
599
567
|
resource: ['image'],
|
|
@@ -606,6 +574,7 @@ class DavixH2I {
|
|
|
606
574
|
name: 'imageOutputBinaryProperty',
|
|
607
575
|
type: 'string',
|
|
608
576
|
default: 'data',
|
|
577
|
+
description: 'Binary property name to store the downloaded file.',
|
|
609
578
|
displayOptions: {
|
|
610
579
|
show: {
|
|
611
580
|
resource: ['image'],
|
|
@@ -631,6 +600,7 @@ class DavixH2I {
|
|
|
631
600
|
name: 'sortByName',
|
|
632
601
|
type: 'boolean',
|
|
633
602
|
default: false,
|
|
603
|
+
description: 'When merging, sort uploaded PDFs by filename before merging.',
|
|
634
604
|
displayOptions: { show: { resource: ['pdf'], operation: ['merge'] } },
|
|
635
605
|
},
|
|
636
606
|
{
|
|
@@ -639,6 +609,7 @@ class DavixH2I {
|
|
|
639
609
|
type: 'string',
|
|
640
610
|
default: '',
|
|
641
611
|
placeholder: '1-3,4-5',
|
|
612
|
+
description: 'Page ranges to keep when splitting (e.g. 1-3,5).',
|
|
642
613
|
displayOptions: { show: { resource: ['pdf'], operation: ['split'] } },
|
|
643
614
|
},
|
|
644
615
|
{
|
|
@@ -646,6 +617,7 @@ class DavixH2I {
|
|
|
646
617
|
name: 'prefix',
|
|
647
618
|
type: 'string',
|
|
648
619
|
default: 'split_',
|
|
620
|
+
description: 'Prefix for split output files.',
|
|
649
621
|
displayOptions: { show: { resource: ['pdf'], operation: ['split', 'extract'] } },
|
|
650
622
|
},
|
|
651
623
|
{
|
|
@@ -654,6 +626,7 @@ class DavixH2I {
|
|
|
654
626
|
type: 'string',
|
|
655
627
|
default: 'all',
|
|
656
628
|
placeholder: 'all OR 1-3,5,7',
|
|
629
|
+
description: 'Page selection, e.g. all or 1-3,5.',
|
|
657
630
|
displayOptions: {
|
|
658
631
|
show: { resource: ['pdf'], operation: ['to-images', 'extract-images', 'watermark', 'rotate', 'delete-pages', 'extract'] },
|
|
659
632
|
},
|
|
@@ -663,6 +636,7 @@ class DavixH2I {
|
|
|
663
636
|
name: 'toFormat',
|
|
664
637
|
type: 'options',
|
|
665
638
|
default: 'png',
|
|
639
|
+
description: 'Image format when converting PDF pages.',
|
|
666
640
|
options: [
|
|
667
641
|
{ name: 'PNG', value: 'png' },
|
|
668
642
|
{ name: 'JPEG', value: 'jpeg' },
|
|
@@ -670,14 +644,15 @@ class DavixH2I {
|
|
|
670
644
|
],
|
|
671
645
|
displayOptions: { show: { resource: ['pdf'], operation: ['to-images'] } },
|
|
672
646
|
},
|
|
673
|
-
{ displayName: 'Width', name: 'pdfWidth', type: 'number', default: 0, displayOptions: { show: { resource: ['pdf'], operation: ['to-images'] } } },
|
|
674
|
-
{ displayName: 'Height', name: 'pdfHeight', type: 'number', default: 0, displayOptions: { show: { resource: ['pdf'], operation: ['to-images'] } } },
|
|
675
|
-
{ displayName: 'DPI', name: 'dpi', type: 'number', default: 150, displayOptions: { show: { resource: ['pdf'], operation: ['to-images'] } } },
|
|
647
|
+
{ displayName: 'Width', name: 'pdfWidth', type: 'number', default: 0, description: 'Resize width for PDF to images (optional).', displayOptions: { show: { resource: ['pdf'], operation: ['to-images'] } } },
|
|
648
|
+
{ displayName: 'Height', name: 'pdfHeight', type: 'number', default: 0, description: 'Resize height for PDF to images (optional).', displayOptions: { show: { resource: ['pdf'], operation: ['to-images'] } } },
|
|
649
|
+
{ displayName: 'DPI', name: 'dpi', type: 'number', default: 150, description: 'Rendering DPI for PDF to images.', displayOptions: { show: { resource: ['pdf'], operation: ['to-images'] } } },
|
|
676
650
|
{
|
|
677
651
|
displayName: 'Extract Image Format',
|
|
678
652
|
name: 'extractImageFormat',
|
|
679
653
|
type: 'options',
|
|
680
654
|
default: 'png',
|
|
655
|
+
description: 'Image format for extracted images.',
|
|
681
656
|
options: [
|
|
682
657
|
{ name: 'PNG', value: 'png' },
|
|
683
658
|
{ name: 'JPEG', value: 'jpeg' },
|
|
@@ -685,8 +660,8 @@ class DavixH2I {
|
|
|
685
660
|
],
|
|
686
661
|
displayOptions: { show: { resource: ['pdf'], operation: ['extract-images'] } },
|
|
687
662
|
},
|
|
688
|
-
{ displayName: 'Watermark Text', name: 'watermarkText', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
689
|
-
{ displayName: 'Watermark Opacity', name: 'watermarkOpacity', type: 'number', default: 0.35, displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
663
|
+
{ displayName: 'Watermark Text', name: 'watermarkText', type: 'string', default: '', description: 'Optional text watermark to apply.', displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
664
|
+
{ displayName: 'Watermark Opacity', name: 'watermarkOpacity', type: 'number', default: 0.35, description: 'Watermark opacity (0-1).', displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
690
665
|
{
|
|
691
666
|
displayName: 'Watermark Position',
|
|
692
667
|
name: 'watermarkPosition',
|
|
@@ -704,33 +679,35 @@ class DavixH2I {
|
|
|
704
679
|
{ displayName: 'Watermark Margin', name: 'watermarkMargin', type: 'number', default: 8, displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
705
680
|
{ displayName: 'Watermark Font Size', name: 'watermarkFontSize', type: 'number', default: 24, displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
706
681
|
{ displayName: 'Watermark Color', name: 'watermarkColor', type: 'string', default: '#000000', displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
707
|
-
{ displayName: 'Watermark Scale', name: 'watermarkScale', type: 'number', default: 1, displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
682
|
+
{ displayName: 'Watermark Scale', name: 'watermarkScale', type: 'number', default: 1, description: 'Scale factor for watermark.', displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } } },
|
|
708
683
|
{
|
|
709
684
|
displayName: 'Watermark Image Binary Property',
|
|
710
685
|
name: 'watermarkImageBinaryProp',
|
|
711
686
|
type: 'string',
|
|
712
687
|
default: '',
|
|
688
|
+
description: 'Binary property containing an image watermark (optional).',
|
|
713
689
|
displayOptions: { show: { resource: ['pdf'], operation: ['watermark'] } },
|
|
714
690
|
},
|
|
715
|
-
{ displayName: 'Degrees', name: 'degrees', type: 'number', default: 0, displayOptions: { show: { resource: ['pdf'], operation: ['rotate'] } } },
|
|
716
|
-
{ displayName: 'Title', name: 'title', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
717
|
-
{ displayName: 'Author', name: 'author', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
718
|
-
{ displayName: 'Subject', name: 'subject', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
719
|
-
{ displayName: 'Keywords', name: 'keywords', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
720
|
-
{ displayName: 'Creator', name: 'creator', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
721
|
-
{ displayName: 'Producer', name: 'producer', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
722
|
-
{ displayName: 'Clean All Metadata', name: 'cleanAllMetadata', type: 'boolean', default: false, displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
723
|
-
{ displayName: 'Order (JSON array)', name: 'order', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['reorder'] } } },
|
|
724
|
-
{ displayName: 'Mode', name: 'mode', type: 'string', default: 'range', displayOptions: { show: { resource: ['pdf'], operation: ['extract'] } } },
|
|
725
|
-
{ displayName: 'Flatten Forms', name: 'flattenForms', type: 'boolean', default: false, displayOptions: { show: { resource: ['pdf'], operation: ['flatten'] } } },
|
|
726
|
-
{ displayName: 'User Password', name: 'userPassword', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['encrypt'] } } },
|
|
727
|
-
{ displayName: 'Owner Password', name: 'ownerPassword', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['encrypt'] } } },
|
|
728
|
-
{ displayName: 'Password', name: 'password', type: 'string', default: '', displayOptions: { show: { resource: ['pdf'], operation: ['decrypt'] } } },
|
|
691
|
+
{ displayName: 'Degrees', name: 'degrees', type: 'number', default: 0, description: 'Rotation angle in degrees.', displayOptions: { show: { resource: ['pdf'], operation: ['rotate'] } } },
|
|
692
|
+
{ displayName: 'Title', name: 'title', type: 'string', default: '', description: 'Set PDF title metadata.', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
693
|
+
{ displayName: 'Author', name: 'author', type: 'string', default: '', description: 'Set PDF author metadata.', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
694
|
+
{ displayName: 'Subject', name: 'subject', type: 'string', default: '', description: 'Set PDF subject metadata.', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
695
|
+
{ displayName: 'Keywords', name: 'keywords', type: 'string', default: '', description: 'Set PDF keywords metadata.', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
696
|
+
{ displayName: 'Creator', name: 'creator', type: 'string', default: '', description: 'Set PDF creator metadata.', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
697
|
+
{ displayName: 'Producer', name: 'producer', type: 'string', default: '', description: 'Set PDF producer metadata.', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
698
|
+
{ displayName: 'Clean All Metadata', name: 'cleanAllMetadata', type: 'boolean', default: false, description: 'Remove existing metadata before applying new fields.', displayOptions: { show: { resource: ['pdf'], operation: ['metadata'] } } },
|
|
699
|
+
{ displayName: 'Order (JSON array)', name: 'order', type: 'string', default: '', description: 'JSON array describing new page order (e.g. [2,1,3]).', displayOptions: { show: { resource: ['pdf'], operation: ['reorder'] } } },
|
|
700
|
+
{ displayName: 'Mode', name: 'mode', type: 'string', default: 'range', description: 'Extraction mode (e.g. range).', displayOptions: { show: { resource: ['pdf'], operation: ['extract'] } } },
|
|
701
|
+
{ displayName: 'Flatten Forms', name: 'flattenForms', type: 'boolean', default: false, description: 'Flatten form fields into static content.', displayOptions: { show: { resource: ['pdf'], operation: ['flatten'] } } },
|
|
702
|
+
{ displayName: 'User Password', name: 'userPassword', type: 'string', default: '', description: 'User password for encryption.', displayOptions: { show: { resource: ['pdf'], operation: ['encrypt'] } } },
|
|
703
|
+
{ displayName: 'Owner Password', name: 'ownerPassword', type: 'string', default: '', description: 'Owner password for encryption.', displayOptions: { show: { resource: ['pdf'], operation: ['encrypt'] } } },
|
|
704
|
+
{ displayName: 'Password', name: 'password', type: 'string', default: '', description: 'Password to decrypt PDF.', displayOptions: { show: { resource: ['pdf'], operation: ['decrypt'] } } },
|
|
729
705
|
{
|
|
730
706
|
displayName: 'Download Result(s) as Binary',
|
|
731
707
|
name: 'pdfDownloadBinary',
|
|
732
708
|
type: 'boolean',
|
|
733
709
|
default: false,
|
|
710
|
+
description: 'If enabled, download the first URL result into a binary property.',
|
|
734
711
|
displayOptions: { show: { resource: ['pdf'] } },
|
|
735
712
|
},
|
|
736
713
|
{
|
|
@@ -738,6 +715,7 @@ class DavixH2I {
|
|
|
738
715
|
name: 'pdfOutputBinaryProperty',
|
|
739
716
|
type: 'string',
|
|
740
717
|
default: 'data',
|
|
718
|
+
description: 'Binary property name to store downloaded PDF/image results.',
|
|
741
719
|
displayOptions: { show: { resource: ['pdf'], pdfDownloadBinary: [true] } },
|
|
742
720
|
},
|
|
743
721
|
// -------------------------
|
|
@@ -749,7 +727,7 @@ class DavixH2I {
|
|
|
749
727
|
type: 'string',
|
|
750
728
|
default: 'data',
|
|
751
729
|
placeholder: 'data OR img1,img2',
|
|
752
|
-
description: 'Comma-separated binary
|
|
730
|
+
description: 'Comma-separated binary properties containing images to analyze (sent as images files).',
|
|
753
731
|
displayOptions: { show: { resource: ['tools'] } },
|
|
754
732
|
},
|
|
755
733
|
{
|
|
@@ -757,6 +735,7 @@ class DavixH2I {
|
|
|
757
735
|
name: 'tool',
|
|
758
736
|
type: 'options',
|
|
759
737
|
default: 'metadata',
|
|
738
|
+
description: 'Single PixLab tool to run in action=single.',
|
|
760
739
|
options: [
|
|
761
740
|
{ name: 'Metadata', value: 'metadata' },
|
|
762
741
|
{ name: 'Colors', value: 'colors' },
|
|
@@ -777,6 +756,7 @@ class DavixH2I {
|
|
|
777
756
|
name: 'tools',
|
|
778
757
|
type: 'multiOptions',
|
|
779
758
|
default: ['metadata'],
|
|
759
|
+
description: 'Multiple PixLab tools to run together in action=multitask.',
|
|
780
760
|
options: [
|
|
781
761
|
{ name: 'Metadata', value: 'metadata' },
|
|
782
762
|
{ name: 'Colors', value: 'colors' },
|
|
@@ -793,140 +773,66 @@ class DavixH2I {
|
|
|
793
773
|
displayOptions: { show: { resource: ['tools'], operation: ['multitask'] } },
|
|
794
774
|
},
|
|
795
775
|
{
|
|
796
|
-
displayName: '
|
|
797
|
-
name: '
|
|
798
|
-
type: '
|
|
799
|
-
default:
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
displayName: 'Include Raw EXIF',
|
|
804
|
-
name: 'multiIncludeRawExif',
|
|
805
|
-
type: 'boolean',
|
|
806
|
-
default: false,
|
|
807
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['metadata'] } },
|
|
808
|
-
},
|
|
809
|
-
{
|
|
810
|
-
displayName: 'Palette Size',
|
|
811
|
-
name: 'paletteSize',
|
|
812
|
-
type: 'number',
|
|
813
|
-
default: 5,
|
|
814
|
-
displayOptions: { show: { resource: ['tools'], operation: ['single'], tool: ['palette'] } },
|
|
815
|
-
},
|
|
816
|
-
{
|
|
817
|
-
displayName: 'Palette Size',
|
|
818
|
-
name: 'multiPaletteSize',
|
|
819
|
-
type: 'number',
|
|
820
|
-
default: 5,
|
|
821
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['palette'] } },
|
|
822
|
-
},
|
|
823
|
-
{
|
|
824
|
-
displayName: 'Hash Type',
|
|
825
|
-
name: 'hashType',
|
|
826
|
-
type: 'options',
|
|
827
|
-
default: 'phash',
|
|
776
|
+
displayName: 'Options',
|
|
777
|
+
name: 'options',
|
|
778
|
+
type: 'collection',
|
|
779
|
+
default: {},
|
|
780
|
+
placeholder: 'Add option',
|
|
781
|
+
description: 'Optional tool parameters (only applied when the selected tool supports them).',
|
|
782
|
+
displayOptions: { show: { resource: ['tools'], operation: ['single'] } },
|
|
828
783
|
options: [
|
|
829
|
-
{ name: '
|
|
830
|
-
{ name: '
|
|
831
|
-
{
|
|
784
|
+
{ displayName: 'Include Raw EXIF', name: 'includeRawExif', type: 'boolean', default: false, description: 'Include raw EXIF data (metadata tool only).' },
|
|
785
|
+
{ displayName: 'Palette Size', name: 'paletteSize', type: 'number', default: 5, description: 'Number of colors to extract (palette tool).' },
|
|
786
|
+
{
|
|
787
|
+
displayName: 'Hash Type',
|
|
788
|
+
name: 'hashType',
|
|
789
|
+
type: 'options',
|
|
790
|
+
default: 'phash',
|
|
791
|
+
description: 'Hash algorithm to compute (hash tool).',
|
|
792
|
+
options: [
|
|
793
|
+
{ name: 'pHash', value: 'phash' },
|
|
794
|
+
{ name: 'MD5', value: 'md5' },
|
|
795
|
+
{ name: 'SHA1', value: 'sha1' },
|
|
796
|
+
],
|
|
797
|
+
},
|
|
798
|
+
{ displayName: 'Similarity Mode', name: 'similarityMode', type: 'string', default: '', description: 'Similarity mode (similarity tool).' },
|
|
799
|
+
{ displayName: 'Similarity Threshold', name: 'similarityThreshold', type: 'number', default: 0, description: 'Similarity threshold (similarity tool).' },
|
|
800
|
+
{ displayName: 'Quality Sample', name: 'qualitySample', type: 'number', default: 0, description: 'Sample size for quality analysis (quality tool).' },
|
|
801
|
+
{ displayName: 'Transparency Sample', name: 'transparencySample', type: 'number', default: 0, description: 'Sample size for transparency analysis (transparency tool).' },
|
|
802
|
+
{ displayName: 'Efficiency Format', name: 'efficiencyFormat', type: 'string', default: '', description: 'Output format for efficiency tool.' },
|
|
803
|
+
{ displayName: 'Efficiency Quality', name: 'efficiencyQuality', type: 'number', default: 0, description: 'Quality setting for efficiency tool.' },
|
|
832
804
|
],
|
|
833
|
-
displayOptions: { show: { resource: ['tools'], operation: ['single'], tool: ['hash'] } },
|
|
834
805
|
},
|
|
835
806
|
{
|
|
836
|
-
displayName: '
|
|
837
|
-
name: '
|
|
838
|
-
type: '
|
|
839
|
-
default:
|
|
807
|
+
displayName: 'Options',
|
|
808
|
+
name: 'options',
|
|
809
|
+
type: 'collection',
|
|
810
|
+
default: {},
|
|
811
|
+
placeholder: 'Add option',
|
|
812
|
+
description: 'Optional tool parameters (applied per selected tool).',
|
|
813
|
+
displayOptions: { show: { resource: ['tools'], operation: ['multitask'] } },
|
|
840
814
|
options: [
|
|
841
|
-
{ name: '
|
|
842
|
-
{ name: '
|
|
843
|
-
{
|
|
815
|
+
{ displayName: 'Include Raw EXIF', name: 'includeRawExif', type: 'boolean', default: false, description: 'Include raw EXIF data (metadata tool).' },
|
|
816
|
+
{ displayName: 'Palette Size', name: 'paletteSize', type: 'number', default: 5, description: 'Number of colors to extract (palette tool).' },
|
|
817
|
+
{
|
|
818
|
+
displayName: 'Hash Type',
|
|
819
|
+
name: 'hashType',
|
|
820
|
+
type: 'options',
|
|
821
|
+
default: 'phash',
|
|
822
|
+
description: 'Hash algorithm to compute (hash tool).',
|
|
823
|
+
options: [
|
|
824
|
+
{ name: 'pHash', value: 'phash' },
|
|
825
|
+
{ name: 'MD5', value: 'md5' },
|
|
826
|
+
{ name: 'SHA1', value: 'sha1' },
|
|
827
|
+
],
|
|
828
|
+
},
|
|
829
|
+
{ displayName: 'Similarity Mode', name: 'similarityMode', type: 'string', default: '', description: 'Similarity mode (similarity tool).' },
|
|
830
|
+
{ displayName: 'Similarity Threshold', name: 'similarityThreshold', type: 'number', default: 0, description: 'Similarity threshold (similarity tool).' },
|
|
831
|
+
{ displayName: 'Quality Sample', name: 'qualitySample', type: 'number', default: 0, description: 'Sample size for quality analysis (quality tool).' },
|
|
832
|
+
{ displayName: 'Transparency Sample', name: 'transparencySample', type: 'number', default: 0, description: 'Sample size for transparency analysis (transparency tool).' },
|
|
833
|
+
{ displayName: 'Efficiency Format', name: 'efficiencyFormat', type: 'string', default: '', description: 'Output format for efficiency tool.' },
|
|
834
|
+
{ displayName: 'Efficiency Quality', name: 'efficiencyQuality', type: 'number', default: 0, description: 'Quality setting for efficiency tool.' },
|
|
844
835
|
],
|
|
845
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['hash'] } },
|
|
846
|
-
},
|
|
847
|
-
{
|
|
848
|
-
displayName: 'Quality Sample',
|
|
849
|
-
name: 'qualitySample',
|
|
850
|
-
type: 'number',
|
|
851
|
-
default: 0,
|
|
852
|
-
displayOptions: { show: { resource: ['tools'], operation: ['single'], tool: ['quality'] } },
|
|
853
|
-
},
|
|
854
|
-
{
|
|
855
|
-
displayName: 'Quality Sample',
|
|
856
|
-
name: 'multiQualitySample',
|
|
857
|
-
type: 'number',
|
|
858
|
-
default: 0,
|
|
859
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['quality'] } },
|
|
860
|
-
},
|
|
861
|
-
{
|
|
862
|
-
displayName: 'Transparency Sample',
|
|
863
|
-
name: 'transparencySample',
|
|
864
|
-
type: 'number',
|
|
865
|
-
default: 0,
|
|
866
|
-
displayOptions: { show: { resource: ['tools'], operation: ['single'], tool: ['transparency'] } },
|
|
867
|
-
},
|
|
868
|
-
{
|
|
869
|
-
displayName: 'Transparency Sample',
|
|
870
|
-
name: 'multiTransparencySample',
|
|
871
|
-
type: 'number',
|
|
872
|
-
default: 0,
|
|
873
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['transparency'] } },
|
|
874
|
-
},
|
|
875
|
-
{
|
|
876
|
-
displayName: 'Similarity Mode',
|
|
877
|
-
name: 'similarityMode',
|
|
878
|
-
type: 'string',
|
|
879
|
-
default: '',
|
|
880
|
-
displayOptions: { show: { resource: ['tools'], operation: ['single'], tool: ['similarity'] } },
|
|
881
|
-
},
|
|
882
|
-
{
|
|
883
|
-
displayName: 'Similarity Mode',
|
|
884
|
-
name: 'multiSimilarityMode',
|
|
885
|
-
type: 'string',
|
|
886
|
-
default: '',
|
|
887
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['similarity'] } },
|
|
888
|
-
},
|
|
889
|
-
{
|
|
890
|
-
displayName: 'Similarity Threshold',
|
|
891
|
-
name: 'similarityThreshold',
|
|
892
|
-
type: 'number',
|
|
893
|
-
default: 0,
|
|
894
|
-
displayOptions: { show: { resource: ['tools'], operation: ['single'], tool: ['similarity'] } },
|
|
895
|
-
},
|
|
896
|
-
{
|
|
897
|
-
displayName: 'Similarity Threshold',
|
|
898
|
-
name: 'multiSimilarityThreshold',
|
|
899
|
-
type: 'number',
|
|
900
|
-
default: 0,
|
|
901
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['similarity'] } },
|
|
902
|
-
},
|
|
903
|
-
{
|
|
904
|
-
displayName: 'Efficiency Format',
|
|
905
|
-
name: 'efficiencyFormat',
|
|
906
|
-
type: 'string',
|
|
907
|
-
default: '',
|
|
908
|
-
displayOptions: { show: { resource: ['tools'], operation: ['single'], tool: ['efficiency'] } },
|
|
909
|
-
},
|
|
910
|
-
{
|
|
911
|
-
displayName: 'Efficiency Format',
|
|
912
|
-
name: 'multiEfficiencyFormat',
|
|
913
|
-
type: 'string',
|
|
914
|
-
default: '',
|
|
915
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['efficiency'] } },
|
|
916
|
-
},
|
|
917
|
-
{
|
|
918
|
-
displayName: 'Efficiency Quality',
|
|
919
|
-
name: 'efficiencyQuality',
|
|
920
|
-
type: 'number',
|
|
921
|
-
default: 0,
|
|
922
|
-
displayOptions: { show: { resource: ['tools'], operation: ['single'], tool: ['efficiency'] } },
|
|
923
|
-
},
|
|
924
|
-
{
|
|
925
|
-
displayName: 'Efficiency Quality',
|
|
926
|
-
name: 'multiEfficiencyQuality',
|
|
927
|
-
type: 'number',
|
|
928
|
-
default: 0,
|
|
929
|
-
displayOptions: { show: { resource: ['tools'], operation: ['multitask'], tools: ['efficiency'] } },
|
|
930
836
|
},
|
|
931
837
|
],
|
|
932
838
|
};
|
|
@@ -1159,93 +1065,108 @@ class DavixH2I {
|
|
|
1159
1065
|
setBool('includeRawExif', this.getNodeParameter('includeRawExif', itemIndex));
|
|
1160
1066
|
break;
|
|
1161
1067
|
case 'multitask': {
|
|
1162
|
-
const options = this.getNodeParameter('
|
|
1163
|
-
const
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
setNumber('
|
|
1177
|
-
|
|
1178
|
-
setNumber('
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
setNumber('
|
|
1215
|
-
|
|
1216
|
-
setNumber('
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
if (
|
|
1220
|
-
|
|
1221
|
-
if (
|
|
1222
|
-
setNumber('
|
|
1223
|
-
if (
|
|
1224
|
-
setString('
|
|
1225
|
-
if (
|
|
1226
|
-
setNumber('borderRadius',
|
|
1227
|
-
if (
|
|
1228
|
-
setNumber('
|
|
1229
|
-
if (
|
|
1230
|
-
setString('
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
setNumber('
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
if (
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
formData.
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
if (
|
|
1248
|
-
|
|
1068
|
+
const options = this.getNodeParameter('options', itemIndex, {}) || {};
|
|
1069
|
+
const hasVal = (key) => Object.prototype.hasOwnProperty.call(options, key);
|
|
1070
|
+
const getOpt = (key) => options[key];
|
|
1071
|
+
if (hasVal('format'))
|
|
1072
|
+
setString('format', getOpt('format'));
|
|
1073
|
+
if (hasVal('width'))
|
|
1074
|
+
setNumber('width', Number(getOpt('width')));
|
|
1075
|
+
if (hasVal('height'))
|
|
1076
|
+
setNumber('height', Number(getOpt('height')));
|
|
1077
|
+
if (hasVal('enlarge'))
|
|
1078
|
+
setBool('enlarge', Boolean(getOpt('enlarge')));
|
|
1079
|
+
if (hasVal('normalizeOrientation'))
|
|
1080
|
+
setBool('normalizeOrientation', Boolean(getOpt('normalizeOrientation')));
|
|
1081
|
+
if (hasVal('cropX'))
|
|
1082
|
+
setNumber('cropX', Number(getOpt('cropX')));
|
|
1083
|
+
if (hasVal('cropY'))
|
|
1084
|
+
setNumber('cropY', Number(getOpt('cropY')));
|
|
1085
|
+
if (hasVal('cropWidth'))
|
|
1086
|
+
setNumber('cropWidth', Number(getOpt('cropWidth')));
|
|
1087
|
+
if (hasVal('cropHeight'))
|
|
1088
|
+
setNumber('cropHeight', Number(getOpt('cropHeight')));
|
|
1089
|
+
if (hasVal('backgroundColor'))
|
|
1090
|
+
setString('backgroundColor', String(getOpt('backgroundColor')));
|
|
1091
|
+
if (hasVal('rotate'))
|
|
1092
|
+
setNumber('rotate', Number(getOpt('rotate')));
|
|
1093
|
+
if (hasVal('flipH'))
|
|
1094
|
+
setBool('flipH', Boolean(getOpt('flipH')));
|
|
1095
|
+
if (hasVal('flipV'))
|
|
1096
|
+
setBool('flipV', Boolean(getOpt('flipV')));
|
|
1097
|
+
if (hasVal('colorSpace'))
|
|
1098
|
+
formData.colorSpace = String(getOpt('colorSpace'));
|
|
1099
|
+
if (hasVal('targetSizeKB'))
|
|
1100
|
+
setNumber('targetSizeKB', Number(getOpt('targetSizeKB')));
|
|
1101
|
+
if (hasVal('quality'))
|
|
1102
|
+
setNumber('quality', Number(getOpt('quality')));
|
|
1103
|
+
if (hasVal('keepMetadata'))
|
|
1104
|
+
setBool('keepMetadata', Boolean(getOpt('keepMetadata')));
|
|
1105
|
+
if (hasVal('blur'))
|
|
1106
|
+
setNumber('blur', Number(getOpt('blur')));
|
|
1107
|
+
if (hasVal('sharpen'))
|
|
1108
|
+
setNumber('sharpen', Number(getOpt('sharpen')));
|
|
1109
|
+
if (hasVal('grayscale'))
|
|
1110
|
+
setBool('grayscale', Boolean(getOpt('grayscale')));
|
|
1111
|
+
if (hasVal('sepia'))
|
|
1112
|
+
setBool('sepia', Boolean(getOpt('sepia')));
|
|
1113
|
+
if (hasVal('brightness'))
|
|
1114
|
+
setNumber('brightness', Number(getOpt('brightness')));
|
|
1115
|
+
if (hasVal('contrast'))
|
|
1116
|
+
setNumber('contrast', Number(getOpt('contrast')));
|
|
1117
|
+
if (hasVal('saturation'))
|
|
1118
|
+
setNumber('saturation', Number(getOpt('saturation')));
|
|
1119
|
+
if (hasVal('pad'))
|
|
1120
|
+
setNumber('pad', Number(getOpt('pad')));
|
|
1121
|
+
if (hasVal('padTop'))
|
|
1122
|
+
setNumber('padTop', Number(getOpt('padTop')));
|
|
1123
|
+
if (hasVal('padRight'))
|
|
1124
|
+
setNumber('padRight', Number(getOpt('padRight')));
|
|
1125
|
+
if (hasVal('padBottom'))
|
|
1126
|
+
setNumber('padBottom', Number(getOpt('padBottom')));
|
|
1127
|
+
if (hasVal('padLeft'))
|
|
1128
|
+
setNumber('padLeft', Number(getOpt('padLeft')));
|
|
1129
|
+
if (hasVal('padColor'))
|
|
1130
|
+
setString('padColor', String(getOpt('padColor')));
|
|
1131
|
+
if (hasVal('borderRadius'))
|
|
1132
|
+
setNumber('borderRadius', Number(getOpt('borderRadius')));
|
|
1133
|
+
if (hasVal('border'))
|
|
1134
|
+
setNumber('border', Number(getOpt('border')));
|
|
1135
|
+
if (hasVal('borderColor'))
|
|
1136
|
+
setString('borderColor', String(getOpt('borderColor')));
|
|
1137
|
+
if (hasVal('backgroundBlur'))
|
|
1138
|
+
setNumber('backgroundBlur', Number(getOpt('backgroundBlur')));
|
|
1139
|
+
if (hasVal('watermarkText'))
|
|
1140
|
+
setString('watermarkText', String(getOpt('watermarkText')));
|
|
1141
|
+
if (hasVal('watermarkFontSize'))
|
|
1142
|
+
setNumber('watermarkFontSize', Number(getOpt('watermarkFontSize')));
|
|
1143
|
+
if (hasVal('watermarkColor'))
|
|
1144
|
+
setString('watermarkColor', String(getOpt('watermarkColor')));
|
|
1145
|
+
if (hasVal('watermarkOpacity'))
|
|
1146
|
+
setNumber('watermarkOpacity', Number(getOpt('watermarkOpacity')));
|
|
1147
|
+
if (hasVal('watermarkPosition'))
|
|
1148
|
+
formData.watermarkPosition = String(getOpt('watermarkPosition'));
|
|
1149
|
+
if (hasVal('watermarkMargin'))
|
|
1150
|
+
setNumber('watermarkMargin', Number(getOpt('watermarkMargin')));
|
|
1151
|
+
if (hasVal('watermarkScale'))
|
|
1152
|
+
setNumber('watermarkScale', Number(getOpt('watermarkScale')));
|
|
1153
|
+
if (hasVal('pdfMode'))
|
|
1154
|
+
formData.pdfMode = String(getOpt('pdfMode'));
|
|
1155
|
+
if (hasVal('pdfPageSize'))
|
|
1156
|
+
formData.pdfPageSize = String(getOpt('pdfPageSize'));
|
|
1157
|
+
if (hasVal('pdfOrientation'))
|
|
1158
|
+
formData.pdfOrientation = String(getOpt('pdfOrientation'));
|
|
1159
|
+
if (hasVal('pdfMargin'))
|
|
1160
|
+
setNumber('pdfMargin', Number(getOpt('pdfMargin')));
|
|
1161
|
+
if (hasVal('pdfEmbedFormat'))
|
|
1162
|
+
formData.pdfEmbedFormat = String(getOpt('pdfEmbedFormat'));
|
|
1163
|
+
if (hasVal('pdfJpegQuality'))
|
|
1164
|
+
setNumber('pdfJpegQuality', Number(getOpt('pdfJpegQuality')));
|
|
1165
|
+
if (hasVal('includeRawExif'))
|
|
1166
|
+
setBool('includeRawExif', Boolean(getOpt('includeRawExif')));
|
|
1167
|
+
const watermarkProp = this.getNodeParameter('watermarkBinaryProperty', itemIndex, '');
|
|
1168
|
+
if (watermarkProp)
|
|
1169
|
+
await includeWatermarkFile(watermarkProp);
|
|
1249
1170
|
break;
|
|
1250
1171
|
}
|
|
1251
1172
|
}
|
|
@@ -1402,56 +1323,41 @@ class DavixH2I {
|
|
|
1402
1323
|
selectedTools = tools;
|
|
1403
1324
|
formData.tools = tools.join(',');
|
|
1404
1325
|
}
|
|
1326
|
+
const toolOptions = this.getNodeParameter('options', itemIndex, {}) || {};
|
|
1327
|
+
const hasOpt = (key) => Object.prototype.hasOwnProperty.call(toolOptions, key);
|
|
1328
|
+
const getOpt = (key) => toolOptions[key];
|
|
1405
1329
|
const hasTool = (toolName) => selectedTools.includes(toolName);
|
|
1406
1330
|
if (hasTool('metadata')) {
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
: this.getNodeParameter('multiIncludeRawExif', itemIndex);
|
|
1410
|
-
setBool('includeRawExif', val);
|
|
1331
|
+
if (hasOpt('includeRawExif'))
|
|
1332
|
+
setBool('includeRawExif', Boolean(getOpt('includeRawExif')));
|
|
1411
1333
|
}
|
|
1412
1334
|
if (hasTool('palette')) {
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
: this.getNodeParameter('multiPaletteSize', itemIndex);
|
|
1416
|
-
setNumber('paletteSize', val);
|
|
1335
|
+
if (hasOpt('paletteSize'))
|
|
1336
|
+
setNumber('paletteSize', Number(getOpt('paletteSize')));
|
|
1417
1337
|
}
|
|
1418
1338
|
if (hasTool('hash')) {
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
: this.getNodeParameter('multiHashType', itemIndex);
|
|
1422
|
-
setString('hashType', val);
|
|
1339
|
+
if (hasOpt('hashType'))
|
|
1340
|
+
setString('hashType', String(getOpt('hashType')));
|
|
1423
1341
|
}
|
|
1424
1342
|
if (hasTool('quality')) {
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
: this.getNodeParameter('multiQualitySample', itemIndex);
|
|
1428
|
-
setNumber('qualitySample', val);
|
|
1343
|
+
if (hasOpt('qualitySample'))
|
|
1344
|
+
setNumber('qualitySample', Number(getOpt('qualitySample')));
|
|
1429
1345
|
}
|
|
1430
1346
|
if (hasTool('transparency')) {
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
: this.getNodeParameter('multiTransparencySample', itemIndex);
|
|
1434
|
-
setNumber('transparencySample', val);
|
|
1347
|
+
if (hasOpt('transparencySample'))
|
|
1348
|
+
setNumber('transparencySample', Number(getOpt('transparencySample')));
|
|
1435
1349
|
}
|
|
1436
1350
|
if (hasTool('similarity')) {
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
? this.getNodeParameter('similarityThreshold', itemIndex)
|
|
1442
|
-
: this.getNodeParameter('multiSimilarityThreshold', itemIndex);
|
|
1443
|
-
setString('similarityMode', mode);
|
|
1444
|
-
setNumber('similarityThreshold', threshold);
|
|
1351
|
+
if (hasOpt('similarityMode'))
|
|
1352
|
+
setString('similarityMode', String(getOpt('similarityMode')));
|
|
1353
|
+
if (hasOpt('similarityThreshold'))
|
|
1354
|
+
setNumber('similarityThreshold', Number(getOpt('similarityThreshold')));
|
|
1445
1355
|
}
|
|
1446
1356
|
if (hasTool('efficiency')) {
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
? this.getNodeParameter('efficiencyQuality', itemIndex)
|
|
1452
|
-
: this.getNodeParameter('multiEfficiencyQuality', itemIndex);
|
|
1453
|
-
setString('efficiencyFormat', format);
|
|
1454
|
-
setNumber('efficiencyQuality', quality);
|
|
1357
|
+
if (hasOpt('efficiencyFormat'))
|
|
1358
|
+
setString('efficiencyFormat', String(getOpt('efficiencyFormat')));
|
|
1359
|
+
if (hasOpt('efficiencyQuality'))
|
|
1360
|
+
setNumber('efficiencyQuality', Number(getOpt('efficiencyQuality')));
|
|
1455
1361
|
}
|
|
1456
1362
|
const response = await GenericFunctions_1.davixRequest.call(this, {
|
|
1457
1363
|
method: 'POST',
|