feat: #206 convert to interactions (buttons and application commands) (#238)

* feat: make command handler slash command-ready

Only `help` and `settings` commands work so far

* feat(commands): finish new settings command

* fix(settings): convert `roles` and `ping` to an array

* fix(commands): make `add` a slash command

* fix(commands): make `blacklist` a slash command

* fix(commands): remove URLs from `help` command

* Add weblate badge and overview image

* Update sponsors

* sqlite things

* imrpovements

* update eslint rules

* (⚠ untested) close command

* fix: default locale for getting command option names

* Update README.md

* Update README.md

* Update README.md

* update new command to slash commands and fix close command

* fixes and improvements

* fix: closing a ticket when the creator has left

* Revert "fix: closing a ticket when the creator has left"

This reverts commit afc40ae17077782e344fd8cee03a089966c2347e.

* fix: closing a ticket when the creator has left

* fix: localisation issues in settings command

* fix: delete category channel

* New button and select panels + updated message panels

Includes new options for panel embed message image and thumbnail

Co-Authored-By: Puneet Gopinath <baalkrshna@gmail.com>
Co-Authored-By: thevisuales <6569806+thevisuales@users.noreply.github.com>

* Finish converting to buttons, added close button

Co-Authored-By: Puneet Gopinath <baalkrshna@gmail.com>
Co-Authored-By: thevisuales <6569806+thevisuales@users.noreply.github.com>

* fully convert to slash commands

* re-add "... has created a ticket" message

* locales

* fix add and remove commands

* fix remove command

* fix stats command

* eslint

Co-authored-by: Puneet Gopinath <baalkrshna@gmail.com>
Co-authored-by: thevisuales <6569806+thevisuales@users.noreply.github.com>
This commit is contained in:
Isaac
2021-09-24 15:32:36 +01:00
committed by GitHub
parent 39e2cef38d
commit 95f76716ed
38 changed files with 2481 additions and 2268 deletions

69
pnpm-lock.yaml generated
View File

@@ -4,19 +4,17 @@ specifiers:
'@eartharoid/i18n': ^1.0.0
all-contributors-cli: ^6.20.0
boxen: ^5.0.1
command-line-args: ^5.2.0
cryptr: ^6.0.2
discord.js: ^13.1.0
dotenv: ^8.6.0
eslint: ^7.32.0
jsonschema: ^1.4.0
keyv: ^4.0.3
leeks.js: ^0.2.2
leekslazylogger: ^3.0.2
mariadb: ^2.5.4
ms: ^2.1.3
mustache: ^4.2.0
mysql2: ^2.3.0
node-emoji: ^1.11.0
node-fetch: ^2.6.1
nodemon: ^2.0.12
pg: ^8.7.1
@@ -24,30 +22,24 @@ specifiers:
semver: ^7.3.5
sequelize: ^6.6.5
sqlite3: ^5.0.2
string-argv: ^0.3.1
tedious: ^11.4.0
terminal-link: ^2.1.1
to-time-monthsfork: ^1.1.4
dependencies:
'@eartharoid/i18n': 1.0.0
boxen: 5.0.1
command-line-args: 5.2.0
cryptr: 6.0.2
discord.js: 13.1.0
dotenv: 8.6.0
jsonschema: 1.4.0
keyv: 4.0.3
leeks.js: 0.2.2
leekslazylogger: 3.0.2
ms: 2.1.3
mustache: 4.2.0
node-emoji: 1.11.0
node-fetch: 2.6.1
semver: 7.3.5
sequelize: 6.6.5_aa1b3c7f5b5df187fb1a5c6073dca637
string-argv: 0.3.1
terminal-link: 2.1.1
to-time-monthsfork: 1.1.4
optionalDependencies:
sqlite3: 5.0.2
@@ -591,11 +583,6 @@ packages:
sprintf-js: 1.0.3
dev: true
/array-back/3.1.0:
resolution: {integrity: sha512-TkuxA4UCOvxuDK6NZYXCalszEzj+TLszyASooky+i742l9TqsOdYCMJJupxRic61hwquNtppB3hgcuq9SVSH1Q==}
engines: {node: '>=6'}
dev: false
/asn1/0.2.4:
resolution: {integrity: sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==}
dependencies:
@@ -659,10 +646,6 @@ packages:
dev: false
optional: true
/bignumber.js/2.4.0:
resolution: {integrity: sha1-g4qZLan51zfg9LLbC+YrsJ3Qxeg=}
dev: false
/binary-extensions/2.2.0:
resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==}
engines: {node: '>=8'}
@@ -908,16 +891,6 @@ packages:
dependencies:
delayed-stream: 1.0.0
/command-line-args/5.2.0:
resolution: {integrity: sha512-4zqtU1hYsSJzcJBOcNZIbW5Fbk9BkjCp1pZVhQKoRaWL5J7N4XphDLwo8aWwdQpTugxwu+jf9u2ZhkXiqp5Z6A==}
engines: {node: '>=4.0.0'}
dependencies:
array-back: 3.1.0
find-replace: 3.0.0
lodash.camelcase: 4.3.0
typical: 4.0.0
dev: false
/concat-map/0.0.1:
resolution: {integrity: sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=}
@@ -1343,13 +1316,6 @@ packages:
to-regex-range: 5.0.1
dev: true
/find-replace/3.0.0:
resolution: {integrity: sha512-6Tb2myMioCAgv5kfvP5/PkZZ/ntTpVK39fHY7WkWBgvbeE+VHd/tZuZ4mrC+bxh4cfOZeYKVPaJIZtZXV7GNCQ==}
engines: {node: '>=4.0.0'}
dependencies:
array-back: 3.1.0
dev: false
/find-up/4.1.0:
resolution: {integrity: sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==}
engines: {node: '>=8'}
@@ -1903,10 +1869,6 @@ packages:
dev: false
optional: true
/jsonschema/1.4.0:
resolution: {integrity: sha512-/YgW6pRMr6M7C+4o8kS+B/2myEpHCrxO4PEWnqJNBFMjn7EWXqlQ4tGwL6xTHeRplwuZmcAncdvfOad1nT2yMw==}
dev: false
/jsonwebtoken/8.5.1:
resolution: {integrity: sha512-XjwVfRS6jTMsqYs0EsuJ4LGxXV14zQybNd4L2r0UvbVnSF9Af8x7p5MzbJ90Ioz/9TI41/hTCvznF/loiSzn8w==}
engines: {node: '>=4', npm: '>=1.4.28'}
@@ -2019,10 +1981,6 @@ packages:
p-locate: 4.1.0
dev: true
/lodash.camelcase/4.3.0:
resolution: {integrity: sha1-soqmKIorn8ZRA1x3EfZathkDMaY=}
dev: false
/lodash.clonedeep/4.5.0:
resolution: {integrity: sha1-4j8/nE+Pvd6HJSnBBxhXoIblzO8=}
dev: true
@@ -2273,12 +2231,6 @@ packages:
resolution: {integrity: sha512-mmcei9JghVNDYydghQmeDX8KoAm0FAiYyIcUt/N4nhyAipB17pllZQDOJD2fotxABnt4Mdz+dKTO7eftLg4d0A==}
optional: true
/node-emoji/1.11.0:
resolution: {integrity: sha512-wo2DpQkQp7Sjm2A0cq+sN7EHKO6Sl0ctXeBdFZrL9T9+UywORbufTcTZxom8YqpLQt/FqNMUkOpkZrJVYSKD3A==}
dependencies:
lodash: 4.17.21
dev: false
/node-fetch/2.6.1:
resolution: {integrity: sha512-V4aYg89jEoVRxRb2fJdAg8FHvI7cEyYdVAh94HH0UIK8oJxUfkjlDQN9RbMx+bEjP7+ggMiFRprSti032Oipxw==}
engines: {node: 4.x || >=6.0.0}
@@ -3102,11 +3054,6 @@ packages:
engines: {node: '>=4', npm: '>=6'}
dev: true
/string-argv/0.3.1:
resolution: {integrity: sha512-a1uQGz7IyVy9YwhqjZIZu1c8JO8dNIe20xBmSS6qu9kv++k3JGzCVmprbNN5Kn+BgzD5E7YYwg1CcjuJMRNsvg==}
engines: {node: '>=0.6.19'}
dev: false
/string-width/1.0.2:
resolution: {integrity: sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=}
engines: {node: '>=0.10.0'}
@@ -3314,13 +3261,6 @@ packages:
is-number: 7.0.0
dev: true
/to-time-monthsfork/1.1.4:
resolution: {integrity: sha512-3bWuIwm9QeOAq/UClxFp86QMSJ4GVHmAT8X+pkM0mIMVrpJPLfSieY5qvSsfLJugLNWTVpYJ2ayKWXH3jcAdow==}
engines: {node: '>=4.6'}
dependencies:
bignumber.js: 2.4.0
dev: false
/toposort-class/1.0.1:
resolution: {integrity: sha1-f/0feMi+KMO6Rc1OGj9e4ZO9mYg=}
dev: false
@@ -3417,11 +3357,6 @@ packages:
is-typedarray: 1.0.0
dev: true
/typical/4.0.0:
resolution: {integrity: sha512-VAH4IvQ7BDFYglMd7BPRDfLgxZZX4O4TFcRDA6EN5X7erNJJq+McIEp8np9aVtxrCJ6qx4GTYVfOWNjcqwZgRw==}
engines: {node: '>=8'}
dev: false
/undefsafe/2.0.3:
resolution: {integrity: sha512-nrXZwwXrD/T/JXeygJqdCO6NZZ1L66HrxM/Z7mIq2oPanoN0F1nLx3lwJMu6AwJY69hdixaFQOuoYsMjE5/C2A==}
dependencies: