n8n-nodes-craft-daily-notes 1.0.0
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/LICENSE.md +19 -0
- package/README.md +105 -0
- package/dist/credentials/CraftDailyNotesApi.credentials.d.ts +9 -0
- package/dist/credentials/CraftDailyNotesApi.credentials.js +34 -0
- package/dist/credentials/CraftDailyNotesApi.credentials.js.map +1 -0
- package/dist/icons/craft.dark.svg +19 -0
- package/dist/icons/craft.svg +30 -0
- package/dist/nodes/CraftDailyNotes/CraftDailyNotes.node.d.ts +11 -0
- package/dist/nodes/CraftDailyNotes/CraftDailyNotes.node.js +143 -0
- package/dist/nodes/CraftDailyNotes/CraftDailyNotes.node.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/CraftDailyNotes.node.json +22 -0
- package/dist/nodes/CraftDailyNotes/listSearch/getCollections.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/listSearch/getCollections.js +14 -0
- package/dist/nodes/CraftDailyNotes/listSearch/getCollections.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/block/delete.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/block/delete.js +24 -0
- package/dist/nodes/CraftDailyNotes/resources/block/delete.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/block/get.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/block/get.js +127 -0
- package/dist/nodes/CraftDailyNotes/resources/block/get.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/block/index.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/block/index.js +95 -0
- package/dist/nodes/CraftDailyNotes/resources/block/index.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/block/insert.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/block/insert.js +154 -0
- package/dist/nodes/CraftDailyNotes/resources/block/insert.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/block/move.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/block/move.js +80 -0
- package/dist/nodes/CraftDailyNotes/resources/block/move.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/block/search.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/block/search.js +96 -0
- package/dist/nodes/CraftDailyNotes/resources/block/search.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/block/update.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/block/update.js +82 -0
- package/dist/nodes/CraftDailyNotes/resources/block/update.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/addItems.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/addItems.js +34 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/addItems.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/deleteItems.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/deleteItems.js +36 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/deleteItems.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/getItems.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/getItems.js +37 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/getItems.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/getSchema.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/getSchema.js +45 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/getSchema.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/index.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/index.js +101 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/index.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/list.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/list.js +57 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/list.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/updateItems.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/updateItems.js +34 -0
- package/dist/nodes/CraftDailyNotes/resources/collection/updateItems.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/search/index.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/search/index.js +107 -0
- package/dist/nodes/CraftDailyNotes/resources/search/index.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/task/add.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/task/add.js +85 -0
- package/dist/nodes/CraftDailyNotes/resources/task/add.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/task/delete.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/task/delete.js +24 -0
- package/dist/nodes/CraftDailyNotes/resources/task/delete.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/task/get.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/task/get.js +44 -0
- package/dist/nodes/CraftDailyNotes/resources/task/get.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/task/index.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/task/index.js +73 -0
- package/dist/nodes/CraftDailyNotes/resources/task/index.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/resources/task/update.d.ts +2 -0
- package/dist/nodes/CraftDailyNotes/resources/task/update.js +87 -0
- package/dist/nodes/CraftDailyNotes/resources/task/update.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/shared/blockBuilder.d.ts +13 -0
- package/dist/nodes/CraftDailyNotes/shared/blockBuilder.js +121 -0
- package/dist/nodes/CraftDailyNotes/shared/blockBuilder.js.map +1 -0
- package/dist/nodes/CraftDailyNotes/shared/transport.d.ts +3 -0
- package/dist/nodes/CraftDailyNotes/shared/transport.js +50 -0
- package/dist/nodes/CraftDailyNotes/shared/transport.js.map +1 -0
- package/dist/package.json +64 -0
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +64 -0
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.blockDescription = void 0;
|
|
4
|
+
const get_1 = require("./get");
|
|
5
|
+
const insert_1 = require("./insert");
|
|
6
|
+
const update_1 = require("./update");
|
|
7
|
+
const delete_1 = require("./delete");
|
|
8
|
+
const move_1 = require("./move");
|
|
9
|
+
const search_1 = require("./search");
|
|
10
|
+
const showOnlyForBlocks = { resource: ['block'] };
|
|
11
|
+
exports.blockDescription = [
|
|
12
|
+
{
|
|
13
|
+
displayName: 'Operation',
|
|
14
|
+
name: 'operation',
|
|
15
|
+
type: 'options',
|
|
16
|
+
noDataExpression: true,
|
|
17
|
+
displayOptions: { show: showOnlyForBlocks },
|
|
18
|
+
options: [
|
|
19
|
+
{
|
|
20
|
+
name: 'Delete',
|
|
21
|
+
value: 'delete',
|
|
22
|
+
action: 'Delete blocks from a daily note',
|
|
23
|
+
description: 'Delete blocks by their IDs',
|
|
24
|
+
routing: {
|
|
25
|
+
request: {
|
|
26
|
+
method: 'DELETE',
|
|
27
|
+
url: '/blocks',
|
|
28
|
+
},
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
name: 'Get',
|
|
33
|
+
value: 'get',
|
|
34
|
+
action: 'Get blocks from a daily note',
|
|
35
|
+
description: 'Fetch content from daily notes by date or block ID',
|
|
36
|
+
routing: {
|
|
37
|
+
request: {
|
|
38
|
+
method: 'GET',
|
|
39
|
+
url: '/blocks',
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
name: 'Insert',
|
|
45
|
+
value: 'insert',
|
|
46
|
+
action: 'Insert blocks into a daily note',
|
|
47
|
+
description: 'Insert content into a daily note',
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
name: 'Move',
|
|
51
|
+
value: 'move',
|
|
52
|
+
action: 'Move blocks',
|
|
53
|
+
description: 'Move blocks to reorder or move to a different daily note',
|
|
54
|
+
routing: {
|
|
55
|
+
request: {
|
|
56
|
+
method: 'PUT',
|
|
57
|
+
url: '/blocks/move',
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
name: 'Search in Document',
|
|
63
|
+
value: 'searchInDocument',
|
|
64
|
+
action: 'Search in a specific daily note',
|
|
65
|
+
description: 'Search content within a specific daily note using regex',
|
|
66
|
+
routing: {
|
|
67
|
+
request: {
|
|
68
|
+
method: 'GET',
|
|
69
|
+
url: '/blocks/search',
|
|
70
|
+
},
|
|
71
|
+
},
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
name: 'Update',
|
|
75
|
+
value: 'update',
|
|
76
|
+
action: 'Update blocks in a daily note',
|
|
77
|
+
description: 'Update content in daily notes',
|
|
78
|
+
routing: {
|
|
79
|
+
request: {
|
|
80
|
+
method: 'PUT',
|
|
81
|
+
url: '/blocks',
|
|
82
|
+
},
|
|
83
|
+
},
|
|
84
|
+
},
|
|
85
|
+
],
|
|
86
|
+
default: 'get',
|
|
87
|
+
},
|
|
88
|
+
...get_1.blockGetDescription,
|
|
89
|
+
...insert_1.blockInsertDescription,
|
|
90
|
+
...update_1.blockUpdateDescription,
|
|
91
|
+
...delete_1.blockDeleteDescription,
|
|
92
|
+
...move_1.blockMoveDescription,
|
|
93
|
+
...search_1.blockSearchDescription,
|
|
94
|
+
];
|
|
95
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../nodes/CraftDailyNotes/resources/block/index.ts"],"names":[],"mappings":";;;AAMA,+BAA4C;AAC5C,qCAAkD;AAClD,qCAAkD;AAClD,qCAAkD;AAClD,iCAA8C;AAC9C,qCAAkD;AAElD,MAAM,iBAAiB,GAAG,EAAE,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;AAErC,QAAA,gBAAgB,GAAsB;IAElD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,E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oBACR,OAAO,EAAE;wBACR,MAAM,EAAE,KAAK;wBACb,GAAG,EAAE,SAAS;qBACd;iBACD;aACD;SACD;QACD,OAAO,EAAE,KAAK;KACd;IAGD,GAAG,yBAAmB;IACtB,GAAG,+BAAsB;IACzB,GAAG,+BAAsB;IACzB,GAAG,+BAAsB;IACzB,GAAG,2BAAoB;IACvB,GAAG,+BAAsB;CACzB,CAAC"}
|
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.blockInsertDescription = void 0;
|
|
4
|
+
const showOnlyForBlockInsert = { operation: ['insert'], resource: ['block'] };
|
|
5
|
+
exports.blockInsertDescription = [
|
|
6
|
+
{
|
|
7
|
+
displayName: 'Content Mode',
|
|
8
|
+
name: 'contentMode',
|
|
9
|
+
type: 'options',
|
|
10
|
+
options: [
|
|
11
|
+
{
|
|
12
|
+
name: 'Markdown Text',
|
|
13
|
+
value: 'markdown',
|
|
14
|
+
description: 'Paste any length content - automatically split into optimal blocks',
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
name: 'Block Array (Advanced)',
|
|
18
|
+
value: 'blocks',
|
|
19
|
+
description: 'Provide pre-structured block array in JSON format',
|
|
20
|
+
},
|
|
21
|
+
],
|
|
22
|
+
default: 'markdown',
|
|
23
|
+
displayOptions: { show: showOnlyForBlockInsert },
|
|
24
|
+
description: 'How to provide the content to insert',
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
displayName: 'Markdown Content',
|
|
28
|
+
name: 'markdownContent',
|
|
29
|
+
type: 'string',
|
|
30
|
+
typeOptions: {
|
|
31
|
+
rows: 10,
|
|
32
|
+
},
|
|
33
|
+
default: '',
|
|
34
|
+
placeholder: '# Meeting Notes\n\n- Discussed timeline\n- Assigned tasks\n\nNext steps...',
|
|
35
|
+
description: 'Paste any length of markdown content. The node will automatically split it into optimal blocks while preserving structure.',
|
|
36
|
+
displayOptions: {
|
|
37
|
+
show: {
|
|
38
|
+
...showOnlyForBlockInsert,
|
|
39
|
+
contentMode: ['markdown'],
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
displayName: 'Block Processing Options',
|
|
45
|
+
name: 'blockProcessingOptions',
|
|
46
|
+
type: 'collection',
|
|
47
|
+
placeholder: 'Add Option',
|
|
48
|
+
default: {},
|
|
49
|
+
displayOptions: {
|
|
50
|
+
show: {
|
|
51
|
+
...showOnlyForBlockInsert,
|
|
52
|
+
contentMode: ['markdown'],
|
|
53
|
+
},
|
|
54
|
+
},
|
|
55
|
+
options: [
|
|
56
|
+
{
|
|
57
|
+
displayName: 'Max Block Size',
|
|
58
|
+
name: 'maxBlockSize',
|
|
59
|
+
type: 'number',
|
|
60
|
+
typeOptions: {
|
|
61
|
+
minValue: 1000,
|
|
62
|
+
maxValue: 10000,
|
|
63
|
+
},
|
|
64
|
+
default: 5000,
|
|
65
|
+
description: 'Maximum character count per block before splitting',
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
displayName: 'Preserve Headers',
|
|
69
|
+
name: 'preserveHeaders',
|
|
70
|
+
type: 'boolean',
|
|
71
|
+
default: true,
|
|
72
|
+
description: 'Whether to keep headers as separate blocks with proper text style',
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
displayName: 'Split on Paragraphs',
|
|
76
|
+
name: 'splitOnParagraphs',
|
|
77
|
+
type: 'boolean',
|
|
78
|
+
default: true,
|
|
79
|
+
description: 'Whether to split content on paragraph breaks (double newlines)',
|
|
80
|
+
},
|
|
81
|
+
],
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
displayName: 'Blocks (JSON)',
|
|
85
|
+
name: 'blocksJson',
|
|
86
|
+
type: 'json',
|
|
87
|
+
default: '[{"type":"text","markdown":"Content here"}]',
|
|
88
|
+
description: 'Pre-structured block array. Each block should have "type" and "markdown" properties.',
|
|
89
|
+
displayOptions: {
|
|
90
|
+
show: {
|
|
91
|
+
...showOnlyForBlockInsert,
|
|
92
|
+
contentMode: ['blocks'],
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
displayName: 'Position',
|
|
98
|
+
name: 'position',
|
|
99
|
+
type: 'fixedCollection',
|
|
100
|
+
default: {},
|
|
101
|
+
placeholder: 'Add Position',
|
|
102
|
+
displayOptions: { show: showOnlyForBlockInsert },
|
|
103
|
+
options: [
|
|
104
|
+
{
|
|
105
|
+
name: 'positionValues',
|
|
106
|
+
displayName: 'Position',
|
|
107
|
+
values: [
|
|
108
|
+
{
|
|
109
|
+
displayName: 'Position Type',
|
|
110
|
+
name: 'position',
|
|
111
|
+
type: 'options',
|
|
112
|
+
options: [
|
|
113
|
+
{ name: 'End', value: 'end', description: 'Insert at the end of the document' },
|
|
114
|
+
{
|
|
115
|
+
name: 'Start',
|
|
116
|
+
value: 'start',
|
|
117
|
+
description: 'Insert at the start of the document',
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
name: 'Before',
|
|
121
|
+
value: 'before',
|
|
122
|
+
description: 'Insert before a specific block',
|
|
123
|
+
},
|
|
124
|
+
{ name: 'After', value: 'after', description: 'Insert after a specific block' },
|
|
125
|
+
],
|
|
126
|
+
default: 'end',
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
displayName: 'Target Date',
|
|
130
|
+
name: 'date',
|
|
131
|
+
type: 'string',
|
|
132
|
+
default: 'today',
|
|
133
|
+
placeholder: 'today, tomorrow, yesterday, or YYYY-MM-DD',
|
|
134
|
+
description: 'Which daily note to insert into',
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
displayName: 'Reference Block ID',
|
|
138
|
+
name: 'referenceBlockId',
|
|
139
|
+
type: 'string',
|
|
140
|
+
default: '',
|
|
141
|
+
placeholder: 'Block ID (UUID)',
|
|
142
|
+
description: 'The block ID to position relative to (required for before/after)',
|
|
143
|
+
displayOptions: {
|
|
144
|
+
show: {
|
|
145
|
+
position: ['before', 'after'],
|
|
146
|
+
},
|
|
147
|
+
},
|
|
148
|
+
},
|
|
149
|
+
],
|
|
150
|
+
},
|
|
151
|
+
],
|
|
152
|
+
},
|
|
153
|
+
];
|
|
154
|
+
//# sourceMappingURL=insert.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"insert.js","sourceRoot":"","sources":["../../../../../nodes/CraftDailyNotes/resources/block/insert.ts"],"names":[],"mappings":";;;AAOA,MAAM,sBAAsB,GAAG,EAAE,SAAS,EAAE,CAAC,QAAQ,CAAC,EAAE,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;AAEjE,QAAA,sBAAsB,GAAsB;IAExD;QACC,WAAW,EAAE,cAAc;QAC3B,IAAI,EAAE,aAAa;QACnB,IAAI,EAAE,SAAS;QACf,OAAO,EAAE;YACR;gBACC,IAAI,EAAE,eAAe;gBACrB,KAAK,EAAE,UAAU;gBACjB,WAAW,EAAE,oEAAoE;aACjF;YACD;gBACC,IAAI,EAAE,wBAAwB;gBAC9B,KAAK,EAAE,QAAQ;gBACf,WAAW,EAAE,mDAAmD;aAChE;SACD;QACD,OAAO,EAAE,UAAU;QACnB,cAAc,EAAE,EAAE,IAAI,EAAE,sBAAsB,EAAE;QAChD,WAAW,EAAE,sCAAsC;KACnD;IAGD;QACC,WAAW,EAAE,kBAAkB;QAC/B,IAAI,EAAE,iBAAiB;QACvB,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE;YACZ,IAAI,EAAE,EAAE;SACR;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,4EAA4E;QACzF,WAAW,EACV,4HAA4H;QAC7H,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,GAAG,sBAAsB;gBACzB,WAAW,EAAE,CAAC,UAAU,CAAC;aACzB;SACD;KACD;IAGD;QACC,WAAW,EAAE,0BAA0B;QACvC,IAAI,EAAE,wBAAwB;QAC9B,IAAI,EAAE,YAAY;QA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AAE,UAAU;wBAChB,IAAI,EAAE,SAAS;wBACf,OAAO,EAAE;4BACR,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,WAAW,EAAE,mCAAmC,EAAE;4BAC/E;gCACC,IAAI,EAAE,OAAO;gCACb,KAAK,EAAE,OAAO;gCACd,WAAW,EAAE,qCAAqC;6BAClD;4BACD;gCACC,IAAI,EAAE,QAAQ;gCACd,KAAK,EAAE,QAAQ;gCACf,WAAW,EAAE,gCAAgC;6BAC7C;4BACD,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,WAAW,EAAE,+BAA+B,EAAE;yBAC/E;wBACD,OAAO,EAAE,KAAK;qBACd;oBACD;wBACC,WAAW,EAAE,aAAa;wBAC1B,IAAI,EAAE,MAAM;wBACZ,IAAI,EAAE,QAAQ;wBACd,OAAO,EAAE,OAAO;wBAChB,WAAW,EAAE,2CAA2C;wBACxD,WAAW,EAAE,iCAAiC;qBAC9C;oBACD;wBACC,WAAW,EAAE,oBAAoB;wBACjC,IAAI,EAAE,kBAAkB;wBACxB,IAAI,EAAE,QAAQ;wBACd,OAAO,EAAE,EAAE;wBACX,WAAW,EAAE,iBAAiB;wBAC9B,WAAW,EAAE,kEAAkE;wBAC/E,cAAc,EAAE;4BACf,IAAI,EAAE;gCACL,QAAQ,EAAE,CAAC,QAAQ,EAAE,OAAO,CAAC;6BAC7B;yBACD;qBACD;iBACD;aACD;SACD;KACD;CACD,CAAC"}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.blockMoveDescription = void 0;
|
|
4
|
+
const showOnlyForBlockMove = { operation: ['move'], resource: ['block'] };
|
|
5
|
+
exports.blockMoveDescription = [
|
|
6
|
+
{
|
|
7
|
+
displayName: 'Block IDs',
|
|
8
|
+
name: 'blockIds',
|
|
9
|
+
type: 'string',
|
|
10
|
+
default: '',
|
|
11
|
+
required: true,
|
|
12
|
+
placeholder: 'ID1, ID2, ID3 or ["ID1", "ID2"]',
|
|
13
|
+
description: 'Block IDs to move. Provide as comma-separated values or JSON array.',
|
|
14
|
+
displayOptions: { show: showOnlyForBlockMove },
|
|
15
|
+
routing: {
|
|
16
|
+
send: {
|
|
17
|
+
type: 'body',
|
|
18
|
+
property: 'blockIds',
|
|
19
|
+
value: '={{ $value.startsWith("[") ? JSON.parse($value) : $value.split(",").map(id => id.trim()) }}',
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
displayName: 'Position',
|
|
25
|
+
name: 'position',
|
|
26
|
+
type: 'fixedCollection',
|
|
27
|
+
default: {},
|
|
28
|
+
placeholder: 'Add Position',
|
|
29
|
+
displayOptions: { show: showOnlyForBlockMove },
|
|
30
|
+
options: [
|
|
31
|
+
{
|
|
32
|
+
name: 'positionValues',
|
|
33
|
+
displayName: 'Position',
|
|
34
|
+
values: [
|
|
35
|
+
{
|
|
36
|
+
displayName: 'Position Type',
|
|
37
|
+
name: 'position',
|
|
38
|
+
type: 'options',
|
|
39
|
+
options: [
|
|
40
|
+
{ name: 'End', value: 'end', description: 'Move to the end of the document' },
|
|
41
|
+
{ name: 'Start', value: 'start', description: 'Move to the start of the document' },
|
|
42
|
+
{ name: 'Before', value: 'before', description: 'Move before a specific block' },
|
|
43
|
+
{ name: 'After', value: 'after', description: 'Move after a specific block' },
|
|
44
|
+
],
|
|
45
|
+
default: 'end',
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
displayName: 'Target Date',
|
|
49
|
+
name: 'date',
|
|
50
|
+
type: 'string',
|
|
51
|
+
default: 'today',
|
|
52
|
+
placeholder: 'today, tomorrow, yesterday, or YYYY-MM-DD',
|
|
53
|
+
description: 'Which daily note to move the blocks to',
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
displayName: 'Reference Block ID',
|
|
57
|
+
name: 'referenceBlockId',
|
|
58
|
+
type: 'string',
|
|
59
|
+
default: '',
|
|
60
|
+
placeholder: 'Block ID (UUID)',
|
|
61
|
+
description: 'The block ID to position relative to (required for before/after)',
|
|
62
|
+
displayOptions: {
|
|
63
|
+
show: {
|
|
64
|
+
position: ['before', 'after'],
|
|
65
|
+
},
|
|
66
|
+
},
|
|
67
|
+
},
|
|
68
|
+
],
|
|
69
|
+
},
|
|
70
|
+
],
|
|
71
|
+
routing: {
|
|
72
|
+
send: {
|
|
73
|
+
type: 'body',
|
|
74
|
+
property: 'position',
|
|
75
|
+
value: '={{ $value.positionValues ? { position: $value.positionValues.position, date: $value.positionValues.date, ...(["before", "after"].includes($value.positionValues.position) && $value.positionValues.referenceBlockId ? { referenceBlockId: $value.positionValues.referenceBlockId } : {}) } : { position: "end", date: "today" } }}',
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
},
|
|
79
|
+
];
|
|
80
|
+
//# sourceMappingURL=move.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"move.js","sourceRoot":"","sources":["../../../../../nodes/CraftDailyNotes/resources/block/move.ts"],"names":[],"mappings":";;;AAMA,MAAM,oBAAoB,GAAG,EAAE,SAAS,EAAE,CAAC,MAAM,CAAC,EAAE,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;AAE7D,QAAA,oBAAoB,GAAsB;IAEtD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,UAAU;QAChB,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,QAAQ,EAAE,IAAI;QACd,WAAW,EAAE,iCAAiC;QAC9C,WAAW,EAAE,qEAAqE;QAClF,cAAc,EAAE,EAAE,IAAI,EAAE,oBAAoB,EAAE;QAC9C,OAAO,EAAE;YACR,IAAI,EAAE;gBACL,IAAI,EAAE,MAAM;gBACZ,QAAQ,EAAE,UAAU;gBACpB,KAAK,EACJ,6FAA6F;aAC9F;SACD;KACD;IAGD;QACC,WAAW,EAAE,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AAE;gBACL,IAAI,EAAE,MAAM;gBACZ,QAAQ,EAAE,UAAU;gBACpB,KAAK,EACJ,qUAAqU;aACtU;SACD;KACD;CACD,CAAC"}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.blockSearchDescription = void 0;
|
|
4
|
+
const showOnlyForBlockSearch = { operation: ['searchInDocument'], resource: ['block'] };
|
|
5
|
+
exports.blockSearchDescription = [
|
|
6
|
+
{
|
|
7
|
+
displayName: 'Date',
|
|
8
|
+
name: 'date',
|
|
9
|
+
type: 'string',
|
|
10
|
+
default: 'today',
|
|
11
|
+
required: true,
|
|
12
|
+
placeholder: 'today, tomorrow, yesterday, or YYYY-MM-DD',
|
|
13
|
+
description: 'The daily note date to search within',
|
|
14
|
+
displayOptions: { show: showOnlyForBlockSearch },
|
|
15
|
+
routing: {
|
|
16
|
+
send: {
|
|
17
|
+
type: 'query',
|
|
18
|
+
property: 'date',
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
displayName: 'Search Pattern',
|
|
24
|
+
name: 'pattern',
|
|
25
|
+
type: 'string',
|
|
26
|
+
default: '',
|
|
27
|
+
required: true,
|
|
28
|
+
placeholder: 'meeting|agenda',
|
|
29
|
+
description: 'The search pattern. Supports NodeJS regular expressions.',
|
|
30
|
+
displayOptions: { show: showOnlyForBlockSearch },
|
|
31
|
+
routing: {
|
|
32
|
+
send: {
|
|
33
|
+
type: 'query',
|
|
34
|
+
property: 'pattern',
|
|
35
|
+
},
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
displayName: 'Options',
|
|
40
|
+
name: 'searchOptions',
|
|
41
|
+
type: 'collection',
|
|
42
|
+
placeholder: 'Add Option',
|
|
43
|
+
default: {},
|
|
44
|
+
displayOptions: { show: showOnlyForBlockSearch },
|
|
45
|
+
options: [
|
|
46
|
+
{
|
|
47
|
+
displayName: 'Case Sensitive',
|
|
48
|
+
name: 'caseSensitive',
|
|
49
|
+
type: 'boolean',
|
|
50
|
+
default: false,
|
|
51
|
+
description: 'Whether the search should be case sensitive',
|
|
52
|
+
routing: {
|
|
53
|
+
send: {
|
|
54
|
+
type: 'query',
|
|
55
|
+
property: 'caseSensitive',
|
|
56
|
+
},
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
displayName: 'Blocks Before',
|
|
61
|
+
name: 'beforeBlockCount',
|
|
62
|
+
type: 'number',
|
|
63
|
+
typeOptions: {
|
|
64
|
+
minValue: 0,
|
|
65
|
+
maxValue: 5,
|
|
66
|
+
},
|
|
67
|
+
default: 0,
|
|
68
|
+
description: 'Number of blocks to include before each match for context',
|
|
69
|
+
routing: {
|
|
70
|
+
send: {
|
|
71
|
+
type: 'query',
|
|
72
|
+
property: 'beforeBlockCount',
|
|
73
|
+
},
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
displayName: 'Blocks After',
|
|
78
|
+
name: 'afterBlockCount',
|
|
79
|
+
type: 'number',
|
|
80
|
+
typeOptions: {
|
|
81
|
+
minValue: 0,
|
|
82
|
+
maxValue: 5,
|
|
83
|
+
},
|
|
84
|
+
default: 0,
|
|
85
|
+
description: 'Number of blocks to include after each match for context',
|
|
86
|
+
routing: {
|
|
87
|
+
send: {
|
|
88
|
+
type: 'query',
|
|
89
|
+
property: 'afterBlockCount',
|
|
90
|
+
},
|
|
91
|
+
},
|
|
92
|
+
},
|
|
93
|
+
],
|
|
94
|
+
},
|
|
95
|
+
];
|
|
96
|
+
//# sourceMappingURL=search.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"search.js","sourceRoot":"","sources":["../../../../../nodes/CraftDailyNotes/resources/block/search.ts"],"names":[],"mappings":";;;AAMA,MAAM,sBAAsB,GAAG,EAAE,SAAS,EAAE,CAAC,kBAAkB,CAAC,EAAE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AI,EAAE,QAAQ;gBACd,WAAW,EAAE;oBACZ,QAAQ,EAAE,CAAC;oBACX,QAAQ,EAAE,CAAC;iBACX;gBACD,OAAO,EAAE,CAAC;gBACV,WAAW,EAAE,2DAA2D;gBACxE,OAAO,EAAE;oBACR,IAAI,EAAE;wBACL,IAAI,EAAE,OAAO;wBACb,QAAQ,EAAE,kBAAkB;qBAC5B;iBACD;aACD;YACD;gBACC,WAAW,EAAE,cAAc;gBAC3B,IAAI,EAAE,iBAAiB;gBACvB,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE;oBACZ,QAAQ,EAAE,CAAC;oBACX,QAAQ,EAAE,CAAC;iBACX;gBACD,OAAO,EAAE,CAAC;gBACV,WAAW,EAAE,0DAA0D;gBACvE,OAAO,EAAE;oBACR,IAAI,EAAE;wBACL,IAAI,EAAE,OAAO;wBACb,QAAQ,EAAE,iBAAiB;qBAC3B;iBACD;aACD;SACD;KACD;CACD,CAAC"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.blockUpdateDescription = void 0;
|
|
4
|
+
const showOnlyForBlockUpdate = { operation: ['update'], resource: ['block'] };
|
|
5
|
+
exports.blockUpdateDescription = [
|
|
6
|
+
{
|
|
7
|
+
displayName: 'Blocks to Update',
|
|
8
|
+
name: 'blocksToUpdate',
|
|
9
|
+
type: 'fixedCollection',
|
|
10
|
+
typeOptions: {
|
|
11
|
+
multipleValues: true,
|
|
12
|
+
},
|
|
13
|
+
default: {},
|
|
14
|
+
placeholder: 'Add Block',
|
|
15
|
+
displayOptions: { show: showOnlyForBlockUpdate },
|
|
16
|
+
options: [
|
|
17
|
+
{
|
|
18
|
+
name: 'blockValues',
|
|
19
|
+
displayName: 'Block',
|
|
20
|
+
values: [
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Block ID',
|
|
23
|
+
name: 'id',
|
|
24
|
+
type: 'string',
|
|
25
|
+
default: '',
|
|
26
|
+
required: true,
|
|
27
|
+
placeholder: 'E21E3640-FBD2-4887-BD1B-B1FFE1781168',
|
|
28
|
+
description: 'The UUID of the block to update',
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
displayName: 'New Markdown',
|
|
32
|
+
name: 'markdown',
|
|
33
|
+
type: 'string',
|
|
34
|
+
typeOptions: {
|
|
35
|
+
rows: 4,
|
|
36
|
+
},
|
|
37
|
+
default: '',
|
|
38
|
+
description: 'The new markdown content for the block',
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
displayName: 'Text Style',
|
|
42
|
+
name: 'textStyle',
|
|
43
|
+
type: 'options',
|
|
44
|
+
options: [
|
|
45
|
+
{ name: 'Body', value: 'body' },
|
|
46
|
+
{ name: 'Code', value: 'code' },
|
|
47
|
+
{ name: 'Heading 1', value: 'h1' },
|
|
48
|
+
{ name: 'Heading 2', value: 'h2' },
|
|
49
|
+
{ name: 'Heading 3', value: 'h3' },
|
|
50
|
+
{ name: 'Subtitle', value: 'subtitle' },
|
|
51
|
+
{ name: 'Title', value: 'title' },
|
|
52
|
+
],
|
|
53
|
+
default: 'body',
|
|
54
|
+
description: 'The text style for the block (optional)',
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
displayName: 'List Style',
|
|
58
|
+
name: 'listStyle',
|
|
59
|
+
type: 'options',
|
|
60
|
+
options: [
|
|
61
|
+
{ name: 'Bullet', value: 'bullet' },
|
|
62
|
+
{ name: 'None', value: 'none' },
|
|
63
|
+
{ name: 'Numbered', value: 'numbered' },
|
|
64
|
+
{ name: 'Todo', value: 'todo' },
|
|
65
|
+
{ name: 'Toggle', value: 'toggle' },
|
|
66
|
+
],
|
|
67
|
+
default: 'none',
|
|
68
|
+
description: 'The list style for the block (optional)',
|
|
69
|
+
},
|
|
70
|
+
],
|
|
71
|
+
},
|
|
72
|
+
],
|
|
73
|
+
routing: {
|
|
74
|
+
send: {
|
|
75
|
+
type: 'body',
|
|
76
|
+
property: 'blocks',
|
|
77
|
+
value: '={{ $value.blockValues ? $value.blockValues.map(b => { const block = { id: b.id }; if (b.markdown) block.markdown = b.markdown; if (b.textStyle && b.textStyle !== "body") block.textStyle = b.textStyle; if (b.listStyle && b.listStyle !== "none") block.listStyle = b.listStyle; return block; }) : [] }}',
|
|
78
|
+
},
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
];
|
|
82
|
+
//# sourceMappingURL=update.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update.js","sourceRoot":"","sources":["../../../../../nodes/CraftDailyNotes/resources/block/update.ts"],"names":[],"mappings":";;;AAMA,MAAM,sBAAsB,GAAG,EAAE,SAAS,EAAE,CAAC,QAAQ,CAAC,EAAE,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;AAEjE,QAAA,sBAAsB,GAAsB;IAExD;QACC,WAAW,EAAE,kBAAkB;QAC/B,IAAI,EAAE,gBAAgB;QACtB,IAAI,EAAE,iBAAiB;QACvB,WAAW,EAAE;YACZ,cAAc,EAAE,IAAI;SACpB;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,WAAW;QACxB,cAAc,EAAE,EAAE,IAAI,EAAE,sBAAsB,EAAE;QAChD,OAAO,EAAE;YACR;gBACC,IAAI,EAAE,aAAa;gBACnB,WAAW,EAAE,OAAO;gBACpB,MAAM,EAAE;oBACP;wBACC,WAAW,EAAE,UAAU;wBACvB,IAAI,EAAE,IAAI;wBACV,IAAI,EAAE,QAAQ;wBACd,OAAO,EAAE,EAAE;wBACX,QAAQ,EAAE,IAAI;wBACd,WAAW,EAAE,sCAAsC;wBACnD,WAAW,EAAE,iCAAiC;qBAC9C;oBACD;wBACC,WAAW,EAAE,cAAc;wBAC3B,IAAI,EAAE,UAAU;wBAChB,IAAI,EAAE,QAAQ;wBACd,WAAW,EAAE;4BACZ,IAAI,EAAE,CAAC;yBACP;wBACD,OAAO,EAAE,EAAE;wBACX,WAAW,EAAE,wC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D,CAAC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.collectionAddItemsDescription = void 0;
|
|
4
|
+
const showOnlyForCollectionAddItems = { operation: ['addItems'], resource: ['collection'] };
|
|
5
|
+
exports.collectionAddItemsDescription = [
|
|
6
|
+
{
|
|
7
|
+
displayName: 'Collection Name or ID',
|
|
8
|
+
name: 'collectionId',
|
|
9
|
+
type: 'options',
|
|
10
|
+
typeOptions: {
|
|
11
|
+
loadOptionsMethod: 'getCollections',
|
|
12
|
+
},
|
|
13
|
+
default: '',
|
|
14
|
+
required: true,
|
|
15
|
+
description: 'Select a collection from your daily notes. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code/expressions/">expression</a>.',
|
|
16
|
+
displayOptions: { show: showOnlyForCollectionAddItems },
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
displayName: 'Items (JSON)',
|
|
20
|
+
name: 'itemsJson',
|
|
21
|
+
type: 'json',
|
|
22
|
+
default: '{"items": [{"title": "New Item", "properties": {}}]}',
|
|
23
|
+
required: true,
|
|
24
|
+
description: 'Items to add in JSON format. Use "Get Schema" operation first to understand the required structure. Each item needs at least a "title" field.',
|
|
25
|
+
displayOptions: { show: showOnlyForCollectionAddItems },
|
|
26
|
+
routing: {
|
|
27
|
+
send: {
|
|
28
|
+
type: 'body',
|
|
29
|
+
value: '={{ JSON.parse($value) }}',
|
|
30
|
+
},
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
];
|
|
34
|
+
//# sourceMappingURL=addItems.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"addItems.js","sourceRoot":"","sources":["../../../../../nodes/CraftDailyNotes/resources/collection/addItems.ts"],"names":[],"mappings":";;;AAMA,MAAM,6BAA6B,GAAG,EAAE,SAAS,EAAE,CAAC,UAAU,CAAC,EAAE,QAAQ,EAAE,CAAC,YAAY,CAAC,EAAE,CAAC;AAE/E,QAAA,6BAA6B,GAAsB;IAE/D;QACC,WAAW,EAAE,uBAAuB;QACpC,IAAI,EAAE,cAAc;QACpB,IAAI,EAAE,SAAS;QACf,WAAW,EAAE;YACZ,iBAAiB,EAAE,gBAAgB;SACnC;QACD,OAAO,EAAE,EAAE;QACX,QAAQ,EAAE,IAAI;QACd,WAAW,EAAE,4JAA4J;QACzK,cAAc,EAAE,EAAE,IAAI,EAAE,6BAA6B,EAAE;KACvD;IAGD;QACC,WAAW,EAAE,cAAc;QAC3B,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,MAAM;QACZ,OAAO,EAAE,sDAAsD;QAC/D,QAAQ,EAAE,IAAI;QACd,WAAW,EACV,+IAA+I;QAChJ,cAAc,EAAE,EAAE,IAAI,EAAE,6BAA6B,EAAE;QACvD,OAAO,EAAE;YACR,IAAI,EAAE;gBACL,IAAI,EAAE,MAAM;gBACZ,KAAK,EAAE,2BAA2B;aAClC;SACD;KACD;CACD,CAAC"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.collectionDeleteItemsDescription = void 0;
|
|
4
|
+
const showOnlyForCollectionDeleteItems = { operation: ['deleteItems'], resource: ['collection'] };
|
|
5
|
+
exports.collectionDeleteItemsDescription = [
|
|
6
|
+
{
|
|
7
|
+
displayName: 'Collection Name or ID',
|
|
8
|
+
name: 'collectionId',
|
|
9
|
+
type: 'options',
|
|
10
|
+
typeOptions: {
|
|
11
|
+
loadOptionsMethod: 'getCollections',
|
|
12
|
+
},
|
|
13
|
+
default: '',
|
|
14
|
+
required: true,
|
|
15
|
+
description: 'Select a collection from your daily notes. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code/expressions/">expression</a>.',
|
|
16
|
+
displayOptions: { show: showOnlyForCollectionDeleteItems },
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
displayName: 'Item IDs',
|
|
20
|
+
name: 'itemIds',
|
|
21
|
+
type: 'string',
|
|
22
|
+
default: '',
|
|
23
|
+
required: true,
|
|
24
|
+
placeholder: 'ID1, ID2, ID3 or ["ID1", "ID2"]',
|
|
25
|
+
description: 'Item IDs to delete. Provide as comma-separated values or JSON array. Non-existent IDs will be silently skipped.',
|
|
26
|
+
displayOptions: { show: showOnlyForCollectionDeleteItems },
|
|
27
|
+
routing: {
|
|
28
|
+
send: {
|
|
29
|
+
type: 'body',
|
|
30
|
+
property: 'idsToDelete',
|
|
31
|
+
value: '={{ $value.startsWith("[") ? JSON.parse($value) : $value.split(",").map(id => id.trim()) }}',
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
];
|
|
36
|
+
//# sourceMappingURL=deleteItems.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deleteItems.js","sourceRoot":"","sources":["../../../../../nodes/CraftDailyNotes/resources/collection/deleteItems.ts"],"names":[],"mappings":";;;AAMA,MAAM,gCAAgC,GAAG,EAAE,SAAS,EAAE,CAAC,aAAa,CAAC,EAAE,QAAQ,EAAE,CAAC,YAAY,CAAC,EAAE,CAAC;AAErF,QAAA,gCAAgC,GAAsB;IAElE;QACC,WAAW,EAAE,uBAAuB;QACpC,IAAI,EAAE,cAAc;QACpB,IAAI,EAAE,SAAS;QACf,WAAW,EAAE;YACZ,iBAAiB,EAAE,gBAAgB;SACnC;QACD,OAAO,EAAE,EAAE;QACX,QAAQ,EAAE,IAAI;QACd,WAAW,EAAE,4JAA4J;QACzK,cAAc,EAAE,EAAE,IAAI,EAAE,gCAAgC,EAAE;KAC1D;IAGD;QACC,WAAW,EAAE,UAAU;QACvB,IAAI,EAAE,SAAS;QACf,IAAI,EAAE,QAAQ;QACd,OAAO,EAAE,EAAE;QACX,QAAQ,EAAE,IAAI;QACd,WAAW,EAAE,iCAAiC;QAC9C,WAAW,EACV,iHAAiH;QAClH,cAAc,EAAE,EAAE,IAAI,EAAE,gCAAgC,EAAE;QAC1D,OAAO,EAAE;YACR,IAAI,EAAE;gBACL,IAAI,EAAE,MAAM;gBACZ,QAAQ,EAAE,aAAa;gBACvB,KAAK,EACJ,6FAA6F;aAC9F;SACD;KACD;CACD,CAAC"}
|