mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-26 21:19:43 -08:00
675ec21d33
- Split Items List node into separate nodes per action - Review node descriptions - New icons - New sections in subcategories --------- Co-authored-by: Giulio Andreini <andreini@netseven.it> Co-authored-by: Deborah <deborah@starfallprojects.co.uk> Co-authored-by: Michael Kret <michael.k@radency.com>
33 lines
1.1 KiB
TypeScript
33 lines
1.1 KiB
TypeScript
import type { INodeTypeBaseDescription, IVersionedNodeType } from 'n8n-workflow';
|
|
import { VersionedNodeType } from 'n8n-workflow';
|
|
|
|
import { ItemListsV1 } from './V1/ItemListsV1.node';
|
|
import { ItemListsV2 } from './V2/ItemListsV2.node';
|
|
import { ItemListsV3 } from './V3/ItemListsV3.node';
|
|
|
|
export class ItemLists extends VersionedNodeType {
|
|
constructor() {
|
|
const baseDescription: INodeTypeBaseDescription = {
|
|
displayName: 'Item Lists',
|
|
name: 'itemLists',
|
|
icon: 'file:itemLists.svg',
|
|
group: ['input'],
|
|
hidden: true,
|
|
subtitle: '={{$parameter["operation"] + ": " + $parameter["resource"]}}',
|
|
description: 'Helper for working with lists of items and transforming arrays',
|
|
defaultVersion: 3.1,
|
|
};
|
|
|
|
const nodeVersions: IVersionedNodeType['nodeVersions'] = {
|
|
1: new ItemListsV1(baseDescription),
|
|
2: new ItemListsV2(baseDescription),
|
|
2.1: new ItemListsV2(baseDescription),
|
|
2.2: new ItemListsV2(baseDescription),
|
|
3: new ItemListsV3(baseDescription),
|
|
3.1: new ItemListsV3(baseDescription),
|
|
};
|
|
|
|
super(nodeVersions, baseDescription);
|
|
}
|
|
}
|