feat(core): Improvements/overhaul for nodes working with binary data (#7651)

Github issue / Community forum post (link here to close automatically):

---------

Co-authored-by: Giulio Andreini <andreini@netseven.it>
Co-authored-by: Marcus <marcus@n8n.io>
This commit is contained in:
Michael Kret
2024-01-03 13:08:16 +02:00
committed by GitHub
parent 259323b97e
commit 5e16dd4ab4
119 changed files with 4477 additions and 1201 deletions

View File

@@ -42,6 +42,7 @@ encodeDecodeOptions.sort((a, b) => {
export class MoveBinaryData implements INodeType {
description: INodeTypeDescription = {
hidden: true,
displayName: 'Convert to/from binary data',
name: 'moveBinaryData',
icon: 'fa:exchange-alt',
@@ -179,6 +180,20 @@ export class MoveBinaryData implements INodeType {
placeholder: 'Add Option',
default: {},
options: [
{
displayName: 'Add Byte Order Mark (BOM)',
name: 'addBOM',
description:
'Whether to add special marker at the start of your text file. This marker helps some programs understand how to read the file correctly.',
displayOptions: {
show: {
'/mode': ['jsonToBinary'],
encoding: bomAware,
},
},
type: 'boolean',
default: false,
},
{
displayName: 'Data Is Base64',
name: 'dataIsBase64',
@@ -206,7 +221,7 @@ export class MoveBinaryData implements INodeType {
},
},
default: 'utf8',
description: 'Set the encoding of the data stream',
description: 'Choose the character set to use to encode the data',
},
{
displayName: 'Strip BOM',
@@ -220,18 +235,6 @@ export class MoveBinaryData implements INodeType {
type: 'boolean',
default: true,
},
{
displayName: 'Add BOM',
name: 'addBOM',
displayOptions: {
show: {
'/mode': ['jsonToBinary'],
encoding: bomAware,
},
},
type: 'boolean',
default: false,
},
{
displayName: 'File Name',
name: 'fileName',