Skip to content

Commit 484d9ea

Browse files
committed
add sort props
1 parent 63d24df commit 484d9ea

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

components/slack/actions/find-message/find-message.mjs

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,34 @@ export default {
2828
default: 100,
2929
optional: true,
3030
},
31+
sort: {
32+
type: "string",
33+
label: "Sort",
34+
description: "Return matches sorted by either `score` or `timestamp`",
35+
options: [
36+
"score",
37+
"timestamp",
38+
],
39+
optional: true,
40+
},
41+
sortDirection: {
42+
type: "string",
43+
label: "Sort Direction",
44+
description: "Sort ascending (asc) or descending (desc)`",
45+
options: [
46+
"desc",
47+
"asc",
48+
],
49+
optional: true,
50+
},
3151
},
3252
async run({ $ }) {
3353
const matches = [];
3454
const params = {
3555
query: this.query,
3656
team_id: this.teamId,
57+
sort: this.sort,
58+
sort_dir: this.sortDirection,
3759
page: 1,
3860
};
3961
let hasMore;

0 commit comments

Comments
 (0)