Skip to content

Clickup - reconfigure props #17155

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jun 19, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 41 additions & 9 deletions components/clickup/actions/common/comment-props.mjs
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
import common from "./workspace-prop.mjs";
import builder from "../../common/builder.mjs";
import propsFragments from "../../common/props-fragments.mjs";

export default {
props: {
Expand All @@ -14,12 +12,46 @@ export default {
}),
],
},
},
additionalProps: builder.buildListProps({
tailProps: {
taskId: propsFragments.taskId,
viewId: propsFragments.viewId,
commentId: propsFragments.commentId,
folderId: {
propDefinition: [
common.props.clickup,
"folderId",
(c) => ({
spaceId: c.spaceId,
}),
],
optional: true,
},
}),
listId: {
propDefinition: [
common.props.clickup,
"listId",
(c) => ({
folderId: c.folderId,
spaceId: c.spaceId,
}),
],
},
taskId: {
propDefinition: [
common.props.clickup,
"taskId",
(c) => ({
listId: c.listId,
useCustomTaskIds: c.useCustomTaskIds,
authorizedTeamId: c.authorizedTeamId,
}),
],
},
commentId: {
propDefinition: [
common.props.clickup,
"commentId",
(c) => ({
taskId: c.taskId,
listId: c.listId,
}),
],
},
},
};
48 changes: 40 additions & 8 deletions components/clickup/actions/common/thread-comment-props.mjs
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import builder from "../../common/builder.mjs";
import propsFragments from "../../common/props-fragments.mjs";
import common from "./workspace-prop.mjs";

export default {
Expand All @@ -14,11 +12,45 @@ export default {
}),
],
},
},
additionalProps: builder.buildListProps({
tailProps: {
taskId: propsFragments.taskId,
commentId: propsFragments.commentId,
folderId: {
propDefinition: [
common.props.clickup,
"folderId",
(c) => ({
spaceId: c.spaceId,
}),
],
optional: true,
},
}),
listId: {
propDefinition: [
common.props.clickup,
"listId",
(c) => ({
folderId: c.folderId,
spaceId: c.spaceId,
}),
],
},
taskId: {
propDefinition: [
common.props.clickup,
"taskId",
(c) => ({
listId: c.listId,
useCustomTaskIds: c.useCustomTaskIds,
}),
],
},
commentId: {
propDefinition: [
common.props.clickup,
"commentId",
(c) => ({
taskId: c.taskId,
listId: c.listId,
}),
],
},
},
};
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import builder from "../../common/builder.mjs";
import propsFragments from "../../common/props-fragments.mjs";
import common from "../common/list-props.mjs";

export default {
...common,
key: "clickup-create-chat-view-comment",
name: "Create Chat View Comment",
description: "Creates a chat view comment. See the docs [here](https://clickup.com/api) in **Comments / Create Chat View Comment** section.",
version: "0.0.9",
description: "Creates a chat view comment. [See the documentation](https://clickup.com/api) in **Comments / Create Chat View Comment** section.",
version: "0.0.10",
type: "action",
props: {
...common.props,
Expand All @@ -33,20 +31,40 @@ export default {
],
optional: true,
},
listWithFolder: {
folderId: {
propDefinition: [
common.props.clickup,
"folderId",
(c) => ({
spaceId: c.spaceId,
}),
],
optional: true,
},
listId: {
propDefinition: [
common.props.clickup,
"listWithFolder",
"listId",
(c) => ({
folderId: c.folderId,
spaceId: c.spaceId,
}),
],
optional: true,
},
},
additionalProps: builder.buildListProps({
listPropsOptional: true,
tailProps: {
viewId: propsFragments.viewId,
viewId: {
propDefinition: [
common.props.clickup,
"viewId",
(c) => ({
workspaceId: c.workspaceId,
spaceId: c.spaceId,
folderId: c.folderId,
listId: c.listId,
}),
],
},
}),
},
async run({ $ }) {
const {
viewId,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import builder from "../../common/builder.mjs";
import propsFragments from "../../common/props-fragments.mjs";
import common from "../common/task-props.mjs";

export default {
...common,
key: "clickup-create-checklist-item",
name: "Create Checklist Item",
description: "Creates a new item in a checklist. See the docs [here](https://clickup.com/api) in **Checklists / Create Checklist Item** section.",
version: "0.0.9",
description: "Creates a new item in a checklist. [See the documentation](https://clickup.com/api) in **Checklists / Create Checklist Item** section.",
version: "0.0.10",
type: "action",
props: {
...common.props,
Expand All @@ -28,19 +26,49 @@ export default {
],
optional: true,
},
listWithFolder: {
folderId: {
propDefinition: [
common.props.clickup,
"listWithFolder",
"folderId",
(c) => ({
spaceId: c.spaceId,
}),
],
optional: true,
},
},
additionalProps: builder.buildListProps({
tailProps: {
taskId: propsFragments.taskId,
checklistId: propsFragments.checklistId,
listId: {
propDefinition: [
common.props.clickup,
"listId",
(c) => ({
folderId: c.folderId,
spaceId: c.spaceId,
}),
],
},
taskId: {
propDefinition: [
common.props.clickup,
"taskId",
(c) => ({
listId: c.listId,
useCustomTaskIds: c.useCustomTaskIds,
authorizedTeamId: c.authorizedTeamId,
}),
],
},
}),
checklistId: {
propDefinition: [
common.props.clickup,
"checklistId",
(c) => ({
taskId: c.taskId,
useCustomTaskIds: c.useCustomTaskIds,
authorizedTeamId: c.authorizedTeamId,
}),
],
},
},
async run({ $ }) {
const {
taskId,
Expand Down
40 changes: 29 additions & 11 deletions components/clickup/actions/create-checklist/create-checklist.mjs
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
import builder from "../../common/builder.mjs";
import propsFragments from "../../common/props-fragments.mjs";
import common from "../common/task-props.mjs";

export default {
...common,
key: "clickup-create-checklist",
name: "Create Checklist",
description: "Creates a new checklist in a task. See the docs [here](https://clickup.com/api) in **Checklists / Create Checklist** section.",
version: "0.0.9",
description: "Creates a new checklist in a task. [See the documentation](https://clickup.com/api) in **Checklists / Create Checklist** section.",
version: "0.0.10",
type: "action",
props: {
...common.props,
Expand All @@ -16,18 +14,38 @@ export default {
type: "string",
description: "The name of checklist",
},
listWithFolder: {
folderId: {
propDefinition: [
common.props.clickup,
"listWithFolder",
"folderId",
(c) => ({
spaceId: c.spaceId,
}),
],
optional: true,
},
},
additionalProps: builder.buildListProps({
tailProps: {
taskId: propsFragments.taskId,
listId: {
propDefinition: [
common.props.clickup,
"listId",
(c) => ({
folderId: c.folderId,
spaceId: c.spaceId,
}),
],
},
}),
taskId: {
propDefinition: [
common.props.clickup,
"taskId",
(c) => ({
listId: c.listId,
useCustomTaskIds: c.useCustomTaskIds,
authorizedTeamId: c.authorizedTeamId,
}),
],
},
},
async run({ $ }) {
const {
taskId,
Expand Down
4 changes: 2 additions & 2 deletions components/clickup/actions/create-folder/create-folder.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ export default {
...common,
key: "clickup-create-folder",
name: "Create Folder",
description: "Creates a new folder. See the docs [here](https://clickup.com/api) in **Folders / Create Folder** section.",
version: "0.0.9",
description: "Creates a new folder. [See the documentation](https://clickup.com/api) in **Folders / Create Folder** section.",
version: "0.0.10",
type: "action",
props: {
...common.props,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
import clickup from "../../clickup.app.mjs";
import builder from "../../common/builder.mjs";
import common from "../common/list-props.mjs";

export default {
...common,
key: "clickup-create-list-comment",
name: "Create List Comment",
description: "Creates a list comment. See the docs [here](https://clickup.com/api) in **Comments / Create List Comment** section.",
version: "0.0.9",
description: "Creates a list comment. [See the documentation](https://clickup.com/api) in **Comments / Create List Comment** section.",
version: "0.0.10",
type: "action",
props: {
...common.props,
Expand All @@ -33,14 +32,27 @@ export default {
],
optional: true,
},
listWithFolder: {
folderId: {
propDefinition: [
common.props.clickup,
"listWithFolder",
"folderId",
(c) => ({
spaceId: c.spaceId,
}),
],
optional: true,
},
listId: {
propDefinition: [
common.props.clickup,
"listId",
(c) => ({
folderId: c.folderId,
spaceId: c.spaceId,
}),
],
},
},
additionalProps: builder.buildListProps(),
async run({ $ }) {
const {
listId,
Expand Down
4 changes: 2 additions & 2 deletions components/clickup/actions/create-list/create-list.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import constants from "../common/constants.mjs";
export default {
key: "clickup-create-list",
name: "Create List",
description: "Creates a new list. See the docs [here](https://clickup.com/api) in **Lists / Create List** section.",
version: "0.0.14",
description: "Creates a new list. [See the documentation](https://clickup.com/api) in **Lists / Create List** section.",
version: "0.0.15",
type: "action",
props: {
clickup,
Expand Down
4 changes: 2 additions & 2 deletions components/clickup/actions/create-space/create-space.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import common from "../common/workspace-prop.mjs";
export default {
key: "clickup-create-space",
name: "Create Space",
description: "Creates a new space. See the docs [here](https://clickup.com/api) in **Spaces / Create Space** section.",
version: "0.0.9",
description: "Creates a new space. [See the documentation](https://clickup.com/api) in **Spaces / Create Space** section.",
version: "0.0.10",
type: "action",
props: {
...common.props,
Expand Down
Loading
Loading