diff --git a/.eslintignore b/.eslintignore index 6c4b50059..e13986ed5 100644 --- a/.eslintignore +++ b/.eslintignore @@ -1,2 +1,3 @@ packages/docs/* -packages/portal/* \ No newline at end of file +packages/portal/* +starters/apps/* \ No newline at end of file diff --git a/.eslintrc b/.eslintrc new file mode 100644 index 000000000..29aedefc3 --- /dev/null +++ b/.eslintrc @@ -0,0 +1,23 @@ +{ + "env": { + "browser": true, + "commonjs": true, + "es2021": true, + "node": true + }, + "extends": "eslint:recommended", + "overrides": [ + { + "files": ["packages/**/*.js"], + "rules": { + "no-unsafe-negation": "off", + "no-prototype-builtins": "off", + "no-useless-escape": "off" + } + } + ], + "parserOptions": { + "ecmaVersion": "latest" + }, + "ignorePatterns": ["node_modules/", "starters/", "__test__", "base-**"] +} diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index ebab55120..000000000 --- a/.eslintrc.js +++ /dev/null @@ -1,18 +0,0 @@ -module.exports = { - env: { - browser: true, - commonjs: true, - es2021: true, - node: true, - }, - extends: 'eslint:recommended', - overrides: [], - parserOptions: { - ecmaVersion: 'latest', - }, - rules: { - 'no-unsafe-negation': 'off', - 'no-prototype-builtins': 'off', - 'no-useless-escape': 'off', - }, -} diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 8278042a7..1eff8e893 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -12,6 +12,6 @@ Por favor agrega una descripción de tu aporte para tener más contexto y poder > Forma parte de este proyecto. - [Discord](https://link.codigoencasa.com/DISCORD) -- [Twitter](https://twitter.com/leifermendez) +- [𝕏 (Twitter)](https://twitter.com/leifermendez) - [Youtube](https://www.youtube.com/watch?v=5lEMCeWEJ8o&list=PL_WGMLcL4jzWPhdhcUyhbFU6bC0oJd2BR) - [Telegram](https://t.me/leifermendez) diff --git a/.github/workflows/netlify-dev.yml b/.github/workflows/netlify-dev.yml index 477d54954..070270af8 100644 --- a/.github/workflows/netlify-dev.yml +++ b/.github/workflows/netlify-dev.yml @@ -45,5 +45,5 @@ jobs: - name: Build and Deploy run: | - cd packages/docs - netlify deploy --build --site ${{ secrets.NETLIFY_SITE_ID }} --auth ${{ secrets.NETLIFY_AUTH_TOKEN }} + cd packages/docs && npm run build + netlify deploy --site ${{ secrets.NETLIFY_SITE_ID }} --auth ${{ secrets.NETLIFY_AUTH_TOKEN }} diff --git a/.github/workflows/netlify.yml b/.github/workflows/netlify.yml index 9c21b3772..63ab48a8b 100644 --- a/.github/workflows/netlify.yml +++ b/.github/workflows/netlify.yml @@ -39,4 +39,4 @@ jobs: - name: Build and Deploy run: | - cd packages/docs && netlify deploy --prod --build --site ${{ secrets.NETLIFY_SITE_ID }} --auth ${{ secrets.NETLIFY_AUTH_TOKEN }} + cd packages/docs && npm run build && netlify deploy --prod --site ${{ secrets.NETLIFY_SITE_ID }} --auth ${{ secrets.NETLIFY_AUTH_TOKEN }} diff --git a/.github/workflows/releases-dev.yml b/.github/workflows/releases-dev.yml index c81260cfa..762acc523 100644 --- a/.github/workflows/releases-dev.yml +++ b/.github/workflows/releases-dev.yml @@ -57,3 +57,6 @@ jobs: - name: Release @bot-whatsapp/portal run: node ./scripts/release.js --name=portal --version= --token="${{ secrets.NPM_TOKEN }}" + + - name: Release eslint-plugin-bot-whatsapp + run: node ./scripts/release.js --name=eslint-plugin-bot-whatsapp --version= --token="${{ secrets.NPM_TOKEN }}" diff --git a/.github/workflows/releases.yml b/.github/workflows/releases.yml index 6bfb838a9..a798d5217 100644 --- a/.github/workflows/releases.yml +++ b/.github/workflows/releases.yml @@ -66,5 +66,8 @@ jobs: - name: Release @bot-whatsapp/portal run: node ./scripts/release.js --name=portal --version="${{ steps.package-version.outputs.current-version}}" --token="${{ secrets.NPM_TOKEN }}" + - name: Release eslint-plugin-bot-whatsapp + run: node ./scripts/release.js --name=eslint-plugin-bot-whatsapp --version="${{ steps.package-version.outputs.current-version}}" --token="${{ secrets.NPM_TOKEN }}" + - name: Release Github run: node ./scripts/github.js --version="${{ steps.package-version.outputs.current-version}}" --token="${{ secrets.OCTO_TOKEN }}" diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0a24cebea..659efb68f 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,62 +1,68 @@ # CONTRIBUTING -### 📄 Bienvenido/a -Si deseas colaborar con el proyecto existen varias maneras, la primera de ellas es aportando conocimiento y mejorando el repositorio (actualizando documentación, mejorando código, revisando __[issues](https://github.com/codigoencasa/bot-whatsapp/issues)__, etc). +### 👋 Bienvenido/a +Nos alegra que estés interesado en colaborar en nuestro proyecto. Para hacerlo, puedes contribuir de diversas maneras, la principal es aportando tu conocimiento y habilidades para mejorar el repositorio, ya sea actualizando la documentación, mejorando el código o revisando problemas pendientes en los __[issues](https://github.com/codigoencasa/bot-whatsapp/issues)__. - También es bien recibido los aportes económicos que se utilizaran para diferentes fines __[ver más](https://opencollective.com/bot-whatsapp)__ +También agradecemos los aportes económicos, que utilizaremos para diversos fines relacionados con el desarrollo y mantenimiento del proyecto. Puedes ver más detalles aquí: __[ver más](https://opencollective.com/bot-whatsapp)__ -El lenguaje principal que se utilizó para desarrollar este proyecto fue __JavaScript__ con el fin de qué personas que están iniciando en el mundo de la programación puedan entender fácilmente. +El lenguaje principal que usamos en este proyecto es __JavaScript__, para que las personas que están comenzando a programar puedan entenderlo más fácilmente. - -### 🤔 Preguntas frecuentes -- ¿Como puedo hacer aportaciones de código en el proyecto?: [Ver Video](https://youtu.be/Lxt8Acob6aU) -- ¿Como ejecutar el entorno de pruebas?: [Ver Video](https://youtu.be/Mf9V-dloBfk) -- ¿Como crear un nuevo proveedor?: [Ver Video](https://youtu.be/cahK9zH3SI8) -- ¿Que son los GithubActions?: [Ver Video](https://youtu.be/nYBEBFKLiqw) +### 💡 Preguntas frecuentes +- ¿Cómo puedo hacer aportaciones de código en el proyecto?: [Ver Video](https://youtu.be/Lxt8Acob6aU) +- ¿Cómo ejecutar el entorno de pruebas?: [Ver Video](https://youtu.be/Mf9V-dloBfk) +- ¿Cómo crear un nuevo proveedor?: [Ver Video](https://youtu.be/cahK9zH3SI8) +- ¿Qué son los GithubActions?: [Ver Video](https://youtu.be/nYBEBFKLiqw) - ¿Canales de comunicación?: [Discord](https://link.codigoencasa.com/DISCORD) ------ +------ -![](https://i.giphy.com/media/ntMt6TvalpstTIx7Ak/giphy.webp) +__Requisitos:__ +Para poder aportar al proyecto necesitarás tener: +- Node v18 o superior. Puedes descargar Node aquí: __[descargar node](https://nodejs.org/es/download/)__ +- __[pnpm](https://pnpm.io/cli/install)__ como administrador de paquetes. Puedes seguir el enlace para saber cómo instalarlo. +- __[VSCode](https://code.visualstudio.com/download)__ es el editor de código que recomendamos, ya que cuenta con plugins útiles. +- __[Conventional Commits](https://marketplace.visualstudio.com/items?itemName=vivaxy.vscode-conventional-commits&ssr=false#overview)__ es un plugin de VSCode que te ayudará a crear commits semánticos, siguiendo buenas prácticas. +### 🚀 Empezando -__Requerimientos:__ -- Node v16 o superior __[descargar node](https://nodejs.org/es/download/)__ -- __[Yarn](https://classic.yarnpkg.com/lang/en/docs/install/#windows-stable)__ como gestor de paquetes. En el link conseguirás las intrucciones para instalar yarn. -- __[VSCode](https://code.visualstudio.com/download)__ (recomendado): Editor de código con plugins. -- __[Conventional Commits](https://marketplace.visualstudio.com/items?itemName=vivaxy.vscode-conventional-commits&ssr=false#overview)__ (plugin-vscode) este plugin te ayudará a crear commit semántico. -- Se usará la rama __dev__ *(https://github.com/leifermendez/bot-whatsapp/tree/dev)* como rama principal hasta que se haga oficialmente el lanzamiento de la V2. +__Hacer Fork del Proyecto__ -### 🚀 Iniciando +Antes de comenzar, es necesario que hagas un fork del proyecto en tu propia cuenta de GitHub. Esto te permitirá trabajar en tu propia copia del repositorio. Haz clic en el siguiente enlace para realizar el fork: [aquí](https://github.com/codigoencasa/bot-whatsapp/fork) -__Clonar repo rama dev__ +__Clona repositorio (desde tu fork)__ ``` -git clone --branch dev https://github.com/codigoencasa/bot-whatsapp +git clone https://github.com/TU_USERNAME/bot-whatsapp ``` __Instalar dependencias__ +Entra a la carpeta del proyecto y ejecuta el siguiente comando para instalar las dependencias necesarias. ``` cd bot-whatsapp -yarn install +pnpm install ``` __Compilar (build)__ -Para compilar la aplicación es necesario ejecutar este comando, el cual genera un directorio `lib` dentro de los paquetes del monorepo. +Para compilar la aplicación, debes ejecutar el siguiente comando, el cual generará un directorio `lib` dentro de los paquetes del monorepo. +``` +pnpm run build +``` +__Aplicación de ejemplo__ +Se ejecuta el CLI (Command Line Interface) para ayudarte a crear un bot de ejemplo. ``` -yarn build +pnpm run cli ``` -__Example-app__ -Se ejecuta el CLI (Command Line Interface) para ayudarte a crear un app-bot de ejemplo. +__Test e2e__ +Todos los cambios realizados deben de pasar las pruebas end-to-end ``` -yarn run cli +pnpm run test.e2e ``` -Selecionas (mediante las flechas arriba y abajo) el proveedor que quieras usar y cuando estes sobre el presiona la barra de espacio, igualmente selecciona la base de datos que quieras usar. +Selecciona el proveedor y la base de datos que quieras usar usando las flechas arriba y abajo de tu teclado y marcándolas con la barra de espacio. -Se creó un subdirecorio con el nombre del proveedor y base de datos que seleccionaste, ejemplo: `base-bailey-mysql` +Este proceso creará un subdirectorio con el nombre del proveedor y la base de datos que seleccionaste, por ejemplo: `base-bailey-mysql` -Dentro de ese directorio necesitas editar el archivo package.json y borrar las siguientes lineas: +Dentro de ese directorio, tendrás que editar el archivo package.json y borrar las siguientes líneas: ``` "@bot-whatsapp/bot": "latest", "@bot-whatsapp/cli": "latest", @@ -64,17 +70,17 @@ Dentro de ese directorio necesitas editar el archivo package.json y borrar las s "@bot-whatsapp/provider": "latest", ``` -Cambiate al directorio creado ejemplo: `base-bailey-mysql` +A continuación, debes desplazarte al directorio que acabas de crear, por ejemplo: `base-baileys-mysql` ``` cd base-baileys-mysql ``` -Ejecuta los comandos: +Y ejecuta los siguientes comandos: ``` npm install npm run pre-copy npm start ``` -En el caso de MySql y Mongo es necesario especificar en app.js los datos de la conexión, ejemplo de MySql: +En el caso de MySql y Mongo, necesitarás especificar en el archivo app.js los datos de la conexión, por ejemplo, para MySql: ``` const BaileysProvider = require('@bot-whatsapp/provider/baileys') const MySQLAdapter = require('@bot-whatsapp/database/mysql') @@ -87,17 +93,11 @@ const MYSQL_DB_USER = 'usr' const MYSQL_DB_PASSWORD = 'pass' const MYSQL_DB_NAME = 'bot' ``` - - -![](https://i.imgur.com/dC6lEwy.png) - -> __NOTA:__ [Eres libre de aportar informacion inexacta a este documento o arreglar horrores de ortografia que dificultan la comprensión. 🤣]( -https://github.com/codigoencasa/bot-whatsapp/edit/dev/CONTRIBUTING.md) +> __NOTA:__ Si encuentras información que podría mejorarse en este documento o algún error ortográfico que dificulte la comprensión, eres libre de corregirlo.([edita aqui](https://github.com/codigoencasa/bot-whatsapp/edit/dev/CONTRIBUTING.md)) ------ - [Discord](https://link.codigoencasa.com/DISCORD) - [Twitter](https://twitter.com/leifermendez) - [Youtube](https://www.youtube.com/watch?v=5lEMCeWEJ8o&list=PL_WGMLcL4jzWPhdhcUyhbFU6bC0oJd2BR) -- [Telegram](https://t.me/leifermendez) +- [Telegram](https://t.me/leifermendez) \ No newline at end of file diff --git a/README.md b/README.md index af4b1247e..afe0a40b5 100644 --- a/README.md +++ b/README.md @@ -26,7 +26,7 @@ Entiende más a fondo sus funcionalidades explicadas en nuestra documentación. - [📄 Documentación](https://bot-whatsapp.netlify.app/) - [🚀 Roadmap](https://github.com/orgs/codigoencasa/projects/1) - [💻 Discord](https://link.codigoencasa.com/DISCORD) -- [👌 Twitter](https://twitter.com/leifermendez) +- [👌 𝕏 (Twitter)](https://twitter.com/leifermendez) - [🎥 Youtube](https://www.youtube.com/watch?v=5lEMCeWEJ8o&list=PL_WGMLcL4jzWPhdhcUyhbFU6bC0oJd2BR) ## Comunidad diff --git a/__mocks__/mock.provider.js b/__mocks__/mock.provider.js index 67b793ec8..95b3a8d11 100644 --- a/__mocks__/mock.provider.js +++ b/__mocks__/mock.provider.js @@ -1,16 +1,14 @@ const ProviderClass = require('../packages/bot/provider/provider.class') +const { delay } = require('./env') class MockProvider extends ProviderClass { constructor() { super() } - delaySendMessage = (miliseconds, eventName, payload) => - new Promise((res) => - setTimeout(() => { - this.emit(eventName, payload) - res - }, miliseconds) - ) + delaySendMessage = async (miliseconds, eventName, payload) => { + await delay(miliseconds) + this.emit(eventName, payload) + } sendMessage = async (userId, message) => { console.log(`Enviando... ${userId}, ${message}`) diff --git a/__test__/0.0.0-case.test.js b/__test__/0.0.0-case.test.js index d798ba911..cb6a9529a 100644 --- a/__test__/0.0.0-case.test.js +++ b/__test__/0.0.0-case.test.js @@ -31,7 +31,7 @@ suiteCase(`Responder a "hola"`, async ({ database, provider }) => { suiteCase(`NO reponder a "pepe"`, async ({ database, provider }) => { const flow = addKeyword('hola').addAnswer('Buenas!').addAnswer('Como vamos!') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), diff --git a/__test__/0.0.1-case.test.js b/__test__/0.0.1-case.test.js index e2cd89e0e..83695cf82 100644 --- a/__test__/0.0.1-case.test.js +++ b/__test__/0.0.1-case.test.js @@ -11,7 +11,7 @@ suiteCase.after.each(clear) suiteCase(`Responder a "EVENTS.LOCATION"`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.LOCATION).addAnswer('Gracias por tu location') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -51,7 +51,7 @@ suiteCase(`Responder a "EVENTS.DOCUMENT"`, async ({ database, provider }) => { suiteCase(`Responder a "EVENTS.WELCOME"`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.WELCOME).addAnswer('Bienvenido!') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -71,7 +71,7 @@ suiteCase(`Responder a "EVENTS.WELCOME"`, async ({ database, provider }) => { suiteCase(`Responder a "EVENTS.MEDIA"`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.MEDIA).addAnswer('gracias por la imagen o video!') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -91,7 +91,7 @@ suiteCase(`Responder a "EVENTS.MEDIA"`, async ({ database, provider }) => { suiteCase(`Responder a "EVENTS.VOICE_NOTE"`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.VOICE_NOTE).addAnswer('gracias por la nota de voz!') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), diff --git a/__test__/0.0.2-case.test.js b/__test__/0.0.2-case.test.js index 7448b337c..03ffba774 100644 --- a/__test__/0.0.2-case.test.js +++ b/__test__/0.0.2-case.test.js @@ -21,13 +21,13 @@ suiteCase(`Debe saltar de flujo`, async ({ database, provider }) => { }) .addAnswer('este mensaje no deberia existir') - createBot({ + await createBot({ database, flow: createFlow([flujoBienvenida]), provider, }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(50, 'message', { from: '000', body: 'hola', }) @@ -52,7 +52,7 @@ suiteCase(`Debe saltar de flujo con capture sin flowDynamic`, async ({ database, }) .addAnswer('este mensaje no deberia existir') - createBot({ + await createBot({ database, flow: createFlow([flujoBienvenida]), provider, @@ -90,7 +90,7 @@ suiteCase(`Debe saltar de flujo con capture con flowDynamic`, async ({ database, }) .addAnswer('este mensaje no deberia existir') - createBot({ + await createBot({ database, flow: createFlow([flujoBienvenida]), provider, diff --git a/__test__/0.1.0-case.test.js b/__test__/0.1.0-case.test.js index 2380edecf..7f45cde37 100644 --- a/__test__/0.1.0-case.test.js +++ b/__test__/0.1.0-case.test.js @@ -11,7 +11,7 @@ suiteCase.after.each(clear) suiteCase(`Responder a "ole" en minuscula`, async ({ database, provider }) => { const flow = addKeyword(['ola', 'ole'], { sensitive: true }).addAnswer('Bienvenido a la OLA') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -31,7 +31,7 @@ suiteCase(`Responder a "ole" en minuscula`, async ({ database, provider }) => { suiteCase(`NO Responder a "ole" en minuscula`, async ({ database, provider }) => { const flow = addKeyword(['ola', 'ole'], { sensitive: true }).addAnswer('Bienvenido a la OLA') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), diff --git a/__test__/0.1.1-case.test.js b/__test__/0.1.1-case.test.js index 499d2ec32..e98d78695 100644 --- a/__test__/0.1.1-case.test.js +++ b/__test__/0.1.1-case.test.js @@ -51,11 +51,13 @@ suiteCase(`Debe continuar el flujo del hijo`, async ({ database, provider }) => body: 'hola', }) + await delay(0) await provider.delaySendMessage(30, 'message', { from: '000', body: 'test@test.com', }) + await delay(0) await provider.delaySendMessage(60, 'message', { from: '000', body: 'paypal', @@ -66,6 +68,7 @@ suiteCase(`Debe continuar el flujo del hijo`, async ({ database, provider }) => body: 'continue!', }) + await delay(0) await delay(800) const getHistory = database.listHistory.map((i) => i.answer) diff --git a/__test__/0.1.2-case.test.js b/__test__/0.1.2-case.test.js index cd0dbcd39..26b6a508c 100644 --- a/__test__/0.1.2-case.test.js +++ b/__test__/0.1.2-case.test.js @@ -15,7 +15,7 @@ suiteCase(`Responder a una expresion regular`, async ({ database, provider }) => .addAnswer(`Gracias por proporcionar un numero de tarjeta valido`) .addAnswer('Fin!') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -39,7 +39,7 @@ suiteCase(`NO Responder a una expresion regular`, async ({ database, provider }) .addAnswer(`Gracias por proporcionar un numero de tarjeta valido`) .addAnswer('Fin!') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), diff --git a/__test__/0.1.3-case.test.js b/__test__/0.1.3-case.test.js index 189358381..2787ad80a 100644 --- a/__test__/0.1.3-case.test.js +++ b/__test__/0.1.3-case.test.js @@ -13,7 +13,7 @@ suiteCase(`Responder a "pregunta"`, async ({ database, provider }) => { .addAnswer(['Hola como estas?', '¿Cual es tu edad?'], { capture: true }) .addAnswer('Gracias por tu respuesta') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), diff --git a/__test__/0.1.4-case.test.js b/__test__/0.1.4-case.test.js index 0139edec8..8febd46bf 100644 --- a/__test__/0.1.4-case.test.js +++ b/__test__/0.1.4-case.test.js @@ -87,7 +87,7 @@ suiteCase(`Responder con un "string"`, async ({ database, provider }) => { }) .addAnswer('y vos?') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -113,7 +113,7 @@ suiteCase(`Responder con un "array"`, async ({ database, provider }) => { }) .addAnswer('y vos?') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -140,7 +140,7 @@ suiteCase(`Responder con un "object"`, async ({ database, provider }) => { }) .addAnswer('y vos?') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -171,23 +171,23 @@ suiteCase(`FlowDynamic con capture`, async ({ database, provider }) => { ) .addAnswer('fin!') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'hola', }) - await provider.delaySendMessage(10, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'mal', }) - await provider.delaySendMessage(20, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'bien', }) @@ -232,7 +232,7 @@ suiteCase(`FlowDynamic con capture en hijo`, async ({ database, provider }) => { [flowDos] ) - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -243,17 +243,17 @@ suiteCase(`FlowDynamic con capture en hijo`, async ({ database, provider }) => { body: 'hola', }) - await provider.delaySendMessage(10, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'flowDos', }) - await provider.delaySendMessage(20, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'flow3', }) - await provider.delaySendMessage(30, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'flow4', }) diff --git a/__test__/0.1.5-case.test.js b/__test__/0.1.5-case.test.js index 8b9e310f9..254cf5ac5 100644 --- a/__test__/0.1.5-case.test.js +++ b/__test__/0.1.5-case.test.js @@ -35,7 +35,7 @@ suiteCase(`Detener el flujo`, async ({ database, provider }) => { return flowDynamic(data) }) - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -70,7 +70,7 @@ suiteCase(`Detener el flujo flowDynamic`, async ({ database, provider }) => { }) .addAnswer('Como estas!') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -117,33 +117,33 @@ suiteCase(`flowDynamic con capture`, async ({ database, provider }) => { }) .addAnswer('Puedes pasar') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'hola', }) - await provider.delaySendMessage(10, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'this is not email value', }) - await provider.delaySendMessage(20, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'test@test.com', }) - await provider.delaySendMessage(90, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: '20', }) - await provider.delaySendMessage(200, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: '18', }) diff --git a/__test__/0.1.6-case.test.js b/__test__/0.1.6-case.test.js index e78b4bff3..372418bc6 100644 --- a/__test__/0.1.6-case.test.js +++ b/__test__/0.1.6-case.test.js @@ -18,7 +18,7 @@ suiteCase.after.each(clear) suiteCase(`WELCOME`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.WELCOME).addAnswer('Bievenido') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -38,7 +38,7 @@ suiteCase(`WELCOME`, async ({ database, provider }) => { suiteCase(`MEDIA`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.MEDIA).addAnswer('media recibido') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -57,7 +57,7 @@ suiteCase(`MEDIA`, async ({ database, provider }) => { suiteCase(`LOCATION`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.LOCATION).addAnswer('location recibido') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -76,7 +76,7 @@ suiteCase(`LOCATION`, async ({ database, provider }) => { suiteCase(`DOCUMENT`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.DOCUMENT).addAnswer('document recibido') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), @@ -95,7 +95,7 @@ suiteCase(`DOCUMENT`, async ({ database, provider }) => { suiteCase(`VOICE_NOTE`, async ({ database, provider }) => { const flow = addKeyword(EVENTS.VOICE_NOTE).addAnswer('voice recibido') - createBot({ + await createBot({ database, provider, flow: createFlow([flow]), diff --git a/__test__/0.1.7-case.test.js b/__test__/0.1.7-case.test.js index de889a28d..bbc89e0e7 100644 --- a/__test__/0.1.7-case.test.js +++ b/__test__/0.1.7-case.test.js @@ -39,45 +39,45 @@ suiteCase(`Debe retornar un mensaje resumen`, async ({ database, provider }) => }) .addAnswer('🤖🤖 Gracias por tu participacion') - createBot({ + await createBot({ database, flow: createFlow([flujoPrincipal]), provider, }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'hola', }) - await provider.delaySendMessage(5, 'message', { + await provider.delaySendMessage(100, 'message', { from: '001', body: 'hola', }) - await provider.delaySendMessage(10, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'Leifer', }) - await provider.delaySendMessage(15, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: '90', }) - await provider.delaySendMessage(20, 'message', { + await provider.delaySendMessage(100, 'message', { from: '001', body: 'Maria', }) - await provider.delaySendMessage(25, 'message', { + await provider.delaySendMessage(100, 'message', { from: '001', body: '100', }) await delay(1000) const getHistory = database.listHistory.map((i) => i.answer) - assert.is(MOCK_VALUES[0], getHistory[0]) + assert.is('¿Cual es tu nombre?', getHistory[0]) assert.is('¿Cual es tu nombre?', getHistory[1]) assert.is('Leifer', getHistory[2]) assert.is('Gracias por tu nombre!', getHistory[3]) @@ -131,38 +131,38 @@ suiteCase(`Manejando globalState`, async ({ database, provider }) => { }) .addAnswer('🤖🤖 Gracias por tu participacion') - createBot({ + await createBot({ database, flow: createFlow([flujoPrincipal]), provider, }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'hola', }) - await provider.delaySendMessage(5, 'message', { + await provider.delaySendMessage(100, 'message', { from: '001', body: 'hola', }) - await provider.delaySendMessage(10, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'Leifer', }) - await provider.delaySendMessage(15, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: '90', }) - await provider.delaySendMessage(20, 'message', { + await provider.delaySendMessage(100, 'message', { from: '001', body: 'Maria', }) - await provider.delaySendMessage(25, 'message', { + await provider.delaySendMessage(100, 'message', { from: '001', body: '100', }) diff --git a/__test__/0.2.0-case.test.js b/__test__/0.2.0-case.test.js index 5957389ee..4b503e9a3 100644 --- a/__test__/0.2.0-case.test.js +++ b/__test__/0.2.0-case.test.js @@ -35,12 +35,12 @@ suiteCase(`Encadenanos addAction con captures`, async ({ database, provider }) = provider, }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'hola', }) - await provider.delaySendMessage(10, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'ping', }) @@ -58,4 +58,206 @@ suiteCase(`Encadenanos addAction con captures`, async ({ database, provider }) = assert.is(undefined, getHistory[8]) }) +suiteCase(`Encadenanos addAction con captures and gotoFlow`, async ({ database, provider }) => { + const flujoPrincipal = addKeyword(['hola']) + .addAction({ ref: `AAAA1111111111111111111` }, async (ctx, { flowDynamic }) => { + await flowDynamic(`Bienvenido a mi tienda`) + }) + .addAction({ ref: `BBB22222222` }, async (ctx, { flowDynamic }) => { + await flowDynamic(`escribe "ver ofertas"`) + }) + + const flujoSegundario = addKeyword(['ofertas']) + .addAction({ ref: `5555555555555` }, async (ctx, { flowDynamic }) => { + await flowDynamic(`Oferta A`) + }) + .addAction({ ref: `333333333333334` }, async (ctx, { flowDynamic }) => { + await flowDynamic(`Oferta B`) + }) + .addAction({ ref: `7777777777777744` }, async (ctx, { flowDynamic }) => { + await flowDynamic(`Oferta C`) + }) + .addAction({ ref: `9999999999444444` }, async (ctx, { flowDynamic }) => { + await flowDynamic(`¿Cual te interesa?`) + }) + .addAction({ ref: 'oooooooooooooooooo', capture: true }, async (ctx, { state, flowDynamic }) => { + await state.update({ res1: ctx.body }) + await flowDynamic(`¿Cual es tu email?`) + }) + .addAction({ ref: `pppppppppppppp`, capture: true }, async (ctx, { state, flowDynamic }) => { + await state.update({ res2: ctx.body }) + await flowDynamic(`Perfecto te desvio`) + }) + .addAction({ ref: `DDDDDDDDDDD` }, async (ctx, { gotoFlow }) => { + return gotoFlow(flujoTercero) + }) + + const flujoTercero = addKeyword(['ordenar']) + .addAction({ ref: `00000000000000000000000` }, async (ctx, { flowDynamic, state }) => { + await flowDynamic(`Gracias por el interes`) + }) + .addAction({ ref: `1111111111111111111` }, async (ctx, { flowDynamic }) => { + await flowDynamic(`Chao!`) + }) + await createBot({ + database, + flow: createFlow([flujoPrincipal, flujoSegundario, flujoTercero]), + provider, + }) + + await provider.delaySendMessage(100, 'message', { + from: '000', + body: 'hola', + }) + + await provider.delaySendMessage(150, 'message', { + from: '000', + body: 'ofertas', + }) + + await provider.delaySendMessage(200, 'message', { + from: '000', + body: 'Ibiza', + }) + + await provider.delaySendMessage(250, 'message', { + from: '000', + body: 'test@test.com', + }) + + await provider.delaySendMessage(300, 'message', { + from: '000', + body: 'hola', + }) + + await delay(8000) + const getHistory = database.listHistory.map((i) => i.answer) + assert.is('__capture_only_intended__', getHistory[0]) + assert.is('Bienvenido a mi tienda', getHistory[1]) + assert.is('__capture_only_intended__', getHistory[2]) + assert.is('escribe "ver ofertas"', getHistory[3]) + assert.is('ofertas', getHistory[4]) + assert.is('__capture_only_intended__', getHistory[5]) + assert.is('Oferta A', getHistory[6]) + assert.is('__capture_only_intended__', getHistory[7]) + assert.is('Oferta B', getHistory[8]) + assert.is('__capture_only_intended__', getHistory[9]) + assert.is('Oferta C', getHistory[10]) + assert.is('__capture_only_intended__', getHistory[11]) + assert.is('¿Cual te interesa?', getHistory[12]) + assert.is('__capture_only_intended__', getHistory[13]) + assert.is('Ibiza', getHistory[14]) + assert.is('¿Cual es tu email?', getHistory[15]) + assert.is('__capture_only_intended__', getHistory[16]) + assert.is('test@test.com', getHistory[17]) + assert.is('Perfecto te desvio', getHistory[18]) + assert.is('__capture_only_intended__', getHistory[19]) + assert.is('__capture_only_intended__', getHistory[20]) + assert.is('__capture_only_intended__', getHistory[21]) + assert.is('Gracias por el interes', getHistory[22]) + assert.is('Chao!', getHistory[23]) + assert.is('hola', getHistory[24]) + assert.is('__capture_only_intended__', getHistory[25]) + assert.is('Bienvenido a mi tienda', getHistory[26]) + assert.is('__capture_only_intended__', getHistory[27]) + assert.is('escribe "ver ofertas"', getHistory[28]) + assert.is(undefined, getHistory[29]) +}) + +suiteCase(`Encadenanos addAction con captures (infinity)`, async ({ database, provider }) => { + const flujoPrincipal = addKeyword(['hola']) + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic(`¡Bienvenido a ViajesExtemos!`) + }) + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic(`ver ofertas: Descubre las promociones que tengo para ti`) + }) + + const flujoSegundario = addKeyword(['ofertas']) + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic(`Perfecto te voy enviar los toures con imagenes`) + }) + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic([{ body: `Tour1`, media: 'http://image.img' }]) + }) + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic([{ body: `Tour2`, media: 'http://image.img' }]) + }) + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic([{ body: `¿Cual de estos tours te interesa?` }]) + }) + .addAction({ capture: true }, async (ctx, { flowDynamic }) => { + await flowDynamic([{ body: `¿Cual es tu email?` }]) + }) + .addAction({ capture: true }, async (ctx, { flowDynamic, gotoFlow }) => { + await flowDynamic([{ body: `Perfecto en pocoas minutos un agente se contactar contigo..` }]) + return gotoFlow(flujoTercero) + }) + + const flujoTercero = addKeyword('ordenar') + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic(`También me gustaria mencionar`) + }) + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic(`ping`) + }) + .addAction(async (ctx, { flowDynamic }) => { + await flowDynamic(`chao`) + }) + + await createBot({ + database, + flow: createFlow([flujoPrincipal, flujoSegundario, flujoTercero]), + provider, + }) + + await provider.delaySendMessage(100, 'message', { + from: '000', + body: 'hola', + }) + + await provider.delaySendMessage(150, 'message', { + from: '000', + body: 'ofertas', + }) + + await provider.delaySendMessage(200, 'message', { + from: '000', + body: 'ibiza', + }) + + await provider.delaySendMessage(250, 'message', { + from: '000', + body: 'test@test.com', + }) + + await delay(2000) + const getHistory = database.listHistory.map((i) => i.answer) + assert.is('__call_action__', getHistory[0]) + assert.is('¡Bienvenido a ViajesExtemos!', getHistory[1]) + assert.is('__call_action__', getHistory[2]) + assert.is('ver ofertas: Descubre las promociones que tengo para ti', getHistory[3]) + assert.is('ofertas', getHistory[4]) + assert.is('__call_action__', getHistory[5]) + assert.is('Perfecto te voy enviar los toures con imagenes', getHistory[6]) + assert.is('__call_action__', getHistory[7]) + assert.is('Tour1', getHistory[8]) + assert.is('__call_action__', getHistory[9]) + assert.is('Tour2', getHistory[10]) + assert.is('__call_action__', getHistory[11]) + assert.is('¿Cual de estos tours te interesa?', getHistory[12]) + assert.is('__capture_only_intended__', getHistory[13]) + assert.is('ibiza', getHistory[14]) + assert.is('¿Cual es tu email?', getHistory[15]) + assert.is('__capture_only_intended__', getHistory[16]) + assert.is('test@test.com', getHistory[17]) + assert.is('Perfecto en pocoas minutos un agente se contactar contigo..', getHistory[18]) + assert.is('__call_action__', getHistory[19]) + assert.is('__call_action__', getHistory[20]) + assert.is('__call_action__', getHistory[21]) + assert.is('También me gustaria mencionar', getHistory[22]) + assert.is('ping', getHistory[23]) + assert.is('chao', getHistory[24]) + assert.is(undefined, getHistory[25]) +}) suiteCase.run() diff --git a/__test__/0.2.1-case.test.js b/__test__/0.2.1-case.test.js index d30e8b8e8..ee461ab5e 100644 --- a/__test__/0.2.1-case.test.js +++ b/__test__/0.2.1-case.test.js @@ -29,12 +29,12 @@ suiteCase(`Prevenir enviar mensaje luego de inactividad (2seg)`, async ({ databa provider, }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'hola', }) - await provider.delaySendMessage(50, 'message', { + await provider.delaySendMessage(150, 'message', { from: '000', body: 'mensaje al segundo', }) @@ -68,7 +68,7 @@ suiteCase(`Enviar mensaje luego de inactividad (2seg)`, async ({ database, provi provider, }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'hola', }) @@ -87,23 +87,27 @@ suiteCase(`Enviar mensajes con ambos casos de idle`, async ({ database, provider await flowDynamic(`Empezemos de nuevo.`) await flowDynamic(`Cual es el numero de orden? tienes dos segundos para responder...`) }) - .addAction({ capture: true, idle: 2000 }, async (ctx, { flowDynamic }) => { + .addAction({ capture: true, idle: 2000, ref: '🙉🙉🙉🙉🙉🙉🙉🙉' }, async (ctx, { flowDynamic }) => { if (ctx?.idleFallBack) { + console.log(`[seundo desvio]`) + console.log(`[idleFallBack]:`, ctx) return flowDynamic(`BYE!`) } await flowDynamic(`Ok el numero que escribiste es ${ctx.body}`) }) .addAnswer('gracias!') - const flujoPrincipal = addKeyword(['hola']).addAnswer( - 'Hola tienes 2 segundos para responder si no te pedire de nuevo otro dato', - { idle: 2000, capture: true }, - async (ctx, { gotoFlow }) => { - if (ctx?.idleFallBack) { - return gotoFlow(flujoFinal) + const flujoPrincipal = addKeyword(['hola']) + .addAnswer( + 'Hola tienes 2 segundos para responder si no te pedire de nuevo otro dato', + { idle: 2000, capture: true, ref: '😪😪😪😪😪😪' }, + async (ctx, { gotoFlow }) => { + if (ctx?.idleFallBack) { + return gotoFlow(flujoFinal) + } } - } - ) + ) + .addAnswer('Esto no debe de existir') await createBot({ database, @@ -111,13 +115,12 @@ suiteCase(`Enviar mensajes con ambos casos de idle`, async ({ database, provider provider, }) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(100, 'message', { from: '000', body: 'hola', }) - await delay(2100) - await provider.delaySendMessage(0, 'message', { + await provider.delaySendMessage(3000, 'message', { from: '000', body: 'el numero es 444', }) @@ -128,13 +131,56 @@ suiteCase(`Enviar mensajes con ambos casos de idle`, async ({ database, provider assert.is('Hola tienes 2 segundos para responder si no te pedire de nuevo otro dato', getHistory[0]) assert.is('Se cancelo por inactividad', getHistory[1]) assert.is('__call_action__', getHistory[2]) - assert.is('Empezemos de nuevo.', getHistory[3]) - assert.is('Cual es el numero de orden? tienes dos segundos para responder...', getHistory[4]) - assert.is('__capture_only_intended__', getHistory[5]) + assert.is('__capture_only_intended__', getHistory[3]) + assert.is('Empezemos de nuevo.', getHistory[4]) + assert.is('Cual es el numero de orden? tienes dos segundos para responder...', getHistory[5]) assert.is('el numero es 444', getHistory[6]) assert.is('Ok el numero que escribiste es el numero es 444', getHistory[7]) assert.is('gracias!', getHistory[8]) assert.is(undefined, getHistory[9]) }) +suiteCase(`Enviar mensaje con gotoFlow anidados`, async ({ database, provider }) => { + const flujoA = addKeyword(EVENTS.WELCOME) + .addAnswer('Bievenido!') + .addAction(async (_, { gotoFlow }) => { + return gotoFlow(flujoB) + }) + + const flujoB = addKeyword(EVENTS.ACTION) + .addAnswer( + 'Esto debe responderse en menos de 2 seg', + { idle: 2000, capture: true }, + async (ctx, { gotoFlow }) => { + if (ctx?.idleFallBack) { + return gotoFlow(flujoC) + } + } + ) + .addAnswer('Respondiste!!') + + const flujoC = addKeyword(EVENTS.ACTION).addAnswer('Chaooo paso el tiempo') + + await createBot({ + database, + flow: createFlow([flujoA, flujoB, flujoC]), + provider, + }) + + await provider.delaySendMessage(100, 'message', { + from: '000', + body: 'hola', + }) + + await delay(5000) + + const getHistory = database.listHistory.map((i) => i.answer) + assert.is('Bievenido!', getHistory[0]) + assert.is('__call_action__', getHistory[1]) + assert.is('__call_action__', getHistory[2]) + assert.is('Esto debe responderse en menos de 2 seg', getHistory[3]) + assert.is('Chaooo paso el tiempo', getHistory[4]) + assert.is(undefined, getHistory[5]) +}) + suiteCase.run() diff --git a/package.json b/package.json index 4b0e38799..c93907430 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@bot-whatsapp/root", - "version": "0.1.32", + "version": "0.1.33", "description": "Bot de wahtsapp open source para MVP o pequeños negocios", "main": "app.js", "private": true, @@ -12,16 +12,17 @@ "provider:rollup": "rollup --config ./packages/provider/rollup-provider.config.js ", "contexts:rollup": "rollup --config ./packages/contexts/rollup-contexts.config.js", "database:rollup": "rollup --config ./packages/database/rollup-database.config.js", + "eslint-plugin:rollup": "rollup --config ./packages/eslint-plugin-bot-whatsapp/rollup-eslint.config.js", "create-bot-whatsapp:rollup": "rollup --config ./packages/create-bot-whatsapp/rollup-create.config.js", "portal:rollup": "rollup --config ./packages/portal/rollup-portal.config.js", "format:check": "prettier --check ./packages", "format:write": "prettier --write ./packages", "fmt.staged": "pretty-quick --staged", - "lint:check": "eslint ./packages", + "lint:check": "eslint .", "lint:fix": "eslint --fix ./packages", "build:portal-web": "cd ./packages/portal/ && pnpm run build.types && pnpm run build.client && pnpm run build.server && pnpm run lint --fix", "build:full": "pnpm run build:portal-web && pnpm run cli:rollup && pnpm run bot:rollup && pnpm run provider:rollup && pnpm run database:rollup && pnpm run contexts:rollup && pnpm run create-bot-whatsapp:rollup && pnpm run portal:rollup", - "build": "pnpm run cli:rollup && pnpm run bot:rollup && pnpm run provider:rollup && pnpm run database:rollup && pnpm run contexts:rollup && pnpm run create-bot-whatsapp:rollup && pnpm run portal:rollup", + "build": "pnpm run cli:rollup && pnpm run bot:rollup && pnpm run provider:rollup && pnpm run database:rollup && pnpm run contexts:rollup && pnpm run create-bot-whatsapp:rollup && pnpm run portal:rollup && pnpm run eslint-plugin:rollup", "copy.lib": "node ./scripts/move.js", "test.unit": "node ./node_modules/uvu/bin.js packages test", "test.e2e": "node ./node_modules/uvu/bin.js __test__", @@ -55,32 +56,32 @@ "repository": "https://github.com/leifermendez/bot-whatsapp", "license": "ISC", "devDependencies": { - "@commitlint/cli": "^17.4.4", - "@rollup/plugin-strip": "^3.0.2", - "@commitlint/config-conventional": "^17.4.4", - "@octokit/core": "^4.2.0", + "@commitlint/cli": "^17.8.1", + "@commitlint/config-conventional": "^17.8.1", + "@octokit/core": "^4.2.4", "@rollup/plugin-commonjs": "^23.0.7", "@rollup/plugin-json": "^5.0.2", - "@rollup/plugin-node-resolve": "^15.0.1", - "@rollup/plugin-replace": "^5.0.2", - "c8": "^7.13.0", + "@rollup/plugin-node-resolve": "^15.2.3", + "@rollup/plugin-replace": "^5.0.4", + "@rollup/plugin-strip": "^3.0.4", + "c8": "^7.14.0", "conventional-changelog": "^3.1.25", "cross-env": "^7.0.3", - "eslint": "^8.34.0", - "eslint-config-prettier": "^8.6.0", - "fs-extra": "^11.1.0", + "eslint": "^8.52.0", + "eslint-config-prettier": "^8.10.0", + "fs-extra": "^11.1.1", "git-cz": "^4.9.0", "husky": "^8.0.3", "mime-types": "^2.1.35", - "only-allow": "^1.1.1", - "prettier": "^2.8.4", + "only-allow": "^1.2.1", + "prettier": "^2.8.8", "pretty-quick": "^3.1.3", "prompts": "^2.4.2", - "rimraf": "^4.1.2", - "rollup": "^3.17.2", + "rimraf": "^4.4.1", + "rollup": "^3.29.4", "rollup-plugin-cleanup": "^3.2.1", - "rollup-plugin-copy": "^3.4.0", - "semver": "^7.3.8", + "rollup-plugin-copy": "^3.5.0", + "semver": "^7.5.4", "standard-version": "^9.5.0", "uvu": "^0.5.6" }, diff --git a/packages/bot/context/idleState.class.js b/packages/bot/context/idleState.class.js index 8b28e50cc..5a94f793a 100755 --- a/packages/bot/context/idleState.class.js +++ b/packages/bot/context/idleState.class.js @@ -1,40 +1,43 @@ class IdleState { - index = new Map() - indexInterval = new Map() - indexEnd = new Map() + indexCb = new Map() - setIdleTime = (inRef, timeInSeconds) => { - this.stop(inRef) - const currentTime = new Date().getTime() - const endTime = currentTime + timeInSeconds * 1000 - if (!this.index.has(inRef)) this.index.set(inRef, timeInSeconds) - if (!this.indexInterval.has(inRef)) this.indexInterval.set(inRef, null) - if (!this.indexEnd.has(inRef)) this.indexEnd.set(inRef, endTime) - } + setIdleTime = ({ from, inRef, timeInSeconds, cb }) => { + const startTime = new Date().getTime() + const endTime = startTime + timeInSeconds * 1000 - start = (inRef, cb = () => null) => { - const refTimer = this.index.get(inRef) ?? undefined - if (refTimer) { - const interval = setInterval(() => { - const currentTime = new Date().getTime() - const endTime = this.indexEnd.get(inRef) - if (currentTime > endTime) { - this.stop(inRef) - cb() - } - }, 1000) + if (!this.indexCb.has(from)) this.indexCb.set(from, []) + const queueCb = this.indexCb.get(from) - this.indexInterval.set(inRef, interval) - } + const interval = setInterval(() => { + const internalTime = new Date().getTime() + if (internalTime > endTime) { + cb({ next: true, inRef }) + const map = this.indexCb.get(from) ?? [] + const index = map.findIndex((o) => o.inRef === inRef) + clearInterval(interval) + map.splice(index, 1) + } + }, 1000) + + queueCb.push({ + from, + inRef, + cb, + stop: (ctxInComming) => { + cb({ ...ctxInComming, next: false, inRef }) + clearInterval(interval) + }, + }) } - stop = (inRef) => { + stop = (ctxInComming) => { try { - clearInterval(this.indexInterval.get(inRef)) - this.index.delete(inRef) - this.indexInterval.delete(inRef) - this.indexEnd.delete(inRef) + const queueCb = this.indexCb.get(ctxInComming.from) ?? [] + for (const iterator of queueCb) { + iterator.stop(ctxInComming) + } } catch (err) { + console.log(err) return null } } diff --git a/packages/bot/core/core.class.js b/packages/bot/core/core.class.js index 1d7a8d988..e69fe5911 100644 --- a/packages/bot/core/core.class.js +++ b/packages/bot/core/core.class.js @@ -9,7 +9,6 @@ const Queue = require('../utils/queue') const { LIST_REGEX } = require('../io/events') const SingleState = require('../context/state.class') const GlobalState = require('../context/globalState.class') -const { generateTime } = require('../utils/hash') const IdleState = require('../context/idleState.class') const logger = new Console({ @@ -20,6 +19,7 @@ const loggerQueue = new Console({ }) const idleForCallback = new IdleState() +const DynamicBlacklist = require('../utils/blacklist.class') /** * [ ] Escuchar eventos del provider asegurarte que los provider emitan eventos @@ -34,6 +34,7 @@ class CoreClass extends EventEmitter { queuePrincipal stateHandler = new SingleState() globalStateHandler = new GlobalState() + dynamicBlacklist = new DynamicBlacklist() generalArgs = { blackList: [], listEvents: {}, @@ -51,6 +52,7 @@ class CoreClass extends EventEmitter { this.databaseClass = _database this.providerClass = _provider this.generalArgs = { ...this.generalArgs, ..._args } + this.dynamicBlacklist.add(this.generalArgs.blackList) this.queuePrincipal = new Queue( loggerQueue, @@ -104,11 +106,12 @@ class CoreClass extends EventEmitter { */ handleMsg = async (messageCtxInComming) => { logger.log(`[handleMsg]: `, messageCtxInComming) + idleForCallback.stop(messageCtxInComming) const { body, from } = messageCtxInComming let msgToSend = [] let endFlowFlag = false let fallBackFlag = false - if (this.generalArgs.blackList.includes(from)) return + if (this.dynamicBlacklist.checkIf(from)) return if (!body) return let prevMsg = await this.databaseClass.getPrevByNumber(from) @@ -151,11 +154,12 @@ class CoreClass extends EventEmitter { const buttons = payload?.buttons ?? [] const capture = payload?.capture ?? false const delay = payload?.delay ?? 0 + const keyword = payload?.keyword ?? null return toCtx({ body, from, - keyword: null, + keyword, index, options: { media, buttons, capture, delay }, }) @@ -170,10 +174,23 @@ class CoreClass extends EventEmitter { // 📄 Finalizar flujo const endFlow = (flag) => - async (message = null) => { + async (messages = null) => { flag.endFlow = true endFlowFlag = true - if (message) this.sendProviderAndSave(from, createCtxMessage(message)) + if (typeof messages === 'string') { + await this.sendProviderAndSave(from, createCtxMessage(messages)) + } + + // Procesos de callback que se deben execute como exepciones + if (Array.isArray(messages)) { + for (const iteratorCtxMessage of messages) { + await resolveCbEveryCtx(iteratorCtxMessage, { + omitEndFlow: true, + idleCtx: !!iteratorCtxMessage?.options?.idle, + triggerKey: iteratorCtxMessage.keyword.startsWith('key_'), + }) + } + } clearQueue() return } @@ -192,15 +209,13 @@ class CoreClass extends EventEmitter { } const delayMs = ctxMessage?.options?.delay ?? this.generalArgs.delay ?? 0 - if (delayMs) { - await delay(delayMs) // Esperar según el retraso configurado - } + await delay(delayMs) //TODO el proceso de forzar cola de procsos if (options?.forceQueue) { const listIdsRefCallbacks = messageToSend.map((i) => i.ref) - const listProcessWait = this.queuePrincipal.getIdsCallbacs(from) + const listProcessWait = this.queuePrincipal.getIdsCallback(from) if (!listProcessWait.length) { this.queuePrincipal.setIdsCallbacks(from, listIdsRefCallbacks) } else { @@ -213,28 +228,34 @@ class CoreClass extends EventEmitter { } try { + // this.queuePrincipal.clearQueue(from); await this.queuePrincipal.enqueue( from, async () => { // Usar async en la función pasada a enqueue - await this.sendProviderAndSave(numberOrId, ctxMessage) + await this.sendProviderAndSave(numberOrId, ctxMessage).then(() => + resolveCbEveryCtx(ctxMessage) + ) logger.log(`[QUEUE_SE_ENVIO]: `, ctxMessage) - await resolveCbEveryCtx(ctxMessage) + // await resolveCbEveryCtx(ctxMessage) }, ctxMessage.ref ) } catch (error) { logger.error(`Error al encolar (ID ${ctxMessage.ref}):`, error) - return Promise.reject + return Promise.reject() // Puedes considerar manejar el error aquí o rechazar la promesa // Pasada a resolveCbEveryCtx con el error correspondiente. } } } - const continueFlow = async () => { + const continueFlow = async (initRef = undefined) => { const currentPrev = await this.databaseClass.getPrevByNumber(from) - const nextFlow = (await this.flowClass.find(refToContinue?.ref, true)) ?? [] + let nextFlow = (await this.flowClass.find(refToContinue?.ref, true)) ?? [] + if (initRef && !initRef?.idleFallBack) { + nextFlow = (await this.flowClass.find(initRef?.ref, true)) ?? [] + } const filterNextFlow = nextFlow.filter((msg) => msg.refSerialize !== currentPrev?.refSerialize) const isContinueFlow = filterNextFlow.map((i) => i.keyword).includes(currentPrev?.ref) @@ -269,17 +290,40 @@ class CoreClass extends EventEmitter { const gotoFlow = (flag) => async (flowInstance, step = 0) => { + const promises = [] flag.gotoFlow = true + + if (!flowInstance?.toJson) { + printer([ + `[CIRCULAR_DEPENDENCY]: Se ha detectado una dependencia circular.`, + `Para evitar problemas, te recomendamos utilizar 'require'('./ruta_del_flow')`, + `Ejemplo: gotoFlow(helloFlow) --> gotoFlow(require('./flows/helloFlow.js'))`, + `[INFO]: https://bot-whatsapp.netlify.app/docs/goto-flow/`, + ]) + return + } + const flowTree = flowInstance.toJson() + const flowParentId = flowTree[step] + + if (endFlowFlag) { + return + } + const parseListMsg = await this.flowClass.find(flowParentId?.ref, true, flowTree) - if (endFlowFlag) return + for (const msg of parseListMsg) { const msgParse = this.flowClass.findSerializeByRef(msg?.ref) + const ctxMessage = { ...msgParse, ...msg } - await this.sendProviderAndSave(from, ctxMessage).then(() => resolveCbEveryCtx(ctxMessage)) + + // Enviar el mensaje al proveedor y guardarlo + await this.sendProviderAndSave(from, ctxMessage).then(() => promises.push(ctxMessage)) } - await endFlow(flag)() + + await endFlow(flag)(promises) + return } @@ -287,40 +331,70 @@ class CoreClass extends EventEmitter { // para evitar bloque de whatsapp const flowDynamic = - (flag) => + (flag, inRef, privateOptions) => async (listMsg = [], options = { continue: true }) => { - if (!options.hasOwnProperty('continue')) options = { ...options, continue: true } + if (!options.hasOwnProperty('continue')) { + options = { ...options, continue: true } + } flag.flowDynamic = true - if (!Array.isArray(listMsg)) listMsg = [{ body: listMsg, ...options }] + + if (!Array.isArray(listMsg)) { + listMsg = [{ body: listMsg, ...options }] + } + const parseListMsg = listMsg.map((opt, index) => createCtxMessage(opt, index)) - if (endFlowFlag) return - this.queuePrincipal.setFingerTime(from, generateTime()) //aqui debeo decirle al sistema como que finalizo el flujo + // Si endFlowFlag existe y no se omite la finalización del flujo, no hacer nada. + if (endFlowFlag && !privateOptions?.omitEndFlow) { + return + } + + this.queuePrincipal.setFingerTime(from, inRef) // Debe decirle al sistema que finalizó el flujo aquí. + for (const msg of parseListMsg) { + if (privateOptions?.idleCtx) { + continue // Saltar al siguiente mensaje si se está en modo idleCtx. + } + const delayMs = msg?.options?.delay ?? this.generalArgs.delay ?? 0 - if (delayMs) await delay(delayMs) + await delay(delayMs) await this.sendProviderAndSave(from, msg) } - if (options?.continue) await continueFlow(generateTime()) + if (options?.continue) { + await continueFlow() + return + } return } // 📄 Se encarga de revisar si el contexto del mensaje tiene callback o idle - const resolveCbEveryCtx = async (ctxMessage) => { + const resolveCbEveryCtx = async ( + ctxMessage, + options = { omitEndFlow: false, idleCtx: false, triggerKey: false } + ) => { if (!!ctxMessage?.options?.idle && !ctxMessage?.options?.capture) { printer( `[ATENCION IDLE]: La función "idle" no tendrá efecto a menos que habilites la opción "capture:true". Por favor, asegúrate de configurar "capture:true" o elimina la función "idle"` ) } - if (ctxMessage?.options?.idle) return await cbEveryCtx(ctxMessage?.ref, ctxMessage?.options?.idle) - if (!ctxMessage?.options?.capture) return await cbEveryCtx(ctxMessage?.ref) + if (ctxMessage?.options?.idle) { + await cbEveryCtx(ctxMessage?.ref, { ...options, startIdleMs: ctxMessage?.options?.idle }) + return + } + if (!ctxMessage?.options?.capture) { + await cbEveryCtx(ctxMessage?.ref, options) + return + } } // 📄 Se encarga de revisar si el contexto del mensaje tiene callback y ejecutarlo - const cbEveryCtx = async (inRef, startIdleMs = 0) => { - let flags = { + const cbEveryCtx = async ( + inRef, + options = { startIdleMs: 0, omitEndFlow: false, idleCtx: false, triggerKey: false } + ) => { + const flags = { endFlow: false, fallBack: false, flowDynamic: false, @@ -337,27 +411,44 @@ class CoreClass extends EventEmitter { state, globalState, extensions, + queue: this.queuePrincipal, idle: idleForCallback, inRef, fallBack: fallBack(flags), - flowDynamic: flowDynamic(flags), + flowDynamic: flowDynamic(flags, inRef, options), endFlow: endFlow(flags), gotoFlow: gotoFlow(flags), } - idleForCallback.stop(inRef) - const runContext = async (continueAfterIdle = true, overCtx = {}) => { + const runContext = async (continueAfterIdle = false, overCtx = {}) => { messageCtxInComming = { ...messageCtxInComming, ...overCtx } + + if (options?.idleCtx && !options?.triggerKey) { + return + } + await this.flowClass.allCallbacks[inRef](messageCtxInComming, argsCb) //Si no hay llamado de fallaback y no hay llamado de flowDynamic y no hay llamado de enflow EL flujo continua + if (continueAfterIdle) { + await continueFlow(overCtx) + return + } const ifContinue = !flags.endFlow && !flags.fallBack && !flags.flowDynamic - if (ifContinue && continueAfterIdle) await continueFlow(prevMsg?.options?.nested?.length) + if (ifContinue) { + await continueFlow() + return + } } - if (startIdleMs > 0) { - idleForCallback.setIdleTime(inRef, startIdleMs / 1000) - idleForCallback.start(inRef, async () => { - await runContext(false, { idleFallBack: !!startIdleMs, from: null, body: null }) + if (options.startIdleMs > 0) { + idleForCallback.setIdleTime({ + from, + inRef, + timeInSeconds: options.startIdleMs / 1000, + cb: async (opts) => { + endFlowFlag = false + await runContext(true, { idleFallBack: opts.next, ref: opts.inRef, body: opts.body }) + }, }) return } @@ -428,6 +519,14 @@ class CoreClass extends EventEmitter { if (LIST_REGEX.REGEX_EVENT_VOICE_NOTE.test(body)) { msgToSend = this.flowClass.find(this.generalArgs.listEvents.VOICE_NOTE) || [] } + + if (LIST_REGEX.REGEX_EVENT_ORDER.test(body)) { + msgToSend = this.flowClass.find(this.generalArgs.listEvents.ORDER) || [] + } + + if (LIST_REGEX.REGEX_EVENT_TEMPLATE.test(body)) { + msgToSend = this.flowClass.find(this.generalArgs.listEvents.TEMPLATE) || [] + } } return exportFunctionsSend(() => sendFlow(msgToSend, from, { forceQueue: true })) } @@ -441,7 +540,7 @@ class CoreClass extends EventEmitter { sendProviderAndSave = async (numberOrId, ctxMessage) => { try { const { answer } = ctxMessage - if (answer && answer.length && answer !== '__call_action__') { + if (answer && answer.length && answer !== '__call_action__' && answer !== '__goto_flow__') { if (answer !== '__capture_only_intended__') { await this.providerClass.sendMessage(numberOrId, answer, ctxMessage) this.emit('send_message', { numberOrId, answer, ctxMessage }) @@ -449,10 +548,10 @@ class CoreClass extends EventEmitter { } await this.databaseClass.save({ ...ctxMessage, from: numberOrId }) - return Promise.resolve + return Promise.resolve() } catch (err) { logger.log(`[ERROR ID (${ctxMessage.ref})]: `, err) - return Promise.reject + return Promise.reject() } } @@ -481,7 +580,7 @@ class CoreClass extends EventEmitter { sendFlowSimple = async (messageToSend, numberOrId) => { for (const ctxMessage of messageToSend) { const delayMs = ctxMessage?.options?.delay ?? this.generalArgs.delay ?? 0 - if (delayMs) await delay(delayMs) + await delay(delayMs) await this.queuePrincipal.enqueue( numberOrId, () => this.sendProviderAndSave(numberOrId, ctxMessage), diff --git a/packages/bot/index.js b/packages/bot/index.js index f5e4c71bb..118688418 100644 --- a/packages/bot/index.js +++ b/packages/bot/index.js @@ -7,7 +7,20 @@ const { LIST_ALL: EVENTS } = require('./io/events') /** * Crear instancia de clase Bot * @param {*} args - * @returns + * @returns {CoreClass} + * @property {Flow} `flowClass` - Instancia de la clase Flow. + * @property {Database} `databaseClass` - Instancia de la clase Database. + * @property {Provider} `providerClass` - Instancia de la clase Provider. + * @property {Queue} `queuePrincipal` - Instancia de la clase Queue. + * @property {SingleState} `stateHandler` - Instancia de la clase SingleState. + * @property {GlobalState} `globalStateHandler` - Instancia de la clase GlobalState. + * @property {Object} `generalArgs` - Argumentos generales que incluyen: + * - blackList: Un array de elementos en la lista negra. + * - listEvents: Un objeto que almacena eventos. + * - delay: Valor de retraso. + * - globalState: Un objeto que almacena el estado global. + * - extensions: Extensiones, si están definidas. + * - queue: Configuración de la cola que incluye timeout y límite de concurrencia. */ const createBot = async ({ flow, database, provider }, args = {}) => new CoreClass(flow, database, provider, { ...args, listEvents: EVENTS }) diff --git a/packages/bot/io/events/eventOrder.js b/packages/bot/io/events/eventOrder.js new file mode 100644 index 000000000..74c6ee81d --- /dev/null +++ b/packages/bot/io/events/eventOrder.js @@ -0,0 +1,9 @@ +const { generateRef } = require('../../utils/hash') + +const eventOrder = () => { + return generateRef('_event_order_') +} + +const REGEX_EVENT_ORDER = /^_event_order__[\w\d]{8}-(?:[\w\d]{4}-){3}[\w\d]{12}$/ + +module.exports = { eventOrder, REGEX_EVENT_ORDER } diff --git a/packages/bot/io/events/eventTemplate.js b/packages/bot/io/events/eventTemplate.js new file mode 100644 index 000000000..e34155ab4 --- /dev/null +++ b/packages/bot/io/events/eventTemplate.js @@ -0,0 +1,9 @@ +const { generateRef } = require('../../utils/hash') + +const eventTemplate = () => { + return generateRef('_event_template_') +} + +const REGEX_EVENT_TEMPLATE = /^_event_template__[\w\d]{8}-(?:[\w\d]{4}-){3}[\w\d]{12}$/ + +module.exports = { eventTemplate, REGEX_EVENT_TEMPLATE } diff --git a/packages/bot/io/events/index.js b/packages/bot/io/events/index.js index 7a51877f6..68b123700 100644 --- a/packages/bot/io/events/index.js +++ b/packages/bot/io/events/index.js @@ -2,6 +2,8 @@ const { eventDocument, REGEX_EVENT_DOCUMENT } = require('./eventDocument') const { eventLocation, REGEX_EVENT_LOCATION } = require('./eventLocation') const { eventMedia, REGEX_EVENT_MEDIA } = require('./eventMedia') const { eventVoiceNote, REGEX_EVENT_VOICE_NOTE } = require('./eventVoiceNote') +const { eventOrder, REGEX_EVENT_ORDER } = require('./eventOrder') +const { eventTemplate, REGEX_EVENT_TEMPLATE } = require('./eventTemplate') const { eventWelcome } = require('./eventWelcome') const { eventAction } = require('./eventAction') @@ -12,6 +14,8 @@ const LIST_ALL = { DOCUMENT: eventDocument(), VOICE_NOTE: eventVoiceNote(), ACTION: eventAction(), + ORDER: eventOrder(), + TEMPLATE: eventTemplate() } const LIST_REGEX = { @@ -19,6 +23,8 @@ const LIST_REGEX = { REGEX_EVENT_LOCATION, REGEX_EVENT_MEDIA, REGEX_EVENT_VOICE_NOTE, + REGEX_EVENT_ORDER, + REGEX_EVENT_TEMPLATE } -module.exports = { LIST_ALL, LIST_REGEX } +module.exports = { LIST_ALL, LIST_REGEX } \ No newline at end of file diff --git a/packages/bot/io/flow.class.js b/packages/bot/io/flow.class.js index 306d5b9cf..7c06f894a 100644 --- a/packages/bot/io/flow.class.js +++ b/packages/bot/io/flow.class.js @@ -1,13 +1,18 @@ const { toSerialize } = require('./methods/toSerialize') const { flatObject } = require('../utils/flattener') +/** + * Esta clas se encarga de manera la manipulacion de los flows + * y la creaciones de indices donde almacenar los callbacks + */ class FlowClass { allCallbacks = [] flowSerialize = [] flowRaw = [] + constructor(_flow) { if (!Array.isArray(_flow)) throw new Error('Esto debe ser un ARRAY') - this.flowRaw = _flow + this.flowRaw = this.addEndsFlows(_flow) this.allCallbacks = flatObject(_flow) @@ -18,6 +23,28 @@ class FlowClass { this.flowSerialize = toSerialize(mergeToJsonSerialize) } + /** + * Agregamos un addAcion con un endFlow + * al finalizar el flow para limpiar rendimiento, colas, etc + * @param {*} _flows + * @returns + */ + addEndsFlows = (_flows) => { + return _flows.map((flow) => + flow.addAction(async (_, { endFlow }) => { + return endFlow() + }) + ) + } + + /** + * Funcion principal encargada de devolver un array de mensajes a continuar + * la idea es basado en un ref o id devolver la lista de mensaes a enviar + * @param {*} keyOrWord + * @param {*} symbol + * @param {*} overFlow + * @returns + */ find = (keyOrWord, symbol = false, overFlow = null) => { keyOrWord = `${keyOrWord}` let capture = false @@ -83,6 +110,11 @@ class FlowClass { } } + /** + * El proposito es cargar los flows y la serializacion de los callbacks + * a los flows qu son hijos + * @returns + */ getFlowsChild = () => { try { const flowChilds = this.flowSerialize diff --git a/packages/bot/io/methods/addAnswer.js b/packages/bot/io/methods/addAnswer.js index 706aa201c..a2419acd7 100644 --- a/packages/bot/io/methods/addAnswer.js +++ b/packages/bot/io/methods/addAnswer.js @@ -23,6 +23,7 @@ const addAnswer = child: typeof options?.child === 'string' ? `${options?.child}` : null, delay: typeof options?.delay === 'number' ? options?.delay : 0, idle: typeof options?.idle === 'number' ? options?.idle : null, + ref: typeof options?.ref === 'string' ? options?.ref : null, }) const getNested = () => { @@ -57,14 +58,13 @@ const addAnswer = * @returns */ const ctxAnswer = () => { - const ref = `ans_${generateRef()}` - const options = { ...getAnswerOptions(), ...getNested(), keyword: {}, callback: !!cb, } + const ref = options?.ref ?? `ans_${generateRef()}` const json = [].concat(inCtx.json).concat([ { diff --git a/packages/bot/io/methods/addKeyword.js b/packages/bot/io/methods/addKeyword.js index e4d545dff..30905d416 100644 --- a/packages/bot/io/methods/addKeyword.js +++ b/packages/bot/io/methods/addKeyword.js @@ -44,7 +44,10 @@ const addKeyword = (keyword, options) => { ctx, ref: ctx.ref, addAnswer: addAnswer(ctx), - addAction: (cb = () => null) => addAnswer(ctx)('__call_action__', null, cb), + addAction: (cb = () => null, flagCb = () => null) => { + if (typeof cb === 'object') return addAnswer(ctx)('__capture_only_intended__', cb, flagCb) + return addAnswer(ctx)('__call_action__', null, cb) + }, toJson: toJson(ctx), } } diff --git a/packages/bot/io/methods/toCtx.js b/packages/bot/io/methods/toCtx.js index 980cbfb62..4a5acc300 100644 --- a/packages/bot/io/methods/toCtx.js +++ b/packages/bot/io/methods/toCtx.js @@ -5,10 +5,10 @@ const { generateRef, generateRefSerialize } = require('../../utils/hash') * @param options {media:string, buttons:[], capture:true default false} * @returns */ -const toCtx = ({ body, from, prevRef, options = {}, index }) => { +const toCtx = ({ body, from, prevRef, keyword, options = {}, index }) => { return { ref: generateRef(), - keyword: prevRef, + keyword: prevRef ?? keyword, answer: body, options: options ?? {}, from, diff --git a/packages/bot/package.json b/packages/bot/package.json index b5db8468c..83aadf683 100644 --- a/packages/bot/package.json +++ b/packages/bot/package.json @@ -1,6 +1,6 @@ { "name": "@bot-whatsapp/bot", - "version": "0.0.183-alpha.0", + "version": "0.0.204-alpha.0", "description": "", "main": "./lib/bundle.bot.cjs", "scripts": { diff --git a/packages/bot/tests/bot.class.test.js b/packages/bot/tests/bot.class.test.js index 96d2c0e65..6876a39f3 100644 --- a/packages/bot/tests/bot.class.test.js +++ b/packages/bot/tests/bot.class.test.js @@ -373,6 +373,33 @@ test(`[Bot] Probando gotoFlow `, async () => { assert.is(Object.values(result).length, 0) }) +test(`[Bot] Probando flowDynamic `, async () => { + const mockProvider = new MockProvider() + const flowWelcome = addKeyword('hola').addAnswer('chao') + const flow = createFlow([flowWelcome]) + const setting = { + flow, + database: new MockDBB(), + provider: mockProvider, + } + + const bot = await createBot(setting) + + const messageCtxInComming = { + body: 'Hola', + from: '123456789', + } + + const botHandler = await bot.handleMsg(messageCtxInComming) + const result = botHandler.flowDynamic([ + { + body: 'Message', + }, + ])(flowWelcome) + + assert.is(Object.values(result).length, 0) +}) + test.run() function delay(ms) { diff --git a/packages/bot/utils/blacklist.class.js b/packages/bot/utils/blacklist.class.js new file mode 100644 index 000000000..85e1e710b --- /dev/null +++ b/packages/bot/utils/blacklist.class.js @@ -0,0 +1,80 @@ +class BlackListClass { + #blacklist = new Set() + + /** + * Constructor para inicializar la lista negra. + * @param {Array} initialNumbers - Lista inicial de números a bloquear. + */ + constructor(initialNumbers = []) { + this.add(initialNumbers) + } + + /** + * Excepción lanzada cuando un número ya existe en la lista negra. + */ + static PhoneNumberAlreadyExistsError = class extends Error { + constructor(phoneNumber) { + super(`El número de teléfono ${phoneNumber} ya está en la lista negra.`) + this.name = 'PhoneNumberAlreadyExistsError' + } + } + + /** + * Excepción lanzada cuando un número no se encuentra en la lista negra. + */ + static PhoneNumberNotFoundError = class extends Error { + constructor(phoneNumber) { + super(`El número de teléfono ${phoneNumber} no está en la lista negra.`) + this.name = 'PhoneNumberNotFoundError' + } + } + + /** + * Añade uno o varios números de teléfono a la lista negra. + * @param {string | Array} phoneNumbers - Número o números a añadir. + * @returns {Array} - Devuelve una lista de mensajes indicando el resultado de añadir cada número. + */ + add(...phoneNumbers) { + const responseMessages = [] + + phoneNumbers.flat().forEach((number) => { + if (this.#blacklist.has(number)) { + responseMessages.push(`El número de teléfono ${number} ya está en la lista negra.`) + } else { + this.#blacklist.add(number) + responseMessages.push(`Número ${number} añadido exitosamente.`) + } + }) + + return responseMessages + } + + /** + * Elimina un número de teléfono de la lista negra. + * @param {string} phoneNumber - El número a eliminar. + */ + remove(phoneNumber) { + if (!this.#blacklist.has(phoneNumber)) { + throw new BlackListClass.PhoneNumberNotFoundError(phoneNumber) + } + this.#blacklist.delete(phoneNumber) + } + + /** + * Verifica si un número de teléfono está en la lista negra. + * @param {string} phoneNumber - El número a verificar. + * @returns {boolean} - Verdadero si está en la lista, falso en caso contrario. + */ + checkIf(phoneNumber) { + return this.#blacklist.has(phoneNumber) + } + + /** + * Proporciona una copia de la lista negra actual. + * @returns {Array} - Los números de teléfono en la lista negra. + */ + getList() { + return [...this.#blacklist] + } +} +module.exports = BlackListClass diff --git a/packages/bot/utils/flattener.js b/packages/bot/utils/flattener.js index ddc823fb4..e886d4928 100644 --- a/packages/bot/utils/flattener.js +++ b/packages/bot/utils/flattener.js @@ -1,22 +1,22 @@ const flatObject = (listArray = []) => { const cbNestedList = Array.isArray(listArray) ? listArray : [] - if (!listArray.length) return {} + if (!cbNestedList.length) return {} - const cbNestedObj = cbNestedList.map(({ ctx }) => ctx?.callbacks).filter((i) => !!i) - const queueCb = cbNestedObj.reduce((acc, current) => { - const getKeys = Object.keys(current) - const parse = getKeys.map((icb, i) => ({ - [icb]: Object.values(current)[i], - })) - return [...acc, ...parse] - }, []) + const cbNestedObj = cbNestedList.map(({ ctx }) => ctx?.callbacks).filter(Boolean) + + const flatObj = cbNestedObj.reduce((acc, current) => { + const keys = Object.keys(current) + const values = Object.values(current) + + keys.forEach((key, i) => { + // acc[key] = values[i](a,b,c) + acc[key] = values[i] + }) + + return acc + }, {}) - const flatObj = {} - for (const iteration of queueCb) { - const [keyCb] = Object.keys(iteration) - flatObj[keyCb] = iteration[keyCb] - } return flatObj } diff --git a/packages/bot/utils/queue.js b/packages/bot/utils/queue.js index 4532657fc..ae8b88153 100644 --- a/packages/bot/utils/queue.js +++ b/packages/bot/utils/queue.js @@ -1,5 +1,5 @@ class Queue { - constructor(logger, concurrencyLimit = 15, timeout = 20000) { + constructor(logger, concurrencyLimit = 15, timeout = 50000) { this.queue = new Map() this.queueTime = new Map() this.timers = new Map() @@ -46,6 +46,7 @@ class Queue { const refIdTimeOut = timer({ reject, resolve }) clearTimeout(this.timers.get(fingerIdRef)) this.timers.set(fingerIdRef, refIdTimeOut) + this.clearQueue(from) return refIdTimeOut } @@ -60,6 +61,12 @@ class Queue { } return new Promise((resolve, reject) => { + const pid = queueByFrom.findIndex((i) => i.fingerIdRef === fingerIdRef) + if (pid !== -1) { + console.log(`🔥🔥🔥🔥`) + this.clearQueue(from) + } + queueByFrom.push({ promiseFunc, fingerIdRef, @@ -69,9 +76,9 @@ class Queue { }) if (!workingByFrom) { - this.logger.log(`${from}:EJECUTANDO`) - this.workingOnPromise.set(from, true) + this.logger.log(`EJECUTANDO:${fingerIdRef}`) this.processQueue(from) + this.workingOnPromise.set(from, true) } }) } @@ -91,15 +98,20 @@ class Queue { const refToPromise = item.promiseFunc(item) const value = await Promise.race([ refToPromise.timerPromise, - refToPromise.promiseInFunc().then(() => refToPromise.cancel()), + refToPromise.promiseInFunc().then(() => { + return refToPromise.cancel() + }), ]) - item.resolve(value) + + this.clearIdFromCallback(from, item.fingerIdRef) this.logger.log(`${from}:SUCCESS`) + return item.resolve(value) } catch (err) { + this.clearIdFromCallback(from, item.fingerIdRef) + this.logger.error(`${from}:ERROR: ${JSON.stringify(err)}`) - item.reject(err) + return item.reject(err) } - this.clearIdFromCallback(from, item.fingerIdRef) }) await Promise.allSettled(promises) @@ -118,15 +130,14 @@ class Queue { const queueByFrom = this.queue.get(from) const workingByFrom = this.workingOnPromise.get(from) - // Marca todas las promesas como canceladas - queueByFrom.forEach((item) => { - item.cancelled = true - item.reject('Queue cleared') - }) - - // Limpia la cola - - this.queue.set(from, []) + try { + for (const item of queueByFrom) { + item.cancelled = true + item.resolve('Queue cleared') + } + } finally { + this.queue.set(from, []) + } // Si hay un proceso en ejecución, también deberías cancelarlo if (workingByFrom) { @@ -149,7 +160,7 @@ class Queue { this.idsCallbacks.set(from, ids) } - getIdsCallbacs = (from) => { + getIdsCallback = (from) => { if (this.idsCallbacks.has(from)) { return this.idsCallbacks.get(from) } else { diff --git a/packages/cli/bin/cli.js b/packages/cli/bin/cli.js old mode 100644 new mode 100755 diff --git a/packages/docs/netlify.toml b/packages/docs/netlify.toml index 4a0047a87..9eaf411ef 100644 --- a/packages/docs/netlify.toml +++ b/packages/docs/netlify.toml @@ -1,6 +1,5 @@ [build] -publish = "dist" -command = "npm run build" +publish = "packages/docs/dist" [[edge_functions]] path = "/*" diff --git a/packages/docs/package.json b/packages/docs/package.json index 7c38118e0..350465daf 100644 --- a/packages/docs/package.json +++ b/packages/docs/package.json @@ -3,7 +3,7 @@ "description": "A template to make your website using Qwik + Tailwind CSS.", "version": "0.1.1", "scripts": { - "build": "qwik build && npm run subfont", + "build": "qwik build", "build.client": "vite build", "build.preview": "vite build --ssr src/entry.preview.tsx", "build.server": "vite build -c adaptors/netlify-edge/vite.config.ts", @@ -16,7 +16,7 @@ "lint": "eslint \"src/**/*.ts*\"", "preview": "qwik build preview && vite preview --open", "start": "vite --open --mode ssr", - "subfont": "subfont -i --inline-css --no-fallbacks --silent --root dist", + "subfont": "subfont -i --inline-css --no-fallbacks --silent --root ./dist", "qwik": "qwik" }, "devDependencies": { diff --git a/packages/docs/src/root.tsx b/packages/docs/src/root.tsx index 0becc0ca8..148235f2d 100644 --- a/packages/docs/src/root.tsx +++ b/packages/docs/src/root.tsx @@ -47,6 +47,8 @@ export default component$(() => { { name: 'fallBack', link: '/docs/fall-back' }, { name: 'endFlow', link: '/docs/end-flow' }, { name: 'gotoFlow', link: '/docs/goto-flow' }, + { name: 'idle', link: '/docs/idle' }, + { name: 'blacklist', link: '/docs/blacklist' }, ], }, { diff --git a/packages/docs/src/routes/docs/blacklist/index.mdx b/packages/docs/src/routes/docs/blacklist/index.mdx new file mode 100644 index 000000000..ee7dcecc6 --- /dev/null +++ b/packages/docs/src/routes/docs/blacklist/index.mdx @@ -0,0 +1,32 @@ +import Navigation from '../../../components/widgets/Navigation' + +# blackList + +Se utiliza para bloquear usuarios que no esten en la lista de usuarios permitidos. + +Para implementar esta caracteristica deberás hacerlo al momento de crear la instancia del bot. + +## Ejemplo + +```js +createBot({ + flow: adapterFlow, + provider: adapterProvider, + database: adapterDB, +},{ + blackList:['34XXXXXXXX'] +}) +``` + +## Propiedades + +- **blackList** (array): Lista de usuarios que no podran interactuar con el bot. + +--- + + diff --git a/packages/docs/src/routes/docs/ctx/index.mdx b/packages/docs/src/routes/docs/ctx/index.mdx index 580512d3b..9d1117ce4 100644 --- a/packages/docs/src/routes/docs/ctx/index.mdx +++ b/packages/docs/src/routes/docs/ctx/index.mdx @@ -2,7 +2,7 @@ import Navigation from '../../../components/widgets/Navigation' # ctx -Esta funcion se encuentra dentro de `addAnswer` o `addAction` +Esta función se encuentra dentro de `addAnswer` o `addAction` Se encarga de responder al usuario, puedes responder un texto o archivo adjunto. @@ -32,7 +32,7 @@ Dentro del ctx puedes conseguir algunas de las siguientes propiedades ``` -Tambien recomiendao que con `console.log(ctx)` puedes ver todas las propiedades que vienen incluidas, muchas de ellas pueden ser propiedades propias del `provider` +También recomiendo que con `console.log(ctx)` puedes ver todas las propiedades que vienen incluidas, muchas de ellas pueden ser propiedades propias del `provider` --- diff --git a/packages/docs/src/routes/docs/essential/index.mdx b/packages/docs/src/routes/docs/essential/index.mdx index b09cd5ca2..2a7568e65 100644 --- a/packages/docs/src/routes/docs/essential/index.mdx +++ b/packages/docs/src/routes/docs/essential/index.mdx @@ -15,11 +15,11 @@ El desarrollo de la librería se base en tres (3) piezas claves para su correcto ## Flow -Los flujos hace referencia al hecho de construir un flujo de conversion. Esto es un flow podemos observar que estan presente dos metodos importantes **[addKeyword](/docs/add-keyword)** y el **[addAnswer](/docs/add-answers)**. +Los flujos hacen referencia al hecho de construir un flujo de conversacion. Esto es un flow podemos observar que estan presentes dos metodos importantes **[addKeyword](/docs/add-keyword)** y **[addAnswer](/docs/add-answers)**. Tan sencillo como decir **palabra/s clave** y **mensaje a responder** -Ambos metodos **[addKeyword](/docs/add-keyword)** y el **[addAnswer](/docs/add-answers)** tienen una serie opciones disponibles +Ambos metodos **[addKeyword](/docs/add-keyword)** y **[addAnswer](/docs/add-answers)** tienen una serie opciones disponibles. ```js const { createBot, createProvider, createFlow, addKeyword } = require('@bot-whatsapp/bot') diff --git a/packages/docs/src/routes/docs/flow-dynamic/index.mdx b/packages/docs/src/routes/docs/flow-dynamic/index.mdx index 08f390828..e766192c4 100644 --- a/packages/docs/src/routes/docs/flow-dynamic/index.mdx +++ b/packages/docs/src/routes/docs/flow-dynamic/index.mdx @@ -50,7 +50,8 @@ const flowString = addKeyword('ver categorias') await flowDynamic([ { body:"soy una imagen", - media:'https://i.imgur.com/0HpzsEm.png' + media:'https://i.imgur.com/0HpzsEm.png', + delay:1000 } ]) diff --git a/packages/docs/src/routes/docs/goto-flow/index.mdx b/packages/docs/src/routes/docs/goto-flow/index.mdx index ddfff630e..a9ddd8a82 100644 --- a/packages/docs/src/routes/docs/goto-flow/index.mdx +++ b/packages/docs/src/routes/docs/goto-flow/index.mdx @@ -1,4 +1,5 @@ import Navigation from '../../../components/widgets/Navigation' +import Alert from '../../../components/widgets/Alert' # gotoFlow @@ -52,6 +53,39 @@ const flowBienvenida = addKeyword('hola') ``` + + Evitar dependencias circular: Si te encuentras en este situación algunas de las recomendaciones son: + - Divide la logica en flows más simples + - Implementa `require` o importacion dinamicas. (ejemplos abajo) + + + + +```js +const { addKeyword } = require('@bot-whatsapp/bot') + + +const flujoUsuariosNORegistrados = addKeyword('USUARIOS_NO_REGISTRADOS') +.addAnswer('Veo que es tu primera vez por aqui') +.addAnswer('¿Cual es tu email?',{capture:true},async(ctx, {flowDynamic, gotoFlow}) => { + + const numero = ctx.from + console.log('registramos en base de datos el numero...') + + + /** La importacion del require se hace dentro de la funcion**/ + + await flowDynamic(`Ya te registramos..`) + await gotoFlow(require('./flows/flujoUsuariosRegistrados')) + -- o -- + const flowRegistrados = require('./flows/flujoUsuariosRegistrados') + await gotoFlow(flowRegistrados) +}) + + +``` + + --- { + if (ctx?.idleFallBack) { + return gotoFlow(flujoFinal) + } + } + ) + .addAnswer('gracias!') + +``` + +## API + +### Propiedades + +- **idle** - Tiempo de inactividad en milisegundos +- **idleFallBack** - Si se ejecutó la acción por inactividad + + +--- + + diff --git a/packages/docs/src/services/github.ts b/packages/docs/src/services/github.ts index 1a06380fb..f4f2893df 100644 --- a/packages/docs/src/services/github.ts +++ b/packages/docs/src/services/github.ts @@ -11,18 +11,13 @@ export const fetchGithub = async (token: string) => { Authorization: `Bearer ${token}`, }, }) - const listUsers = await data.json() + try { + const listUsers = await data.json() return listUsers.map((u: any) => ({ ...u, avatar_url: `${u.avatar_url}&s=80`, })) - // try { - // const listUsers = await data.json() - // return listUsers.map((u: any) => ({ - // ...u, - // avatar_url: `${u.avatar_url}&s=80`, - // })) - // } catch (error) { - // return [] - // } + } catch (error) { + return [] + } } \ No newline at end of file diff --git a/packages/eslint-plugin-bot-whatsapp/configs/recommended.js b/packages/eslint-plugin-bot-whatsapp/configs/recommended.js new file mode 100644 index 000000000..f080f330c --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/configs/recommended.js @@ -0,0 +1,9 @@ +module.exports = { + rules: { + 'bot-whatsapp/func-prefix-goto-flow-return': 2, + 'bot-whatsapp/func-prefix-end-flow-return': 2, + 'bot-whatsapp/func-prefix-dynamic-flow-await': 2, + 'bot-whatsapp/func-prefix-state-update-await': 2, + 'bot-whatsapp/func-prefix-fall-back-return': 2, + }, +} diff --git a/packages/eslint-plugin-bot-whatsapp/index.js b/packages/eslint-plugin-bot-whatsapp/index.js new file mode 100644 index 000000000..b9ae74d1b --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/index.js @@ -0,0 +1,43 @@ +const { processGotoFlowReturn } = require('./rules/processGotoFlowReturn') +const { processDynamicFlowAwait } = require('./rules/processDynamicFlowAwait') +const { processStateUpdateAwait } = require('./rules/processStateUpdateAwait') +const { processFallBackReturn } = require('./rules/processFallBackReturn') +const { processEndFlowReturn } = require('./rules/processEndFlowReturn') + +module.exports = { + configs: { + recommended: require('./configs/recommended'), + }, + rules: { + 'func-prefix-goto-flow-return': { + meta: { + fixable: 'code', + }, + create: processGotoFlowReturn, + }, + 'func-prefix-fall-back-return': { + meta: { + fixable: 'code', + }, + create: processFallBackReturn, + }, + 'func-prefix-end-flow-return': { + meta: { + fixable: 'code', + }, + create: processEndFlowReturn, + }, + 'func-prefix-dynamic-flow-await': { + meta: { + fixable: 'code', + }, + create: processDynamicFlowAwait, + }, + 'func-prefix-state-update-await': { + meta: { + fixable: 'code', + }, + create: processStateUpdateAwait, + }, + }, +} diff --git a/packages/eslint-plugin-bot-whatsapp/package.json b/packages/eslint-plugin-bot-whatsapp/package.json new file mode 100644 index 000000000..a689f3ce7 --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/package.json @@ -0,0 +1,11 @@ +{ + "name": "eslint-plugin-bot-whatsapp", + "version": "0.0.4-alpha.0", + "description": "", + "main": "./lib/eslint-plugin-bot-whatsapp.cjs", + "files": [ + "./lib/*" + ], + "author": "", + "license": "ISC" +} diff --git a/packages/eslint-plugin-bot-whatsapp/rollup-eslint.config.js b/packages/eslint-plugin-bot-whatsapp/rollup-eslint.config.js new file mode 100644 index 000000000..eef52e8c4 --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/rollup-eslint.config.js @@ -0,0 +1,16 @@ +const banner = require('../../config/banner.rollup.json') +const commonjs = require('@rollup/plugin-commonjs') +const { nodeResolve } = require('@rollup/plugin-node-resolve') +const { join } = require('path') + +const PATH = join(__dirname, 'lib', 'eslint-plugin-bot-whatsapp.cjs') + +module.exports = { + input: join(__dirname, 'index.js'), + output: { + banner: banner['banner.output'].join(''), + file: PATH, + format: 'cjs', + }, + plugins: [commonjs(), nodeResolve()], +} diff --git a/packages/eslint-plugin-bot-whatsapp/rules/processDynamicFlowAwait.js b/packages/eslint-plugin-bot-whatsapp/rules/processDynamicFlowAwait.js new file mode 100644 index 000000000..11fd56215 --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/rules/processDynamicFlowAwait.js @@ -0,0 +1,41 @@ +function isInsideAddActionOrAddAnswer(node) { + let currentNode = node + while (currentNode) { + if ( + currentNode.type === 'CallExpression' && + currentNode.callee && + currentNode.callee.property && + (currentNode.callee.property.name === 'addAnswer' || currentNode.callee.property.name === 'addAction') + ) { + return true + } + currentNode = currentNode.parent + } + return false +} + +const processDynamicFlowAwait = (context) => { + return { + 'CallExpression[callee.name="flowDynamic"]'(node) { + let parentNode = node.parent + + // Verificar si estamos dentro de un 'addAction' o 'addAnswer' + if (!isInsideAddActionOrAddAnswer(node)) { + return + } + + // Verificar si el nodo padre es 'AwaitExpression', de lo contrario se reporta + if (parentNode.type !== 'AwaitExpression') { + context.report({ + node, + message: 'Please use "await" before "flowDynamic" function', + fix: function (fixer) { + return fixer.insertTextBefore(node, 'await ') + }, + }) + } + }, + } +} + +module.exports = { processDynamicFlowAwait } diff --git a/packages/eslint-plugin-bot-whatsapp/rules/processEndFlowReturn.js b/packages/eslint-plugin-bot-whatsapp/rules/processEndFlowReturn.js new file mode 100644 index 000000000..79e076eb0 --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/rules/processEndFlowReturn.js @@ -0,0 +1,41 @@ +function isInsideAddActionOrAddAnswer(node) { + let currentNode = node + while (currentNode) { + if ( + currentNode.type === 'CallExpression' && + currentNode.callee && + currentNode.callee.property && + (currentNode.callee.property.name === 'addAnswer' || currentNode.callee.property.name === 'addAction') + ) { + return true + } + currentNode = currentNode.parent + } + return false +} + +const processEndFlowReturn = (context) => { + return { + 'CallExpression[callee.name="endFlow"]'(node) { + let parentNode = node.parent + + // Verificar si estamos dentro de un 'addAction' o 'addAnswer' + if (!isInsideAddActionOrAddAnswer(node)) { + return + } + + // Verificar si nodo padre es de tipo ReturnStatement, si no lo es, reportar + if (parentNode.type !== 'ReturnStatement') { + context.report({ + node, + message: 'Please ensure "endFlow" function is returned', + fix: function (fixer) { + return fixer.insertTextBefore(node, 'return ') + }, + }) + } + }, + } +} + +module.exports = { processEndFlowReturn } diff --git a/packages/eslint-plugin-bot-whatsapp/rules/processFallBackReturn.js b/packages/eslint-plugin-bot-whatsapp/rules/processFallBackReturn.js new file mode 100644 index 000000000..63c4a2db0 --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/rules/processFallBackReturn.js @@ -0,0 +1,41 @@ +function isInsideAddActionOrAddAnswer(node) { + let currentNode = node + while (currentNode) { + if ( + currentNode.type === 'CallExpression' && + currentNode.callee && + currentNode.callee.property && + (currentNode.callee.property.name === 'addAnswer' || currentNode.callee.property.name === 'addAction') + ) { + return true + } + currentNode = currentNode.parent + } + return false +} + +const processFallBackReturn = (context) => { + return { + 'CallExpression[callee.name="fallBack"]'(node) { + let parentNode = node.parent + + // Verificar si estamos dentro de un 'addAction' o 'addAnswer' + if (!isInsideAddActionOrAddAnswer(node)) { + return + } + + // Verificar si nodo padre es de tipo ReturnStatement, si no lo es, reportar + if (parentNode.type !== 'ReturnStatement') { + context.report({ + node, + message: 'Please ensure "fallBack" function is returned', + fix: function (fixer) { + return fixer.insertTextBefore(node, 'return ') + }, + }) + } + }, + } +} + +module.exports = { processFallBackReturn } diff --git a/packages/eslint-plugin-bot-whatsapp/rules/processGotoFlowReturn.js b/packages/eslint-plugin-bot-whatsapp/rules/processGotoFlowReturn.js new file mode 100644 index 000000000..7819cdf90 --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/rules/processGotoFlowReturn.js @@ -0,0 +1,41 @@ +function isInsideAddActionOrAddAnswer(node) { + let currentNode = node + while (currentNode) { + if ( + currentNode.type === 'CallExpression' && + currentNode.callee && + currentNode.callee.property && + (currentNode.callee.property.name === 'addAnswer' || currentNode.callee.property.name === 'addAction') + ) { + return true + } + currentNode = currentNode.parent + } + return false +} + +const processGotoFlowReturn = (context) => { + return { + 'CallExpression[callee.name="gotoFlow"]'(node) { + let parentNode = node.parent + + // Verificar si estamos dentro de un 'addAction' o 'addAnswer' + if (!isInsideAddActionOrAddAnswer(node)) { + return + } + + // Verificar si nodo padre es de tipo ReturnStatement, si no lo es, reportar + if (parentNode.type !== 'ReturnStatement') { + context.report({ + node, + message: 'Please ensure "gotoFlow" function is returned', + fix: function (fixer) { + return fixer.insertTextBefore(node, 'return ') + }, + }) + } + }, + } +} + +module.exports = { processGotoFlowReturn } diff --git a/packages/eslint-plugin-bot-whatsapp/rules/processStateUpdateAwait.js b/packages/eslint-plugin-bot-whatsapp/rules/processStateUpdateAwait.js new file mode 100644 index 000000000..37eaa5467 --- /dev/null +++ b/packages/eslint-plugin-bot-whatsapp/rules/processStateUpdateAwait.js @@ -0,0 +1,63 @@ +function isInsideAddActionOrAddAnswer(node) { + let currentNode = node + while (currentNode) { + if ( + currentNode.type === 'CallExpression' && + currentNode.callee && + currentNode.callee.property && + (currentNode.callee.property.name === 'addAnswer' || currentNode.callee.property.name === 'addAction') + ) { + return true + } + currentNode = currentNode.parent + } + return false +} + +const processStateUpdateAwait = (context) => { + return { + 'MemberExpression[property.name="update"]'(node) { + // Verificar si el objeto es 'state' + if (node.object.name !== 'state') { + return + } + + if (node.object.name === 'state') { + const sourceCode = context.getSourceCode() + const rangeStart = node.range[0] - 6 // Longitud de "await " + const rangeEnd = node.range[0] + const parentNodeText = sourceCode.getText().substring(rangeStart, rangeEnd) + if (parentNodeText.includes('await')) { + return + } + } + + let parentNode = node.parent + // Verificar si estamos dentro de un 'addAction' o 'addAnswer' + if (!isInsideAddActionOrAddAnswer(node)) { + return + } + + // Verificar si el nodo padre es 'AwaitExpression', de lo contrario se reporta + if (parentNode.type !== 'AwaitExpression') { + context.report({ + node, + message: 'Please use "await" before "state.update"', + fix: function (fixer) { + // Comprueba si existe un await antes de state.update + const sourceCode = context.getSourceCode() + const rangeStart = node.range[0] - 7 // Longitud de "await " + const rangeEnd = node.range[0] + const parentNodeText = sourceCode.getText().substring(rangeStart, rangeEnd) + + if (parentNodeText.trim() !== 'await') { + return fixer.insertTextBefore(node, 'await ') + } + }, + }) + } + }, + } +} + +module.exports = { processStateUpdateAwait } diff --git a/packages/provider/src/meta/index.js b/packages/provider/src/meta/index.js index 47e3dcae8..393de9666 100644 --- a/packages/provider/src/meta/index.js +++ b/packages/provider/src/meta/index.js @@ -359,6 +359,7 @@ class MetaProvider extends ProviderClass { * @param {*} number * @param {*} template * @param {*} languageCode + * Usarse de acuerdo a cada plantilla en particular, esto solo es un mapeo de como funciona. * @returns */ @@ -373,8 +374,49 @@ class MetaProvider extends ProviderClass { language: { code: languageCode, // examples: es_Mex, en_Us }, + components: [ + { + type: 'header', + parameters: [ + { + type: 'image', + image: { + link: 'https://i.imgur.com/3xUQq0U.png', + }, + }, + ], + }, + { + type: 'body', + parameters: [ + { + type: 'text', // currency, date_time, etc + text: 'text-string', + }, + { + type: "currency", + currency: { + fallback_value: "$100.99", + code: "USD", + amount_1000: 100990 + } + }, + ] + }, + { + type: 'button', + subtype: 'quick_reply', + index: 0, + parameters: [ + { + type: 'payload', + payload: 'aGlzIHRoaXMgaXMgY29v' + }, + ], + }, + ] }, - } + }; return this.sendMessageMeta(body) } @@ -409,6 +451,37 @@ class MetaProvider extends ProviderClass { return this.sendMessageMeta(body) } + /** + * Enviar catálogo + * @param {*} number + * @param {*} bodyText + * @param {*} itemCatalogId + * @param {*} footerText + * @returns + */ + + sendCatalog = async (number, bodyText, itemCatalogId) => { + const body = { + messaging_product: 'whatsapp', + recipient_type: 'individual', + to: number, + type: 'interactive', + interactive: { + type: 'catalog_message', + body: { + text: bodyText, + }, + action: { + name: 'catalog_message', + parameters: { + "thumbnail_product_retailer_id": itemCatalogId, + } + } + } + } + return this.sendMessageMeta(body) + } + /** * * @param {*} userId diff --git a/packages/provider/src/meta/server.js b/packages/provider/src/meta/server.js index c940f97d4..ed12e7855 100644 --- a/packages/provider/src/meta/server.js +++ b/packages/provider/src/meta/server.js @@ -52,18 +52,36 @@ class MetaWebHookServer extends EventEmitter { if (message.type === 'interactive') { const body = message.interactive?.button_reply?.title || message.interactive?.list_reply?.id + const title_button_reply = message.interactive?.button_reply?.title const title_list_reply = message.interactive?.list_reply?.title const responseObj = { type: 'interactive', from: message.from, to, body, + title_button_reply, title_list_reply, pushName, } this.emit('message', responseObj) } + if (message.type === 'button') { + const body = message.button?.text + const payload = message.button?.payload + const title_button_reply = message.button?.payload + const responseObj = { + type: 'button', + from: message.from, + to, + body, + payload, + title_button_reply, + pushName, + } + this.emit('message', responseObj) + } + if (message.type === 'image') { const body = generateRefprovider('_event_media_') const idUrl = message.image?.id diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 3f72bc570..d7f4bf1df 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -8,32 +8,32 @@ importers: .: devDependencies: '@commitlint/cli': - specifier: ^17.4.4 - version: 17.4.4 + specifier: ^17.8.1 + version: 17.8.1 '@commitlint/config-conventional': - specifier: ^17.4.4 - version: 17.4.4 + specifier: ^17.8.1 + version: 17.8.1 '@octokit/core': - specifier: ^4.2.0 - version: 4.2.0 + specifier: ^4.2.4 + version: 4.2.4 '@rollup/plugin-commonjs': specifier: ^23.0.7 - version: 23.0.7(rollup@3.17.2) + version: 23.0.7(rollup@3.29.4) '@rollup/plugin-json': specifier: ^5.0.2 - version: 5.0.2(rollup@3.17.2) + version: 5.0.2(rollup@3.29.4) '@rollup/plugin-node-resolve': - specifier: ^15.0.1 - version: 15.0.1(rollup@3.17.2) + specifier: ^15.2.3 + version: 15.2.3(rollup@3.29.4) '@rollup/plugin-replace': - specifier: ^5.0.2 - version: 5.0.2(rollup@3.17.2) + specifier: ^5.0.4 + version: 5.0.4(rollup@3.29.4) '@rollup/plugin-strip': - specifier: ^3.0.2 - version: 3.0.2(rollup@3.17.2) + specifier: ^3.0.4 + version: 3.0.4(rollup@3.29.4) c8: - specifier: ^7.13.0 - version: 7.13.0 + specifier: ^7.14.0 + version: 7.14.0 conventional-changelog: specifier: ^3.1.25 version: 3.1.25 @@ -41,14 +41,14 @@ importers: specifier: ^7.0.3 version: 7.0.3 eslint: - specifier: ^8.34.0 - version: 8.34.0 + specifier: ^8.52.0 + version: 8.52.0 eslint-config-prettier: - specifier: ^8.6.0 - version: 8.6.0(eslint@8.34.0) + specifier: ^8.10.0 + version: 8.10.0(eslint@8.52.0) fs-extra: - specifier: ^11.1.0 - version: 11.1.0 + specifier: ^11.1.1 + version: 11.1.1 git-cz: specifier: ^4.9.0 version: 4.9.0 @@ -59,32 +59,32 @@ importers: specifier: ^2.1.35 version: 2.1.35 only-allow: - specifier: ^1.1.1 - version: 1.1.1 + specifier: ^1.2.1 + version: 1.2.1 prettier: - specifier: ^2.8.4 - version: 2.8.4 + specifier: ^2.8.8 + version: 2.8.8 pretty-quick: specifier: ^3.1.3 - version: 3.1.3(prettier@2.8.4) + version: 3.1.3(prettier@2.8.8) prompts: specifier: ^2.4.2 version: 2.4.2 rimraf: - specifier: ^4.1.2 - version: 4.1.2 + specifier: ^4.4.1 + version: 4.4.1 rollup: - specifier: ^3.17.2 - version: 3.17.2 + specifier: ^3.29.4 + version: 3.29.4 rollup-plugin-cleanup: specifier: ^3.2.1 - version: 3.2.1(rollup@3.17.2) + version: 3.2.1(rollup@3.29.4) rollup-plugin-copy: - specifier: ^3.4.0 - version: 3.4.0 + specifier: ^3.5.0 + version: 3.5.0 semver: - specifier: ^7.3.8 - version: 7.3.8 + specifier: ^7.5.4 + version: 7.5.4 standard-version: specifier: ^9.5.0 version: 9.5.0 @@ -100,7 +100,7 @@ importers: devDependencies: '@bot-whatsapp/cli': specifier: '*' - version: link:../cli + version: 0.1.33 kleur: specifier: ^4.1.5 version: 4.1.5 @@ -134,13 +134,13 @@ importers: dependencies: '@bot-whatsapp/bot': specifier: '*' - version: link:../bot + version: 0.1.33 packages/create-bot-whatsapp: dependencies: '@bot-whatsapp/cli': specifier: '*' - version: link:../cli + version: 0.1.33 packages/database: dependencies: @@ -170,7 +170,7 @@ importers: version: 0.2.1(@builder.io/qwik@0.16.1)(@types/react-dom@18.0.5)(@types/react@18.0.14)(react-dom@18.2.0)(react@18.2.0) '@docsearch/react': specifier: ^3.3.3 - version: 3.3.3(@algolia/client-search@4.19.1)(@types/react@18.0.14)(react-dom@18.2.0)(react@18.2.0) + version: 3.3.3(@algolia/client-search@4.20.0)(@types/react@18.0.14)(react-dom@18.2.0)(react@18.2.0) '@emotion/react': specifier: 11.10.4 version: 11.10.4(@types/react@18.0.14)(react@18.2.0) @@ -266,11 +266,13 @@ importers: version: 3.2.4(@types/node@20.5.7) vite-imagetools: specifier: ^4.0.11 - version: 4.0.11(rollup@3.17.2) + version: 4.0.11(rollup@3.29.4) vite-tsconfig-paths: specifier: 3.6.0 version: 3.6.0(vite@3.2.4) + packages/eslint-plugin-bot-whatsapp: {} + packages/portal: dependencies: kleur: @@ -333,7 +335,7 @@ importers: dependencies: '@bot-whatsapp/bot': specifier: '*' - version: link:../bot + version: 0.1.33 '@ffmpeg-installer/ffmpeg': specifier: ^1.1.0 version: 1.1.0 @@ -377,7 +379,7 @@ packages: '@algolia/autocomplete-shared': 1.7.4 dev: true - /@algolia/autocomplete-preset-algolia@1.7.4(@algolia/client-search@4.19.1)(algoliasearch@4.19.1): + /@algolia/autocomplete-preset-algolia@1.7.4(@algolia/client-search@4.20.0)(algoliasearch@4.19.1): resolution: { integrity: sha512-s37hrvLEIfcmKY8VU9LsAXgm2yfmkdHT3DnA3SgHaY93yjZ2qL57wzb5QweVkYuEBZkT2PIREvRoLXC2sxTbpQ==, @@ -387,7 +389,7 @@ packages: algoliasearch: '>= 4.9.1 < 6' dependencies: '@algolia/autocomplete-shared': 1.7.4 - '@algolia/client-search': 4.19.1 + '@algolia/client-search': 4.20.0 algoliasearch: 4.19.1 dev: true @@ -414,6 +416,13 @@ packages: } dev: true + /@algolia/cache-common@4.20.0: + resolution: + { + integrity: sha512-vCfxauaZutL3NImzB2G9LjLt36vKAckc6DhMp05An14kVo8F1Yofb6SIl6U3SaEz8pG2QOB9ptwM5c+zGevwIQ==, + } + dev: true + /@algolia/cache-in-memory@4.19.1: resolution: { @@ -456,6 +465,16 @@ packages: '@algolia/transporter': 4.19.1 dev: true + /@algolia/client-common@4.20.0: + resolution: + { + integrity: sha512-P3WgMdEss915p+knMMSd/fwiHRHKvDu4DYRrCRaBrsfFw7EQHon+EbRSm4QisS9NYdxbS04kcvNoavVGthyfqQ==, + } + dependencies: + '@algolia/requester-common': 4.20.0 + '@algolia/transporter': 4.20.0 + dev: true + /@algolia/client-personalization@4.19.1: resolution: { @@ -478,6 +497,17 @@ packages: '@algolia/transporter': 4.19.1 dev: true + /@algolia/client-search@4.20.0: + resolution: + { + integrity: sha512-zgwqnMvhWLdpzKTpd3sGmMlr4c+iS7eyyLGiaO51zDZWGMkpgoNVmltkzdBwxOVXz0RsFMznIxB9zuarUv4TZg==, + } + dependencies: + '@algolia/client-common': 4.20.0 + '@algolia/requester-common': 4.20.0 + '@algolia/transporter': 4.20.0 + dev: true + /@algolia/logger-common@4.19.1: resolution: { @@ -485,6 +515,13 @@ packages: } dev: true + /@algolia/logger-common@4.20.0: + resolution: + { + integrity: sha512-xouigCMB5WJYEwvoWW5XDv7Z9f0A8VoXJc3VKwlHJw/je+3p2RcDXfksLI4G4lIVncFUYMZx30tP/rsdlvvzHQ==, + } + dev: true + /@algolia/logger-console@4.19.1: resolution: { @@ -510,6 +547,13 @@ packages: } dev: true + /@algolia/requester-common@4.20.0: + resolution: + { + integrity: sha512-9h6ye6RY/BkfmeJp7Z8gyyeMrmmWsMOCRBXQDs4mZKKsyVlfIVICpcSibbeYcuUdurLhIlrOUkH3rQEgZzonng==, + } + dev: true + /@algolia/requester-node-http@4.19.1: resolution: { @@ -530,6 +574,17 @@ packages: '@algolia/requester-common': 4.19.1 dev: true + /@algolia/transporter@4.20.0: + resolution: + { + integrity: sha512-Lsii1pGWOAISbzeyuf+r/GPhvHMPHSPrTDWNcIzOE1SG1inlJHICaVe2ikuoRjcpgxZNU54Jl+if15SUCsaTUg==, + } + dependencies: + '@algolia/cache-common': 4.20.0 + '@algolia/logger-common': 4.20.0 + '@algolia/requester-common': 4.20.0 + dev: true + /@arr/every@1.0.1: resolution: { @@ -546,7 +601,7 @@ packages: requiresBuild: true dependencies: '@aws-crypto/util': 3.0.0 - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 tslib: 1.14.1 dev: false optional: true @@ -573,7 +628,7 @@ packages: '@aws-crypto/sha256-js': 3.0.0 '@aws-crypto/supports-web-crypto': 3.0.0 '@aws-crypto/util': 3.0.0 - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 '@aws-sdk/util-locate-window': 3.310.0 '@aws-sdk/util-utf8-browser': 3.259.0 tslib: 1.14.1 @@ -588,7 +643,7 @@ packages: requiresBuild: true dependencies: '@aws-crypto/util': 3.0.0 - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 tslib: 1.14.1 dev: false optional: true @@ -611,54 +666,56 @@ packages: } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 '@aws-sdk/util-utf8-browser': 3.259.0 tslib: 1.14.1 dev: false optional: true - /@aws-sdk/client-cognito-identity@3.398.0: + /@aws-sdk/client-cognito-identity@3.437.0: resolution: { - integrity: sha512-Pr/S1f8R2FsJ8DwBC6g0CSdtZNNV5dMHhlIi+t8YAmCJvP4KT+UhzFjbvQRINlBRLFuGUuP7p5vRcGVELD3+wA==, + integrity: sha512-7mI0WT21ru2H6T13J5xNHMIE/dXj1tEeObvwAvUcwQl1J1ZKzFFM/fth3AHX+KACJJ/B5WD+xiTuv62/SXE7AA==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: '@aws-crypto/sha256-browser': 3.0.0 '@aws-crypto/sha256-js': 3.0.0 - '@aws-sdk/client-sts': 3.398.0 - '@aws-sdk/credential-provider-node': 3.398.0 - '@aws-sdk/middleware-host-header': 3.398.0 - '@aws-sdk/middleware-logger': 3.398.0 - '@aws-sdk/middleware-recursion-detection': 3.398.0 - '@aws-sdk/middleware-signing': 3.398.0 - '@aws-sdk/middleware-user-agent': 3.398.0 - '@aws-sdk/types': 3.398.0 - '@aws-sdk/util-endpoints': 3.398.0 - '@aws-sdk/util-user-agent-browser': 3.398.0 - '@aws-sdk/util-user-agent-node': 3.398.0 - '@smithy/config-resolver': 2.0.5 - '@smithy/fetch-http-handler': 2.0.5 - '@smithy/hash-node': 2.0.5 - '@smithy/invalid-dependency': 2.0.5 - '@smithy/middleware-content-length': 2.0.5 - '@smithy/middleware-endpoint': 2.0.5 - '@smithy/middleware-retry': 2.0.5 - '@smithy/middleware-serde': 2.0.5 - '@smithy/middleware-stack': 2.0.0 - '@smithy/node-config-provider': 2.0.5 - '@smithy/node-http-handler': 2.0.5 - '@smithy/protocol-http': 2.0.5 - '@smithy/smithy-client': 2.0.5 - '@smithy/types': 2.2.2 - '@smithy/url-parser': 2.0.5 + '@aws-sdk/client-sts': 3.437.0 + '@aws-sdk/core': 3.436.0 + '@aws-sdk/credential-provider-node': 3.437.0 + '@aws-sdk/middleware-host-header': 3.433.0 + '@aws-sdk/middleware-logger': 3.433.0 + '@aws-sdk/middleware-recursion-detection': 3.433.0 + '@aws-sdk/middleware-signing': 3.433.0 + '@aws-sdk/middleware-user-agent': 3.433.0 + '@aws-sdk/region-config-resolver': 3.433.0 + '@aws-sdk/types': 3.433.0 + '@aws-sdk/util-endpoints': 3.433.0 + '@aws-sdk/util-user-agent-browser': 3.433.0 + '@aws-sdk/util-user-agent-node': 3.437.0 + '@smithy/config-resolver': 2.0.16 + '@smithy/fetch-http-handler': 2.2.4 + '@smithy/hash-node': 2.0.12 + '@smithy/invalid-dependency': 2.0.12 + '@smithy/middleware-content-length': 2.0.14 + '@smithy/middleware-endpoint': 2.1.3 + '@smithy/middleware-retry': 2.0.18 + '@smithy/middleware-serde': 2.0.12 + '@smithy/middleware-stack': 2.0.6 + '@smithy/node-config-provider': 2.1.3 + '@smithy/node-http-handler': 2.1.8 + '@smithy/protocol-http': 3.0.8 + '@smithy/smithy-client': 2.1.12 + '@smithy/types': 2.4.0 + '@smithy/url-parser': 2.0.12 '@smithy/util-base64': 2.0.0 '@smithy/util-body-length-browser': 2.0.0 '@smithy/util-body-length-node': 2.1.0 - '@smithy/util-defaults-mode-browser': 2.0.5 - '@smithy/util-defaults-mode-node': 2.0.5 - '@smithy/util-retry': 2.0.0 + '@smithy/util-defaults-mode-browser': 2.0.16 + '@smithy/util-defaults-mode-node': 2.0.21 + '@smithy/util-retry': 2.0.5 '@smithy/util-utf8': 2.0.0 tslib: 2.6.2 transitivePeerDependencies: @@ -666,45 +723,47 @@ packages: dev: false optional: true - /@aws-sdk/client-sso@3.398.0: + /@aws-sdk/client-sso@3.437.0: resolution: { - integrity: sha512-CygL0jhfibw4kmWXG/3sfZMFNjcXo66XUuPC4BqZBk8Rj5vFoxp1vZeMkDLzTIk97Nvo5J5Bh+QnXKhub6AckQ==, + integrity: sha512-AxlLWz9ec3b8Bt+RqRb2Q1ucGQtKrLdKDna+UTjz7AouB/jpoMiegV9NHXVX64N6YFnQnvB0UEGigXiOQE+y/g==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: '@aws-crypto/sha256-browser': 3.0.0 '@aws-crypto/sha256-js': 3.0.0 - '@aws-sdk/middleware-host-header': 3.398.0 - '@aws-sdk/middleware-logger': 3.398.0 - '@aws-sdk/middleware-recursion-detection': 3.398.0 - '@aws-sdk/middleware-user-agent': 3.398.0 - '@aws-sdk/types': 3.398.0 - '@aws-sdk/util-endpoints': 3.398.0 - '@aws-sdk/util-user-agent-browser': 3.398.0 - '@aws-sdk/util-user-agent-node': 3.398.0 - '@smithy/config-resolver': 2.0.5 - '@smithy/fetch-http-handler': 2.0.5 - '@smithy/hash-node': 2.0.5 - '@smithy/invalid-dependency': 2.0.5 - '@smithy/middleware-content-length': 2.0.5 - '@smithy/middleware-endpoint': 2.0.5 - '@smithy/middleware-retry': 2.0.5 - '@smithy/middleware-serde': 2.0.5 - '@smithy/middleware-stack': 2.0.0 - '@smithy/node-config-provider': 2.0.5 - '@smithy/node-http-handler': 2.0.5 - '@smithy/protocol-http': 2.0.5 - '@smithy/smithy-client': 2.0.5 - '@smithy/types': 2.2.2 - '@smithy/url-parser': 2.0.5 + '@aws-sdk/core': 3.436.0 + '@aws-sdk/middleware-host-header': 3.433.0 + '@aws-sdk/middleware-logger': 3.433.0 + '@aws-sdk/middleware-recursion-detection': 3.433.0 + '@aws-sdk/middleware-user-agent': 3.433.0 + '@aws-sdk/region-config-resolver': 3.433.0 + '@aws-sdk/types': 3.433.0 + '@aws-sdk/util-endpoints': 3.433.0 + '@aws-sdk/util-user-agent-browser': 3.433.0 + '@aws-sdk/util-user-agent-node': 3.437.0 + '@smithy/config-resolver': 2.0.16 + '@smithy/fetch-http-handler': 2.2.4 + '@smithy/hash-node': 2.0.12 + '@smithy/invalid-dependency': 2.0.12 + '@smithy/middleware-content-length': 2.0.14 + '@smithy/middleware-endpoint': 2.1.3 + '@smithy/middleware-retry': 2.0.18 + '@smithy/middleware-serde': 2.0.12 + '@smithy/middleware-stack': 2.0.6 + '@smithy/node-config-provider': 2.1.3 + '@smithy/node-http-handler': 2.1.8 + '@smithy/protocol-http': 3.0.8 + '@smithy/smithy-client': 2.1.12 + '@smithy/types': 2.4.0 + '@smithy/url-parser': 2.0.12 '@smithy/util-base64': 2.0.0 '@smithy/util-body-length-browser': 2.0.0 '@smithy/util-body-length-node': 2.1.0 - '@smithy/util-defaults-mode-browser': 2.0.5 - '@smithy/util-defaults-mode-node': 2.0.5 - '@smithy/util-retry': 2.0.0 + '@smithy/util-defaults-mode-browser': 2.0.16 + '@smithy/util-defaults-mode-node': 2.0.21 + '@smithy/util-retry': 2.0.5 '@smithy/util-utf8': 2.0.0 tslib: 2.6.2 transitivePeerDependencies: @@ -712,48 +771,50 @@ packages: dev: false optional: true - /@aws-sdk/client-sts@3.398.0: + /@aws-sdk/client-sts@3.437.0: resolution: { - integrity: sha512-/3Pa9wLMvBZipKraq3AtbmTfXW6q9kyvhwOno64f1Fz7kFb8ijQFMGoATS70B2pGEZTlxkUqJFWDiisT6Q6dFg==, + integrity: sha512-ilLcrCVwH81UbKNpB9Vax1Fw/mNx2d/bWXkCNXPvrExO+K39VFGS/VijOuSrru2iBq844NlG3uQV8DL/nbiKdA==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: '@aws-crypto/sha256-browser': 3.0.0 '@aws-crypto/sha256-js': 3.0.0 - '@aws-sdk/credential-provider-node': 3.398.0 - '@aws-sdk/middleware-host-header': 3.398.0 - '@aws-sdk/middleware-logger': 3.398.0 - '@aws-sdk/middleware-recursion-detection': 3.398.0 - '@aws-sdk/middleware-sdk-sts': 3.398.0 - '@aws-sdk/middleware-signing': 3.398.0 - '@aws-sdk/middleware-user-agent': 3.398.0 - '@aws-sdk/types': 3.398.0 - '@aws-sdk/util-endpoints': 3.398.0 - '@aws-sdk/util-user-agent-browser': 3.398.0 - '@aws-sdk/util-user-agent-node': 3.398.0 - '@smithy/config-resolver': 2.0.5 - '@smithy/fetch-http-handler': 2.0.5 - '@smithy/hash-node': 2.0.5 - '@smithy/invalid-dependency': 2.0.5 - '@smithy/middleware-content-length': 2.0.5 - '@smithy/middleware-endpoint': 2.0.5 - '@smithy/middleware-retry': 2.0.5 - '@smithy/middleware-serde': 2.0.5 - '@smithy/middleware-stack': 2.0.0 - '@smithy/node-config-provider': 2.0.5 - '@smithy/node-http-handler': 2.0.5 - '@smithy/protocol-http': 2.0.5 - '@smithy/smithy-client': 2.0.5 - '@smithy/types': 2.2.2 - '@smithy/url-parser': 2.0.5 + '@aws-sdk/core': 3.436.0 + '@aws-sdk/credential-provider-node': 3.437.0 + '@aws-sdk/middleware-host-header': 3.433.0 + '@aws-sdk/middleware-logger': 3.433.0 + '@aws-sdk/middleware-recursion-detection': 3.433.0 + '@aws-sdk/middleware-sdk-sts': 3.433.0 + '@aws-sdk/middleware-signing': 3.433.0 + '@aws-sdk/middleware-user-agent': 3.433.0 + '@aws-sdk/region-config-resolver': 3.433.0 + '@aws-sdk/types': 3.433.0 + '@aws-sdk/util-endpoints': 3.433.0 + '@aws-sdk/util-user-agent-browser': 3.433.0 + '@aws-sdk/util-user-agent-node': 3.437.0 + '@smithy/config-resolver': 2.0.16 + '@smithy/fetch-http-handler': 2.2.4 + '@smithy/hash-node': 2.0.12 + '@smithy/invalid-dependency': 2.0.12 + '@smithy/middleware-content-length': 2.0.14 + '@smithy/middleware-endpoint': 2.1.3 + '@smithy/middleware-retry': 2.0.18 + '@smithy/middleware-serde': 2.0.12 + '@smithy/middleware-stack': 2.0.6 + '@smithy/node-config-provider': 2.1.3 + '@smithy/node-http-handler': 2.1.8 + '@smithy/protocol-http': 3.0.8 + '@smithy/smithy-client': 2.1.12 + '@smithy/types': 2.4.0 + '@smithy/url-parser': 2.0.12 '@smithy/util-base64': 2.0.0 '@smithy/util-body-length-browser': 2.0.0 '@smithy/util-body-length-node': 2.1.0 - '@smithy/util-defaults-mode-browser': 2.0.5 - '@smithy/util-defaults-mode-node': 2.0.5 - '@smithy/util-retry': 2.0.0 + '@smithy/util-defaults-mode-browser': 2.0.16 + '@smithy/util-defaults-mode-node': 2.0.21 + '@smithy/util-retry': 2.0.5 '@smithy/util-utf8': 2.0.0 fast-xml-parser: 4.2.5 tslib: 2.6.2 @@ -762,299 +823,349 @@ packages: dev: false optional: true - /@aws-sdk/credential-provider-cognito-identity@3.398.0: + /@aws-sdk/core@3.436.0: + resolution: + { + integrity: sha512-vX5/LjXvCejC2XUY6TSg1oozjqK6BvkE75t0ys9dgqyr5PlZyZksMoeAFHUlj0sCjhT3ziWCujP1oiSpPWY9hg==, + } + engines: { node: '>=14.0.0' } + requiresBuild: true + dependencies: + '@smithy/smithy-client': 2.1.12 + dev: false + optional: true + + /@aws-sdk/credential-provider-cognito-identity@3.437.0: resolution: { - integrity: sha512-MFUhy1YayHg5ypRTk4OTfDumQRP+OJBagaGv14kA8DzhKH1sNrU4HV7A7y2J4SvkN5hG/KnLJqxpakCtB2/O2g==, + integrity: sha512-XCIb6yfX9YlEc7Hn4dfSkLny31OMpekA7usFsXEnoOn3geCKC1xFvrpa9LhHbxkMqLTVzWPGji2DGlJAb2xxpw==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/client-cognito-identity': 3.398.0 - '@aws-sdk/types': 3.398.0 + '@aws-sdk/client-cognito-identity': 3.437.0 + '@aws-sdk/types': 3.433.0 '@smithy/property-provider': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 transitivePeerDependencies: - aws-crt dev: false optional: true - /@aws-sdk/credential-provider-env@3.398.0: + /@aws-sdk/credential-provider-env@3.433.0: resolution: { - integrity: sha512-Z8Yj5z7FroAsR6UVML+XUdlpoqEe9Dnle8c2h8/xWwIC2feTfIBhjLhRVxfbpbM1pLgBSNEcZ7U8fwq5l7ESVQ==, + integrity: sha512-Vl7Qz5qYyxBurMn6hfSiNJeUHSqfVUlMt0C1Bds3tCkl3IzecRWwyBOlxtxO3VCrgVeW3HqswLzCvhAFzPH6nQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 '@smithy/property-provider': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/credential-provider-ini@3.398.0: + /@aws-sdk/credential-provider-http@3.435.0: resolution: { - integrity: sha512-AsK1lStK3nB9Cn6S6ODb1ktGh7SRejsNVQVKX3t5d3tgOaX+aX1Iwy8FzM/ZEN8uCloeRifUGIY9uQFygg5mSw==, + integrity: sha512-i07YSy3+IrXwAzp3goCMo2OYzAwqRGIWPNMUX5ziFgA1eMlRWNC2slnbqJzax6xHrU8HdpNESAfflnQvUVBqYQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/credential-provider-env': 3.398.0 - '@aws-sdk/credential-provider-process': 3.398.0 - '@aws-sdk/credential-provider-sso': 3.398.0 - '@aws-sdk/credential-provider-web-identity': 3.398.0 - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 + '@smithy/fetch-http-handler': 2.2.4 + '@smithy/node-http-handler': 2.1.8 + '@smithy/property-provider': 2.0.5 + '@smithy/protocol-http': 3.0.8 + '@smithy/smithy-client': 2.1.12 + '@smithy/types': 2.4.0 + '@smithy/util-stream': 2.0.17 + tslib: 2.6.2 + dev: false + optional: true + + /@aws-sdk/credential-provider-ini@3.437.0: + resolution: + { + integrity: sha512-UybiJxYPvdwok5OcI9LakaHmaWZBdkX0gY8yU2n7TomYgWOwDJ88MpQgjXUJJ249PH+9/+How5H3vnFp0xJ0uQ==, + } + engines: { node: '>=14.0.0' } + requiresBuild: true + dependencies: + '@aws-sdk/credential-provider-env': 3.433.0 + '@aws-sdk/credential-provider-process': 3.433.0 + '@aws-sdk/credential-provider-sso': 3.437.0 + '@aws-sdk/credential-provider-web-identity': 3.433.0 + '@aws-sdk/types': 3.433.0 '@smithy/credential-provider-imds': 2.0.5 '@smithy/property-provider': 2.0.5 - '@smithy/shared-ini-file-loader': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/shared-ini-file-loader': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 transitivePeerDependencies: - aws-crt dev: false optional: true - /@aws-sdk/credential-provider-node@3.398.0: + /@aws-sdk/credential-provider-node@3.437.0: resolution: { - integrity: sha512-odmI/DSKfuWUYeDnGTCEHBbC8/MwnF6yEq874zl6+owoVv0ZsYP8qBHfiJkYqrwg7wQ7Pi40sSAPC1rhesGwzg==, + integrity: sha512-FMtgEe/me68xZQsymEpMcw7OuuiHaHx/Tp5EqZP5FC0Yv1yX3qr/ncIWU2zY3a9K0iLERmzQI1g3CMd8r4sy8A==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/credential-provider-env': 3.398.0 - '@aws-sdk/credential-provider-ini': 3.398.0 - '@aws-sdk/credential-provider-process': 3.398.0 - '@aws-sdk/credential-provider-sso': 3.398.0 - '@aws-sdk/credential-provider-web-identity': 3.398.0 - '@aws-sdk/types': 3.398.0 + '@aws-sdk/credential-provider-env': 3.433.0 + '@aws-sdk/credential-provider-ini': 3.437.0 + '@aws-sdk/credential-provider-process': 3.433.0 + '@aws-sdk/credential-provider-sso': 3.437.0 + '@aws-sdk/credential-provider-web-identity': 3.433.0 + '@aws-sdk/types': 3.433.0 '@smithy/credential-provider-imds': 2.0.5 '@smithy/property-provider': 2.0.5 - '@smithy/shared-ini-file-loader': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/shared-ini-file-loader': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 transitivePeerDependencies: - aws-crt dev: false optional: true - /@aws-sdk/credential-provider-process@3.398.0: + /@aws-sdk/credential-provider-process@3.433.0: resolution: { - integrity: sha512-WrkBL1W7TXN508PA9wRXPFtzmGpVSW98gDaHEaa8GolAPHMPa5t2QcC/z/cFpglzrcVv8SA277zu9Z8tELdZhg==, + integrity: sha512-W7FcGlQjio9Y/PepcZGRyl5Bpwb0uWU7qIUCh+u4+q2mW4D5ZngXg8V/opL9/I/p4tUH9VXZLyLGwyBSkdhL+A==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 '@smithy/property-provider': 2.0.5 - '@smithy/shared-ini-file-loader': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/shared-ini-file-loader': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/credential-provider-sso@3.398.0: + /@aws-sdk/credential-provider-sso@3.437.0: resolution: { - integrity: sha512-2Dl35587xbnzR/GGZqA2MnFs8+kS4wbHQO9BioU0okA+8NRueohNMdrdQmQDdSNK4BfIpFspiZmFkXFNyEAfgw==, + integrity: sha512-kijtnyyA6/+ipOef4KACsLDUTFWDZ97DSWKU0hJFyGEfelaon6o7NNVufuVOWrBNyklNWZqvPLuwWWQCxb6fuQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/client-sso': 3.398.0 - '@aws-sdk/token-providers': 3.398.0 - '@aws-sdk/types': 3.398.0 + '@aws-sdk/client-sso': 3.437.0 + '@aws-sdk/token-providers': 3.437.0 + '@aws-sdk/types': 3.433.0 '@smithy/property-provider': 2.0.5 - '@smithy/shared-ini-file-loader': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/shared-ini-file-loader': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 transitivePeerDependencies: - aws-crt dev: false optional: true - /@aws-sdk/credential-provider-web-identity@3.398.0: + /@aws-sdk/credential-provider-web-identity@3.433.0: resolution: { - integrity: sha512-iG3905Alv9pINbQ8/MIsshgqYMbWx+NDQWpxbIW3W0MkSH3iAqdVpSCteYidYX9G/jv2Um1nW3y360ib20bvNg==, + integrity: sha512-RlwjP1I5wO+aPpwyCp23Mk8nmRbRL33hqRASy73c4JA2z2YiRua+ryt6MalIxehhwQU6xvXUKulJnPG9VaMFZg==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 '@smithy/property-provider': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/credential-providers@3.398.0: + /@aws-sdk/credential-providers@3.437.0: resolution: { - integrity: sha512-355vXmImn2e85mIWSYDVb101AF2lIVHKNCaH6sV1U/8i0ZOXh2cJYNdkRYrxNt1ezDB0k97lSKvuDx7RDvJyRg==, + integrity: sha512-aLgwo45dTDxAO2Gtx+9y4CfiEhvvGfWz2M+IMS48dQ2gmp1z+GXMiJv1zBhoidL2AvQMOpkgO0bl+qFlC4Cmmw==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/client-cognito-identity': 3.398.0 - '@aws-sdk/client-sso': 3.398.0 - '@aws-sdk/client-sts': 3.398.0 - '@aws-sdk/credential-provider-cognito-identity': 3.398.0 - '@aws-sdk/credential-provider-env': 3.398.0 - '@aws-sdk/credential-provider-ini': 3.398.0 - '@aws-sdk/credential-provider-node': 3.398.0 - '@aws-sdk/credential-provider-process': 3.398.0 - '@aws-sdk/credential-provider-sso': 3.398.0 - '@aws-sdk/credential-provider-web-identity': 3.398.0 - '@aws-sdk/types': 3.398.0 + '@aws-sdk/client-cognito-identity': 3.437.0 + '@aws-sdk/client-sso': 3.437.0 + '@aws-sdk/client-sts': 3.437.0 + '@aws-sdk/credential-provider-cognito-identity': 3.437.0 + '@aws-sdk/credential-provider-env': 3.433.0 + '@aws-sdk/credential-provider-http': 3.435.0 + '@aws-sdk/credential-provider-ini': 3.437.0 + '@aws-sdk/credential-provider-node': 3.437.0 + '@aws-sdk/credential-provider-process': 3.433.0 + '@aws-sdk/credential-provider-sso': 3.437.0 + '@aws-sdk/credential-provider-web-identity': 3.433.0 + '@aws-sdk/types': 3.433.0 '@smithy/credential-provider-imds': 2.0.5 '@smithy/property-provider': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 transitivePeerDependencies: - aws-crt dev: false optional: true - /@aws-sdk/middleware-host-header@3.398.0: + /@aws-sdk/middleware-host-header@3.433.0: resolution: { - integrity: sha512-m+5laWdBaxIZK2ko0OwcCHJZJ5V1MgEIt8QVQ3k4/kOkN9ICjevOYmba751pHoTnbOYB7zQd6D2OT3EYEEsUcA==, + integrity: sha512-mBTq3UWv1UzeHG+OfUQ2MB/5GEkt5LTKFaUqzL7ESwzW8XtpBgXnjZvIwu3Vcd3sEetMwijwaGiJhY0ae/YyaA==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 - '@smithy/protocol-http': 2.0.5 - '@smithy/types': 2.2.2 + '@aws-sdk/types': 3.433.0 + '@smithy/protocol-http': 3.0.8 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/middleware-logger@3.398.0: + /@aws-sdk/middleware-logger@3.433.0: resolution: { - integrity: sha512-CiJjW+FL12elS6Pn7/UVjVK8HWHhXMfvHZvOwx/Qkpy340sIhkuzOO6fZEruECDTZhl2Wqn81XdJ1ZQ4pRKpCg==, + integrity: sha512-We346Fb5xGonTGVZC9Nvqtnqy74VJzYuTLLiuuftA5sbNzftBDy/22QCfvYSTOAl3bvif+dkDUzQY2ihc5PwOQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 - '@smithy/types': 2.2.2 + '@aws-sdk/types': 3.433.0 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/middleware-recursion-detection@3.398.0: + /@aws-sdk/middleware-recursion-detection@3.433.0: resolution: { - integrity: sha512-7QpOqPQAZNXDXv6vsRex4R8dLniL0E/80OPK4PPFsrCh9btEyhN9Begh4i1T+5lL28hmYkztLOkTQ2N5J3hgRQ==, + integrity: sha512-HEvYC9PQlWY/ccUYtLvAlwwf1iCif2TSAmLNr3YTBRVa98x6jKL0hlCrHWYklFeqOGSKy6XhE+NGJMUII0/HaQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 - '@smithy/protocol-http': 2.0.5 - '@smithy/types': 2.2.2 + '@aws-sdk/types': 3.433.0 + '@smithy/protocol-http': 3.0.8 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/middleware-sdk-sts@3.398.0: + /@aws-sdk/middleware-sdk-sts@3.433.0: resolution: { - integrity: sha512-+JH76XHEgfVihkY+GurohOQ5Z83zVN1nYcQzwCFnCDTh4dG4KwhnZKG+WPw6XJECocY0R+H0ivofeALHvVWJtQ==, + integrity: sha512-ORYbJnBejUyonFl5FwIqhvI3Cq6sAp9j+JpkKZtFNma9tFPdrhmYgfCeNH32H/wGTQV/tUoQ3luh0gA4cuk6DA==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/middleware-signing': 3.398.0 - '@aws-sdk/types': 3.398.0 - '@smithy/types': 2.2.2 + '@aws-sdk/middleware-signing': 3.433.0 + '@aws-sdk/types': 3.433.0 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/middleware-signing@3.398.0: + /@aws-sdk/middleware-signing@3.433.0: resolution: { - integrity: sha512-O0KqXAix1TcvZBFt1qoFkHMUNJOSgjJTYS7lFTRKSwgsD27bdW2TM2r9R8DAccWFt5Amjkdt+eOwQMIXPGTm8w==, + integrity: sha512-jxPvt59NZo/epMNLNTu47ikmP8v0q217I6bQFGJG7JVFnfl36zDktMwGw+0xZR80qiK47/2BWrNpta61Zd2FxQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 '@smithy/property-provider': 2.0.5 - '@smithy/protocol-http': 2.0.5 - '@smithy/signature-v4': 2.0.5 - '@smithy/types': 2.2.2 - '@smithy/util-middleware': 2.0.0 + '@smithy/protocol-http': 3.0.8 + '@smithy/signature-v4': 2.0.12 + '@smithy/types': 2.4.0 + '@smithy/util-middleware': 2.0.5 + tslib: 2.6.2 + dev: false + optional: true + + /@aws-sdk/middleware-user-agent@3.433.0: + resolution: + { + integrity: sha512-jMgA1jHfisBK4oSjMKrtKEZf0sl2vzADivkFmyZFzORpSZxBnF6hC21RjaI+70LJLcc9rSCzLgcoz5lHb9LLDg==, + } + engines: { node: '>=14.0.0' } + requiresBuild: true + dependencies: + '@aws-sdk/types': 3.433.0 + '@aws-sdk/util-endpoints': 3.433.0 + '@smithy/protocol-http': 3.0.8 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/middleware-user-agent@3.398.0: + /@aws-sdk/region-config-resolver@3.433.0: resolution: { - integrity: sha512-nF1jg0L+18b5HvTcYzwyFgfZQQMELJINFqI0mi4yRKaX7T5a3aGp5RVLGGju/6tAGTuFbfBoEhkhU3kkxexPYQ==, + integrity: sha512-xpjRjCZW+CDFdcMmmhIYg81ST5UAnJh61IHziQEk0FXONrg4kjyYPZAOjEdzXQ+HxJQuGQLKPhRdzxmQnbX7pg==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 - '@aws-sdk/util-endpoints': 3.398.0 - '@smithy/protocol-http': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/node-config-provider': 2.1.3 + '@smithy/types': 2.4.0 + '@smithy/util-config-provider': 2.0.0 + '@smithy/util-middleware': 2.0.5 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/token-providers@3.398.0: + /@aws-sdk/token-providers@3.437.0: resolution: { - integrity: sha512-nrYgjzavGCKJL/48Vt0EL+OlIc5UZLfNGpgyUW9cv3XZwl+kXV0QB+HH0rHZZLfpbBgZ2RBIJR9uD5ieu/6hpQ==, + integrity: sha512-nV9qIuG0+6XJb7hWpCC+/K7RoY3PZUWndP8BRQv7PQhhpd8tG/I5Kxb0V83h2XFBXyyjnv0aOHO8ehz3Kfcv2Q==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: '@aws-crypto/sha256-browser': 3.0.0 '@aws-crypto/sha256-js': 3.0.0 - '@aws-sdk/middleware-host-header': 3.398.0 - '@aws-sdk/middleware-logger': 3.398.0 - '@aws-sdk/middleware-recursion-detection': 3.398.0 - '@aws-sdk/middleware-user-agent': 3.398.0 - '@aws-sdk/types': 3.398.0 - '@aws-sdk/util-endpoints': 3.398.0 - '@aws-sdk/util-user-agent-browser': 3.398.0 - '@aws-sdk/util-user-agent-node': 3.398.0 - '@smithy/config-resolver': 2.0.5 - '@smithy/fetch-http-handler': 2.0.5 - '@smithy/hash-node': 2.0.5 - '@smithy/invalid-dependency': 2.0.5 - '@smithy/middleware-content-length': 2.0.5 - '@smithy/middleware-endpoint': 2.0.5 - '@smithy/middleware-retry': 2.0.5 - '@smithy/middleware-serde': 2.0.5 - '@smithy/middleware-stack': 2.0.0 - '@smithy/node-config-provider': 2.0.5 - '@smithy/node-http-handler': 2.0.5 + '@aws-sdk/middleware-host-header': 3.433.0 + '@aws-sdk/middleware-logger': 3.433.0 + '@aws-sdk/middleware-recursion-detection': 3.433.0 + '@aws-sdk/middleware-user-agent': 3.433.0 + '@aws-sdk/region-config-resolver': 3.433.0 + '@aws-sdk/types': 3.433.0 + '@aws-sdk/util-endpoints': 3.433.0 + '@aws-sdk/util-user-agent-browser': 3.433.0 + '@aws-sdk/util-user-agent-node': 3.437.0 + '@smithy/config-resolver': 2.0.16 + '@smithy/fetch-http-handler': 2.2.4 + '@smithy/hash-node': 2.0.12 + '@smithy/invalid-dependency': 2.0.12 + '@smithy/middleware-content-length': 2.0.14 + '@smithy/middleware-endpoint': 2.1.3 + '@smithy/middleware-retry': 2.0.18 + '@smithy/middleware-serde': 2.0.12 + '@smithy/middleware-stack': 2.0.6 + '@smithy/node-config-provider': 2.1.3 + '@smithy/node-http-handler': 2.1.8 '@smithy/property-provider': 2.0.5 - '@smithy/protocol-http': 2.0.5 - '@smithy/shared-ini-file-loader': 2.0.5 - '@smithy/smithy-client': 2.0.5 - '@smithy/types': 2.2.2 - '@smithy/url-parser': 2.0.5 + '@smithy/protocol-http': 3.0.8 + '@smithy/shared-ini-file-loader': 2.2.2 + '@smithy/smithy-client': 2.1.12 + '@smithy/types': 2.4.0 + '@smithy/url-parser': 2.0.12 '@smithy/util-base64': 2.0.0 '@smithy/util-body-length-browser': 2.0.0 '@smithy/util-body-length-node': 2.1.0 - '@smithy/util-defaults-mode-browser': 2.0.5 - '@smithy/util-defaults-mode-node': 2.0.5 - '@smithy/util-retry': 2.0.0 + '@smithy/util-defaults-mode-browser': 2.0.16 + '@smithy/util-defaults-mode-node': 2.0.21 + '@smithy/util-retry': 2.0.5 '@smithy/util-utf8': 2.0.0 tslib: 2.6.2 transitivePeerDependencies: @@ -1062,28 +1173,28 @@ packages: dev: false optional: true - /@aws-sdk/types@3.398.0: + /@aws-sdk/types@3.433.0: resolution: { - integrity: sha512-r44fkS+vsEgKCuEuTV+TIk0t0m5ZlXHNjSDYEUvzLStbbfUFiNus/YG4UCa0wOk9R7VuQI67badsvvPeVPCGDQ==, + integrity: sha512-0jEE2mSrNDd8VGFjTc1otYrwYPIkzZJEIK90ZxisKvQ/EURGBhNzWn7ejWB9XCMFT6XumYLBR0V9qq5UPisWtA==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/util-endpoints@3.398.0: + /@aws-sdk/util-endpoints@3.433.0: resolution: { - integrity: sha512-Fy0gLYAei/Rd6BrXG4baspCnWTUSd0NdokU1pZh4KlfEAEN1i8SPPgfiO5hLk7+2inqtCmqxVJlfqbMVe9k4bw==, + integrity: sha512-LFNUh9FH7RMtYjSjPGz9lAJQMzmJ3RcXISzc5X5k2R/9mNwMK7y1k2VAfvx+RbuDbll6xwsXlgv6QHcxVdF2zw==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 + '@aws-sdk/types': 3.433.0 tslib: 2.6.2 dev: false optional: true @@ -1100,24 +1211,24 @@ packages: dev: false optional: true - /@aws-sdk/util-user-agent-browser@3.398.0: + /@aws-sdk/util-user-agent-browser@3.433.0: resolution: { - integrity: sha512-A3Tzx1tkDHlBT+IgxmsMCHbV8LM7SwwCozq2ZjJRx0nqw3MCrrcxQFXldHeX/gdUMO+0Oocb7HGSnVODTq+0EA==, + integrity: sha512-2Cf/Lwvxbt5RXvWFXrFr49vXv0IddiUwrZoAiwhDYxvsh+BMnh+NUFot+ZQaTrk/8IPZVDeLPWZRdVy00iaVXQ==, } requiresBuild: true dependencies: - '@aws-sdk/types': 3.398.0 - '@smithy/types': 2.2.2 + '@aws-sdk/types': 3.433.0 + '@smithy/types': 2.4.0 bowser: 2.11.0 tslib: 2.6.2 dev: false optional: true - /@aws-sdk/util-user-agent-node@3.398.0: + /@aws-sdk/util-user-agent-node@3.437.0: resolution: { - integrity: sha512-RTVQofdj961ej4//fEkppFf4KXqKGMTCqJYghx3G0C/MYXbg7MGl7LjfNGtJcboRE8pfHHQ/TUWBDA7RIAPPlQ==, + integrity: sha512-JVEcvWaniamtYVPem4UthtCNoTBCfFTwYj7Y3CrWZ2Qic4TqrwLkAfaBGtI2TGrhIClVr77uzLI6exqMTN7orA==, } engines: { node: '>=14.0.0' } requiresBuild: true @@ -1127,9 +1238,9 @@ packages: aws-crt: optional: true dependencies: - '@aws-sdk/types': 3.398.0 - '@smithy/node-config-provider': 2.0.5 - '@smithy/types': 2.2.2 + '@aws-sdk/types': 3.433.0 + '@smithy/node-config-provider': 2.1.3 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true @@ -1245,6 +1356,24 @@ packages: } dev: true + /@bot-whatsapp/bot@0.1.33: + resolution: + { + integrity: sha512-PHM4pe0wx8IUipL37O+rcx2a36HMBzgPQt7Sto3EH7Fndqj7bwsmmhKTzAtGDsja4NOlecjz2bh8fjC1aI9Faw==, + } + dependencies: + dotenv: 16.3.1 + dev: false + + /@bot-whatsapp/cli@0.1.33: + resolution: + { + integrity: sha512-DkHZVlowAZAqXestrMcplCJzRYiHFu54TpCvR/nXlOzz/g4UfqT3lcZGb6mm28Jc8HxTTAVnwCnjKnNZSaht/Q==, + } + hasBin: true + dependencies: + picocolors: 1.0.0 + /@bugsnag/browser@7.21.0: resolution: { @@ -1394,19 +1523,19 @@ packages: engines: { node: '>=0.1.90' } dev: true - /@commitlint/cli@17.4.4: + /@commitlint/cli@17.8.1: resolution: { - integrity: sha512-HwKlD7CPVMVGTAeFZylVNy14Vm5POVY0WxPkZr7EXLC/os0LH/obs6z4HRvJtH/nHCMYBvUBQhGwnufKfTjd5g==, + integrity: sha512-ay+WbzQesE0Rv4EQKfNbSMiJJ12KdKTDzIt0tcK4k11FdsWmtwP0Kp1NWMOUswfIWo6Eb7p7Ln721Nx9FLNBjg==, } engines: { node: '>=v14' } hasBin: true dependencies: - '@commitlint/format': 17.4.4 - '@commitlint/lint': 17.7.0 - '@commitlint/load': 17.7.1 - '@commitlint/read': 17.5.1 - '@commitlint/types': 17.4.4 + '@commitlint/format': 17.8.1 + '@commitlint/lint': 17.8.1 + '@commitlint/load': 17.8.1 + '@commitlint/read': 17.8.1 + '@commitlint/types': 17.8.1 execa: 5.1.1 lodash.isfunction: 3.0.9 resolve-from: 5.0.0 @@ -1417,35 +1546,35 @@ packages: - '@swc/wasm' dev: true - /@commitlint/config-conventional@17.4.4: + /@commitlint/config-conventional@17.8.1: resolution: { - integrity: sha512-u6ztvxqzi6NuhrcEDR7a+z0yrh11elY66nRrQIpqsqW6sZmpxYkDLtpRH8jRML+mmxYQ8s4qqF06Q/IQx5aJeQ==, + integrity: sha512-NxCOHx1kgneig3VLauWJcDWS40DVjg7nKOpBEEK9E5fjJpQqLCilcnKkIIjdBH98kEO1q3NpE5NSrZ2kl/QGJg==, } engines: { node: '>=v14' } dependencies: - conventional-changelog-conventionalcommits: 5.0.0 + conventional-changelog-conventionalcommits: 6.1.0 dev: true - /@commitlint/config-validator@17.6.7: + /@commitlint/config-validator@17.8.1: resolution: { - integrity: sha512-vJSncmnzwMvpr3lIcm0I8YVVDJTzyjy7NZAeXbTXy+MPUdAr9pKyyg7Tx/ebOQ9kqzE6O9WT6jg2164br5UdsQ==, + integrity: sha512-UUgUC+sNiiMwkyiuIFR7JG2cfd9t/7MV8VB4TZ+q02ZFkHoduUS4tJGsCBWvBOGD9Btev6IecPMvlWUfJorkEA==, } engines: { node: '>=v14' } dependencies: - '@commitlint/types': 17.4.4 + '@commitlint/types': 17.8.1 ajv: 8.12.0 dev: true - /@commitlint/ensure@17.6.7: + /@commitlint/ensure@17.8.1: resolution: { - integrity: sha512-mfDJOd1/O/eIb/h4qwXzUxkmskXDL9vNPnZ4AKYKiZALz4vHzwMxBSYtyL2mUIDeU9DRSpEUins8SeKtFkYHSw==, + integrity: sha512-xjafwKxid8s1K23NFpL8JNo6JnY/ysetKo8kegVM7c8vs+kWLP8VrQq+NbhgVlmCojhEDbzQKp4eRXSjVOGsow==, } engines: { node: '>=v14' } dependencies: - '@commitlint/types': 17.4.4 + '@commitlint/types': 17.8.1 lodash.camelcase: 4.3.0 lodash.kebabcase: 4.1.1 lodash.snakecase: 4.1.1 @@ -1453,160 +1582,160 @@ packages: lodash.upperfirst: 4.3.1 dev: true - /@commitlint/execute-rule@17.4.0: + /@commitlint/execute-rule@17.8.1: resolution: { - integrity: sha512-LIgYXuCSO5Gvtc0t9bebAMSwd68ewzmqLypqI2Kke1rqOqqDbMpYcYfoPfFlv9eyLIh4jocHWwCK5FS7z9icUA==, + integrity: sha512-JHVupQeSdNI6xzA9SqMF+p/JjrHTcrJdI02PwesQIDCIGUrv04hicJgCcws5nzaoZbROapPs0s6zeVHoxpMwFQ==, } engines: { node: '>=v14' } dev: true - /@commitlint/format@17.4.4: + /@commitlint/format@17.8.1: resolution: { - integrity: sha512-+IS7vpC4Gd/x+uyQPTAt3hXs5NxnkqAZ3aqrHd5Bx/R9skyCAWusNlNbw3InDbAK6j166D9asQM8fnmYIa+CXQ==, + integrity: sha512-f3oMTyZ84M9ht7fb93wbCKmWxO5/kKSbwuYvS867duVomoOsgrgljkGGIztmT/srZnaiGbaK8+Wf8Ik2tSr5eg==, } engines: { node: '>=v14' } dependencies: - '@commitlint/types': 17.4.4 + '@commitlint/types': 17.8.1 chalk: 4.1.2 dev: true - /@commitlint/is-ignored@17.7.0: + /@commitlint/is-ignored@17.8.1: resolution: { - integrity: sha512-043rA7m45tyEfW7Zv2vZHF++176MLHH9h70fnPoYlB1slKBeKl8BwNIlnPg4xBdRBVNPaCqvXxWswx2GR4c9Hw==, + integrity: sha512-UshMi4Ltb4ZlNn4F7WtSEugFDZmctzFpmbqvpyxD3la510J+PLcnyhf9chs7EryaRFJMdAKwsEKfNK0jL/QM4g==, } engines: { node: '>=v14' } dependencies: - '@commitlint/types': 17.4.4 + '@commitlint/types': 17.8.1 semver: 7.5.4 dev: true - /@commitlint/lint@17.7.0: + /@commitlint/lint@17.8.1: resolution: { - integrity: sha512-TCQihm7/uszA5z1Ux1vw+Nf3yHTgicus/+9HiUQk+kRSQawByxZNESeQoX9ujfVd3r4Sa+3fn0JQAguG4xvvbA==, + integrity: sha512-aQUlwIR1/VMv2D4GXSk7PfL5hIaFSfy6hSHV94O8Y27T5q+DlDEgd/cZ4KmVI+MWKzFfCTiTuWqjfRSfdRllCA==, } engines: { node: '>=v14' } dependencies: - '@commitlint/is-ignored': 17.7.0 - '@commitlint/parse': 17.7.0 - '@commitlint/rules': 17.7.0 - '@commitlint/types': 17.4.4 + '@commitlint/is-ignored': 17.8.1 + '@commitlint/parse': 17.8.1 + '@commitlint/rules': 17.8.1 + '@commitlint/types': 17.8.1 dev: true - /@commitlint/load@17.7.1: + /@commitlint/load@17.8.1: resolution: { - integrity: sha512-S/QSOjE1ztdogYj61p6n3UbkUvweR17FQ0zDbNtoTLc+Hz7vvfS7ehoTMQ27hPSjVBpp7SzEcOQu081RLjKHJQ==, + integrity: sha512-iF4CL7KDFstP1kpVUkT8K2Wl17h2yx9VaR1ztTc8vzByWWcbO/WaKwxsnCOqow9tVAlzPfo1ywk9m2oJ9ucMqA==, } engines: { node: '>=v14' } dependencies: - '@commitlint/config-validator': 17.6.7 - '@commitlint/execute-rule': 17.4.0 - '@commitlint/resolve-extends': 17.6.7 - '@commitlint/types': 17.4.4 - '@types/node': 20.4.7 + '@commitlint/config-validator': 17.8.1 + '@commitlint/execute-rule': 17.8.1 + '@commitlint/resolve-extends': 17.8.1 + '@commitlint/types': 17.8.1 + '@types/node': 20.5.1 chalk: 4.1.2 - cosmiconfig: 8.2.0 - cosmiconfig-typescript-loader: 4.4.0(@types/node@20.4.7)(cosmiconfig@8.2.0)(ts-node@10.9.1)(typescript@4.9.4) + cosmiconfig: 8.3.6(typescript@5.2.2) + cosmiconfig-typescript-loader: 4.4.0(@types/node@20.5.1)(cosmiconfig@8.3.6)(ts-node@10.9.1)(typescript@5.2.2) lodash.isplainobject: 4.0.6 lodash.merge: 4.6.2 lodash.uniq: 4.5.0 resolve-from: 5.0.0 - ts-node: 10.9.1(@types/node@20.4.7)(typescript@4.9.4) - typescript: 4.9.4 + ts-node: 10.9.1(@types/node@20.5.1)(typescript@5.2.2) + typescript: 5.2.2 transitivePeerDependencies: - '@swc/core' - '@swc/wasm' dev: true - /@commitlint/message@17.4.2: + /@commitlint/message@17.8.1: resolution: { - integrity: sha512-3XMNbzB+3bhKA1hSAWPCQA3lNxR4zaeQAQcHj0Hx5sVdO6ryXtgUBGGv+1ZCLMgAPRixuc6en+iNAzZ4NzAa8Q==, + integrity: sha512-6bYL1GUQsD6bLhTH3QQty8pVFoETfFQlMn2Nzmz3AOLqRVfNNtXBaSY0dhZ0dM6A2MEq4+2d7L/2LP8TjqGRkA==, } engines: { node: '>=v14' } dev: true - /@commitlint/parse@17.7.0: + /@commitlint/parse@17.8.1: resolution: { - integrity: sha512-dIvFNUMCUHqq5Abv80mIEjLVfw8QNuA4DS7OWip4pcK/3h5wggmjVnlwGCDvDChkw2TjK1K6O+tAEV78oxjxag==, + integrity: sha512-/wLUickTo0rNpQgWwLPavTm7WbwkZoBy3X8PpkUmlSmQJyWQTj0m6bDjiykMaDt41qcUbfeFfaCvXfiR4EGnfw==, } engines: { node: '>=v14' } dependencies: - '@commitlint/types': 17.4.4 + '@commitlint/types': 17.8.1 conventional-changelog-angular: 6.0.0 conventional-commits-parser: 4.0.0 dev: true - /@commitlint/read@17.5.1: + /@commitlint/read@17.8.1: resolution: { - integrity: sha512-7IhfvEvB//p9aYW09YVclHbdf1u7g7QhxeYW9ZHSO8Huzp8Rz7m05aCO1mFG7G8M+7yfFnXB5xOmG18brqQIBg==, + integrity: sha512-Fd55Oaz9irzBESPCdMd8vWWgxsW3OWR99wOntBDHgf9h7Y6OOHjWEdS9Xzen1GFndqgyoaFplQS5y7KZe0kO2w==, } engines: { node: '>=v14' } dependencies: - '@commitlint/top-level': 17.4.0 - '@commitlint/types': 17.4.4 - fs-extra: 11.1.0 + '@commitlint/top-level': 17.8.1 + '@commitlint/types': 17.8.1 + fs-extra: 11.1.1 git-raw-commits: 2.0.11 minimist: 1.2.8 dev: true - /@commitlint/resolve-extends@17.6.7: + /@commitlint/resolve-extends@17.8.1: resolution: { - integrity: sha512-PfeoAwLHtbOaC9bGn/FADN156CqkFz6ZKiVDMjuC2N5N0740Ke56rKU7Wxdwya8R8xzLK9vZzHgNbuGhaOVKIg==, + integrity: sha512-W/ryRoQ0TSVXqJrx5SGkaYuAaE/BUontL1j1HsKckvM6e5ZaG0M9126zcwL6peKSuIetJi7E87PRQF8O86EW0Q==, } engines: { node: '>=v14' } dependencies: - '@commitlint/config-validator': 17.6.7 - '@commitlint/types': 17.4.4 + '@commitlint/config-validator': 17.8.1 + '@commitlint/types': 17.8.1 import-fresh: 3.3.0 lodash.mergewith: 4.6.2 resolve-from: 5.0.0 resolve-global: 1.0.0 dev: true - /@commitlint/rules@17.7.0: + /@commitlint/rules@17.8.1: resolution: { - integrity: sha512-J3qTh0+ilUE5folSaoK91ByOb8XeQjiGcdIdiB/8UT1/Rd1itKo0ju/eQVGyFzgTMYt8HrDJnGTmNWwcMR1rmA==, + integrity: sha512-2b7OdVbN7MTAt9U0vKOYKCDsOvESVXxQmrvuVUZ0rGFMCrCPJWWP1GJ7f0lAypbDAhaGb8zqtdOr47192LBrIA==, } engines: { node: '>=v14' } dependencies: - '@commitlint/ensure': 17.6.7 - '@commitlint/message': 17.4.2 - '@commitlint/to-lines': 17.4.0 - '@commitlint/types': 17.4.4 + '@commitlint/ensure': 17.8.1 + '@commitlint/message': 17.8.1 + '@commitlint/to-lines': 17.8.1 + '@commitlint/types': 17.8.1 execa: 5.1.1 dev: true - /@commitlint/to-lines@17.4.0: + /@commitlint/to-lines@17.8.1: resolution: { - integrity: sha512-LcIy/6ZZolsfwDUWfN1mJ+co09soSuNASfKEU5sCmgFCvX5iHwRYLiIuoqXzOVDYOy7E7IcHilr/KS0e5T+0Hg==, + integrity: sha512-LE0jb8CuR/mj6xJyrIk8VLz03OEzXFgLdivBytoooKO5xLt5yalc8Ma5guTWobw998sbR3ogDd+2jed03CFmJA==, } engines: { node: '>=v14' } dev: true - /@commitlint/top-level@17.4.0: + /@commitlint/top-level@17.8.1: resolution: { - integrity: sha512-/1loE/g+dTTQgHnjoCy0AexKAEFyHsR2zRB4NWrZ6lZSMIxAhBJnmCqwao7b4H8888PsfoTBCLBYIw8vGnej8g==, + integrity: sha512-l6+Z6rrNf5p333SHfEte6r+WkOxGlWK4bLuZKbtf/2TXRN+qhrvn1XE63VhD8Oe9oIHQ7F7W1nG2k/TJFhx2yA==, } engines: { node: '>=v14' } dependencies: find-up: 5.0.0 dev: true - /@commitlint/types@17.4.4: + /@commitlint/types@17.8.1: resolution: { - integrity: sha512-amRN8tRLYOsxRr6mTnGGGvB5EmW/4DDjLMgiwK3CCVEmN6Sr/6xePGEpWaspKkckILuUORCwe6VfDBw6uj4axQ==, + integrity: sha512-PXDQXkAmiMEG162Bqdh9ChML/GJZo6vU+7F03ALKDK8zYc6SuAr47LjG7hGYRqUOz+WK0dU7bQ0xzuqFMdxzeQ==, } engines: { node: '>=v14' } dependencies: @@ -1670,7 +1799,7 @@ packages: } dev: true - /@docsearch/react@3.3.3(@algolia/client-search@4.19.1)(@types/react@18.0.14)(react-dom@18.2.0)(react@18.2.0): + /@docsearch/react@3.3.3(@algolia/client-search@4.20.0)(@types/react@18.0.14)(react-dom@18.2.0)(react@18.2.0): resolution: { integrity: sha512-pLa0cxnl+G0FuIDuYlW+EBK6Rw2jwLw9B1RHIeS4N4s2VhsfJ/wzeCi3CWcs5yVfxLd5ZK50t//TMA5e79YT7Q==, @@ -1688,7 +1817,7 @@ packages: optional: true dependencies: '@algolia/autocomplete-core': 1.7.4 - '@algolia/autocomplete-preset-algolia': 1.7.4(@algolia/client-search@4.19.1)(algoliasearch@4.19.1) + '@algolia/autocomplete-preset-algolia': 1.7.4(@algolia/client-search@4.20.0)(algoliasearch@4.19.1) '@docsearch/css': 3.3.3 '@types/react': 18.0.14 algoliasearch: 4.19.1 @@ -2147,6 +2276,27 @@ packages: dev: true optional: true + /@eslint-community/eslint-utils@4.4.0(eslint@8.52.0): + resolution: + { + integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==, + } + engines: { node: ^12.22.0 || ^14.17.0 || >=16.0.0 } + peerDependencies: + eslint: ^6.0.0 || ^7.0.0 || >=8.0.0 + dependencies: + eslint: 8.52.0 + eslint-visitor-keys: 3.4.3 + dev: true + + /@eslint-community/regexpp@4.10.0: + resolution: + { + integrity: sha512-Cu96Sd2By9mCNTx2iyKOmq10v22jUVQv0lQnlGNy16oE9589yE+QADPbrMGCkA51cKZSg3Pu/aTJVTGfL/qjUA==, + } + engines: { node: ^12.0.0 || ^14.0.0 || >=16.0.0 } + dev: true + /@eslint/eslintrc@1.4.1: resolution: { @@ -2167,6 +2317,34 @@ packages: - supports-color dev: true + /@eslint/eslintrc@2.1.2: + resolution: + { + integrity: sha512-+wvgpDsrB1YqAMdEUCcnTlpfVBH7Vqn6A/NT3D8WVXFIaKMlErPIZT3oCIAVCOtarRpMtelZLqJeU3t7WY6X6g==, + } + engines: { node: ^12.22.0 || ^14.17.0 || >=16.0.0 } + dependencies: + ajv: 6.12.6 + debug: 4.3.4(supports-color@9.4.0) + espree: 9.6.1 + globals: 13.23.0 + ignore: 5.2.4 + import-fresh: 3.3.0 + js-yaml: 4.1.0 + minimatch: 3.1.2 + strip-json-comments: 3.1.1 + transitivePeerDependencies: + - supports-color + dev: true + + /@eslint/js@8.52.0: + resolution: + { + integrity: sha512-mjZVbpaeMZludF2fsWLD0Z9gCref1Tk4i9+wddjRvpUNqqcndPkBD09N/Mapey0b3jaXbLm2kICwFv2E64QinA==, + } + engines: { node: ^12.22.0 || ^14.17.0 || >=16.0.0 } + dev: true + /@ffmpeg-installer/darwin-arm64@4.1.5: resolution: { @@ -2353,6 +2531,20 @@ packages: - supports-color dev: true + /@humanwhocodes/config-array@0.11.13: + resolution: + { + integrity: sha512-JSBDMiDKSzQVngfRjOdFXgFfklaXI4K9nLF49Auh21lmBWRLIK3+xTErTWD4KU54pb6coM6ESE7Awz/FNU3zgQ==, + } + engines: { node: '>=10.10.0' } + dependencies: + '@humanwhocodes/object-schema': 2.0.1 + debug: 4.3.4(supports-color@9.4.0) + minimatch: 3.1.2 + transitivePeerDependencies: + - supports-color + dev: true + /@humanwhocodes/module-importer@1.0.1: resolution: { @@ -2376,6 +2568,13 @@ packages: } dev: true + /@humanwhocodes/object-schema@2.0.1: + resolution: + { + integrity: sha512-dvuCeX5fC9dXgJn9t+X5atfmgQAzUOWqS1254Gh0m6i8wKd10ebXkfNKiRK+1GWi/yTvvLDHpoxLr0xxxeslWw==, + } + dev: true + /@hutson/parse-repository-url@3.0.2: resolution: { @@ -2422,7 +2621,7 @@ packages: } engines: { node: '>= 8.3' } dependencies: - '@types/istanbul-lib-coverage': 2.0.4 + '@types/istanbul-lib-coverage': 2.0.5 '@types/istanbul-reports': 1.1.2 '@types/yargs': 15.0.15 chalk: 3.0.0 @@ -2435,7 +2634,7 @@ packages: } engines: { node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0 } dependencies: - '@types/istanbul-lib-coverage': 2.0.4 + '@types/istanbul-lib-coverage': 2.0.5 '@types/istanbul-reports': 3.0.1 '@types/node': 20.5.7 '@types/yargs': 16.0.5 @@ -2487,6 +2686,16 @@ packages: '@jridgewell/sourcemap-codec': 1.4.15 dev: true + /@jridgewell/trace-mapping@0.3.20: + resolution: + { + integrity: sha512-R8LcPeWZol2zR8mmH3JeKQ6QRCFb7XgUhV9ZlGhHLGyg4wpPiPZNQOOWhFZhxKw8u//yTbNGI42Bx/3paXEQ+Q==, + } + dependencies: + '@jridgewell/resolve-uri': 3.1.1 + '@jridgewell/sourcemap-codec': 1.4.15 + dev: true + /@jridgewell/trace-mapping@0.3.9: resolution: { @@ -2598,7 +2807,7 @@ packages: ps-list: 8.1.1 read-pkg-up: 9.1.0 readdirp: 3.6.0 - resolve: 2.0.0-next.4 + resolve: 2.0.0-next.5 rfdc: 1.3.0 safe-json-stringify: 1.2.0 semver: 7.5.4 @@ -3590,7 +3799,7 @@ packages: precinct: 9.2.1(supports-color@9.4.0) read-package-json-fast: 2.0.3 require-package-name: 2.0.1 - resolve: 2.0.0-next.4 + resolve: 2.0.0-next.5 semver: 7.5.4 tmp-promise: 3.0.3 toml: 3.0.0 @@ -3634,7 +3843,7 @@ packages: path-exists: 5.0.0 precinct: 11.0.5(supports-color@9.4.0) require-package-name: 2.0.1 - resolve: 2.0.0-next.4 + resolve: 2.0.0-next.5 semver: 7.5.4 tmp-promise: 3.0.3 toml: 3.0.0 @@ -3684,24 +3893,6 @@ packages: engines: { node: '>= 14' } dev: true - /@octokit/core@4.2.0: - resolution: - { - integrity: sha512-AgvDRUg3COpR82P7PBdGZF/NNqGmtMq2NiPqeSsDIeCfYFOZ9gddqWNQHnFdEUf+YwOj4aZYmJnlPp7OXmDIDg==, - } - engines: { node: '>= 14' } - dependencies: - '@octokit/auth-token': 3.0.4 - '@octokit/graphql': 5.0.6 - '@octokit/request': 6.2.8 - '@octokit/request-error': 3.0.3 - '@octokit/types': 9.3.2 - before-after-hook: 2.2.3 - universal-user-agent: 6.0.0 - transitivePeerDependencies: - - encoding - dev: true - /@octokit/core@4.2.4: resolution: { @@ -3746,10 +3937,10 @@ packages: - encoding dev: true - /@octokit/openapi-types@18.0.0: + /@octokit/openapi-types@18.1.1: resolution: { - integrity: sha512-V8GImKs3TeQRxRtXFpG2wl19V7444NIOTDF24AWuIbmNaNYOQMWRbjcGDXV5B+0n887fgDcuMNOmlul+k+oJtw==, + integrity: sha512-VRaeH8nCDtF5aXWnjPuEMIYf1itK/s3JYyJcWFJT8X9pSNnBtriDf7wlEWsGuhPLl4QIH4xM8fqTXDwJ3Mu6sw==, } dev: true @@ -3848,7 +4039,7 @@ packages: integrity: sha512-Vm8IddVmhCgU1fxC1eyinpwqzXPEYu0NrYzD3YZjlGjyftdLBTeqNblRC0jmJmgxbJIsQlyogVeGnrNaaMVzIg==, } dependencies: - '@octokit/openapi-types': 18.0.0 + '@octokit/openapi-types': 18.1.1 dev: true /@octokit/types@9.3.2: @@ -3857,7 +4048,7 @@ packages: integrity: sha512-D4iHGTdAnEEVsB8fl95m1hiz7D5YiRdQ9b/OEb3BYRVwbLsGHcRVPz+u+BgRLNk0Q0/4iZCBqDN96j2XNxfXrA==, } dependencies: - '@octokit/openapi-types': 18.0.0 + '@octokit/openapi-types': 18.1.1 dev: true /@pnpm/config.env-replace@1.1.0: @@ -3897,7 +4088,7 @@ packages: } dev: false - /@rollup/plugin-commonjs@23.0.7(rollup@3.17.2): + /@rollup/plugin-commonjs@23.0.7(rollup@3.29.4): resolution: { integrity: sha512-hsSD5Qzyuat/swzrExGG5l7EuIlPhwTsT7KwKbSCQzIcJWjRxiimi/0tyMYY2bByitNb3i1p+6JWEDGa0NvT0Q==, @@ -3909,16 +4100,16 @@ packages: rollup: optional: true dependencies: - '@rollup/pluginutils': 5.0.3(rollup@3.17.2) + '@rollup/pluginutils': 5.0.5(rollup@3.29.4) commondir: 1.0.1 estree-walker: 2.0.2 glob: 8.1.0 is-reference: 1.2.1 magic-string: 0.27.0 - rollup: 3.17.2 + rollup: 3.29.4 dev: true - /@rollup/plugin-json@5.0.2(rollup@3.17.2): + /@rollup/plugin-json@5.0.2(rollup@3.29.4): resolution: { integrity: sha512-D1CoOT2wPvadWLhVcmpkDnesTzjhNIQRWLsc3fA49IFOP2Y84cFOOJ+nKGYedvXHKUsPeq07HR4hXpBBr+CHlA==, @@ -3930,64 +4121,64 @@ packages: rollup: optional: true dependencies: - '@rollup/pluginutils': 5.0.3(rollup@3.17.2) - rollup: 3.17.2 + '@rollup/pluginutils': 5.0.5(rollup@3.29.4) + rollup: 3.29.4 dev: true - /@rollup/plugin-node-resolve@15.0.1(rollup@3.17.2): + /@rollup/plugin-node-resolve@15.2.3(rollup@3.29.4): resolution: { - integrity: sha512-ReY88T7JhJjeRVbfCyNj+NXAG3IIsVMsX9b5/9jC98dRP8/yxlZdz7mHZbHk5zHr24wZZICS5AcXsFZAXYUQEg==, + integrity: sha512-j/lym8nf5E21LwBT4Df1VD6hRO2L2iwUeUmP7litikRsVp1H6NWx20NEp0Y7su+7XGc476GnXXc4kFeZNGmaSQ==, } engines: { node: '>=14.0.0' } peerDependencies: - rollup: ^2.78.0||^3.0.0 + rollup: ^2.78.0||^3.0.0||^4.0.0 peerDependenciesMeta: rollup: optional: true dependencies: - '@rollup/pluginutils': 5.0.3(rollup@3.17.2) + '@rollup/pluginutils': 5.0.5(rollup@3.29.4) '@types/resolve': 1.20.2 deepmerge: 4.3.1 is-builtin-module: 3.2.1 is-module: 1.0.0 - resolve: 1.22.4 - rollup: 3.17.2 + resolve: 1.22.8 + rollup: 3.29.4 dev: true - /@rollup/plugin-replace@5.0.2(rollup@3.17.2): + /@rollup/plugin-replace@5.0.4(rollup@3.29.4): resolution: { - integrity: sha512-M9YXNekv/C/iHHK+cvORzfRYfPbq0RDD8r0G+bMiTXjNGKulPnCT9O3Ss46WfhI6ZOCgApOP7xAdmCQJ+U2LAA==, + integrity: sha512-E2hmRnlh09K8HGT0rOnnri9OTh+BILGr7NVJGB30S4E3cLRn3J0xjdiyOZ74adPs4NiAMgrjUMGAZNJDBgsdmQ==, } engines: { node: '>=14.0.0' } peerDependencies: - rollup: ^1.20.0||^2.0.0||^3.0.0 + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 peerDependenciesMeta: rollup: optional: true dependencies: - '@rollup/pluginutils': 5.0.3(rollup@3.17.2) - magic-string: 0.27.0 - rollup: 3.17.2 + '@rollup/pluginutils': 5.0.5(rollup@3.29.4) + magic-string: 0.30.5 + rollup: 3.29.4 dev: true - /@rollup/plugin-strip@3.0.2(rollup@3.17.2): + /@rollup/plugin-strip@3.0.4(rollup@3.29.4): resolution: { - integrity: sha512-L8Whin/DB5XsLE586+xcud6yX/pMVUlfalA999uAsC+dtwmBHSiUwtAxMl3eVvykX3N5BhdeAjStqDlzMmfUXw==, + integrity: sha512-LDRV49ZaavxUo2YoKKMQjCxzCxugu1rCPQa0lDYBOWLj6vtzBMr8DcoJjsmg+s450RbKbe3qI9ZLaSO+O1oNbg==, } engines: { node: '>=14.0.0' } peerDependencies: - rollup: ^1.20.0||^2.0.0||^3.0.0 + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 peerDependenciesMeta: rollup: optional: true dependencies: - '@rollup/pluginutils': 5.0.3(rollup@3.17.2) + '@rollup/pluginutils': 5.0.5(rollup@3.29.4) estree-walker: 2.0.2 - magic-string: 0.27.0 - rollup: 3.17.2 + magic-string: 0.30.5 + rollup: 3.29.4 dev: true /@rollup/pluginutils@4.2.1: @@ -4001,7 +4192,7 @@ packages: picomatch: 2.3.1 dev: true - /@rollup/pluginutils@5.0.3(rollup@3.17.2): + /@rollup/pluginutils@5.0.3(rollup@3.29.4): resolution: { integrity: sha512-hfllNN4a80rwNQ9QCxhxuHCGHMAvabXqxNdaChUSSadMre7t4iEUI6fFAhBOn/eIYTgYVhBv7vCLsAJ4u3lf3g==, @@ -4016,7 +4207,25 @@ packages: '@types/estree': 1.0.1 estree-walker: 2.0.2 picomatch: 2.3.1 - rollup: 3.17.2 + rollup: 3.29.4 + dev: true + + /@rollup/pluginutils@5.0.5(rollup@3.29.4): + resolution: + { + integrity: sha512-6aEYR910NyP73oHiJglti74iRyOwgFU4x3meH/H8OJx6Ry0j6cOVZ5X/wTvub7G7Ao6qaHBEaNsV3GLJkSsF+Q==, + } + engines: { node: '>=14.0.0' } + peerDependencies: + rollup: ^1.20.0||^2.0.0||^3.0.0||^4.0.0 + peerDependenciesMeta: + rollup: + optional: true + dependencies: + '@types/estree': 1.0.3 + estree-walker: 2.0.2 + picomatch: 2.3.1 + rollup: 3.29.4 dev: true /@samverschueren/stream-to-observable@0.3.1(rxjs@6.6.7): @@ -4093,30 +4302,47 @@ packages: escape-string-regexp: 5.0.0 dev: true - /@smithy/abort-controller@2.0.5: + /@smithy/abort-controller@2.0.12: resolution: { - integrity: sha512-byVZ2KWLMPYAZGKjRpniAzLcygJO4ruClZKdJTuB0eCB76ONFTdptBHlviHpAZXknRz7skYWPfcgO9v30A1SyA==, + integrity: sha512-YIJyefe1mi3GxKdZxEBEuzYOeQ9xpYfqnFmWzojCssRAuR7ycxwpoRQgp965vuW426xUAQhCV5rCaWElQ7XsaA==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/config-resolver@2.0.5: + /@smithy/config-resolver@2.0.16: resolution: { - integrity: sha512-n0c2AXz+kjALY2FQr7Zy9zhYigXzboIh1AuUUVCqFBKFtdEvTwnwPXrTDoEehLiRTUHNL+4yzZ3s+D0kKYSLSg==, + integrity: sha512-1k+FWHQDt2pfpXhJsOmNMmlAZ3NUQ98X5tYsjQhVGq+0X6cOBMhfh6Igd0IX3Ut6lEO6DQAdPMI/blNr3JZfMQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/node-config-provider': 2.1.3 + '@smithy/types': 2.4.0 '@smithy/util-config-provider': 2.0.0 - '@smithy/util-middleware': 2.0.0 + '@smithy/util-middleware': 2.0.5 + tslib: 2.6.2 + dev: false + optional: true + + /@smithy/credential-provider-imds@2.0.18: + resolution: + { + integrity: sha512-QnPBi6D2zj6AHJdUTo5zXmk8vwHJ2bNevhcVned1y+TZz/OI5cizz5DsYNkqFUIDn8tBuEyKNgbmKVNhBbuY3g==, + } + engines: { node: '>=14.0.0' } + requiresBuild: true + dependencies: + '@smithy/node-config-provider': 2.1.3 + '@smithy/property-provider': 2.0.13 + '@smithy/types': 2.4.0 + '@smithy/url-parser': 2.0.12 tslib: 2.6.2 dev: false optional: true @@ -4131,64 +4357,64 @@ packages: dependencies: '@smithy/node-config-provider': 2.0.5 '@smithy/property-provider': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 '@smithy/url-parser': 2.0.5 tslib: 2.6.2 dev: false optional: true - /@smithy/eventstream-codec@2.0.5: + /@smithy/eventstream-codec@2.0.12: resolution: { - integrity: sha512-iqR6OuOV3zbQK8uVs9o+9AxhVk8kW9NAxA71nugwUB+kTY9C35pUd0A5/m4PRT0Y0oIW7W4kgnSR3fdYXQjECw==, + integrity: sha512-ZZQLzHBJkbiAAdj2C5K+lBlYp/XJ+eH2uy+jgJgYIFW/o5AM59Hlj7zyI44/ZTDIQWmBxb3EFv/c5t44V8/g8A==, } requiresBuild: true dependencies: '@aws-crypto/crc32': 3.0.0 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 '@smithy/util-hex-encoding': 2.0.0 tslib: 2.6.2 dev: false optional: true - /@smithy/fetch-http-handler@2.0.5: + /@smithy/fetch-http-handler@2.2.4: resolution: { - integrity: sha512-EzFoMowdBNy1VqtvkiXgPFEdosIAt4/4bgZ8uiDiUyfhmNXq/3bV+CagPFFBsgFOR/X2XK4zFZHRsoa7PNHVVg==, + integrity: sha512-gIPRFEGi+c6V52eauGKrjDzPWF2Cu7Z1r5F8A3j2wcwz25sPG/t8kjsbEhli/tS/2zJp/ybCZXe4j4ro3yv/HA==, } requiresBuild: true dependencies: - '@smithy/protocol-http': 2.0.5 - '@smithy/querystring-builder': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/protocol-http': 3.0.8 + '@smithy/querystring-builder': 2.0.12 + '@smithy/types': 2.4.0 '@smithy/util-base64': 2.0.0 tslib: 2.6.2 dev: false optional: true - /@smithy/hash-node@2.0.5: + /@smithy/hash-node@2.0.12: resolution: { - integrity: sha512-mk551hIywBITT+kXruRNXk7f8Fy7DTzBjZJSr/V6nolYKmUHIG3w5QU6nO9qPYEQGKc/yEPtkpdS28ndeG93lA==, + integrity: sha512-fDZnTr5j9t5qcbeJ037aMZXxMka13Znqwrgy3PAqYj6Dm3XHXHftTH3q+NWgayUxl1992GFtQt1RuEzRMy3NnQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 '@smithy/util-buffer-from': 2.0.0 '@smithy/util-utf8': 2.0.0 tslib: 2.6.2 dev: false optional: true - /@smithy/invalid-dependency@2.0.5: + /@smithy/invalid-dependency@2.0.12: resolution: { - integrity: sha512-0wEi+JT0hM+UUwrJVYbqjuGFhy5agY/zXyiN7BNAJ1XoCDjU5uaNSj8ekPWsXd/d4yM6NSe8UbPd8cOc1+3oBQ==, + integrity: sha512-p5Y+iMHV3SoEpy3VSR7mifbreHQwVSvHSAz/m4GdoXfOzKzaYC8hYv10Ks7Deblkf7lhas8U+lAp9ThbBM+ZXA==, } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true @@ -4205,75 +4431,79 @@ packages: dev: false optional: true - /@smithy/middleware-content-length@2.0.5: + /@smithy/middleware-content-length@2.0.14: resolution: { - integrity: sha512-E7VwV5H02fgZIUGRli4GevBCAPvkyEI/fgl9SU47nPPi3DAAX3nEtUb8xfGbXjOcJ5BdSUoWWZn42tEd/blOqA==, + integrity: sha512-poUNgKTw9XwPXfX9nEHpVgrMNVpaSMZbshqvPxFVoalF4wp6kRzYKOfdesSVectlQ51VtigoLfbXcdyPwvxgTg==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/protocol-http': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/protocol-http': 3.0.8 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/middleware-endpoint@2.0.5: + /@smithy/middleware-endpoint@2.1.3: resolution: { - integrity: sha512-tyzDuoNTbsMQCq5Xkc4QOt6e2GACUllQIV8SQ5fc59FtOIV9/vbf58/GxVjZm2o8+MMbdDBANjTDZe/ijZKfyA==, + integrity: sha512-ZrQ0/YX6hNVTxqMEHtEaDbDv6pNeEji/a5Vk3HuFC5R3ZY8lfoATyxmOGxBVYnF3NUvZLNC7umEv1WzWGWvCGQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/middleware-serde': 2.0.5 - '@smithy/types': 2.2.2 - '@smithy/url-parser': 2.0.5 - '@smithy/util-middleware': 2.0.0 + '@smithy/middleware-serde': 2.0.12 + '@smithy/node-config-provider': 2.1.3 + '@smithy/shared-ini-file-loader': 2.2.2 + '@smithy/types': 2.4.0 + '@smithy/url-parser': 2.0.12 + '@smithy/util-middleware': 2.0.5 tslib: 2.6.2 dev: false optional: true - /@smithy/middleware-retry@2.0.5: + /@smithy/middleware-retry@2.0.18: resolution: { - integrity: sha512-ulIfbFyzQTVnJbLjUl1CTSi0etg6tej/ekwaLp0Gn8ybUkDkKYa+uB6CF/m2J5B6meRwyJlsryR+DjaOVyiicg==, + integrity: sha512-VyrHQRldGSb3v9oFOB5yPxmLT7U2sQic2ytylOnYlnsmVOLlFIaI6sW22c+w2675yq+XZ6HOuzV7x2OBYCWRNA==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/protocol-http': 2.0.5 - '@smithy/service-error-classification': 2.0.0 - '@smithy/types': 2.2.2 - '@smithy/util-middleware': 2.0.0 - '@smithy/util-retry': 2.0.0 + '@smithy/node-config-provider': 2.1.3 + '@smithy/protocol-http': 3.0.8 + '@smithy/service-error-classification': 2.0.5 + '@smithy/types': 2.4.0 + '@smithy/util-middleware': 2.0.5 + '@smithy/util-retry': 2.0.5 tslib: 2.6.2 uuid: 8.3.2 dev: false optional: true - /@smithy/middleware-serde@2.0.5: + /@smithy/middleware-serde@2.0.12: resolution: { - integrity: sha512-in0AA5sous74dOfTGU9rMJBXJ0bDVNxwdXtEt5lh3FVd2sEyjhI+rqpLLRF1E4ixbw3RSEf80hfRpcPdjg4vvQ==, + integrity: sha512-IBeco157lIScecq2Z+n0gq56i4MTnfKxS7rbfrAORveDJgnbBAaEQgYqMqp/cYqKrpvEXcyTjwKHrBjCCIZh2A==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/middleware-stack@2.0.0: + /@smithy/middleware-stack@2.0.6: resolution: { - integrity: sha512-31XC1xNF65nlbc16yuh3wwTudmqs6qy4EseQUGF8A/p2m/5wdd/cnXJqpniy/XvXVwkHPz/GwV36HqzHtIKATQ==, + integrity: sha512-YSvNZeOKWLJ0M/ycxwDIe2Ztkp6Qixmcml1ggsSv2fdHKGkBPhGrX5tMzPGMI1yyx55UEYBi2OB4s+RriXX48A==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true @@ -4288,23 +4518,51 @@ packages: dependencies: '@smithy/property-provider': 2.0.5 '@smithy/shared-ini-file-loader': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/node-http-handler@2.0.5: + /@smithy/node-config-provider@2.1.3: resolution: { - integrity: sha512-lZm5DZf4b3V0saUw9WTC4/du887P6cy2fUyQgQQKRRV6OseButyD5yTzeMmXE53CaXJBMBsUvvIQ0hRVxIq56w==, + integrity: sha512-J6lXvRHGVnSX3n1PYi+e1L5HN73DkkJpUviV3Ebf+8wSaIjAf+eVNbzyvh/S5EQz7nf4KVfwbD5vdoZMAthAEQ==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/abort-controller': 2.0.5 - '@smithy/protocol-http': 2.0.5 - '@smithy/querystring-builder': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/property-provider': 2.0.13 + '@smithy/shared-ini-file-loader': 2.2.2 + '@smithy/types': 2.4.0 + tslib: 2.6.2 + dev: false + optional: true + + /@smithy/node-http-handler@2.1.8: + resolution: + { + integrity: sha512-KZylM7Wff/So5SmCiwg2kQNXJ+RXgz34wkxS7WNwIUXuZrZZpY/jKJCK+ZaGyuESDu3TxcaY+zeYGJmnFKbQsA==, + } + engines: { node: '>=14.0.0' } + requiresBuild: true + dependencies: + '@smithy/abort-controller': 2.0.12 + '@smithy/protocol-http': 3.0.8 + '@smithy/querystring-builder': 2.0.12 + '@smithy/types': 2.4.0 + tslib: 2.6.2 + dev: false + optional: true + + /@smithy/property-provider@2.0.13: + resolution: + { + integrity: sha512-VJqUf2CbsQX6uUiC5dUPuoEATuFjkbkW3lJHbRnpk9EDC9X+iKqhfTK+WP+lve5EQ9TcCI1Q6R7hrg41FyC54w==, + } + engines: { node: '>=14.0.0' } + requiresBuild: true + dependencies: + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true @@ -4317,38 +4575,51 @@ packages: engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/protocol-http@2.0.5: + /@smithy/protocol-http@3.0.8: resolution: { - integrity: sha512-d2hhHj34mA2V86doiDfrsy2fNTnUOowGaf9hKb0hIPHqvcnShU4/OSc4Uf1FwHkAdYF3cFXTrj5VGUYbEuvMdw==, + integrity: sha512-SHJvYeWq8q0FK8xHk+xjV9dzDUDjFMT+G1pZbV+XB6OVoac/FSVshlMNPeUJ8AmSkcDKHRu5vASnRqZHgD3qhw==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/querystring-builder@2.0.5: + /@smithy/querystring-builder@2.0.12: resolution: { - integrity: sha512-4DCX9krxLzATj+HdFPC3i8pb7XTAWzzKqSw8aTZMjXjtQY+vhe4azMAqIvbb6g7JKwIkmkRAjK6EXO3YWSnJVQ==, + integrity: sha512-cDbF07IuCjiN8CdGvPzfJjXIrmDSelScRfyJYrYBNBbKl2+k7QD/KqiHhtRyEKgID5mmEVrV6KE6L/iPJ98sFw==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 '@smithy/util-uri-escape': 2.0.0 tslib: 2.6.2 dev: false optional: true + /@smithy/querystring-parser@2.0.12: + resolution: + { + integrity: sha512-fytyTcXaMzPBuNtPlhj5v6dbl4bJAnwKZFyyItAGt4Tgm9HFPZNo7a9r1SKPr/qdxUEBzvL9Rh+B9SkTX3kFxg==, + } + engines: { node: '>=14.0.0' } + requiresBuild: true + dependencies: + '@smithy/types': 2.4.0 + tslib: 2.6.2 + dev: false + optional: true + /@smithy/querystring-parser@2.0.5: resolution: { @@ -4357,18 +4628,20 @@ packages: engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/service-error-classification@2.0.0: + /@smithy/service-error-classification@2.0.5: resolution: { - integrity: sha512-2z5Nafy1O0cTf69wKyNjGW/sNVMiqDnb4jgwfMG8ye8KnFJ5qmJpDccwIbJNhXIfbsxTg9SEec2oe1cexhMJvw==, + integrity: sha512-M0SeJnEgD2ywJyV99Fb1yKFzmxDe9JfpJiYTVSRMyRLc467BPU0qsuuDPzMCdB1mU8M8u1rVOdkqdoyFN8UFTw==, } engines: { node: '>=14.0.0' } requiresBuild: true + dependencies: + '@smithy/types': 2.4.0 dev: false optional: true @@ -4380,49 +4653,62 @@ packages: engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/signature-v4@2.0.5: + /@smithy/shared-ini-file-loader@2.2.2: resolution: { - integrity: sha512-ABIzXmUDXK4n2c9cXjQLELgH2RdtABpYKT+U131e2I6RbCypFZmxIHmIBufJzU2kdMCQ3+thBGDWorAITFW04A==, + integrity: sha512-noyQUPn7b1M8uB0GEXc/Zyxq+5K2b7aaqWnLp+hgJ7+xu/FCvtyWy5eWLDjQEsHnAet2IZhS5QF8872OR69uNg==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/eventstream-codec': 2.0.5 + '@smithy/types': 2.4.0 + tslib: 2.6.2 + dev: false + optional: true + + /@smithy/signature-v4@2.0.12: + resolution: + { + integrity: sha512-6Kc2lCZEVmb1nNYngyNbWpq0d82OZwITH11SW/Q0U6PX5fH7B2cIcFe7o6eGEFPkTZTP8itTzmYiGcECL0D0Lw==, + } + engines: { node: '>=14.0.0' } + requiresBuild: true + dependencies: + '@smithy/eventstream-codec': 2.0.12 '@smithy/is-array-buffer': 2.0.0 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 '@smithy/util-hex-encoding': 2.0.0 - '@smithy/util-middleware': 2.0.0 + '@smithy/util-middleware': 2.0.5 '@smithy/util-uri-escape': 2.0.0 '@smithy/util-utf8': 2.0.0 tslib: 2.6.2 dev: false optional: true - /@smithy/smithy-client@2.0.5: + /@smithy/smithy-client@2.1.12: resolution: { - integrity: sha512-kCTFr8wfOAWKDzGvfBElc6shHigWtHNhMQ1IbosjC4jOlayFyZMSs2PysKB+Ox/dhQ41KqOzgVjgiQ+PyWqHMQ==, + integrity: sha512-XXqhridfkKnpj+lt8vM6HRlZbqUAqBjVC74JIi13F/AYQd/zTj9SOyGfxnbp4mjY9q28LityxIuV8CTinr9r5w==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/middleware-stack': 2.0.0 - '@smithy/types': 2.2.2 - '@smithy/util-stream': 2.0.5 + '@smithy/middleware-stack': 2.0.6 + '@smithy/types': 2.4.0 + '@smithy/util-stream': 2.0.17 tslib: 2.6.2 dev: false optional: true - /@smithy/types@2.2.2: + /@smithy/types@2.4.0: resolution: { - integrity: sha512-4PS0y1VxDnELGHGgBWlDksB2LJK8TG8lcvlWxIsgR+8vROI7Ms8h1P4FQUx+ftAX2QZv5g1CJCdhdRmQKyonyw==, + integrity: sha512-iH1Xz68FWlmBJ9vvYeHifVMWJf82ONx+OybPW8ZGf5wnEv2S0UXcU4zwlwJkRXuLKpcSLHrraHbn2ucdVXLb4g==, } engines: { node: '>=14.0.0' } requiresBuild: true @@ -4431,6 +4717,19 @@ packages: dev: false optional: true + /@smithy/url-parser@2.0.12: + resolution: + { + integrity: sha512-qgkW2mZqRvlNUcBkxYB/gYacRaAdck77Dk3/g2iw0S9F0EYthIS3loGfly8AwoWpIvHKhkTsCXXQfzksgZ4zIA==, + } + requiresBuild: true + dependencies: + '@smithy/querystring-parser': 2.0.12 + '@smithy/types': 2.4.0 + tslib: 2.6.2 + dev: false + optional: true + /@smithy/url-parser@2.0.5: resolution: { @@ -4439,7 +4738,7 @@ packages: requiresBuild: true dependencies: '@smithy/querystring-parser': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true @@ -4505,34 +4804,36 @@ packages: dev: false optional: true - /@smithy/util-defaults-mode-browser@2.0.5: + /@smithy/util-defaults-mode-browser@2.0.16: resolution: { - integrity: sha512-yciP6TPttLsj731aHTvekgyuCGXQrEAJibEwEWAh3kzaDsfGAVCuZSBlyvC2Dl3TZmHKCOQwHV8mIE7KQCTPuQ==, + integrity: sha512-Uv5Cu8nVkuvLn0puX+R9zWbSNpLIR3AxUlPoLJ7hC5lvir8B2WVqVEkJLwtixKAncVLasnTVjPDCidtAUTGEQw==, } engines: { node: '>= 10.0.0' } requiresBuild: true dependencies: - '@smithy/property-provider': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/property-provider': 2.0.13 + '@smithy/smithy-client': 2.1.12 + '@smithy/types': 2.4.0 bowser: 2.11.0 tslib: 2.6.2 dev: false optional: true - /@smithy/util-defaults-mode-node@2.0.5: + /@smithy/util-defaults-mode-node@2.0.21: resolution: { - integrity: sha512-M07t99rWasXt+IaDZDyP3BkcoEm/mgIE1RIMASrE49LKSNxaVN7PVcgGc77+4uu2kzBAyqJKy79pgtezuknyjQ==, + integrity: sha512-cUEsttVZ79B7Al2rWK2FW03HBpD9LyuqFtm+1qFty5u9sHSdesr215gS2Ln53fTopNiPgeXpdoM3IgjvIO0rJw==, } engines: { node: '>= 10.0.0' } requiresBuild: true dependencies: - '@smithy/config-resolver': 2.0.5 - '@smithy/credential-provider-imds': 2.0.5 - '@smithy/node-config-provider': 2.0.5 - '@smithy/property-provider': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/config-resolver': 2.0.16 + '@smithy/credential-provider-imds': 2.0.18 + '@smithy/node-config-provider': 2.1.3 + '@smithy/property-provider': 2.0.13 + '@smithy/smithy-client': 2.1.12 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true @@ -4549,42 +4850,44 @@ packages: dev: false optional: true - /@smithy/util-middleware@2.0.0: + /@smithy/util-middleware@2.0.5: resolution: { - integrity: sha512-eCWX4ECuDHn1wuyyDdGdUWnT4OGyIzV0LN1xRttBFMPI9Ff/4heSHVxneyiMtOB//zpXWCha1/SWHJOZstG7kA==, + integrity: sha512-1lyT3TcaMJQe+OFfVI+TlomDkPuVzb27NZYdYtmSTltVmLaUjdCyt4KE+OH1CnhZKsz4/cdCL420Lg9UH5Z2Mw==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/util-retry@2.0.0: + /@smithy/util-retry@2.0.5: resolution: { - integrity: sha512-/dvJ8afrElasuiiIttRJeoS2sy8YXpksQwiM/TcepqdRVp7u4ejd9C4IQURHNjlfPUT7Y6lCDSa2zQJbdHhVTg==, + integrity: sha512-x3t1+MQAJ6QONk3GTbJNcugCFDVJ+Bkro5YqQQK1EyVesajNDqxFtCx9WdOFNGm/Cbm7tUdwVEmfKQOJoU2Vtw==, } engines: { node: '>= 14.0.0' } requiresBuild: true dependencies: - '@smithy/service-error-classification': 2.0.0 + '@smithy/service-error-classification': 2.0.5 + '@smithy/types': 2.4.0 tslib: 2.6.2 dev: false optional: true - /@smithy/util-stream@2.0.5: + /@smithy/util-stream@2.0.17: resolution: { - integrity: sha512-ylx27GwI05xLpYQ4hDIfS15vm+wYjNN0Sc2P0FxuzgRe8v0BOLHppGIQ+Bezcynk8C9nUzsUue3TmtRhjut43g==, + integrity: sha512-fP/ZQ27rRvHsqItds8yB7jerwMpZFTL3QqbQbidUiG0+mttMoKdP0ZqnvM8UK5q0/dfc3/pN7g4XKPXOU7oRWw==, } engines: { node: '>=14.0.0' } requiresBuild: true dependencies: - '@smithy/fetch-http-handler': 2.0.5 - '@smithy/node-http-handler': 2.0.5 - '@smithy/types': 2.2.2 + '@smithy/fetch-http-handler': 2.2.4 + '@smithy/node-http-handler': 2.1.8 + '@smithy/types': 2.4.0 '@smithy/util-base64': 2.0.0 '@smithy/util-buffer-from': 2.0.0 '@smithy/util-hex-encoding': 2.0.0 @@ -4854,6 +5157,13 @@ packages: } dev: true + /@types/estree@1.0.3: + resolution: + { + integrity: sha512-CS2rOaoQ/eAgAfcTfq6amKG7bsN+EMcgGY4FAFQdvSj2y1ixvOZTUA9mOtCai7E1SYu283XNw7urKK30nP3wkQ==, + } + dev: true + /@types/express-serve-static-core@4.17.36: resolution: { @@ -4878,13 +5188,13 @@ packages: '@types/serve-static': 1.15.2 dev: true - /@types/fs-extra@8.1.2: + /@types/fs-extra@8.1.4: resolution: { - integrity: sha512-SvSrYXfWSc7R4eqnOzbQF4TZmfpNSM9FrSWLU3EUnWBuyZqNBOrv1B1JA3byUDPUl9z4Ab3jeZG2eDdySlgNMg==, + integrity: sha512-OMcQKnlrkrOI0TaZ/MgVDA8LYFl7CykzFsjMj9l5x3un2nFxCY20ZFlnqrM0lcqlbs0Yro2HbnZlmopyRaoJ5w==, } dependencies: - '@types/node': 18.11.18 + '@types/node': 20.8.9 dev: true /@types/glob@7.2.0: @@ -4894,7 +5204,7 @@ packages: } dependencies: '@types/minimatch': 5.1.2 - '@types/node': 18.11.18 + '@types/node': 20.8.9 dev: true /@types/got@9.6.12: @@ -4940,10 +5250,10 @@ packages: '@types/node': 20.5.7 dev: true - /@types/istanbul-lib-coverage@2.0.4: + /@types/istanbul-lib-coverage@2.0.5: resolution: { - integrity: sha512-z/QT1XN4K4KYuslS23k62yDIDLwLFkzxOuMplDtObz0+y7VqJCaO2o+SPwHCvLFZh7xazvvoor2tA/hPz9ee7g==, + integrity: sha512-zONci81DZYCZjiLe0r6equvZut0b+dBRPBN5kBDjsONnutYNtJMoWQ9uR2RkL1gLG9NMTzvf+29e5RFfPbeKhQ==, } dev: true @@ -4953,7 +5263,7 @@ packages: integrity: sha512-plGgXAPfVKFoYfa9NpYDAkseG+g6Jr294RqeqcqDixSbU34MZVJRi/P+7Y8GDpzkEwLaGZZOpKIEmeVZNtKsrg==, } dependencies: - '@types/istanbul-lib-coverage': 2.0.4 + '@types/istanbul-lib-coverage': 2.0.5 dev: true /@types/istanbul-reports@1.1.2: @@ -4962,7 +5272,7 @@ packages: integrity: sha512-P/W9yOX/3oPZSpaYOCQzGqgCQRXn0FFO/V8bWrCQs+wLmvVVxk6CRBXALEvNs9OHIatlnlFokfhuDo2ug01ciw==, } dependencies: - '@types/istanbul-lib-coverage': 2.0.4 + '@types/istanbul-lib-coverage': 2.0.5 '@types/istanbul-lib-report': 3.0.0 dev: true @@ -5035,10 +5345,10 @@ packages: } dev: true - /@types/minimist@1.2.2: + /@types/minimist@1.2.4: resolution: { - integrity: sha512-jhuKLIRrhvCPLqwPcx6INqmKeiA5EWrsCOPhrlFSrbrmU4ZMPjj5Ul/oLCMDO98XRUIwVm78xICz4EPCektzeQ==, + integrity: sha512-Kfe/D3hxHTusnPNRbycJE1N77WHDsdS4AjUYIzlDzhDrS47NrwuL3YW4VITxwR7KCVpzwgy4Rbj829KSSQmwXQ==, } dev: true @@ -5064,11 +5374,12 @@ packages: { integrity: sha512-DHQpWGjyQKSHj3ebjFI/wRKcqQcdR+MoFBygntYOZytCqNfkd2ZC4ARDJ2DQqhjH5p85Nnd3jhUJIXrszFX/JA==, } + dev: true - /@types/node@20.4.7: + /@types/node@20.5.1: resolution: { - integrity: sha512-bUBrPjEry2QUTsnuEjzjbS7voGWCc30W0qzgMf90GPeDGFRakvrz47ju+oqDAKCXLUCe39u57/ORMl/O/04/9g==, + integrity: sha512-4tT2UrL5LBqDwoed9wZ6N3umC4Yhz3W3FloMmiiG4JwmUJWpie0c7lcnUNd4gtMKuDEO4wRVS8B6Xa0uMRsMKg==, } dev: true @@ -5077,6 +5388,14 @@ packages: { integrity: sha512-dP7f3LdZIysZnmvP3ANJYTSwg+wLLl8p7RqniVlV7j+oXSXAbt9h0WIBFmJy5inWZoX9wZN6eXx+YXd9Rh3RBA==, } + + /@types/node@20.8.9: + resolution: + { + integrity: sha512-UzykFsT3FhHb1h7yD4CA4YhBHq545JC0YnEz41xkipN88eKQtL6rSgocL5tbAP6Ola9Izm/Aw4Ora8He4x0BHg==, + } + dependencies: + undici-types: 5.26.5 dev: true /@types/normalize-package-data@2.4.1: @@ -5226,7 +5545,7 @@ packages: integrity: sha512-FtQu10RWgn3D9U4aazdwIE2yzphmTJREDqNdODHrbrZmmMqI0vMheC/6NE/J1Yveaj8H+ela+YwWTjq5PGmuhA==, } dependencies: - '@types/node': 18.11.18 + '@types/node': 20.5.7 '@types/webidl-conversions': 7.0.0 dev: false @@ -5255,10 +5574,10 @@ packages: '@types/yargs-parser': 21.0.0 dev: true - /@types/yauzl@2.10.0: + /@types/yauzl@2.10.2: resolution: { - integrity: sha512-Cn6WYCm0tXv8p6k+A8PvbDG763EDpBoTzHdA+Q/MF6H3sapGjCm9NzoaJncJS9tUKSuCoDs9XHxYYsQDgxR6kw==, + integrity: sha512-Km7XAtUIduROw7QPgvcft0lIupeG8a8rdKL8RiSyKvlE7dYY31fEn41HVuQsRFDuROA8tA4K2UVL+WdfFmErBA==, } requiresBuild: true dependencies: @@ -5639,6 +5958,13 @@ packages: eslint-visitor-keys: 3.4.3 dev: true + /@ungap/structured-clone@1.2.0: + resolution: + { + integrity: sha512-zuVdFrMJiuCDQUMCzQaD6KL28MjnqqN8XnAqiEq9PNm/hCPTSGfrXCOfwj1ow4LFb/tNymJPwsNbVePc1xFqrQ==, + } + dev: true + /@vercel/nft@0.22.6(supports-color@9.4.0): resolution: { @@ -6734,23 +7060,6 @@ packages: dev: false optional: true - /boxen@4.2.0: - resolution: - { - integrity: sha512-eB4uT9RGzg2odpER62bBwSLvUeGC+WbRjjyyFhGsKnc8wp/m0+hQsMUvUe3H2V0D5vw0nBdO1hCJoZo5mKeuIQ==, - } - engines: { node: '>=8' } - dependencies: - ansi-align: 3.0.1 - camelcase: 5.3.1 - chalk: 3.0.0 - cli-boxes: 2.2.1 - string-width: 4.2.3 - term-size: 2.2.1 - type-fest: 0.8.1 - widest-line: 3.1.0 - dev: true - /boxen@5.1.2: resolution: { @@ -6995,10 +7304,10 @@ packages: engines: { node: '>= 0.8' } dev: true - /c8@7.13.0: + /c8@7.14.0: resolution: { - integrity: sha512-/NL4hQTv1gBL6J6ei80zu3IiTrmePDKXKXOTLpHvcIWZTVYQlDhVWjjWvkhICylE8EwwnMVzDZugCvdx0/DIIA==, + integrity: sha512-i04rtkkcNcCf7zsQcSv/T9EbUn4RXQ6mropeMcjFOsQXQ0iGLAr/xT6TImQg4+U9hmNpN9XdvPkjUL1IzbgxJw==, } engines: { node: '>=10.12.0' } hasBin: true @@ -7012,7 +7321,7 @@ packages: istanbul-reports: 3.1.6 rimraf: 3.0.2 test-exclude: 6.0.0 - v8-to-istanbul: 9.1.0 + v8-to-istanbul: 9.1.3 yargs: 16.2.0 yargs-parser: 20.2.9 dev: true @@ -7064,7 +7373,7 @@ packages: '@types/http-cache-semantics': 4.0.1 get-stream: 6.0.1 http-cache-semantics: 4.1.1 - keyv: 4.5.3 + keyv: 4.5.4 mimic-response: 4.0.0 normalize-url: 8.0.0 responselike: 3.0.0 @@ -8044,16 +8353,14 @@ packages: q: 1.5.1 dev: true - /conventional-changelog-conventionalcommits@5.0.0: + /conventional-changelog-conventionalcommits@6.1.0: resolution: { - integrity: sha512-lCDbA+ZqVFQGUj7h9QBKoIpLhl8iihkO0nCTyRNzuXtcd7ubODpYB04IFy31JloiJgG0Uovu8ot8oxRzn7Nwtw==, + integrity: sha512-3cS3GEtR78zTfMzk0AizXKKIdN4OvSh7ibNz6/DPbhWWQu7LqE/8+/GqSodV+sywUR2gpJAdP/1JFf4XtN7Zpw==, } - engines: { node: '>=10' } + engines: { node: '>=14' } dependencies: compare-func: 2.0.0 - lodash: 4.17.21 - q: 1.5.1 dev: true /conventional-changelog-core@4.2.4: @@ -8243,6 +8550,13 @@ packages: } dev: true + /convert-source-map@2.0.0: + resolution: + { + integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==, + } + dev: true + /cookie-signature@1.0.6: resolution: { @@ -8308,7 +8622,7 @@ packages: } dev: true - /cosmiconfig-typescript-loader@4.4.0(@types/node@20.4.7)(cosmiconfig@8.2.0)(ts-node@10.9.1)(typescript@4.9.4): + /cosmiconfig-typescript-loader@4.4.0(@types/node@20.5.1)(cosmiconfig@8.3.6)(ts-node@10.9.1)(typescript@5.2.2): resolution: { integrity: sha512-BabizFdC3wBHhbI4kJh0VkQP9GkBfoHPydD0COMce1nJ1kJAB3F2TmJ/I7diULBKtmEWSwEbuN/KDtgnmUUVmw==, @@ -8320,10 +8634,10 @@ packages: ts-node: '>=10' typescript: '>=4' dependencies: - '@types/node': 20.4.7 - cosmiconfig: 8.2.0 - ts-node: 10.9.1(@types/node@20.4.7)(typescript@4.9.4) - typescript: 4.9.4 + '@types/node': 20.5.1 + cosmiconfig: 8.3.6(typescript@5.2.2) + ts-node: 10.9.1(@types/node@20.5.1)(typescript@5.2.2) + typescript: 5.2.2 dev: true /cosmiconfig@7.1.0: @@ -8340,17 +8654,23 @@ packages: yaml: 1.10.2 dev: true - /cosmiconfig@8.2.0: + /cosmiconfig@8.3.6(typescript@5.2.2): resolution: { - integrity: sha512-3rTMnFJA1tCOPwRxtgF4wd7Ab2qvDbL8jX+3smjIbS4HlZBagTlpERbdN7iAbWlrfxE3M8c27kTwTawQ7st+OQ==, + integrity: sha512-kcZ6+W5QzcJ3P1Mt+83OUv/oHFqZHIx8DuxG6eZ5RGMERoLqp4BuGjhHLYGK+Kf5XVkQvqBSmAy/nGWN3qDgEA==, } engines: { node: '>=14' } + peerDependencies: + typescript: '>=4.9.5' + peerDependenciesMeta: + typescript: + optional: true dependencies: import-fresh: 3.3.0 js-yaml: 4.1.0 parse-json: 5.2.0 path-type: 4.0.0 + typescript: 5.2.2 dev: true /counteraction@1.3.2: @@ -9589,7 +9909,6 @@ packages: integrity: sha512-IPzF4w4/Rd94bA9imS68tZBaYyBWSCE47V1RGuMrB94iyTOIEwRmVL2x/4An+6mETpLrKJ5hQkB8W4kFAadeIQ==, } engines: { node: '>=12' } - dev: true /dotgitignore@2.1.0: resolution: @@ -10273,16 +10592,16 @@ packages: source-map: 0.6.1 dev: true - /eslint-config-prettier@8.6.0(eslint@8.34.0): + /eslint-config-prettier@8.10.0(eslint@8.52.0): resolution: { - integrity: sha512-bAF0eLpLVqP5oEVUFKpMA+NnRFICwn9X8B5jrR9FcqnYBuPbqWEjTEspPWMj5ye6czoSLDweCzSo3Ko7gGrZaA==, + integrity: sha512-SM8AMJdeQqRYT9O9zguiruQZaN7+z+E4eAP9oiLNGKMtomwaB1E9dcgUD6ZAn/eQAb52USbvezbiljfZUhbJcg==, } hasBin: true peerDependencies: eslint: '>=7.0.0' dependencies: - eslint: 8.34.0 + eslint: 8.52.0 dev: true /eslint-plugin-qwik@0.15.0(eslint@8.29.0): @@ -10357,19 +10676,6 @@ packages: eslint-visitor-keys: 2.1.0 dev: true - /eslint-utils@3.0.0(eslint@8.34.0): - resolution: - { - integrity: sha512-uuQC43IGctw68pJA1RgbQS8/NP7rch6Cwd4j3ZBtgo4/8Flj4eGE7ZYSZRN3iq5pVUv6GPdW5Z1RFleo84uLDA==, - } - engines: { node: ^10.0.0 || ^12.0.0 || >= 14.0.0 } - peerDependencies: - eslint: '>=5' - dependencies: - eslint: 8.34.0 - eslint-visitor-keys: 2.1.0 - dev: true - /eslint-visitor-keys@2.1.0: resolution: { @@ -10488,18 +10794,22 @@ packages: - supports-color dev: true - /eslint@8.34.0: + /eslint@8.52.0: resolution: { - integrity: sha512-1Z8iFsucw+7kSqXNZVslXS8Ioa4u2KM7GPwuKtkTFAqZ/cHMcEaR+1+Br0wLlot49cNxIiZk5wp8EAbPcYZxTg==, + integrity: sha512-zh/JHnaixqHZsolRB/w9/02akBk9EPrOs9JwcTP2ek7yL5bVvXuRariiaAjjoJ5DvuwQ1WAE/HsMz+w17YgBCg==, } engines: { node: ^12.22.0 || ^14.17.0 || >=16.0.0 } hasBin: true dependencies: - '@eslint/eslintrc': 1.4.1 - '@humanwhocodes/config-array': 0.11.10 + '@eslint-community/eslint-utils': 4.4.0(eslint@8.52.0) + '@eslint-community/regexpp': 4.10.0 + '@eslint/eslintrc': 2.1.2 + '@eslint/js': 8.52.0 + '@humanwhocodes/config-array': 0.11.13 '@humanwhocodes/module-importer': 1.0.1 '@nodelib/fs.walk': 1.2.8 + '@ungap/structured-clone': 1.2.0 ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.3 @@ -10507,7 +10817,6 @@ packages: doctrine: 3.0.0 escape-string-regexp: 4.0.0 eslint-scope: 7.2.2 - eslint-utils: 3.0.0(eslint@8.34.0) eslint-visitor-keys: 3.4.3 espree: 9.6.1 esquery: 1.5.0 @@ -10516,14 +10825,12 @@ packages: file-entry-cache: 6.0.1 find-up: 5.0.0 glob-parent: 6.0.2 - globals: 13.21.0 - grapheme-splitter: 1.0.4 + globals: 13.23.0 + graphemer: 1.4.0 ignore: 5.2.4 - import-fresh: 3.3.0 imurmurhash: 0.1.4 is-glob: 4.0.3 is-path-inside: 3.0.3 - js-sdsl: 4.4.2 js-yaml: 4.1.0 json-stable-stringify-without-jsonify: 1.0.1 levn: 0.4.1 @@ -10531,9 +10838,7 @@ packages: minimatch: 3.1.2 natural-compare: 1.4.0 optionator: 0.9.3 - regexpp: 3.2.0 strip-ansi: 6.0.1 - strip-json-comments: 3.1.1 text-table: 0.2.0 transitivePeerDependencies: - supports-color @@ -10936,7 +11241,7 @@ packages: get-stream: 5.2.0 yauzl: 2.10.0 optionalDependencies: - '@types/yauzl': 2.10.0 + '@types/yauzl': 2.10.2 transitivePeerDependencies: - supports-color dev: true @@ -11126,7 +11431,7 @@ packages: } engines: { node: ^10.12.0 || >=12.0.0 } dependencies: - flat-cache: 3.0.4 + flat-cache: 3.1.1 dev: true /file-size@0.0.5: @@ -11327,21 +11632,22 @@ packages: path-exists: 5.0.0 dev: true - /flat-cache@3.0.4: + /flat-cache@3.1.1: resolution: { - integrity: sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg==, + integrity: sha512-/qM2b3LUIaIgviBQovTLvijfyOQXPtSRnRK26ksj2J7rzPIecePUIpJsZ4T02Qg+xiAEKIs5K8dsHEd+VaKa/Q==, } - engines: { node: ^10.12.0 || >=12.0.0 } + engines: { node: '>=12.0.0' } dependencies: - flatted: 3.2.7 + flatted: 3.2.9 + keyv: 4.5.4 rimraf: 3.0.2 dev: true - /flatted@3.2.7: + /flatted@3.2.9: resolution: { - integrity: sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==, + integrity: sha512-36yxDn5H7OFZQla0/jFJmbIKTdZAQHngCedGxiMmpNfEZM0sdEeT+WczLQrjK6D7o2aiyLYDnkw0R3JK0Qv1RQ==, } dev: true @@ -11626,10 +11932,10 @@ packages: integrity: sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==, } - /fs-extra@11.1.0: + /fs-extra@11.1.1: resolution: { - integrity: sha512-0rcTq621PD5jM/e0a3EJoGC/1TC5ZBCERW82LQuwfGnCa1V8w7dpYH1yNu+SLb6E5dkeCBzKEyLGlFrnr+dUyw==, + integrity: sha512-MGIE4HOvQCeUCzmlHs0vXpih4ysz4wg9qiSAu6cd42lVwPbTM1TjV7RusoyQqMmk/95gdQZX72u+YW+c3eEpFQ==, } engines: { node: '>=14.14' } dependencies: @@ -11695,6 +12001,13 @@ packages: } dev: true + /function-bind@1.1.2: + resolution: + { + integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==, + } + dev: true + /function.prototype.name@1.1.5: resolution: { @@ -12097,6 +12410,19 @@ packages: once: 1.4.0 dev: true + /glob@9.3.5: + resolution: + { + integrity: sha512-e1LleDykUz2Iu+MTYdkSsuWX8lvAjAcs0Xef0lNIu0S2wOAzuTxCJtcd9S3cijlwYF18EsU3rzb8jPVobxDh9Q==, + } + engines: { node: '>=16 || 14 >=14.17' } + dependencies: + fs.realpath: 1.0.0 + minimatch: 8.0.4 + minipass: 4.2.8 + path-scurry: 1.10.1 + dev: true + /global-cache-dir@2.0.0: resolution: { @@ -12148,6 +12474,16 @@ packages: type-fest: 0.20.2 dev: true + /globals@13.23.0: + resolution: + { + integrity: sha512-XAmF0RjlrjY23MA51q3HltdlGxUpXPvg0GioKiD9X6HD28iMjo2dKC8Vqwm7lne4GNr78+RHTfliktR6ZH09wA==, + } + engines: { node: '>=8' } + dependencies: + type-fest: 0.20.2 + dev: true + /globalthis@1.0.3: resolution: { @@ -12348,6 +12684,13 @@ packages: } dev: true + /graphemer@1.4.0: + resolution: + { + integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==, + } + dev: true + /graphql@16.5.0: resolution: { @@ -12599,6 +12942,16 @@ packages: type-fest: 0.8.1 dev: true + /hasown@2.0.0: + resolution: + { + integrity: sha512-vUptKVTpIJhcczKBbgnS+RtcuYMB8+oNzPK2/Hp3hanz8JmpATdmmgLgSaadVREkDm+e2giHwY3ZRkyjSIDDFA==, + } + engines: { node: '>= 0.4' } + dependencies: + function-bind: 1.1.2 + dev: true + /hast-util-has-property@2.0.1: resolution: { @@ -13321,6 +13674,15 @@ packages: has: 1.0.3 dev: true + /is-core-module@2.13.1: + resolution: + { + integrity: sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw==, + } + dependencies: + hasown: 2.0.0 + dev: true + /is-data-descriptor@0.1.4: resolution: { @@ -13716,7 +14078,7 @@ packages: integrity: sha512-U82MsXXiFIrjCK4otLT+o2NA2Cd2g5MLoOVXUZjIOhLurrRxpEXzI8O0KZHr3IjLvlAH1kTPYSuqer5T9ZVBKQ==, } dependencies: - '@types/estree': 1.0.1 + '@types/estree': 1.0.3 dev: true /is-reference@3.0.1: @@ -14424,6 +14786,15 @@ packages: json-buffer: 3.0.1 dev: true + /keyv@4.5.4: + resolution: + { + integrity: sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==, + } + dependencies: + json-buffer: 3.0.1 + dev: true + /kind-of@3.2.2: resolution: { @@ -15096,6 +15467,14 @@ packages: engines: { node: ^12.20.0 || ^14.13.1 || >=16.0.0 } dev: true + /lru-cache@10.0.1: + resolution: + { + integrity: sha512-IJ4uwUTi2qCccrioU6g9g/5rvvVl13bsdczUUcqbciD9iLr095yj8DQKdObriEvuNSx325N1rV1O0sJFszx75g==, + } + engines: { node: 14 || >=16.14 } + dev: true + /lru-cache@2.3.1: resolution: { @@ -15155,6 +15534,16 @@ packages: '@jridgewell/sourcemap-codec': 1.4.15 dev: true + /magic-string@0.30.5: + resolution: + { + integrity: sha512-7xlpfBaQaP/T6Vh8MO/EqXSW5En6INHEvEXQiuff7Gku0PWjU3uf6w/j9o7O+SpB5fOAkrI5HeoNgwjEO0pFsA==, + } + engines: { node: '>=12' } + dependencies: + '@jridgewell/sourcemap-codec': 1.4.15 + dev: true + /make-dir@1.3.0: resolution: { @@ -15490,7 +15879,7 @@ packages: } engines: { node: '>=10' } dependencies: - '@types/minimist': 1.2.2 + '@types/minimist': 1.2.4 camelcase-keys: 6.2.2 decamelize-keys: 1.1.1 hard-rejection: 2.1.0 @@ -16068,6 +16457,16 @@ packages: brace-expansion: 2.0.1 dev: true + /minimatch@8.0.4: + resolution: + { + integrity: sha512-W0Wvr9HyFXZRGIDgCicunpQ299OKXs9RgZfaukz4qAW/pJhcpUfupc9c+OObPOFueNy8VSrZgEmDtk6Kh4WzDA==, + } + engines: { node: '>=16 || 14 >=14.17' } + dependencies: + brace-expansion: 2.0.1 + dev: true + /minimatch@9.0.3: resolution: { @@ -16106,6 +16505,14 @@ packages: yallist: 4.0.0 dev: true + /minipass@4.2.8: + resolution: + { + integrity: sha512-fNzuVyifolSLFL4NzpF+wEF4qrgqaaKX0haXPQEdQ7NKAN+WecoKMHV09YcuL/DHxrUsYQOK3MiuDf7Ip2OXfQ==, + } + engines: { node: '>=8' } + dev: true + /minipass@5.0.0: resolution: { @@ -16114,6 +16521,14 @@ packages: engines: { node: '>=8' } dev: true + /minipass@7.0.4: + resolution: + { + integrity: sha512-jYofLM5Dam9279rdkWzqHozUo4ybjdZmCsDHePy5V/PbBcVMiSZR97gmAy45aqi8CK1lG2ECd356FU86avfwUQ==, + } + engines: { node: '>=16 || 14 >=14.17' } + dev: true + /minizlib@2.1.2: resolution: { @@ -16225,7 +16640,7 @@ packages: mongodb-connection-string-url: 2.6.0 socks: 2.7.1 optionalDependencies: - '@aws-sdk/credential-providers': 3.398.0 + '@aws-sdk/credential-providers': 3.437.0 saslprep: 1.0.3 transitivePeerDependencies: - aws-crt @@ -16770,7 +17185,7 @@ packages: } dependencies: hosted-git-info: 2.8.9 - resolve: 1.22.4 + resolve: 1.22.8 semver: 5.7.2 validate-npm-package-license: 3.0.4 dev: true @@ -16783,8 +17198,8 @@ packages: engines: { node: '>=10' } dependencies: hosted-git-info: 4.1.0 - is-core-module: 2.13.0 - semver: 7.3.8 + is-core-module: 2.13.1 + semver: 7.5.4 validate-npm-package-license: 3.0.4 dev: true @@ -17096,14 +17511,13 @@ packages: mimic-fn: 4.0.0 dev: true - /only-allow@1.1.1: + /only-allow@1.2.1: resolution: { - integrity: sha512-WE01hpInLQUF3MKK7vhu4p1VZLKb4rL4d+CI3rwwwsToXELx6YawNFhZy3rVU3rpQpI9kF9zFMk4OjB3xwXdJA==, + integrity: sha512-M7CJbmv7UCopc0neRKdzfoGWaVZC+xC1925GitKH9EAqYFzX9//25Q7oX4+jw0tiCCj+t5l6VZh8UPH23NZkMA==, } hasBin: true dependencies: - boxen: 4.2.0 which-pm-runs: 1.1.0 dev: true @@ -17761,6 +18175,17 @@ packages: } dev: true + /path-scurry@1.10.1: + resolution: + { + integrity: sha512-MkhCqzzBEpPvxxQ71Md0b1Kk51W01lrYvlMzSUaIzNsODdd7mqhiimSZlr+VegAz5Z6Vzt9Xg2ttE//XBhH3EQ==, + } + engines: { node: '>=16 || 14 >=14.17' } + dependencies: + lru-cache: 10.0.1 + minipass: 7.0.4 + dev: true + /path-to-regexp@0.1.7: resolution: { @@ -18199,7 +18624,7 @@ packages: dependencies: lilconfig: 2.1.0 postcss: 8.4.19 - ts-node: 10.9.1(@types/node@20.4.7)(typescript@4.9.4) + ts-node: 10.9.1(@types/node@20.5.1)(typescript@5.2.2) yaml: 1.10.2 dev: true @@ -18717,10 +19142,10 @@ packages: hasBin: true dev: true - /prettier@2.8.4: + /prettier@2.8.8: resolution: { - integrity: sha512-vIS4Rlc2FNh0BySk3Wkd6xmwxB0FpOndW5fisM5H8hsZSxU2VWVB5CWIkIjWvrHjIhxk2g3bfMKM87zNTrZddw==, + integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==, } engines: { node: '>=10.13.0' } hasBin: true @@ -18769,7 +19194,7 @@ packages: parse-ms: 2.1.0 dev: true - /pretty-quick@3.1.3(prettier@2.8.4): + /pretty-quick@3.1.3(prettier@2.8.8): resolution: { integrity: sha512-kOCi2FJabvuh1as9enxYmrnBC6tVMoVOenMaBqRfsvBHB0cbpYHjdQEpSglpASDFEXVwplpcGR4CLEaisYAFcA==, @@ -18785,7 +19210,7 @@ packages: ignore: 5.2.4 mri: 1.2.0 multimatch: 4.0.0 - prettier: 2.8.4 + prettier: 2.8.8 dev: true /prettyjson@1.2.5: @@ -19641,14 +20066,26 @@ packages: supports-preserve-symlinks-flag: 1.0.0 dev: true - /resolve@2.0.0-next.4: + /resolve@1.22.8: resolution: { - integrity: sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==, + integrity: sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==, } hasBin: true dependencies: - is-core-module: 2.13.0 + is-core-module: 2.13.1 + path-parse: 1.0.7 + supports-preserve-symlinks-flag: 1.0.0 + dev: true + + /resolve@2.0.0-next.5: + resolution: + { + integrity: sha512-U7WjGVG9sH8tvjW5SmGbQuui75FiyjAX72HX15DwBBwF9dNiQZRQAg9nnPhYy+TUnE0+VcrttuvNI8oSxZcocA==, + } + hasBin: true + dependencies: + is-core-module: 2.13.1 path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 dev: true @@ -19761,17 +20198,18 @@ packages: dependencies: glob: 7.2.3 - /rimraf@4.1.2: + /rimraf@4.4.1: resolution: { - integrity: sha512-BlIbgFryTbw3Dz6hyoWFhKk+unCcHMSkZGrTFVAx2WmttdBSonsdtRlwiuTbDqTKr+UlXIUqJVS4QT5tUzGENQ==, + integrity: sha512-Gk8NlF062+T9CqNGn6h4tls3k6T1+/nXdOcSZVikNVtlRdYpA7wRJJMoXmuvOnLW844rPjdQ7JgXCYM6PPC/og==, } engines: { node: '>=14' } - deprecated: Please upgrade to 4.3.1 or higher to fix a potentially damaging issue regarding symbolic link following. See https://github.com/isaacs/rimraf/issues/259 for details. hasBin: true + dependencies: + glob: 9.3.5 dev: true - /rollup-plugin-cleanup@3.2.1(rollup@3.17.2): + /rollup-plugin-cleanup@3.2.1(rollup@3.29.4): resolution: { integrity: sha512-zuv8EhoO3TpnrU8MX8W7YxSbO4gmOR0ny06Lm3nkFfq0IVKdBUtHwhVzY1OAJyNCIAdLiyPnOrU0KnO0Fri1GQ==, @@ -19781,18 +20219,18 @@ packages: rollup: '>=2.0' dependencies: js-cleanup: 1.2.0 - rollup: 3.17.2 + rollup: 3.29.4 rollup-pluginutils: 2.8.2 dev: true - /rollup-plugin-copy@3.4.0: + /rollup-plugin-copy@3.5.0: resolution: { - integrity: sha512-rGUmYYsYsceRJRqLVlE9FivJMxJ7X6jDlP79fmFkL8sJs7VVMSVyA2yfyL+PGyO/vJs4A87hwhgVfz61njI+uQ==, + integrity: sha512-wI8D5dvYovRMx/YYKtUNt3Yxaw4ORC9xo6Gt9t22kveWz1enG9QrhVlagzwrxSC455xD1dHMKhIJkbsQ7d48BA==, } engines: { node: '>=8.3' } dependencies: - '@types/fs-extra': 8.1.2 + '@types/fs-extra': 8.1.4 colorette: 1.4.0 fs-extra: 8.1.0 globby: 10.0.1 @@ -19819,21 +20257,10 @@ packages: fsevents: 2.3.3 dev: true - /rollup@3.17.2: + /rollup@3.29.4: resolution: { - integrity: sha512-qMNZdlQPCkWodrAZ3qnJtvCAl4vpQ8q77uEujVCCbC/6CLB7Lcmvjq7HyiOSnf4fxTT9XgsE36oLHJBH49xjqA==, - } - engines: { node: '>=14.18.0', npm: '>=8.0.0' } - hasBin: true - optionalDependencies: - fsevents: 2.3.3 - dev: true - - /rollup@3.28.1: - resolution: - { - integrity: sha512-R9OMQmIHJm9znrU3m3cpE8uhN0fGdXiawME7aZIpQqvpS/85+Vt1Hq1/yVIcYfOmaQiHjvXkQAoJukvLpau6Yw==, + integrity: sha512-oWzmBZwvYrU0iJHtDmhsm662rC15FRXmcjCk1xD771dFDx5jJ02ufAQQTn0etB2emNk4J9EZg/yWKpsn9BWGRw==, } engines: { node: '>=14.18.0', npm: '>=8.0.0' } hasBin: true @@ -20045,17 +20472,6 @@ packages: hasBin: true dev: true - /semver@7.3.8: - resolution: - { - integrity: sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A==, - } - engines: { node: '>=10' } - hasBin: true - dependencies: - lru-cache: 6.0.0 - dev: true - /semver@7.5.4: resolution: { @@ -20692,7 +21108,7 @@ packages: figures: 3.2.0 find-up: 5.0.0 git-semver-tags: 4.1.1 - semver: 7.3.8 + semver: 7.5.4 stringify-package: 1.0.1 yargs: 16.2.0 dev: true @@ -21443,14 +21859,6 @@ packages: unique-string: 2.0.0 dev: true - /term-size@2.2.1: - resolution: - { - integrity: sha512-wK0Ri4fOGjv/XPy8SBHZChl8CM7uMc5VML7SqiQ0zG7+J5Vr+RMQDoHa2CNT6KHUnTGIXH34UDMkPzAUyapBZg==, - } - engines: { node: '>=8' } - dev: true - /terminal-link@2.1.1: resolution: { @@ -21859,7 +22267,7 @@ packages: } dev: true - /ts-node@10.9.1(@types/node@20.4.7)(typescript@4.9.4): + /ts-node@10.9.1(@types/node@20.5.1)(typescript@5.2.2): resolution: { integrity: sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==, @@ -21881,14 +22289,14 @@ packages: '@tsconfig/node12': 1.0.11 '@tsconfig/node14': 1.0.3 '@tsconfig/node16': 1.0.4 - '@types/node': 20.4.7 + '@types/node': 20.5.1 acorn: 8.10.0 acorn-walk: 8.2.0 arg: 4.1.3 create-require: 1.1.1 diff: 4.0.2 make-error: 1.3.6 - typescript: 4.9.4 + typescript: 5.2.2 v8-compile-cache-lib: 3.0.1 yn: 3.1.1 dev: true @@ -21944,12 +22352,14 @@ packages: { integrity: sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==, } + requiresBuild: true /tslib@2.6.2: resolution: { integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==, } + requiresBuild: true /tsutils@3.21.0(typescript@4.8.4): resolution: @@ -22231,6 +22641,15 @@ packages: hasBin: true dev: true + /typescript@5.2.2: + resolution: + { + integrity: sha512-mI4WrpHsbCIcwT9cF4FZvr80QUeKvsUsUvKDoR+X/7XHQH98xYD8YHZg7ANtz2GtZt/CBq2QJ0thkGJMHfqc1w==, + } + engines: { node: '>=14.17' } + hasBin: true + dev: true + /uglify-js@3.17.4: resolution: { @@ -22279,6 +22698,13 @@ packages: } dev: true + /undici-types@5.26.5: + resolution: + { + integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==, + } + dev: true + /undici@5.14.0: resolution: { @@ -22683,6 +23109,7 @@ packages: integrity: sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==, } hasBin: true + requiresBuild: true /uuid@9.0.0: resolution: @@ -22713,16 +23140,16 @@ packages: } dev: true - /v8-to-istanbul@9.1.0: + /v8-to-istanbul@9.1.3: resolution: { - integrity: sha512-6z3GW9x8G1gd+JIIgQQQxXuiJtCXeAjp6RaPEPLv62mH3iPHPxV6W3robxtCzNErRo6ZwTmzWhsbNvjyEBKzKA==, + integrity: sha512-9lDD+EVI2fjFsMWXc6dy5JJzBsVTcQ2fVkfBvncZ6xJWG9wtBhOldG+mHkSL0+V1K/xgZz0JDO5UT5hFwHUghg==, } engines: { node: '>=10.12.0' } dependencies: - '@jridgewell/trace-mapping': 0.3.19 - '@types/istanbul-lib-coverage': 2.0.4 - convert-source-map: 1.9.0 + '@jridgewell/trace-mapping': 0.3.20 + '@types/istanbul-lib-coverage': 2.0.5 + convert-source-map: 2.0.0 dev: true /validate-npm-package-license@3.0.4: @@ -22799,14 +23226,14 @@ packages: vfile-message: 3.1.4 dev: true - /vite-imagetools@4.0.11(rollup@3.17.2): + /vite-imagetools@4.0.11(rollup@3.29.4): resolution: { integrity: sha512-S6+vzsd/6kSBdPIdjJFGeZ4+UV/aIK09V7oLb/Z9soV3jNwKh60WBi6jF+RnKtY7F9FMU3W6xPbln+VPHI0icA==, } engines: { node: '>=12.0.0' } dependencies: - '@rollup/pluginutils': 5.0.3(rollup@3.17.2) + '@rollup/pluginutils': 5.0.3(rollup@3.29.4) imagetools-core: 3.2.3 transitivePeerDependencies: - rollup @@ -22915,7 +23342,7 @@ packages: esbuild: 0.16.17 postcss: 8.4.28 resolve: 1.22.4 - rollup: 3.28.1 + rollup: 3.29.4 optionalDependencies: fsevents: 2.3.3 dev: true diff --git a/scripts/release.js b/scripts/release.js index f3d26bbcd..bd819b574 100644 --- a/scripts/release.js +++ b/scripts/release.js @@ -81,7 +81,7 @@ const checkExistVersion = async (packageName = null, version = null) => { try { const pkgJson = join(PATH_PACKAGES, packageName) const pkgJsonObject = readPackage(packageName) - const { stdout } = await cmd(NPM_COMMAND, ['view', `${pkgJsonObject.name}@${version}`], { + await cmd(NPM_COMMAND, ['view', `${pkgJsonObject.name}@${version}`], { stdio: 'inherit', cwd: pkgJson, }) diff --git a/starters/apps/base-baileys-json/.eslintrc.js b/starters/apps/base-baileys-json/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-baileys-json/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-baileys-json/.gitignore b/starters/apps/base-baileys-json/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-baileys-json/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-baileys-json/package.json b/starters/apps/base-baileys-json/package.json index 6f85ee56f..1e5bc2321 100644 --- a/starters/apps/base-baileys-json/package.json +++ b/starters/apps/base-baileys-json/package.json @@ -18,6 +18,10 @@ "@whiskeysockets/baileys": "^6.4.0", "wa-sticker-formatter": "4.3.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-baileys-memory/.eslintrc.js b/starters/apps/base-baileys-memory/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-baileys-memory/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-baileys-memory/.gitignore b/starters/apps/base-baileys-memory/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-baileys-memory/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-baileys-memory/package.json b/starters/apps/base-baileys-memory/package.json index 5c64e3537..3457bd951 100644 --- a/starters/apps/base-baileys-memory/package.json +++ b/starters/apps/base-baileys-memory/package.json @@ -17,6 +17,10 @@ "@whiskeysockets/baileys": "^6.4.0", "wa-sticker-formatter": "4.3.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-baileys-mongo/.eslintrc.js b/starters/apps/base-baileys-mongo/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-baileys-mongo/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-baileys-mongo/.gitignore b/starters/apps/base-baileys-mongo/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-baileys-mongo/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-baileys-mongo/package.json b/starters/apps/base-baileys-mongo/package.json index 305261b0d..8faba3f2d 100644 --- a/starters/apps/base-baileys-mongo/package.json +++ b/starters/apps/base-baileys-mongo/package.json @@ -19,6 +19,10 @@ "@whiskeysockets/baileys": "^6.4.0", "wa-sticker-formatter": "4.3.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-baileys-mysql/.eslintrc.js b/starters/apps/base-baileys-mysql/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-baileys-mysql/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-baileys-mysql/.gitignore b/starters/apps/base-baileys-mysql/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-baileys-mysql/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-baileys-mysql/package.json b/starters/apps/base-baileys-mysql/package.json index b1284ff69..949b8b65e 100644 --- a/starters/apps/base-baileys-mysql/package.json +++ b/starters/apps/base-baileys-mysql/package.json @@ -18,6 +18,10 @@ "@whiskeysockets/baileys": "^6.4.0", "wa-sticker-formatter": "4.3.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-baileys-postgres/.eslintrc.js b/starters/apps/base-baileys-postgres/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-baileys-postgres/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-baileys-postgres/.gitignore b/starters/apps/base-baileys-postgres/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-baileys-postgres/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-baileys-postgres/package.json b/starters/apps/base-baileys-postgres/package.json index 95f7ae970..813e2f655 100644 --- a/starters/apps/base-baileys-postgres/package.json +++ b/starters/apps/base-baileys-postgres/package.json @@ -18,6 +18,10 @@ "wa-sticker-formatter": "4.3.2", "pg": "^8.11.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-meta-json/.eslintrc.js b/starters/apps/base-meta-json/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-meta-json/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-meta-json/.gitignore b/starters/apps/base-meta-json/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-meta-json/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-meta-json/package.json b/starters/apps/base-meta-json/package.json index 10d215ede..1e7dc62f7 100644 --- a/starters/apps/base-meta-json/package.json +++ b/starters/apps/base-meta-json/package.json @@ -17,6 +17,10 @@ "@bot-whatsapp/provider": "latest", "axios": "^1.2.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-meta-memory/.eslintrc.js b/starters/apps/base-meta-memory/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-meta-memory/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-meta-memory/.gitignore b/starters/apps/base-meta-memory/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-meta-memory/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-meta-memory/package.json b/starters/apps/base-meta-memory/package.json index 4eef87f9a..666949226 100644 --- a/starters/apps/base-meta-memory/package.json +++ b/starters/apps/base-meta-memory/package.json @@ -17,6 +17,10 @@ "@bot-whatsapp/provider": "latest", "axios": "^1.2.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-meta-mongo/.eslintrc.js b/starters/apps/base-meta-mongo/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-meta-mongo/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-meta-mongo/.gitignore b/starters/apps/base-meta-mongo/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-meta-mongo/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-meta-mongo/package.json b/starters/apps/base-meta-mongo/package.json index c949de860..e44b24de0 100644 --- a/starters/apps/base-meta-mongo/package.json +++ b/starters/apps/base-meta-mongo/package.json @@ -18,6 +18,10 @@ "axios": "^1.2.1", "mongodb": "^4.12.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-meta-mysql/.eslintrc.js b/starters/apps/base-meta-mysql/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-meta-mysql/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-meta-mysql/.gitignore b/starters/apps/base-meta-mysql/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-meta-mysql/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-meta-mysql/package.json b/starters/apps/base-meta-mysql/package.json index 55e3ce28f..1b072d92f 100644 --- a/starters/apps/base-meta-mysql/package.json +++ b/starters/apps/base-meta-mysql/package.json @@ -18,6 +18,10 @@ "axios": "^1.2.1", "mysql2": "^2.3.3" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-meta-postgres/.eslintrc.js b/starters/apps/base-meta-postgres/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-meta-postgres/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-meta-postgres/.gitignore b/starters/apps/base-meta-postgres/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-meta-postgres/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-meta-postgres/package.json b/starters/apps/base-meta-postgres/package.json index 420c35d29..2c6920276 100644 --- a/starters/apps/base-meta-postgres/package.json +++ b/starters/apps/base-meta-postgres/package.json @@ -18,6 +18,10 @@ "axios": "^1.2.1", "pg": "^8.11.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-twilio-json/.eslintrc.js b/starters/apps/base-twilio-json/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-twilio-json/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-twilio-json/.gitignore b/starters/apps/base-twilio-json/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-twilio-json/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-twilio-json/package.json b/starters/apps/base-twilio-json/package.json index 4d05e6584..18f0c3165 100644 --- a/starters/apps/base-twilio-json/package.json +++ b/starters/apps/base-twilio-json/package.json @@ -17,6 +17,10 @@ "@bot-whatsapp/database": "latest", "@bot-whatsapp/provider": "latest" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-twilio-memory/.eslintrc.js b/starters/apps/base-twilio-memory/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-twilio-memory/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-twilio-memory/.gitignore b/starters/apps/base-twilio-memory/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-twilio-memory/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-twilio-memory/package.json b/starters/apps/base-twilio-memory/package.json index 8b2533ff9..8c4bdda4c 100644 --- a/starters/apps/base-twilio-memory/package.json +++ b/starters/apps/base-twilio-memory/package.json @@ -17,6 +17,10 @@ "@bot-whatsapp/database": "latest", "@bot-whatsapp/provider": "latest" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-twilio-mongo/.eslintrc.js b/starters/apps/base-twilio-mongo/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-twilio-mongo/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-twilio-mongo/.gitignore b/starters/apps/base-twilio-mongo/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-twilio-mongo/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-twilio-mongo/package.json b/starters/apps/base-twilio-mongo/package.json index 4b182c723..6103d7a15 100644 --- a/starters/apps/base-twilio-mongo/package.json +++ b/starters/apps/base-twilio-mongo/package.json @@ -19,6 +19,10 @@ "mime-types": "^2.1.35", "mongodb": "^4.12.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-twilio-mysql/.eslintrc.js b/starters/apps/base-twilio-mysql/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-twilio-mysql/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-twilio-mysql/.gitignore b/starters/apps/base-twilio-mysql/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-twilio-mysql/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-twilio-mysql/package.json b/starters/apps/base-twilio-mysql/package.json index aec11c4ee..70c18fe12 100644 --- a/starters/apps/base-twilio-mysql/package.json +++ b/starters/apps/base-twilio-mysql/package.json @@ -18,6 +18,10 @@ "@bot-whatsapp/provider": "latest", "mysql2": "^2.3.3" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-twilio-postgres/.eslintrc.js b/starters/apps/base-twilio-postgres/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-twilio-postgres/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-twilio-postgres/.gitignore b/starters/apps/base-twilio-postgres/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-twilio-postgres/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-twilio-postgres/package.json b/starters/apps/base-twilio-postgres/package.json index c71324da8..69e457b21 100644 --- a/starters/apps/base-twilio-postgres/package.json +++ b/starters/apps/base-twilio-postgres/package.json @@ -18,6 +18,10 @@ "@bot-whatsapp/provider": "latest", "pg": "^8.11.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-venom-json/.eslintrc.js b/starters/apps/base-venom-json/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-venom-json/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-venom-json/.gitignore b/starters/apps/base-venom-json/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-venom-json/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-venom-json/package.json b/starters/apps/base-venom-json/package.json index a8088fea0..b25633c77 100644 --- a/starters/apps/base-venom-json/package.json +++ b/starters/apps/base-venom-json/package.json @@ -17,6 +17,10 @@ "@bot-whatsapp/provider": "latest", "@bot-whatsapp/portal": "latest" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-venom-memory/.eslintrc.js b/starters/apps/base-venom-memory/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-venom-memory/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-venom-memory/.gitignore b/starters/apps/base-venom-memory/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-venom-memory/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-venom-memory/package.json b/starters/apps/base-venom-memory/package.json index 65d660a82..e7d8d0d71 100644 --- a/starters/apps/base-venom-memory/package.json +++ b/starters/apps/base-venom-memory/package.json @@ -17,6 +17,10 @@ "@bot-whatsapp/portal": "latest", "mime-types": "2.1.35" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-venom-mongo/.eslintrc.js b/starters/apps/base-venom-mongo/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-venom-mongo/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-venom-mongo/.gitignore b/starters/apps/base-venom-mongo/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-venom-mongo/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-venom-mongo/package.json b/starters/apps/base-venom-mongo/package.json index 1de9e1907..f765476f6 100644 --- a/starters/apps/base-venom-mongo/package.json +++ b/starters/apps/base-venom-mongo/package.json @@ -18,6 +18,10 @@ "mime-types": "2.1.35", "mongodb": "^4.12.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-venom-mysql/.eslintrc.js b/starters/apps/base-venom-mysql/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-venom-mysql/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-venom-mysql/.gitignore b/starters/apps/base-venom-mysql/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-venom-mysql/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-venom-mysql/package.json b/starters/apps/base-venom-mysql/package.json index 766ef6720..68c8bfec8 100644 --- a/starters/apps/base-venom-mysql/package.json +++ b/starters/apps/base-venom-mysql/package.json @@ -18,6 +18,10 @@ "mysql2": "^2.3.3", "mime-types": "2.1.35" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-venom-postgres/.eslintrc.js b/starters/apps/base-venom-postgres/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-venom-postgres/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-venom-postgres/.gitignore b/starters/apps/base-venom-postgres/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-venom-postgres/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-venom-postgres/package.json b/starters/apps/base-venom-postgres/package.json index f95988bca..4a9d57a4f 100644 --- a/starters/apps/base-venom-postgres/package.json +++ b/starters/apps/base-venom-postgres/package.json @@ -18,6 +18,10 @@ "mime-types": "2.1.35", "pg": "^8.11.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wppconnect-json/.eslintrc.js b/starters/apps/base-wppconnect-json/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wppconnect-json/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wppconnect-json/.gitignore b/starters/apps/base-wppconnect-json/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wppconnect-json/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wppconnect-json/package.json b/starters/apps/base-wppconnect-json/package.json index 8bfaddc09..a963e1a21 100644 --- a/starters/apps/base-wppconnect-json/package.json +++ b/starters/apps/base-wppconnect-json/package.json @@ -17,6 +17,10 @@ "@wppconnect-team/wppconnect": "^1.27.3", "mime-types": "2.1.35" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wppconnect-memory/.eslintrc.js b/starters/apps/base-wppconnect-memory/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wppconnect-memory/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wppconnect-memory/.gitignore b/starters/apps/base-wppconnect-memory/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wppconnect-memory/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wppconnect-memory/package.json b/starters/apps/base-wppconnect-memory/package.json index 8a0bf692d..6f6775e0a 100644 --- a/starters/apps/base-wppconnect-memory/package.json +++ b/starters/apps/base-wppconnect-memory/package.json @@ -17,6 +17,10 @@ "@wppconnect-team/wppconnect": "^1.27.3", "mime-types": "2.1.35" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wppconnect-mongo/.eslintrc.js b/starters/apps/base-wppconnect-mongo/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wppconnect-mongo/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wppconnect-mongo/.gitignore b/starters/apps/base-wppconnect-mongo/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wppconnect-mongo/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wppconnect-mongo/package.json b/starters/apps/base-wppconnect-mongo/package.json index d56044ffb..f75b5510a 100644 --- a/starters/apps/base-wppconnect-mongo/package.json +++ b/starters/apps/base-wppconnect-mongo/package.json @@ -18,6 +18,10 @@ "mime-types": "2.1.35", "mongodb": "4.12.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wppconnect-mysql/.eslintrc.js b/starters/apps/base-wppconnect-mysql/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wppconnect-mysql/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wppconnect-mysql/.gitignore b/starters/apps/base-wppconnect-mysql/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wppconnect-mysql/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wppconnect-mysql/package.json b/starters/apps/base-wppconnect-mysql/package.json index 5617892ff..7182dada2 100644 --- a/starters/apps/base-wppconnect-mysql/package.json +++ b/starters/apps/base-wppconnect-mysql/package.json @@ -18,6 +18,10 @@ "mime-types": "2.1.35", "mysql2": "2.3.3" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wppconnect-postgres/.eslintrc.js b/starters/apps/base-wppconnect-postgres/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wppconnect-postgres/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wppconnect-postgres/.gitignore b/starters/apps/base-wppconnect-postgres/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wppconnect-postgres/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wppconnect-postgres/package.json b/starters/apps/base-wppconnect-postgres/package.json index 7136b309a..70d3e10cf 100644 --- a/starters/apps/base-wppconnect-postgres/package.json +++ b/starters/apps/base-wppconnect-postgres/package.json @@ -18,6 +18,10 @@ "mime-types": "2.1.35", "pg": "^8.11.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wweb-json/.eslintrc.js b/starters/apps/base-wweb-json/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wweb-json/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wweb-json/.gitignore b/starters/apps/base-wweb-json/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wweb-json/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wweb-json/package.json b/starters/apps/base-wweb-json/package.json index 0a270a16b..ec30aaffa 100644 --- a/starters/apps/base-wweb-json/package.json +++ b/starters/apps/base-wweb-json/package.json @@ -16,6 +16,10 @@ "@bot-whatsapp/portal": "latest", "whatsapp-web.js": "^1.22.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wweb-memory/.eslintrc.js b/starters/apps/base-wweb-memory/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wweb-memory/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wweb-memory/.gitignore b/starters/apps/base-wweb-memory/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wweb-memory/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wweb-memory/package.json b/starters/apps/base-wweb-memory/package.json index b762530c5..bf1d817a5 100644 --- a/starters/apps/base-wweb-memory/package.json +++ b/starters/apps/base-wweb-memory/package.json @@ -16,6 +16,10 @@ "@bot-whatsapp/portal": "latest", "whatsapp-web.js": "^1.22.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wweb-mongo/.eslintrc.js b/starters/apps/base-wweb-mongo/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wweb-mongo/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wweb-mongo/.gitignore b/starters/apps/base-wweb-mongo/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wweb-mongo/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wweb-mongo/package.json b/starters/apps/base-wweb-mongo/package.json index ce1c57d56..256660d88 100644 --- a/starters/apps/base-wweb-mongo/package.json +++ b/starters/apps/base-wweb-mongo/package.json @@ -18,6 +18,10 @@ "mime-types": "^2.1.35", "mongodb": "^4.12.1" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wweb-mysql/.eslintrc.js b/starters/apps/base-wweb-mysql/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wweb-mysql/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wweb-mysql/.gitignore b/starters/apps/base-wweb-mysql/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wweb-mysql/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wweb-mysql/package.json b/starters/apps/base-wweb-mysql/package.json index 02abf8926..4b1c32f18 100644 --- a/starters/apps/base-wweb-mysql/package.json +++ b/starters/apps/base-wweb-mysql/package.json @@ -17,6 +17,10 @@ "@bot-whatsapp/portal": "latest", "mysql2": "^2.3.3" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" } diff --git a/starters/apps/base-wweb-postgres/.eslintrc.js b/starters/apps/base-wweb-postgres/.eslintrc.js new file mode 100644 index 000000000..7a287ba0b --- /dev/null +++ b/starters/apps/base-wweb-postgres/.eslintrc.js @@ -0,0 +1,23 @@ +module.exports = { + env: { + browser: true, + commonjs: true, + es2021: true, + }, + overrides: [ + { + env: { + node: true, + }, + files: ['.eslintrc.{js,cjs}'], + parserOptions: { + sourceType: 'script', + }, + }, + ], + parserOptions: { + ecmaVersion: 'latest', + }, + plugins: ['bot-whatsapp'], + extends: ['plugin:bot-whatsapp/recommended'], +} diff --git a/starters/apps/base-wweb-postgres/.gitignore b/starters/apps/base-wweb-postgres/.gitignore new file mode 100644 index 000000000..a6390c587 --- /dev/null +++ b/starters/apps/base-wweb-postgres/.gitignore @@ -0,0 +1,4 @@ +node_modules +.env +*_sessions +*.log \ No newline at end of file diff --git a/starters/apps/base-wweb-postgres/package.json b/starters/apps/base-wweb-postgres/package.json index 77e18d5ee..89bde4ad4 100644 --- a/starters/apps/base-wweb-postgres/package.json +++ b/starters/apps/base-wweb-postgres/package.json @@ -17,6 +17,10 @@ "@bot-whatsapp/portal": "latest", "pg": "^8.11.2" }, + "devDependencies": { + "eslint-plugin-bot-whatsapp": "latest", + "eslint": "^8.52.0" + }, "author": "", "license": "ISC" }