@tehw0lf/n8n-nodes-toon 1.0.1

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.
@@ -0,0 +1,300 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || (function () {
19
+ var ownKeys = function(o) {
20
+ ownKeys = Object.getOwnPropertyNames || function (o) {
21
+ var ar = [];
22
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
23
+ return ar;
24
+ };
25
+ return ownKeys(o);
26
+ };
27
+ return function (mod) {
28
+ if (mod && mod.__esModule) return mod;
29
+ var result = {};
30
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
31
+ __setModuleDefault(result, mod);
32
+ return result;
33
+ };
34
+ })();
35
+ Object.defineProperty(exports, "__esModule", { value: true });
36
+ exports.Toon = void 0;
37
+ const n8n_workflow_1 = require("n8n-workflow");
38
+ const ToonEncoder_1 = require("./ToonEncoder");
39
+ const ToonDecoder_1 = require("./ToonDecoder");
40
+ const utils = __importStar(require("./ToonUtils"));
41
+ class Toon {
42
+ constructor() {
43
+ this.description = {
44
+ displayName: 'TOON',
45
+ name: 'toon',
46
+ icon: 'file:toon.svg',
47
+ group: ['transform'],
48
+ version: 1,
49
+ description: 'Convert between TOON and JSON formats with zero external dependencies',
50
+ defaults: {
51
+ name: 'TOON',
52
+ },
53
+ inputs: [n8n_workflow_1.NodeConnectionTypes.Main],
54
+ outputs: [n8n_workflow_1.NodeConnectionTypes.Main],
55
+ properties: [
56
+ {
57
+ displayName: 'Operation',
58
+ name: 'operation',
59
+ type: 'options',
60
+ noDataExpression: true,
61
+ options: [
62
+ {
63
+ name: 'JSON to TOON',
64
+ value: 'jsonToToon',
65
+ description: 'Convert JSON data to TOON format',
66
+ action: 'Convert JSON to TOON',
67
+ },
68
+ {
69
+ name: 'TOON to JSON',
70
+ value: 'toonToJson',
71
+ description: 'Parse TOON format to JSON',
72
+ action: 'Convert TOON to JSON',
73
+ },
74
+ ],
75
+ default: 'jsonToToon',
76
+ },
77
+ {
78
+ displayName: 'Indent Size',
79
+ name: 'indent',
80
+ type: 'number',
81
+ default: 2,
82
+ description: 'Number of spaces per indentation level',
83
+ displayOptions: {
84
+ show: {
85
+ operation: ['jsonToToon'],
86
+ },
87
+ },
88
+ },
89
+ {
90
+ displayName: 'Delimiter',
91
+ name: 'delimiter',
92
+ type: 'options',
93
+ options: [
94
+ { name: 'Comma (,)', value: 'comma' },
95
+ { name: 'Tab', value: 'tab' },
96
+ { name: 'Pipe (|)', value: 'pipe' },
97
+ ],
98
+ default: 'comma',
99
+ description: 'Delimiter for array values',
100
+ displayOptions: {
101
+ show: {
102
+ operation: ['jsonToToon'],
103
+ },
104
+ },
105
+ },
106
+ {
107
+ displayName: 'Key Folding',
108
+ name: 'keyFolding',
109
+ type: 'options',
110
+ options: [
111
+ { name: 'Off', value: 'off' },
112
+ { name: 'Safe', value: 'safe' },
113
+ ],
114
+ default: 'off',
115
+ description: 'Collapse single-key object chains into dotted paths (e.g., "a.b.c")',
116
+ displayOptions: {
117
+ show: {
118
+ operation: ['jsonToToon'],
119
+ },
120
+ },
121
+ },
122
+ {
123
+ displayName: 'Flatten Depth',
124
+ name: 'flattenDepth',
125
+ type: 'number',
126
+ default: 999,
127
+ description: 'Maximum number of segments to fold (use 999 for unlimited)',
128
+ displayOptions: {
129
+ show: {
130
+ operation: ['jsonToToon'],
131
+ keyFolding: ['safe'],
132
+ },
133
+ },
134
+ },
135
+ {
136
+ displayName: 'Expected Indent Size',
137
+ name: 'indent',
138
+ type: 'number',
139
+ default: 2,
140
+ description: 'Expected indentation size for validation',
141
+ displayOptions: {
142
+ show: {
143
+ operation: ['toonToJson'],
144
+ },
145
+ },
146
+ },
147
+ {
148
+ displayName: 'Strict Mode',
149
+ name: 'strict',
150
+ type: 'boolean',
151
+ default: true,
152
+ description: 'Whether to enforce array counts, indentation multiples, and validation rules',
153
+ displayOptions: {
154
+ show: {
155
+ operation: ['toonToJson'],
156
+ },
157
+ },
158
+ },
159
+ {
160
+ displayName: 'Expand Paths',
161
+ name: 'expandPaths',
162
+ type: 'options',
163
+ options: [
164
+ { name: 'Off', value: 'off' },
165
+ { name: 'Safe', value: 'safe' },
166
+ ],
167
+ default: 'off',
168
+ description: 'Split dotted keys into nested objects (e.g., "a.b.c" → {a: {b: {c: ...}}})',
169
+ displayOptions: {
170
+ show: {
171
+ operation: ['toonToJson'],
172
+ },
173
+ },
174
+ },
175
+ {
176
+ displayName: 'Input Mode',
177
+ name: 'inputMode',
178
+ type: 'options',
179
+ options: [
180
+ { name: 'Field', value: 'field' },
181
+ { name: 'Entire JSON', value: 'json' },
182
+ ],
183
+ default: 'field',
184
+ description: 'Whether to use a specific field or the entire JSON object',
185
+ },
186
+ {
187
+ displayName: 'Input Field',
188
+ name: 'inputField',
189
+ type: 'string',
190
+ default: 'data',
191
+ description: 'Field containing input data (string for TOON, object for JSON)',
192
+ displayOptions: {
193
+ show: {
194
+ inputMode: ['field'],
195
+ },
196
+ },
197
+ },
198
+ {
199
+ displayName: 'Output Field',
200
+ name: 'outputField',
201
+ type: 'string',
202
+ default: 'data',
203
+ description: 'Field name to store the converted output',
204
+ },
205
+ ],
206
+ usableAsTool: true,
207
+ };
208
+ }
209
+ async execute() {
210
+ const items = this.getInputData();
211
+ const returnData = [];
212
+ const operation = this.getNodeParameter('operation', 0);
213
+ for (let itemIndex = 0; itemIndex < items.length; itemIndex++) {
214
+ try {
215
+ const inputMode = this.getNodeParameter('inputMode', itemIndex);
216
+ const outputField = this.getNodeParameter('outputField', itemIndex);
217
+ let inputData;
218
+ if (inputMode === 'json') {
219
+ inputData = items[itemIndex].json;
220
+ }
221
+ else {
222
+ const inputField = this.getNodeParameter('inputField', itemIndex);
223
+ inputData = items[itemIndex].json[inputField];
224
+ }
225
+ let result;
226
+ switch (operation) {
227
+ case 'jsonToToon':
228
+ result = convertJsonToToon.call(this, inputData, itemIndex);
229
+ break;
230
+ case 'toonToJson':
231
+ result = convertToonToJson.call(this, inputData, itemIndex);
232
+ break;
233
+ default:
234
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), `Unknown operation: ${operation}`, { itemIndex });
235
+ }
236
+ returnData.push({
237
+ json: {
238
+ ...items[itemIndex].json,
239
+ [outputField]: result,
240
+ },
241
+ pairedItem: { item: itemIndex },
242
+ });
243
+ }
244
+ catch (error) {
245
+ if (this.continueOnFail()) {
246
+ returnData.push({
247
+ json: {
248
+ error: error.message,
249
+ itemIndex,
250
+ },
251
+ pairedItem: { item: itemIndex },
252
+ });
253
+ }
254
+ else {
255
+ if (error.context) {
256
+ error.context.itemIndex = itemIndex;
257
+ throw error;
258
+ }
259
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), error, {
260
+ itemIndex,
261
+ });
262
+ }
263
+ }
264
+ }
265
+ return [returnData];
266
+ }
267
+ }
268
+ exports.Toon = Toon;
269
+ function convertJsonToToon(data, itemIndex) {
270
+ const indent = this.getNodeParameter('indent', itemIndex);
271
+ const delimiterOption = this.getNodeParameter('delimiter', itemIndex);
272
+ const keyFolding = this.getNodeParameter('keyFolding', itemIndex);
273
+ const flattenDepth = keyFolding === 'safe'
274
+ ? this.getNodeParameter('flattenDepth', itemIndex)
275
+ : Infinity;
276
+ const options = {
277
+ indent,
278
+ delimiter: utils.getDelimiterChar(delimiterOption),
279
+ keyFolding,
280
+ flattenDepth: flattenDepth === 999 ? Infinity : flattenDepth,
281
+ };
282
+ const encoder = new ToonEncoder_1.ToonEncoder(options);
283
+ return encoder.encode(data);
284
+ }
285
+ function convertToonToJson(toonText, itemIndex) {
286
+ if (typeof toonText !== 'string') {
287
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), 'Input must be a string for TOON to JSON conversion', { itemIndex });
288
+ }
289
+ const indent = this.getNodeParameter('indent', itemIndex);
290
+ const strict = this.getNodeParameter('strict', itemIndex);
291
+ const expandPaths = this.getNodeParameter('expandPaths', itemIndex);
292
+ const options = {
293
+ indent,
294
+ strict,
295
+ expandPaths,
296
+ };
297
+ const decoder = new ToonDecoder_1.ToonDecoder(options);
298
+ return decoder.decode(toonText);
299
+ }
300
+ //# sourceMappingURL=Toon.node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Toon.node.js","sourceRoot":"","sources":["../../../nodes/Toon/Toon.node.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAWA,+CAAuE;AAEvE,+CAA4C;AAC5C,+CAA4C;AAC5C,mDAAqC;AAGrC,MAAa,IAAI;IAAjB;QACC,gBAAW,GAAyB;YACnC,WAAW,EAAE,MAAM;YACnB,IAAI,EAAE,MAAM;YACZ,IAAI,EAAE,eAAe;YACrB,KAAK,EAAE,CAAC,WAAW,CAAC;YACpB,OAAO,EAAE,CAAC;YACV,WAAW,EAAE,uEAAuE;YACpF,QAAQ,EAAE;gBACT,IAAI,EAAE,MAAM;aACZ;YACD,MAAM,EAAE,CAAC,kCAAmB,CAAC,IAAI,CAAC;YAClC,OAAO,EAAE,CAAC,kCAAmB,CAAC,IAAI,CAAC;YACnC,UAAU,EAAE;gBACX;oBACC,WAAW,EAAE,WAAW;oBACxB,IAAI,EAAE,WAAW;oBACjB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M,IAAI,iCAAkB,CAC3B,IAAI,CAAC,OAAO,EAAE,EACd,oDAAoD,EACpD,EAAE,SAAS,EAAE,CACb,CAAC;IACH,CAAC;IAED,MAAM,MAAM,GAAG,IAAI,CAAC,gBAAgB,CAAC,QAAQ,EAAE,SAAS,CAAW,CAAC;IACpE,MAAM,MAAM,GAAG,IAAI,CAAC,gBAAgB,CAAC,QAAQ,EAAE,SAAS,CAAY,CAAC;IACrE,MAAM,WAAW,GAAG,IAAI,CAAC,gBAAgB,CAAC,aAAa,EAAE,SAAS,CAAmB,CAAC;IAEtF,MAAM,OAAO,GAAmB;QAC/B,MAAM;QACN,MAAM;QACN,WAAW;KACX,CAAC;IAEF,MAAM,OAAO,GAAG,IAAI,yBAAW,CAAC,OAAO,CAAC,CAAC;IACzC,OAAO,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;AACjC,CAAC"}
@@ -0,0 +1,15 @@
1
+ {
2
+ "node": "n8n-nodes-toon",
3
+ "nodeVersion": "1.0",
4
+ "codexVersion": "1.0",
5
+ "categories": ["Development", "Data & Storage"],
6
+ "resources": {
7
+ "credentialDocumentation": [],
8
+ "primaryDocumentation": [
9
+ {
10
+ "url": "https://github.com/tehw0lf/n8n-nodes-toon#readme"
11
+ }
12
+ ]
13
+ },
14
+ "alias": ["JSON", "Data Format", "Conversion"]
15
+ }
@@ -0,0 +1,19 @@
1
+ import type { DecoderOptions } from './types';
2
+ export declare class ToonDecoder {
3
+ private options;
4
+ constructor(options: DecoderOptions);
5
+ decode(toonText: string): unknown;
6
+ private parseLines;
7
+ private determineRootForm;
8
+ private parseArrayHeader;
9
+ private parseDelimitedTokens;
10
+ private parseArray;
11
+ private parseTabularArray;
12
+ private parseObject;
13
+ private findUnquotedColon;
14
+ private findNextSiblingIndex;
15
+ private parseTokenValue;
16
+ private expandPaths;
17
+ private isExpandable;
18
+ private deepSet;
19
+ }